Skip to content

Conversation

@silviuaavram
Copy link
Collaborator

@silviuaavram silviuaavram commented Jul 5, 2020

What:

On Escape, if the menu is open, close it. If menu is closed, clear inputValue and selectedItem.

Why:

To close #719.

How:

In downshift revert to the previous behavior before the clear change was introduced.
In useCombobox change the reducer to clear inputValue and selectedItem if state.isOpen is false.

Checklist:

  • Documentation
  • Tests
  • TypeScript Types
  • Flow Types
  • Ready to be merged

@silviuaavram silviuaavram changed the base branch from master to v6 July 5, 2020 12:39
@silviuaavram silviuaavram merged commit 3496289 into v6 Jul 5, 2020
@silviuaavram silviuaavram deleted the fix/clear-close-on-escape branch July 5, 2020 12:53
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

Successfully merging this pull request may close these issues.

onChange called with null when esc pressed

2 participants