9244c91c23
- Replace the design tokens in globals.css with the Living Codex system (parchment light · candlelit dark, gilt accent), keeping every existing --app-*/utility name so nothing breaks. Adds surface-2/panel-2/line-strong/ink-soft/faint/accent-deep/ accent-soft/accent-glow/verdigris + --app-accent-hue (one-number reskin) and paper-grain/gilt-rule/smallcaps helpers. - Self-host the type system via @fontsource (offline-safe, no CDN/CSP change): Spectral (serif headings), Hanken Grotesk (UI), Spline Sans Mono (stats). - Kept: dice/crit animations, print rule, reduced-motion, scrollbars. 223 unit + 34 e2e green; no console errors. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
28 lines
1.0 KiB
TypeScript
28 lines
1.0 KiB
TypeScript
import { StrictMode } from 'react';
|
|
import { createRoot } from 'react-dom/client';
|
|
import { RouterProvider } from '@tanstack/react-router';
|
|
import { router } from './router';
|
|
import { useUiStore, applyTheme } from './stores/uiStore';
|
|
// "The Living Codex" type system (self-hosted, offline-safe): Spectral (editorial
|
|
// serif headings), Hanken Grotesk (UI), Spline Sans Mono (stats/dice).
|
|
import '@fontsource/spectral/400.css';
|
|
import '@fontsource/spectral/500.css';
|
|
import '@fontsource/spectral/600.css';
|
|
import '@fontsource/spectral/700.css';
|
|
import '@fontsource/spectral/400-italic.css';
|
|
import '@fontsource-variable/hanken-grotesk/index.css';
|
|
import '@fontsource-variable/spline-sans-mono/index.css';
|
|
import './styles/globals.css';
|
|
|
|
// Apply persisted theme before first paint.
|
|
applyTheme(useUiStore.getState().theme);
|
|
|
|
const rootEl = document.getElementById('root');
|
|
if (!rootEl) throw new Error('Root element #root not found');
|
|
|
|
createRoot(rootEl).render(
|
|
<StrictMode>
|
|
<RouterProvider router={router} />
|
|
</StrictMode>,
|
|
);
|