From abbbb09180f510bdf4ee9766fefe292e82e65be0 Mon Sep 17 00:00:00 2001 From: Lisa Durand Date: Wed, 11 Sep 2024 11:41:11 +0200 Subject: [PATCH] make reset link page clearer --- .../users/passwords/reset_link_sent.html.haml | 47 ++++++++----------- config/locales/en.yml | 6 +-- config/locales/fr.yml | 5 +- 3 files changed, 22 insertions(+), 36 deletions(-) diff --git a/app/views/users/passwords/reset_link_sent.html.haml b/app/views/users/passwords/reset_link_sent.html.haml index 712bb866a..1e2aef66d 100644 --- a/app/views/users/passwords/reset_link_sent.html.haml +++ b/app/views/users/passwords/reset_link_sent.html.haml @@ -3,34 +3,25 @@ - content_for :footer do = render partial: 'root/footer' -.fr-container.fr-mt-4w.fr-mb-3w +.fr-container.fr-my-4w .fr-grid-row.fr-grid-row--center .fr-col-12.fr-col-md-9.fr-col-lg-7 - .center - = image_tag('user/confirmation-email.svg', alt: "") - %h1.fr-mb-6w - = t('views.users.passwords.reset_link_sent.got_it') - %br - = t('views.users.passwords.reset_link_sent.open_your_mailbox') + %h1.fr-h2 + = t('views.users.passwords.reset_link_sent.email_sent_html', email: @email, application_name: Current.application_name) - .fr-callout.fr-callout--green-emeraude.fr-mb-6w - %p.fr-callout__text.fr-mb-2w - = t('views.users.passwords.reset_link_sent.email_sent_html', email: @email, application_name: Current.application_name) - %p.fr-callout__text.fr-mb-2w - = t('views.users.passwords.reset_link_sent.click_link_to_reset_password') - %p.fr-callout__text - = t('views.users.shared.email_can_take_a_while_html') - - %h2= t('views.users.passwords.reset_link_sent.no_mail') - %ol - %li - = t('views.users.passwords.reset_link_sent.check_spams') - %li - = t('views.users.passwords.reset_link_sent.check_account', email: @email, application_name: Current.application_name) - - if FranceConnectService.enabled? - %li - = t('views.users.passwords.reset_link_sent.check_france_connect_html', href: france_connect_particulier_path) - %li - = t('views.users.passwords.reset_link_sent.check_gpdr') - %p - = t('views.users.shared.contact_us_if_any_trouble_html', href: contact_url) + = render Dsfr::AlertComponent.new(title: t('views.users.passwords.reset_link_sent.no_mail'), state: '', extra_class_names: 'fr-alert--info' ) do |c| + - c.with_body do + %ol + %li + = t('views.users.shared.email_can_take_a_while_html') + %li + = t('views.users.passwords.reset_link_sent.check_spams') + %li + = t('views.users.passwords.reset_link_sent.check_account', email: @email, application_name: Current.application_name) + - if FranceConnectService.enabled? + %li + = t('views.users.passwords.reset_link_sent.check_france_connect_html', href: france_connect_particulier_path) + %li + = t('views.users.passwords.reset_link_sent.check_gpdr') + %p + = t('views.users.shared.contact_us_if_any_trouble_html', href: contact_url) diff --git a/config/locales/en.yml b/config/locales/en.yml index 825eecee3..7a4601239 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -574,15 +574,13 @@ en: submit: Change password submit_loading: Sending… reset_link_sent: - got_it: Got it! - open_your_mailbox: Now open your mailbox. - email_sent_html: "If a %{application_name} account exists with the address %{email}, we have sent you an email." - click_link_to_reset_password: Click on the link in the email to change your password. + email_sent_html: "If an account exists with the address %{email}, we have sent you an email." no_mail: Didn't receive the email? check_spams: Check your junk or spam email. check_account: Have you created a %{application_name} account with the adress %{email}? You will not receive any message if no account is linked to your email adress. check_france_connect_html: Have you once logged in with France Connect? If yes, try again with France Connect. check_gpdr: "The account may have been deleted in the event of prolonged inactivity and no current file. In this case you will have to recreate an account from a procedure." + title: "Password reset link sent" shared: email_can_take_a_while_html: Please note that this email can take up to 15 minutes to arrive. contact_us_if_any_trouble_html: 'You can contact us through this form if a problem still exists.' diff --git a/config/locales/fr.yml b/config/locales/fr.yml index 397254c61..8ee504710 100644 --- a/config/locales/fr.yml +++ b/config/locales/fr.yml @@ -577,15 +577,12 @@ fr: submit: Changer le mot de passe submit_loading: Envoi… reset_link_sent: - email_sent_html: "Si un compte %{application_name} existe avec l’adresse %{email}, nous vous avons envoyé un email." - click_link_to_reset_password: "Cliquez sur le lien contenu dans l’email pour changer votre mot de passe." + email_sent_html: "Si un compte existe avec l’adresse %{email}, nous vous avons envoyé un email pour réinitialiser votre mot de passe." no_mail: "Vous n’avez pas reçu l’email ?" check_spams: "Vérifiez la boite Indésirables ou Spam de votre boite email." check_account: "Avez-vous bien créé un compte %{application_name} avec l’adresse %{email} ? Si aucun compte n’existe avec cette adresse, vous ne recevrez pas de message." check_france_connect_html: "Vous êtes-vous connecté avec France Connect par le passé ? Dans ce cas essayez à nouveau avec France Connect." check_gpdr: "Le compte a pu être supprimé en cas d’inactivité prolongée et sans dossier en cours. Dans ce cas vous devrez recréer un compte à partir d’une démarche." - got_it: "Bien reçu !" - open_your_mailbox: "Maintenant ouvrez votre boite email." title: "Lien de réinitialisation du mot de passe envoyé" shared: email_can_take_a_while_html: "Attention, ce courriel peut mettre jusqu’à 15 minutes pour arriver."