Add instructional text to the 2FA setup screen#686
Conversation
jessieay
left a comment
There was a problem hiding this comment.
Looks awesome! One comment about using HTML within I18n.
config/locales/devise/en.yml
Outdated
There was a problem hiding this comment.
I18n protip: we can keep this lead text in the same translation and bold it by taking advantage of I18n's built-in HTML support.
How:
append _html to the translation name (so this would be otp_setup_html), and add the css you need into the translation inline. Like this:
<strong>Every time you log in,</strong> we will send you a one-time passcode via text we will send you a one-time passcode via text message or phone call. This helps safeguard your account.
The Rails view will automatically interpret this string as HTML now. (don't forget to also change the key in the view to be = t('devise.two_factor_authentication.otp_setup_html')
There was a problem hiding this comment.
Thanks, that's great to know! Will implement. 👍
config/locales/devise/en.yml
Outdated
There was a problem hiding this comment.
To me, "any time" implies that there is a setting where they can change their choice, even after authenticating, but we don't have that feature. The only times they can make a choice are:
- right before they are about to receive an OTP, such as on the phone setup screen or on the delivery method screen
- when already having received an OTP and deciding they want to change the delivery method ("call me with the code instead", or "text me the code instead")
There was a problem hiding this comment.
you're right @monfresh but I feel like that subtle difference is fine here
There was a problem hiding this comment.
Perhaps we should ask @esgoodman and @jeanninehunter to weigh in here? What do each of you think about this language given the feature set?
There was a problem hiding this comment.
All good points. However, I can easily see how we might be more precise without destroying plain language simplicity. Let's go with this for otp_method.instruction:
You can change your choice the next time you sign in
**Why**: - Presumably, users found it confusing before Rework 2FA setup info and instruction text **Why**: - Makes instructional language more accurate - Simplifies translation strings for info paragraph
74a965f to
3cd028f
Compare
|
Changes implemented! Ready for a second review. |
**Why**: - Presumably, users found it confusing before Rework 2FA setup info and instruction text **Why**: - Makes instructional language more accurate - Simplifies translation strings for info paragraph
* Updating capitalization of login.gov to Login.gov. * Updating ASCII because fun is important. * Fixin dat YAML. * MOAR YML! * Update config/locales/user_mailer/es.yml Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update config/locales/user_mailer/es.yml Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update config/locales/user_mailer/es.yml Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update config/locales/user_mailer/fr.yml Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update vendor/assets/javascripts/local-time.js Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update vendor/assets/javascripts/local-time.js Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update vendor/assets/javascripts/local-time.js Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> * Update saml_idp with better logic for matching_cert (#5220) * Bring back a default cert, to fix NoMethodErrors on nil (#5224) * Add regression spec for NoMethodError * Remove .erdconfig (#5226) **Why**: We removed the ERD in #4960 * Update APP_NAME in application.rb. * Revert Gemfile.lock. * Update config/locales/idv/fr.yml Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com> * Update Gemfile Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com> * Run `make normalize_yaml` * Update spec that used lowercase login to use uppercase Co-authored-by: Andrew Duthie <andrew.duthie@gsa.gov> Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com> Co-authored-by: Jonathan Hooper <jonathan.hooper@gsa.gov> Co-authored-by: Zach Margolis <zachary.margolis@gsa.gov>
Why:
What:
Visual:
