Skip to content

DS-077: Add VisuallyHidden and LiveRegion accessibility primitives #488

Description

@IbrahimIjai

Context

Shared components need consistent utilities for screen-reader-only labels and
non-disruptive status announcements. Ad hoc sr-only markup and live regions
are easy to misuse or duplicate.

Scope

  • Add a VisuallyHidden primitive that can wrap text or semantic elements.
  • Add a LiveRegion with polite, assertive, and off modes.
  • Support atomic announcements and an optional visually rendered fallback.
  • Document appropriate use and cases where visible text is still required.

Acceptance criteria

  • Visually hidden content remains available to assistive technology and focusable when needed.
  • LiveRegion renders the correct ARIA live, atomic, and role attributes.
  • Repeated identical messages can be intentionally re-announced through a documented API.
  • Neither primitive affects surrounding layout.
  • Tests cover semantic attributes, focusable content, modes, and message updates.

Out of scope

  • A global notification queue.
  • Replacing visible labels with hidden labels by default.

Metadata

Metadata

Assignees

Labels

Stellar WaveIssues in the Stellar wave program

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions