Skip to content

feat: show What's new in the interface language - #811

Merged
omartelo merged 1 commit into
mainfrom
feat/translated-patch-notes
Oct 17, 2026
Merged

omartelo merged 1 commit into
mainfrom
feat/translated-patch-notes

Conversation

@omartelo

Copy link
Copy Markdown
Collaborator

Summary

The What's new dialog parses CHANGELOG.md, so a user running lich in any language but English read the release notes in English. This translates them, per release, without touching CHANGELOG.md, which stays English and canonical (the release page still reads it).

  • changelog/<locale>.md, one per interface language except English, holds only the latest release: a build only ever reads its own section, and git keeps the old ones. Embedded beside CHANGELOG.md.
  • patchnotes.Current(locale) reads the locale's file and falls back to English when it is missing or translates another release (dev builds, a release cut without translating).
  • Group names ("Added", "Fixed", the "2 fixed" counts) come from the catalogs in both windows, all 7 locales. Translations keep the ### headings in English: the windows color groups by the English word.
  • TestTranslations holds every locale file to the latest release in CHANGELOG.md: one section under the same heading, same groups, item counts, alert kinds, code spans and bold lead-ins. A release cut without translating fails the gate.
  • lich-changelog-i18n skill (versioned, .gitignore allowlist updated) is the procedure: slice the section, translate from English per locale (parallel, cheap model), keep headings, alert openers and code spans byte for byte, take interface words from the catalogs, run the test.
  • 0.69.0 is translated as the first case. CLAUDE.md › Releases gains the step; the i18n rules in CLAUDE.md, frontend/CLAUDE.md and lich-i18n say where these translations live.

Known limit

In the native window, switching the interface language while the notes are loaded keeps them in the previous language until the window is reopened. The web window refetches (the resource key carries the locale).

Test plan

  • go test ./internal/patchnotes: locale read, fallback for a missing locale and for a translation of another release, TestTranslations over the 6 real files
  • native/: lichclient sends the locale; group labels and counts in pt-BR; catalog parity and plural forms
  • Frontend: PatchNotesDialog.test.tsx renders the groups in pt-BR
  • Local gate: biome ci, tsc, vite build, vitest with coverage, gofmt, go vet, go test (root and native/)
  • Review a translated dialog in a real window: a dev build has no changelog section, so no -shot was taken

The What's new dialog read CHANGELOG.md, so every non-English user saw the
release notes in English. Each release is now translated into
changelog/<locale>.md, one file per interface language holding only the
latest release, embedded beside CHANGELOG.md. patchnotes.Current takes the
window's locale and falls back to English when the release has no
translation into it.

Both windows name Keep a Changelog's groups from the catalogs, which is why
translations keep the ### headings in English. TestTranslations holds every
locale file to the latest release (groups, item counts, alert kinds, code
spans, bold lead-ins), so a release cut without the new lich-changelog-i18n
skill fails the gate. 0.69.0 is translated as the first case.
@omartelo
omartelo merged commit a7397e2 into main Oct 17, 2026
10 checks passed
@omartelo
omartelo deleted the feat/translated-patch-notes branch October 17, 2026 18:53
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