Skip to content

Landing page: EN/JA toggle + full Japanese translation#16

Merged
kenrinzero merged 2 commits into
mainfrom
claude/landing-i18n
May 30, 2026
Merged

Landing page: EN/JA toggle + full Japanese translation#16
kenrinzero merged 2 commits into
mainfrom
claude/landing-i18n

Conversation

@kenrinzero

Copy link
Copy Markdown
Owner

Bilingual landing page — EN/JA toggle + full Japanese translation

The TUI ships EN/JA, so the landing page should too. This adds a language toggle and a complete Japanese version of every visible string.

How it works

  • A fixed EN ⇄ 日本語 toggle (top-right). It's a static GitHub Pages site, so the swap is client-side: the markup stays the EN source of truth, each translatable element gets a data-i18n key, and a small script snapshots the EN innerHTML on load and swaps to JA on toggle (so toggling back is lossless).
  • Choice persists in localStorage; first-time visitors default from navigator.language (JA browsers land on JA).
  • <html lang> updates with the choice.

What's translated

Every section — hero tagline/meta, about, install steps, all 14 feature bullets, the keybindings panel, the daily-notice blurb, credits, and footer. 70 keys, EN↔JA parity verified. The notice-board preview also flips to the JA banner (【週間】更新予定スレ) and JA post bodies in JA mode, matching the real app.

Bonus fixes

  • The keybindings panel was stale — added the 0.4.x keys it was missing: D Duplicate, u Undo, r Resume.
  • JA strings deliberately avoid fullwidth punctuation outside the bundled DotGothic16 subset, so JA text renders in the pixel font instead of falling back to a system font (keeps the retro look consistent).

Notes

  • docs-only — no app code or version change.
  • Validated: 70/70 data-i18n↔JA key parity, HTML well-formed (tag balance), and the toggle script passes node --check. (Couldn't run a real browser here — worth a quick visual click-through of the toggle when it's live.)

🤖 Generated with Claude Code

kenrinzero and others added 2 commits May 30, 2026 16:24
The TUI is bilingual (EN/JA); the landing page now is too.

- Fixed top-right EN/JA toggle button. The markup stays the EN source of truth;
  each translatable element carries data-i18n, and the script snapshots EN
  innerHTML on load and swaps to JA on toggle. Choice persists in localStorage;
  first visit defaults from navigator.language.
- Full JA translations across hero / about / install / features / preview /
  keybindings / daily-notice / credits / footer (70 keys; EN-JA parity verified).
  The notice-board preview shows the JA banner + bodies in JA mode.
- Brings the keybindings panel up to 0.4.x: adds D Duplicate, u Undo, r Resume
  (it was still missing them).
- JA strings use only punctuation inside the bundled DotGothic16 subset so the
  text renders in the pixel font rather than a fallback.

docs-only (no app/version change). Validated: 70/70 i18n key parity, HTML
well-formed, JS passes `node --check`.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…able amber

The footer (〜 終 〜 + the no-telemetry line) was ~0.72em and the
second line used --amber-faint (#2a1500), nearly invisible. Bumped the footer
to 1em / .dim to 0.95em and recolored .dim to --amber-dimmer so it is legible.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@kenrinzero kenrinzero merged commit dea7320 into main May 30, 2026
@kenrinzero kenrinzero deleted the claude/landing-i18n branch May 30, 2026 14:30
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.

1 participant