hubfeenix.fi/app/views/devise/registrations/edit.html.haml

33 lines
2.4 KiB
Plaintext
Raw Normal View History

2022-12-20 20:02:36 +01:00
.flex.justify-center
2023-01-20 08:35:45 +01:00
.w-full.max-w-xs.md:max-w-md
2023-01-20 07:15:33 +01:00
%h1.font-hairline.mb-6.text-center.text-2xl
Change password
2022-12-21 17:04:09 +01:00
= form_for(resource, as: resource_name,
html: { class: "bg-white mb-4 px-8 pt-6 pb-8 rounded shadow-md",
method: :put } ,
url: registration_path(resource_name) ) do |f|
2022-12-20 20:46:58 +01:00
= render "devise/shared/error_messages", resource: resource
2022-12-20 20:02:36 +01:00
- if devise_mapping.confirmable? && resource.pending_reconfirmation?
%div
Currently waiting confirmation for: #{resource.unconfirmed_email}
.mb-4
2023-01-20 07:15:33 +01:00
= f.label :new_password, class: "block font-bold mb-2 text-gray-700 text-sm"
2022-12-20 20:02:36 +01:00
= f.password_field :password, autocomplete: "new-password", class: "shadow appearance-none border rounded w-full py-2 px-3 text-gray-700 mb-3 leading-tight focus:outline-none focus:shadow-outline"
.mb-4
= f.label :password_confirmation, class: "block font-bold mb-2 text-gray-700 text-sm"
= f.password_field :password_confirmation, |
autocomplete: "new-password", |
class: "shadow appearance-none border rounded w-full py-2 px-3 text-gray-700 mb-3 leading-tight focus:outline-none focus:shadow-outline" |
.mb-4
= f.label :current_password, class: "block font-bold mb-2 text-gray-700 text-sm"
= f.password_field :current_password, |
autocomplete: "current-password", |
class: "shadow appearance-none border rounded w-full py-2 px-3 text-gray-700 mb-3 leading-tight focus:outline-none focus:shadow-outline" |
.actions
2023-01-16 19:17:23 +01:00
= f.submit "Update", class: "button bg-cyan-700 hover:bg-cyan-500 font-bold text-white focus:outline-none py-2 px-4 rounded focus:shadow-outline w-full"
2023-01-20 07:15:33 +01:00
.flex.justify-between
%p
%span= button_to "Delete my account", registration_path(resource_name), data: { confirm: "Are you sure?" }, method: :delete , class: button_classes
%button{class: button_classes}
= link_to "Back", :back