feat: add Catalan strings#1049
Conversation
|
No actionable comments were generated in the recent review. 🎉 📜 Recent review detailsConfiguration used: Organization UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used🧠 Learnings (2)📓 Common learnings📚 Learning: 2026-02-16T22:25:35.674ZApplied to files:
⏰ 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)
🔇 Additional comments (2)
📝 WalkthroughWalkthroughAdds Catalan language support and translator credit: updates docs, declares and wires Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related PRs
Suggested reviewers
🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
Actionable comments posted: 3
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
docs/translators.mdlib/I18n/I18nKeys.hlib/I18n/I18nStrings.hlib/I18n/translations/catalan.yaml
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2026-02-16T22:25:35.674Z
Learnt from: whyte-j
Repo: crosspoint-reader/crosspoint-reader PR: 733
File: lib/I18n/I18nKeys.h:271-272
Timestamp: 2026-02-16T22:25:35.674Z
Learning: In the crosspoint-reader i18n system (lib/I18n/), missing translation keys in non-English YAML files are automatically filled with English strings at build time by the gen_i18n.py script. All generated string arrays (STRINGS_EN, STRINGS_ES, etc.) have identical lengths, so runtime array indexing is safe without per-string fallback logic. The system prints "INFO: '{key}' missing in {lang_code}, using English fallback" during code generation when this occurs.
Applied to files:
lib/I18n/I18nStrings.hlib/I18n/translations/catalan.yamllib/I18n/I18nKeys.h
🧬 Code graph analysis (1)
lib/I18n/I18nKeys.h (1)
lib/I18n/I18nStrings.h (1)
i18n_strings(8-21)
⏰ 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: build
🔇 Additional comments (4)
docs/translators.md (1)
37-41: LGTM!The Romanian formatting fix and new Catalan translator entry follow the established pattern for other languages in this file.
lib/I18n/I18nStrings.h (1)
19-19: LGTM!The
STRINGS_CAdeclaration follows the established pattern for other language string arrays and uses the correct ISO 639-1 language code suffix.lib/I18n/I18nKeys.h (1)
17-17: LGTM!The Catalan language support is properly integrated:
- Forward declaration of
STRINGS_CAfollows the existing patternCATALAN = 9enum value is sequential and placed correctly before_COUNTgetStringArrayswitch case correctly returnsi18n_strings::STRINGS_CAAlso applies to: 31-31, 383-384
lib/I18n/translations/catalan.yaml (1)
1-4: LGTM on the file structure and metadata.The metadata correctly identifies Catalan with
_order: "9"matching theCATALAN = 9enum value inI18nKeys.h, and format specifiers (%zu,%d,%.2f%%) are properly preserved throughout the translations.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@lib/I18n/translations/catalan.yaml`:
- Line 267: Fix the typo in the Catalan translation string STR_CALIBRE_DESC by
replacing "tranferències" with the correct spelling "transferències" so the
value becomes "Usa les transferències sense fils de Calibre"; update the
translation entry for STR_CALIBRE_DESC accordingly.
- Line 47: The translation string STR_HOW_CONNECT contains a typo
("conectar-vos"); update its value to use the correct Catalan spelling
"connectar-vos" by editing the STR_HOW_CONNECT entry in
lib/I18n/translations/catalan.yaml so the line reads STR_HOW_CONNECT: "Com voleu
connectar-vos?".
- Line 139: The Catalan translation for STR_CLEAR_CACHE_WARNING_1 has incorrect
gender/number agreement ("tota les dades"); update the string value to use the
feminine plural "totes les dades" so it reads: STR_CLEAR_CACHE_WARNING_1 ->
"Això esborrarà totes les dades de lectura de la memòria cau." Locate
STR_CLEAR_CACHE_WARNING_1 in the translations (catalan.yaml) and replace the
phrase accordingly.
There was a problem hiding this comment.
Actionable comments posted: 2
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
lib/I18n/translations/catalan.yaml
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: whyte-j
Repo: crosspoint-reader/crosspoint-reader PR: 733
File: lib/I18n/I18nKeys.h:271-272
Timestamp: 2026-02-16T22:25:35.674Z
Learning: In the crosspoint-reader i18n system (lib/I18n/), missing translation keys in non-English YAML files are automatically filled with English strings at build time by the gen_i18n.py script. All generated string arrays (STRINGS_EN, STRINGS_ES, etc.) have identical lengths, so runtime array indexing is safe without per-string fallback logic. The system prints "INFO: '{key}' missing in {lang_code}, using English fallback" during code generation when this occurs.
📚 Learning: 2026-02-16T22:25:35.674Z
Learnt from: whyte-j
Repo: crosspoint-reader/crosspoint-reader PR: 733
File: lib/I18n/I18nKeys.h:271-272
Timestamp: 2026-02-16T22:25:35.674Z
Learning: In the crosspoint-reader i18n system (lib/I18n/), missing translation keys in non-English YAML files are automatically filled with English strings at build time by the gen_i18n.py script. All generated string arrays (STRINGS_EN, STRINGS_ES, etc.) have identical lengths, so runtime array indexing is safe without per-string fallback logic. The system prints "INFO: '{key}' missing in {lang_code}, using English fallback" during code generation when this occurs.
Applied to files:
lib/I18n/translations/catalan.yaml
⏰ 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). (2)
- GitHub Check: build
- GitHub Check: cppcheck
🔇 Additional comments (3)
lib/I18n/translations/catalan.yaml (3)
1-3: LGTM!Metadata is correctly defined and aligns with the
Language::CATALAN = 9enum declaration in the header files.
47-47: Previously flagged typos have been corrected.The fixes from commit 1594a42 are confirmed:
- Line 47: "connectar-vos" ✓
- Line 139: "totes les dades" ✓
- Line 267: "transferències" ✓
Also applies to: 139-139, 267-267
35-35: Format string placeholders correctly preserved.The format specifiers (
%zu,%d,%.2f,%%,%s) and escape sequences (\\n) are properly maintained, ensuring runtime string formatting will work correctly.Also applies to: 306-308
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@lib/I18n/translations/catalan.yaml`:
- Line 312: The Catalan translation key STR_UPLOAD_PROMPT uses the informal
"Vols" which is inconsistent with the rest of the prompts; update the value for
STR_UPLOAD_PROMPT to use the formal plural "Voleu" so it reads "Voleu pujar la
posició actual?" to match other keys like "Voleu oblidar" and "Com voleu
connectar-vos?".
- Line 219: The translation value for key STR_SCAN_QR_WIFI_HINT uses
inconsistent capitalization ("Wifi"); update the string to use "WiFi" to match
other occurrences (e.g., change "o escanegeu el codi QR amb el telèfon per
connectar el Wifi." to use "WiFi"), keeping the rest of the sentence identical
and preserving punctuation and YAML quoting.
## Summary * **What is the goal of this PR?** (e.g., Implements the new feature for file uploading.) Add support for Catalan language user interface. * **What changes are included?** A new i18n file catalan.yml. ## Additional Context * Add any other information that might be helpful for the reviewer (e.g., performance implications, potential risks, specific areas to focus on). --- ### AI Usage While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it helps set the right context for reviewers. Did you use AI tools to help write this code? NO
Summary
Add support for Catalan language user interface.
A new i18n file catalan.yml.
Additional Context
specific areas to focus on).
AI Usage
While CrossPoint doesn't have restrictions on AI tools in contributing, please be transparent about their usage as it
helps set the right context for reviewers.
Did you use AI tools to help write this code? NO