Skip to content

fix(authenticator): Add accessible names for password toggle and form errors - #7229

Closed
VarshithaPamisetty wants to merge 2 commits into
aws-amplify:mainfrom
VarshithaPamisetty:bug/authenticator-form-field-accessible-names
Closed

fix(authenticator): Add accessible names for password toggle and form errors#7229
VarshithaPamisetty wants to merge 2 commits into
aws-amplify:mainfrom
VarshithaPamisetty:bug/authenticator-form-field-accessible-names

Conversation

@VarshithaPamisetty

@VarshithaPamisetty VarshithaPamisetty commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Issue #, if available:
Fixes #6568
Fixes #6581

Description:
Continues the work in #6577 by @ekjotmultani, addressing the review feedback.

Adds tooltip/accessible names to the password visibility toggle so screen readers announce "Show password"/"Hide password" (#6568), and wraps banner and form content in semantics so validation errors are announced (#6581).

Review follow-ups from #6577:

  • Tooltip strings are defined in the ARB source (inputs_en.arb) and reflected in the generated localizations.
  • A blank helperText is set on the input fields as a workaround for [a11y] VoiceOver does not announce form validation errors flutter/flutter#99715 so validation errors are announced on web; this adds a consistent helper line under every field, which the updated golden snapshots reflect.
  • Golden snapshots updated for the new form-field layout.

Tests

  • Added widget tests for the password toggle accessible name (Show/Hide) and the banner/snackbar live-region announcements.
  • Full authenticator suite passes locally; dart analyze and dart format clean.
  • Manually verified with VoiceOver on web (Chrome): the toggle announces "Show password" / "Hide password", and submitting an empty form auto-announces the validation error via the live-region.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

… errors

Adds tooltip/accessible names to the password visibility toggle so screen
readers announce "Show password"/"Hide password", and wraps banner and form
content in semantics so validation errors are announced. Tooltip strings are
defined in the inputs ARB source (inputs_en.arb) and reflected in the
generated localizations.

Continues the work in aws-amplify#6577 by @ekjotmultani.

Issues:
aws-amplify#6568
aws-amplify#6581
@VarshithaPamisetty
VarshithaPamisetty requested a review from a team as a code owner August 4, 2026 12:11
@VarshithaPamisetty

VarshithaPamisetty commented Aug 4, 2026

Copy link
Copy Markdown
Contributor Author

@ekjotmultani @cadivus this continues #6577 with the review fixes. Could you review and approve the CI run when you get a chance? Thanks!

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 86.20690% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 41.24%. Comparing base (7c5ffa8) to head (011304b).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7229      +/-   ##
==========================================
+ Coverage   40.97%   41.24%   +0.26%     
==========================================
  Files         121      121              
  Lines        8273     8288      +15     
  Branches     3598     3604       +6     
==========================================
+ Hits         3390     3418      +28     
+ Misses       4883     4870      -13     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment on lines +207 to +209
// Workaround for Flutter issue where validation errors are not
// announced by screen readers on web unless helperText is set.
// See: https://github.com/flutter/flutter/issues/99715

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like that you reference the issue that leads to such a "weird" workaround.

@VarshithaPamisetty

Copy link
Copy Markdown
Contributor Author

Superseded by #7254, reopened from an upstream branch so CI runs without the fork-secret issues. Continuing there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

3 participants