Extract header/footer into shared design system package#794
Draft
PavelMakarchuk wants to merge 2 commits intomainfrom
Draft
Extract header/footer into shared design system package#794PavelMakarchuk wants to merge 2 commits intomainfrom
PavelMakarchuk wants to merge 2 commits intomainfrom
Conversation
Placeholder commit for tracking. See issue #793 for full scope. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
I tried to review this PR but ran into an issue: |
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.
Summary
Extracts the header and footer components from app-v2 into
@policyengine/design-systemso that rewrite-proxied apps (watca, taxsim, keep-your-pay-act, model, api) can render the same header/footer while preserving SEO benefits.Why
Apps served via Vercel rewrites get SEO indexing under
policyengine.orgbut lose the app-v2 header/footer since they are entirely separate apps. Iframes would give us the shell but kill SEO. A shared package gives us both.Current header/footer state
Header (
HomeHeader.tsx):linear-gradient(to right, primary[800], primary[600])Footer (
Footer.tsx):linear-gradient(to right, primary[800], primary[600])What needs to happen
Phase 1: Decouple from app-v2 internals
Linkwith plain<a>tagsuseCurrentCountry()withcountryIdpropuseWebsitePath()with direct URLsuseNavigate()/useLocation()with callback propsPhase 2: Move into design system package
packages/design-system/src/shell/@tabler/icons-react, shadcn/ui primitivesHeaderandFooterfrom package entry pointPhase 3: Update consumers
Rewrite-proxied apps that need the shared shell
/us/watcaworking-americans-tax-cut-act-one.vercel.app/us/keep-your-pay-actkeep-your-pay-act.vercel.app/us/taxsimpolicyengine-taxsim-policy-engine.vercel.app/:countryId/modelpolicyengine-model.vercel.app/us/apihousehold-api-docs-policy-engine.vercel.appCode quality to address during extraction
Footer.tsxandGiveCalcBanner.tsx(0 tests currently)Closes #793