-  return {
-    session  => $::locale->text('The session is invalid or has expired.'),
-    password => $::locale->text('Incorrect password!'),
-  }->{$_[0]};
+  my %states = (
+    session  => { warning => t8('The session has expired. Please log in again.')                   },
+    password => { error   => t8('Incorrect username or password or no access to selected client!') },
+    action   => { warning => t8('The action is missing or invalid.')                               },
+  );
+
+  return %{ $states{$_[0]} || {} };
+}
+
+sub set_layout {
+  $::request->{layout} = SL::Layout::Dispatcher->new(style => 'login');
+}
+
+sub init_clients {
+  return SL::DB::Manager::AuthClient->get_all_sorted;
+}
+
+sub init_default_client_id {
+  my ($self)         = @_;
+  my $default_client = first { $_->is_default } @{ $self->clients };
+  return $default_client ? $default_client->id : undef;
+}
+
+sub show_login_form {
+  my ($self, %params) = @_;
+
+  $self->render('login_screen/user_login', %params, version => $::form->read_version);