Hello,
Does anyone know if there are plans to have a configuration for KendoReact date inputs that work similarly to Kendo UI for jQuery's parseFormats?
I am using a DateTimePicker and have the following requirements:
- The time must be formatted using military time ie HH:MM
- The user must be able to manually type the year as a two OR four digit year
- On blur, the year ought to display as a four digit year (I don't make the rules)
I have been able to accomplish the second point in a DatePicker by 1. Not specifying a format and 2. Adding some logic in the onBlur event so that a 2-digit year is replaced with a 4-digit year.
I have been scratching my head as to how to accomplish this with the DateTimePicker - I need to specify the format for the time format, and that is constraining the year length.
I'm sure I will find a solution eventually, but having an option like parseFormats would be really helpful in this case. Or maybe there is a different config I can use for this?
Thanks!
If anyone is interested, I did find a solution: I set the format to "MM/dd/y HH:mm". I just had to read the kendo-intl date formatting docs a little more closely.
Here's an example of what I did. I realize it's not working 100% (cannot set value using calendar, but my actual project has some additional onChange handling that takes care of that).
My question still stands, however, about the possibility of a "parseFormats" prop in the future.