Repository navigation
fix(platform): a11y polish — aria-modal, radiogroup arrows, single preview heading, protected-row checkbox (#1998) - #2203
Conversation
…nd protected rows (#1998) Four accessibility refinements found in the keyboard/AT sweep: - Add `aria-modal="true"` to the modal dialog primitives (platform `Dialog`, `Sheet`, and `@tale/ui` `ResponsiveDialog` desktop dialog + mobile drawer) — Radix does not set it for us in this version. - Lock in arrow-key navigation for the run-code "Default Mode" radiogroup with a real-Chromium regression test. The platform `RadioGroup` already provides roving-tabindex via Radix `RadioGroupPrimitive`; the test guards against a future swap to hand-rolled radios. - Render the document-preview heading once: the visible title is now a styled span, so the dialog's single accessible heading is the visually-hidden `DialogTitle`, instead of exposing "Document preview" twice. - Hide the select-row checkbox on non-selectable rows in the shared select column (`row.getCanSelect()`), removing the false "Select row" affordance on protected agent rows. No user-visible strings, env vars, schema, or config changed — i18n, docs and migrations are N/A. Touches `@tale/ui` (responsive-dialog) alongside platform. Closes #1998
Desk Review — PR #2203 (issue #1998: accessibility polish)Verdict: NOT READY — one blocking gap in item 1 (aria-modal coverage). The four implemented items are well-built, tested, and the CI is fully green — but a prominent modal (the global/chat SearchCommand palette) was left out of the Verification performed
What's correct (verified by reading the surrounding code + node_modules)
BLOCKING
Non-blocking nits (not required for merge)
NOT READY — CHANGES REQUIRED
|
Desk review — #1998 accessibility polishVerdict: READY TO MERGE. Reviewed the full implementation on this branch (head CIAll required checks green on head Tests run locally (all pass)
Findings — all four issue points genuinely resolved
Non-blocking notes (do not block merge)
READY TO MERGE. |
What & why
Resolves the four accessibility refinements from the keyboard/AT sweep in #1998 (none block a task; all WCAG 2.1 AA polish).
1.
aria-modal="true"on modal dialogsRadix does not emit
aria-modalin this version (verified: the dialog content rendered witharia-modal=null). Added it to every modal dialog primitive:Dialog(components/ui/dialog/dialog.tsx)Sheet(components/ui/overlays/sheet.tsx)@tale/uiResponsiveDialog— both the desktop Radix dialog and the mobile vaul drawer content.2. Run-code "Default Mode" radiogroup — arrow-key navigation
The platform
RadioGroupalready delegates to RadixRadioGroupPrimitive, which provides roving-tabindex arrow navigation. Confirmed empirically in real Chromium (a nativeArrowDownkeydown on the focused radio moves selection and firesonValueChange). The reported failure reproduced only withuserEvent.keyboard('{ArrowDown}'), which doesn't drive Radix's RovingFocusGroup under the test runner — a harness artifact, not an app bug. Added a real-Chromium regression test (radio-group.browser.test.tsx) to lock the behaviour in and guard against a future swap to hand-rolled radios.3. Duplicate "Document preview" heading
The Dialog renders a visually-hidden
DialogTitle(an<h2>) for its accessible name; the document-preview custom header also rendered a visible<Heading level={2}>with the same text, so AT exposed the heading twice. The visible title is now a styled<span>, leaving the hiddenDialogTitleas the single heading.4. Fake "Select row" checkbox on protected rows
The shared select column rendered an inert
Checkbox(with a "Select row" label) even on rows gated out by the table'senableRowSelectionpredicate — a false affordance on protected agent rows. The cell now renders nothing whenrow.getCanSelect()is false. Tables without per-row gating are unaffected.Tests
bun run --filter @tale/platform typecheck,lint— green;@tale/ui typecheck,lint— green.aria-modalassertions onDialog+Sheet; newDocumentPreviewDialogtest (heading exposed once); newDataTablerow-selection tests (checkbox only on selectable rows). 208 passed.RadioGrouparrow-key navigation tests + existingform-dialogfocus-trap. All passed.@tale/ui:ResponsiveDialogaria-modalassertions (desktop + mobile drawer). 6 passed.Ripple Map
No user-visible strings, env vars, Convex/knowledge schema, or org-config schema changed — i18n, docs, README, and migrations are N/A. Change spans
@tale/ui(responsive-dialog) alongside the platform app.Closes #1998