-
Notifications
You must be signed in to change notification settings - Fork 4k
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(Search): fix an error when showNoResults=false
and arrow down is pressed
#3938
fix(Search): fix an error when showNoResults=false
and arrow down is pressed
#3938
Conversation
💖 Thanks for opening this pull request! 💖 Here is a list of things that will help get it across the finish line:
We get a lot of pull requests on this repo, so please be patient and we will get back to you as soon as we can. |
…NoResults-is-false
Codecov Report
@@ Coverage Diff @@
## master #3938 +/- ##
==========================================
- Coverage 99.84% 99.84% -0.01%
==========================================
Files 184 178 -6
Lines 3218 3152 -66
==========================================
- Hits 3213 3147 -66
Misses 5 5
Continue to review full report at Codecov.
|
showNoResults=false
and arrow down is pressed
…NoResults-is-false
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Verified, the issue is fixed 👍
This PR fixes an unexpected error on
Search
module.When the Search module built with
showNoResults={false}
props, the<div class="result">
element won't present in DOM. And if a user types cursor-down (keycode: 40) in search input, then it raises an error:This PR can avoid that error by checking
menu
element existence.