-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #117 from 5andu/devise-pages-design-improvements
- Loading branch information
Showing
5 changed files
with
39 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,30 +1,32 @@ | ||
<%= render 'devise/shared/devise_heading', title: 'Change your password' %> | ||
<div class="min-h-screen flex justify-center py-12 px-4 sm:px-6 lg:px-8"> | ||
<div class="max-w-md w-full"> | ||
<%= render 'devise/shared/devise_heading', title: 'Change your password' %> | ||
<%= form_for(resource, as: resource_name, url: password_path(resource_name), html: { class: "mt-8", method: :put }) do |f| %> | ||
<%= render "devise/shared/error_messages", resource: resource %> | ||
<%= f.hidden_field :reset_password_token %> | ||
|
||
<div class="field mb-2"> | ||
<div class="field mb-3"> | ||
<%= f.label :password, "New password" %><br /> | ||
<% if @minimum_password_length %> | ||
<em>(<%= @minimum_password_length %> characters minimum)</em><br /> | ||
<% end %> | ||
<%= f.password_field :password, autofocus: true, autocomplete: "new-password", class: "appearance-none rounded-b-md rounded-t-md relative block w-full px-3 py-2 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:border-primary-300 focus:ring-primary-500 focus:z-10 sm:text-sm sm:leading-5" %> | ||
<%= f.password_field :password, autofocus: true, autocomplete: "new-password", class: "my-1 block w-full rounded-md border-gray-300 shadow-sm focus:border-primary-500 focus:ring focus:ring-primary-500 focus:ring-opacity-50" %> | ||
</div> | ||
|
||
<div class="field mb-2"> | ||
<div class="field mb-3"> | ||
<%= f.label :password_confirmation, "Confirm new password" %><br /> | ||
<%= f.password_field :password_confirmation, autocomplete: "new-password", class: "appearance-none rounded-b-md rounded-t-md relative block w-full px-3 py-2 border border-gray-300 placeholder-gray-500 text-gray-900 focus:outline-none focus:border-primary-300 focus:ring-primary-500 focus:z-10 sm:text-sm sm:leading-5" %> | ||
<%= f.password_field :password_confirmation, autocomplete: "new-password", class: "my-1 block w-full rounded-md border-gray-300 shadow-sm focus:border-primary-500 focus:ring focus:ring-primary-500 focus:ring-opacity-50" %> | ||
</div> | ||
|
||
<div class="mt-6"> | ||
<%= f.submit "Change my password", class: "group relative w-full flex justify-center py-2 px-4 border border-transparent text-sm leading-5 font-medium rounded-md text-white bg-primary-600 hover:bg-primary-700 focus:outline-none transition duration-150 ease-in-out cursor-pointer" %> | ||
<%= f.submit "Change my password", class: "group relative w-full flex justify-center py-2.5 px-4 border border-transparent text-sm leading-5 font-medium rounded-md text-white bg-primary-600 hover:bg-primary-700 focus:outline-none cursor-pointer" %> | ||
</div> | ||
<% end %> | ||
|
||
<div class="flex space-x-3 justify-center"> | ||
<%= render "devise/shared/links" %> | ||
<div class="flex space-x-3 justify-center mt-2"> | ||
<%= link_to "Log in", new_user_session_path, class: "text-sm leading-5 font-medium text-gray-600 hover:text-gray-500 focus:outline-none focus:underline transition ease-in-out duration-150" %> | ||
<%= link_to "Sign up", new_user_registration_path, class: "text-sm leading-5 font-medium text-gray-600 hover:text-gray-500 focus:outline-none focus:underline transition ease-in-out duration-150" %> | ||
</div> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<div class="pt-3"> | ||
<p class="text-neutral-600 text-center"> | ||
<%= subtitle %> | ||
</p> | ||
</div> |