worldwide 1.31.2 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/dependabot.yml +30 -1
- data/CHANGELOG.md +22 -0
- data/Gemfile +4 -1
- data/Gemfile.lock +3 -3
- data/data/cldr/likely_subtags.yml +1 -1
- data/data/cldr/locales/en/currencies.yml +4 -0
- data/data/cldr/locales/es/currencies.yml +5 -0
- data/data/cldr/locales/nl/currencies.yml +4 -0
- data/data/cldr/locales/root/currencies.yml +2 -0
- data/data/cldr/locales/sr/calendars.yml +232 -232
- data/data/cldr/locales/sr/characters.yml +5 -4
- data/data/cldr/locales/sr/currencies.yml +1134 -1134
- data/data/cldr/locales/sr/fields.yml +424 -426
- data/data/cldr/locales/sr/languages.yml +508 -508
- data/data/cldr/locales/sr/lists.yml +12 -12
- data/data/cldr/locales/sr/numbers.yml +108 -108
- data/data/cldr/locales/sr/rbnf.yml +123 -123
- data/data/cldr/locales/sr/subdivisions.yml +2478 -2478
- data/data/cldr/locales/sr/territories.yml +294 -294
- data/data/cldr/locales/sr/timezones.yml +765 -765
- data/data/cldr/locales/sr/units.yml +230 -230
- data/data/cldr/locales/sr-Cyrl/calendars.yml +375 -0
- data/data/cldr/locales/sr-Cyrl/characters.yml +12 -1
- data/data/cldr/locales/sr-Cyrl/currencies.yml +1673 -0
- data/data/cldr/locales/sr-Cyrl/delimiters.yml +10 -0
- data/data/cldr/locales/sr-Cyrl/fields.yml +669 -0
- data/data/cldr/locales/sr-Cyrl/languages.yml +511 -0
- data/data/cldr/locales/sr-Cyrl/lists.yml +33 -0
- data/data/cldr/locales/sr-Cyrl/numbers.yml +189 -0
- data/data/cldr/locales/sr-Cyrl/plurals.rb +1 -0
- data/data/cldr/locales/sr-Cyrl/rbnf.yml +288 -0
- data/data/cldr/locales/sr-Cyrl/subdivisions.yml +2481 -0
- data/data/cldr/locales/sr-Cyrl/territories.yml +297 -0
- data/data/cldr/locales/sr-Cyrl/timezones.yml +1537 -0
- data/data/cldr/locales/sr-Cyrl/units.yml +546 -0
- data/data/cldr/parent_locales.yml +2 -1
- data/data/cldr/paths.txt +13 -0
- data/data/other/currency/mappings/codes.yml +3 -0
- data/data/other/currency/mappings/digits.yml +2 -0
- data/data/other/generated/sr-Latn-BA.yml +17 -17
- data/data/other/generated/sr-Latn-ME.yml +15 -15
- data/data/other/generated/sr-Latn-RS.yml +15 -15
- data/data/other/generated/sr-Latn-XK.yml +15 -15
- data/data/other/generated/sr-Latn.yml +15 -15
- data/data/other/generated/sr.yml +73 -73
- data/data/other/hand_translated/sr.yml +15 -0
- data/data/other/paths.txt +1 -0
- data/data/regions/AR.yml +1 -0
- data/data/regions/AT.yml +1 -0
- data/data/regions/BE.yml +1 -0
- data/data/regions/BR.yml +1 -0
- data/data/regions/CH.yml +1 -0
- data/data/regions/CL.yml +1 -0
- data/data/regions/CZ.yml +1 -0
- data/data/regions/ES.yml +1 -0
- data/data/regions/FI.yml +1 -0
- data/data/regions/HU.yml +1 -0
- data/data/regions/MX.yml +1 -0
- data/data/regions/NO.yml +1 -0
- data/data/regions/PA.yml +3 -3
- data/data/regions/PT.yml +1 -0
- data/data/regions/SE.yml +1 -0
- data/data/regions/UY.yml +1 -0
- data/lib/worldwide/locale.rb +20 -23
- data/lib/worldwide/version.rb +1 -1
- data/lib/worldwide/zip.rb +1 -1
- metadata +16 -2
|
@@ -29,13 +29,13 @@ sr-Latn-ME:
|
|
|
29
29
|
default: "%-d.%-m.%Y."
|
|
30
30
|
billing: "%-d.%-m.%Y."
|
|
31
31
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
32
|
-
today_at_time:
|
|
33
|
-
yesterday_at_time:
|
|
34
|
-
tomorrow_at_time:
|
|
35
|
-
on_weekday_at_time:
|
|
36
|
-
on_date_time_current_year: "
|
|
32
|
+
today_at_time: Danas u %02k:%M
|
|
33
|
+
yesterday_at_time: Juče u %02k:%M
|
|
34
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
35
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
36
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
37
37
|
on_date: "%-d. %b %Y."
|
|
38
|
-
ago:
|
|
38
|
+
ago: Pre %{time}
|
|
39
39
|
x_hours_ago:
|
|
40
40
|
few: pre %{count} sata
|
|
41
41
|
one: pre %{count} sata
|
|
@@ -130,13 +130,13 @@ sr-Latn-ME:
|
|
|
130
130
|
short: "%-d. %b %02k:%M"
|
|
131
131
|
billing: "%-d.%-m.%Y."
|
|
132
132
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
133
|
-
today_at_time:
|
|
134
|
-
yesterday_at_time:
|
|
135
|
-
tomorrow_at_time:
|
|
136
|
-
on_weekday_at_time:
|
|
137
|
-
on_date_time_current_year: "
|
|
133
|
+
today_at_time: Danas u %02k:%M
|
|
134
|
+
yesterday_at_time: Juče u %02k:%M
|
|
135
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
136
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
137
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
138
138
|
on_date: "%-d. %b %Y."
|
|
139
|
-
ago:
|
|
139
|
+
ago: Pre %{time}
|
|
140
140
|
x_hours_ago:
|
|
141
141
|
few: pre %{count} sata
|
|
142
142
|
one: pre %{count} sata
|
|
@@ -146,7 +146,7 @@ sr-Latn-ME:
|
|
|
146
146
|
one: pre %{count} minuta
|
|
147
147
|
other: pre %{count} minuta
|
|
148
148
|
cc_expiry_date: "%m/%Y"
|
|
149
|
-
am:
|
|
150
|
-
pm:
|
|
151
|
-
just_now: sada
|
|
149
|
+
am: pre podne
|
|
150
|
+
pm: po podne
|
|
151
|
+
just_now: Upravo sada
|
|
152
152
|
yesterday: juče
|
|
@@ -29,13 +29,13 @@ sr-Latn-RS:
|
|
|
29
29
|
default: "%-d.%-m.%Y."
|
|
30
30
|
billing: "%-d.%-m.%Y."
|
|
31
31
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
32
|
-
today_at_time:
|
|
33
|
-
yesterday_at_time:
|
|
34
|
-
tomorrow_at_time:
|
|
35
|
-
on_weekday_at_time:
|
|
36
|
-
on_date_time_current_year: "
|
|
32
|
+
today_at_time: Danas u %02k:%M
|
|
33
|
+
yesterday_at_time: Juče u %02k:%M
|
|
34
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
35
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
36
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
37
37
|
on_date: "%-d. %b %Y."
|
|
38
|
-
ago:
|
|
38
|
+
ago: Pre %{time}
|
|
39
39
|
x_hours_ago:
|
|
40
40
|
few: pre %{count} sata
|
|
41
41
|
one: pre %{count} sata
|
|
@@ -130,13 +130,13 @@ sr-Latn-RS:
|
|
|
130
130
|
short: "%-d. %b %02k:%M"
|
|
131
131
|
billing: "%-d.%-m.%Y."
|
|
132
132
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
133
|
-
today_at_time:
|
|
134
|
-
yesterday_at_time:
|
|
135
|
-
tomorrow_at_time:
|
|
136
|
-
on_weekday_at_time:
|
|
137
|
-
on_date_time_current_year: "
|
|
133
|
+
today_at_time: Danas u %02k:%M
|
|
134
|
+
yesterday_at_time: Juče u %02k:%M
|
|
135
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
136
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
137
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
138
138
|
on_date: "%-d. %b %Y."
|
|
139
|
-
ago:
|
|
139
|
+
ago: Pre %{time}
|
|
140
140
|
x_hours_ago:
|
|
141
141
|
few: pre %{count} sata
|
|
142
142
|
one: pre %{count} sata
|
|
@@ -146,7 +146,7 @@ sr-Latn-RS:
|
|
|
146
146
|
one: pre %{count} minuta
|
|
147
147
|
other: pre %{count} minuta
|
|
148
148
|
cc_expiry_date: "%m/%Y"
|
|
149
|
-
am:
|
|
150
|
-
pm:
|
|
151
|
-
just_now: sada
|
|
149
|
+
am: pre podne
|
|
150
|
+
pm: po podne
|
|
151
|
+
just_now: Upravo sada
|
|
152
152
|
yesterday: juče
|
|
@@ -29,13 +29,13 @@ sr-Latn-XK:
|
|
|
29
29
|
default: "%-d.%-m.%Y."
|
|
30
30
|
billing: "%-d.%-m.%Y."
|
|
31
31
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
32
|
-
today_at_time:
|
|
33
|
-
yesterday_at_time:
|
|
34
|
-
tomorrow_at_time:
|
|
35
|
-
on_weekday_at_time:
|
|
36
|
-
on_date_time_current_year: "
|
|
32
|
+
today_at_time: Danas u %02k:%M
|
|
33
|
+
yesterday_at_time: Juče u %02k:%M
|
|
34
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
35
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
36
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
37
37
|
on_date: "%-d. %b %Y."
|
|
38
|
-
ago:
|
|
38
|
+
ago: Pre %{time}
|
|
39
39
|
x_hours_ago:
|
|
40
40
|
few: pre %{count} sata
|
|
41
41
|
one: pre %{count} sata
|
|
@@ -130,13 +130,13 @@ sr-Latn-XK:
|
|
|
130
130
|
short: "%-d. %b %02k:%M"
|
|
131
131
|
billing: "%-d.%-m.%Y."
|
|
132
132
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
133
|
-
today_at_time:
|
|
134
|
-
yesterday_at_time:
|
|
135
|
-
tomorrow_at_time:
|
|
136
|
-
on_weekday_at_time:
|
|
137
|
-
on_date_time_current_year: "
|
|
133
|
+
today_at_time: Danas u %02k:%M
|
|
134
|
+
yesterday_at_time: Juče u %02k:%M
|
|
135
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
136
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
137
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
138
138
|
on_date: "%-d. %b %Y."
|
|
139
|
-
ago:
|
|
139
|
+
ago: Pre %{time}
|
|
140
140
|
x_hours_ago:
|
|
141
141
|
few: pre %{count} sata
|
|
142
142
|
one: pre %{count} sata
|
|
@@ -146,7 +146,7 @@ sr-Latn-XK:
|
|
|
146
146
|
one: pre %{count} minuta
|
|
147
147
|
other: pre %{count} minuta
|
|
148
148
|
cc_expiry_date: "%m/%Y"
|
|
149
|
-
am:
|
|
150
|
-
pm:
|
|
151
|
-
just_now: sada
|
|
149
|
+
am: pre podne
|
|
150
|
+
pm: po podne
|
|
151
|
+
just_now: Upravo sada
|
|
152
152
|
yesterday: juče
|
|
@@ -29,13 +29,13 @@ sr-Latn:
|
|
|
29
29
|
default: "%-d.%-m.%Y."
|
|
30
30
|
billing: "%-d.%-m.%Y."
|
|
31
31
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
32
|
-
today_at_time:
|
|
33
|
-
yesterday_at_time:
|
|
34
|
-
tomorrow_at_time:
|
|
35
|
-
on_weekday_at_time:
|
|
36
|
-
on_date_time_current_year: "
|
|
32
|
+
today_at_time: Danas u %02k:%M
|
|
33
|
+
yesterday_at_time: Juče u %02k:%M
|
|
34
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
35
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
36
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
37
37
|
on_date: "%-d. %b %Y."
|
|
38
|
-
ago:
|
|
38
|
+
ago: Pre %{time}
|
|
39
39
|
x_hours_ago:
|
|
40
40
|
few: pre %{count} sata
|
|
41
41
|
one: pre %{count} sata
|
|
@@ -130,13 +130,13 @@ sr-Latn:
|
|
|
130
130
|
short: "%-d. %b %02k:%M"
|
|
131
131
|
billing: "%-d.%-m.%Y."
|
|
132
132
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
133
|
-
today_at_time:
|
|
134
|
-
yesterday_at_time:
|
|
135
|
-
tomorrow_at_time:
|
|
136
|
-
on_weekday_at_time:
|
|
137
|
-
on_date_time_current_year: "
|
|
133
|
+
today_at_time: Danas u %02k:%M
|
|
134
|
+
yesterday_at_time: Juče u %02k:%M
|
|
135
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
136
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
137
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
138
138
|
on_date: "%-d. %b %Y."
|
|
139
|
-
ago:
|
|
139
|
+
ago: Pre %{time}
|
|
140
140
|
x_hours_ago:
|
|
141
141
|
few: pre %{count} sata
|
|
142
142
|
one: pre %{count} sata
|
|
@@ -146,7 +146,7 @@ sr-Latn:
|
|
|
146
146
|
one: pre %{count} minuta
|
|
147
147
|
other: pre %{count} minuta
|
|
148
148
|
cc_expiry_date: "%m/%Y"
|
|
149
|
-
am:
|
|
150
|
-
pm:
|
|
151
|
-
just_now: sada
|
|
149
|
+
am: pre podne
|
|
150
|
+
pm: po podne
|
|
151
|
+
just_now: Upravo sada
|
|
152
152
|
yesterday: juče
|
data/data/other/generated/sr.yml
CHANGED
|
@@ -29,74 +29,74 @@ sr:
|
|
|
29
29
|
default: "%-d.%-m.%Y."
|
|
30
30
|
billing: "%-d.%-m.%Y."
|
|
31
31
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
32
|
-
today_at_time:
|
|
33
|
-
yesterday_at_time:
|
|
34
|
-
tomorrow_at_time:
|
|
35
|
-
on_weekday_at_time:
|
|
36
|
-
on_date_time_current_year: "
|
|
32
|
+
today_at_time: Danas u %02k:%M
|
|
33
|
+
yesterday_at_time: Juče u %02k:%M
|
|
34
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
35
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
36
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
37
37
|
on_date: "%-d. %b %Y."
|
|
38
|
-
ago:
|
|
38
|
+
ago: Pre %{time}
|
|
39
39
|
x_hours_ago:
|
|
40
|
-
few:
|
|
41
|
-
one:
|
|
42
|
-
other:
|
|
40
|
+
few: pre %{count} sata
|
|
41
|
+
one: pre %{count} sata
|
|
42
|
+
other: pre %{count} sati
|
|
43
43
|
x_minutes_ago:
|
|
44
|
-
few:
|
|
45
|
-
one:
|
|
46
|
-
other:
|
|
44
|
+
few: pre %{count} minuta
|
|
45
|
+
one: pre %{count} minuta
|
|
46
|
+
other: pre %{count} minuta
|
|
47
47
|
cc_expiry_date: "%m/%Y"
|
|
48
48
|
abbr_day_names:
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
-
|
|
52
|
-
-
|
|
53
|
-
-
|
|
54
|
-
-
|
|
55
|
-
-
|
|
49
|
+
- ned
|
|
50
|
+
- pon
|
|
51
|
+
- uto
|
|
52
|
+
- sre
|
|
53
|
+
- čet
|
|
54
|
+
- pet
|
|
55
|
+
- sub
|
|
56
56
|
abbr_month_names:
|
|
57
57
|
- ''
|
|
58
|
-
-
|
|
59
|
-
-
|
|
60
|
-
-
|
|
61
|
-
-
|
|
62
|
-
-
|
|
63
|
-
-
|
|
64
|
-
-
|
|
65
|
-
-
|
|
66
|
-
-
|
|
67
|
-
-
|
|
68
|
-
-
|
|
69
|
-
-
|
|
58
|
+
- jan
|
|
59
|
+
- feb
|
|
60
|
+
- mar
|
|
61
|
+
- apr
|
|
62
|
+
- maj
|
|
63
|
+
- jun
|
|
64
|
+
- jul
|
|
65
|
+
- avg
|
|
66
|
+
- sep
|
|
67
|
+
- okt
|
|
68
|
+
- nov
|
|
69
|
+
- dec
|
|
70
70
|
day_names:
|
|
71
|
-
-
|
|
72
|
-
-
|
|
73
|
-
-
|
|
74
|
-
-
|
|
75
|
-
-
|
|
76
|
-
-
|
|
77
|
-
-
|
|
71
|
+
- nedelja
|
|
72
|
+
- ponedeljak
|
|
73
|
+
- utorak
|
|
74
|
+
- sreda
|
|
75
|
+
- četvrtak
|
|
76
|
+
- petak
|
|
77
|
+
- subota
|
|
78
78
|
month_names:
|
|
79
79
|
- ''
|
|
80
|
-
-
|
|
81
|
-
-
|
|
82
|
-
-
|
|
83
|
-
-
|
|
84
|
-
-
|
|
85
|
-
-
|
|
86
|
-
-
|
|
87
|
-
-
|
|
88
|
-
-
|
|
89
|
-
-
|
|
90
|
-
-
|
|
91
|
-
-
|
|
80
|
+
- januar
|
|
81
|
+
- februar
|
|
82
|
+
- mart
|
|
83
|
+
- april
|
|
84
|
+
- maj
|
|
85
|
+
- jun
|
|
86
|
+
- jul
|
|
87
|
+
- avgust
|
|
88
|
+
- septembar
|
|
89
|
+
- oktobar
|
|
90
|
+
- novembar
|
|
91
|
+
- decembar
|
|
92
92
|
relative_day_names:
|
|
93
|
-
this_week:
|
|
94
|
-
this_month:
|
|
95
|
-
day_before_yesterday:
|
|
96
|
-
yesterday:
|
|
97
|
-
today:
|
|
98
|
-
tomorrow:
|
|
99
|
-
day_after_tomorrow:
|
|
93
|
+
this_week: ove nedelje
|
|
94
|
+
this_month: ovog meseca
|
|
95
|
+
day_before_yesterday: prekjuče
|
|
96
|
+
yesterday: juče
|
|
97
|
+
today: danas
|
|
98
|
+
tomorrow: sutra
|
|
99
|
+
day_after_tomorrow: prekosutra
|
|
100
100
|
order:
|
|
101
101
|
- :day
|
|
102
102
|
- :month
|
|
@@ -130,23 +130,23 @@ sr:
|
|
|
130
130
|
short: "%-d. %b %02k:%M"
|
|
131
131
|
billing: "%-d.%-m.%Y."
|
|
132
132
|
yearless_ordinal: "%{ordinalized_day} %B"
|
|
133
|
-
today_at_time:
|
|
134
|
-
yesterday_at_time:
|
|
135
|
-
tomorrow_at_time:
|
|
136
|
-
on_weekday_at_time:
|
|
137
|
-
on_date_time_current_year: "
|
|
133
|
+
today_at_time: Danas u %02k:%M
|
|
134
|
+
yesterday_at_time: Juče u %02k:%M
|
|
135
|
+
tomorrow_at_time: Sutra u %02k:%M
|
|
136
|
+
on_weekday_at_time: u %A u %02k:%M
|
|
137
|
+
on_date_time_current_year: "%-d. %b u %02k:%M"
|
|
138
138
|
on_date: "%-d. %b %Y."
|
|
139
|
-
ago:
|
|
139
|
+
ago: Pre %{time}
|
|
140
140
|
x_hours_ago:
|
|
141
|
-
few:
|
|
142
|
-
one:
|
|
143
|
-
other:
|
|
141
|
+
few: pre %{count} sata
|
|
142
|
+
one: pre %{count} sata
|
|
143
|
+
other: pre %{count} sati
|
|
144
144
|
x_minutes_ago:
|
|
145
|
-
few:
|
|
146
|
-
one:
|
|
147
|
-
other:
|
|
145
|
+
few: pre %{count} minuta
|
|
146
|
+
one: pre %{count} minuta
|
|
147
|
+
other: pre %{count} minuta
|
|
148
148
|
cc_expiry_date: "%m/%Y"
|
|
149
|
-
am:
|
|
150
|
-
pm:
|
|
151
|
-
just_now:
|
|
152
|
-
yesterday:
|
|
149
|
+
am: pre podne
|
|
150
|
+
pm: po podne
|
|
151
|
+
just_now: Upravo sada
|
|
152
|
+
yesterday: juče
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
---
|
|
2
|
+
sr:
|
|
3
|
+
date_time_translation:
|
|
4
|
+
today_at_time: Danas u %{time}
|
|
5
|
+
yesterday_at_time: Juče u %{time}
|
|
6
|
+
tomorrow_at_time: Sutra u %{time}
|
|
7
|
+
on_weekday_at_time: u %{weekday_name} u %{time}
|
|
8
|
+
on_date_time_current_year: "%{month_and_day} u %{time}"
|
|
9
|
+
on_date: "%{date}"
|
|
10
|
+
ago: Pre %{time}
|
|
11
|
+
am: pre podne
|
|
12
|
+
pm: po podne
|
|
13
|
+
just_now: Upravo sada
|
|
14
|
+
this_week: ove nedelje
|
|
15
|
+
this_month: ovog meseca
|
data/data/other/paths.txt
CHANGED
|
@@ -874,6 +874,7 @@
|
|
|
874
874
|
/data/other/hand_translated/ru.yml
|
|
875
875
|
/data/other/hand_translated/sk.yml
|
|
876
876
|
/data/other/hand_translated/sl.yml
|
|
877
|
+
/data/other/hand_translated/sr.yml
|
|
877
878
|
/data/other/hand_translated/sv.yml
|
|
878
879
|
/data/other/hand_translated/ta.yml
|
|
879
880
|
/data/other/hand_translated/te.yml
|
data/data/regions/AR.yml
CHANGED
|
@@ -14,6 +14,7 @@ building_number_required: true
|
|
|
14
14
|
zip_regex: "^[A-Z]?\\d{4}([A-Z]{3})?$"
|
|
15
15
|
week_start_day: sunday
|
|
16
16
|
format:
|
|
17
|
+
address1: "{street} {building_num}"
|
|
17
18
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}{province}_{phone}"
|
|
18
19
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city} {province}_{country}_{phone}"
|
|
19
20
|
emoji: "\U0001F1E6\U0001F1F7"
|
data/data/regions/AT.yml
CHANGED
|
@@ -24,6 +24,7 @@ example_address:
|
|
|
24
24
|
zip: '1015'
|
|
25
25
|
phone: "+43 1 53410"
|
|
26
26
|
format:
|
|
27
|
+
address1: "{street} {building_num}"
|
|
27
28
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
28
29
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
29
30
|
emoji: "\U0001F1E6\U0001F1F9"
|
data/data/regions/BE.yml
CHANGED
|
@@ -27,6 +27,7 @@ example_address:
|
|
|
27
27
|
zip: '1000'
|
|
28
28
|
phone: "+32 (0)2-551.20.20"
|
|
29
29
|
format:
|
|
30
|
+
address1: "{street} {building_num}"
|
|
30
31
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
31
32
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
32
33
|
format_extended:
|
data/data/regions/BR.yml
CHANGED
|
@@ -24,6 +24,7 @@ example_address:
|
|
|
24
24
|
zip: 70050-000
|
|
25
25
|
phone: "+55 61 3224-4073"
|
|
26
26
|
format:
|
|
27
|
+
address1: "{street}, {building_num}"
|
|
27
28
|
edit: "{country}_{firstName}{lastName}_{company}_{zip}_{address1}_{address2}_{city}{province}_{phone}"
|
|
28
29
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city} {province}_{country}_{phone}"
|
|
29
30
|
format_extended:
|
data/data/regions/CH.yml
CHANGED
|
@@ -28,6 +28,7 @@ example_address:
|
|
|
28
28
|
zip: '3003'
|
|
29
29
|
phone: "+41 31 377 77 77"
|
|
30
30
|
format:
|
|
31
|
+
address1: "{street} {building_num}"
|
|
31
32
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
32
33
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
33
34
|
emoji: "\U0001F1E8\U0001F1ED"
|
data/data/regions/CL.yml
CHANGED
|
@@ -12,6 +12,7 @@ zip_example: '8340457'
|
|
|
12
12
|
phone_number_prefix: 56
|
|
13
13
|
week_start_day: sunday
|
|
14
14
|
format:
|
|
15
|
+
address1: "{street} {building_num}"
|
|
15
16
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{province}_{phone}"
|
|
16
17
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{province}_{country}_{phone}"
|
|
17
18
|
format_extended:
|
data/data/regions/CZ.yml
CHANGED
|
@@ -18,6 +18,7 @@ phone_number_prefix: 420
|
|
|
18
18
|
building_number_required: true
|
|
19
19
|
week_start_day: monday
|
|
20
20
|
format:
|
|
21
|
+
address1: "{street} {building_num}"
|
|
21
22
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
22
23
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
23
24
|
emoji: "\U0001F1E8\U0001F1FF"
|
data/data/regions/ES.yml
CHANGED
|
@@ -25,6 +25,7 @@ example_address:
|
|
|
25
25
|
zip: '28004'
|
|
26
26
|
phone: "+34 91 701 72 67"
|
|
27
27
|
format:
|
|
28
|
+
address1: "{street} {building_num}"
|
|
28
29
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}{province}_{phone}"
|
|
29
30
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{province}_{country}_{phone}"
|
|
30
31
|
format_extended:
|
data/data/regions/FI.yml
CHANGED
|
@@ -17,6 +17,7 @@ phone_number_prefix: 358
|
|
|
17
17
|
building_number_required: true
|
|
18
18
|
week_start_day: monday
|
|
19
19
|
format:
|
|
20
|
+
address1: "{street} {building_num}"
|
|
20
21
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
21
22
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
22
23
|
emoji: "\U0001F1EB\U0001F1EE"
|
data/data/regions/HU.yml
CHANGED
|
@@ -14,6 +14,7 @@ phone_number_prefix: 36
|
|
|
14
14
|
building_number_required: true
|
|
15
15
|
week_start_day: monday
|
|
16
16
|
format:
|
|
17
|
+
address1: "{street} {building_num}"
|
|
17
18
|
edit: "{country}_{firstName}{lastName}_{company}_{zip}{city}_{address1}_{address2}_{phone}"
|
|
18
19
|
show: "{firstName} {lastName}_{company}_{zip} {city}_{address1}_{address2}_{country}_{phone}"
|
|
19
20
|
tags:
|
data/data/regions/MX.yml
CHANGED
|
@@ -14,6 +14,7 @@ phone_number_prefix: 52
|
|
|
14
14
|
building_number_required: true
|
|
15
15
|
week_start_day: sunday
|
|
16
16
|
format:
|
|
17
|
+
address1: "{street} {building_num}"
|
|
17
18
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}{province}_{phone}"
|
|
18
19
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city} {province}_{country}_{phone}"
|
|
19
20
|
format_extended:
|
data/data/regions/NO.yml
CHANGED
|
@@ -24,6 +24,7 @@ example_address:
|
|
|
24
24
|
zip: '0287'
|
|
25
25
|
phone: "+47 22 13 52 80"
|
|
26
26
|
format:
|
|
27
|
+
address1: "{street} {building_num}"
|
|
27
28
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
28
29
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
29
30
|
emoji: "\U0001F1F3\U0001F1F4"
|
data/data/regions/PA.yml
CHANGED
|
@@ -7,8 +7,8 @@ unit_system: metric
|
|
|
7
7
|
tax_name: ITBMS
|
|
8
8
|
group: Central American Countries
|
|
9
9
|
group_name: Central America
|
|
10
|
-
zip_regex: "
|
|
11
|
-
zip_example: "
|
|
10
|
+
zip_regex: "^(?:\\d{4}|[A-Z0-9]{2}[2-9A-HJ-NP-TV-XZ]{3}[ -]?[2-9A-HJ-NP-TV-XZ]{5})$"
|
|
11
|
+
zip_example: "ADC96-M8H44"
|
|
12
12
|
zip_requirement: optional
|
|
13
13
|
phone_number_prefix: 507
|
|
14
14
|
week_start_day: sunday
|
|
@@ -45,7 +45,7 @@ example_address:
|
|
|
45
45
|
address2: y entre calles 35 y, C. 36 Este, El Marañón
|
|
46
46
|
city: Panamá
|
|
47
47
|
province_code: PA-8
|
|
48
|
-
zip:
|
|
48
|
+
zip: ADC96-M8H44
|
|
49
49
|
phone: "+507 524-8900"
|
|
50
50
|
zones:
|
|
51
51
|
- name: Bocas del Toro
|
data/data/regions/PT.yml
CHANGED
|
@@ -17,6 +17,7 @@ tags:
|
|
|
17
17
|
- EU-member
|
|
18
18
|
week_start_day: monday
|
|
19
19
|
format:
|
|
20
|
+
address1: "{street} {building_num}"
|
|
20
21
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}{province}_{phone}"
|
|
21
22
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{province}_{country}_{phone}"
|
|
22
23
|
emoji: "\U0001F1F5\U0001F1F9"
|
data/data/regions/SE.yml
CHANGED
|
@@ -24,6 +24,7 @@ example_address:
|
|
|
24
24
|
zip: 103 16
|
|
25
25
|
phone: "+46 8 534 818 00"
|
|
26
26
|
format:
|
|
27
|
+
address1: "{street} {building_num}"
|
|
27
28
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}_{phone}"
|
|
28
29
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}_{country}_{phone}"
|
|
29
30
|
emoji: "\U0001F1F8\U0001F1EA"
|
data/data/regions/UY.yml
CHANGED
|
@@ -11,6 +11,7 @@ zip_example: '11600'
|
|
|
11
11
|
phone_number_prefix: 598
|
|
12
12
|
week_start_day: monday
|
|
13
13
|
format:
|
|
14
|
+
address1: "{street} {building_num}"
|
|
14
15
|
edit: "{country}_{firstName}{lastName}_{company}_{address1}_{address2}_{zip}{city}{province}_{phone}"
|
|
15
16
|
show: "{firstName} {lastName}_{company}_{address1}_{address2}_{zip} {city}, {province}_{country}_{phone}"
|
|
16
17
|
emoji: "\U0001F1FA\U0001F1FE"
|
data/lib/worldwide/locale.rb
CHANGED
|
@@ -11,6 +11,7 @@ module Worldwide
|
|
|
11
11
|
|
|
12
12
|
@code = code.to_sym
|
|
13
13
|
@name_cache = {}
|
|
14
|
+
@endonym_cache = {}
|
|
14
15
|
end
|
|
15
16
|
|
|
16
17
|
# Special CLDR value
|
|
@@ -47,7 +48,8 @@ module Worldwide
|
|
|
47
48
|
end
|
|
48
49
|
|
|
49
50
|
def name(locale: I18n.locale, context: :middle_of_sentence, throw: true)
|
|
50
|
-
|
|
51
|
+
cache_key = [locale&.to_sym, context]
|
|
52
|
+
@name_cache[cache_key] ||= I18n.with_locale(locale) do
|
|
51
53
|
# Try to find a language name as specific as possible in the locale we wanted.
|
|
52
54
|
exonym(target_locale: locale, context: context) ||
|
|
53
55
|
|
|
@@ -68,48 +70,46 @@ module Worldwide
|
|
|
68
70
|
I18n::MissingTranslation.new(locale, "languages.#{code}")
|
|
69
71
|
end
|
|
70
72
|
|
|
71
|
-
if @name_cache[
|
|
72
|
-
raise @name_cache[
|
|
73
|
+
if @name_cache[cache_key].is_a?(I18n::MissingTranslation)
|
|
74
|
+
raise @name_cache[cache_key] if throw
|
|
73
75
|
|
|
74
76
|
return
|
|
75
77
|
end
|
|
76
78
|
|
|
77
|
-
@name_cache[
|
|
79
|
+
@name_cache[cache_key]
|
|
78
80
|
end
|
|
79
81
|
|
|
80
82
|
# The language's name in that language ("endonym").
|
|
81
83
|
def endonym(context: :middle_of_sentence, throw: true)
|
|
82
|
-
|
|
84
|
+
@endonym_cache[context] ||= begin
|
|
85
|
+
result = begin
|
|
86
|
+
lookup(code, locale: code)
|
|
87
|
+
rescue I18n::InvalidLocale => e
|
|
88
|
+
raise e if throw
|
|
89
|
+
end
|
|
83
90
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
rescue I18n::InvalidLocale => e
|
|
87
|
-
raise e if throw
|
|
91
|
+
result = Worldwide::Cldr::ContextTransforms.transform(result, :languages, context, locale: code) unless result.nil?
|
|
92
|
+
result || I18n::MissingTranslation.new(code, "languages.#{code}")
|
|
88
93
|
end
|
|
89
94
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
if @endonym.is_a?(I18n::MissingTranslation)
|
|
94
|
-
raise @endonym if throw
|
|
95
|
+
if @endonym_cache[context].is_a?(I18n::MissingTranslation)
|
|
96
|
+
raise @endonym_cache[context] if throw
|
|
95
97
|
|
|
96
98
|
return
|
|
97
99
|
end
|
|
98
100
|
|
|
99
|
-
@
|
|
101
|
+
@endonym_cache[context]
|
|
100
102
|
end
|
|
101
103
|
|
|
102
104
|
private
|
|
103
105
|
|
|
104
106
|
def exonym(target_locale:, context:)
|
|
105
|
-
return @exonym if defined?(@exonym)
|
|
106
|
-
|
|
107
107
|
# Try to find a language name as specific as possible in the locale we wanted.
|
|
108
108
|
# We chop the hyphens to get more and more general language names
|
|
109
109
|
# (e.g., "Traditional Chinese as spoken in Hong Kong" (zh-Hant-HK) -> "Traditional Chinese" (zh-Hant) -> "Chinese" (zh))
|
|
110
110
|
# and rely on `territories_suffix` to add in additional details after.
|
|
111
111
|
# It's just a heuristic and definitely not perfect (for the really important ones, we can manually patch the data)
|
|
112
|
-
|
|
112
|
+
chop(code.to_s, "-").each_with_index do |language, i|
|
|
113
113
|
result = lookup(language, locale: target_locale)
|
|
114
114
|
if result
|
|
115
115
|
transformed = Worldwide::Cldr::ContextTransforms.transform(result, :languages, context, locale: target_locale)
|
|
@@ -119,11 +119,8 @@ module Worldwide
|
|
|
119
119
|
end
|
|
120
120
|
|
|
121
121
|
def name_in_default_locale(context:)
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
@name_in_default_locale = lookup(code, locale: I18n.default_locale)
|
|
125
|
-
@name_in_default_locale = Worldwide::Cldr::ContextTransforms.transform(@name_in_default_locale, :languages, context, locale: I18n.default_locale) unless @name_in_default_locale.nil?
|
|
126
|
-
@name_in_default_locale
|
|
122
|
+
result = lookup(code, locale: I18n.default_locale)
|
|
123
|
+
Worldwide::Cldr::ContextTransforms.transform(result, :languages, context, locale: I18n.default_locale) unless result.nil?
|
|
127
124
|
end
|
|
128
125
|
|
|
129
126
|
def lookup(key, locale:)
|