Segmented
A single-select linear segmented control for light filtering / view switching, role="radiogroup", with per-item disabling.
Basic usage
Basic usage
Default selection
Controlled value
Disabled items
Disabled options
Switch event
oas-change event
API
Attributes
| Attribute | Description | Type | Default |
|---|---|---|---|
options | [{ label, value, disabled? }] JSON string | string | [] |
value | Selected value (defaults to the first option; controlled) | string | — |
Events
| Event | Description |
|---|---|
oas-change | Switched, detail: { value } |
The container is role="radiogroup"; each item is role="radio" + aria-checked / aria-disabled.