today_ai_weather/app/views/devise/passwords/edit.html.erb
songtianlun be1f76a76d feat: enhance devise views with new styling
- Updated confirmation, password, unlock, and session views to use a
  card-based layout for improved visual appeal.
- Added responsive design features to ensure compatibility across devices.
- Enhanced usability by providing clear placeholders in form fields.

These changes improve the user experience during account recovery and
management processes. The design promotes a modern interface while
maintaining functionality.
2025-02-11 16:43:05 +08:00

39 lines
1.6 KiB
Plaintext

<div class="min-h-screen flex items-center justify-center px-4">
<div class="card w-full max-w-md bg-base-100 shadow-xl">
<div class="card-body">
<h2 class="card-title text-2xl mb-4">Change your password</h2>
<%= form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f| %>
<%= render "devise/shared/error_messages", resource: resource %>
<%= f.hidden_field :reset_password_token %>
<div class="form-control">
<%= f.label :password, "New password", class: "label" %>
<% if @minimum_password_length %>
<small class="text-gray-500">(<%= @minimum_password_length %> characters minimum)</small>
<% end %>
<%= f.password_field :password, autofocus: true, autocomplete: "new-password",
class: "input input-bordered w-full",
placeholder: "Enter new password" %>
</div>
<div class="form-control mt-4">
<%= f.label :password_confirmation, "Confirm new password", class: "label" %>
<%= f.password_field :password_confirmation, autocomplete: "new-password",
class: "input input-bordered w-full",
placeholder: "Confirm new password" %>
</div>
<div class="form-control mt-6">
<%= f.submit "Change my password", class: "btn btn-primary w-full" %>
</div>
<% end %>
<div class="divider"></div>
<div class="text-sm text-center">
<%= render "devise/shared/links" %>
</div>
</div>
</div>
</div>