NotificationItem
moleculesOne notification row: tone icon, title, two-line text, relative time, unread dot, up to two actions plus a "…" menu, inline confirm and a pending state; resolved items turn muted with their state label.
Approval with Approve / Reject
Reject sets requiresConfirm and asks inline; onaction returns a promise, so the button stays pending until it settles, then the parent sets state.
Deploy api@4.12.0 to production Unread
The release pipeline is waiting for a second approval before it rolls out to the eu-west and us-east clusters.
Info, resolved and overflow
An info item with href; a resolved item renders its state label and no actions; actions past the second go into the "…" menu.
Nightly backup finished Unread
3.2 GB written to the cold tier in 4 min.
Rotate the deploy token
Approved on phone Disk almost full on build-runner-3 with a very long hostname that has to truncate
98% used.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
title required | string | — | |
text | string | — | |
time required | Date | number | string | — | |
icon | NotificationIcon | — | Kit icon name or a snippet; defaults to a glyph matching `tone`. |
tone | Tone | 'warning' | 'neutral' | |
unread | boolean | false | |
state | string | — | |
actions | NotificationAction[] | [] | |
href | string | — | |
onaction | (id: string) => unknown | — | `onaction` may return a promise; the action stays pending until it settles, or until `state` / `actions` change. |
onopen | () => void | — | |
ondismiss | () => void | — | Shows a dismiss button when set. |
dismissLabel | string | 'Dismiss' | |
moreLabel | string | 'More actions' | |
cancelLabel | string | 'Cancel' | |
unreadLabel | string | 'Unread' | |
as | 'div' | 'li' | 'div' | Mount the item as an `li` inside a list. |
class | string | '' |