[openstreetmap/openstreetmap-website] Refactor login form to use form helpers for password field (PR #4935)
Anton Khorev
notifications at github.com
Tue Jul 2 12:54:15 UTC 2024
@AntonKhorev commented on this pull request.
> </div>
- <input class="form-control mb-3" type="password" name="password" id="password" tabindex="2" value="" autocomplete="on" />
+
+ <%= f.password_field :password, :autocomplete => true, :tabindex => 2, :value => "", :skip_label => true %>
Why was `autocomplete="on"` changed to `autocomplete="true"`?
> + <div class="col d-flex justify-content-between align-items-center">
+ <%= f.label :password, t(".password"), :class => "my-2" %>
+ <small><%= link_to(t(".lost password link"), user_forgot_password_path) %></small>
Why do you need `.col`? This element is not inside `.row`.
I'd do this:
```suggestion
<div class="d-flex flex-wrap column-gap-3 justify-content-between align-items-baseline">
<%= f.label :password, t(".password"), :class => "my-2" %>
<small class="mb-2"><%= link_to(t(".lost password link"), user_forgot_password_path) %></small>
```
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/4935#pullrequestreview-2153712358
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/openstreetmap-website/pull/4935/review/2153712358 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20240702/eb9dd1cb/attachment.htm>
More information about the rails-dev
mailing list