diff --git a/docs/astro.config.mjs b/docs/astro.config.mjs index d6d9f4e4a9..a4123a6ad9 100644 --- a/docs/astro.config.mjs +++ b/docs/astro.config.mjs @@ -196,7 +196,7 @@ export default defineConfig({ tag: "link", attrs: { rel: "stylesheet", - href: "https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap", + href: "https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500&display=swap", }, }, // Plausible analytics — defer keeps it off the critical path diff --git a/docs/src/fonts/dammit-sans-v0.3-bold.otf b/docs/src/fonts/dammit-sans-v0.3-bold.otf new file mode 100755 index 0000000000..44cf6cfecb Binary files /dev/null and b/docs/src/fonts/dammit-sans-v0.3-bold.otf differ diff --git a/docs/src/styles/cli.css b/docs/src/styles/cli.css index 26794bf449..ea247d8e28 100644 --- a/docs/src/styles/cli.css +++ b/docs/src/styles/cli.css @@ -3,6 +3,27 @@ Base theme provided by @sentry/starlight-theme ========================================================================== */ +/* Brand fonts: Dammit Sans (headings, self-hosted below) + Rubik (body, self- + hosted by @sentry/starlight-theme as "Rubik Variable") + JetBrains Mono + (code). Dammit Sans is a display face with a limited glyph set, so headings + fall back to Rubik for any missing glyph (e.g. # / * \ | ^ _ ` ~). */ +@font-face { + font-family: "Dammit Sans"; + /* Relative URL so Vite bundles + hashes it and respects the site `base` + (root-absolute paths break under the PR-preview base, e.g. /_preview/pr-N). */ + src: url("../fonts/dammit-sans-v0.3-bold.otf") format("opentype"); + font-weight: 700; + font-style: normal; + font-display: swap; +} + +/* Headings use the Dammit Sans display font; body/code are unaffected. */ +.sl-markdown-content :is(h1, h2, h3, h4, h5, h6):not(:where(.not-content *)), +.page-title-wrapper h1, +.hero h1 { + font-family: var(--sl-font-headings); +} + :root, :root[data-theme="dark"], :root[data-theme="light"] { @@ -10,8 +31,12 @@ /* Sentry brand purple (#7553FF), the mid-anchor of the CLI banner gradient */ --sl-color-accent-rgb: 117 83 255; - /* CLI uses Inter + JetBrains Mono */ - --sl-font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; + /* Body uses the theme's self-hosted Rubik Variable; headings use Dammit Sans; + code stays JetBrains Mono. */ + --sl-font: "Rubik Variable", -apple-system, BlinkMacSystemFont, "Segoe UI", + sans-serif; + --sl-font-headings: "Dammit Sans", "Rubik Variable", -apple-system, + BlinkMacSystemFont, "Segoe UI", sans-serif; --sl-font-mono: "JetBrains Mono", ui-monospace, monospace; /* Match the original CLI docs header sizing. */