react-datetime-picker
react-datetime-picker copied to clipboard
Input with one invalid date field value (day, month, or year) cannot be cleared
preconditions:
- the date picker is initialized without a date and a format similar to MM/dd/y OR
- the date picker is initialized with a date and the 'clear' button is clicked
reproduction steps:
- by typing, two of the date fields (day, month, or year) are filled with valid values and the third date field is left empty OR filled with an invalid value
- click the 'clear' button
expected result
- the form fields clear
actual result
- the form fields are not cleared.
This is reproducible on the demo site.
NOTE this behavior is specific to typing in the inputs, it does not happen if the input is initalized with a date (or a date in the calendar is clicked) and the value of one of the fields is deleted.