Skip to content

fix: removed redundant hindi translation file#38917

Open
KumarHarshit3603 wants to merge 6 commits into
RocketChat:developfrom
KumarHarshit3603:hindi-rem
Open

fix: removed redundant hindi translation file#38917
KumarHarshit3603 wants to merge 6 commits into
RocketChat:developfrom
KumarHarshit3603:hindi-rem

Conversation

@KumarHarshit3603
Copy link
Copy Markdown

@KumarHarshit3603 KumarHarshit3603 commented Feb 23, 2026

Issue

In Preferences → Localization → Language, there are two Hindi language options:

  • Hindi
  • Hindi (India)

Out of these, "Hindi" makes very minimal (almost zero) changes and appears to be redundant.


Steps to Test / Reproduce

  1. Go to Preferences → Localization → Language.
  2. Select Hindi.
  3. Observe that only a few words are translated and most of the interface remains unchanged.

Expected Behavior

The localization option should meaningfully translate the interface.


Actual Behavior

The Hindi localization file provides minimal translations and does not significantly change the UI, making it redundant.


Suggested Solution

Remove the redundant Hindi localization and retain Hindi (India), which works correctly and provides proper translations.

23.02.2026_10.36.36_REC.mp4

Fixes #38916

Summary by CodeRabbit

  • Localization
    • Added region-specific Hindi locale (hi‑IN) to improve locale matching.
    • Switched Hindi translations to load at runtime rather than bundled; as a result, the packaged Hindi resource was removed and UI will fall back to default strings if translations are not available.

@KumarHarshit3603 KumarHarshit3603 requested review from a team as code owners February 23, 2026 06:02
@dionisio-bot
Copy link
Copy Markdown
Contributor

dionisio-bot Bot commented Feb 23, 2026

Looks like this PR is not ready to merge, because of the following issues:

  • This PR is missing the 'stat: QA assured' label
  • This PR is missing the required milestone or project

Please fix the issues and try again

If you have any trouble, please check the PR guidelines

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Feb 23, 2026

⚠️ No Changeset found

Latest commit: 05cb37e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Feb 23, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b5b4600 and c44a7ca.

📒 Files selected for processing (1)
  • packages/livechat/src/supportedLocales.ts
🚧 Files skipped from review as they are similar to previous changes (1)
  • packages/livechat/src/supportedLocales.ts
📜 Recent review details
⏰ 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: cubic · AI code reviewer

Walkthrough

Migrates Hindi locale usage from the generic hi to the region-specific hi-IN by removing the hi locale file, deleting its static import, and adding hi-IN to the supported locales list. Runtime dynamic loading of translations remains unchanged.

Changes

Cohort / File(s) Summary
i18n initialization
apps/meteor/server/lib/i18n.ts
Removed static import of the hi locale from the unreachable-bundle block; runtime still loads locales dynamically.
Locale resources
packages/i18n/src/locales/hi.i18n.json
Deleted the hi locale JSON file (entire Hindi translations removed).
Supported locales
packages/livechat/src/supportedLocales.ts
Added hi-IN to the supportedLocales array while keeping hi for backwards-compatibility resolution (comment added).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 I hopped through keys and strings with care,
Swapped hi for hi-IN in tidy fare,
A file tucked away, bundles breathe light,
India’s words now step into sight.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR removes the Hindi translation file but adds 'hi-IN' to supportedLocales while keeping 'hi', contradicting the goal of removing the redundant 'Hindi' option entirely from Preferences → Localization → Language. Remove 'hi' from supportedLocales to ensure the redundant 'Hindi' option no longer appears in the language selection, leaving only 'hi-IN' (Hindi India) as intended.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main change: removing a redundant Hindi translation file, which aligns with the primary objective of eliminating the minimally-translating 'Hindi' localization option.
Out of Scope Changes check ✅ Passed All changes (removing the Hindi translation file, updating the import statement, and modifying supportedLocales) are directly related to the objective of removing the redundant Hindi localization option.
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
Contributor

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

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

1 issue found across 3 files

Prompt for AI agents (all issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="packages/livechat/src/supportedLocales.ts">

<violation number="1" location="packages/livechat/src/supportedLocales.ts:27">
P2: Removing `'hi'` from `supportedLocales` breaks existing `hi` language settings: the locale resolver only matches against this list and will now fall back to `en-US` without any aliasing to `hi-IN`, causing Hindi users to lose localized date formatting.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Comment thread packages/livechat/src/supportedLocales.ts
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.

Redundant hindi Translation file

1 participant