Open airasyaqub opened 4 years ago
The parse
method is used to convert text the user types to a date, you also need to override the createDate
which is used to create dates given the year, month, and date.
I think we should have a guide on creating custom date adapters, I'll use this issue to track that
I want to use my own timezone for selected dates in mat date picker. After researching my best option was to write my own parser to use my desired time zone in adapter. Currently the parser only runs when I input in field whereas it should also run when selecting date from toggle box. There are currently many threads on different platform with similar requirements. Kindly update your angular docs with suitable example or give us the example up here to provide timezone on mat date picker.
Reproduction
Use StackBlitz to reproduce your issue: https://stackblitz.com/edit/angular-edvxsk
Steps to reproduce:
Expected Behavior
Parser function should also run when selecting date from toggle box.
Actual Behavior
Parser only runs when I input in field