-
-
Notifications
You must be signed in to change notification settings - Fork 53
Description
Labels: tests, a11y, component:RadioGroup, priority:medium
Summary
Ensure RadioGroup supports roving focus, controlled/uncontrolled selection, form submission, and data-state attributes.
Acceptance Criteria
Arrow keys move focus and selection; Home/End jump to first/last.
Controlled value prop syncs with onValueChange; defaultValue works.
form submit includes selected value; disabled radios skip focus.
data-state="checked|unchecked"; data-disabled set when disabled.
AXE: no violations; role="radiogroup"/"radio".
asChild radios preserve semantics/refs.
Test Plan (Implementation Notes)
Framework: Jest + React Testing Library
Files: src/components/ui/RadioGroup/tests/RadioGroup.behavior.test.tsx
Helpers: user-event
Edge cases: no default selection, nested groups, RTL
Coverage Targets: ≥80% branch.
Out of Scope
Visual layouts.
Risk
medium – roving focus.
Effort
M
References
src/components/ui/RadioGroup/RadioGroup.tsx
src/components/ui/RadioGroup/tests/RadioGroup.test.tsx
WAI-ARIA radiogroup pattern