Repository navigation
Fix the root-page lookup and the doc-rooted donor page - #2888
Merged
Merged
Conversation
Fixtures for the no-/docs site with nested pages named docs (docsy#2875, build failure and the silently wrong llms.txt documentation index) and for the shared-chrome donor on a doc-rooted site. All three fail at this commit; the fix follows.
td/root-page.html and all.llms.txt look the docs section up as /docs: a bare docs falls back to Hugo's by-filename lookup when there is no /docs section, failing the build on two pages named docs and taking a single one for the section (docsy#2875). chrome-render.html keeps the navbar and footer on the page the helper selects instead of IsHome, so a doc-rooted site's shared build gets its donor; the placeholders already named the root URL. Fixture rename avoids chrome-render's ccr-doc-rooted tmp dir.
Adds project/design/root-page.md as the one home for what the root page is, who depends on it, how it is resolved and why by absolute path, and every case the lookup covers with the fixture pinning each; pins the auto-created translated landing and baseURL-subpath cases; CCR-20 in the case registry; chrome guide names the root page as the navbar/footer donor; 0.19.0 changelog entry under Experimental.
Manual 206 seeds for the new page's version-menu links (main deploy: +0d; www.docsy.dev: live at the 0.19.0 release) and the entries the check added for the page's own links.
✅ Deploy Preview for docsydocs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Owner review round: the intro becomes a two-case list with the home page linked to site.Home; donor page replaces bare donor across the PR's prose, comments and assertion messages, linked to the chrome guide's section; the chrome guide links root page to the design page.
…ents Review rounds 1 and 2 (r1.2-r1.7, r1.9, r2.1-r2.6; r1.1 documented, not gated): the design page follows the rule, consumers, rationale, cases, limits outline, states the description fallback and the section-only LLMS case, separates behavior from fixture evidence, and defers the definition to the user guide; the chrome guide links the user definition; helper, placeholder and test comments shrink to their rationale; the default-language subdirectory is now exercised.
The HTML format is the current one when it is among the page's output formats but not its alternatives; the root page's print render now gets a placeholder like any other page. Design page row and evidence updated (r1.1, A2 revised to gate).
Builds the doc-rooted variant in shared mode and asserts the navbar and footer on each language root and placeholders on an inner page; red against the 0.18 gate, which built this variant with no chrome anywhere.
…ot-page and chrome fixtures buildCleanSite on the harness carries the exit-0, warning-free pattern the three suites each copied; lib/fixtures.mjs holds the recipe config and link-only homes, front-matter helper, describedby and chrome probes. Behavior pinned by the suites is unchanged.
…ame the home-as-docs case Merges the two hugo-build doc-rooted files into doc-rooted.test.mjs, built once in shared mode (its llms assertions are chrome-independent); chrome-render's legacy case is the pre-0.15 home-typed-docs shape, now named so.
…donor is the root page in chrome-nav comments Review round 3: affirmative assertion labels and purpose-only suite headers; the root-page and site tests take the chrome probes from lib/fixtures.mjs; the site test registers its cleanup before asserting on the build; the design page drops its restated inventory and closer; chrome-nav.js comments name the donor page as the root page (comment-only, the file's behavior untouched).
…d shared mode; site test builds both modes The build-failure fix moves to Other changes (it hit every 0.18 site), the donor fix stays Experimental. CCR-20 is partial with its open item (doc-rooted active link), CCR-10 notes doc-rooted slugs, chrome-nav.js's header and claims are softened and complete. The site test builds the doc-rooted variant in full mode for the llms assertions again and in shared mode for the chrome ones. Fixture lib gains the llms outputs config; the chrome fixture's landing carries LLMS; design page and chrome guide lean edits; helper comment restructured.
…doc-rooted active-link gap precisely The donor placeholders follow the gate: the home's HTML render, not whichever format is rendering, so a permalinkable print format can't send print pages to a chrome-less donor. CCR-20's open item and the chrome guide's third known case say which pages the gap touches. Changelog entries cite the PR and the 0.15 reach; the design page drops its duplicated Discovery limit; the chrome fixture header states why its landing carries LLMS and print; fixture lib sheds unused exports; the main-deploy cache seed is extended to the likely merge.
…st; check both placeholders (red) A permalinkable format with a weight below HTML's renders first, so its pass fills the per-language root-page cache: the fixture reproduces the home being cached for a doc-rooted site. The permalinkable-print fixture now checks the footer placeholder as well as the navbar's, through the lib's probes.
…TML render; design-page limits The selection compares the docs page's HTML URL with the home's URL whatever format is being rendered, so render order no longer matters. The navbar and footer placeholders take their donor URL from the root page's HTML render, the same page the chrome gate keeps, instead of the home's. The design page records three more limits: a doc-rooted home whose outputs don't start with HTML, a doc-rooted language without a docs section, and HTML marked notAlternative.
…comments point at their homes The design page's description names the two candidate pages and drops the body closer it absorbed; the consumers list and the rule's rationale read against the URL comparison. The shared-chrome changelog entry takes the section's verb-led past tense. Test and fixture comments keep their input cues and point at the templates that own the rationale; the chrome guide's third known case cites its tracker inline like its siblings.
The chrome guide's known case names the non-docs pages a full build leaves unmarked (taxonomy, 404) and the language root rather than `/`; the registry's example no longer names a page that carries a menu entry. The design page's outputs limit distinguishes site `outputs.home` from the home's front matter, and "no URL" from the empty site list only. Two comments stop narrating.
…ition; claim precision The section-only fixture now pins the Markdown version's missing llms.txt link and the shortcode's build failure, which a template falling back to the section's LLMS output would otherwise pass. The chrome guide's donor-page anchor moves from the mode list to the sentence that defines the term. The client's active-link comment calls its longest-prefix pick an approximation of a full build's per-entry tests; the design page's discovery bullet loses its second colon; the lookup-fix changelog entry cites its key issue only.
…nav.js and the registry The caution callout had grown a heading-like lead and a case list; the cases move to a "Known differences from a full build" section, the callout keeps the warning, and the list gains the language-selector case the registry already records (CCR-10). The client's comments and the registry's prose use parentheses and colons where they had literal em dashes; the table's "no test" glyph stays.
The term gets a heading-level home before the reachability section, which now opens with its per-region list; the inline anchor goes, and the three pages linking the term point at the section. The no-JavaScript consequence moves from the caution to the definition.
…p; Hugo's language vocabulary The version-menu item returns to the reachability section (the browser restores those links; a link checker reaches only the root page's), the known differences keep the three restore gaps with the language-selector case split in two, and "locale" gives way to "language" per Hugo's glossary. The design page opens with the two cases and links the definition, drops the cache count, and names `build.render: never` among the shapes that leave the home without a URL. The navbar placeholder comment states what the client does with each hint; the directive suite reads the shared probe; comments and the registry lose restated lines and literal em dashes.
…ception; comments say language The navbar and footer probes match the class token, not its prefix, so a renamed or missing region can no longer pass. The chrome guide's reachability section names the one case a shared build cannot reach without JavaScript, a translation hidden from the left-nav, and the registry records it under CCR-10. Edited comments use "language" for the per-language instance, the donor-page link def takes its link text, and four narrating comments go.
…oint How it works gives each page its logical path and permalink, states what the convention moves, defines home page and root page as a pair, and closes on the one consequence: the two differ only on a doc-rooted site, so the theme selects the root page itself. The inbound anchor keeps its plural form; the glossary defines logical tree and project.
…cestor; registry truth; test pins The chrome guide's reachability section reads as a nested list with its two exceptions, and the known differences gain the nested-menu case: the restore marks the longest match only, so a parent entry loses its active state under a child entry, on doc-rooted sites the docs entry. The registry records it under CCR-03 and CCR-20 (both partial) and marks CCR-07 partial for the compact non-foldable nav. The two-docs fixture pins the directive as well as the describedby link; the directive suite reads the shared outputs; the site test's root-formats loop gets its cue back. Comments and the footer lose restated or narrating lines.
…gate test The root-page comparison, the donor gate and the two placeholders read the page's canonical output format (Hugo 0.154.4: the format whose rel is canonical, HTML by default) instead of naming HTML, so a project whose canonical format differs, or that makes another format permalinkable, behaves the same way. The navbar placeholder takes the footer's one-expression shape. The design page and registry say canonical where they said HTML render; a site with no canonical format keeps the chrome on no render.
The gate's header lists each region's kind, donor and the hints its placeholder carries, so the navbar and footer placeholders need no comment of their own.
The header states the partial's context, return and the guide link; the model, the per-region table and the hints had their homes in the guide, the client and the registry. The gate names its variables for what they hold and keeps the one reason nothing else states, why not outputformat.html.
…-21) The gate reads td.chrome with .Param on purpose, so a page that must be complete without JavaScript can opt out of the shared build in its front matter. The guide says so, the registry gives the case an ID, and a fixture pins it: it fails when the gate reads the site param only.
…ssary links cached The design page's main-branch preview URL goes live with the PR, so its seed takes the convention's +0d; the refresh also records the five Hugo glossary anchors the docs now link.
… Experimental Only the 0.18.0 build failure reached every site; the index lookup's two symptoms live inside the experimental llms.txt feature, so they move there. The bug-fix entry carries the error text a user would search for.
Two shapes the Canonical-based selection gets wrong: `rel: canonical` moved to the print format (the home is selected, so no page renders the chrome), and a link-only home whose outputs list LLMS first (its URL becomes /llms.txt, so the comparison against it fails and llms.txt links the home's LLMS file as the home page). Test labels and the CCR-20 row say "HTML render" for what the donor is.
`.OutputFormats.Canonical` is per-format `rel` configuration (SEO metadata a site may move), not page identity: round 13 broke selection, discovery and the donor by moving `rel: canonical` to print. The two option matrices (36 and 48 builds, Hugo 0.166.0) settled on the page's `html` output URL as the stable navigation identity. - td/root-page.html compares the docs page's `html` URL with the site root derived from the Site it receives (baseURL plus language prefix; absLangURL would bind to the rendering site in all.llms.txt's locale loop), so a link-only home's own URL no longer matters. Callers key the cache by language. - The chrome no longer looks the root page up: a page is the donor when its `html` URL is the site root and html is the current render; placeholders name the site root (`relLangURL ""`, since a leading slash drops a baseURL path) and the page's `html` URL. - Design page: rule, consumers, why, covered cases (rel moved; LLMS-first home) and Limits (html notAlternative; root page without HTML; paginated root).
The configuration-derived root (baseURL plus language prefix) from the previous commit breaks under uglyURLs (/index.html), multihost (no language prefix in URLs) and the site matrix's version dimension (/v1.0.0/ has no public accessor), as Sol's review reproduced; the extended matrix (54 builds) shows the home page's `html` output URL holding under all of them. Its one gap is a home with no `html` format (a link-only home listing LLMS first, render: never, empty outputs.home), back on the design page's Limits and pinned by the LLMS-first fixture as a documented limit. - td/root-page.html compares the docs page's html URL with the home's; the chrome gate and both donor attributes use the same reference. - partialCached keys: none at same-site calls (Hugo caches per site); the llms.txt locale loop keys by `.String`, the full site vector, since `.Language.Lang` collides across version sites. - Fixtures: uglyURLs case; footer donor and data-canonical-path assertions on the rel-moved case.
- navbar: `data-canonical-path` falls back to `.RelPermalink` for pages with no html output (the 404 page baked "" and the client fell back to the requested URL); fixture asserts `/404.html`. - footer: the two whitespace trims dropped in round 12 as comments were functional; restored with the navbar's empty-comment idiom. - Chrome guide: donors named once in § Donor pages (left-nav's own rule included); compact non-foldable sidebar difference; two limits of the per-page `full` setting (cached left-nav above sidebar_cache_limit; an opted-out left-nav donor leaves its active state in restored navs), the latter pinned by chrome-donor-opt-out.test.mjs and a CCR-21 open item. - Design page: § Why as a list; placeholder URL contract and the left-nav donor rule under Consumers; Limits name the remapped-section donor split, the empty donor/links of a home without html, the unselected no-html docs page; description names the doc-rooted case. - Changelog: the build failure owned by the Other-changes entry with both version scopes; Experimental gains the HTML-render-only donor and the per-page setting. - User guide: the convention's two benefits restored in the lead; "project" for the Hugo project in the section, stable id on the heading; wording. - Comments: chrome-render gate links the design page and drops the restated rule; chrome-nav header, section and restore comments pruned to the why plus CCR ids, "logical path" replaced by the page's HTML URL; test headers and titles trued up; real-print fixture asserts both canonical paths. - Registry: CCR-20 and CCR-07 residue; two unreferenced link-cache entries. r13.2-r13.5, r13.7-r13.10; r14.1, r14.2, r14.3, r14.4, r14.6-r14.11, r14.13-r14.18.
…ments - Chrome guide and registry: with uglyURLs the restored version and language selector links keep the donor's index.html (CCR-09 partial, open item with CCR-10); the scoped-sidebar residual (CCR-14) can show as one indentation level less, so the "not visible" claim goes. Both reproduced by the round. - chrome-nav: the version-link exactness comment names its condition. - Changelog: the per-page setting is documented, not new. - Test comments: root-page header drops the variant inventory the design page owns; the rel-moved rationale comment goes; an assertion label affirmed. - head.html: the canvas-colors comment keeps its why only. r16.1-r16.7.
- Design page: `uglyURLs` set for the docs section only publishes the section page at /index.html while the home keeps /, so the home stays the root page (new Limits bullet; "site-wide uglyURLs" in § Why and the row); "logical path" for Hugo's term; the left-nav donor rule linked, not restated; "reproduces in full"; the navbar placeholder alone carries the canonical path; the render: never bullet notes the docs page still publishes llms.txt. - td/root-page.html: the return value stated exactly; a design note on partialCached's per-site cache and when a caller keys by site. - User guide: project configuration, a project follows the convention, a project set up before 0.15.0; a restated sentence dropped. - Chrome guide and registry: CCR-21's leak conditioned on sidebar_cache_limit; CCR-14 wording unified; a double colon split; round provenance cut. - Changelog: past tense, two-line entries, the since-scopes compacted, the build-flag entry covers scheduled builds; link definitions by label. - Comments: no-deprecations test's premise under --panicOnWarning; the opt-out test header; fixture pointers made exact; chrome-render label; chrome-nav header, citation and uglyURLs note; head.html duplicate and typo; the doc-rooted config comment on its outputs list. - LLMS-first fixture asserts the empty donor placeholder. r17.1 (a), r17.2-r17.4, r17.6-r17.16, r17.18.
…note - Chrome guide and registry: with uglyURLs the restore also loses the navbar active link, the out-of-tree active path (CCR-17) and the scoped sidebar's "up" link (CCR-12), all through normalizePath's "/index.html/"; one open item covers the six cases. CCR-03 notes the missing origin check on external entries. The CCR-10 reachability sentence returns to the guide, its home. - chrome-render fixture: the home-as-docs case cascades type: docs, so the guide pages render through the docs layout and the Home.Type branch is load-bearing (red without it: the guide section page keeps an inline nav). - all.llms.txt: the locale loop keys the root-page call by the site it evaluates, with the known limit (Hugo hashes a Site by its language; a Hugo issue is planned); the partial's note states the caller contract only; the design page keeps "caches per site". - chrome-nav: "page-invariant chrome" named for what it is, the navbar and footer; a code-restating comment dropped. - no-deprecations test: the comment states what each check catches. - Design page: the canonical-path sentence trimmed to the contract; Limits bullet 4 notes that discovery follows the home's kept formats; the per-section uglyURLs bullet loses its second colon and its redundant close. - Comments restating test titles or config dropped; changelog tense and link; the agent-support heading carries its id. r18.1-r18.4, r18.5 (site variant, @chalin), r18.6-r18.10, r18.12.
chalin
marked this pull request as ready for review
October 20, 2026 13:25
This was referenced Oct 30, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
page reference "docs" is ambiguouswhen two pages are named docs (0.18.0) #2875docssection build regardless of other pages nameddocsllms.txtindexing a nesteddocspage as the docs sectionsharedchrome its navbar/footer donor on doc-rooted sites (the HTML render of the page published at the home page's URL), where it had nonetd.chrome: fullsetting and its limits (CCR-21)sharedchrome mode (CCR): post-0.16.0 follow-ups #2689chrome-nav.jsbehavior (comments corrected only)docssection or renaming the nested pages, and 0.19.0 is neartheme/layouts/_partials/td/root-page.html(why, and what was rejected), then_partials/chrome-render.html