Skip to content

fix(l10n): New translations#730

Closed
wfcd-bot-boi wants to merge 12 commits into
masterfrom
l10n_master
Closed

fix(l10n): New translations#730
wfcd-bot-boi wants to merge 12 commits into
masterfrom
l10n_master

Conversation

@wfcd-bot-boi
Copy link
Copy Markdown
Collaborator

@wfcd-bot-boi wfcd-bot-boi commented Jan 15, 2026

Summary by CodeRabbit

  • Localization
    • Added localized strings for user feedback functionality (label, error message, submit button) across all supported languages.
    • Added localized strings for app and data translation contribution features.
    • Added localized text for donation descriptions.
    • Updated locale identifiers for Spanish, Portuguese, Serbian, and Chinese to use more specific regional codes.
    • Updated metadata descriptions for translation contribution interface text.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jan 15, 2026

📝 Walkthrough

Walkthrough

This PR adds new translation keys for app translation contributions, data translation contributions, user feedback UI elements, and donation descriptions across 12 localization files. It also updates metadata descriptions, corrects locale tags, and adjusts one translation value in Chinese.

Changes

Cohort / File(s) Summary
Localization additions across all languages
lib/l10n/arb/intl_cs.arb, intl_de.arb, intl_es.arb, intl_fr.arb, intl_it.arb, intl_ko.arb, intl_pl.arb, intl_pt.arb, intl_ru.arb, intl_sr.arb, intl_tr.arb, intl_zh.arb
Added translation keys: contributeAppTranslationsTitle/Description, contributeDataTranslationsTitle/Description, userFeedbackLabelText/ErrorText/SubmitButton, donationDescriptionText with corresponding metadata entries. Updated @contributeTranslationsTitle description across all files from "Title for contribute translations link" to "Description for contribute translations link".
Locale tag corrections
lib/l10n/arb/intl_es.arb, intl_pt.arb, intl_sr.arb, intl_zh.arb
Updated locale identifiers: es → es-ES, pt → pt-BR, sr → sr-CS, zh → zh-CN.
Translation value update
lib/l10n/arb/intl_zh.arb
Changed baroTitle value from "Baro Ki'Teer" to "奸商" (Chinese translation).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • SlayerOrnstein

Poem

🐰 Hop and translate, from east to west! New feedback keys pass the test,
Donations shine, donations bright, locale tags corrected right!
Seven languages, plus four more, translation features we'll adore!

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'fix(l10n): New translations' is vague and doesn't clearly convey what translations were added or modified, using the generic phrase 'New translations' without specificity. Consider a more descriptive title that specifies the localization changes, such as 'fix(l10n): Add user feedback and contribution translations across multiple locales' or 'fix(l10n): Expand translation keys for contributions and feedback'.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Note

Due to the large number of review comments, Critical, Major severity comments were prioritized as inline comments.

🤖 Fix all issues with AI agents
In `@lib/l10n/arb/intl_es.arb`:
- Line 2: The locale declaration in intl_es.arb currently uses "@@locale":
"es-ES", which is inconsistent with the project's single-language locale
convention; change the @@locale value to "es" (i.e., "@@locale": "es") in
intl_es.arb so it aligns with other locales (cs, de, en, fr, it, ko, pl, ru, tr)
and ensures proper matching/fallback for generic and other Spanish variants, or
alternatively add a brief comment/documentation in the same file explaining why
"es-ES" must be used and update the app's locale matching/fallback logic to
account for region-specific tags.
🟡 Minor comments (24)
lib/l10n/arb/intl_es.arb-1309-1328 (1)

1309-1328: New translation keys are not translated to Spanish and contain a typo.

The user feedback and donation keys contain English text. Line 1324: "maintance" → "maintenance".

lib/l10n/arb/intl_fr.arb-1309-1328 (1)

1309-1328: New translation keys are not translated to French and contain a typo.

The keys userFeedbackLabelText, userFeedbackErrorText, userFeedbackSubmitButton, and donationDescriptionText contain English text.

Line 1324: "maintance" → "maintenance".

lib/l10n/arb/intl_fr.arb-399-418 (1)

399-418: New translation keys are not translated to French.

The new keys (contributeAppTranslationsTitle, contributeAppTranslationsDescription, contributeDataTranslationsTitle, contributeDataTranslationsDescription) contain English text. These should be translated to French for this locale file.

lib/l10n/arb/intl_es.arb-399-418 (1)

399-418: New translation keys are not translated to Spanish.

The new contribution-related keys contain English text and should be translated to Spanish.

lib/l10n/arb/intl_pl.arb-399-418 (1)

399-418: New translation keys are not translated to Polish.

These keys (contributeAppTranslationsTitle, contributeAppTranslationsDescription, contributeDataTranslationsTitle, contributeDataTranslationsDescription) contain English text in a Polish locale file. They should be translated to Polish for consistency with the rest of the file.

Additionally, the @contributeAppTranslationsDescription and @contributeDataTranslationsDescription metadata incorrectly use "Title for contribute translations link" as the description, but these are description entries, not titles.

lib/l10n/arb/intl_it.arb-399-418 (1)

399-418: New translation keys are not translated to Italian.

The new contribution-related keys contain English text and should be translated to Italian.

lib/l10n/arb/intl_tr.arb-399-418 (1)

399-418: New translation keys are not translated to Turkish.

The new contribution-related keys contain English text and should be translated to Turkish.

lib/l10n/arb/intl_it.arb-1309-1328 (1)

1309-1328: New translation keys are not translated to Italian and contain a typo.

The user feedback and donation keys contain English text. Line 1324: "maintance" → "maintenance".

lib/l10n/arb/intl_tr.arb-1309-1328 (1)

1309-1328: New translation keys are not translated to Turkish and contain a typo.

The user feedback and donation keys contain English text. Line 1324: "maintance" → "maintenance".

lib/l10n/arb/intl_pl.arb-1309-1328 (1)

1309-1328: New translation keys are not translated to Polish and contain a typo.

The keys userFeedbackLabelText, userFeedbackErrorText, userFeedbackSubmitButton, and donationDescriptionText contain English text in a Polish locale file.

Also, Line 1324 has a typo: "maintance" should be "maintenance".

Proposed fix for the typo
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_cs.arb-399-418 (1)

399-418: Localize the new CS strings (currently English).

These values are still English; please translate or confirm intended fallback.

Also applies to: 1309-1323

lib/l10n/arb/intl_ru.arb-399-418 (1)

399-418: Localize the new RU strings (currently English).

These user-facing values are still English; please translate or confirm that English fallback is intended for RU.

Also applies to: 1309-1323

lib/l10n/arb/intl_pt.arb-399-414 (1)

399-414: Translate new contribute strings to pt-BR.*

These entries are still English; consider localized pt-BR equivalents for consistency.

lib/l10n/arb/intl_zh.arb-399-418 (1)

399-418: Localize the new ZH strings (currently English).

These values are still English; please translate or confirm intended fallback.

Also applies to: 1309-1323

lib/l10n/arb/intl_de.arb-399-418 (1)

399-418: Localize the new DE strings (currently English).

These values are still English; please translate or confirm intended fallback.

Also applies to: 1309-1323

lib/l10n/arb/intl_de.arb-1324-1325 (1)

1324-1325: Fix typo in donation description ("maintance").

✏️ Suggested fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_zh.arb-1324-1325 (1)

1324-1325: Fix typo in donation description ("maintance").

✏️ Suggested fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_cs.arb-1324-1325 (1)

1324-1325: Fix typo in donation description ("maintance").

✏️ Suggested fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_ru.arb-1324-1325 (1)

1324-1325: Fix typo in donation description ("maintance").

✏️ Suggested fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_sr.arb-419-423 (1)

419-423: Metadata description may be incorrect.

The description for @contributeTranslationsTitle was changed to "Description for contribute translations link", but contributeTranslationsTitle is a title entry (line 419). The original description "Title for contribute translations link" appears to have been correct. This change seems to introduce an inconsistency rather than fix one.

lib/l10n/arb/intl_ko.arb-419-423 (1)

419-423: Same metadata description issue as in intl_sr.arb.

The description for @contributeTranslationsTitle was changed to "Description for contribute translations link", but this entry is a title. The original description was likely correct.

lib/l10n/arb/intl_ko.arb-1324-1324 (1)

1324-1324: Same typo: "maintance" should be "maintenance".

This typo appears across multiple locale files in this PR.

Proposed fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_sr.arb-1324-1324 (1)

1324-1324: Typo: "maintance" should be "maintenance".

The text contains a spelling error that will be visible to users.

Proposed fix
-  "donationDescriptionText": "Everything from tech support to supporting app maintance",
+  "donationDescriptionText": "Everything from tech support to supporting app maintenance",
lib/l10n/arb/intl_sr.arb-2-2 (1)

2-2: Update the @@locale tag from the obsolete sr-CS code to sr-RS.

The locale code sr-CS is deprecated per BCP 47 standards because CS (Serbia and Montenegro) is an obsolete ISO 3166 region code. Use sr-RS instead, which is the current standard for Serbian in Serbia.

🧹 Nitpick comments (2)
lib/l10n/arb/intl_sr.arb (1)

405-408: Inconsistent metadata description.

The @contributeAppTranslationsDescription metadata says "description": "Title for contribute translations link", but this is a description entry, not a title. The same issue exists for @contributeDataTranslationsDescription on lines 415-418. Consider updating to "Description for contribute translations link" for consistency.

lib/l10n/arb/intl_ko.arb (1)

399-418: New translation keys are in English, not Korean.

The newly added keys (contributeAppTranslationsTitle, contributeAppTranslationsDescription, contributeDataTranslationsTitle, contributeDataTranslationsDescription) contain English text. If this is intentional as a placeholder pending translation, this is fine. Otherwise, these should be localized to Korean.

Additionally, the metadata descriptions for @contributeAppTranslationsDescription (line 406) and @contributeDataTranslationsDescription (line 416) incorrectly say "Title for contribute translations link" when they should say "Description for...".

📜 Review details

Configuration used: defaults

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f9cefdd and 5941164.

📒 Files selected for processing (12)
  • lib/l10n/arb/intl_cs.arb
  • lib/l10n/arb/intl_de.arb
  • lib/l10n/arb/intl_es.arb
  • lib/l10n/arb/intl_fr.arb
  • lib/l10n/arb/intl_it.arb
  • lib/l10n/arb/intl_ko.arb
  • lib/l10n/arb/intl_pl.arb
  • lib/l10n/arb/intl_pt.arb
  • lib/l10n/arb/intl_ru.arb
  • lib/l10n/arb/intl_sr.arb
  • lib/l10n/arb/intl_tr.arb
  • lib/l10n/arb/intl_zh.arb
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: test / android
🔇 Additional comments (9)
lib/l10n/arb/intl_ru.arb (1)

421-421: Metadata description update looks good.

lib/l10n/arb/intl_pt.arb (3)

421-421: Metadata description update looks good.


1309-1325: LGTM for the new PT feedback/donation strings.


2-2: No action required—the "pt-BR" locale tag is correct and supported.

The Flutter l10n generator accepts hyphenated BCP 47 locale tags. This is confirmed by other locales in the same project (es-ES, zh-CN) that use the same hyphenated format. The @@Locale field inside intl_pt.arb is correctly set to "pt-BR", and localization will load properly for Portuguese (Brazil) users.

lib/l10n/arb/intl_de.arb (1)

421-421: Metadata description update looks good.

lib/l10n/arb/intl_zh.arb (3)

82-82: baroTitle update looks fine.


421-421: Metadata description update looks good.


2-2: The "zh-CN" locale tag format is correctly accepted by Flutter's intl generator. The codebase already uses hyphenated country codes for other locales (es-ES, pt-BR, sr-CS), and Flutter's Locale class natively parses these into language and country components. The locale resolution logic in app_root.dart uses languageCode matching, which correctly handles all hyphenated formats. No changes needed.

lib/l10n/arb/intl_cs.arb (1)

421-421: Metadata description update looks good.

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.

Comment thread lib/l10n/arb/intl_es.arb
@@ -1,5 +1,5 @@
{
"@@locale": "es",
"@@locale": "es-ES",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check if there are other Spanish locale variants in the project
find lib/l10n/arb -name "*intl_es*.arb" 2>/dev/null | sort

# Check for l10n configuration file
find . -maxdepth 2 -name "l10n.yaml" -o -name ".l10nrc" 2>/dev/null

# Check pubspec.yaml for Flutter localization configuration
if [ -f pubspec.yaml ]; then
  echo "=== pubspec.yaml localization section ==="
  cat pubspec.yaml | grep -A 30 "flutter:" | head -40
fi

# Check if intl_es.arb currently has the locale set
echo "=== Current intl_es.arb locale setting ==="
head -5 lib/l10n/arb/intl_es.arb 2>/dev/null

Repository: WFCD/navis

Length of output: 1157


🏁 Script executed:

cat l10n.yaml

Repository: WFCD/navis

Length of output: 193


🏁 Script executed:

# Check the git diff for this file
cd lib/l10n/arb && git diff HEAD~1 intl_es.arb 2>/dev/null | head -50

# Also list all ARB files to see the locale pattern
echo "=== All locale files ===" 
ls -la lib/l10n/arb/intl_*.arb 2>/dev/null | awk '{print $NF}' | xargs -I {} basename {} | sort

Repository: WFCD/navis

Length of output: 78


🏁 Script executed:

# List all files in the l10n directory
echo "=== Files in lib/l10n/arb ===" 
ls -la lib/l10n/arb/ | head -20

# Verify the specific file exists and show its locale
echo "=== intl_es.arb first 10 lines ===" 
head -10 lib/l10n/arb/intl_es.arb

# Check git status for this file
echo "=== Git status for intl_es.arb ===" 
git status lib/l10n/arb/intl_es.arb 2>/dev/null || echo "File status check failed"

# Try to see recent changes to this file
echo "=== Git log for intl_es.arb ===" 
git log --oneline -10 lib/l10n/arb/intl_es.arb 2>/dev/null || echo "Git log failed"

Repository: WFCD/navis

Length of output: 1512


🏁 Script executed:

# Get the current HEAD and show git diff
git diff HEAD lib/l10n/arb/intl_es.arb | head -100

# Also check git show to see what changed
git show HEAD:lib/l10n/arb/intl_es.arb 2>/dev/null | head -10

Repository: WFCD/navis

Length of output: 331


🏁 Script executed:

# Show the previous version
git show HEAD~1:lib/l10n/arb/intl_es.arb 2>/dev/null | head -5

# Show detailed log with changes
git log -p -1 lib/l10n/arb/intl_es.arb 2>/dev/null | head -50

Repository: WFCD/navis

Length of output: 36


🏁 Script executed:

# Check if file was recently added
git log --name-status --oneline lib/l10n/arb/intl_es.arb 2>/dev/null | head -20

# Check the current branch/commit info
git log --oneline -5 2>/dev/null

# Search for any mention of "es" locale in recent changes
git diff --name-only HEAD~5..HEAD 2>/dev/null | grep -i es

Repository: WFCD/navis

Length of output: 204


🏁 Script executed:

# Check the @@locale values in all locale files
for file in lib/l10n/arb/intl_*.arb; do
  locale_code=$(head -3 "$file" | grep '@@locale' | sed 's/.*"@@locale": "\([^"]*\)".*/\1/')
  filename=$(basename "$file")
  echo "$filename: $locale_code"
done

Repository: WFCD/navis

Length of output: 273


🌐 Web query:

Flutter locale matching es-ES vs es fallback behavior

💡 Result:

Short answer

  • Flutter's default resolution picks the best match in this priority: exact (language+script+country), language+script, language+country, language-only, country-only, then the first supportedLocale. So es-ES will resolve to an exact supported Locale('es','ES') if present; otherwise it will fall back to a language-only Locale('es') if that is listed. [1][2]

Notes and recommendations

  • If you need different behavior, provide localeListResolutionCallback/localeResolutionCallback or include both Locale('es') and Locale('es','ES') in supportedLocales (exact match wins). [3][1]

Sources

  • supportedLocales and default matching priority. [1]
  • basicLocaleListResolution (default algorithm details). [2]
  • localeListResolutionCallback / override points. [3]

New Spanish locale file uses es-ES instead of es, breaking locale matching pattern.

The new intl_es.arb file declares @@locale: "es-ES" (Spain-specific Spanish), which is inconsistent with other single-language locales in the project (cs, de, en, fr, it, ko, pl, ru, tr all use just the language code). This inconsistency could cause locale matching issues: users with devices set to generic Spanish (es) or other Spanish variants (e.g., es-MX, es-AR) won't match this region-specific locale and will fall back to English.

Either use es to align with other single-language locales, or document why Spain-specific Spanish is preferred and ensure proper fallback configuration.

🤖 Prompt for AI Agents
In `@lib/l10n/arb/intl_es.arb` at line 2, The locale declaration in intl_es.arb
currently uses "@@locale": "es-ES", which is inconsistent with the project's
single-language locale convention; change the @@locale value to "es" (i.e.,
"@@locale": "es") in intl_es.arb so it aligns with other locales (cs, de, en,
fr, it, ko, pl, ru, tr) and ensures proper matching/fallback for generic and
other Spanish variants, or alternatively add a brief comment/documentation in
the same file explaining why "es-ES" must be used and update the app's locale
matching/fallback logic to account for region-specific tags.

@SlayerOrnstein SlayerOrnstein deleted the l10n_master branch January 16, 2026 13:22
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.

2 participants