2021-12-01 10:50:01 +03:00
|
|
|
// Copyright 2021 The Gitea Authors. All rights reserved.
|
2022-11-27 21:20:29 +03:00
|
|
|
// SPDX-License-Identifier: MIT
|
2021-12-01 10:50:01 +03:00
|
|
|
|
|
|
|
package setting
|
|
|
|
|
|
|
|
// defaultI18nLangNames must be a slice, we need the order
|
|
|
|
var defaultI18nLangNames = []string{
|
|
|
|
"en-US", "English",
|
|
|
|
"zh-CN", "简体中文",
|
|
|
|
"zh-HK", "繁體中文(香港)",
|
|
|
|
"zh-TW", "繁體中文(台灣)",
|
|
|
|
"de-DE", "Deutsch",
|
2022-06-15 13:08:49 +03:00
|
|
|
"fr-FR", "Français",
|
2021-12-01 10:50:01 +03:00
|
|
|
"nl-NL", "Nederlands",
|
2022-06-15 13:08:49 +03:00
|
|
|
"lv-LV", "Latviešu",
|
|
|
|
"ru-RU", "Русский",
|
2021-12-01 10:50:01 +03:00
|
|
|
"uk-UA", "Українська",
|
|
|
|
"ja-JP", "日本語",
|
2022-06-15 13:08:49 +03:00
|
|
|
"es-ES", "Español",
|
|
|
|
"pt-BR", "Português do Brasil",
|
2021-12-01 10:50:01 +03:00
|
|
|
"pt-PT", "Português de Portugal",
|
2022-06-15 13:08:49 +03:00
|
|
|
"pl-PL", "Polski",
|
|
|
|
"bg-BG", "Български",
|
|
|
|
"it-IT", "Italiano",
|
|
|
|
"fi-FI", "Suomi",
|
2021-12-01 10:50:01 +03:00
|
|
|
"tr-TR", "Türkçe",
|
2022-06-15 13:08:49 +03:00
|
|
|
"cs-CZ", "Čeština",
|
|
|
|
"sv-SE", "Svenska",
|
2021-12-01 10:50:01 +03:00
|
|
|
"ko-KR", "한국어",
|
2022-06-15 13:08:49 +03:00
|
|
|
"el-GR", "Ελληνικά",
|
2021-12-01 10:50:01 +03:00
|
|
|
"fa-IR", "فارسی",
|
2022-06-15 13:08:49 +03:00
|
|
|
"hu-HU", "Magyar nyelv",
|
|
|
|
"id-ID", "Bahasa Indonesia",
|
2021-12-01 10:50:01 +03:00
|
|
|
"ml-IN", "മലയാളം",
|
|
|
|
}
|
|
|
|
|
|
|
|
func defaultI18nLangs() (res []string) {
|
|
|
|
for i := 0; i < len(defaultI18nLangNames); i += 2 {
|
|
|
|
res = append(res, defaultI18nLangNames[i])
|
|
|
|
}
|
2022-06-20 13:02:49 +03:00
|
|
|
return res
|
2021-12-01 10:50:01 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
func defaultI18nNames() (res []string) {
|
|
|
|
for i := 0; i < len(defaultI18nLangNames); i += 2 {
|
|
|
|
res = append(res, defaultI18nLangNames[i+1])
|
|
|
|
}
|
2022-06-20 13:02:49 +03:00
|
|
|
return res
|
2021-12-01 10:50:01 +03:00
|
|
|
}
|