Skip to content

Notification Center

A notification center: a bell with an unread badge that opens a panel of past notifications — the persistent, history side of feedback, the counterpart to the ephemeral Notification toast. It is a pattern, not a component: pure composition of pieces you already have.

  • Button (ghost) + Count — the bell and its unread badge.
  • Sheet Dialog (side="end", roomier via --ds-sheet-dialog-size) — the panel. A lateral sheet, not a popover: a history list wants width, scroll and a footer, and the sheet brings focus trap, Escape / backdrop dismissal and scroll lock. Its headerActions region puts Mark all read and the settings gear on the title row (the gear sits last, next to the close button); its headerLead region holds the back affordance shown in the settings view, on the leading edge before the title. The title swaps between Notifications and Notification Settings.
  • Search (Text Field) and topic filter chips — a Toggle Group (wrap) of check Toggle Buttons: each is a native checkbox and shows a checkmark when selected — at the top.
  • Date sections — Today / Yesterday / This week headers over each group.
  • Rows are Inline Notification in the plain layout with status="neutral" and iconBox="transparent": no surface, no border, no status color — the list stays calm, rows set apart by spacing alone. Each row carries a per-type icon (mapped from the notification’s topic, not its status), the time, and an unread dot you press to mark it read.
  • A settings button (gear) swaps the panel to per-type Switch toggles — turn notification types on or off.

Some centers let you remove a notification instead of tracking read state. Same calm rows, but each has a close (✕) to delete and the header clears all:

Pick one model, not both: mark-read (nothing is deleted; the dot tracks state) suits an audit-style history; deletable (dismiss when handled) suits a work queue.

Two ways to narrow by topic:

  • Chips (shown above) — multi-select toggles that filter the list in place. Compact; good for combining topics and pairing with search.
  • Tabs — one view per type, each tab carrying its own unread count (Tabs supports item.count). Clearer separation, but one type at a time. Prefer tabs when the types are few and rarely combined. (Rich per-tab lists need the Tabs panel to hold components — a snippet-based panel is the planned enabler; until then the chips model is the composable one.)
  • Fixed by the pieces: dialog + keyboard/focus (Sheet Dialog), the badge and its accessible name (Count), each row’s live region and icon (Inline Notification), the settings toggles (Switch).
  • Owned by the application: the list and its persistence, what “unread” means, topic taxonomy, grouping/pagination, and the data source.
  • The bell is a button; the unread Count has an accessible name ("3 unread notifications") — not conveyed by number/color alone.
  • The panel is the Sheet Dialog’s modal role="dialog" — focus moves in, is trapped, and returns to the bell on close.
  • Rows use no color to carry meaning: read state is a dot (present when unread, gone once read — the row itself never changes), type is an icon + text — never color alone.