Skip to content

fix(i18n): replace hardcoded english strings with translate pipes in …#3319

Open
NotxNoodles wants to merge 1 commit intoopenMF:devfrom
NotxNoodles:fix/hardcoded-strings-receipt
Open

fix(i18n): replace hardcoded english strings with translate pipes in …#3319
NotxNoodles wants to merge 1 commit intoopenMF:devfrom
NotxNoodles:fix/hardcoded-strings-receipt

Conversation

@NotxNoodles
Copy link
Contributor

@NotxNoodles NotxNoodles commented Mar 5, 2026

Description

Replaced 7 hardcoded English strings in the view-reciept.component.html template with translate pipes to fully support internationalization (i18n).

Changes Made:

  • view-reciept.component.html: Replaced the hardcoded "Back" button with the existing labels.buttons.Back key. Replaced the 6 hardcoded error strings in the <ng-template #noData> block with translation keys.
  • en-US.json: Safely added the 7 new translation keys to ensure the error block renders correctly in English:
    • labels.heading.Unable to Load Receipt
    • labels.text.Invalid transaction data
    • labels.text.Missing or incomplete report configuration
    • labels.text.Please contact your system administrator for assistance.
    • labels.text.Report generation service unavailable
    • labels.text.Technical details may be available in the browser console (F12).
    • labels.text.The transaction receipt could not be loaded. This may be due to:

Note: Part of my familiarization with the Angular codebase for GSoC 2026 (MCP AI Assistant).

Related issues and discussion

N/A - Minor i18n cleanup spotted during codebase review.

Screenshots, if any

N/A

Checklist

Please make sure these boxes are checked before submitting your pull request - thanks!

  • If you have multiple commits please combine them into one commit by squashing them.
  • Read and understood the contribution guidelines at web-app/.github/CONTRIBUTING.md.

Summary by CodeRabbit

  • Chores
    • Added localization support to the receipt view. Error messages, system alerts, instructional text, and buttons now support multiple languages through the translation system.

@coderabbitai
Copy link

coderabbitai bot commented Mar 5, 2026

Note

.coderabbit.yaml has unrecognized properties

CodeRabbit is using all valid settings from your configuration. Unrecognized properties (listed below) have been ignored and may indicate typos or deprecated fields that can be removed.

⚠️ Parsing warnings (1)
Validation error: Unrecognized key(s) in object: 'pre_merge_checks'
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 5c4ad5d5-3094-48c9-9a6f-b40f246727ba

📥 Commits

Reviewing files that changed from the base of the PR and between d5c35a6 and 3bd0ee2.

📒 Files selected for processing (2)
  • src/app/savings/savings-account-view/transactions/view-reciept/view-reciept.component.html
  • src/assets/translations/en-US.json

Walkthrough

This change replaces hard-coded English strings with internationalization (i18n) translation keys in a receipt view component's HTML template and adds the corresponding English translations to the translation file. The functionality and control flow remain unchanged; only the content delivery mechanism is updated to support translation.

Changes

Cohort / File(s) Summary
Receipt View Component Template
src/app/savings/savings-account-view/transactions/view-reciept/view-reciept.component.html
Replaced hard-coded UI strings with i18n translation keys for back button label, NoData block heading, list items, and informational messages.
Translation File
src/assets/translations/en-US.json
Added seven new translation entries for receipt view error messages and informational text (Unable to Load Receipt, Invalid transaction data, Missing or incomplete report configuration, Report generation service unavailable, Please contact your system administrator for assistance, Technical details may be available in the browser console, and The transaction receipt could not be loaded message).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

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 PR title accurately describes the primary change: replacing hardcoded English strings with translate pipes for i18n support in the view-receipt component.
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.

❤️ Share

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

Copy link
Collaborator

@alberto-art3ch alberto-art3ch left a comment

Choose a reason for hiding this comment

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

Please add the translation in the other languages

Copy link
Contributor

@IOhacker IOhacker left a comment

Choose a reason for hiding this comment

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

Pending Jira ticket

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.

3 participants