moment / moment-timezone

Timezone support for moment.js
momentjs.com/timezone
MIT License
3.83k stars 838 forks source link

Moment timezone is not correctly showing the zone abbreviation for Pacific/Nauru. #780

Closed shweshi closed 2 years ago

shweshi commented 5 years ago

Moment timezone is not correctly showing the zone abbreviation for Pacific/Nauru.

Example:

moment.tz('America/New_York').zoneAbbr(); // "EDT" moment.tz('Pacific/Nauru').zoneAbbr(); // +12

It should give the zone abbreviation.

ellenaua commented 5 years ago

There has been big change in 2017 when IANA (Internet Assigned Numbers Authority) changed some time zone abbreviations to numeric representations. And this one was also changed because NRT was considered as self-invented abbreviation

https://mm.icann.org/pipermail/tz/2017-January/024769.html

NouraldinS commented 5 years ago

Same for America/Santiago.

dustinsgoodman commented 5 years ago

Same for America/Sao_Paulohttps://codesandbox.io/s/objective-pasteur-znco2

ellenaua commented 4 years ago

In december 2016, IANA (https://www.iana.org/) deprecated these abbreviations and many others

America/Sao_Paulo - BRT (-03) BRST (-02) America/Santiago - CLT (-04) CLST (-03)

https://mm.icann.org/pipermail/tz/2016-December/024645.html

This is international standartization organization. So, abbreviations like BRST, BRT are considered deprecated. Could you please tell me what do you see when do console.log(new Date()) in browser console - Sat Mar 14 2020 07:38:18 GMT-0300 (-03) or Sat Mar 14 2020 07:38:18 GMT-0300 (BRT) @dustinsgoodman?

dustinsgoodman commented 4 years ago

@ellenaua I was reporting based on an investigation from a user of my site. I set my system's timezone to Brazil and ran the command and got the following output:

Screen Shot 2020-03-14 at 2 41 43 PM

Hope that's helpful!

ichernev commented 2 years ago

moment-timezone is not in a position to maintain timezone offset names outside of IANA/tzdb. Please redirect your anger there, you might manage to convince them to bring some of the offset names back (if enough people complain).