Skip to main content

Radio

Interactive

See Radio in Storybook for every variant, with live controls.

One choice from a small set of mutually exclusive options. Above about five options, use Select.

import { Radio } from "@kairosis/eidos";

{
options.map((option) => (
<Radio
key={option.value}
name="trigger"
value={option.value}
label={option.label}
checked={value === option.value}
onChange={setValue}
/>
));
}

Props

PropTypeDefaultDescription
checkedbooleanRequired. Controlled
onChange(value: string) => voidReceives this radio's value
labelReactNode
namestringGroups radios together
valuestringThis option's value
disabledbooleanfalse

Forwards a ref to the underlying <input type="radio">.

Guidelines

  • Give every radio in a group the same name — that's what makes arrow keys move between them.
  • onChange receives the radio's value, so a group needs no per-option handler.
  • Radio is a single option, not the group: render one per choice and hold the selected value yourself.