Repository navigation
i18n: add Turkish (tr) as a bundled locale - #1184
volkankurt2 wants to merge 2 commits into
Conversation
Adds `tr` to the Lingui config, the translate/check tooling and the bundled locale packs, with Turkish glossary terms and a full draft catalog of all 2,611 messages. Every entry is a machine draft (`fuzzy`, `Review: required`), so the compiled pack stays empty and Turkish shows as English until a native speaker reviews entries; review follows in later PRs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E3gd4d8ajhkLqYhF3KbFPB
Aymericr
left a comment
There was a problem hiding this comment.
Thanks for this, and welcome! The wiring follows the "To bundle another language" steps: tr is added to lingui.config.ts, TARGET_LOCALES, BundledLocale and bundledLocalePacks, and the glossary terms look right. Since every draft is fuzzy with Review: required, the compiled pack is {} and the UI keeps falling back to English, so nothing changes on screen yet and no screenshots are needed for this one.
One small ask for your first reviewed batch: please add tr to the expectations in packages/editor/src/i18n/locales.test.ts (the viewer.display.title and editor.buildPanel.rooms.title strings) once those two are reviewed, so the pack gets the same coverage as the other languages. Screenshots of the Turkish UI on those follow-ups would help too.
CI hasn't run yet because this is your first contribution from a fork. It'll merge once a maintainer approves the workflow run and checks are green.
| const GLOSSARY_PATH = join(ROOT, 'i18n/glossary.json') | ||
| const LINGUI_BIN = join(ROOT, 'node_modules/.bin/lingui') | ||
| const TARGET_LOCALES = ['zh-CN', 'fr', 'es', 'ja'] as const | ||
| const TARGET_LOCALES = ['zh-CN', 'fr', 'es', 'ja', 'tr'] as const |
There was a problem hiding this comment.
Test fixtures omit Turkish locale
Medium Severity
Adding tr to TARGET_LOCALES leaves the i18n script tests still listing only zh-CN, fr, es, and ja. Fixture extract reads a missing Turkish catalog, and checkTranslationEntries reports tr as missing, so scripts/i18n.test.ts and scripts/i18n-literals.test.ts fail under bun run test.
Reviewed by Cursor Bugbot for commit 96691fe. Configure here.
There was a problem hiding this comment.
Right, fixed in 99bbdf5: tr is now in the fixture locales of scripts/i18n.test.ts and scripts/i18n-literals.test.ts (56 pass locally).
The i18n script tests listed only zh-CN, fr, es and ja, so with tr in TARGET_LOCALES the extract fixture read a missing Turkish catalog and checkTranslationEntries reported tr as missing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01E3gd4d8ajhkLqYhF3KbFPB
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
There are 2 total unresolved issues (including 1 from previous review).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 99bbdf5. Configure here.
| const GLOSSARY_PATH = join(ROOT, 'i18n/glossary.json') | ||
| const LINGUI_BIN = join(ROOT, 'node_modules/.bin/lingui') | ||
| const TARGET_LOCALES = ['zh-CN', 'fr', 'es', 'ja'] as const | ||
| const TARGET_LOCALES = ['zh-CN', 'fr', 'es', 'ja', 'tr'] as const |
There was a problem hiding this comment.
New locale breaks release base lookup
High Severity
Adding tr to TARGET_LOCALES makes hasCatalogs require a Turkish PO on the comparison revision. Existing @pascal-app/editor@* tags and the original catalogs commit lack that file, so releaseBase() can no longer use them. On a release from main, origin/main matches HEAD and is skipped, and release-check fails asking for --base.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 99bbdf5. Configure here.


What does this PR do?
Adds Turkish (
tr) as a bundled locale, following the "To bundle another language" steps ini18n/README.mdand the communitytrpack discussed in #621 and #1148.lingui.config.tsandTARGET_LOCALESinscripts/i18n.tsgaintr.packages/editor/src/i18n/locales.tsregisters thetrpack.i18n/glossary.jsongains Turkish terms: tavan, kat planı, kat, oda, 3B tarama, duvar, gezinti.packages/editor/src/i18n/locales/tr/messages.pohas a draft for all 2,611 messages.Every entry is an AI draft, marked
fuzzy+Review: required(AI-Provider: claude-code). The drafts were not produced withi18n:translate; they were checked with the samevalidateTranslationrules (placeholders, tags, Turkishone/otherplurals, glossary). Since onlyReview: humanentries are compiled, the shippedtrpack stays empty and the UI shows English until a native speaker reviews entries. I'm a native speaker and will send reviewed batches as follow-ups, starting with the viewer, navbar, toolbar and Build panel copy.How to test
bun run i18n:check: it passes and reportstr 2611awaiting review.bun scripts/i18n.ts check --reviewed trfails as expected, because nothing is reviewed yet.bun test packages/editor/src/i18npasses.Screenshots / screen recording
N/A — no reviewed strings yet, so nothing changes on screen.
Checklist
bun devbun checkto verify)mainbranch🤖 Generated with Claude Code
https://claude.ai/code/session_01E3gd4d8ajhkLqYhF3KbFPB
Note
Low Risk
Infrastructure-only i18n wiring with an empty compiled Turkish pack, so user-visible behavior is unchanged until human-reviewed strings are merged.
Overview
Adds Turkish (
tr) as a bundled locale across Lingui, the i18n toolchain, and editor locale registration, following the existing pattern for zh-CN, fr, es, and ja.lingui.config.ts,TARGET_LOCALESinscripts/i18n.ts, andbundledLocalePacksinpackages/editor/src/i18n/locales.tsall includetr. The glossary gains Turkish equivalents for architecture terms (e.g. tavan, kat planı, duvar). i18n unit tests now treattrlike other target locales.The shipped
trcompiled pack stays empty (messages.tsis{}) because onlyReview: humanentries are compiled; draft PO entries (per the PR description) remain fuzzy and do not change the UI until reviewed batches land.Reviewed by Cursor Bugbot for commit 99bbdf5. Bugbot is set up for automated code reviews on this repo. Configure here.