Back to Components

Navigation

SegmentedControl

Radio group rendered as connected buttons sharing one rounded chassis. For binary or ternary mode toggles.

Examples

Two options

Selected: list
<SegmentedControl
  options={[
    {value: 'list', label: 'List'},
    {value: 'card', label: 'Cards'},
  ]}
  bind:value
  ariaLabel="Layout"
/>

Props

PropTypeDefaultDescription
options{value, label, icon?, disabled?}[]Option definitions.
valueTBindable selected value.
onChange(next: T) => voidOptional change callback.
size'sm' | 'md''md'Height tier.
ariaLabelstringAccessible label for the radiogroup.

Install

CLI

npx @a3tai/mittsu add segmented-control