Radio — dir/ui
A group of mutually exclusive options with keyboard navigation.
# Radio
A group of mutually exclusive options with keyboard navigation.
## Install
```sh
npx shadcn@4.21.0 add lr-run/dir-ui/radio#v0.1.2
```
[Registry item with source and dependencies](https://github.com/lr-run/dir-ui/blob/v0.1.2/registry.json)
Requires React 19, Tailwind CSS 4 and shadcn initialized with Base UI. Registry target placeholders resolve through components.json: @ui, @components, @hooks and @lib. Imports below use the conventional @/ prefix for illustration; the CLI rewrites them to your configured aliases. Shared components are installed once through registryDependencies. Theme CSS is imported by the UI modules. Existing files are never forcibly overwritten; review CLI conflicts before accepting changes. No Dir runtime is required.
The registry item installs Base UI and shared theme styles. Compose RadioGroup and Radio.Root directly.
## Radio
```tsx
import { Radio } from '@base-ui/react/radio'
```
| Prop | Type | Default / required | Notes |
| --- | --- | --- | --- |
| RadioGroup.value / defaultValue | unknown | — | |
| RadioGroup.onValueChange | (value, details) => void | — | |
| RadioGroup.name | string | — | |
| RadioGroup.disabled / required | boolean | false | |
| Radio.Root.value | unknown | Required | |
| Radio.Root.disabled | boolean | false | |
| Radio.Root.className / Radio.Indicator.className | string | — | |
```ts
import { RadioGroup } from '@base-ui/react/radio-group'
// RadioGroup > Radio.Root > Radio.Indicator
```