From 7a0b2c323d534d60aff4661ef5ae0354fa0742d4 Mon Sep 17 00:00:00 2001 From: Ian Clarke Date: Mon, 28 Sep 2026 10:51:49 -0500 Subject: [PATCH 1/3] fix(nix): render /nix/ as an article page, not a section landing page As _index.md the page used the section-landing layout: a 1344px shell where paragraphs are capped at 66ch but code blocks, the alert and the table run full width, so the prose looked hard-wrapped against a wide empty margin. As a leaf page (index.md, same /nix/ URL, like /bug/) it gets the is-prose column that headings, text and code share. Claude-Session: https://claude.ai/code/session_016xwEnj4eizFJUpd1bPwPQa --- hugo-site/content/nix/{_index.md => index.md} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename hugo-site/content/nix/{_index.md => index.md} (100%) diff --git a/hugo-site/content/nix/_index.md b/hugo-site/content/nix/index.md similarity index 100% rename from hugo-site/content/nix/_index.md rename to hugo-site/content/nix/index.md From 3f89b5f35a1fa56c1f4b9e5e4bfcfc09d6654370 Mon Sep 17 00:00:00 2001 From: Ian Clarke Date: Mon, 28 Sep 2026 10:54:30 -0500 Subject: [PATCH 2/3] fix(theme): stop section pages stranding prose beside full-width blocks Section pages used a 1344px shell where paragraphs are capped at 66ch but code blocks, tables, tabs and alerts run the full width, so the text looked hard-wrapped. A section with no child pages (try, uninstall, donate/thanks, ghostkey/success) now renders in the is-prose article column; one with a card grid (quickstart, build, about, ...) caps the intro as a whole, so its blocks share the text measure while the grid below stays wide. Also make fenced code blocks break out of the prose column as the CSS already intended: Hugo wraps them in div.highlight, so the '> pre' selector never matched one. Claude-Session: https://claude.ai/code/session_016xwEnj4eizFJUpd1bPwPQa --- hugo-site/themes/freenet/assets/css/base.css | 11 +++++++++++ hugo-site/themes/freenet/layouts/_default/list.html | 6 +++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/hugo-site/themes/freenet/assets/css/base.css b/hugo-site/themes/freenet/assets/css/base.css index f5c391b4..853e35f9 100644 --- a/hugo-site/themes/freenet/assets/css/base.css +++ b/hugo-site/themes/freenet/assets/css/base.css @@ -361,6 +361,14 @@ pre code { max-width: 1344px; } +/* ...but cap the intro as a whole, not just its paragraphs. Capping only the + paragraphs left code blocks, tables, tabs and alerts running the full shell + width beside them, so the prose looked hard-wrapped in a narrow strip. The + card grid below keeps the full width. */ +.container.is-section-page .page-intro { + max-width: var(--measure); +} + .page-list.is-grid { display: grid; gap: 1.5rem; @@ -401,6 +409,9 @@ pre code { @media screen and (min-width: 1024px) { .container.is-prose .content > table, .container.is-prose .content > pre, + /* Hugo wraps every highlighted fence in
, so the + bare `> pre` above never matched a fenced code block. */ + .container.is-prose .content > .highlight, .container.is-prose .content > figure { margin-inline: calc((var(--measure-content) - var(--breakout)) / 2); width: var(--breakout); diff --git a/hugo-site/themes/freenet/layouts/_default/list.html b/hugo-site/themes/freenet/layouts/_default/list.html index e8756f75..ce4bb7dc 100644 --- a/hugo-site/themes/freenet/layouts/_default/list.html +++ b/hugo-site/themes/freenet/layouts/_default/list.html @@ -1,5 +1,9 @@ {{ define "main" }} -
+ {{/* The wide shell exists for the child-page card grid. A section with no + child pages (try, uninstall, ...) is just an article, and in the wide + shell its capped paragraphs sit beside full-width code blocks and + alerts, which reads as hard-wrapped text. */}} +

{{ .Title }}

{{ if .IsSection }}
From 31f30794e5f9983dddf1fa218248d6a4a4de3986 Mon Sep 17 00:00:00 2001 From: Ian Clarke Date: Mon, 28 Sep 2026 11:04:34 -0500 Subject: [PATCH 3/3] fix(theme): skip the empty card grid on sections with no child pages It rendered an empty div whose top margin left a gap at the foot of what is now an article-width page (review finding on #190). Claude-Session: https://claude.ai/code/session_016xwEnj4eizFJUpd1bPwPQa --- hugo-site/themes/freenet/layouts/_default/list.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hugo-site/themes/freenet/layouts/_default/list.html b/hugo-site/themes/freenet/layouts/_default/list.html index ce4bb7dc..251bb10e 100644 --- a/hugo-site/themes/freenet/layouts/_default/list.html +++ b/hugo-site/themes/freenet/layouts/_default/list.html @@ -9,6 +9,7 @@

{{ .Title }}

{{ .Content }}
+ {{ if .Pages }}
{{ range .Pages }}
@@ -29,6 +30,7 @@

{{ end }}
+ {{ end }} {{ else }} {{ if eq .Section "news" }} {{ $dateMachine := .Date | time.Format "2006-01-02T15:04:05-07:00" }}