-
Notifications
You must be signed in to change notification settings - Fork 530
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(numericMenu): take array into account for empty state (#4084)
This PR fixes a regression we introduced with the new behaviour of the Helper. We now preserve the empty state to avoid the parent to override the refinement when the widget is mounted. The `numericMenu` was relying on the previous behaviour to pick the "no value" element. We now check that every operator is empty. **Before** ![before](https://user-images.githubusercontent.com/6513513/64005002-c0235600-cb0f-11e9-80a1-74382cb47ebc.gif) **After** ![after](https://user-images.githubusercontent.com/6513513/64005037-cca7ae80-cb0f-11e9-888d-527676bff6b2.gif) You check the behaviour on the Storybook with [the `currentRefinement` stories](https://deploy-preview-4084--instantsearchjs.netlify.com/stories/?path=/story/currentrefinements--with-numericmenu).
- Loading branch information
Showing
2 changed files
with
69 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters