feat(web): introduce FabledSword design system tokens + Tailwind aliases

Add the canonical FS token palette (surfaces, text, action, semantic,
accent, radii, fonts) as CSS custom properties under web/src/lib/styles/
fabledsword-tokens.css, with a [data-fs-app="minstrel"] hook reserved
for future per-app accent overrides. Wire the tokens through Tailwind by
aliasing semantic colour utilities (bg-background, bg-surface,
bg-surface-hover, text-text-primary/secondary/muted, border-border,
bg-action-primary/secondary/destructive, accent, warning/error/info) to
the new variables, plus rounded-sm..xl and font-display/sans/mono. Load
Fraunces, Inter, and JetBrains Mono (400/500 only) via Google Fonts and
default the body to Inter. Existing components inherit the new palette
without per-page changes.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-04-29 18:48:20 -04:00
parent d1c1853d49
commit a7090c3768
4 changed files with 95 additions and 7 deletions
+30 -6
View File
@@ -4,15 +4,39 @@ export default {
theme: {
extend: {
colors: {
background: 'var(--fs-obsidian)',
surface: {
900: '#14161a',
800: '#1a1d22',
700: '#2a2f36'
DEFAULT: 'var(--fs-iron)',
hover: 'var(--fs-slate)'
},
border: {
DEFAULT: 'var(--fs-pewter)'
},
text: {
primary: '#e8ecf2',
secondary: '#cdd3db'
}
primary: 'var(--fs-parchment)',
secondary: 'var(--fs-vellum)',
muted: 'var(--fs-ash)'
},
action: {
primary: 'var(--fs-moss)',
secondary: 'var(--fs-bronze)',
destructive: 'var(--fs-oxblood)'
},
accent: 'var(--fs-accent)',
warning: 'var(--fs-warning)',
error: 'var(--fs-error)',
info: 'var(--fs-info)'
},
borderRadius: {
sm: 'var(--fs-radius-sm)',
md: 'var(--fs-radius-md)',
lg: 'var(--fs-radius-lg)',
xl: 'var(--fs-radius-xl)'
},
fontFamily: {
display: ['Fraunces', 'Georgia', 'serif'],
sans: ['Inter', 'system-ui', 'sans-serif'],
mono: ['JetBrains Mono', 'ui-monospace', 'monospace']
}
}
},