Using the components
Where the shared components live and how the website uses them.
Every component in the catalog is the website's own code. Components live in packages/ui (@sr/ui) in the
stage-reference repo. The website (web/) imports them, and each catalog entry here renders the same component with
the site's Tailwind styles and theme tokens (packages/ui/src/theme.css). Change a component once and both update.
| Component | Source (packages/ui/src/) | Used on |
|---|---|---|
| SiteHeader, SiteFooter | site-header.tsx, site-footer.tsx | Every page (web/src/app/layout.tsx) |
| PageHero, StatsStrip | page-hero.tsx, stats-strip.tsx | Home |
| LinkCard | link-card.tsx | Home sections, Dancer Resources topics |
| SectionCard | section-card.tsx | City lists, club profile, legal entries, cases |
| ClubCard | club-card.tsx | State pages, club search |
| FieldRow | field-row.tsx | Club profile |
| Chip, PermitChip | chip.tsx, permit-chip.tsx | Club status, legal entries, members markers |
| LockedPanel | locked-panel.tsx | Club profile, legal pages, rights |
| LegalMap | legal-map.tsx | Legal Map |
| Button | button.tsx | Everywhere |
Adding a component
- Add
packages/ui/src/<name>.tsxand export it fromindex.ts. Take aLinkComponentprop for links. - Use it in
web/(the site passesnext/linkthroughweb/src/components/ui.tsx). - Add a catalog entry in
design-system/components/<name>/: a thin wrapper<Name>.tsxand<name>.handoff.tswith previews.
On This Page