From 12e65c638bbdcb9a57aeb897c330440550012b79 Mon Sep 17 00:00:00 2001 From: Connor Turland Date: Mon, 27 Oct 2014 18:24:30 -0400 Subject: [PATCH] changes for reset password form --- app/assets/stylesheets/application.css | 6 ++++++ .../users/mailer/reset_password_instructions.html.erb | 4 ++-- app/views/users/passwords/edit.html.erb | 8 ++++---- config/environments/production.rb | 2 +- 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/app/assets/stylesheets/application.css b/app/assets/stylesheets/application.css index ea524f6d..a6e71fed 100644 --- a/app/assets/stylesheets/application.css +++ b/app/assets/stylesheets/application.css @@ -242,6 +242,12 @@ input[type="submit"]:active { margin-top: -83px; line-height: 18px; } +.forgotPasswordReset { + height: 215px !important; +} +.forgotPasswordReset input[type="submit"] { + top: 200px !important; +} /* forgot password fix */ diff --git a/app/views/users/mailer/reset_password_instructions.html.erb b/app/views/users/mailer/reset_password_instructions.html.erb index c0444a6d..bb938968 100644 --- a/app/views/users/mailer/reset_password_instructions.html.erb +++ b/app/views/users/mailer/reset_password_instructions.html.erb @@ -2,10 +2,10 @@

Please create a new password. Your password needs to contain a capital letter, a number, an emoji, 7 elements from the Periodic Table, and a plot containing a protagonist with some character development and a surprise twist ending.

-

Just kidding. But it does have to be between 8 and 128 characters.

+

Just kidding. But it does have to be between 8 and 40 characters.

Change your password using the link below.

-

<%= link_to 'Change my password', edit_password_url(@resource, :reset_password_token => @resource.reset_password_token) %>

+

<%= link_to 'Change my password', edit_password_url(@resource, :reset_password_token => @token) %>

If you didn't request this, click your heels three times and pretend nothing ever happened.

diff --git a/app/views/users/passwords/edit.html.erb b/app/views/users/passwords/edit.html.erb index 109d2e25..5eb51623 100644 --- a/app/views/users/passwords/edit.html.erb +++ b/app/views/users/passwords/edit.html.erb @@ -1,15 +1,15 @@ <% content_for :title, "Change Password | Metamaps" %>
-<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :class => "forgotPassword centerGreyForm" }) do |f| %> +<%= form_for(resource, :as => resource_name, :url => password_path(resource_name), :html => { :method => :put, :class => "forgotPassword centerGreyForm forgotPasswordReset" }) do |f| %> <%= f.hidden_field :reset_password_token %> -

Change your password

+

Change password

-
<%= f.label :password, "New password" %> +
<%= f.label :password, "New password", :class => "firstFieldText" %> <%= f.password_field :password, :autofocus => true %>
-
<%= f.label :password_confirmation, "Confirm new password" %> +
<%= f.label :password_confirmation, "Confirm new password", :class => "firstFieldText" %> <%= f.password_field :password_confirmation %>
<%= f.submit "Change my password" %>
diff --git a/config/environments/production.rb b/config/environments/production.rb index 0707c5e7..eddb8e01 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -34,7 +34,7 @@ Metamaps::Application.configure do authentication: 'plain', enable_starttls_auto: true, openssl_verify_mode: 'none' } - config.action_mailer.default_url_options = { :host => 'metamaps.cc' } + config.action_mailer.default_url_options = { :host => 'metamaps.herokuapp.com' } # Don't care if the mailer can't send config.action_mailer.raise_delivery_errors = true