One source of truth, from Figma to npm.
Pance is an open-source design system for social-impact and data-heavy products. I took it from a generated docs site to a tested, versioned system with a Figma library, React components and tokens on npm.
01 Try it
Change the brand. Nothing else.
These are the published @pance/react components. Pick a ramp and one attribute re-points every token that aliases it, in light and dark.
<div class="brand-scope">Shown on the public dashboard.
Households reached
3,204
vs previous period
Same components, same code
Only the ramp behind the tokens changed. Contrast still passes: solid fills use step 700.
Tip: switch the site to light mode from the top bar — the same components follow.
02 The problem
It looked finished. It wasn’t a system yet.
Pance began as a documentation site generated with Figma Make. The pages were polished, but the components didn’t read from tokens, the docs and the code disagreed, and some of what looked right was failing accessibility in ways you can’t see.
So before building anything new, I extracted it into a repo and wrote an audit: what the docs say, what the code does, and a fix for each gap. Some of what it found:
Warning buttons
2.15 : 1
White text on amber-500. AA needs 4.5 : 1.
Primary buttons
3.68 : 1
White on aqua-600 at 13–16 px semibold — not “large text”, so it fails.
Dialog semantics
None
Modals and drawers had no role, no focus trap, no Escape, no focus return.
Invisible styles
3
Class names built from string pieces that Tailwind never generated. Outlined alerts had no border.
Docs and code also disagreed on the basics: the breakpoint (480 vs. 640 px), the H3 size (18 vs. 20 px), disabled opacity (four different values). Each one became a recorded decision.
03 Architecture
Three tiers, five outputs.
A change starts in one JSON file and reaches design and code in the same pull request.
- Tier 1Primitivesaqua.700 = #0e7490
- Tier 2Semanticintent.primary.solid → aqua.700
- Tier 3Componentsbutton.primary.bg → intent.primary.solid
- CSS variables--pance-color-*, light + dark
- Tailwind v4 themebg-primary-solid, text-ink-muted
- Typed JS objectcharts, canvas, tests
- Figma variables878, Light and Dark modes
- @pance/react45+ components on npm
lint:tokens fails the build otherwise.04 Decisions
Written down, so they last.
Pance keeps a register of design decision records (DDR-DS). A future contributor can read why something is the way it is — and argue with it.
Decision
One source of truth
The token JSON in the repo is canonical. Figma variables are generated from it — never the other way round.
Decision
Solid fills at step 700
Every filled control carries white text at 5 : 1 or better. Aqua stays the brand in outlines, links and focus.
Decision
Severity × variant × size
One model for 45+ components: what it means, how loud it is, how big it is. Fewer props to learn.
Decision
Open, but curated
MIT licensed and open to proposals. Every change that lands — or is declined — is approved by the maintainer.
DDR-DS-018
Leading and trailing icons
Button takes both, so “Download ▾” needs no custom component. Additive, shipped in 1.4.0 with matching Figma properties.
DDR-DS-019
Four gradient tokens, no more
brand, hero, surface-soft and fade — a new token type with light and dark values, contrast-tested at every stop.
05 Quality
Accessibility checked by machines, every push.
Memory and good intentions don’t scale. CI does.
- axe-core
- 20 pages × 2 viewports on every push. 975 violations down to 36, all WCAG-exempt.
- Contrast test
- 202 text and control pairs per mode — 4.5 : 1 for text, 3 : 1 for controls and focus.
- Keyboard & ARIA
- 35 tests: dialog, menu button, combobox, tabs, radio group, tooltip, disclosure.
- lint:tokens
- Blocks hard-coded colours and magic pixel sizes in components.
- Visual regression
- Base commit vs. pull request on the same runner. No committed screenshots.
- Package test
- Installs @pance/react and @pance/tokens in a fresh project and checks they render.
Every interactive control also gets at least a 24 × 24 px target (WCAG 2.5.8) through an invisible hit area, and panels like popovers and date pickers shift to stay inside the viewport.
06 Built for data
Charts and tables are first-class.
Metric cards, line, bar, diverging, heatmap, donut and scatter charts, meters and a data table with expandable rows — each with a table view for screen readers.
Culture stimuli · 2006 — 2026
Where the grants went
Projects
8,214
vs. previous five years
Towns reached
611
vs previous period
Active at 3 yrs
42%
vs previous period
Grants awarded per year
Illustrative data — the real project is in discovery
- Pacific region
- Andean region
Use the arrow keys to move between data points.
Built with Pance
Every element in this frame is a @pance/react component reading @pance/tokens.
07 Shipping
Six releases, no stored secrets.
Published from GitHub Actions with npm trusted publishing and provenance. The docs deploy to GitHub Pages on every push to main.
- 1.1.0First release on npm: tokens and React, ESM, types, precompiled CSS.
- 1.2.0Built-in strings become props with English defaults — translatable, no i18n dependency.
- 1.3.0One mature release: dates, theme, feedback, forms, table features, charts.
- 1.4.0Button trailing icon (DDR-DS-018) and the finished Figma library.
- 1.4.1Fixes only: 24 px pointer targets, panels that stay on screen.
- 1.5.0Gradient tokens (DDR-DS-019) and the docs on their own domain.
- 947Design tokens
- 878Figma variables
- 1,027Figma variants across 88 components
- 71Generated documentation pages
- 70Icons — a curated selection of Phosphor’s 1,000+
08 What’s next
Proof in real products.
- Altazor CRM — the first production app built on Pance, for a creative writing school.
- Screen-reader passes with NVDA and VoiceOver on the dialog, combobox, data table and date picker.
- Figma Code Connect, and dark values for component tokens in Figma.
- This website. It’s built with @pance/react and @pance/tokens plus a thin editorial layer: a display typeface, re-pointed font tokens and a generated brand scope. Press I to see it.