WEB-709 Interest Rate Field Error Messages Not Translated#3137
Conversation
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. Note
|
| Cohort / File(s) | Summary |
|---|---|
Error Message Refactor src/app/products/loan-products/loan-product-stepper/loan-product-terms-step/loan-product-terms-step.component.html |
Unified fragmented mat-error messages into single "is required" phrases for floating rate, differential rate, minimum/default/maximum differential lending rate, and related nominal rate frequency errors. |
Translation Additions (multiple locales) src/assets/translations/{cs-CS,de-DE,en-US,es-CL,es-MX,fr-FR,it-IT,ko-KO,lt-LT,lv-LV,ne-NE,pt-PT,sw-SW}.json |
Added five new inputs keys per file: "Floating rate", "Differential rate", "Minimum interest rate", "Interest rate", and "Maximum interest rate" with localized values. |
Estimated code review effort
🎯 2 (Simple) | ⏱️ ~12 minutes
Possibly related PRs
- WEB-467 Interest rates field allows zero and negative values in loan product creation form #2891: Modifies the same loan-product-terms-step.component.html and translation keys for rate-related inputs — strong overlap.
- WEB-521 fix(i18n): add missing translations and apply translate pipes across … #2934: Broad i18n/localization updates that overlap with added translation keys.
Suggested reviewers
- IOhacker
- alberto-art3ch
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
| Check name | Status | Explanation |
|---|---|---|
| Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. |
| Title check | ✅ Passed | The title 'WEB-709 Interest Rate Field Error Messages Not Translated' clearly and specifically describes the main change: adding translations for interest rate field error messages across supported language files. |
| 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.
✨ Finishing touches
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Post copyable unit tests in a comment
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 @coderabbitai help to get the list of available commands and usage tips.
There was a problem hiding this comment.
Actionable comments posted: 4
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
src/app/products/loan-products/loan-product-stepper/loan-product-terms-step/loan-product-terms-step.component.html (1)
252-294:⚠️ Potential issue | 🟡 MinorKeep translation keys consistent between labels and error text.
Line 252/265 use “Floating Rate” / “Differential Rate”, while Line 261/268 use lowercase variants. This can yield mismatched wording per locale and forces duplicate translations. Prefer reusing the same keys for both label and error.
🔧 Suggested change (reuse label keys)
- {{ 'labels.inputs.Floating rate' | translate }} {{ 'labels.commons.is required' | translate }} + {{ 'labels.inputs.Floating Rate' | translate }} {{ 'labels.commons.is required' | translate }} - {{ 'labels.inputs.Differential rate' | translate }} {{ 'labels.commons.is required' | translate }} + {{ 'labels.inputs.Differential Rate' | translate }} {{ 'labels.commons.is required' | translate }}
🤖 Fix all issues with AI agents
In `@src/assets/translations/cs-CS.json`:
- Around line 1300-1304: The translation for the key "Differential rate" is
inconsistent with the existing "Differential Rate" entry—update the new key
"Differential rate" so its Czech value matches the existing translation
("Diferenční sazba") used for "Differential Rate" (or alternatively standardize
both keys to use the same Czech string), ensuring consistency between the
"Differential rate" and "Differential Rate" entries.
In `@src/assets/translations/ko-KO.json`:
- Around line 1302-1306: The five new i18n keys ("Floating rate", "Differential
rate", "Minimum interest rate", "Interest rate", "Maximum interest rate") in
ko-KO.json are not referenced by any component; either remove them if they
duplicate existing keys (e.g., "Floating Interest Rate" and "Interest Rate") or
update the components to use these exact keys; search for usages of these keys
in components and if they are intentional placeholders, add a short comment in
the translations file documenting that they are reserved for future UI fields
and keep only one canonical key for each concept (e.g., consolidate "Interest
rate" with existing "Interest Rate" to avoid duplicates).
In `@src/assets/translations/lt-LT.json`:
- Around line 1299-1303: The Lithuanian values for the keys "Floating rate" and
"Differential rate" are inconsistent with established UI terminology; update the
translations for "Floating rate" -> "Slankioji norma" and "Differential rate" ->
"Diferencinis tarifas" (so they align with existing keys like "Interest rate",
"Minimum interest rate", "Maximum interest rate") to ensure label/error text
consistency across the UI.
In `@src/assets/translations/sw-SW.json`:
- Around line 1298-1302: The Swahili strings for the keys "Floating rate",
"Differential rate", "Minimum interest rate", "Interest rate", and "Maximum
interest rate" use wording/casing inconsistent with existing translations;
locate the previously used translations for "Floating Rate", "Differential Rate"
and "Interest Rate" in the same translations file and replace these entries so
they reuse the exact same Swahili phrasing/capitalization (ensure "Floating
rate" and "Differential rate" keys match the established "Floating Rate" /
"Differential Rate" wording and align "Minimum interest rate" / "Maximum
interest rate" to the same "Interest Rate" phrasing style).
🧹 Nitpick comments (2)
src/assets/translations/de-DE.json (1)
1301-1305: Check for duplicate rate keys and harmonize terminology.This file already contains similar keys like “Floating Rate” / “Differential Rate” with slightly different German wording. These new keys differ only by casing and (for “Differential rate”) by terminology, which can lead to inconsistent UI text depending on which key is used. Consider reusing existing keys or aligning translations across all variants.
src/assets/translations/es-MX.json (1)
1300-1304: Keep floating-rate terminology consistent with existing es‑MX strings.Elsewhere in this file, “Floating Rate/Interest Rate” is translated as “Tasa de interés variable” or “Tipo de interés variable.” The new “Tasa flotante” may cause mixed terminology in the UI. Consider aligning to the existing term.
💡 Suggested tweak
- "Floating rate": "Tasa flotante", + "Floating rate": "Tasa de interés variable",
f17af7e to
2d99960
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@src/assets/translations/fr-FR.json`:
- Line 1304: The translation for the key "Floating rate" currently uses "Taux
variable" which conflicts with the existing translation for "Floating Rate"
("Taux flottant"); update the value for the "Floating rate" key to "Taux
flottant" so both keys use the same French term ("Taux flottant") for
consistency across the locale file.
2d99960 to
bb15260
Compare
|
@IOhacker Thank You for the review |
Changed Made :-
-Added localized translations for interest rate field error messages in all supported language files.
WEB-709
Before :-
After :-
Summary by CodeRabbit
New Features
Bug Fixes