Selection
Radio group
A radio group asks for exactly one choice from two to five options that stay in view, such as when a reminder should go off.
In kanso-ui as RadioGroup
Anatomy
- Legend (
k-group__legend): the question, "Remind me". - Radio: a 20px circle with a 2px
outlinering onsurface. - Dot: 10px of
inkin the chosen radio, whose ring turnsink. - Label: the option, with an optional detail after it in
font-mono, like the time "14:45". - Reason (optional): under a disabled option, saying why.
Measurements
From the design’s stylesheet, each design token with the value kanso-ui gives it in light.
| Class | Property | Value |
|---|---|---|
k-group | border | 0 |
padding | 0 | |
gap | 0 | |
k-group--nested | padding-left | 32px (space-3xl) |
Tokens used
| Design token | In kanso-ui | Light | Dark |
|---|---|---|---|
paper | --kui-color-paper | #fafafa | #121212 |
surface | --kui-color-kanso-surface | #ffffff | #1c1c1c |
ink | --kui-color-ink | #1a1a1a | #ececec |
ink-muted | --kui-color-ink-muted | #5c5c5c | #b3b3b3 |
outline | --kui-color-outline | #8a8a8a | #8c8c8c |
focus-ring | --kui-color-focus-ring | #1a1a1a | #ececec |
size-control-lg | --kui-sizing-kanso-control-lg | 48px | 48px |
space-xs | --kui-spacing-kanso-xs | 4px | 4px |
space-md | --kui-spacing-kanso-md | 12px | 12px |
space-3xl | --kui-spacing-kanso-3xl | 32px | 32px |
state-disabled-content | --kui-state-layer-opacity-kanso-disabled-content | 0.38 | 0.38 |
font-plain | --kui-typography-font-family-plain | 'Roboto Flex', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif | 'Roboto Flex', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif |
font-mono | --kui-typography-font-family-mono | 'Roboto Mono', ui-monospace, 'SF Mono', Menlo, monospace | 'Roboto Mono', ui-monospace, 'SF Mono', Menlo, monospace |