Closed brunolopesr closed 5 months ago
I already have a fix for it, a simpler change. Tnx for the PR tho.
Guess I will need to use my fork of the library then.
Why do you keep an open source project open if you do not accept third-party contributions other than your own?
Why didn't you suggest in @brunolopesr PR what the simpler solution would be?
If someone has spent their time contributing to this project and you simply respond with a message like that, believe me, you are not contributing positively to the community.
This pull request addresses issue #817
The date used to map the array of month numbers should not have explicitly set timezone in its ISO 8601 string, because in timezones like
America/Sao_Paulo
which has a negative offset of-3
hours, all dates will be computed one day earlier, eg:Sat Dec 31 2016 22:00:00 GMT-0200 (Horário de Verão de Brasília)
This will make the array of months to be something like:
['December', 'January', 'February', ..., 'November']
, making a buggy behaviour inDatePicker
andMonthPicker
components.I think the best way is to remove the timezone from the string and the timezone from the
Intl.DateTimeFormat
constructor, thus defaulting to the system timezone.Also as I was running the tests in a negative offset, I made some adjustments to the
timezone.spec.ts
tests.