diff options
author | David Yip <yipdw@member.fsf.org> | 2018-02-02 08:39:52 -0600 |
---|---|---|
committer | David Yip <yipdw@member.fsf.org> | 2018-02-02 08:39:52 -0600 |
commit | 4c1fd9a19c779fa6e7d74513c61f37ce05a841b3 (patch) | |
tree | 0cf23810e2f7ff0f45c65a3f2f9b35016587c68a /app/views/auth/passwords | |
parent | ad3a2dfb66abc01a90807f23191b7e28c3c242ed (diff) | |
parent | 33f56811e38bc330de9dcfa6794c29a176a30311 (diff) |
Merge remote-tracking branch 'tootsuite/master' into merge-upstream
Conflicts: app/javascript/styles/mastodon/components.scss
Diffstat (limited to 'app/views/auth/passwords')
-rw-r--r-- | app/views/auth/passwords/edit.html.haml | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/app/views/auth/passwords/edit.html.haml b/app/views/auth/passwords/edit.html.haml index 5ef3de976..d8fed9e77 100644 --- a/app/views/auth/passwords/edit.html.haml +++ b/app/views/auth/passwords/edit.html.haml @@ -1,14 +1,18 @@ - content_for :page_title do = t('auth.set_new_password') -= simple_form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f| - = render 'shared/error_messages', object: resource - = f.input :reset_password_token, as: :hidden + = simple_form_for(resource, as: resource_name, url: password_path(resource_name), html: { method: :put }) do |f| + = render 'shared/error_messages', object: resource - = f.input :password, autofocus: true, placeholder: t('simple_form.labels.defaults.new_password'), input_html: { 'aria-label' => t('simple_form.labels.defaults.new_password'), :autocomplete => 'off' } - = f.input :password_confirmation, placeholder: t('simple_form.labels.defaults.confirm_new_password'), input_html: { 'aria-label' => t('simple_form.labels.defaults.confirm_new_password'), :autocomplete => 'off' } + - if use_pam? || current_user.encrypted_password.present? + = f.input :reset_password_token, as: :hidden - .actions - = f.button :button, t('auth.set_new_password'), type: :submit + = f.input :password, autofocus: true, placeholder: t('simple_form.labels.defaults.new_password'), input_html: { 'aria-label' => t('simple_form.labels.defaults.new_password'), :autocomplete => 'off' } + = f.input :password_confirmation, placeholder: t('simple_form.labels.defaults.confirm_new_password'), input_html: { 'aria-label' => t('simple_form.labels.defaults.confirm_new_password'), :autocomplete => 'off' } + + .actions + = f.button :button, t('auth.set_new_password'), type: :submit + - else + = t('simple_form.labels.defaults.pam_account') .form-footer= render 'auth/shared/links' |