Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ says so (`bump:`), and `bump` refuses it.
`task reference:check` fails on a picture that is not the release's, and on a record of
another release than the site documents. A release without the asset fails `task sources`,
saying to give it one: `gh workflow run site-shots.yml -R spin-stack/spin -f tag=<tag>`.
Inter and JetBrains Mono are served from the site, and the hero types a session spin printed: a snapshot, the
Geist and Geist Mono are served from the site, and the hero types a session spin printed: a snapshot, the
disk removed from inside, the machine restored (`src/components/Hero.astro`, `Undo.astro`). `task links` fails a page that loads a
script, a stylesheet, a font or an image from another site.
- The site is served at `SITE_URL` + `BASE_PATH`, by default `https://docs.spinbox.dev` and `/`.
Expand Down
4 changes: 2 additions & 2 deletions astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ export default defineConfig({
// Every stylesheet a file, never a <style>: 'self' covers a file, and Astro can't hash the
// styles of a component an MDX page imports.
build: { inlineStylesheets: 'never' },
// Nor is a face inlined as a data: URL, which the policy's default-src refuses: JetBrains Mono's
// Greek and Vietnamese files are under Vite's 4 KiB limit, and each page logged a refused font.
// Nor is a face inlined as a data: URL, which the policy's default-src refuses: Geist Mono's
// Cyrillic Extended files are under Vite's 4 KiB limit, and each page logged a refused font.
vite: { build: { assetsInlineLimit: (file) => (/\.woff2?$/.test(file) ? false : undefined) } },
env: { schema: { GTM_ID: envField.string({ context: 'server', access: 'public', optional: true }) } },
// Starlight colours code with Expressive Code; Astro's own Shiki colours nothing here, and with it on
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
"dependencies": {
"@astrojs/markdown-remark": "^7.3.10",
"@astrojs/starlight": "^0.43.1",
"@fontsource/inter": "5.3.0",
"@fontsource/jetbrains-mono": "5.3.0",
"@fontsource/geist": "5.3.0",
"@fontsource/geist-mono": "5.3.0",
"astro": "^7.4.13",
"satori": "0.63.2",
"sharp": "^0.35.5",
Expand Down
16 changes: 8 additions & 8 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions src/components/Head.astro
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ import Default from '@astrojs/starlight/components/Head.astro';
// The faces the first screen sets, fetched with the page: found late, through the stylesheet, a
// face swaps in after the first paint and the notice and the hero move with it (a layout shift of
// 0.23 on a phone, measured).
import sans400 from '@fontsource/inter/files/inter-latin-400-normal.woff2?url';
import sans600 from '@fontsource/inter/files/inter-latin-600-normal.woff2?url';
import mono400 from '@fontsource/jetbrains-mono/files/jetbrains-mono-latin-400-normal.woff2?url';
import mono600 from '@fontsource/jetbrains-mono/files/jetbrains-mono-latin-600-normal.woff2?url';
import sans400 from '@fontsource/geist/files/geist-latin-400-normal.woff2?url';
import sans600 from '@fontsource/geist/files/geist-latin-600-normal.woff2?url';
import mono400 from '@fontsource/geist-mono/files/geist-mono-latin-400-normal.woff2?url';
import mono600 from '@fontsource/geist-mono/files/geist-mono-latin-600-normal.woff2?url';
import { graph } from '../lib/jsonld';
import { twinPath } from '../lib/twin';

Expand Down
2 changes: 1 addition & 1 deletion src/data/reference.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"release": "v20261123.01"
},
"brand": {
"commit": "591ae52460634d893e04410b75dd432f1fad5da3"
"commit": "3b33d5ceab0198fd3a4492326230bb45c8a55a0e"
},
"counts": {
"built": 97,
Expand Down
18 changes: 9 additions & 9 deletions src/lib/card.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@ function token(name: string, from = tokens): string {
}
const c = { page: token('page'), text: token('text'), muted: token('muted'), accent: token('accent-text'), dim: token('border-strong') };

// Inter and JetBrains Mono as the site serves them. satori reads WOFF, not the WOFF2 the pages load.
// Geist and Geist Mono as the site serves them. satori reads WOFF, not the WOFF2 the pages load.
const face = (pkg: string, weight: 400 | 600) => readFileSync(`node_modules/@fontsource/${pkg}/files/${pkg}-latin-${weight}-normal.woff`);
const fonts = [
{ name: 'Inter', data: face('inter', 400), weight: 400 as const },
{ name: 'Inter', data: face('inter', 600), weight: 600 as const },
{ name: 'JetBrains Mono', data: face('jetbrains-mono', 400), weight: 400 as const },
{ name: 'JetBrains Mono', data: face('jetbrains-mono', 600), weight: 600 as const },
{ name: 'Geist', data: face('geist', 400), weight: 400 as const },
{ name: 'Geist', data: face('geist', 600), weight: 600 as const },
{ name: 'Geist Mono', data: face('geist-mono', 400), weight: 400 as const },
{ name: 'Geist Mono', data: face('geist-mono', 600), weight: 600 as const },
];
// The organization's mark drawn for the navy page, as the header has it.
const mark = `data:image/png;base64,${readFileSync('src/assets/logo.png').toString('base64')}`;
Expand All @@ -52,11 +52,11 @@ export interface Card {
}

export async function card({ topic, title, description, site }: Card): Promise<Buffer> {
const mono = { fontFamily: 'JetBrains Mono', fontWeight: 600, letterSpacing: 1.5 };
const mono = { fontFamily: 'Geist Mono', fontWeight: 600, letterSpacing: 1.5 };
const column = W - 2 * PAD;
// The column has its size written out: satori grows a padded box by its padding, and the
// last line fell off the card.
const tree = el('div', { width: W, height: H, display: 'flex', background: c.page, fontFamily: 'Inter' }, [
const tree = el('div', { width: W, height: H, display: 'flex', background: c.page, fontFamily: 'Geist' }, [
el('div', { width: column, height: H - 2 * PAD, margin: PAD, display: 'flex', flexDirection: 'column' }, [
el('div', { display: 'flex', alignItems: 'center', fontSize: 22, ...mono }, [
el('img', { width: 64, height: 64, marginRight: 20 }, undefined, { src: mark, width: 64, height: 64 }),
Expand Down Expand Up @@ -100,7 +100,7 @@ export async function landing({ lead, rest, session, site }: Landing): Promise<B
bad: token('terminal-red'),
edge: c.dim,
};
const mono = { fontFamily: 'JetBrains Mono' };
const mono = { fontFamily: 'Geist Mono' };
const left = 470;
const term = W - 2 * PAD - left - 48;
const row = (line: Line) =>
Expand All @@ -111,7 +111,7 @@ export async function landing({ lead, rest, session, site }: Landing): Promise<B
{ display: 'flex', width: term - 50, color: line.tone === 'ok' ? t.ok : line.tone === 'bad' ? t.bad : line.tone === 'dim' ? t.muted : t.text },
line.out,
);
const tree = el('div', { width: W, height: H, display: 'flex', background: l.page, fontFamily: 'Inter' }, [
const tree = el('div', { width: W, height: H, display: 'flex', background: l.page, fontFamily: 'Geist' }, [
el('div', { width: W - 2 * PAD, height: H - 2 * PAD, margin: PAD, display: 'flex', alignItems: 'center' }, [
el('div', { width: left, height: H - 2 * PAD, display: 'flex', flexDirection: 'column', justifyContent: 'space-between' }, [
el('div', { display: 'flex', alignItems: 'center', fontSize: 22, ...mono, fontWeight: 600, letterSpacing: 1.5 }, [
Expand Down
14 changes: 7 additions & 7 deletions src/styles/brand-starlight.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/* Written by `task palette` from palette.toml (spin-stack/brand). Edit palette.toml, not this file. */
:root {
--sl-color-accent-low: #113F57;
--sl-color-accent-low: #0D283C;
--sl-color-accent: #26BDED;
--sl-color-accent-high: #9FE0F6;
--sl-color-white: #F7F9FB;
Expand All @@ -16,8 +16,8 @@
--sl-color-banner-text: #EAF0F6;
}
:root[data-theme='light'] {
--sl-color-accent-low: #BFC1C5;
--sl-color-accent: #111827;
--sl-color-accent-low: #DDEBF2;
--sl-color-accent: #0A6FA3;
--sl-color-accent-high: #0A3449;
--sl-color-white: #0A0E17;
--sl-color-gray-1: #0E131F;
Expand All @@ -26,16 +26,16 @@
--sl-color-gray-4: #748099;
--sl-color-gray-5: #C4CCD9;
--sl-color-gray-6: #E0E6F1;
--sl-color-hairline-light: #E3E6ED;
--sl-color-hairline-light: #D2D8E2;
--sl-color-black: #FFFFFF;
--sl-color-banner-bg: #C0C4CB;
--sl-color-banner-bg: #BED7E6;
--sl-color-banner-text: #111827;
--sl-color-gray-7: #F1F4F9;
--sl-color-text-accent: #024F6A;
}
:root {
--sl-font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
--sl-font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
--sl-font: 'Geist', system-ui, -apple-system, 'Segoe UI', sans-serif;
--sl-font-mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}
:root {
--sl-text-h1: clamp(1.75rem, 1.421rem + 1.348vw, 2.5rem);
Expand Down
Loading