refactor(web): self-host fonts via next/font/google
Replace external <link> to fonts.googleapis.com with next/font/google for Cormorant Garamond and Inter. Fonts are now built-time downloaded and served from /_next/static/media, exposed via --font-serif and --font-sans CSS variables that Tailwind's fontFamily reads. Eliminates runtime dependency on Google Fonts CDN (helpful for offline or region-restricted deploys), avoids FOUT through next/font's size-adjusted fallback, and removes two render-blocking external stylesheet requests on first load. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -24,8 +24,8 @@ const config: Config = {
|
||||
},
|
||||
},
|
||||
fontFamily: {
|
||||
serif: ['"Cormorant Garamond"', '"Source Han Serif SC"', "ui-serif", "Georgia", "serif"],
|
||||
sans: ['"Inter"', '"PingFang SC"', "ui-sans-serif", "system-ui", "sans-serif"],
|
||||
serif: ['var(--font-serif)', '"Source Han Serif SC"', "ui-serif", "Georgia", "serif"],
|
||||
sans: ['var(--font-sans)', '"PingFang SC"', "ui-sans-serif", "system-ui", "sans-serif"],
|
||||
},
|
||||
letterSpacing: {
|
||||
widest: "0.32em",
|
||||
|
||||
Reference in New Issue
Block a user