Add pt lang.

This commit is contained in:
Dessalines 2021-09-02 23:12:08 -04:00
parent 640441169b
commit ad04657f81
2 changed files with 6 additions and 1 deletions

View file

@ -29,6 +29,7 @@ import { nb_NO } from "./translations/nb_NO";
import { nl } from "./translations/nl"; import { nl } from "./translations/nl";
import { oc } from "./translations/oc"; import { oc } from "./translations/oc";
import { pl } from "./translations/pl"; import { pl } from "./translations/pl";
import { pt } from "./translations/pt";
import { pt_BR } from "./translations/pt_BR"; import { pt_BR } from "./translations/pt_BR";
import { ru } from "./translations/ru"; import { ru } from "./translations/ru";
import { sk } from "./translations/sk"; import { sk } from "./translations/sk";
@ -87,6 +88,7 @@ const resources = {
mnc, mnc,
sk, sk,
vi, vi,
pt,
}; };
function format(value: any, format: any): any { function format(value: any, format: any): any {

View file

@ -145,6 +145,7 @@ export const languages = [
{ code: "mnc" }, { code: "mnc" },
{ code: "sk" }, { code: "sk" },
{ code: "vi" }, { code: "vi" },
{ code: "pt" },
]; ];
export const themes = [ export const themes = [
@ -446,7 +447,7 @@ export function getMomentLanguage(): string {
lang = "fa"; lang = "fa";
} else if (lang.startsWith("pl")) { } else if (lang.startsWith("pl")) {
lang = "pl"; lang = "pl";
} else if (lang.startsWith("pt")) { } else if (lang.startsWith("pt_BR")) {
lang = "pt-br"; lang = "pt-br";
} else if (lang.startsWith("ja")) { } else if (lang.startsWith("ja")) {
lang = "ja"; lang = "ja";
@ -496,6 +497,8 @@ export function getMomentLanguage(): string {
lang = "sk"; lang = "sk";
} else if (lang.startsWith("vi")) { } else if (lang.startsWith("vi")) {
lang = "vi"; lang = "vi";
} else if (lang.startsWith("pt")) {
lang = "pt";
} else { } else {
lang = "en"; lang = "en";
} }