Skip to content

Block 149 of 297

Service Status

City services status board with last-updated time, affected count, and status as icon plus text.

Puck key
ServiceStatusBlock
Export
serviceStatusBlock
React component
<ServiceStatus />
Path
components/puck/service-status-block.tsx
Dependencies
None
License
MIT

About this block

When to use it, how to write for it, and what to change in the code.

What it's for

A service status board for city operations such as trash, water, transit and facilities. A summary bar counts how many services are not running normally and takes its tone from the worst status listed, and each row shows the service, a note and a status pill. It stays one narrow column at every width, with pills dropping below names on phones.

  • A city home page panel during storms or holiday schedule changes
  • A public works or utilities page with ongoing service notices
  • An emergency information page listing closures
Writing the content
  • Change Last updated every time you edit a status. Readers rely on it to judge whether the board is current.
  • Use Details to say what is happening and what people should do; leave it blank when service is Normal.
  • The summary line is calculated for you, such as "2 of 6 services are affected", so you only set each Status.
  • Point the Alerts link at your text or email sign-up. The board holds up to 20 services.
Accessibility
  • Every status pill shows an icon and a word (Normal, Delayed, Disrupted, Closed) and adds hidden "Status:" text, so status never depends on color alone (WCAG 1.4.1).
  • The summary is written as a sentence, and the section is labelled by its heading, with service names as headings one level below it.
  • The board is static: changes appear when the page is republished, not announced live to screen readers.
Customizing the code
  • Status labels, pill colors and icons are set in the statuses map; summary bar colors are in summaryTone.

Editor fields

What content editors see in the P1 sidebar when they select this block.

  • Headingtext
  • Heading levelselect
  • Introtextarea
  • Last updatedtext
  • Servicesarray
  • Alerts link texttext
  • Alerts linktext