Skip to content

Block 156 of 297

Project Updates

Capital project cards with a four-step phase tracker, latest update, budget and expected completion.

Puck key
ProjectUpdatesBlock
Export
projectUpdatesBlock
React component
<ProjectUpdates />
Path
components/puck/project-updates-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

Capital project cards in a grid, each with an optional photo, a phase badge, a four-step tracker (Planning, Design, Construction, Complete), the latest update and facts for budget and completion. The grid moves from one column to two at medium widths and three on wide screens. Use it to show residents what is being built and how far along it is.

  • A public works page tracking road and utility projects
  • A parks capital plan showing new playgrounds and facilities
  • A bond program page reporting on voter-approved projects
Writing the content
  • Set Phase on every project; it drives both the badge and the tracker, and an unrecognized value falls back to Planning.
  • Keep Latest update to one to three sentences about what residents will notice, like lane closures or open dates.
  • For finished projects, write the opening date in Expected completion; the label switches to "Finished" when Phase is Complete.
  • Image URL is optional and shows at 16:9. Leave Project page link blank and the card will not be clickable.
Accessibility
  • The tracker is an ordered list labeled "Project phase"; the current step carries aria-current="step" and each step adds hidden text such as "(done)" or "(not started)" (WCAG 1.3.1).
  • Phase is always written as a word, with a hidden "Current phase:" prefix, so the colored badges are never the only signal (WCAG 1.4.1).
Customizing the code
  • Badge colors per phase live in the badge map (neutral, indigo, amber, emerald); tracker bar colors are set inline in the steps map.
  • Change md:grid-cols-2 xl:grid-cols-3 on the list to adjust columns, or aspect-[16/9] on the image to change the crop.

Editor fields

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

  • Headingtext
  • Heading levelselect
  • Introtextarea
  • Projectsarray
  • View all link texttext
  • View all linktext