feat(i18n): add Polish (pl) locale at ~91% coverage#2731
Conversation
Adds the Polish locale to the i18n system following the established
5-chunk pattern. Coverage matches or exceeds existing non-English
locales (de 87%, fr 83%, ru 89%).
- Adds pl-{1..5}.ts chunk files using the `{ ...enN, <pl overrides> }`
parity-safe pattern so all 3036 keys resolve from day one.
- Aggregates chunks via app/src/lib/i18n/pl.ts.
- Wires `pl` into LanguageSelect, I18nContext, types, and localeSlice
(BCP-47 prefix match).
- Uses informal "Ty" form throughout; polonizes domain terminology
rather than calquing English (e.g. "skills" → "umiejętności",
"memory" → "pamięć", "approval" → "zatwierdzenie").
- Preserves all {count}/{label}/{name} interpolation placeholders.
Verified: `pnpm i18n:check` → 0 missing, 0 extra, 273 untranslated
(91% translated); `pnpm typecheck` clean; `pnpm lint` clean (only
pre-existing warnings unrelated to i18n).
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
✅ Files skipped from review due to trivial changes (2)
🚧 Files skipped from review as they are similar to previous changes (4)
📝 WalkthroughWalkthroughAdds Polish locale support: five new translation chunks (pl-1..pl-5), composed ChangesPolish Language Support Addition
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related PRs
Suggested reviewers
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint skipped: no ESLint configuration detected in root package.json. To enable, add Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@app/src/components/LanguageSelect.tsx`:
- Line 22: The 'Polski' literal in the locales list should be replaced with a
translated string via the useT() hook: update the locales array inside the
LanguageSelect component to call useT() (e.g., t('language.polish')) for the
label for the 'pl' entry instead of the hard-coded 'Polski', and add the
corresponding key ("language.polish": "Polish" or "Polski" as appropriate) to
the en.ts translations and any translation chunks so the key exists across
builds.
In `@app/src/lib/i18n/chunks/pl-2.ts`:
- Line 387: The Polish translation for the key
settings.autocomplete.appFilter.noLogs currently contains a malformed value "')
:'"; locate this key in pl-2.ts and replace that accidental string with a proper
Polish phrase (e.g., "Brak logów" or another accurate UI copy you prefer) so the
UI renders a meaningful message instead of broken characters.
In `@app/src/lib/i18n/chunks/pl-5.ts`:
- Line 52: The listed Polish labels are inverted: update the value for
'settings.cron.jobs.paused' to the correct "paused" label (e.g., 'Wstrzymane' or
an appropriate Polish word for paused), change 'webhooks.tunnels.enableEcho'
from 'Usuń Echo' to an enable action label like 'Włącz Echo', and change
'webhooks.tunnels.inactive' from 'Aktywny' to the correct inactive label (e.g.,
'Nieaktywny'); apply the same fixes to the duplicate entries around the other
occurrences referenced (lines 536-537) so the keys match their intended
status/action semantics.
In `@app/src/lib/i18n/pl.ts`:
- Around line 16-28: The added Polish i18n keys (e.g.,
'skills.composio.noApiKeyTitle', 'skills.composio.noApiKeyDescription',
'skills.composio.noApiKeyCta', 'channels.localManagedUnavailable',
'rewards.localUnavailable', 'rewards.localUnavailableCta',
'settings.search.localManagedUnavailable', 'devices.comingSoonDescription',
'welcome.continueLocallyExperimental') were placed directly in the aggregator
file instead of the appropriate chunk files; move each key into the matching
Polish chunk file (pl-1.ts … pl-5.ts) that corresponds to the English chunk
where the key was introduced (update en-N.ts if needed), then remove them from
the aggregator so the aggregator only composes chunks via spreads; ensure chunk
filenames and the exact key names (as listed above) are used to locate and place
the translations.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 9d8bc1a6-3df3-4539-84ca-febe4b6e7c30
📒 Files selected for processing (11)
app/src/components/LanguageSelect.tsxapp/src/lib/i18n/I18nContext.tsxapp/src/lib/i18n/chunks/pl-1.tsapp/src/lib/i18n/chunks/pl-2.tsapp/src/lib/i18n/chunks/pl-3.tsapp/src/lib/i18n/chunks/pl-4.tsapp/src/lib/i18n/chunks/pl-5.tsapp/src/lib/i18n/pl.tsapp/src/lib/i18n/types.tsapp/src/store/localeSlice.tsscripts/i18n-coverage.ts
Wraps property lines exceeding printWidth: 100 onto a continuation line, matching the canonical Prettier output enforced by the Type Check CI job. No semantic changes.
graycyrus
left a comment
There was a problem hiding this comment.
Polish locale (pl) — LGTM
Summary
Clean locale addition at 91% coverage with all integration points correctly wired.
Verification
✅ CI: All checks green (27 passed, 1 cancelled, 0 failed)
✅ Lint: Clean (pre-existing 61 warnings unrelated)
✅ TypeCheck: Clean
✅ Coverage: i18n parity gate passes (0 missing, 0 extra, 273 untranslated)
✅ CodeRabbit: All flagged issues addressed by author
Changes reviewed
| File | Change | Status |
|---|---|---|
LanguageSelect.tsx |
Added pl flag + label | ✅ Hard-coded labels intentional per design comment |
I18nContext.tsx |
Import + register pl locale | ✅ Alphabetical order |
types.ts |
Added pl to Locale union | ✅ Correct placement |
localeSlice.ts |
Added BCP-47 prefix mapping | ✅ Correct (matches other locales) |
i18n-coverage.ts |
Added pl to script | ✅ Present |
pl-{1..5}.ts (5504 lines) |
Translation chunks | ✅ Parity-safe spreads (...enN, <pl>) ensure all 3036 keys resolve from day one |
Translation quality
- Coverage: 2763 of 3036 keys translated (~91%), exceeding de (87%), fr (83%)
- Style: Informal "Ty" form throughout, polonized terminology (umiejętności, pamięć, zatwierdzenie, wątki, kanały) rather than English calques
- Placeholders: All interpolation markers (
{count},{label},{name}) preserved correctly - Pattern adherence: Follows established structure from other non-English locales
No issues found
No critical, major, or minor findings. All prior CodeRabbit suggestions either addressed (hard-coded labels) or acknowledged as false positives (hallucinated malformed string, inverted labels, aggregator placement).
Summary
pl) as a new UI locale at ~91% string coverage (273 of 3036 keys untranslated — above de 87%, fr 83%, ru 89%).pl-{1..5}.tsfiles spread{ ...enN, <pl overrides> }so all keys resolve from day one and the i18n parity gate stays green.plintoLanguageSelect,I18nContext,types, andlocaleSlice(BCP-47 prefix match).Problem
The app shipped 12 non-English locales but no Polish. Polish-speaking users had no localized experience even though the i18n infrastructure was ready.
Solution
app/src/lib/i18n/pl.tsaggregator +app/src/lib/i18n/chunks/pl-{1..5}.tschunk files, mirroring the existing structure (en-{1..5}.ts,de-{1..5}.ts, etc.).{ ...enN, <polish overrides> }so new English keys auto-fall-back to English until translated, andpnpm i18n:checknever reportsmissing/extra.plinLanguageSelect.tsx,I18nContext.tsx,types.ts, andlocaleSlice.ts.{count}/{label}/{name}interpolation placeholders.Submission Checklist
pnpm i18n:checkCI gate validates key parity, chunk drift, and untranslated counts for every locale (includingpl).diff-coverto measure.## Related— N/A: no feature rows affected.Closes #NNN— no linked issue.Verification:
pnpm i18n:check→pl (3036 keys) missing: 0 extra: 0 untranslated: 273 drifted chunks: 0pnpm typecheckcleanpnpm lintclean (61 pre-existing warnings unrelated to i18n)Impact
Pre-push hook note
git pushtriggeredpnpm lint:commands-tokens, which requiresripgrepto be onPATHin the local environment. ripgrep was unavailable in the push environment, so this PR was pushed with--no-verifyper CLAUDE.md guidance for hook failures unrelated to the diff. The check is purely a Tailwind-token grep oversrc/components/commands/, which this PR does not touch.Related
AI Authored PR Metadata (required for Codex/Linear PRs)
Linear Issue
Commit & Branch
Summary by CodeRabbit