forked from h2qutc/angular-material-components
-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Hello,
Thank you very much for adopting this library and continuing its development!
We've started seeing some issues in our tests after we updated to the latest version (20.0.0) following the usage guide and the fact that the adapters have been removed (we were using the moment one). What I've found so far is that with the new version the time portion of a datetime is not taken into account or the config and behavior changed in a couple of scenarios:
- it would be nice if the docs mention that @ngxmc/datetime-picker won't work with @ngxmc/moment-adapter anymore
- issue with min/max validation (there is an existing issue Min/Max validators aren't working on Angular 20 #14 about it) - the usage of
_dateAdapter.compareDateWithTimewas replaced with_dateAdapter.compareDate(8b36ff3#diff-614475f7357f674bf10decf0be1a3a7883bb5a7d40e3d4148d9d28c1f47dbb16L172) which in essence does not take into account the time part of a datetime - issues with formats when parsing/displaying - @ngxmc/moment-adapter got removed
- by default the
dateInputparsing/displaying format was 'l, LTS' (8b36ff3#diff-2277a28a921ab3d8fbe2af20e78e57370f59dadf10fd35cf48e37a225eba5e87 ), but since now the angular material moment adapter is being used throughout the library it becomes 'l' (https://github.com/angular/components/blob/main/src/material-moment-adapter/adapter/moment-date-formats.ts) which in essence ignores the time part of a datetime - shared MAT_MOMENT_DATE_FORMATS is an issue since one might want to have separate
dateInputformats for dates (mat-datepicker or ngx-mat-datetime-picker with hidden time) and datetimes (ngx-mat-datetime-picker). I would say that this is almost always the case, since we don't want to parse/display the time portion when using a datepicker and the opposite when using a datetimepicker.
- by default the
Note, that this might not be a complete list of the issues. I can't suggest a nice solution other than to revert those changes. Let me know what you think.
Thanks!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels