mui/material-ui-pickers

KeyboardTimePicker also changes the date when modifying the time using the keyboard

tran-simon opened this issue ยท 3 comments

  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior ๐Ÿ˜ฏ

With the KeyboardTimePicker default value at "2021-06-10T12:00:00", changing the time using the keyboard to 12:30 also changes the date to today's date. Using the picker popup doesn't change the date

Expected Behavior ๐Ÿค”

The behavior should be the same whether the users uses the keyboard or the popup picker

Steps to Reproduce ๐Ÿ•น

https://codesandbox.io/s/keyboardtimepicker-bug-zqeh4?file=/src/App.tsx

Steps:

  1. Have a KeyboardTimePicker with the initial date value not in today's date
  2. Change the time using the keyboard
  3. The date changes
Tech Version
@material-ui/core v4.11.4
@material-ui/pickers v.3.3.10
React v.17.0.2

@oliviertassinari Why was this closed?

I see.

Since the bug is still present in Material-UI Alpha 5.0.0, I've opened the same issue there: mui/material-ui#26799