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

Selecting a date should close the picker #1651

Closed
oliviertassinari opened this issue Apr 12, 2020 · 2 comments · Fixed by #1923
Closed

Selecting a date should close the picker #1651

oliviertassinari opened this issue Apr 12, 2020 · 2 comments · Fixed by #1923
Milestone

Comments

@oliviertassinari
Copy link
Member

Environment

Tech Version
@material-ui/pickers v4.0.0-alpha.5

Steps to reproduce

  1. Open https://next.material-ui-pickers.dev/demo/datepicker#basic-usage
  2. Click on the first calendar icon
  3. Select a date
  4. The popup is still open

Expected behavior

The popup should close.

I think that we could consider a disableCloseOnSelect prop as the Autocomplete has for the current behavior.

@oliviertassinari oliviertassinari added the bug 🐛 Something isn't working label Apr 12, 2020
@CarsonF
Copy link

CarsonF commented Apr 15, 2020

FYI autoOk={true} does this

@oliviertassinari
Copy link
Member Author

oliviertassinari commented Apr 15, 2020

@CarsonF Thanks for raising this point up. It seems that we should handle desktop and mobile the opposite way, meaning autoOk={true} on a pointer device and autoOk={false} on a touch device. This would match the experience that is most commonly implemented. For instance, take Google Calendar, or Gmail as an example (compare the mobile app, with the web app).

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

Successfully merging a pull request may close this issue.

2 participants