import { RadiantElement } from '@ecopages/radiant'; import type { EventEmitter } from '@ecopages/radiant/tools/event-emitter'; export type RuiRadioGroupProps = { /** Currently selected value. Reflects to markup. */ value?: string; /** Form field name shared by all radios in the group. */ name?: string; /** Accessible name for the group when no visible legend is slotted. */ label?: string; /** Disable every radio in the group. Default: `false`. */ disabled?: boolean; }; export type RuiRadioGroupChangeDetail = { value: string; }; /** * `` — a set of radio buttons where only one option may * be selected at a time. * * Implements the WAI-ARIA APG Radio Group pattern using native * `` controls inside a `role="radiogroup"` container. * Arrow-key navigation and Space activation are provided by the browser. * * @see https://www.w3.org/WAI/ARIA/apg/patterns/radio/ * * Keyboard interaction (native radio group): * - `Tab` / `Shift+Tab`: move focus into and out of the group * - `Arrow` keys: move selection between radios * - `Space`: check the focused radio * * @element rui-radio-group * * @attr {string} value - Selected radio value. Reflects to markup. Default: `''`. * @attr {string} name - Form field name shared by all radios in the group. Default: `''`. * @attr {string} label - Accessible name when no visible legend is slotted. Default: `''`. * @attr {boolean} disabled - Disables every radio in the group. Default: `false`. * * @slot - One or more `