RadioGroup accessibility
WCAG 2.1 AA — release blocker
Semantics
- Root renders as
<fieldset>withrole="radiogroup"so screen readers announce the group boundary. - Each
RadioGroupItemusesrole="radio"witharia-checkedto indicate selection state. - Only one item can be
aria-checked="true"at a time.
Keyboard navigation
- Tab moves focus into/out of the group (focuses the selected item, or the first item if none selected).
- Arrow keys move between items and select the focused item.
- Items are wrapped in a single tab stop — only the selected item is in the tab order.
Labelling
- Pair with a
<legend>inside the fieldset or aLabelcomponent to provide a group-level accessible name. - Each
RadioGroupItemchild text serves as the accessible label for that option.
Disabled state
disabledon the group disables all items and setsaria-disabledon each.- Individual items can also be disabled independently.
Audit checklist
- Screen reader announces group name and option count.
- Arrow keys cycle through options and select them.
- Tab moves focus in/out of the group as a single tab stop.
- Disabled items cannot be selected via keyboard or pointer.
- Focus ring is visible on the focused item (4.5:1 contrast).