Skip to content

feat: landing page support, edit-this-page links, and body font-weight fix#26

Merged
DanFlannel merged 2 commits into
mainfrom
feat/home-page-and-github-editing
Jul 11, 2026
Merged

feat: landing page support, edit-this-page links, and body font-weight fix#26
DanFlannel merged 2 commits into
mainfrom
feat/home-page-and-github-editing

Conversation

@DanFlannel

Copy link
Copy Markdown
Contributor

Summary

Two features that close the remaining gaps vs Docusaurus, plus a site-wide font fix they surfaced.

Landing page (content/home.mdx) — presence-gated: drop the file in and / renders a
prerendered landing page (TopNav + footer, no sidebar); delete it and / redirects to /docs
as before. Ships four MDX components (Hero, FeatureGrid, Feature, LinkButton — all real
crawlable anchors), a demo home page for this repo, and full pipeline integration:

  • home is a reserved slug — excluded from sidebar/search/manifest/llms.txt, but
    prerendered with its own OG card and a / sitemap entry.
  • The prerendered home is written to dist/index.html, which doubles as the SPA fallback for
    non-prerendered URLs. Every prerendered page therefore carries a
    <meta name="capsa-prerendered"> route marker; the client hydrates only on a marker match
    and falls back to a clean client render otherwise (404s and /docs/api covered by e2e).
  • The brand wordmark in the top bar now links home from every page (/ with a landing page,
    /docs without) — SPA-fast, cmd-clickable.

Edit this page — every doc links to GITHUB_URL/edit/<branch>/content/<slug>.mdx in two
places: a PageActions menu item and a visible link below the article. New optional
VITE_GITHUB_BRANCH (default main).

Fix: body text rendered bold site-wide — Tamagui resolves font weight from the
size-matched key in the font config (fontSize="$5"weight['5']), and the map escalated
with size, so every 16px+ paragraph rendered at weight 700. The weight map is now flat 400 at
every size; headings keep their explicit weights. Also adds a body font-family fallback so
stray text nodes never fall to serif.

Type of change

  • Bug fix
  • New feature
  • Docs / content

Checklist

  • pnpm typecheck passes
  • pnpm lint passes
  • pnpm format:check passes (run pnpm format to fix)
  • pnpm build succeeds
  • pnpm check:links passes
  • Docs/examples updated if behavior changed

Notes

  • Behavioral note: non-prerendered URLs are now served the landing-page HTML by static
    hosts (previously the empty shell). Head meta is identical (site defaults) and the route
    marker guarantees a clean client render — no user-visible change, but worth knowing when
    debugging view-source.
  • Visual change: all body text drops from 700 → 400 weight — this is the intended look;
    don't tune themes against the old bold rendering.
  • e2e grew 16 → 21 tests (landing prerender + hydration, SPA-fallback safety, reserved-slug
    exclusion, edit links + brand-home navigation). PRERENDER=0 rollback re-verified.
  • New guide: Guides → Landing Page; config docs + README + .env.example updated.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 11, 2026

Copy link
Copy Markdown

Deploying capsa with  Cloudflare Pages  Cloudflare Pages

Latest commit: d30ce0f
Status: ✅  Deploy successful!
Preview URL: https://7c4edf5e.capsa-6ct.pages.dev
Branch Preview URL: https://feat-home-page-and-github-ed.capsa-6ct.pages.dev

View logs

@DanFlannel
DanFlannel merged commit 12da646 into main Jul 11, 2026
3 checks passed
@DanFlannel
DanFlannel deleted the feat/home-page-and-github-editing branch July 11, 2026 02:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant