Update language files and fix UI issues
This commit is contained in:
@@ -2,6 +2,7 @@ import i18n from "i18next";
|
||||
import LanguageDetector from "i18next-browser-languagedetector";
|
||||
import { initReactI18next } from "react-i18next";
|
||||
import { en } from "./lang/en";
|
||||
import { ml } from "./lang/ml";
|
||||
|
||||
i18n
|
||||
.use(LanguageDetector)
|
||||
@@ -9,7 +10,8 @@ i18n
|
||||
.init({
|
||||
debug: true,
|
||||
resources: {
|
||||
en: en
|
||||
en: en,
|
||||
ml: ml
|
||||
},
|
||||
fallbackLng: "en",
|
||||
lng: localStorage.getItem("i18nextLng") || "en",
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import option from "@/assets/locale/en/option.json";
|
||||
import optionPlayground from "@/assets/locale/en/option-playground.json";
|
||||
import playground from "@/assets/locale/en/playground.json";
|
||||
import common from "@/assets/locale/en/common.json";
|
||||
|
||||
|
||||
export const en = {
|
||||
option,
|
||||
optionPlayground,
|
||||
playground,
|
||||
common
|
||||
}
|
||||
10
src/i18n/lang/ml.ts
Normal file
10
src/i18n/lang/ml.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import option from "@/assets/locale/ml/option.json";
|
||||
import playground from "@/assets/locale/ml/playground.json";
|
||||
import common from "@/assets/locale/ml/common.json";
|
||||
|
||||
|
||||
export const ml = {
|
||||
option,
|
||||
playground,
|
||||
common
|
||||
}
|
||||
11
src/i18n/support-language.ts
Normal file
11
src/i18n/support-language.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
// Please add new language code to supportLanguage array
|
||||
export const supportLanguage = [
|
||||
{
|
||||
label: "English",
|
||||
value: "en"
|
||||
},
|
||||
{
|
||||
label: "മലയാളം",
|
||||
value: "ml"
|
||||
}
|
||||
]
|
||||
Reference in New Issue
Block a user