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

Fix clearing date picker by setting value to null #4312

Merged
merged 2 commits into from
Mar 31, 2023
Merged

Conversation

devongovett
Copy link
Member

Fixes #3187.

This fixes an issue where setting the controlled value of a DatePicker or DateRangePicker to null with granularity="minute" did not clear the calendar or time fields within the popover. This was because we never reset our state for partial selection (e.g. only date or time) when we have a complete value entered. The fix is to reset those when we emit onChange.

@rspbot
Copy link

rspbot commented Mar 31, 2023

@rspbot
Copy link

rspbot commented Mar 31, 2023

@rspbot
Copy link

rspbot commented Mar 31, 2023

## API Changes

unknown top level export { type: 'identifier', name: 'Column' }
unknown top level export { type: 'identifier', name: 'Column' }
unknown type { type: 'link' }
unknown type { type: 'link' }
unknown type { type: 'link' }
unknown type { type: 'link' }
unknown type { type: 'link' }
unknown type { type: 'link' }

@devongovett devongovett merged commit f629719 into main Mar 31, 2023
@devongovett devongovett deleted the datepicker-clear branch March 31, 2023 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants