Adding bn, ml, and cs langs

This commit is contained in:
Dessalines 2021-09-28 10:56:38 -04:00
parent e14c0c2a47
commit 8a6a8981fc
2 changed files with 18 additions and 0 deletions

View file

@ -1,7 +1,9 @@
import i18next, { i18nTyped } from "i18next";
import { ar } from "./translations/ar";
import { bg } from "./translations/bg";
import { bn } from "./translations/bn";
import { ca } from "./translations/ca";
import { cs } from "./translations/cs";
import { cy } from "./translations/cy";
import { da } from "./translations/da";
import { de } from "./translations/de";
@ -24,6 +26,7 @@ import { ja } from "./translations/ja";
import { ka } from "./translations/ka";
import { km } from "./translations/km";
import { ko } from "./translations/ko";
import { ml } from "./translations/ml";
import { mnc } from "./translations/mnc";
import { nb_NO } from "./translations/nb_NO";
import { nl } from "./translations/nl";
@ -89,6 +92,9 @@ const resources = {
sk,
vi,
pt,
bn,
ml,
cs,
};
function format(value: any, format: any): any {

View file

@ -32,7 +32,9 @@ import markdown_it_sub from "markdown-it-sub";
import markdown_it_sup from "markdown-it-sup";
import moment from "moment";
import "moment/locale/bg";
import "moment/locale/bn";
import "moment/locale/ca";
import "moment/locale/cs";
import "moment/locale/cy";
import "moment/locale/da";
import "moment/locale/de";
@ -54,6 +56,7 @@ import "moment/locale/ja";
import "moment/locale/ka";
import "moment/locale/km";
import "moment/locale/ko";
import "moment/locale/ml";
import "moment/locale/nb";
import "moment/locale/nl";
import "moment/locale/pl";
@ -150,6 +153,9 @@ export const languages = [
{ code: "vi" },
{ code: "pt" },
{ code: "ar" },
{ code: "bn" },
{ code: "ml" },
{ code: "cs" },
];
export const themes = [
@ -515,6 +521,12 @@ export function getMomentLanguage(): string {
lang = "pt";
} else if (lang.startsWith("ar")) {
lang = "ar";
} else if (lang.startsWith("bn")) {
lang = "bn";
} else if (lang.startsWith("ml")) {
lang = "ml";
} else if (lang.startsWith("cs")) {
lang = "cs";
} else {
lang = "en";
}