mirror of https://github.com/Chocobozzz/PeerTube
Add esperanto, lojban, klingon and kotava (audio/subtitle) languages
parent
57a81ff649
commit
1d94c15468
|
@ -590,29 +590,34 @@ function buildLanguages () {
|
||||||
|
|
||||||
const languages: { [ id: string ]: string } = {}
|
const languages: { [ id: string ]: string } = {}
|
||||||
|
|
||||||
const signLanguages = [
|
const additionalLanguages = {
|
||||||
'sgn', // Sign languages (macro language)
|
'sgn': true, // Sign languages (macro language)
|
||||||
'ase', // American
|
'ase': true, // American sign language
|
||||||
'sdl', // Arabian
|
'sdl': true, // Arabian sign language
|
||||||
'bfi', // British
|
'bfi': true, // British sign language
|
||||||
'bzs', // Brazilian
|
'bzs': true, // Brazilian sign language
|
||||||
'csl', // Chinese
|
'csl': true, // Chinese sign language
|
||||||
'cse', // Czech
|
'cse': true, // Czech sign language
|
||||||
'dsl', // Danish
|
'dsl': true, // Danish sign language
|
||||||
'fsl', // French
|
'fsl': true, // French sign language
|
||||||
'gsg', // German
|
'gsg': true, // German sign language
|
||||||
'pks', // Pakistan
|
'pks': true, // Pakistan sign language
|
||||||
'jsl', // Japanese
|
'jsl': true, // Japanese sign language
|
||||||
'sfs', // South African
|
'sfs': true, // South African sign language
|
||||||
'swl', // Swedish
|
'swl': true, // Swedish sign language
|
||||||
'rsl' // Russian
|
'rsl': true, // Russian sign language: true
|
||||||
]
|
|
||||||
|
'epo': true, // Esperanto
|
||||||
|
'tlh': true, // Klingon
|
||||||
|
'jbo': true, // Lojban
|
||||||
|
'avk': true // Kotava
|
||||||
|
}
|
||||||
|
|
||||||
// Only add ISO639-1 languages and some sign languages (ISO639-3)
|
// Only add ISO639-1 languages and some sign languages (ISO639-3)
|
||||||
iso639
|
iso639
|
||||||
.filter(l => {
|
.filter(l => {
|
||||||
return (l.iso6391 !== null && l.type === 'living') ||
|
return (l.iso6391 !== null && l.type === 'living') ||
|
||||||
signLanguages.indexOf(l.iso6393) !== -1
|
additionalLanguages[l.iso6393] === true
|
||||||
})
|
})
|
||||||
.forEach(l => languages[l.iso6391 || l.iso6393] = l.name)
|
.forEach(l => languages[l.iso6391 || l.iso6393] = l.name)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue