Design System

V2 audit — Feedback

Success, warning, error and information, plus the empty and loading states that carry a screen when there is no data yet.

Alert / Callout / Banner

V2

Alert is an inline message tied to a region, Callout is an in-flow advisory block, Banner is a page-level notice.

AlertCalloutBanner

Live component

Two care plans are overdue for review.

Roster published

All 24 staff have been notified.

Handover window

Notes added after 21:00 appear on the next shift's summary.

Legacy mapping

Legacy screens had five differently coloured notice boxes. V2 keeps three, separated by placement, sharing one semantic colour map.

Alert / Callout / Banner — standardized specification
AttributeSpecification
Defaultvariant="info"
Variantsneutral · info · success · warning · error
SizesSingle density; Banner spans the container width
Statesstatic · dismissible · with action
Icon behaviourOne leading status icon per variant at `--size-icon-sm` (Info, CheckCircle2, AlertTriangle, AlertOctagon).
SpacingPadding 16px, gap 12px, action row gap 8px.
TypographyTitle `text-label-md`, body `text-body-sm`.
Border radius`rounded-md`.
Colour usage`*-subtle` surface + `*-subtle-foreground` text; the icon and title state the meaning.
ResponsiveActions wrap below the message under `sm`.

When to use

  • Validation summaries, system notices, contextual advice

When not to use

  • Transient confirmations — use Toast

Accessibility

  • Error alerts use `role="alert"`; non-urgent ones stay in normal reading order.
  • Dismiss controls are labelled.

Toast / Notification

V2

Transient confirmation or failure of a completed action.

ToastProvideruseToastNotification

Live component

Toasts live in the root viewport

Trigger them with useToast(); every toast announces politely and auto-dismisses. The specimen here stays inline so the audit page does not spam the viewport.

Legacy mapping

Legacy toasts appeared in three corners with different durations. V2 has one viewport and one duration scale.

Toast / Notification — standardized specification
AttributeSpecification
Defaultvariant="neutral", auto-dismiss
Variantsneutral · success · warning · error
SizesSingle width, max 400px
Statesentering · visible · with action · dismissed
Icon behaviourStatus icon at `--size-icon-sm`, matching the Alert vocabulary.
SpacingPadding 16px, viewport gap 8px.
TypographyTitle `text-label-md`, body `text-body-sm`.
Border radius`rounded-md`.
Colour usageSoft-glass surface with a semantic status accent.
ResponsiveFull-width at the bottom on mobile, bottom-right on desktop.

When to use

  • "Saved", "Invite sent", "Export failed"

When not to use

  • Errors the person must act on — use inline validation or a dialog

Accessibility

  • Viewport is a labelled `role="region"`; messages are announced politely (assertively on error).
  • Never the only place a failure is reported.

Empty / Error / NoResults states

V2

Carries a region when there is nothing to show, nothing matched, or something failed.

EmptyStateErrorStateNoResultsStateSuccessState

Live component

No residents yet

Add a resident to start building care plans.

No results found

No residents match “sunrise night shift”.

Something went wrong

We could not load the roster. Your connection may have dropped.

Legacy mapping

Legacy screens showed a bare "No data" line. V2 always pairs the explanation with the recovery action.

Empty / Error / NoResults states — standardized specification
AttributeSpecification
DefaultCentred, with icon, title, description and one action
Variantsempty · no results · error · success
Sizescompact (in-card) · full (page region)
Statesstatic · with primary action · with secondary action
Icon behaviourOne illustrative Lucide icon at `--size-icon-xl` in `text-text-tertiary`.
SpacingVertical rhythm 8/12/24px; region padding 48px in full size.
TypographyTitle `text-heading-6`, description `text-body-sm`.
Border radius`rounded-lg` when framed in a card.
Colour usageNeutral surface; only the action carries colour. Error state adds an `error-subtle` icon chip.
ResponsiveCopy width capped at ~48ch; illustration hides under `sm` if space is tight.

When to use

  • First-run, filtered-to-nothing, and failed loads

When not to use

  • While data is still loading — use the loading state

Accessibility

  • Error states are announced; the retry action is a real button.

Loading states

V2

Communicates work in progress: indeterminate (spinner/skeleton) or determinate (progress).

SpinnerSkeletonLoadingStateProgressCircularProgress

Live component

Legacy mapping

Legacy screens blanked the region while loading. V2 preserves layout with skeletons and reserves spinners for actions.

Loading states — standardized specification
AttributeSpecification
DefaultSkeleton for content, Spinner for in-control waits
Variantsskeleton block · skeleton text · spinner · linear progress · circular progress
SizesSpinner xs/sm/md/lg · Progress small/medium
Statesindeterminate · determinate · complete
Icon behaviourSpinner only; no additional icons while loading.
SpacingSkeletons match the rhythm of the content they replace.
TypographySkeleton lines match the line-height they stand in for.
Border radius`rounded-sm` text skeletons, `rounded-md` blocks.
Colour usage`bg-background-muted` shimmer; spinner uses `currentColor`.
ResponsiveSkeletons mirror the responsive layout they replace.

When to use

  • Any wait longer than ~300ms

When not to use

  • Instant local state changes

Accessibility

  • `aria-busy` on the loading region and a polite status message; animation collapses under `prefers-reduced-motion`.