Skip to content

Accessibility audit: keyboard, screen-reader, reduced-motion (CI fixes)#880

Open
Timrossid wants to merge 24 commits into
Stellar-Mail:mainfrom
Timrossid:fix/a11y-ci
Open

Accessibility audit: keyboard, screen-reader, reduced-motion (CI fixes)#880
Timrossid wants to merge 24 commits into
Stellar-Mail:mainfrom
Timrossid:fix/a11y-ci

Conversation

@Timrossid

Copy link
Copy Markdown

Why this matters

Security controls that are inaccessible create both exclusion and operational risk.

Scope

This PR addresses audit findings across: focus order, dialog trapping, semantic names, live regions, contrast, keyboard shortcuts, reduced motion, and error messaging.

Changes

Focus Management

  • Created reusable useFocusTrap hook providing focus trapping and restoration for all custom dialogs
  • Applied focus traps to: ShortcutOverlay, CommandPalette, ProofInspectorModal, SenderConversionDialog, SnoozeDialog, SettingsModal, Compose
  • Focus now restores to trigger element when overlays close

Keyboard Complete

  • Added aria-current="page" to sidebar navigation items
  • Added aria-label to icon-only buttons in EmailView (Snooze, Archive, Trash, Star)
  • Added Escape key handlers to Topbar filter/help/account dropdowns
  • Added data-shortcuts-disabled attribute support for WCAG 2.1.4 single-key shortcut compliance

ARIA & Semantic Names

  • Fixed invalid role="listbox" on EmailList (changed to role="list")
  • Added role="dialog", aria-modal="true", aria-label to SettingsModal, Compose, and provenance modal
  • Added role="menu" and role="menuitem" to Topbar account dropdown
  • Added aria-label to sidebar <nav> landmark and collapsed folder buttons
  • Added aria-labelledby linking to ShortcutOverlay and ProofInspectorModal headings

Live Regions

  • Added aria-live="polite" and aria-live="assertive" containers in root layout
  • Added aria-live="polite" wrapping proof inspector search results

Automated Checks (CI)

  • Added eslint-plugin-jsx-a11y with recommended rules to ESLint config
  • Added @axe-core/playwright for automated accessibility testing in CI
  • Created accessibility E2E spec checking main mail view, compose dialog, settings modal, and keyboard shortcuts modal for critical/serious violations

Reduced Motion

  • @media (prefers-reduced-motion: reduce) respected throughout

CI Fixes Included

  • Fixed prettier syntax error in Sidebar.tsx (unclosed nav element)
  • Fixed undefined hasUnread reference in SettingsModal (added useChangelog hook call)

Acceptance Criteria

  • Primary flows are keyboard complete
  • Focus restores after overlays
  • Proof and transaction changes are announced
  • Automated accessibility checks run in CI

Closes #72

Timrossid and others added 12 commits June 17, 2026 19:02
…CI checks

- Add useFocusTrap hook for focus trapping and restoration across all dialogs
- Add jsx-a11y ESLint plugin and axe-core Playwright for CI checks
- Fix primary flows keyboard completeness (arrow nav, escape handlers)
- Fix focus restoration after overlays close (ShortcutOverlay, CommandPalette,
  ProofInspectorModal, SenderConversionDialog, SnoozeDialog, SettingsModal, Compose)
- Add live region announcements (aria-live) for proof inspector and app root
- Fix ARIA roles: dialog attributes on SettingsModal, Compose, provenance modal
- Fix EmailList invalid listbox role (changed to list)
- Add aria-labels to icon-only buttons in EmailView, Sidebar collapsed state
- Add aria-current to sidebar navigation, aria-label to nav landmarks
- Add Escape key handlers to Topbar dropdown menus
- Add data-shortcuts-disabled attribute support for WCAG 2.1.4 compliance
- Add screen-reader live regions to root layout for status/alert announcements
- Add accessibility E2E spec with axe-core violation checks
- Fix prettier syntax error in Sidebar.tsx (removed duplicate nested <nav>)
- Fix undefined hasUnread reference in SettingsModal (added useChangelog hook call)
@kryputh

kryputh commented Jun 19, 2026

Copy link
Copy Markdown
Collaborator

@Timrossid Kindly Fix CL and COnflict

Conflict can be fixed via web editor

Timrossid and others added 12 commits June 19, 2026 14:00
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…aths

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…instead

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…cal vitest config used for CI debugging

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Timrossid <timothyegwuda@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

client: complete keyboard, screen-reader, and reduced-motion accessibility

2 participants