mirror of
https://git.mirrors.martin98.com/https://github.com/infiniflow/ragflow.git
synced 2025-08-14 17:35:53 +08:00
New locale for Bahasa Indonesia support (#3255)
### What problem does this PR solve? Add native translation in locales for Bahasa Indonesia to support new local language ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
parent
cdcbe6c2b3
commit
f45c29360c
@ -39,18 +39,25 @@ export const fileIconMap = {
|
|||||||
xml: 'xml.svg',
|
xml: 'xml.svg',
|
||||||
};
|
};
|
||||||
|
|
||||||
export const LanguageList = ['English', 'Chinese', 'Traditional Chinese'];
|
export const LanguageList = [
|
||||||
|
'English',
|
||||||
|
'Chinese',
|
||||||
|
'Traditional Chinese',
|
||||||
|
'Indonesia',
|
||||||
|
];
|
||||||
|
|
||||||
export const LanguageMap = {
|
export const LanguageMap = {
|
||||||
English: 'English',
|
English: 'English',
|
||||||
Chinese: '简体中文',
|
Chinese: '简体中文',
|
||||||
'Traditional Chinese': '繁體中文',
|
'Traditional Chinese': '繁體中文',
|
||||||
|
Indonesia: 'Indonesia',
|
||||||
};
|
};
|
||||||
|
|
||||||
export const LanguageTranslationMap = {
|
export const LanguageTranslationMap = {
|
||||||
English: 'en',
|
English: 'en',
|
||||||
Chinese: 'zh',
|
Chinese: 'zh',
|
||||||
'Traditional Chinese': 'zh-TRADITIONAL',
|
'Traditional Chinese': 'zh-TRADITIONAL',
|
||||||
|
Indonesia: 'id',
|
||||||
};
|
};
|
||||||
|
|
||||||
export const FileMimeTypeMap = {
|
export const FileMimeTypeMap = {
|
||||||
|
@ -3,13 +3,14 @@ import LanguageDetector from 'i18next-browser-languagedetector';
|
|||||||
import { initReactI18next } from 'react-i18next';
|
import { initReactI18next } from 'react-i18next';
|
||||||
|
|
||||||
import translation_en from './en';
|
import translation_en from './en';
|
||||||
|
import translation_id from './id';
|
||||||
import translation_zh from './zh';
|
import translation_zh from './zh';
|
||||||
import translation_zh_traditional from './zh-traditional';
|
import translation_zh_traditional from './zh-traditional';
|
||||||
|
|
||||||
const resources = {
|
const resources = {
|
||||||
en: translation_en,
|
en: translation_en,
|
||||||
zh: translation_zh,
|
zh: translation_zh,
|
||||||
'zh-TRADITIONAL': translation_zh_traditional,
|
'zh-TRADITIONAL': translation_zh_traditional,
|
||||||
|
id: translation_id,
|
||||||
};
|
};
|
||||||
|
|
||||||
i18n
|
i18n
|
||||||
@ -19,7 +20,7 @@ i18n
|
|||||||
detection: {
|
detection: {
|
||||||
lookupLocalStorage: 'lng',
|
lookupLocalStorage: 'lng',
|
||||||
},
|
},
|
||||||
supportedLngs: ['en', 'zh', 'zh-TRADITIONAL'],
|
supportedLngs: ['en', 'zh', 'zh-TRADITIONAL', 'id'],
|
||||||
resources,
|
resources,
|
||||||
fallbackLng: 'en',
|
fallbackLng: 'en',
|
||||||
interpolation: {
|
interpolation: {
|
||||||
|
1011
web/src/locales/id.ts
Normal file
1011
web/src/locales/id.ts
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user