add fr and nl translations (#4587)
* add fr and nl translations * update fr * fix password label translation * translate country strings * fix double accents * fix Ivory Coast * sort countries * use more performant Collator over localeCompare Co-authored-by: Jeremy Letto <jeremy.letto@datasite.com>
This commit is contained in:
parent
f5b973e15c
commit
21f7dd5eba
13 changed files with 555 additions and 279 deletions
|
@ -66,10 +66,20 @@ async function createI18NDefault() {
|
||||||
const files = getAllFiles(ROOT_DIR, i18nFileRegex);
|
const files = getAllFiles(ROOT_DIR, i18nFileRegex);
|
||||||
const allJson = await Promise.all(files.map(file => fse.readJson(file)));
|
const allJson = await Promise.all(files.map(file => fse.readJson(file)));
|
||||||
|
|
||||||
const rollup = allJson.reduce((acc, json) => ({
|
const rollup = allJson.reduce((acc, json) => {
|
||||||
|
const newKeys = Object.keys(json);
|
||||||
|
|
||||||
|
newKeys.forEach(key => {
|
||||||
|
if (acc[key]) {
|
||||||
|
throw new Error(`i18n key collision: ${key}\n${JSON.stringify(json)}`);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
return {
|
||||||
...acc,
|
...acc,
|
||||||
...json,
|
...json,
|
||||||
}), {});
|
};
|
||||||
|
}, {});
|
||||||
|
|
||||||
fse.outputFile(i18nDefaultFile, JSON.stringify(rollup));
|
fse.outputFile(i18nDefaultFile, JSON.stringify(rollup));
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
|
@ -1,4 +0,0 @@
|
||||||
{
|
|
||||||
"Common": { "disconnect": "Desconectar"},
|
|
||||||
"LoginContainer": { "title": "Acceso" }
|
|
||||||
}
|
|
1
webclient/public/locales/fr/translation.json
Normal file
1
webclient/public/locales/fr/translation.json
Normal file
|
@ -0,0 +1 @@
|
||||||
|
{"Common":{"language":"Traduire en anglais.","disconnect":"Déconnecter","label":{"confirmPassword":"Confirmer le mot de passe","confirmSure":"Êtes-vous sûr ?","country":"Pays","delete":"Effacer","email":"E-mail","hostName":"Nom d'hôte","hostAddress":"Adresse d'hôte","password":"Mot de passe","passwordAgain":"Mot de passe à nouveau","port":"Port","realName":"Nom réel","saveChanges":"Sauvegarder les changements","token":"Jeton","username":"Nom d'utilisateur"},"validation":{"minChars":"Minimum de {count} {count, plural, one {caractère} other {caractères}} requis","passwordsMustMatch":"Les mots de passe ne correspondent pas.","required":"Requis"}},"KnownHosts":{"label":"Hôte","add":"Ajouter un nouvel hôte","toast":"Hôte {mode, select, created {créé} deleted {effacé} other {édité}} avec succès."},"InitializeContainer":{"title":"LE SAVIEZ-VOUS ?","subtitle":"<1>Cockatrice est géré par des volontaires</1><1>qui aiment les jeux de cartes !</1>"},"LoginContainer":{"header":{"title":"S'identifier","subtitle":"Un jeu de table virtuel multi-plate-forme pour jeux de cartes multijoueurs."},"footer":{"registerPrompt":"Pas encore inscrit ?","registerAction":"Créer un compte","credit":"Cockatrice est un projet open source.","version":"Version"},"content":{"subtitle1":"Jouer à des jeux de cartes multijoueurs en ligne.","subtitle2":"Jeu de table virtuel multi-plate-forme pour jeux de cartes multijoueurs. Gratuit pour toujours."},"toasts":{"passwordResetSuccessToast":"Mot de passe réinitialisé avec succès","accountActivationSuccess":"Compte activé avec succès"}},"UnsupportedContainer":{"title":"Navigateur non supporté","subtitle1":"Veuillez mettre à jour votre navigateur et/ou vérifier vos permissions.","subtitle2":"Note : La navigation privée désactive certaines permissions ou fonctionnalités."},"AccountActivationDialog":{"title":"Activation du compte","subtitle1":"Votre compte n'a pas encore été activé.","subtitle2":"Vous devez fournir le jeton d'activation reçu dans l'e-mail d'activation."},"KnownHostDialog":{"title":"{mode, select, edit {Éditer} other {Ajouter}} un hôte connu","subtitle":"Ajouter un nouvel hôte vous permet de vous connecter à différents serveurs. Entrez les détails ci-dessous dans votre liste d'hôtes."},"RegistrationDialog":{"title":"Créer un nouveau compte"},"RequestPasswordResetDialog":{"title":"Demander une réinitialisation du mot de passe"},"ResetPasswordDialog":{"title":"Réinitialiser le mot de passe"},"AccountActivationForm":{"error":{"failed":"L'activation du compte a échoué."},"label":{"activate":"Activer le compte"}},"KnownHostForm":{"help":"Besoin d'aide pour ajouter un nouvel hôte ?","label":{"add":"Ajouter un hôte","find":"Trouver un hôte"}},"LoginForm":{"label":{"autoConnect":"Connexion automatique","forgot":"Mot de passe oublié","login":"S'identifier","savePassword":"Enregistrer le mot de passe","savedPassword":"Mot de passe enregistré"}},"RegisterForm":{"label":{"register":"S'enregistrer"},"toast":{"registerSuccess":"Enregistrement réussi !"}},"RequestPasswordResetForm":{"error":"La demande de réinitialisation du mot de passe a échoué.","mfaEnabled":"L'authentification multifacteur est activée sur ce serveur.","request":"Réinitialiser jeton","skipRequest":"Je possède déjà un jeton de réinitialisation."},"ResetPasswordForm":{"error":"La réinitialisation du mot de passe a échoué.","label":{"reset":"Réinitialiser le mot de passe"}}}
|
1
webclient/public/locales/nl/translation.json
Normal file
1
webclient/public/locales/nl/translation.json
Normal file
|
@ -0,0 +1 @@
|
||||||
|
{"Common":{"language":"Vertaal naar Nederlands.","disconnect":"Verbinding Verbreken","label":{"confirmPassword":"Wachtwoord Bevestigen","confirmSure":"Weet je het zeker?","country":"Land","delete":"Verwijderen","email":"Email","hostName":"Hostnaam","hostAddress":"Hostaddres","password":"Wachtwoord","passwordAgain":"Wachtwoord Nogmaals","port":"Poort","realName":"Echte Naam","saveChanges":"Wijzigingen Opslaan","token":"Token","username":"Gebruikersnaam"},"validation":{"minChars":"Minimum van {count} {count, plural, one {karakter} other {karakters}} verplicht","passwordsMustMatch":"Wachtwoorden komen niet overeen","required":"Verplicht"}},"KnownHosts":{"label":"Host","add":"Voeg nieuwe host toe","toast":"Host {mode, select created {toegevoegd} deleted {verwijderd} other {aangepast}}."},"InitializeContainer":{"title":"WIST JE DAT","subtitle":"<1>Cockatrice word gerund door vrijwilligers</1><1>die van kaartspellen houden!</1>"},"LoginContainer":{"header":{"title":"Login","subtitle":"Een cross-platform virtual tabletop voor multiplayer kaartspellen."},"footer":{"registerPrompt":"Nog niet geregistreerd?","registerAction":"Maak een account aan","credit":"Cockatrice is een open source project","version":"Versie"},"content":{"subtitle1":"Speel multiplayer kaartspellen online.","subtitle2":"Cross-platform virtual tabletop voor multiplayer kaartspellen. Gratis en open source."},"toasts":{"passwordResetSuccessToast":"Wachtwoord Opnieuw Ingesteld","accountActivationSuccess":"Account Succesvol Geactiveerd"}},"UnsupportedContainer":{"title":"Niet-ondersteunde Browser","subtitle1":"Update je browser en/of check je instellingen.","subtitle2":"Let op: Private browsing zorgt er voor dat sommige browsers bepaalde toestemmingen of functies uitschakelen."},"AccountActivationDialog":{"title":"Account Activatie","subtitle1":"Je account is nog niet geactiveerd.","subtitle2":"Vul de activerings-token die je hebt ontvangen via de activerings-email in."},"KnownHostDialog":{"title":"{mode, select, edit {Aanpassen} other {Toevoegen}} Bekende Host","subtitle":"Door een nieuwe host toe te voegen kun je verbinden met andere servers. Vul hieronder de gegevens in."},"RegistrationDialog":{"title":"Maak Een Account Aan"},"RequestPasswordResetDialog":{"title":"Opniew Wachtwoord Aanvragen"},"ResetPasswordDialog":{"title":"Vraag Wachtwoord Opnieuw Aan"},"AccountActivationForm":{"error":{"failed":"Activering account mislukt"},"label":{"activate":"Activeer Account"}},"KnownHostForm":{"help":"Hulp nodig met het toevoegen van een nieuwe host?","label":{"add":"Voeg Host Toe","find":"Vind Host"}},"LoginForm":{"label":{"autoConnect":"Verbind Automatisch","forgot":"Wachtwoord Vergeten","login":"Log in","savePassword":"Wachtwoord Opslaan","savedPassword":"Opgeslagen Wachtwoord"}},"RegisterForm":{"label":{"register":"Registreer"},"toast":{"registerSuccess":"Registratie Geslaagd!"}},"RequestPasswordResetForm":{"error":"Opniew wachtwoord aanvragen mislukt","mfaEnabled":"Server heeft multi-factor authenticatie ingeschakeld","request":"Vraag Reset Token Aan","skipRequest":"Ik heb al een reset token"},"ResetPasswordForm":{"error":"Opnieuw wachtwoord aanvragen mislukt","label":{"reset":"Vraag Wachtwoord Opnieuw Aan"}}}
|
|
@ -22,6 +22,258 @@
|
||||||
"minChars": "Minimum of {count} {count, plural, one {character} other {characters}} required",
|
"minChars": "Minimum of {count} {count, plural, one {character} other {characters}} required",
|
||||||
"passwordsMustMatch": "Passwords don't match",
|
"passwordsMustMatch": "Passwords don't match",
|
||||||
"required": "Required"
|
"required": "Required"
|
||||||
|
},
|
||||||
|
"countries": {
|
||||||
|
"AF": "Afghanistan",
|
||||||
|
"AX": "Åland Islands",
|
||||||
|
"AL": "Albania",
|
||||||
|
"DZ": "Algeria",
|
||||||
|
"AS": "American Samoa",
|
||||||
|
"AD": "Andorra",
|
||||||
|
"AO": "Angola",
|
||||||
|
"AI": "Anguilla",
|
||||||
|
"AQ": "Antarctica",
|
||||||
|
"AG": "Antigua and Barbuda",
|
||||||
|
"AR": "Argentina",
|
||||||
|
"AM": "Armenia",
|
||||||
|
"AW": "Aruba",
|
||||||
|
"AU": "Australia",
|
||||||
|
"AT": "Austria",
|
||||||
|
"AZ": "Azerbaijan",
|
||||||
|
"BH": "Bahrain",
|
||||||
|
"BS": "Bahamas",
|
||||||
|
"BD": "Bangladesh",
|
||||||
|
"BB": "Barbados",
|
||||||
|
"BY": "Belarus",
|
||||||
|
"BE": "Belgium",
|
||||||
|
"BZ": "Belize",
|
||||||
|
"BJ": "Benin",
|
||||||
|
"BM": "Bermuda",
|
||||||
|
"BT": "Bhutan",
|
||||||
|
"BO": "Plurinational State of Bolivia",
|
||||||
|
"BQ": "Sint Eustatius and Saba Bonaire",
|
||||||
|
"BA": "Bosnia and Herzegovina",
|
||||||
|
"BW": "Botswana",
|
||||||
|
"BV": "Bouvet Island",
|
||||||
|
"BR": "Brazil",
|
||||||
|
"IO": "British Indian Ocean Territory",
|
||||||
|
"BN": "Brunei Darussalam",
|
||||||
|
"BG": "Bulgaria",
|
||||||
|
"BF": "Burkina Faso",
|
||||||
|
"BI": "Burundi",
|
||||||
|
"KH": "Cambodia",
|
||||||
|
"CM": "Cameroon",
|
||||||
|
"CA": "Canada",
|
||||||
|
"CV": "Cape Verde",
|
||||||
|
"KY": "Cayman Islands",
|
||||||
|
"CF": "Central African Republic",
|
||||||
|
"TD": "Chad",
|
||||||
|
"CL": "Chile",
|
||||||
|
"CN": "China",
|
||||||
|
"CX": "Christmas Island",
|
||||||
|
"CC": "Cocos (Keeling) Islands",
|
||||||
|
"CO": "Colombia",
|
||||||
|
"KM": "Comoros",
|
||||||
|
"CG": "Congo",
|
||||||
|
"CD": "The Democratic Republic of the Congo",
|
||||||
|
"CK": "Cook Islands",
|
||||||
|
"CR": "Costa Rica",
|
||||||
|
"CI": "Ivory Coast",
|
||||||
|
"HR": "Croatia",
|
||||||
|
"CU": "Cuba",
|
||||||
|
"CW": "Curaçao",
|
||||||
|
"CY": "Cyprus",
|
||||||
|
"CZ": "Czech Republic",
|
||||||
|
"DK": "Denmark",
|
||||||
|
"DJ": "Djibouti",
|
||||||
|
"DM": "Dominica",
|
||||||
|
"DO": "Dominican Republic",
|
||||||
|
"EC": "Ecuador",
|
||||||
|
"EG": "Egypt",
|
||||||
|
"SV": "El Salvador",
|
||||||
|
"GQ": "Equatorial Guinea",
|
||||||
|
"ER": "Eritrea",
|
||||||
|
"EE": "Estonia",
|
||||||
|
"ET": "Ethiopia",
|
||||||
|
"EU": "European Union",
|
||||||
|
"FK": "Falkland Islands (Malvinas)",
|
||||||
|
"FO": "Faroe Islands",
|
||||||
|
"FJ": "Fiji",
|
||||||
|
"FI": "Finland",
|
||||||
|
"FR": "France",
|
||||||
|
"GF": "French Guiana",
|
||||||
|
"PF": "French Polynesia",
|
||||||
|
"TF": "French Southern Territories",
|
||||||
|
"GA": "Gabon",
|
||||||
|
"GM": "Gambia",
|
||||||
|
"GE": "Georgia",
|
||||||
|
"DE": "Germany",
|
||||||
|
"GH": "Ghana",
|
||||||
|
"GI": "Gibraltar",
|
||||||
|
"GR": "Greece",
|
||||||
|
"GL": "Greenland",
|
||||||
|
"GD": "Grenada",
|
||||||
|
"GP": "Guadeloupe",
|
||||||
|
"GU": "Guam",
|
||||||
|
"GT": "Guatemala",
|
||||||
|
"GG": "Guernsey",
|
||||||
|
"GN": "Guinea",
|
||||||
|
"GW": "Guinea-Bissau",
|
||||||
|
"GY": "Guyana",
|
||||||
|
"HT": "Haiti",
|
||||||
|
"HM": "Heard Island and McDonald Islands",
|
||||||
|
"VA": "Holy See (Vatican City State)",
|
||||||
|
"HN": "Honduras",
|
||||||
|
"HK": "Hong Kong",
|
||||||
|
"HU": "Hungary",
|
||||||
|
"IS": "Iceland",
|
||||||
|
"IN": "India",
|
||||||
|
"ID": "Indonesia",
|
||||||
|
"IR": "Islamic Republic of Iran",
|
||||||
|
"IQ": "Iraq",
|
||||||
|
"IE": "Ireland",
|
||||||
|
"IM": "Isle of Man",
|
||||||
|
"IL": "Israel",
|
||||||
|
"IT": "Italy",
|
||||||
|
"JM": "Jamaica",
|
||||||
|
"JP": "Japan",
|
||||||
|
"JE": "Jersey",
|
||||||
|
"JO": "Jordan",
|
||||||
|
"KZ": "Kazakhstan",
|
||||||
|
"KE": "Kenya",
|
||||||
|
"KI": "Kiribati",
|
||||||
|
"KP": "Democratic People's Republic of Korea",
|
||||||
|
"KR": "Republic of Korea",
|
||||||
|
"KW": "Kuwait",
|
||||||
|
"KG": "Kyrgyzstan",
|
||||||
|
"LA": "Lao People's Democratic Republic",
|
||||||
|
"LV": "Latvia",
|
||||||
|
"LB": "Lebanon",
|
||||||
|
"LS": "Lesotho",
|
||||||
|
"LR": "Liberia",
|
||||||
|
"LY": "Libya",
|
||||||
|
"LI": "Liechtenstein",
|
||||||
|
"LT": "Lithuania",
|
||||||
|
"LU": "Luxembourg",
|
||||||
|
"MO": "Macao",
|
||||||
|
"MK": "The Former Yugoslav Republic of Macedonia",
|
||||||
|
"MG": "Madagascar",
|
||||||
|
"MW": "Malawi",
|
||||||
|
"MY": "Malaysia",
|
||||||
|
"MV": "Maldives",
|
||||||
|
"ML": "Mali",
|
||||||
|
"MT": "Malta",
|
||||||
|
"MH": "Marshall Islands",
|
||||||
|
"MQ": "Martinique",
|
||||||
|
"MR": "Mauritania",
|
||||||
|
"MU": "Mauritius",
|
||||||
|
"YT": "Mayotte",
|
||||||
|
"MX": "Mexico",
|
||||||
|
"FM": "Federated States of Micronesia",
|
||||||
|
"MD": "Republic of Moldova",
|
||||||
|
"MC": "Monaco",
|
||||||
|
"MN": "Mongolia",
|
||||||
|
"ME": "Montenegro",
|
||||||
|
"MS": "Montserrat",
|
||||||
|
"MA": "Morocco",
|
||||||
|
"MZ": "Mozambique",
|
||||||
|
"MM": "Myanmar",
|
||||||
|
"NA": "Namibia",
|
||||||
|
"NR": "Nauru",
|
||||||
|
"NP": "Nepal",
|
||||||
|
"NL": "Netherlands",
|
||||||
|
"NC": "New Caledonia",
|
||||||
|
"NZ": "New Zealand",
|
||||||
|
"NI": "Nicaragua",
|
||||||
|
"NE": "Niger",
|
||||||
|
"NG": "Nigeria",
|
||||||
|
"NU": "Niue",
|
||||||
|
"NF": "Norfolk Island",
|
||||||
|
"MP": "Northern Mariana Islands",
|
||||||
|
"NO": "Norway",
|
||||||
|
"OM": "Oman",
|
||||||
|
"PK": "Pakistan",
|
||||||
|
"PW": "Palau",
|
||||||
|
"PS": "State of Palestine",
|
||||||
|
"PA": "Panama",
|
||||||
|
"PG": "Papua New Guinea",
|
||||||
|
"PY": "Paraguay",
|
||||||
|
"PE": "Peru",
|
||||||
|
"PH": "Philippines",
|
||||||
|
"PN": "Pitcairn",
|
||||||
|
"PL": "Poland",
|
||||||
|
"PT": "Portugal",
|
||||||
|
"PR": "Puerto Rico",
|
||||||
|
"QA": "Qatar",
|
||||||
|
"RE": "Réunion",
|
||||||
|
"RO": "Romania",
|
||||||
|
"RU": "Russian Federation",
|
||||||
|
"RW": "Rwanda",
|
||||||
|
"BL": "Saint Barthélemy",
|
||||||
|
"SH": "Ascension and Tristan da Cunha Saint Helena",
|
||||||
|
"KN": "Saint Kitts and Nevis",
|
||||||
|
"LC": "Saint Lucia",
|
||||||
|
"MF": "Saint Martin (French part)",
|
||||||
|
"PM": "Saint Pierre and Miquelon",
|
||||||
|
"VC": "Saint Vincent and the Grenadines",
|
||||||
|
"WS": "Samoa",
|
||||||
|
"SM": "San Marino",
|
||||||
|
"ST": "Sao Tome and Principe",
|
||||||
|
"SA": "Saudi Arabia",
|
||||||
|
"SN": "Senegal",
|
||||||
|
"RS": "Serbia",
|
||||||
|
"SC": "Seychelles",
|
||||||
|
"SL": "Sierra Leone",
|
||||||
|
"SG": "Singapore",
|
||||||
|
"SX": "Sint Maarten (Dutch part)",
|
||||||
|
"SK": "Slovakia",
|
||||||
|
"SI": "Slovenia",
|
||||||
|
"SB": "Solomon Islands",
|
||||||
|
"SO": "Somalia",
|
||||||
|
"ZA": "South Africa",
|
||||||
|
"GS": "South Georgia and the South Sandwich Islands",
|
||||||
|
"SS": "South Sudan",
|
||||||
|
"ES": "Spain",
|
||||||
|
"LK": "Sri Lanka",
|
||||||
|
"SD": "Sudan",
|
||||||
|
"SR": "Suriname",
|
||||||
|
"SJ": "Svalbard and Jan Mayen",
|
||||||
|
"SZ": "Swaziland",
|
||||||
|
"SE": "Sweden",
|
||||||
|
"CH": "Switzerland",
|
||||||
|
"SY": "Syrian Arab Republic",
|
||||||
|
"TW": "Taiwan",
|
||||||
|
"TJ": "Tajikistan",
|
||||||
|
"TZ": "United Republic of Tanzania",
|
||||||
|
"TH": "Thailand",
|
||||||
|
"TL": "Timor-Leste",
|
||||||
|
"TG": "Togo",
|
||||||
|
"TK": "Tokelau",
|
||||||
|
"TO": "Tonga",
|
||||||
|
"TT": "Trinidad and Tobago",
|
||||||
|
"TN": "Tunisia",
|
||||||
|
"TR": "Turkey",
|
||||||
|
"TM": "Turkmenistan",
|
||||||
|
"TC": "Turks and Caicos Islands",
|
||||||
|
"TV": "Tuvalu",
|
||||||
|
"UG": "Uganda",
|
||||||
|
"UA": "Ukraine",
|
||||||
|
"AE": "United Arab Emirates",
|
||||||
|
"GB": "United Kingdom",
|
||||||
|
"US": "United States",
|
||||||
|
"UM": "United States Minor Outlying Islands",
|
||||||
|
"UY": "Uruguay",
|
||||||
|
"UZ": "Uzbekistan",
|
||||||
|
"VU": "Vanuatu",
|
||||||
|
"VE": "Bolivarian Republic of Venezuela",
|
||||||
|
"VN": "Viet Nam",
|
||||||
|
"VG": "British Virgin Islands",
|
||||||
|
"VI": "U.S. Virgin Islands",
|
||||||
|
"WF": "Wallis and Futuna",
|
||||||
|
"EH": "Western Sahara",
|
||||||
|
"YE": "Yemen",
|
||||||
|
"ZM": "Zambia",
|
||||||
|
"ZW": "Zimbabwe"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,15 +3,28 @@ import React, { useEffect, useState } from 'react';
|
||||||
import { Select, MenuItem } from '@material-ui/core';
|
import { Select, MenuItem } from '@material-ui/core';
|
||||||
import FormControl from '@material-ui/core/FormControl';
|
import FormControl from '@material-ui/core/FormControl';
|
||||||
import InputLabel from '@material-ui/core/InputLabel';
|
import InputLabel from '@material-ui/core/InputLabel';
|
||||||
|
import { useTranslation } from 'react-i18next';
|
||||||
|
|
||||||
import { Images } from 'images/Images';
|
import { Images } from 'images/Images';
|
||||||
|
import { CountryCode } from 'types';
|
||||||
|
|
||||||
import './CountryDropdown.css';
|
import './CountryDropdown.css';
|
||||||
import { CountryLabel } from 'types';
|
|
||||||
|
|
||||||
const CountryDropdown = ({ input: { onChange } }) => {
|
const CountryDropdown = ({ input: { onChange } }) => {
|
||||||
const [state, setState] = useState('');
|
const [state, setState] = useState('');
|
||||||
|
const [sortedCountries, setSortedCountries] = useState([]);
|
||||||
|
const { t, i18n } = useTranslation();
|
||||||
|
|
||||||
useEffect(() => onChange(state), [state]);
|
useEffect(() => onChange(state), [state]);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const collator = new Intl.Collator(i18n.language);
|
||||||
|
|
||||||
|
setSortedCountries(Object.keys(CountryCode).sort((a, b) =>
|
||||||
|
collator.compare(t(`Common.countries.${a}`), t(`Common.countries.${b}`))
|
||||||
|
));
|
||||||
|
}, [i18n.language]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<FormControl variant='outlined' className='CountryDropdown'>
|
<FormControl variant='outlined' className='CountryDropdown'>
|
||||||
<InputLabel id='CountryDropdown-select'>Country</InputLabel>
|
<InputLabel id='CountryDropdown-select'>Country</InputLabel>
|
||||||
|
@ -31,11 +44,11 @@ const CountryDropdown = ({ input: { onChange } }) => {
|
||||||
</MenuItem>
|
</MenuItem>
|
||||||
|
|
||||||
{
|
{
|
||||||
Object.keys(CountryLabel).map((country, index:number) => (
|
sortedCountries.map((country, index:number) => (
|
||||||
<MenuItem value={country} key={index}>
|
<MenuItem value={country} key={index}>
|
||||||
<div className="CountryDropdown-item">
|
<div className="CountryDropdown-item">
|
||||||
<img className="CountryDropdown-item__image" src={Images.Countries[country.toLowerCase()]} alt={CountryLabel[country]} />
|
<img className="CountryDropdown-item__image" src={Images.Countries[country.toLowerCase()]} />
|
||||||
<span className="CountryDropdown-item__label">{CountryLabel[country.toUpperCase()] || country.toUpperCase()}</span>
|
<span className="CountryDropdown-item__label">{t(`Common.countries.${country}`)}</span>
|
||||||
</div>
|
</div>
|
||||||
</MenuItem>
|
</MenuItem>
|
||||||
))
|
))
|
||||||
|
|
|
@ -6,7 +6,7 @@ import FormControl from '@material-ui/core/FormControl';
|
||||||
import InputLabel from '@material-ui/core/InputLabel';
|
import InputLabel from '@material-ui/core/InputLabel';
|
||||||
|
|
||||||
import { Images } from 'images/Images';
|
import { Images } from 'images/Images';
|
||||||
import { CountryLabel, Language, LanguageCountry } from 'types';
|
import { Language, LanguageCountry } from 'types';
|
||||||
|
|
||||||
import './LanguageDropdown.css';
|
import './LanguageDropdown.css';
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ const LanguageDropdown = () => {
|
||||||
return (
|
return (
|
||||||
<MenuItem value={lang} key={lang}>
|
<MenuItem value={lang} key={lang}>
|
||||||
<div className="LanguageDropdown-item">
|
<div className="LanguageDropdown-item">
|
||||||
<img className="LanguageDropdown-item__image" src={Images.Countries[country]} alt={CountryLabel[country]} />
|
<img className="LanguageDropdown-item__image" src={Images.Countries[country]} />
|
||||||
<span className="LanguageDropdown-item__label">{lang}</span>
|
<span className="LanguageDropdown-item__label">{lang}</span>
|
||||||
</div>
|
</div>
|
||||||
</MenuItem>
|
</MenuItem>
|
||||||
|
|
|
@ -19,10 +19,9 @@ const LoginForm = ({ onSubmit, disableSubmitButton, onResetPassword }: LoginForm
|
||||||
const STORED_PASSWORD_LABEL = `* ${t('LoginForm.label.savedPassword')} *`;
|
const STORED_PASSWORD_LABEL = `* ${t('LoginForm.label.savedPassword')} *`;
|
||||||
|
|
||||||
const [host, setHost] = useState(null);
|
const [host, setHost] = useState(null);
|
||||||
const [passwordLabel, setPasswordLabel] = useState(PASSWORD_LABEL);
|
const [useStoredPasswordLabel, setUseStoredPasswordLabel] = useState(false);
|
||||||
const [autoConnect, setAutoConnect] = useAutoConnect();
|
const [autoConnect, setAutoConnect] = useAutoConnect();
|
||||||
|
|
||||||
|
|
||||||
const validate = values => {
|
const validate = values => {
|
||||||
const errors: any = {};
|
const errors: any = {};
|
||||||
|
|
||||||
|
@ -38,7 +37,7 @@ const LoginForm = ({ onSubmit, disableSubmitButton, onResetPassword }: LoginForm
|
||||||
|
|
||||||
const useStoredPassword = (remember, password) => remember && host.hashedPassword && !password;
|
const useStoredPassword = (remember, password) => remember && host.hashedPassword && !password;
|
||||||
const togglePasswordLabel = (useStoredLabel) => {
|
const togglePasswordLabel = (useStoredLabel) => {
|
||||||
setPasswordLabel(useStoredLabel ? STORED_PASSWORD_LABEL : PASSWORD_LABEL);
|
setUseStoredPasswordLabel(useStoredLabel);
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleOnSubmit = ({ userName, ...values }) => {
|
const handleOnSubmit = ({ userName, ...values }) => {
|
||||||
|
@ -120,8 +119,8 @@ const LoginForm = ({ onSubmit, disableSubmitButton, onResetPassword }: LoginForm
|
||||||
</div>
|
</div>
|
||||||
<div className='loginForm-item'>
|
<div className='loginForm-item'>
|
||||||
<Field
|
<Field
|
||||||
label={passwordLabel}
|
label={useStoredPasswordLabel ? STORED_PASSWORD_LABEL : PASSWORD_LABEL}
|
||||||
onFocus={() => setPasswordLabel(PASSWORD_LABEL)}
|
onFocus={() => setUseStoredPasswordLabel(false)}
|
||||||
onBlur={() => togglePasswordLabel(useStoredPassword(values.remember, values.password))}
|
onBlur={() => togglePasswordLabel(useStoredPassword(values.remember, values.password))}
|
||||||
name='password'
|
name='password'
|
||||||
type='password'
|
type='password'
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -17,9 +17,9 @@ i18n
|
||||||
.use(initReactI18next)
|
.use(initReactI18next)
|
||||||
// for all options read: https://www.i18next.com/overview/configuration-options
|
// for all options read: https://www.i18next.com/overview/configuration-options
|
||||||
.init({
|
.init({
|
||||||
fallbackLng: Language['en-US'],
|
fallbackLng: Language['en'],
|
||||||
resources: {
|
resources: {
|
||||||
[Language['en-US']]: { translation },
|
[Language['en']]: { translation },
|
||||||
},
|
},
|
||||||
partialBundledLanguages: true,
|
partialBundledLanguages: true,
|
||||||
|
|
||||||
|
|
|
@ -45,6 +45,8 @@ import ci from './ci.svg';
|
||||||
import ck from './ck.svg';
|
import ck from './ck.svg';
|
||||||
import cl from './cl.svg';
|
import cl from './cl.svg';
|
||||||
import cm from './cm.svg';
|
import cm from './cm.svg';
|
||||||
|
import cn from './cn.svg';
|
||||||
|
import co from './co.svg';
|
||||||
import cr from './cr.svg';
|
import cr from './cr.svg';
|
||||||
import cu from './cu.svg';
|
import cu from './cu.svg';
|
||||||
import cv from './cv.svg';
|
import cv from './cv.svg';
|
||||||
|
@ -295,6 +297,8 @@ export const Countries = {
|
||||||
ck,
|
ck,
|
||||||
cl,
|
cl,
|
||||||
cm,
|
cm,
|
||||||
|
cn,
|
||||||
|
co,
|
||||||
cr,
|
cr,
|
||||||
cu,
|
cu,
|
||||||
cv,
|
cv,
|
||||||
|
|
|
@ -1,252 +1,252 @@
|
||||||
export enum CountryLabel{
|
export enum CountryCode {
|
||||||
'AF'= 'Afghanistan',
|
'AF' = 'AF',
|
||||||
'AX'= 'Åland Islands',
|
'AX' = 'AX',
|
||||||
'AL'= 'Albania',
|
'AL' = 'AL',
|
||||||
'DZ'= 'Algeria',
|
'DZ' = 'DZ',
|
||||||
'AS'= 'American Samoa',
|
'AS' = 'AS',
|
||||||
'AD'= 'Andorra',
|
'AD' = 'AD',
|
||||||
'AO'= 'Angola',
|
'AO' = 'AO',
|
||||||
'AI'= 'Anguilla',
|
'AI' = 'AI',
|
||||||
'AQ'= 'Antarctica',
|
'AQ' = 'AQ',
|
||||||
'AG'= 'Antigua and Barbuda',
|
'AG' = 'AG',
|
||||||
'AR'= 'Argentina',
|
'AR' = 'AR',
|
||||||
'AM'= 'Armenia',
|
'AM' = 'AM',
|
||||||
'AW'= 'Aruba',
|
'AW' = 'AW',
|
||||||
'AU'= 'Australia',
|
'AU' = 'AU',
|
||||||
'AT'= 'Austria',
|
'AT' = 'AT',
|
||||||
'AZ'= 'Azerbaijan',
|
'AZ' = 'AZ',
|
||||||
'BH'= 'Bahrain',
|
'BH' = 'BH',
|
||||||
'BS'= 'Bahamas',
|
'BS' = 'BS',
|
||||||
'BD'= 'Bangladesh',
|
'BD' = 'BD',
|
||||||
'BB'= 'Barbados',
|
'BB' = 'BB',
|
||||||
'BY'= 'Belarus',
|
'BY' = 'BY',
|
||||||
'BE'= 'Belgium',
|
'BE' = 'BE',
|
||||||
'BZ'= 'Belize',
|
'BZ' = 'BZ',
|
||||||
'BJ'= 'Benin',
|
'BJ' = 'BJ',
|
||||||
'BM'= 'Bermuda',
|
'BM' = 'BM',
|
||||||
'BT'= 'Bhutan',
|
'BT' = 'BT',
|
||||||
'BO'= 'Plurinational State of Bolivia',
|
'BO' = 'BO',
|
||||||
'BQ'= 'Sint Eustatius and Saba Bonaire',
|
'BQ' = 'BQ',
|
||||||
'BA'= 'Bosnia and Herzegovina',
|
'BA' = 'BA',
|
||||||
'BW'= 'Botswana',
|
'BW' = 'BW',
|
||||||
'BV'= 'Bouvet Island',
|
'BV' = 'BV',
|
||||||
'BR'= 'Brazil',
|
'BR' = 'BR',
|
||||||
'IO'= 'British Indian Ocean Territory',
|
'IO' = 'IO',
|
||||||
'BN'= 'Brunei Darussalam',
|
'BN' = 'BN',
|
||||||
'BG'= 'Bulgaria',
|
'BG' = 'BG',
|
||||||
'BF'= 'Burkina Faso',
|
'BF' = 'BF',
|
||||||
'BI'= 'Burundi',
|
'BI' = 'BI',
|
||||||
'KH'= 'Cambodia',
|
'KH' = 'KH',
|
||||||
'CM'= 'Cameroon',
|
'CM' = 'CM',
|
||||||
'CA'= 'Canada',
|
'CA' = 'CA',
|
||||||
'CV'= 'Cape Verde',
|
'CV' = 'CV',
|
||||||
'KY'= 'Cayman Islands',
|
'KY' = 'KY',
|
||||||
'CF'= 'Central African Republic',
|
'CF' = 'CF',
|
||||||
'TD'= 'Chad',
|
'TD' = 'TD',
|
||||||
'CL'= 'Chile',
|
'CL' = 'CL',
|
||||||
'CN'= 'China',
|
'CN' = 'CN',
|
||||||
'CX'= 'Christmas Island',
|
'CX' = 'CX',
|
||||||
'CC'= 'Cocos (Keeling) Islands',
|
'CC' = 'CC',
|
||||||
'CO'= 'Colombia',
|
'CO' = 'CO',
|
||||||
'KM'= 'Comoros',
|
'KM' = 'KM',
|
||||||
'CG'= 'Congo',
|
'CG' = 'CG',
|
||||||
'CD'= 'The Democratic Republic of the Congo',
|
'CD' = 'CD',
|
||||||
'CK'= 'Cook Islands',
|
'CK' = 'CK',
|
||||||
'CR'= 'Costa Rica',
|
'CR' = 'CR',
|
||||||
'CI'= 'Côte d\'Ivoire',
|
'CI' = 'CI',
|
||||||
'HR'= 'Croatia',
|
'HR' = 'HR',
|
||||||
'CU'= 'Cuba',
|
'CU' = 'CU',
|
||||||
'CW'= 'Curaçao',
|
'CW' = 'CW',
|
||||||
'CY'= 'Cyprus',
|
'CY' = 'CY',
|
||||||
'CZ'= 'Czech Republic',
|
'CZ' = 'CZ',
|
||||||
'DK'= 'Denmark',
|
'DK' = 'DK',
|
||||||
'DJ'= 'Djibouti',
|
'DJ' = 'DJ',
|
||||||
'DM'= 'Dominica',
|
'DM' = 'DM',
|
||||||
'DO'= 'Dominican Republic',
|
'DO' = 'DO',
|
||||||
'EC'= 'Ecuador',
|
'EC' = 'EC',
|
||||||
'EG'= 'Egypt',
|
'EG' = 'EG',
|
||||||
'SV'= 'El Salvador',
|
'SV' = 'SV',
|
||||||
'GQ'= 'Equatorial Guinea',
|
'GQ' = 'GQ',
|
||||||
'ER'= 'Eritrea',
|
'ER' = 'ER',
|
||||||
'EE'= 'Estonia',
|
'EE' = 'EE',
|
||||||
'ET'= 'Ethiopia',
|
'ET' = 'ET',
|
||||||
'EU'= 'European Union',
|
'EU' = 'EU',
|
||||||
'FK'= 'Falkland Islands (Malvinas)',
|
'FK' = 'FK',
|
||||||
'FO'= 'Faroe Islands',
|
'FO' = 'FO',
|
||||||
'FJ'= 'Fiji',
|
'FJ' = 'FJ',
|
||||||
'FI'= 'Finland',
|
'FI' = 'FI',
|
||||||
'FR'= 'France',
|
'FR' = 'FR',
|
||||||
'GF'= 'French Guiana',
|
'GF' = 'GF',
|
||||||
'PF'= 'French Polynesia',
|
'PF' = 'PF',
|
||||||
'TF'= 'French Southern Territories',
|
'TF' = 'TF',
|
||||||
'GA'= 'Gabon',
|
'GA' = 'GA',
|
||||||
'GM'= 'Gambia',
|
'GM' = 'GM',
|
||||||
'GE'= 'Georgia',
|
'GE' = 'GE',
|
||||||
'DE'= 'Germany',
|
'DE' = 'DE',
|
||||||
'GH'= 'Ghana',
|
'GH' = 'GH',
|
||||||
'GI'= 'Gibraltar',
|
'GI' = 'GI',
|
||||||
'GR'= 'Greece',
|
'GR' = 'GR',
|
||||||
'GL'= 'Greenland',
|
'GL' = 'GL',
|
||||||
'GD'= 'Grenada',
|
'GD' = 'GD',
|
||||||
'GP'= 'Guadeloupe',
|
'GP' = 'GP',
|
||||||
'GU'= 'Guam',
|
'GU' = 'GU',
|
||||||
'GT'= 'Guatemala',
|
'GT' = 'GT',
|
||||||
'GG'= 'Guernsey',
|
'GG' = 'GG',
|
||||||
'GN'= 'Guinea',
|
'GN' = 'GN',
|
||||||
'GW'= 'Guinea-Bissau',
|
'GW' = 'GW',
|
||||||
'GY'= 'Guyana',
|
'GY' = 'GY',
|
||||||
'HT'= 'Haiti',
|
'HT' = 'HT',
|
||||||
'HM'= 'Heard Island and McDonald Islands',
|
'HM' = 'HM',
|
||||||
'VA'= 'Holy See (Vatican City State)',
|
'VA' = 'VA',
|
||||||
'HN'= 'Honduras',
|
'HN' = 'HN',
|
||||||
'HK'= 'Hong Kong',
|
'HK' = 'HK',
|
||||||
'HU'= 'Hungary',
|
'HU' = 'HU',
|
||||||
'IS'= 'Iceland',
|
'IS' = 'IS',
|
||||||
'IN'= 'India',
|
'IN' = 'IN',
|
||||||
'ID'= 'Indonesia',
|
'ID' = 'ID',
|
||||||
'IR'= 'Islamic Republic of Iran',
|
'IR' = 'IR',
|
||||||
'IQ'= 'Iraq',
|
'IQ' = 'IQ',
|
||||||
'IE'= 'Ireland',
|
'IE' = 'IE',
|
||||||
'IM'= 'Isle of Man',
|
'IM' = 'IM',
|
||||||
'IL'= 'Israel',
|
'IL' = 'IL',
|
||||||
'IT'= 'Italy',
|
'IT' = 'IT',
|
||||||
'JM'= 'Jamaica',
|
'JM' = 'JM',
|
||||||
'JP'= 'Japan',
|
'JP' = 'JP',
|
||||||
'JE'= 'Jersey',
|
'JE' = 'JE',
|
||||||
'JO'= 'Jordan',
|
'JO' = 'JO',
|
||||||
'KZ'= 'Kazakhstan',
|
'KZ' = 'KZ',
|
||||||
'KE'= 'Kenya',
|
'KE' = 'KE',
|
||||||
'KI'= 'Kiribati',
|
'KI' = 'KI',
|
||||||
'KP'= 'Democratic People\'s Republic of Korea',
|
'KP' = 'KP',
|
||||||
'KR'= 'Republic of Korea',
|
'KR' = 'KR',
|
||||||
'KW'= 'Kuwait',
|
'KW' = 'KW',
|
||||||
'KG'= 'Kyrgyzstan',
|
'KG' = 'KG',
|
||||||
'LA'= 'Lao People\'s Democratic Republic',
|
'LA' = 'LA',
|
||||||
'LV'= 'Latvia',
|
'LV' = 'LV',
|
||||||
'LB'= 'Lebanon',
|
'LB' = 'LB',
|
||||||
'LS'= 'Lesotho',
|
'LS' = 'LS',
|
||||||
'LR'= 'Liberia',
|
'LR' = 'LR',
|
||||||
'LY'= 'Libya',
|
'LY' = 'LY',
|
||||||
'LI'= 'Liechtenstein',
|
'LI' = 'LI',
|
||||||
'LT'= 'Lithuania',
|
'LT' = 'LT',
|
||||||
'LU'= 'Luxembourg',
|
'LU' = 'LU',
|
||||||
'MO'= 'Macao',
|
'MO' = 'MO',
|
||||||
'MK'= 'The Former Yugoslav Republic of Macedonia',
|
'MK' = 'MK',
|
||||||
'MG'= 'Madagascar',
|
'MG' = 'MG',
|
||||||
'MW'= 'Malawi',
|
'MW' = 'MW',
|
||||||
'MY'= 'Malaysia',
|
'MY' = 'MY',
|
||||||
'MV'= 'Maldives',
|
'MV' = 'MV',
|
||||||
'ML'= 'Mali',
|
'ML' = 'ML',
|
||||||
'MT'= 'Malta',
|
'MT' = 'MT',
|
||||||
'MH'= 'Marshall Islands',
|
'MH' = 'MH',
|
||||||
'MQ'= 'Martinique',
|
'MQ' = 'MQ',
|
||||||
'MR'= 'Mauritania',
|
'MR' = 'MR',
|
||||||
'MU'= 'Mauritius',
|
'MU' = 'MU',
|
||||||
'YT'= 'Mayotte',
|
'YT' = 'YT',
|
||||||
'MX'= 'Mexico',
|
'MX' = 'MX',
|
||||||
'FM'= 'Federated States of Micronesia',
|
'FM' = 'FM',
|
||||||
'MD'= 'Republic of Moldova',
|
'MD' = 'MD',
|
||||||
'MC'= 'Monaco',
|
'MC' = 'MC',
|
||||||
'MN'= 'Mongolia',
|
'MN' = 'MN',
|
||||||
'ME'= 'Montenegro',
|
'ME' = 'ME',
|
||||||
'MS'= 'Montserrat',
|
'MS' = 'MS',
|
||||||
'MA'= 'Morocco',
|
'MA' = 'MA',
|
||||||
'MZ'= 'Mozambique',
|
'MZ' = 'MZ',
|
||||||
'MM'= 'Myanmar',
|
'MM' = 'MM',
|
||||||
'NA'= 'Namibia',
|
'NA' = 'NA',
|
||||||
'NR'= 'Nauru',
|
'NR' = 'NR',
|
||||||
'NP'= 'Nepal',
|
'NP' = 'NP',
|
||||||
'NL'= 'Netherlands',
|
'NL' = 'NL',
|
||||||
'NC'= 'New Caledonia',
|
'NC' = 'NC',
|
||||||
'NZ'= 'New Zealand',
|
'NZ' = 'NZ',
|
||||||
'NI'= 'Nicaragua',
|
'NI' = 'NI',
|
||||||
'NE'= 'Niger',
|
'NE' = 'NE',
|
||||||
'NG'= 'Nigeria',
|
'NG' = 'NG',
|
||||||
'NU'= 'Niue',
|
'NU' = 'NU',
|
||||||
'NF'= 'Norfolk Island',
|
'NF' = 'NF',
|
||||||
'MP'= 'Northern Mariana Islands',
|
'MP' = 'MP',
|
||||||
'NO'= 'Norway',
|
'NO' = 'NO',
|
||||||
'OM'= 'Oman',
|
'OM' = 'OM',
|
||||||
'PK'= 'Pakistan',
|
'PK' = 'PK',
|
||||||
'PW'= 'Palau',
|
'PW' = 'PW',
|
||||||
'PS'= 'State of Palestine',
|
'PS' = 'PS',
|
||||||
'PA'= 'Panama',
|
'PA' = 'PA',
|
||||||
'PG'= 'Papua New Guinea',
|
'PG' = 'PG',
|
||||||
'PY'= 'Paraguay',
|
'PY' = 'PY',
|
||||||
'PE'= 'Peru',
|
'PE' = 'PE',
|
||||||
'PH'= 'Philippines',
|
'PH' = 'PH',
|
||||||
'PN'= 'Pitcairn',
|
'PN' = 'PN',
|
||||||
'PL'= 'Poland',
|
'PL' = 'PL',
|
||||||
'PT'= 'Portugal',
|
'PT' = 'PT',
|
||||||
'PR'= 'Puerto Rico',
|
'PR' = 'PR',
|
||||||
'QA'= 'Qatar',
|
'QA' = 'QA',
|
||||||
'RE'= 'Réunion',
|
'RE' = 'RE',
|
||||||
'RO'= 'Romania',
|
'RO' = 'RO',
|
||||||
'RU'= 'Russian Federation',
|
'RU' = 'RU',
|
||||||
'RW'= 'Rwanda',
|
'RW' = 'RW',
|
||||||
'BL'= 'Saint Barthélemy',
|
'BL' = 'BL',
|
||||||
'SH'= 'Ascension and Tristan da Cunha Saint Helena',
|
'SH' = 'SH',
|
||||||
'KN'= 'Saint Kitts and Nevis',
|
'KN' = 'KN',
|
||||||
'LC'= 'Saint Lucia',
|
'LC' = 'LC',
|
||||||
'MF'= 'Saint Martin (French part)',
|
'MF' = 'MF',
|
||||||
'PM'= 'Saint Pierre and Miquelon',
|
'PM' = 'PM',
|
||||||
'VC'= 'Saint Vincent and the Grenadines',
|
'VC' = 'VC',
|
||||||
'WS'= 'Samoa',
|
'WS' = 'WS',
|
||||||
'SM'= 'San Marino',
|
'SM' = 'SM',
|
||||||
'ST'= 'Sao Tome and Principe',
|
'ST' = 'ST',
|
||||||
'SA'= 'Saudi Arabia',
|
'SA' = 'SA',
|
||||||
'SN'= 'Senegal',
|
'SN' = 'SN',
|
||||||
'RS'= 'Serbia',
|
'RS' = 'RS',
|
||||||
'SC'= 'Seychelles',
|
'SC' = 'SC',
|
||||||
'SL'= 'Sierra Leone',
|
'SL' = 'SL',
|
||||||
'SG'= 'Singapore',
|
'SG' = 'SG',
|
||||||
'SX'= 'Sint Maarten (Dutch part)',
|
'SX' = 'SX',
|
||||||
'SK'= 'Slovakia',
|
'SK' = 'SK',
|
||||||
'SI'= 'Slovenia',
|
'SI' = 'SI',
|
||||||
'SB'= 'Solomon Islands',
|
'SB' = 'SB',
|
||||||
'SO'= 'Somalia',
|
'SO' = 'SO',
|
||||||
'ZA'= 'South Africa',
|
'ZA' = 'ZA',
|
||||||
'GS'= 'South Georgia and the South Sandwich Islands',
|
'GS' = 'GS',
|
||||||
'SS'= 'South Sudan',
|
'SS' = 'SS',
|
||||||
'ES'= 'Spain',
|
'ES' = 'ES',
|
||||||
'LK'= 'Sri Lanka',
|
'LK' = 'LK',
|
||||||
'SD'= 'Sudan',
|
'SD' = 'SD',
|
||||||
'SR'= 'Suriname',
|
'SR' = 'SR',
|
||||||
'SJ'= 'Svalbard and Jan Mayen',
|
'SJ' = 'SJ',
|
||||||
'SZ'= 'Swaziland',
|
'SZ' = 'SZ',
|
||||||
'SE'= 'Sweden',
|
'SE' = 'SE',
|
||||||
'CH'= 'Switzerland',
|
'CH' = 'CH',
|
||||||
'SY'= 'Syrian Arab Republic',
|
'SY' = 'SY',
|
||||||
'TW'= 'Taiwan',
|
'TW' = 'TW',
|
||||||
'TJ'= 'Tajikistan',
|
'TJ' = 'TJ',
|
||||||
'TZ'= 'United Republic of Tanzania',
|
'TZ' = 'TZ',
|
||||||
'TH'= 'Thailand',
|
'TH' = 'TH',
|
||||||
'TL'= 'Timor-Leste',
|
'TL' = 'TL',
|
||||||
'TG'= 'Togo',
|
'TG' = 'TG',
|
||||||
'TK'= 'Tokelau',
|
'TK' = 'TK',
|
||||||
'TO'= 'Tonga',
|
'TO' = 'TO',
|
||||||
'TT'= 'Trinidad and Tobago',
|
'TT' = 'TT',
|
||||||
'TN'= 'Tunisia',
|
'TN' = 'TN',
|
||||||
'TR'= 'Turkey',
|
'TR' = 'TR',
|
||||||
'TM'= 'Turkmenistan',
|
'TM' = 'TM',
|
||||||
'TC'= 'Turks and Caicos Islands',
|
'TC' = 'TC',
|
||||||
'TV'= 'Tuvalu',
|
'TV' = 'TV',
|
||||||
'UG'= 'Uganda',
|
'UG' = 'UG',
|
||||||
'UA'= 'Ukraine',
|
'UA' = 'UA',
|
||||||
'AE'= 'United Arab Emirates',
|
'AE' = 'AE',
|
||||||
'GB'= 'United Kingdom',
|
'GB' = 'GB',
|
||||||
'US'= 'United States',
|
'US' = 'US',
|
||||||
'UM'= 'United States Minor Outlying Islands',
|
'UM' = 'UM',
|
||||||
'UY'= 'Uruguay',
|
'UY' = 'UY',
|
||||||
'UZ'= 'Uzbekistan',
|
'UZ' = 'UZ',
|
||||||
'VU'= 'Vanuatu',
|
'VU' = 'VU',
|
||||||
'VE'= 'Bolivarian Republic of Venezuela',
|
'VE' = 'VE',
|
||||||
'VN'= 'Viet Nam',
|
'VN' = 'VN',
|
||||||
'VG'= 'British Virgin Islands',
|
'VG' = 'VG',
|
||||||
'VI'= 'U.S. Virgin Islands',
|
'VI' = 'VI',
|
||||||
'WF'= 'Wallis and Futuna',
|
'WF' = 'WF',
|
||||||
'EH'= 'Western Sahara',
|
'EH' = 'EH',
|
||||||
'YE'= 'Yemen',
|
'YE' = 'YE',
|
||||||
'ZM'= 'Zambia',
|
'ZM' = 'ZM',
|
||||||
'ZW'= 'Zimbabwe'
|
'ZW' = 'ZW',
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
import { CountryLabel } from './countries';
|
|
||||||
|
|
||||||
export enum Language {
|
export enum Language {
|
||||||
'en-US' = 'en-US',
|
'en' = 'en',
|
||||||
'es-ES' = 'es-ES',
|
'fr' = 'fr',
|
||||||
|
'nl' = 'nl',
|
||||||
}
|
}
|
||||||
|
|
||||||
export enum LanguageCountry {
|
export enum LanguageCountry {
|
||||||
'en-US' = 'us',
|
'en' = 'us',
|
||||||
'es-ES' = 'es',
|
'fr' = 'fr',
|
||||||
|
'nl' = 'nl',
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue