fix: curriculum map sidebar spacing and donate campaign param - #66
Draft
ahmaxed wants to merge 1 commit into
Draft
fix: curriculum map sidebar spacing and donate campaign param#66ahmaxed wants to merge 1 commit into
ahmaxed wants to merge 1 commit into
Conversation
Rework the curriculum map sidebar and correct the donate link's campaign tag in the astro-react template. curriculum-map.astro - Add module and lesson counts to the section and module headers - Wrap modules in a .modules element so they share one vertical rail - Replace the completed badge with an inline checkbox and screen reader only status text - Validate stored progress slugs before applying them curriculum-map.css - Centre the section divider: the last lesson row's padding and the global li bottom margin sit below the last visible text and pushed the divider low, so pull the section's bottom edge back up to the text - Align the active lesson row's left border with the module rail instead of letting it bleed into the sidebar padding, keeping the row content at its original position - Use --blue-mid for the active row's border and checkbox nav.css - Add a header bottom border, inset the nav divider, and tighten button line height nav.tsx - Rename the donate link campaign from test-2026 to universal-nav-button Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
ahmaxed
marked this pull request as draft
August 10, 2026 11:36
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.
Reworks the curriculum map sidebar in the astro-react template and corrects the donate link's campaign tag.
Sidebar structure (
curriculum-map.astro)3 modules), module headers show a lesson count (0/6), filled in from stored progress..moduleselement so they share one vertical rail./^[a-z0-9-]+$/before being applied.Sidebar spacing and alignment (
curriculum-map.css)Section divider was not centred.
.navigation's grid gap and.section + .section'spadding-topare both--space-lg, so the border is centred in the box model. But the section above does not end at its last visible text: the last lesson row addspadding-bottom: var(--space-sm)(9px), andglobal.css'sli { margin-bottom: var(--space-xs) }leaks into.listfor another 4.5px. Real gap was ~40px above vs 27px below..modulesnow carries a matching negativemargin-bottomto pull the section's bottom edge back to the text.Active row border was left of the module rail. Taking x = 0 at the section's content edge:
.modulesrail (border-left)0.25rem.item-linkleft edge, before-0.5rem + 1px.item-linkleft edge, after0.25remThe row started 0.75rem left of the rail, bleeding into the sidebar padding.
margin-leftis nowcalc(-1 * (var(--space-md) + 1px))so the 3px indicator lands on the rail, withpadding-leftcompensating to keep the checkbox and title at2.25rem + 4px, pixel-identical to before. The right bleed is unchanged.Colour. The active row's border and checkbox both use
--blue-midinstead of--yellow-gold.Nav (
nav.css)Header bottom border, inset nav divider, tighter button line height.
Donate link (
nav.tsx)campaign=test-2026tocampaign=universal-nav-button. The value was a hardcoded literal, not interpolated, and was the only occurrence in the repo.Testing
pnpm testpasses: 4 files, 144 passed, 1 skipped.Note that the suite covers layer generation, schemas, template validity, and framework
package.jsonfiles. Nothing imports these components or checks the donate URL, so the CSS and nav changes are not covered by automated tests and were verified by reading the box model rather than in a browser.files/framework/astro-react/has nonode_moduleslocally, so the template's owntypecheckandlintwere not run.Unrelated issue spotted
nav.tsx:5imports../../donation-config.json, which resolves tofiles/framework/astro-react/donation-config.json. That file does not exist anywhere underfiles/. If it is not generated at scaffold time,cfg.donationIdin the donate URL is broken independently of this change. Not touched here.🤖 Generated with Claude Code