---
title: Accessibility & Inclusive UX
summary: WCAG 2.1 Level AA target, four-layer accessibility defense, streaming AI chat announcements, and barrier reporting governance.
owners:
  - catalog-experience-team
badges:
  - content: Architecture
    backgroundColor: purple
    textColor: purple
  - content: Reference
    backgroundColor: blue
    textColor: blue
---

## Purpose & Scope

This reference defines BookWorm's accessibility architecture across **Storefront**, **Commerce**, and **Backoffice**, targeting **WCAG 2.1 Level AA**. Because automated scanners detect only a fraction of real-world barriers—particularly around keyboard focus management and streaming AI responses—BookWorm enforces a four-layer defense from authoring time through runtime assistive-technology behavior.

## Four-Layer Accessibility Defense

The visual below illustrates how static linting, browser audits, keyboard focus management, and paced live announcements reinforce each other across development and runtime.

<MermaidFileLoader file="mermaids/008-accessibility-principles-diagram-1.mmd" />

## Architectural Principles & Rules

- **Full keyboard operability:** Every interactive workflow—including catalog filtering, modal dialogs, and end-to-end checkout across **Storefront** and **Commerce**—must be operable without a mouse, with a visible skip-to-main-content link and predictable focus order.
- **Focus trapping & restoration:** Modal dialogs, drawers, and popovers must trap focus while open, dismiss on `Escape`, and restore focus to the triggering control upon closure.
- **Semantic landmarks & headings:** Every page must expose proper landmark regions (`main`, `navigation`, `contentinfo`), a single top-level heading, and non-skipped heading levels.
- **Non-color cues & contrast:** Text and interactive borders must meet WCAG 2.1 Level AA contrast ratios (4.5:1 normal text, 3:1 large text and UI components), and status or validation errors must never rely on color alone.
- **Paced live announcements:** Dynamic status updates (offline notices, rate-limit alerts, basket updates, and **Storefront**'s streaming AI assistant) must announce through `aria-live` regions without flooding screen readers during token streaming.

<Admonition type="info" title="Streaming AI Accessibility">
	Unthrottled conversational AI token streams can overwhelm screen readers. **Storefront**
	integrates generative accessibility adapters with the AG-UI stream so assistant responses, tool
	calls, and interactive cards announce at a readable pace.
</Admonition>

## Patterns & Boundaries

| Concern / Surface                     | Architectural Approach                                                                  | Responsibility Boundary                                                                 | Key Trade-off                                                                         |
| :------------------------------------ | :-------------------------------------------------------------------------------------- | :-------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------ |
| **Layer 1: Primitives & Static Lint** | Headless accessible UI primitives paired with zero-warning static accessibility linting | Shared UI and lint config enforce baseline ARIA and semantic rules at authoring time    | Cannot detect runtime contrast, focus traps, or screen-reader pacing                  |
| **Layer 2: Browser Audits**           | Automated `axe-core` contrast and landmark checks inside end-to-end browser suites      | **Storefront** suite verifies customer discovery and **Commerce** checkout journeys     | Requires running browser stack; **Backoffice** relies on static lint and unit queries |
| **Layer 3: Keyboard & Focus**         | Skip links, logical tab order, focus traps, and `Escape` restoration                    | Shared UI primitives provide focus mechanics; feature slices verify page-level tab flow | Requires manual keyboard verification on complex custom layouts                       |
| **Layer 4: Live Announcements**       | `aria-live` regions and generative accessibility adapters for AI streams                | Feature slices own status regions; **Storefront** AI integration owns stream pacing     | Adds integration surface tied to conversational UI events                             |

<Accordion title="Barrier Reporting & Security Boundary">

- **Supported Environments:** Modern desktop and mobile browsers, keyboard-only navigation, and standard screen-reader workflows.
- **Barrier Reporting:** Accessibility barriers are tracked via dedicated issue templates capturing affected surface, reproduction steps, assistive technology, and severity.
- **Security Boundary:** Contributors and users must never include passwords, tokens, or private data in public accessibility reports.

</Accordion>

## Quality & Operational Impact

- **Inclusivity:** Keyboard-only and screen-reader users can complete discovery, AI-assisted search, basket management, and checkout independently.
- **Early Defect Prevention:** Catching missing labels and invalid ARIA at lint time is significantly faster and cheaper than fixing them after UI release.
- **AI Usability:** Paced live announcements make conversational AI genuinely usable for assistive-technology users rather than noisy or disorienting.
