Skip to content

i18n(ko): add Korean (한국어) translation - #15863

Merged
yingfeng merged 1 commit into
infiniflow:mainfrom
yooxdb:feat/add-korean-language-support
Jun 11, 2026
Merged

yingfeng merged 1 commit into
infiniflow:mainfrom
yooxdb:feat/add-korean-language-support

Conversation

@yooxdb

@yooxdb yooxdb commented Jun 9, 2026 •

Copy link
Copy Markdown
Contributor

What problem does this PR solve?

  • Add web/src/locales/ko.ts with full Korean translation (~3100 keys)
  • Register Ko = 'ko' in LanguageAbbreviation enum (common.ts)
  • Add [LanguageAbbreviation.Ko]: '한국어' to LanguageAbbreviationMap
  • Add lazy-load entry in web/src/locales/config.ts
  • Add korean key to all existing locale files (ja, id, es, pt-br, vi, zh-traditional)
  • Fix duplicate enum value FileMimeType.Mdx ('text/markdown' → 'text/mdx')

Type of change

  • New Feature (non-breaking change which adds functionality)
  • Other (please describe): Korean (한국어) i18n translation + fix duplicate FileMimeType.Mdx enum value

@dosubot dosubot Bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Jun 9, 2026
@coderabbitai

coderabbitai Bot commented Jun 9, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

This PR adds Korean language support to the application. The core language abbreviation and mapping are registered in constants, the locale loader is configured to lazy-import the Korean locale, and the Korean language name is translated across all supported UI languages.

Changes

Korean Language Support

Layer / File(s) Summary
Language constants and locale registration
web/src/constants/common.ts, web/src/locales/config.ts
Adds Ko abbreviation to LanguageAbbreviation enum, defines LanguageAbbreviationMap[Ko] = '한국어', registers Korean locale import in languageImports, and fixes FileMimeType.Mdx from 'text/markdown' to 'text/mdx'.
Korean language translations across locales
web/src/locales/es.ts, web/src/locales/id.ts, web/src/locales/ja.ts, web/src/locales/pt-br.ts, web/src/locales/vi.ts, web/src/locales/zh-traditional.ts
Adds korean translation key with localized language name labels: Coreano (Spanish), Korea (Indonesian), 韓国語 (Japanese), Coreano (Portuguese Brazil), Tiếng Hàn (Vietnamese), 韓語 (Traditional Chinese).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Suggested labels

🐞 bug

Poem

🐰 A rabbit hops in Korean shoes,
Through locale files with morning dews,
Ko abbreviation takes its place,
While 한국어 shows its face!
Translations bloom in every tongue,
A new language song has been sung. 🌍

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately summarizes the main change: adding Korean (한국어) translation support to the i18n system.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description check ✅ Passed The pull request description covers all required sections with sufficient detail, clearly explaining the problem being solved and categorizing the change type.

✏️ 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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
web/src/constants/common.ts (1)

97-117: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Korean registration is incomplete across language registries.

LanguageAbbreviation/LanguageAbbreviationMap now include Korean, but LanguageList and LanguageMap still omit it. Any UI/path still using those legacy registries won’t expose Korean as selectable.

Suggested fix
 export const LanguageList = [
   'English',
   'Chinese',
   'Traditional Chinese',
   'Russian',
   'Indonesian',
   'Spanish',
   'Vietnamese',
   'Japanese',
+  'Korean',
   'Portuguese BR',
   'German',
   'French',
   'Italian',
   'Bulgarian',
   'Arabic',
   'Turkish',
 ];
 export const LanguageMap = {
   English: 'English',
   Chinese: '简体中文',
   'Traditional Chinese': '繁體中文',
   Russian: 'Русский',
   Indonesian: 'Bahasa Indonesia',
   Indonesia: 'Indonesia',
   Spanish: 'Español',
   Vietnamese: 'Tiếng việt',
   Japanese: '日本語',
+  Korean: '한국어',
   'Portuguese BR': 'Português BR',
   German: 'Deutsch',
   French: 'Français',
   Italian: 'Italiano',
   Bulgarian: 'Български',
   Arabic: 'العربية',
   Turkish: 'Türkçe',
 };
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@web/src/constants/common.ts` around lines 97 - 117, LanguageList and
LanguageMap are missing the new Korean entry so UIs still using those registries
won't show Korean; update both LanguageList and LanguageMap to include an entry
for LanguageAbbreviation.Ko mapped to the display name "한국어" (and ensure any
corresponding value keys use the same enum member LanguageAbbreviation.Ko) so
the legacy registries match LanguageAbbreviation and LanguageAbbreviationMap;
verify components that iterate LanguageList/LanguageMap now surface Korean as
selectable.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Outside diff comments:
In `@web/src/constants/common.ts`:
- Around line 97-117: LanguageList and LanguageMap are missing the new Korean
entry so UIs still using those registries won't show Korean; update both
LanguageList and LanguageMap to include an entry for LanguageAbbreviation.Ko
mapped to the display name "한국어" (and ensure any corresponding value keys use
the same enum member LanguageAbbreviation.Ko) so the legacy registries match
LanguageAbbreviation and LanguageAbbreviationMap; verify components that iterate
LanguageList/LanguageMap now surface Korean as selectable.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e1e04957-5812-46b8-83e4-d1ffa874c997

📥 Commits

Reviewing files that changed from the base of the PR and between 88e4d6b and c057ff2.

📒 Files selected for processing (9)
  • web/src/constants/common.ts
  • web/src/locales/config.ts
  • web/src/locales/es.ts
  • web/src/locales/id.ts
  • web/src/locales/ja.ts
  • web/src/locales/ko.ts
  • web/src/locales/pt-br.ts
  • web/src/locales/vi.ts
  • web/src/locales/zh-traditional.ts

@yingfeng yingfeng added the ci Continue Integration label Jun 9, 2026
@yingfeng
yingfeng marked this pull request as draft June 9, 2026 13:13
@yingfeng
yingfeng marked this pull request as ready for review June 9, 2026 13:13
@codecov

codecov Bot commented Jun 9, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 93.16%. Comparing base (64b860f) to head (c057ff2).
⚠️ Report is 9 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #15863   +/-   ##
=======================================
  Coverage   93.16%   93.16%           
=======================================
  Files          10       10           
  Lines         717      717           
  Branches      118      118           
=======================================
  Hits          668      668           
  Misses         29       29           
  Partials       20       20           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@yingfeng
yingfeng merged commit 49ef959 into infiniflow:main Jun 11, 2026
1 check passed
yingfeng pushed a commit that referenced this pull request Jun 24, 2026
…16203)

### What problem does this PR solve?

This PR follows up on
[#15863](#15863) (Korean i18n)
with translation refinements and i18n coverage for hardcoded strings
found in the UI.

- Refine awkward Korean phrasing (e.g. 'Chunk 만들기' → 'Chunk 생성', '유형' →
'타입', etc.)
- Apply i18n to hardcoded strings in `message-item`,
`next-message-item`, `multi-select`, `chat-prompt-engine`, and various
filter hooks
- Rename `use-selelct-filters.ts` → `use-select-filters.ts` (typo fix)

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
geversite pushed a commit to geversite/ragflow that referenced this pull request Jul 3, 2026
…#16203)

### What problem does this PR solve?

This PR follows up on
[#15863](infiniflow/ragflow#15863) (Korean i18n)
with translation refinements and i18n coverage for hardcoded strings
found in the UI.

- Refine awkward Korean phrasing (e.g. 'Chunk 만들기' → 'Chunk 생성', '유형' →
'타입', etc.)
- Apply i18n to hardcoded strings in `message-item`,
`next-message-item`, `multi-select`, `chat-prompt-engine`, and various
filter hooks
- Rename `use-selelct-filters.ts` → `use-select-filters.ts` (typo fix)

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci Continue Integration size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants