diff --git a/landing/public/fonts/BlockBlueprint.ttf b/landing/public/fonts/BlockBlueprint.ttf new file mode 100644 index 0000000..17afc37 Binary files /dev/null and b/landing/public/fonts/BlockBlueprint.ttf differ diff --git a/landing/public/fonts/fonts.css b/landing/public/fonts/fonts.css index 8aa44ed..cd63139 100644 --- a/landing/public/fonts/fonts.css +++ b/landing/public/fonts/fonts.css @@ -268,3 +268,13 @@ src: url(/fonts/pxiKyp0ihIEF2isfFJU.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; } +/* Block Blueprint — vendored from 1001fonts (NOT on Google Fonts; appended by + fetch-fonts.sh after the Google rewrite). License: 1001Fonts Free For Personal + Use. Single weight, TTF (no woff2 toolchain on the build box). */ +@font-face { + font-family: 'Block Blueprint'; + font-style: normal; + font-weight: 400; + font-display: swap; + src: url(/fonts/BlockBlueprint.ttf) format('truetype'); +} diff --git a/landing/src/data/site.ts b/landing/src/data/site.ts index 2111aad..38a5e70 100644 --- a/landing/src/data/site.ts +++ b/landing/src/data/site.ts @@ -120,12 +120,12 @@ export const site = { // Design knobs (replace the design's in-browser TweaksPanel). Baked at build. // mood: "grass" | "nether" | "end" // hero: "centered" | "split" | "spotlight" - // headFont: "pixelify" | "8bit" | "silkscreen" + // headFont: "blockblueprint" | "pixelify" | "8bit" | "silkscreen" // dust: floating pixel particles in the hero theme: { mood: "grass", hero: "centered", - headFont: "pixelify", + headFont: "blockblueprint", dust: true, }, @@ -216,6 +216,7 @@ export const LITERALS = { // Head-font CSS stacks, keyed by theme.headFont. export const HEAD_FONTS: Record = { + blockblueprint: "'Block Blueprint', system-ui, sans-serif", pixelify: "'Pixelify Sans', system-ui, sans-serif", "8bit": "'Press Start 2P', monospace", silkscreen: "'Silkscreen', system-ui, sans-serif", diff --git a/tooling/fetch-fonts.sh b/tooling/fetch-fonts.sh index ff74dcf..5155a91 100755 --- a/tooling/fetch-fonts.sh +++ b/tooling/fetch-fonts.sh @@ -41,4 +41,30 @@ echo "→ writing fonts.css (URLs rewritten to /fonts/…)" # Rewrite absolute gstatic URLs to local /fonts/. echo "$raw" | sed -E 's#https://fonts\.gstatic\.com/[^)]+/([^)/]+\.woff2)#/fonts/\1#g' > "$out/fonts.css" +# Block Blueprint — the heading font. NOT on Google Fonts, so it can't ride the +# css2 request above; vendored straight from 1001fonts (License: 1001Fonts Free +# For Personal Use — fine for this private friends' server). TTF only, no woff2 +# (no woff2 toolchain assumed). Appended AFTER the rewrite so it survives re-runs. +echo "→ vendoring Block Blueprint (1001fonts)" +bb_ttf="$out/BlockBlueprint.ttf" +if [ ! -f "$bb_ttf" ]; then + tmpzip="$(mktemp)" + curl -fsSL -A "$UA" -o "$tmpzip" "https://www.1001fonts.com/download/blockblueprint.zip" + unzip -p "$tmpzip" BlockBlueprint.ttf > "$bb_ttf" + rm -f "$tmpzip" + echo " BlockBlueprint.ttf" +fi +cat >> "$out/fonts.css" <<'EOF' +/* Block Blueprint — vendored from 1001fonts (NOT on Google Fonts; appended by + fetch-fonts.sh after the Google rewrite). License: 1001Fonts Free For Personal + Use. Single weight, TTF (no woff2 toolchain on the build box). */ +@font-face { + font-family: 'Block Blueprint'; + font-style: normal; + font-weight: 400; + font-display: swap; + src: url(/fonts/BlockBlueprint.ttf) format('truetype'); +} +EOF + echo "✓ fonts vendored into $out"