feat: support 3 more UI languages (#2218)

Signed-off-by: baihhh <2542274498@qq.com>
This commit is contained in:
Baihhh
2023-08-16 15:54:34 +08:00
committed by GitHub
parent 2ff9020884
commit 47f40c5b24
10 changed files with 3476 additions and 2 deletions

View File

@ -27,6 +27,9 @@ import pt from "./locales/pt/data.json";
import it from "./locales/it/data.json";
import ms from "./locales/ms/data.json";
import tr from "./locales/tr/data.json";
import ar from "./locales/ar/data.json";
import he from "./locales/he/data.json";
import fi from "./locales/fi/data.json";
import * as Conf from "./Conf";
import {initReactI18next} from "react-i18next";
@ -45,6 +48,9 @@ const resources = {
it: it,
ms: ms,
tr: tr,
ar: ar,
he: he,
fi: fi,
};
function initLanguage() {
@ -103,6 +109,15 @@ function initLanguage() {
case "tr":
language = "tr";
break;
case "ar":
language = "ar";
break;
case "he":
language = "he";
break;
case "fi":
language = "fi";
break;
default:
language = Conf.DefaultLanguage;
}