language selector: translate entries to both native and localized

Languages used to be hardcoded to English, change that to both the
native language plus writing system along with their translation in
the currently selected language.

Signed-off-by: Noel Ullreich <n.ullreich@proxmox.com>
 [ T: drop redundant info from subject and reword a bit ]
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Noel Ullreich 2023-03-23 15:44:24 +01:00 committed by Thomas Lamprecht
parent 5835bc4c10
commit 58518b154e

View File

@ -62,31 +62,31 @@ utilities: {
stateText: gettext('State'),
groupText: gettext('Group'),
language_map: {
ar: 'Arabic',
ca: 'Catalan',
zh_CN: 'Chinese (Simplified)',
zh_TW: 'Chinese (Traditional)',
da: 'Danish',
nl: 'Dutch',
en: 'English',
eu: 'Euskera (Basque)',
fr: 'French',
de: 'German',
he: 'Hebrew',
it: 'Italian',
ja: 'Japanese',
kr: 'Korean',
nb: 'Norwegian (Bokmal)',
nn: 'Norwegian (Nynorsk)',
fa: 'Persian (Farsi)',
pl: 'Polish',
pt_BR: 'Portuguese (Brazil)',
ru: 'Russian',
sl: 'Slovenian',
es: 'Spanish',
sv: 'Swedish',
tr: 'Turkish',
language_map: { //language map is sorted alphabetically by iso 639-1
ar: 'العربية - '+gettext("Arabic"),
ca: 'Català - '+gettext("Catalan"),
da: 'Dansk - '+gettext("Danish"),
de: 'Deutsch - '+gettext("German"),
en: 'English - '+gettext("English"),
es: 'Español - '+gettext("Spanish"),
eu: 'Euskera (Basque) - '+gettext("Euskera (Basque)"),
fa: 'فارسی - '+gettext("Persian (Farsi)"),
fr: 'Français - '+gettext("French"),
he: 'עברית - '+gettext("Hebrew"),
it: 'Italiano - '+gettext("Italian"),
ja: '日本語 - '+gettext("Japanese"),
kr: '한국어 - '+gettext("Korean"),
nb: 'Bokmål - '+gettext("Norwegian (Bokmal)"),
nl: 'Nederlands - '+gettext("Dutch"),
nn: 'Nynorsk - '+gettext("Norwegian (Nynorsk)"),
pl: 'Polski - '+gettext("Polish"),
pt_BR: 'Português Brasileiro - '+gettext("Portuguese (Brazil)"),
ru: 'Русский - '+gettext("Russian"),
sl: 'Slovenščina - '+gettext("Slovenian"),
sv: 'Svenska - '+gettext("Swedish"),
tr: 'Türkçe - '+gettext("Turkish"),
zh_CN: '中文(简体) - '+gettext("Chinese (Simplified)"),
zh_TW: '中文(繁體) - '+gettext("Chinese (Traditional)"),
},
render_language: function(value) {