mirror of
https://github.com/discourse/discourse.git
synced 2025-05-21 18:12:32 +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:
@ -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();
|
||||
},
|
||||
|
||||
|
Reference in New Issue
Block a user