175 lines
4.7 KiB
TypeScript
175 lines
4.7 KiB
TypeScript
// ---------------------------------------------------------------------------
|
|
import { SuperBlocks } from '../certification-settings';
|
|
/*
|
|
* List of languages with localizations enabled for builds.
|
|
*
|
|
* Client is the UI, and Curriculum is the Challenge Content.
|
|
*
|
|
* An error will be thrown if the CLIENT_LOCALE and CURRICULUM_LOCALE variables
|
|
* from the .env file aren't found in their respective arrays below
|
|
*/
|
|
export const availableLangs = {
|
|
client: [
|
|
'english',
|
|
'espanol',
|
|
'chinese',
|
|
'chinese-traditional',
|
|
'italian',
|
|
'portuguese',
|
|
'ukrainian',
|
|
'japanese'
|
|
],
|
|
curriculum: [
|
|
'english',
|
|
'espanol',
|
|
'chinese',
|
|
'chinese-traditional',
|
|
'italian',
|
|
'portuguese',
|
|
'ukrainian',
|
|
'japanese'
|
|
]
|
|
};
|
|
|
|
/*
|
|
* List of certifications with localization enabled in their world language.
|
|
*
|
|
* These certifications have been approved 100% on Crowdin at least during
|
|
* their launch, and hence meet the QA standard to be published live. Other
|
|
* certifications which have not been audited & approved will fallback to
|
|
* English equivalent.
|
|
*/
|
|
export const auditedCerts = {
|
|
espanol: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis
|
|
],
|
|
chinese: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy
|
|
],
|
|
'chinese-traditional': [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy
|
|
],
|
|
italian: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy
|
|
],
|
|
portuguese: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy,
|
|
SuperBlocks.CodingInterviewPrep,
|
|
SuperBlocks.RelationalDb
|
|
],
|
|
ukrainian: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy,
|
|
SuperBlocks.CodingInterviewPrep,
|
|
SuperBlocks.RelationalDb
|
|
],
|
|
japanese: [
|
|
SuperBlocks.RespWebDesign,
|
|
SuperBlocks.JsAlgoDataStruct,
|
|
SuperBlocks.FrontEndDevLibs,
|
|
SuperBlocks.DataVis,
|
|
SuperBlocks.BackEndDevApis,
|
|
SuperBlocks.QualityAssurance,
|
|
SuperBlocks.SciCompPy,
|
|
SuperBlocks.DataAnalysisPy,
|
|
SuperBlocks.InfoSec,
|
|
SuperBlocks.MachineLearningPy,
|
|
SuperBlocks.CodingInterviewPrep,
|
|
SuperBlocks.RelationalDb
|
|
]
|
|
};
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
// Each client language needs an entry in the rest of the variables below
|
|
|
|
/* These strings set the i18next language. It needs to be the two character
|
|
* string for the language to take advantage of available functionality.
|
|
* Use a 639-1 code here https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes
|
|
*/
|
|
export const i18nextCodes = {
|
|
english: 'en',
|
|
espanol: 'es',
|
|
chinese: 'zh',
|
|
'chinese-traditional': 'zh-Hant',
|
|
italian: 'it',
|
|
portuguese: 'pt-BR',
|
|
ukrainian: 'uk',
|
|
japanese: 'ja'
|
|
};
|
|
|
|
// These are for the language selector dropdown menu in the footer
|
|
export const langDisplayNames = {
|
|
english: 'English',
|
|
espanol: 'Español',
|
|
chinese: '中文(简体字)',
|
|
'chinese-traditional': '中文(繁體字)',
|
|
italian: 'Italiano',
|
|
portuguese: 'Português',
|
|
ukrainian: 'Українська',
|
|
japanese: '日本語'
|
|
};
|
|
|
|
/* These are for formatting dates and numbers. Used with JS .toLocaleString().
|
|
* There's an example in profile/components/Camper.js
|
|
* List: https://github.com/unicode-cldr/cldr-dates-modern/tree/master/main
|
|
*/
|
|
export const langCodes = {
|
|
english: 'en-US',
|
|
espanol: 'es-419',
|
|
chinese: 'zh',
|
|
'chinese-traditional': 'zh-Hant',
|
|
italian: 'it',
|
|
portuguese: 'pt-BR',
|
|
ukrainian: 'uk',
|
|
japanese: 'ja'
|
|
};
|