CARVIEW |
Navigation Menu
-
Notifications
You must be signed in to change notification settings - Fork 160
Description
- Update Date Editor Spec
- Mask Refactoring Mask refactoringΒ #6454
- Update Mask Editor Spec
- Implementation & Unit tests
- I want to able display date/time values based on defined formats (display value and edit value; all defined masks, like shortDate/longDate & custom format)
- Implementation - move to date-editor.common - util functions and pipes.
- Unit tests - copy existing tests from date-picker/time-picker and create new.
- I want to able to spin date/time parts
- Implementation
- Unit tests - copy existing tests from time-picker and create new for date-picker.
- I want to edit date/time values in the editor
- Implementation
- Unit tests
- I want to be able to set minValue & maxValue
- Implementation - releated issue min and max properties in the DatePicker component.Β #6286
- Unit tests
- I want to be able to use date-editor in Template Form and Reactive Form
- Implementation
- Unit tests
- I want have customizable prompt chars
- Implementation
- Unit tests
- I want have placeholder text
- Implementation
- Unit tests
- I want to complete partialy entered dates
- Implementation
- Unit tests
- I want to clear any invalid input
- Implementation
- Unit tests
- Other inputs, outputs & methods
- Implementation
- Unit tests
- I want to able display date/time values based on defined formats (display value and edit value; all defined masks, like shortDate/longDate & custom format)
- Demos Dev
- Separate Demo for date editor
- Update existing Reactive Form the demo and add date editor
- Add demo for Template Driven Form with editor components
- Topic and Samples
- Create new topic for date-editor
- Simple demo
- Advanced demo
Is your feature request related to a problem? Please describe.
Right now there's a standalone Mask input, but no alternative for Date input.
Functionality for this exists inside the Date Picker, however it's not exposed. Further, this leads to re-templated pickers being stuck with reduced functionality (see Retemplated Dropdown Date Picker) and isn't reusable by other components (e.g. Date Range)
Looking at angular/angular#8203 we might want to look into supporting type "date" and "datetime-local"
Describe the solution you'd like
Ideally a directive that can handle Date (perhaps and time) input (extending from igxMask
) and Model binding (ValueAccessor
), potentially supporting native date input types as well.
Describe alternatives you've considered
See SO links below. Those don't look clean in API or always work well TBH.
Additional context
Date input is especially painful, since dates usually require formatting which means a separation of value and display text and there's definitely room for improvement here as seen in multiple SO questions:
https://stackoverflow.com/questions/37055311/angular2-how-to-use-javascript-date-object-with-ngmodel-two-way-binding
https://stackoverflow.com/questions/38175251/angular-2-date-input-not-binding-to-date-value
All of those deal with trying to format the Date as string and somehow parse it back with varying success.