-
Notifications
You must be signed in to change notification settings - Fork 224
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
Consider calling search callback after a blur ? #152
Comments
You could just add a check to the blur callback for any difference between the latest query and a cached value of the last search query. |
Of course, but I thought this could be VS responsibility |
Going along these lines, is it possible to make the "tab" key on a "value" go to the next set of facet, value inputs? As opposed to what happens now which is that it blurs the input. Basically what I'm asking is for a way to "match" the value regardless of whether it actually matched or not. The use case is that we allow for values not in the callbacks of the facetMatching method. I considered a 'keydown' event, checking for a 'tab' keypress. However this won't work because I can't attach an event to non-existing input fields. I also tried setting this as the value matching callback:
At first I thought it might be an ugly solution, but it still won't work because it will actually execute a search on tab (which incidentally does what @Intrepidd wanted to do). So maybe if this is the only simple solution, is there a way to stop the search event from firing on tab? |
To achieve what you want just turn the |
Also, it shouldn't be blurring the input on tab. If that's happening thats a bug and should be filed separately. Make sure you mention your browser and OS. |
Alright let me give that one a try. And as for the blurring, I could've sworn it was the intended behavior. Try it out on the fiddle that Intrepidd posted on this thread. Meanwhile, here it is: OS: Windows, Linux, Mac OS To replicate, enter a category, tab over to the value, enter something, tab again. After that tab, it won't go to the next set but will just blur out. |
Consider the following jsfiddle : https://jsfiddle.net/zL847sqy/
If you type : "title" then tab, then a value, then tab again (or click outside of the field), the
search
callback is not fired.Of course one could use the
blur
callback (as commented in the fiddle) but this is unreliable as you would only want the callback to be fired after a change, not for each blur, imagine a search being performed live after each call to thesearch
callback.WDYT ?
The text was updated successfully, but these errors were encountered: