Segment-Schalter — component.segmented-control
Umschalter aus verbundenen Segmenten (genau eine Auswahl) — für Ansichts-/Modus-Wechsel; als Formularwert über das name-Feld, Tastatur mit Pfeiltasten
Componentv1.0.0Formulareweb.documentweb.applicationdesktop.shell
Beispiele
Ansichts-Wechsel
Als Formularfeld (hidden input), klein
Eigenschaften
| Prop | Typ | Default |
|---|---|---|
options * | array | — |
value | string | "" |
name | string | "" |
size | string: sm | md | "md" |
Events & Slots
Events: change
Stellschrauben (Komponenten-Tokens)
| Token | Default |
|---|---|
--segmented-control-background | var(--color-surface-sunken) |
--segmented-control-active-background | var(--color-surface-default) |
--segmented-control-border | var(--color-border-subtle) |
Genutzte Design-Tokens
border.hairline color.border.subtle color.surface.default color.surface.sunken color.text.default color.text.muted duration.fast easing.standard elevation.control font.family.default radius.control size.1 size.2 size.3 text.sm text.xs weight.medium