Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow partially erasing date by keyboard without moving rest of date string #1289

Closed
Talal916 opened this issue Aug 28, 2019 · 3 comments
Closed

Comments

@Talal916
Copy link

Is your feature request related to a problem? Please describe.
Deleting characters in the middle of a date/time/datetime string through the keyboard results in the rest of the string shifting left.

Undesired behavior
https://material-ui-pickers.dev/demo/datepicker

Describe the solution you'd like
I'd like to able to edit parts of the date and time without the rest of the date/time/datetime being affected. This is the standard behavior for most datepickers and the keyboard pickers used by Material-UI result in unexpected behavior for users.

This is a demo of the desired behavior, using the native picker.
https://material-ui.com/components/pickers/
Desired behavior

@Talal916
Copy link
Author

Here's another example of the current behavior being unpleasant

@croraf
Copy link

croraf commented Sep 27, 2019

Yes, this is a very bad user experience.

When nothing is selected but cursor is in the field:

  • DEL sets the next figure to "_" or the letter representation of the figure ("d", "m", "y"). I don't know if the cursors position should change or stay where it was?
  • backspace sets the previous figure to "_" or the letter representation of the figure. The cursor should move 1 figure back.

When some figures are selected then:

  • DEL should put all these figures to "_" or letter representation of the figures. Not sure where the cursor position should end?
  • backspace should put all these figures to "_" or letter representation of the figures. The cursor should be set to the beginning of the selection.

@dmtrKovalenko
Copy link
Member

Already fixed in v4-alpha👨‍🏭

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants