Block 283 of 297
Constellation Network
Partner or community section beside a live network of drifting nodes that link up and brighten under the pointer.
- Puck key
- ConstellationNetworkBlock
- Export
- constellationNetworkBlock
- React component
- <ConstellationNetwork />
- Files
- components/puck/constellation-network-block.tsx
- components/puck/constellation-network.client.tsx
- Dependencies
- vgpu
- 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 two-column partner section: heading, body and a link on one side, a rounded panel of drifting nodes that connect as they pass on the other. One large stat sits at the bottom of the panel over a dark gradient. Nodes near the mouse brighten. On phones the panel stacks below the copy in a taller 4:5 shape.
- Coalition or partner network pages
- Community collaborative or collective impact overviews
- A "who we work with" section with a single headline count
Writing the content
- Stat number and Stat label work as a pair, such as "140+" and "partner organizations"; the number can be bound to a P1 data source with {{ }}.
- Use Stat note for the source or date of the count; it hides when blank.
- Keep Night color dark, since the stat text is white. Highlight color should stand apart from Node color so pointer movement is visible.
- Density sets how many nodes fill the panel.
Accessibility
- The stat is server-rendered text on a dark gradient, so it reads the same with or without the animation.
- The node canvas is aria-hidden. Reduced motion draws one still frame and turns off pointer tracking.
- The link has a 44px minimum height and a focus outline; touch input doesn't move the highlight, so nothing depends on hover.
Customizing the code
- Requires vgpu and constellation-network.client.tsx. The 0.3 wander radius in nodeAt() and the link length limit work together, so change them carefully to avoid lines clipping at cell borders.
- The eyebrow and link use Tailwind indigo-700; the panel shape is aspect-4/5 sm:aspect-4/3.
Editor fields
What content editors see in the P1 sidebar when they select this block.
- Eyebrowtext
- Headingtextarea
- Heading levelselect
- Bodytextarea
- Stat numbertext
- Stat labeltext
- Stat notetext
- Link texttext
- Linktext
- Night colortext
- Node colortext
- Highlight colortext
- Densityradio
- Motionradio