mirror of
https://github.com/bmad-code-org/BMAD-METHOD.git
synced 2026-09-19 08:11:52 +08:00
42de7ff102
* fix(docs-site): act on the review findings from #2850 Five findings, all valid, verified against the code rather than taken on trust. The label register failed WCAG AA. --sl-color-gray-3 resolved to #7c8797, which is 3.64:1 on white, and it sets the sidebar group labels, the table of contents heading, the search shortcut and the footer meta — 11px uppercase mono, the hardest case in the file. It is #687383 now: 4.81:1, and still a step lighter than the body's muted ink so the ramp keeps its shape. Dark was already 6.16:1 and is untouched. The footer's column headings were <h2> inside <main>, so they joined the page's heading outline: a reader skimming by heading met "Method" and "Community" among the article's own sections. Each column is now a nav labelled by its own visible text. Diagram.astro substituted labels with a regex that had no g flag and did not escape the key, so a key used twice in one drawing replaced only its first occurrence and a key containing regex metacharacters could match the wrong element. The rehype plugin walks the tree and has neither problem; this path now escapes and replaces globally. The diagram cache guard returned early when no diagrams were found, so deleting the last one left the pages that embedded it rendering from cache. The empty list now reaches the digest. The accessible-name guard checked ariaLabelledBy but not ariaLabel, so a diagram naming itself that way still had its name replaced by the markdown alt text. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> * fix(docs-site): bring the section list back above the fold The themed sidebar spaced its groups at 1.8rem, which pushed the last section 132px below the fold at 1440x800 — so a reader could no longer see what the docs contain without scrolling, which is the sidebar's main job on first visit. Group spacing goes to 0.9rem and item rows lose a little padding. The mono label register keeps enough air to read as a label. Measured against the sidebar as it was before the theme landed: 1440x800 before 791px, themed 932px, now 788px (fold at 800) 1280x720 before 791px, themed 932px, now 788px (fold at 720) At 720 the original overflowed by 71px and this now overflows by 68, so it is no worse than the baseline; at 800 both fit. In every case the full list of sections sits above the fold with the first two sections showing their contents. Reported by Alex Verkhovsky. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> * fix(docs-site): stop printing the sidebar script on narrow screens `.page > .main-frame > *` set `display: flex` on every child of the main frame. One of those children is Starlight's inline sidebar-persistence module, and `display: flex` overrides the browser's `display: none` for a script element — so its source rendered as text on the page. Only below 72rem, because that is where the rule lives, and only in a production build, where the module is inlined rather than loaded from a file. That is why it showed on mobile and never in dev. The selector names the wrapper div instead. Confirmed at 375px: the script computes `display: none` again, and the footer still sits at the bottom of the page, which is what the rule was there for. Also brings two imported diagrams onto the shared type scale. Apparent size is nominal size over viewBox width; build-run and walkthrough-run sit at 0.0149, development-paths was 0.0237 and bmad-delivery-loop 0.0187, so their labels rendered up to 1.6x larger than everything else on the site. Both are scaled to match; planning-skills was within 12% and is left alone. Median rendered text is now 10.5px on build-run, 10.5px on planning-skills and 12px on development-paths, with no overflow or collisions. Reported by Ruben. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5 <noreply@anthropic.com>