forked from bwmarrin/discordgo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
locales.go
83 lines (79 loc) · 2.18 KB
/
locales.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
package discordgo
// Locale represents the accepted languages for Discord.
// https://discord.com/developers/docs/reference#locales
type Locale string
// String returns the human-readable string of the locale
func (l Locale) String() string {
if name, ok := Locales[l]; ok {
return name
}
return Unknown.String()
}
// All defined locales in Discord
const (
EnglishUS Locale = "en-US"
EnglishGB Locale = "en-GB"
Bulgarian Locale = "bg"
ChineseCN Locale = "zh-CN"
ChineseTW Locale = "zh-TW"
Croatian Locale = "hr"
Czech Locale = "cs"
Danish Locale = "da"
Dutch Locale = "nl"
Finnish Locale = "fi"
French Locale = "fr"
German Locale = "de"
Greek Locale = "el"
Hindi Locale = "hi"
Hungarian Locale = "hu"
Italian Locale = "it"
Japanese Locale = "ja"
Korean Locale = "ko"
Lithuanian Locale = "lt"
Norwegian Locale = "no"
Polish Locale = "pl"
PortugueseBR Locale = "pt-BR"
Romanian Locale = "ro"
Russian Locale = "ru"
SpanishES Locale = "es-ES"
Swedish Locale = "sv-SE"
Thai Locale = "th"
Turkish Locale = "tr"
Ukrainian Locale = "uk"
Vietnamese Locale = "vi"
Unknown Locale = ""
)
// Locales is a map of all the languages codes to their names.
var Locales = map[Locale]string{
EnglishUS: "English (United States)",
EnglishGB: "English (Great Britain)",
Bulgarian: "Bulgarian",
ChineseCN: "Chinese (China)",
ChineseTW: "Chinese (Taiwan)",
Croatian: "Croatian",
Czech: "Czech",
Danish: "Danish",
Dutch: "Dutch",
Finnish: "Finnish",
French: "French",
German: "German",
Greek: "Greek",
Hindi: "Hindi",
Hungarian: "Hungarian",
Italian: "Italian",
Japanese: "Japanese",
Korean: "Korean",
Lithuanian: "Lithuanian",
Norwegian: "Norwegian",
Polish: "Polish",
PortugueseBR: "Portuguese (Brazil)",
Romanian: "Romanian",
Russian: "Russian",
SpanishES: "Spanish (Spain)",
Swedish: "Swedish",
Thai: "Thai",
Turkish: "Turkish",
Ukrainian: "Ukrainian",
Vietnamese: "Vietnamese",
Unknown: "unknown",
}