-
-
Notifications
You must be signed in to change notification settings - Fork 4
Update frontend/viewer/src/locales #1855
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the 📝 WalkthroughWalkthroughThis change updates localization JSON files for English, Spanish, French, Indonesian, and Korean, adding numerous new translation keys related to audio features, filtering, synchronization, and UI labels. The README for the frontend viewer receives editorial and formatting improvements. No code or functional changes are introduced. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Possibly related PRs
Suggested labels
Suggested reviewers
Poem
✨ Finishing Touches🧪 Generate unit tests
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
UI unit Tests 1 files 38 suites 19s ⏱️ Results for commit 0b0c343. ♻️ This comment has been updated with latest results. |
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
C# Unit Tests126 tests 126 ✅ 12s ⏱️ Results for commit 0b0c343. ♻️ This comment has been updated with latest results. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🧹 Nitpick comments (11)
frontend/viewer/src/locales/en.json (3)
482-493
: Duplicate key differs only by title-case – pick one style
"Citation Form"
was just introduced, but"Citation form"
already exists at lines 471-480. Two almost-identical strings will show up in menus and filters and look like a typo to users. Decide on one canonical label (sentence-case or title-case) and remove the other.- "message": "Citation Form", + "message": "Citation form",
1487-1497
: Same issue for “Lexeme Form” vs “Lexeme form”The new title-case variant duplicates the existing sentence-case key. Align the casing with the earlier entry to avoid UI inconsistency.
- "message": "Lexeme Form", + "message": "Lexeme form",
314-325
: Ambiguous wording “Any Ws”End-users are unlikely to understand what “Ws” means. Spell it out (“Any writing system”) or at least use capital “WS” if that acronym is established in your UI copy guidelines.
frontend/viewer/README.md (3)
5-8
: Convert bare URLs to Markdown links
markdownlint
flags the raw URLs on lines 5-6 (MD034). Wrap them in angle brackets or standard link syntax to silence the linter and improve readability.-We're using a different library here from the lexbox UI. The core lib is https://lingui.dev/ -with a Svelte plugin https://github.com/HenryLie/svelte-i18n-lingui +We're using a different library here from the Lexbox UI. +The core library is <https://lingui.dev/> with a Svelte plugin at <https://github.com/HenryLie/svelte-i18n-lingui>.
20-21
: Avoid casual “If you want” phrasingMinor style nit: replace conversational wording with concise instruction, e.g. “You can then feed those files to an AI translator…”.
37-41
: ShadCN command – keep version pin explicit
pnpx shadcn-svelte@next
will always pull the latest prerelease and may introduce breaking changes. Pin to a known good version (e.g.,@0.6.3
) or document that the project deliberately tracksnext
.frontend/viewer/src/locales/fr.json (3)
82-93
: Prefer French abbreviation “Mo” instead of “MB”.If you leave the translation blank, the UI will fall back to “MB”, which is unfamiliar to many French users.
Proposed quick fix:- "translation": "" + "translation": "{0} Mo"
482-493
: Potential duplicate keys differ only by capitalisation (“Citation form” vs “Citation Form”, “Lexeme form” vs “Lexeme Form”).Unless both variants are required by design, keeping only one prevents accidental inconsistency and eases translators’ work. Double-check in code whether both IDs are actually consumed.
Also applies to: 1475-1497
194-209
: Many new audio / filter strings still untranslated.It’s fine to merge with blanks, but consider at least adding TODO comments in Crowdin/POEditor so translators see the new keys immediately.
Also applies to: 350-361, 646-657, 866-877, 922-945, 1002-1013, 1890-1901, 2398-2409, 2626-2637
frontend/viewer/src/locales/id.json (2)
82-93
: Localise unit abbreviation to “MB” or “MiB” consistently.Indonesian UI sometimes chooses to keep English units. Decide whether you want to keep “MB” or localise (e.g. still “MB”, no full-width space) and set the translation accordingly to avoid fallback logic.
- "translation": "" + "translation": "{0} MB"
482-493
: Duplicate keys with only first-letter case difference.
"Citation form"
/"Citation Form"
and"Lexeme form"
/"Lexeme Form"
appear again. Validate that the UI really needs both—otherwise translators will have to maintain two identical strings.Also applies to: 1475-1497
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (6)
frontend/viewer/README.md
(1 hunks)frontend/viewer/src/locales/en.json
(78 hunks)frontend/viewer/src/locales/es.json
(78 hunks)frontend/viewer/src/locales/fr.json
(79 hunks)frontend/viewer/src/locales/id.json
(78 hunks)frontend/viewer/src/locales/ko.json
(78 hunks)
🧰 Additional context used
🧠 Learnings (7)
📓 Common learnings
Learnt from: myieye
PR: sillsdev/languageforge-lexbox#1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
frontend/viewer/README.md (1)
Learnt from: rmunn
PR: #1836
File: frontend/viewer/src/lib/components/audio/AudioDialog.svelte:25-25
Timestamp: 2025-07-22T09:19:37.386Z
Learning: In the sillsdev/languageforge-lexbox project, when file size limits or other constants need to be shared between C# backend and TypeScript frontend code, prefer exposing them through Reinforced.Typings type generation rather than hardcoding the values separately. This ensures consistency and prevents discrepancies when values change.
frontend/viewer/src/locales/id.json (2)
Learnt from: myieye
PR: #1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
Learnt from: hahn-kev
PR: #1757
File: frontend/viewer/src/lib/components/field-editors/multi-select.svelte:130-136
Timestamp: 2025-06-18T05:13:00.591Z
Learning: In frontend/viewer/src/lib/components/field-editors/multi-select.svelte, the computeCommandScore function from 'bits-ui' handles empty filter strings appropriately and does not hide all options when the filter is empty, contrary to initial analysis assumptions.
frontend/viewer/src/locales/en.json (3)
Learnt from: myieye
PR: #1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
Learnt from: hahn-kev
PR: #1757
File: frontend/viewer/src/lib/components/field-editors/multi-select.svelte:130-136
Timestamp: 2025-06-18T05:13:00.591Z
Learning: In frontend/viewer/src/lib/components/field-editors/multi-select.svelte, the computeCommandScore function from 'bits-ui' handles empty filter strings appropriately and does not hide all options when the filter is empty, contrary to initial analysis assumptions.
Learnt from: rmunn
PR: #1650
File: frontend/src/lib/i18n/locales/en.json:671-681
Timestamp: 2025-05-13T09:50:00.358Z
Learning: The Lexbox project uses the \n\
pattern at the end of lines in JSON locale files to handle multiline strings, where the \n
represents a newline character and the trailing backslash indicates line continuation. Standard JSON validators may flag this as invalid, but it's an established convention in the project that their tooling supports.
frontend/viewer/src/locales/ko.json (2)
Learnt from: myieye
PR: #1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
Learnt from: hahn-kev
PR: #1757
File: frontend/viewer/src/lib/components/field-editors/multi-select.svelte:130-136
Timestamp: 2025-06-18T05:13:00.591Z
Learning: In frontend/viewer/src/lib/components/field-editors/multi-select.svelte, the computeCommandScore function from 'bits-ui' handles empty filter strings appropriately and does not hide all options when the filter is empty, contrary to initial analysis assumptions.
frontend/viewer/src/locales/fr.json (2)
Learnt from: myieye
PR: #1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
Learnt from: hahn-kev
PR: #1757
File: frontend/viewer/src/lib/components/field-editors/multi-select.svelte:130-136
Timestamp: 2025-06-18T05:13:00.591Z
Learning: In frontend/viewer/src/lib/components/field-editors/multi-select.svelte, the computeCommandScore function from 'bits-ui' handles empty filter strings appropriately and does not hide all options when the filter is empty, contrary to initial analysis assumptions.
frontend/viewer/src/locales/es.json (2)
Learnt from: myieye
PR: #1720
File: frontend/viewer/src/locales/es.json:1786-1790
Timestamp: 2025-06-02T14:27:02.745Z
Learning: Spanish locale file (frontend/viewer/src/locales/es.json) contains generated code that may have null line numbers in origin entries due to limitations in the code generation process.
Learnt from: hahn-kev
PR: #1757
File: frontend/viewer/src/lib/components/field-editors/multi-select.svelte:130-136
Timestamp: 2025-06-18T05:13:00.591Z
Learning: In frontend/viewer/src/lib/components/field-editors/multi-select.svelte, the computeCommandScore function from 'bits-ui' handles empty filter strings appropriately and does not hide all options when the filter is empty, contrary to initial analysis assumptions.
🪛 LanguageTool
frontend/viewer/README.md
[style] ~20-~20: This phrasing can be overused. Try elevating your writing with a more formal alternative.
Context: ...update the files under /src/locales/
. If you want, you can then feed those files to an AI...
(IF_YOU_WANT)
🪛 markdownlint-cli2 (0.17.2)
frontend/viewer/README.md
5-5: Bare URL used
(MD034, no-bare-urls)
6-6: Bare URL used
(MD034, no-bare-urls)
⏰ 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). (6)
- GitHub Check: Build UI / publish-ui
- GitHub Check: Build API / publish-api
- GitHub Check: check-and-lint
- GitHub Check: frontend-component-unit-tests
- GitHub Check: frontend
- GitHub Check: Build FW Lite and run tests
🔇 Additional comments (6)
frontend/viewer/src/locales/en.json (4)
2819-2830
: “Writing System(s)” label collision
"Writing System"
(singular) and"Writing Systems"
(plural) make sense, but adding an identical singular string here without context (“Writing System” in a filter vs. a label) risks translators mapping them differently. Consider adding descriptive comments or renaming keys to clarify their usage (e.g."writingSystemFilterLabel"
).
2387-2397
: Redundant size prefix
"Size:"
duplicates information already given by{0} MB
(keyZTysYT
). Unless both are needed in different components, consider removing one to keep the UI minimal.
1400-1409
: Hard-wrapped newline escapes – verify rendering
"Hold to record or\\npress and release to start recording."
embeds an escaped newline. Ensure the consumer component interprets\n
correctly; otherwise the literal “\n” will appear to users.
1675-1777
: Plural-form “audio” strings added – looks goodAll newly added audio-related messages (“Add/Remove/Replace/Save audio”, “No audio”, etc.) are self-consistent and placeholder-free. 👍
frontend/viewer/src/locales/fr.json (1)
146-161
: Fill obvious one-word translations to avoid English fall-backs.Keys like
"Field"
(AXjA78
) and"Filter for"
(BkugWJ
) are trivial to translate (e.g.Champ
,Filtrer par
). Supplying them now prevents mixed-language UI snippets later.frontend/viewer/src/locales/id.json (1)
195-209
: Same untranslated block as French – add at least placeholders.For fast-moving features (audio editor, filters) consider adding Indonesian stubs (
"Tambahkan audio"
,"Buang"
, etc.) to minimise mixed-language UI.Also applies to: 350-361, 646-657, 866-877, 922-945, 1002-1013, 1890-1901, 2398-2409, 2626-2637
taking over this PR as I actually want to change our format to support Crowdin |
No description provided.