Repository navigation
Declare Sprint 3 theme tokens and match navbar exclusions by prefix - #305
Conversation
Two Sprint 3 pages need a navbar-free subtree (/forms/ and /accept-invitation/), so NO_NAVBAR_PAGES entries ending in "/" now match every path under them. Other entries still match exactly. Declare --color-page-bg, --color-page-text, --color-brand-foreground, --font-display, and --radius-control with today's values, so the forms and auth pages can use their Tailwind classes before per-org theming lands. Nothing uses them yet, so nothing looks different. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017RYaE2zBcm7SfFBJdydeuR
✅ Deploy Preview for servicestart ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Disclaimer: This comment was AI-generated and is not necessarily completely accurate. Please take code comments with a grain of salt.
|
From review: the component tests only used exact entries, so they would pass if the wrapper went back to exact matching. Add a prefix entry in the test and check a nested path and a lookalike path. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017RYaE2zBcm7SfFBJdydeuR
|
Generated by Claude Code |
Part of #295: the theme tokens and the navbar prefix matching. Schema and contracts are in #304. This PR doesn't depend on it, and neither needs a migration from the other.
Theme tokens (
styles/globals.css)These tokens are declared with today's values, so #299 and #301 can use the classes from day one. Nothing uses them yet, so nothing looks different. #300 makes them follow each org.
--color-page-bgbg-page-bg#ffffff(the body's default)--color-page-texttext-page-textvar(--color-grey-text-strong)(the app's main text color)--color-brand-foregroundtext-brand-foreground#ffffff(thetext-whiteon today'sbg-brand-textbuttons)--font-displayfont-displayvar(--font-heading)--radius-controlrounded-control0.25rem(Tailwind'srounded, as used on the auth pages andBogButton)I compiled
globals.csswith the Tailwind CLI to check that all five classes are generated and that the variables they reference are emitted.Navbar prefix matching (
lib/navbar.ts)NO_NAVBAR_PAGESentries ending in/now match every path under them./forms/matches/forms/abcbut not/formsor/formsabc. Other entries still match exactly.NavbarWrapperuses the newisNoNavbarPage, so #299 (/forms/) and #301 (/accept-invitation/) only need to add their entry.Testing
matchesPage(prefix vs. exact,/formsabcdoesn't match/forms/) and aNavbarWrappercomponent test.pnpm lint,pnpm format, andtsc --noEmitpass locally.Checklist:
🤖 Generated with Claude Code
https://claude.ai/code/session_017RYaE2zBcm7SfFBJdydeuR
Generated by Claude Code