Component changelog

RadioGroup changelog

Component-specific release notes collected from the full changelog. This page filters the published entries that mention RadioGroup.

Release

v1.2.1

npm
Patch Changes
  • 8859953: Combobox, Checkbox, CheckboxGroup, RadioGroup, Switch and Field no longer restore their default value when the owning form's reset event is cancelled with preventDefault(). They used to reset anyway, so a page that cancels resets lost the user's selection and submitted the default. The restore now runs after the event has finished dispatching, like a native control, so it also follows the browser's own reset of the form (#2344).

  • cd01923: children is optional in the types of parts that work without it: Checkbox.Root, Switch.Root, Progress.Root, Slider.Root, RadioGroup.Root and RadioGroup.Item, and the triggers of Dialog, AlertDialog, Tooltip, DropdownMenu, ContextMenu and Menubar. A wrapper typed from React.ComponentProps<typeof Checkbox.Root> no longer forces every call site to pass children (#2334).

  • b8cddb8: RadioGroup and RadioCards render their items directly inside the radiogroup element. They used to sit in an extra <div role="group">, so display: grid or flex with gap on the root didn't lay them out, and assistive tech met a group nested inside the radiogroup. The Clarity and Baremetal themes now lay out the root itself. If your own CSS targeted the inner wrapper (.rad-ui-radio-group-root > [role="group"]), move those rules to the root (#2336).

Release

v1.2.0

npm
Minor Changes
  • 07e6783: Add readOnly to Checkbox, Switch and RadioGroup. A read-only control shows its state, stays focusable and in the form, but clicks and Space don't change it; it carries aria-readonly and data-readonly.

  • 07e6783: Add DirectionProvider and useDirection. Wrap an RTL app once with <DirectionProvider dir="rtl"> and every Rad UI component inside uses right-to-left keyboard navigation and positioning: Tabs, TabNav, ToggleGroup, Toolbar, RadioGroup, CheckboxGroup, Accordion, Menubar, menus, NavigationMenu, Splitter, Slider, Select and Combobox. A component's own dir prop still wins. Set dir on <html> as well so text and CSS follow.

  • befc825: Checkbox takes indeterminate, uncheckedValue, form and inputRef; Switch takes uncheckedValue, form and inputRef; RadioGroup takes form and inputRef. Form reset now also works with a form outside the tree. Slider takes thumbCollisionBehavior (none, push, swap), format/locale, largeStep and form; its thumbs take getAriaLabel, getAriaValueText and inputRef. NumberField takes allowOutOfRange, snapOnStep, form and inputRef.

  • ed15256: Add forceMount to Checkbox.Indicator and RadioGroup.Indicator (and the CheckboxGroup primitive content): the indicator stays rendered while unchecked, with data-state="unchecked", so it can animate out or reserve space. The radio indicator now also carries data-state.

  • 07e6783: DropdownMenu, ContextMenu and Menubar gain CheckboxItem, RadioGroup, RadioItem, ItemIndicator, Group and GroupLabel. Checkbox items toggle (checked, defaultChecked, onCheckedChange), radio items pick one value in their group (value, defaultValue, onValueChange), and both keep the menu open unless closeOnClick is set. They expose menuitemcheckbox and menuitemradio with aria-checked, data-state and data-checked, and a GroupLabel names its Group for screen readers.

Patch Changes
  • 07e6783CheckboxGroup and RadioGroup always render their group wrapper. With a single item wrapped in its Label, the group's role and id used to merge onto that <label>, so the checkbox or radio lost its accessible name.

Release

v1.1.0

npm
Patch Changes
  • 9ff88bf: fix(a11y): Command separators and RadioGroup arrow keys

    • Command: Command.Separator is now hidden from assistive technology (aria-hidden, no role="separator"). A separator isn't an allowed child of the listbox it renders inside, so axe reported a critical aria-required-children violation.
    • RadioGroup / RadioCards: all four arrow keys move between options, whatever the orientation, as the WAI-ARIA radio pattern specifies. Radix and Base UI do the same. orientation still sets aria-orientation.

Release

v1.0.0

npm
Patch Changes
  • 903a35dExpose stable RadioGroup anatomy markers through data-slot attributes on root, label, item, and indicator parts.

Release

v0.1.0

npm
Minor Changes
  • b471ddbTests, API improvements across components, Steps + Minimap, roving focus for CheckboxGroup, RadioGroup and Select updates, forwardRef on many primitives, a11y and build fixes.