Repository navigation
Show one navigation pane on the landing page and the docs - #366
Conversation
…r, and the live check Signed-off-by: rocklambros <rock@rockcyber.com>
…t pass Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
…the landing page Signed-off-by: rocklambros <rock@rockcyber.com>
…policy Signed-off-by: rocklambros <rock@rockcyber.com>
…ides Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
…ests Each build measured at under a second; the suite stays about 22 seconds locally and 8 seconds in CI's Run the guards. Signed-off-by: rocklambros <rock@rockcyber.com>
…epair Signed-off-by: rocklambros <rock@rockcyber.com>
…s on it Signed-off-by: rocklambros <rock@rockcyber.com>
…n its own step Signed-off-by: rocklambros <rock@rockcyber.com>
…host allowlist by role Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
|
This pull request's description says it closes #361, which is on the project roadmap. When it merges, GitHub closes that issue and the roadmap counts it as delivered. Please confirm the change delivers the whole issue before merging. |
Signed-off-by: rocklambros <rock@rockcyber.com>
…e panel on an outside tap Signed-off-by: rocklambros <rock@rockcyber.com>
…s nav entry cannot stop the deploy of main Signed-off-by: rocklambros <rock@rockcyber.com>
…hen there is nothing to re-derive Signed-off-by: rocklambros <rock@rockcyber.com>
…t so the step cap never kills it before the summary Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
…eplaying an override diff Signed-off-by: rocklambros <rock@rockcyber.com>
…oved out of a protected tree still reaches the path rule Signed-off-by: rocklambros <rock@rockcyber.com>
|
@bar-capsule @afogel can one of you review this and approve it? I can't approve my own PR, and one approval from either of you covers all 41 files. I ran head I also served the built site locally the way Pages does. What's left:
Please review now, and approve after that push. The ruleset drops any approval when I push. |
Signed-off-by: rocklambros <rock@rockcyber.com>
…he job stays green before the first promotion Signed-off-by: rocklambros <rock@rockcyber.com>
Signed-off-by: rocklambros <rock@rockcyber.com>
What changed
The landing page and the documentation now show one left navigation pane with the same rows in the same order, and
mkdocs.ymlis its only source. The landing renderer escapes and validates every value it reads frommkdocs.ymland adds a hashed content security policy, while the docs get the pane through two recorded overrides of Material's partials with a tool that re-derives them on a theme bump. A test holds the two panes equal on every sampled page, the docs 404 is now served from the site root, and a new deploy step and monitor job check the published pane.Which issue does this implement
Closes #361
meaning, so it needs no issue
Base branch
integration, because this touches the specification, schemas, a referenceimplementation, an adapter, tests, or CI
main, because every changed path is on the documentation lane allowlist inCONTRIBUTING.md
Type of change
I tested this
uv run pytest -vpasses on my machineuv run mkdocs build --strictpasses on my machineThe suite on the branch head:
1074 passed, 1 skipped. The strict build withGITHUB_PAGES_URLset endsDocumentation built in 0.55 secondswith no warning.zizmor on the two workflows this changes:
The five pre-merge checks, each run in a copy outside the working tree.
(a) A scratch relock to mkdocs-material 9.8.0, the bump that arrives first. The plan expected the override test to fail with the upstream-equality message. It does not, because the 9.8.0 copies of
nav.htmlandnav-item.htmlare byte-identical to the 9.7.7 copies committed underoverrides/.upstream/partials/, so there is no delta to report. The "relock first" message comes from the re-derivation tool instead, which is the expected answer when nothing upstream changed.(b) Zensical 0.0.73 with the classic variant.
variant: classicadded undertheme:in a scratch copy, built with the pinned package and the test fixture's base URL so the canonical links match.Caveat: Zensical overrides replace Zensical's own partials, not Material's, so this proves the override templates render under Zensical and walk to the same rows. It does not prove they are the right partials to override there.
(c) The landing page in a browser. Rendered with
uv run --no-dev python tools/render_landing.py landing /tmp/nav-t10/_site, served bypython3 -m http.server 8123 --bind 127.0.0.1, and opened in Chromium through Playwright. At 1366x768 the sidebar column shows Home open with its eight sections, then Trustworthy Agents, ACS, FAQ, Topics, Concepts, Specification, About, the External resources heading with GitHub, Roadmap, and Slack, and the theme toggle at y=642, inside the 768px column without scrolling it. At 400px wide, pressing Menu opens the drawer with the same rows and the toggle. The console at both widths:No message contains
Content Security PolicyorRefused to. The screenshots of the sidebar column and the open phone drawer are available on request.(d) The live verifier, one attempt against the published site. The tool has no single-attempt flag, so
checkwas called directly. Before merge it reports GitHub's default 404, as expected.(e) The third-party guard.
Checklist
git commit -s(required by the DCO)Security
mkdocs.ymlbecomes a landing build input, so every value the renderer reads from it is treated as untrusted text. Titles must match the title pattern, anchors the anchor pattern, and URLs either a relative.mdpath or anhttpsURL on a reviewed host. Every emitted value is HTML-escaped, and a value that fails a pattern stops the render with an error naming the entry instead of dropping the link. The docs overrides apply| eto every value they emit.The landing page carries a content security policy with
default-src 'none', and its one inline script and one inline style are allowed by sha256 hashes computed from the rendered bodies. A test recomputes the hashes and holds the page to no other inline script or style, nostyleattribute, and nodata:URI, so the hashes stay complete.A token test scans the built docs for
on*attributes and forjavascript:,data:, andvbscript:URLs, and checks the hosts in the built theme scripts against an allowlist keyed by bundle name.tools/rederive_overrides.pywill not adopt a change in Material's partials until it is run again with--accept-deltaand the sha256 of the delta it printed, so a theme bump cannot rewrite the overrides without someone reading what changed upstream. Its--recordmode never re-baselines an upstream copy that differs from the installed partial.Permission changes
.github/CODEOWNERSadds@Lrd0036to four lines:/landing/,/mkdocs.yml,/overrides/, and/docs/stylesheets/. That widens who can approve those paths, so it is a permission change for the owner to confirm./pyproject.tomland/uv.lockare unchanged and stay with the leads pending his call.Before merge
overrides/README.mdfollows it.scope:in-focus.Rollback, from the Hosting section of CLAUDE.md: before re-running an older deploy, run
gh variable set ROADMAP_REFRESH_ENABLED --body false, or the 05:15 UTC nightly redeploys main. Expect the navigation job inmonitor-pages.ymlto stay red until the revert reaches main, since it checks out main's verifier against the rolled-back site. Re-enable the variable once the revert deploys. A red navigation verify after a green Deploy to Pages means the site is live and the edge may be stale. Re-run once, then read the step summary.