veza/packages/design-system/tokens/primitive/typography.json
senke a25ad2e0b4 feat(design-system): introduce Style Dictionary (W3C tokens) — Sprint 2 foundation
Set up token build pipeline to kill the drift between apps/web/src/index.css,
packages/design-system/src/tokens/colors.ts, and packages/design-system/README.md
(three contradictory palettes coexisting at v2/v3/v4).

New: packages/design-system/tokens/ — single source of truth (W3C token spec)
- primitive/color.json — ink/washi/void/mizu/kin/viz/functional/alpha
- primitive/typography.json — Space Grotesk + Inter + JetBrains Mono scales
- primitive/spacing.json — strict 4px scale + radius + z-index
- primitive/motion.json — durations (goutte/trait/lavis/vague/maree) + easings
- primitive/elevation.json — shadows + blur + opacity (ink wash)
- semantic/dark.json — dark theme refs (default :root)
- semantic/light.json — light theme refs (washi paper)

Outputs (gitignored, regenerated via npm run build:tokens):
- dist/tokens.css (unified primitive + dark + light)
- dist/tokens-{primitive,dark,light}.css (split)
- dist/tokens.ts + tokens.d.ts (TS exports)

Palette content = Option B (cyan unique UI + 4 pigments data viz only).
Aligned with CHARTE_GRAPHIQUE_TALAS.md section 4 (canonical brand source).

Migration of apps/web/src/index.css and components hardcoding hex pigments
follows in subsequent commits.

SKIP_TESTS=1 used because pre-commit unit tests fail on a pre-existing
LazyDmca mock issue unrelated to this commit's scope (packages/design-system).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-27 04:52:15 +02:00

42 lines
2.2 KiB
JSON

{
"font": {
"family": {
"heading": { "$value": "'Space Grotesk', system-ui, sans-serif", "$type": "fontFamily", "$description": "Titres — MAJUSCULES, letter-spacing 0.10-0.15em" },
"body": { "$value": "'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif", "$type": "fontFamily" },
"mono": { "$value": "'JetBrains Mono', 'SF Mono', 'Consolas', monospace", "$type": "fontFamily", "$description": "Code et specs techniques uniquement" }
},
"weight": {
"regular": { "$value": 400, "$type": "fontWeight" },
"medium": { "$value": 500, "$type": "fontWeight" },
"semibold": { "$value": 600, "$type": "fontWeight" },
"bold": { "$value": 700, "$type": "fontWeight" }
},
"size": {
"xs": { "$value": "0.75rem", "$type": "dimension" },
"sm": { "$value": "0.8125rem", "$type": "dimension" },
"base": { "$value": "0.875rem", "$type": "dimension" },
"md": { "$value": "1rem", "$type": "dimension" },
"lg": { "$value": "1.125rem", "$type": "dimension" },
"xl": { "$value": "1.25rem", "$type": "dimension" },
"2xl": { "$value": "1.5rem", "$type": "dimension" },
"3xl": { "$value": "1.875rem", "$type": "dimension" },
"4xl": { "$value": "2.25rem", "$type": "dimension" }
},
"leading": {
"none": { "$value": "1", "$type": "number" },
"tight": { "$value": "1.25", "$type": "number" },
"snug": { "$value": "1.375", "$type": "number" },
"normal": { "$value": "1.5", "$type": "number" },
"relaxed": { "$value": "1.625", "$type": "number" },
"loose": { "$value": "1.7", "$type": "number", "$description": "Corps de texte — interligne charte" }
},
"tracking": {
"tight": { "$value": "-0.02em", "$type": "dimension" },
"normal": { "$value": "0", "$type": "dimension" },
"wide": { "$value": "0.08em", "$type": "dimension" },
"wider": { "$value": "0.10em", "$type": "dimension", "$description": "H3 charte" },
"widest": { "$value": "0.12em", "$type": "dimension", "$description": "H2 charte" },
"huge": { "$value": "0.15em", "$type": "dimension", "$description": "H1 charte" }
}
}
}