mirror of
https://github.com/discourse/discourse.git
synced 2025-09-10 21:01:33 +08:00
FEATURE: Add localized timezone names (#7004)
Uses github.com/discourse/moment-timezone-names-translations to translate timezone names. Plugins can also provide their own timezone name translations.
This commit is contained in:
parent
42df20e4f0
commit
9bf11a7c02
45 changed files with 628 additions and 5 deletions
|
@ -65,6 +65,12 @@ export default Ember.Component.extend({
|
|||
|
||||
@computed()
|
||||
allTimezones() {
|
||||
if (
|
||||
moment.locale() !== "en" &&
|
||||
typeof moment.tz.localizedNames === "function"
|
||||
) {
|
||||
return moment.tz.localizedNames();
|
||||
}
|
||||
return moment.tz.names();
|
||||
},
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue