Activate PT and EU languages. Add CA and EU Flags.

This commit is contained in:
Reckless_Satoshi 2022-06-29 04:04:43 -07:00
parent db73914cf5
commit 4429b5086c
No known key found for this signature in database
GPG Key ID: 9C4585B561315571
5 changed files with 36 additions and 1 deletions

View File

@ -14,6 +14,9 @@ import SmartToyIcon from '@mui/icons-material/SmartToy';
import PercentIcon from '@mui/icons-material/Percent'; import PercentIcon from '@mui/icons-material/Percent';
import PriceChangeIcon from '@mui/icons-material/PriceChange'; import PriceChangeIcon from '@mui/icons-material/PriceChange';
// Missing flags
import { CataloniaFlag, BasqueCountryFlag} from "./Icons";
import { import {
CommunityDialog, CommunityDialog,
ExchangeSummaryDialog, ExchangeSummaryDialog,
@ -312,8 +315,10 @@ bottomBarDesktop =()=>{
<MenuItem value={'fr'}><div style={{width:24,position:"relative",top:3}}><Flags.FR {...flagProps}/></div>FR</MenuItem> <MenuItem value={'fr'}><div style={{width:24,position:"relative",top:3}}><Flags.FR {...flagProps}/></div>FR</MenuItem>
<MenuItem value={'ru'}><div style={{width:24,position:"relative",top:3}}><Flags.RU {...flagProps}/></div>RU</MenuItem> <MenuItem value={'ru'}><div style={{width:24,position:"relative",top:3}}><Flags.RU {...flagProps}/></div>RU</MenuItem>
<MenuItem value={'it'}><div style={{width:24,position:"relative",top:3}}><Flags.IT {...flagProps}/></div>IT</MenuItem> <MenuItem value={'it'}><div style={{width:24,position:"relative",top:3}}><Flags.IT {...flagProps}/></div>IT</MenuItem>
<MenuItem value={'pt'}><div style={{width:24,position:"relative",top:3}}><Flags.BR {...flagProps}/></div>PT</MenuItem>
<MenuItem disabled={true} value={'zh'}><div style={{width:24,position:"relative",top:3}}><Flags.CN {...flagProps}/></div>ZH</MenuItem> <MenuItem disabled={true} value={'zh'}><div style={{width:24,position:"relative",top:3}}><Flags.CN {...flagProps}/></div>ZH</MenuItem>
<MenuItem value={'ca'}>CAT</MenuItem> <MenuItem value={'ca'}><div style={{width:24,position:"relative",top:3}}><CataloniaFlag {...flagProps}/></div>CA</MenuItem>
<MenuItem value={'eu'}><div style={{width:24,position:"relative",top:3}}><BasqueCountryFlag {...flagProps}/></div>EU</MenuItem>
</Select> </Select>
) )
} }

View File

@ -0,0 +1,12 @@
import React, { Component } from "react";
import { SvgIcon } from "@mui/material"
export default function BasqueCountryFlag(props) {
return (
<SvgIcon {...props} x="0px" y="0px" viewBox="0 0 50 28">
<path d="M0,0 v28 h50 v-28 z" fill="#D52B1E"/>
<path d="M0,0 L50,28 M50,0 L0,28" stroke="#009B48" stroke-width="4.3"/>
<path d="M25,0 v28 M0,14 h50" stroke="#fff" stroke-width="4.3"/>
</SvgIcon>
);
}

View File

@ -0,0 +1,11 @@
import React, { Component } from "react";
import { SvgIcon } from "@mui/material"
export default function CataloniaFlag(props) {
return (
<SvgIcon {...props} x="0px" y="0px" viewBox="0 0 810 540">
<rect width="810" height="540" fill="#FCDD09"/>
<path stroke="#DA121A" stroke-width="60" d="M0,90H810m0,120H0m0,120H810m0,120H0"/>
</SvgIcon>
);
}

View File

@ -14,3 +14,6 @@ export { default as SellSatsIcon } from "./SellSats";
export { default as SendReceiveIcon } from "./SendReceive"; export { default as SendReceiveIcon } from "./SendReceive";
export { default as ExportIcon } from "./Export"; export { default as ExportIcon } from "./Export";
// Some Flags missing on react-flags
export { default as BasqueCountryFlag } from "./BasqueCountryFlag";
export { default as CataloniaFlag } from "./CataloniaFlag";

View File

@ -12,6 +12,8 @@ import translationPL from "../locales/pl.json";
import translationFR from "../locales/fr.json"; import translationFR from "../locales/fr.json";
import translationCA from "../locales/ca.json"; import translationCA from "../locales/ca.json";
import translationIT from "../locales/it.json"; import translationIT from "../locales/it.json";
import translationPT from "../locales/pt.json";
import translationEU from "../locales/eu.json";
i18n i18n
.use(HttpApi) .use(HttpApi)
@ -28,6 +30,8 @@ i18n
fr: {translations: translationFR}, fr: {translations: translationFR},
ca: {translations: translationCA}, ca: {translations: translationCA},
it: {translations: translationIT}, it: {translations: translationIT},
pt: {translations: translationPT},
eu: {translations: translationEU},
}, },
fallbackLng: "en", fallbackLng: "en",