From 1ce191943c7348023fb8cdd936572e977ceb023c Mon Sep 17 00:00:00 2001 From: Emin Kocan Date: Mon, 1 Jul 2024 13:23:03 +0200 Subject: [PATCH] refactor password field to use form helpers --- app/views/sessions/new.html.erb | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/app/views/sessions/new.html.erb b/app/views/sessions/new.html.erb index 57e6d014a..4ee1168f0 100644 --- a/app/views/sessions/new.html.erb +++ b/app/views/sessions/new.html.erb @@ -33,15 +33,12 @@ <%= f.text_field :username, :label => t(".email or username"), :autofocus => true, :tabindex => 1, :value => params[:username] %> -
-
- <%= f.label :password, t(".password"), :class => "form-label" %> -
-
- <%= link_to(t(".lost password link"), user_forgot_password_path) %> -
+
+ <%= f.label :password, t(".password"), :class => "my-2" %> + <%= link_to(t(".lost password link"), user_forgot_password_path) %>
- + + <%= f.password_field :password, :autocomplete => "on", :tabindex => 2, :value => "", :skip_label => true %> <%= f.form_group do %> <%= f.check_box :remember_me, { :label => t(".remember"), :tabindex => 3, :checked => (params[:remember_me] == "yes") }, "yes" %> -- 2.39.5