Feedback
Dialog
A dialog stops the person with one question that needs an answer before they go on, such as skipping an item or deleting a file.
In kanso-ui as Dialog
Anatomy
- Scrim (
k-scrim) over the page. - Container (
k-dialog):surface,radius-3xl,shadow-3,space-2xlpadding, up to 400 px wide. - Title (
k-dialog__title): the question, in the voice face. - Body (
k-dialog__body): what will happen, and whether it can be undone. - Actions (
k-dialog__actions): Cancel first, the confirming action last, at the end of the row.
Tokens used
| Design token | In kanso-ui | Light | Dark |
|---|---|---|---|
surface | --kui-color-kanso-surface | #ffffff | #1c1c1c |
ink | --kui-color-ink | #1a1a1a | #ececec |
ink-muted | --kui-color-ink-muted | #5c5c5c | #b3b3b3 |
accent | --kui-color-accent | #1a1a1a | #ececec |
on-ink | --kui-color-on-ink | #fafafa | #121212 |
critical | --kui-color-critical | #b3261e | #f2b8b5 |
on-critical | --kui-color-on-critical | #ffffff | #601410 |
scrim | --kui-color-scrim | rgba(0, 0, 0, 0.4) | rgba(0, 0, 0, 0.6) |
shadow-3 | --kui-shadow-kanso-3 | 0px 8px 24px 0px rgba(0, 0, 0, 0.12), 0px 24px 56px 0px rgba(0, 0, 0, 0.14) | 0px 12px 40px 0px rgba(0, 0, 0, 0.7) |
radius-3xl | --kui-radius-kanso-3xl | 28px | 28px |
space-2xl | --kui-spacing-kanso-2xl | 24px | 24px |
space-lg | --kui-spacing-kanso-lg | 16px | 16px |
space-sm | --kui-spacing-kanso-sm | 8px | 8px |
font-voice | --kui-typography-font-family-voice | 'Roboto Serif', 'Iowan Old Style', Georgia, serif | 'Roboto Serif', 'Iowan Old Style', Georgia, serif |