Notification list
import { NotificationList, notificationCounts, notificationSummary } from "@arcadia/ui";- Ship the release tonight, or wait for review? Review closes at 18:00
NotificationList
itemsrequired- readonly NotificationItem[]
- The notifications, in the order each group holds them.
labels- Partial<Record<NotificationWeight, string>>
- Group names by weight. Defaults: Needs you, For you, While you were away.
groupActions- Partial<Record<NotificationWeight, ReactNode>>
- One control at a group's heading, by weight (a Mark all read).
filters- boolean
- The filter row: true always, false never, left out it stands when more than one group holds something.
filterLabels- Partial<Record<NotificationFilter, string>>
- Filter names. Defaults: All, Needs you, For you, Away.
filter- NotificationFilter
- The chosen filter, controlled.
projects- readonly NotificationProject[]
- Default:
[] projectFilter- string
onProjectFilterChange- (project: string) => void
defaultFilter- NotificationFilter
- Default:
"all" - Its first value when uncontrolled.
onFilterChange- (filter: NotificationFilter) => void
- A filter pressed.
now- number
- The time the ages are read from, epoch ms. Default the shared clock, ticked each minute. A running state's clock always counts up live from its
since. loading- boolean
- Default:
false - The first page is on its way: skeleton rows and aria-busy.
empty- ReactNode
- Default:
"Nothing needs you" - What stands when there are no notifications. Default Nothing needs you.
onDone- (item: NotificationItem) => void
- The row's Done was pressed. Without it no Done control stands.
onReadChange- (item: NotificationItem, unread: boolean) => void
- Mark as read or unread was pressed. Without it the row has no menu.
onMute- (item: NotificationItem) => void
- Mute was pressed.
onTurnOff- (item: NotificationItem) => void
- Turn off was pressed.
group- "weight" | "owner"
- Default:
"weight" - How the rows group.
weight: Needs you, For you and While you were away, with filters.owner: the work list of Needs you, a heading that counts what is working and what is to check, then one group per actor under its picture, its rows without a read state, each with its state, progress, evidence, check and the choice made for the person, in the order given. fold- number
- Default:
4 - The rows an owner's group shows before Show N more folds the rest.
heading- string
- Default:
"Work" - The owner list's heading.
onCheck- (item: NotificationItem, verdict: NotificationVerdict) => void
- Looks good or Not right pressed on a row ready to check. Without it a check row draws no buttons.
rootStyle- RootStyle
- Typed StyleX override: where the list sits.
Rest props go to <section> props.
State machine
- Review the deploy 2m The preview is ready.