Skip to content

[r3.4] docs: enforce brand font consistency and fix installation page UX#20997

Merged
bloxster merged 8 commits into
release/3.4from
docs/remove-quantify-font
May 11, 2026
Merged

[r3.4] docs: enforce brand font consistency and fix installation page UX#20997
bloxster merged 8 commits into
release/3.4from
docs/remove-quantify-font

Conversation

@bloxster

@bloxster bloxster commented May 5, 2026

Copy link
Copy Markdown
Collaborator

Summary

Originally a typography fix for the brand font; expanded into broader design tuning on the same scope.

1. Quantify → Montserrat 800 (the original fix)

  • Removes @font-face declaration for Quantify from custom.css
  • Deletes docs/site/static/fonts/Quantify.woff2 (non-commercial license, wrong usage scope)
  • Updates .navbar__title and footer brand to use Montserrat weight 800 (already self-hosted) instead of Quantify weight 700

Reason: Quantify is the brand font on erigon.tech for the logo wordmark only (header + footer wordmark). Per brand guidelines, everything else must use Montserrat / Nunito Sans.

2. Typography polish (custom.css)

Refinements that target Montserrat ExtraBold at display sizes — no new fonts, no size changes:

  • Negative letter-spacing on h1 (-0.015em) and h2 (-0.01em)
  • h6 treated as a section label (uppercase, 0.85rem, muted) — gives real visual hierarchy
  • --ifm-heading-line-height: 1.2 (was Docusaurus default 1.25)
  • Font-smoothing + text-rendering: optimizeLegibility on <html>
  • Vertical rhythm: more breathing room above .markdown h2 / h3
  • scroll-margin-top on all .markdown headings so in-page anchor links land just below the sticky navbar

3. Installation page scroll behavior fix (get-started/installation/index.mdx)

Restores and improves the smooth scroll + auto-open behavior on the install-method tabs:

  • Clicking a method (e.g. Pre-built Binaries) now scrolls to the parent OS section heading (#linuxmacos, #windows, #all-operating-systems) — not the <details> element — and updates the URL hash.
  • Other open install methods are auto-closed so only one is visible at a time.
  • The previous logic raced the close/open animations against the smooth scroll, causing non-deterministic landing on second-clicks across sections. New flow polls document.body.scrollHeight per requestAnimationFrame until stable for 6 frames (~100ms), then scrolls — so the smooth-scroll target is always at its final position.

Visual change

Where Change
Navbar title Quantify → Montserrat ExtraBold
Footer brand Quantify → Montserrat ExtraBold
All h1–h6 Tighter heading line-height, antialiased rendering
h1 / h2 Slight negative tracking
h6 Now a small uppercase label
Install page tabs Smooth scroll + open behavior fully working again

Test plan

  • pnpm run start — local dev, all scroll/open paths verified across Brave, Chromium, Firefox, LibreWolf
  • cd docs/site && pnpm run build — clean build
  • Verify navbar title renders in Montserrat in light + dark mode
  • Confirm no requests to any font CDN in Network tab
  • Sanity-check headings on representative content pages (e.g. /fundamentals/logs, /interacting-with-erigon/trace)

🤖 Generated with Claude Code

@yperbasis yperbasis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Footer still references Quantify — will silently fall back after this PR (bug)

docs/site/src/theme/Footer/index.tsx:47:
<span style={{fontFamily: "'Quantify', sans-serif", fontWeight: 700, ...}}>erigon.tech
With the @font-face removed and Quantify.woff2 deleted, this brand text will fall back to whatever the browser resolves sans-serif to — different from both Quantify and the navbar's
new Montserrat 800. The PR description says "No change to headings, body, or any other element", but the footer brand text will visibly change.

The PR reasoning explicitly calls out that "Quantify is the brand font on erigon.tech (logo wordmark only, two occurrences: header + footer)" — so the same fix that's being applied to
the navbar should be applied to the footer in the same PR. Otherwise the navbar and footer brand text will diverge.

  1. docs/site/DESIGN-SPEC.md is now stale

Four references contradict the new state:

  • Line 119: "Font: Quantify, weight 700, letter-spacing 0.04em" (navbar title)
  • Line 159: "Brand text: Quantify font, weight 700" (footer brand)
  • Line 272: @import url('https://fonts.cdnfonts.com/css/quantify'); (already stale from #20991, but worth fixing here)
  • Line 280: | Navbar title, footer brand | Quantify | 700 |

The doc was written as a brand spec, so leaving it describing a font that no longer ships is confusing for future contributors.

Addresses review feedback on #20997:

- Footer/index.tsx: replace inline Quantify/700 with Montserrat/800 to
  match the navbar change; without this the footer brand text would
  silently fall back to sans-serif after the @font-face and .woff2 are
  removed
- DESIGN-SPEC.md: update four stale Quantify references (navbar title,
  footer brand, CDN @import, font-roles table) to reflect Montserrat 800

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@bloxster

bloxster commented May 5, 2026

Copy link
Copy Markdown
Collaborator Author
  • Footer: 'Quantify', 700 → 'Montserrat', 800 — navbar and footer now use the same font/weight
  • DESIGN-SPEC.md: all four stale Quantify references updated (navbar title, footer brand, CDN @import line removed, font roles table)

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the docs site branding typography by removing the custom Quantify font usage and switching the navbar title (and footer brand text) to the already self-hosted Montserrat ExtraBold (800), aligning the docs UI with the stated brand guidelines.

Changes:

  • Removed the @font-face for Quantify and updated .navbar__title to Montserrat weight 800.
  • Updated the footer “erigon.tech” brand text to use Montserrat weight 800.
  • Adjusted the design spec to reflect the new navbar/footer brand font choice (but see documentation note below).

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated 1 comment.

File Description
docs/site/src/theme/Footer/index.tsx Switch footer brand text font from Quantify to Montserrat 800.
docs/site/src/css/custom.css Remove Quantify font-face and update navbar title typography to Montserrat 800.
docs/site/DESIGN-SPEC.md Update spec to state Montserrat 800 for navbar title/footer brand.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/site/DESIGN-SPEC.md Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 4 changed files in this pull request and generated no new comments.

@yperbasis yperbasis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm. We can keep Quantify because we have the licence now, right?

@bloxster

bloxster commented May 7, 2026

Copy link
Copy Markdown
Collaborator Author

Yes, correct, we are licensed.

@bloxster bloxster requested a review from yperbasis May 7, 2026 16:36
…tion

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@yperbasis yperbasis closed this May 8, 2026
@yperbasis

Copy link
Copy Markdown
Member

Closing because we can keep Quantify.

@bloxster bloxster reopened this May 8, 2026
@bloxster

bloxster commented May 8, 2026

Copy link
Copy Markdown
Collaborator Author

@yperbasis the PR about fixing CSS with the right place for each font, please approve / merge.

Typography (custom.css):
- Negative letter-spacing on h1 (-0.015em) and h2 (-0.01em) — Montserrat
  ExtraBold reads tighter at display sizes
- Treat h6 as a section label (uppercase, 0.85rem, muted) — gives real
  visual hierarchy below h1–h5 instead of yet-another-bold-heading
- Heading line-height 1.2 (was Docusaurus default 1.25), font-smoothing
  + optimizeLegibility on <html>
- Vertical rhythm: 2.5rem above .markdown h2, 1.75rem above h3
- scroll-margin-top on all .markdown headings = navbar + 1rem so anchor
  links land just below the sticky navbar

Installation scroll fix (get-started/installation/index.mdx):
The OS-method links no longer scroll to the wrong place on the first
click. Two issues addressed:

1. Section anchor mapping — clicking an install method now scrolls to
   the parent section heading (`#linuxmacos`, `#windows`,
   `#all-operating-systems`) rather than the <details> element itself,
   and the URL hash is updated to match via history.replaceState.

2. Layout-stability sequencing — the previous code tried to scroll
   while close/open animations were still in flight, which caused
   non-deterministic landing positions (especially on second clicks
   that crossed sections, e.g. macOS→Windows). The new flow:
   close other open methods → open the requested one → poll
   document.body.scrollHeight via requestAnimationFrame until stable
   for 6 frames (~100ms) → smooth-scroll to the section heading.
   Also closes any other open install method first so only one is
   visible at a time.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@yperbasis

Copy link
Copy Markdown
Member

@bloxster Please update the title and description then to match the end result.

@bloxster bloxster changed the title docs: replace Quantify with Montserrat 800 in navbar title docs: enforce brand font consistency and fix install page UX May 9, 2026
@bloxster bloxster changed the title docs: enforce brand font consistency and fix install page UX docs: enforce brand font consistency and fix installation page UX May 9, 2026
@bloxster

Copy link
Copy Markdown
Collaborator Author

The docs-site / build CI failure here is caused by a pre-existing TypeScript error in the release/3.4 base branch (SidebarsConfig was moved from @docusaurus/types to @docusaurus/plugin-content-docs in Docusaurus 3.x).

This is fixed in #21074, which is currently green and awaiting review. Once #21074 merges into release/3.4, this PR's CI should pass automatically — no changes needed here.

@yperbasis yperbasis changed the title docs: enforce brand font consistency and fix installation page UX [r3.4] docs: enforce brand font consistency and fix installation page UX May 11, 2026

@yperbasis yperbasis left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overview

Three independent changes bundled into one PR:

  1. Brand font realignment — Quantify → Montserrat 800 for navbar + footer (erigon.tech), and deletes Quantify.woff2 since no text on the docs site uses it anymore.
  2. Typography polish in custom.css — letter-spacing on h1/h2, h6 as a small uppercase label, tighter heading line-height, font smoothing, vertical rhythm, scroll-margin-top.
  3. Install-page scroll behavior rewrite — replaces the toggle-event-listener-then-scroll flow with a "wait for stable layout, then resolve target section heading, then smooth-scroll" flow that also closes sibling <details> and updates location.hash.

Approving — direction is right, brand fix is correct, all four stale DESIGN-SPEC.md references caught after the prior round. A few suggestions below, none blocking.

What's good

  • Self-hosted fonts only. Replaces two Google/CDN @import lines with explicit @font-face declarations. Removes a cross-origin runtime dependency and a referrer leak.
  • history.replaceState not pushState for the hash update — correct UX choice; clicking install-method tabs shouldn't pollute back-button history.
  • 6-frame stability + 90-frame cap in waitForStableLayout — sensible defensive pattern: bounded worst case (~1.5s @ 60Hz) and avoids the previous race between toggle animation and smooth-scroll.
  • scroll-margin-top: calc(var(--ifm-navbar-height) + 1rem) on all .markdown headings — the right fix for in-page anchor offset under a sticky navbar.

Suggestions (non-blocking)

1. if (e) e.preventDefault() in the new go(id, e) is dead code

The go function signature gained an e parameter, but all call sites are unchanged and still look like:

<a href=\"#install-prebuilt\" onClick={e => { e.preventDefault(); go('install-prebuilt'); }}>

go is invoked with a single argument, so e is always `undefined` inside go and the new guard never fires. Either drop the second param, or simplify call sites to onClick={e => go('install-prebuilt', e)} and rely on go to call preventDefault. Don't ship both forms.

2. summary.click() for opening/closing <details> is roundabout

const s = d.querySelector('summary');
if (s) s.click();
else d.open = false;

Direct d.open = false / el.open = true produces the same visible result, fires the toggle event, and is one less thing to reason about. A synthetic click runs through any other listeners on <summary> and depends on the browser's default-action toggle behavior — indirect for no apparent gain.

3. h6 visual reassignment changes existing semantics

Repurposing h6 as a small uppercase muted label is a stylistic call, but any existing MDX page that uses ###### as a real sub-sub-heading will silently re-render as uppercase muted text. Worth either grepping the docs to confirm no collateral damage, or documenting the new h6 role explicitly in DESIGN-SPEC.md (the spec currently lists h1–h6 as one row at Montserrat 800).

4. Typography polish not reflected in DESIGN-SPEC.md

The PR fixes the spec for the Quantify→Montserrat changes but adds new rules the spec doesn't describe:

  • -0.015em / -0.01em letter-spacing on h1/h2
  • --ifm-heading-line-height: 1.2
  • h6 as small uppercase label
  • vertical rhythm above .markdown h2/h3
  • scroll-margin-top on markdown headings
  • text-rendering: optimizeLegibility + font-smoothing on <html>

If DESIGN-SPEC.md is the brand source-of-truth, a "Typography rhythm" subsection that mirrors what landed in custom.css would keep it complete.

5. text-rendering: optimizeLegibility on <html> — minor perf caveat

Forces ligatures + kerning across the entire document. There's a long-standing known cost on very text-heavy pages and on older Android browsers where it triggers a slower text path. Consider scoping to headings (h1,h2,h3,h4,h5,h6 { text-rendering: optimizeLegibility; }) where the visual gain is real, rather than globally on <html>.

6. resolveTarget mapping is fragile

sectionForMethod is hardcoded against three Docusaurus-generated section ids (linuxmacos, windows, all-operating-systems). If the docs author later renames ### Linux/macOS to ### Linux / macOS, the slug changes (linux--macos or similar), the mapping breaks silently, and we fall through to the previous-sibling walk — at which point we're scrolling to whatever heading happens to precede the details element. Two ways to harden:

  • Add a runtime warning when sectionForMethod[id] resolves to a non-existent element.
  • Better, walk up the DOM from the <details> until the first heading is found, removing the hardcoded mapping entirely.

Fine for now since it'll be discovered visually, but worth acknowledging as a coupling between content and JS.

7. Add font-display: swap to the new @font-face blocks

The previous Quantify rule had font-display: swap explicitly; the four new @font-face declarations omit it and rely on the browser default (auto). Adding swap keeps FOUT behavior consistent and explicit.

8. Scope

Original change was the Quantify→Montserrat brand fix; typography polish and install-page rewrite rode along. Each is independently reviewable. Bundling means a regression in one area shares a single git revert with the others. Not blocking, but worth a thought for future PRs in this area.

9. CI

docs-site / build is red; the author flagged it as a pre-existing SidebarsConfig TS error fixed by another PR. The actual fix appears to be #21083 (docs: fix SidebarsConfig TypeScript import for Docusaurus 3.10 compatibility), not #21074 (which is the llms.txt regen). Worth confirming the merge order with that PR.

@bloxster bloxster merged commit a9135af into release/3.4 May 11, 2026
21 of 23 checks passed
@bloxster bloxster deleted the docs/remove-quantify-font branch May 11, 2026 10:52
pull Bot pushed a commit to Dustin4444/erigon that referenced this pull request May 13, 2026
## Summary

Brings the full `docs/site/` Docusaurus tree into `main`, incorporating
all documentation improvements developed against `release/3.4`.

**Scope:** `docs/site/**` + root `llms.txt` / `llms-full.txt` + removal
of superseded `docs/gitbook/` and `docs/gitbook-help/`. No changes to
Go, proto, or any non-docs source files.

### Included — merged to release/3.4

| PR | What |
|----|------|
| [erigontech#20883](erigontech#20883) | Docusaurus
v3 migration — full `docs/site/` tree, Docusaurus config, versioned v3.3
snapshot |
| [erigontech#20263](erigontech#20263) /
[erigontech#20264](erigontech#20264) | All v3.3
docs ported; branch/versioning convention established |
| [erigontech#20978](erigontech#20978) | Mobile
footer fix, SEO meta tags, OG image |
| [erigontech#20991](erigontech#20991) | Self-host
brand fonts (remove Google Fonts / CDN) |
| [erigontech#21000](erigontech#21000) | `llms.txt`
/ `llms-full.txt` generator script + root artifacts |
| [erigontech#21018](erigontech#21018) | May 2026
w19 maintenance — stale flags, broken links, accuracy fixes |
| [erigontech#21045](erigontech#21045) | CI:
docs-only path filter (skip Go jobs, run docs-site build) |
| [erigontech#21063](erigontech#21063) | `trace`
response fields reference + sync-monitoring guidance |
| [erigontech#21074](erigontech#21074) | Regenerate
`llms.txt` after sync-modes update |
| [erigontech#20997](erigontech#20997) | Brand font
consistency fix, installation page UX |

### Included — pending review on release/3.4

| PR | What |
|----|------|
| [erigontech#21030](erigontech#21030) | Automated
disk size pipeline: `update-disk-sizes.py`, `disk-sizes.json`,
`hardware-requirements.mdx` JSX fix, `generate-llms.py` `—` fallback,
unit tests |
| [erigontech#21129](erigontech#21129) | May 2026
w20 maintenance — `--caplin.nat`, `--caplin.columns-keep-slots`, RPC
subscription defaults, `nat.md` Caplin section, log.dir.verbosity
default |

### What changes on `main`

- `docs/site/` added (full Docusaurus tree, current v3.4 + frozen v3.3
snapshot)
- `docs/gitbook/` and `docs/gitbook-help/` removed (superseded by
Docusaurus)
- Root `llms.txt` and `llms-full.txt` updated to Docusaurus-generated
versions

> ⚠️ This PR does **not** remove `docs/gitbook/` yet — that cleanup will
be a separate commit once this PR is reviewed and approved.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Bloxster <bloxster@proton.me>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: lupin012 <58134934+lupin012@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants