Skip to content

feat(registry): full French i18n parity + drift guard + E2E#476

Open
bntvllnt wants to merge 2 commits into
mainfrom
worktree-i18n-parity
Open

feat(registry): full French i18n parity + drift guard + E2E#476
bntvllnt wants to merge 2 commits into
mainfrom
worktree-i18n-parity

Conversation

@bntvllnt

@bntvllnt bntvllnt commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

Closes #475

Takes the registry site from ~10% localized to full French parity. next-intl was correctly wired but barely consumed — most routes served English to /fr despite complete French translations sitting unused.

What changed

  • Drift guardscripts/check-i18n.ts + pnpm i18n:check: message-key parity across locales, MDX coverage (every content page × every locale), and no dead/undefined message namespaces.
  • Wired every surface — home/Landing, footer, both forms, header, and all ~20 route pages (components/detail/playground, docs, philosophy, report/request, vs/*, ai, build, releases, changelog, templates, themes, design). Internal links switched to the localized @/i18n/routing Link (no locale leak).
  • Docs MDX parity — 9 flat docs migrated to per-locale folders (<slug>/{en,fr}.mdx) + French translations (diacritic-stripped house style).
  • +15 pages.* namespaces added to messages/{en,fr}.json, en/fr key-identical.
  • E2Ee2e/i18n.spec.ts: every route × both locales (status + <html lang> + hreflang + console-clean), switcher round-trip, real-French, docs-fallback guard.
  • llms-full.txt fixed to read pages via the folder-aware loader (the docs migration had regressed it; also recovers 4 pages it was silently dropping).
  • AGENTS.md — i18n architecture, the gate, and the add-a-language recipe.

Verification

pnpm i18n:check green · tsc clean · next build exit 0 (1632 static pages incl. all /fr) · eslint clean on changed files · E2E 36/36 against the production build (switcher stable under --repeat-each=3).

Out of scope (data, not UI)

Component descriptions, template/use-case data, the design-guide body, and some metadata/JSON-LD stay English — bulk content translation, tracked separately.

https://claude.ai/code/session_018ktYZpgFmQbM2GrXF8GyBv

@vllnt-pilot

vllnt-pilot Bot commented Jul 2, 2026

Copy link
Copy Markdown

ntk preview

App Status Preview
ui-registry Ready https://pr-476-ui-registry.preview.vllnt.ai
storybook Skipped (preview cell not configured)

Built from d4be0102 · public + no-index (ADR-082) · torn down on close

Rebased onto main and integrated with the new per-family landing pages (#464)
and typography primitives (#465). Takes the registry from ~10% localized to
full French parity, drift-guarded and E2E-verified.

- next-intl wiring across every route + shared component (home/footer/forms/
  header/landing, docs, philosophy, report/request, vs/*, releases, changelog,
  templates, themes + editor, design, build, components, families) — localized
  Link everywhere (no locale leak)
- docs migrated to per-locale folders <slug>/{en,fr}.mdx with French translations
- messages/{en,fr}.json: pages.*/shared.*/families.* namespaces, en/fr key-identical
- new families landing pages localized; ComponentCard story-count localized;
  /ai now redirects to /families/ai so pages.ai retired
- scripts/check-i18n.ts (`i18n:check`): message parity + MDX coverage + dead-namespace guard
- e2e/i18n.spec.ts: every route x both locales, switcher, hreflang, real-French, fallback
- llms-full.txt reads pages via the folder-aware loader
- AGENTS.md: i18n architecture, gate, add-a-language recipe

Data left English by design: component/family descriptions, family FAQ, design-guide
body, demo-fixture previews, some SEO metadata/JSON-LD.

Gates: i18n:check green, tsc clean, next build 0 errors, eslint clean, E2E 45/45.

Closes #475
…ded sweep)

A stricter multi-line + single-word-aware scan caught chrome an earlier pass
missed (single-word button labels like "Copied!"/"Share"):
- quick-add: Copy install command / Copied! / Add to v0.dev -> shared.quickAdd.*
- share-embed-bar: Share/Embed/Copy link/Link copied!/embed dialog title+desc/
  Copy embed code/share dialog title+desc -> shared.shareEmbed.* (platform names
  X/LinkedIn/Reddit/... kept as brands)
- e2e: add /components/button (exercises these + storybook-embed) + /families routes

Remaining hardcoded strings are intentional: demo-fixture previews, registry/
family data, SEO metadata + JSON-LD, brand names, literal paths, and the RSS
<link> title (feed is English).

i18n:check green, tsc clean, eslint clean, next build 0 errors, E2E 47/47.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Full French (fr) i18n parity across the registry site

1 participant