-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Unified Search] Field autocomplete only matches from the beginning of the field name #158876
Comments
Pinging @elastic/kibana-visualizations @elastic/kibana-visualizations-external (Team:Visualizations) |
I think this task can be better addressed once the |
@dej611 @timductive Now that elastic/eui#7028 has been completed, is there additional work required by the EUI team to complete this task? |
@dej611 yes seems great, has the EUI version which contains this feature be merged in Kibana? |
I can see it landing here: #166868 |
While #166868 solves the truncation problem, I think there's still some work on our side for this feature to be done as it looks search findings are wiped out with an |
Had a quick look at this use case but it can be quite challening to support autocomplete beside starting matches:
|
(Cross-posting this comment from elastic/eui#7236 for more visibility and to get more UX feedback) I strongly think this usage of While the load time doesn't necessarily feel great, this is (IMO) the more technically correct approach that we specifically demo in our docs, and also given that EuiComboBox does not know the full list of suggestions (if they're async) and could therefore also be suggesting incomplete items regardless of matching logic. You can pull down my spike here to test this locally: main...cee-chen:kibana:combobox-async-suggestions |
EUI seems to be providing a set of capabilities that can be worked into a solution here, so I am in favor of closing the sibling issue over there. As for this issue, I am a +1 for Cee's recommendation - the loading state feels warranted and is more accurate than potentially showing a partial (and misleading) set of results. We acknowledge that there are likely some UX guidelines needed for building such search experiences. We'll track that in our patterns work and, ultimately, provide a clearer take on how we believe search should behave (e.g. don't show partial results, match anywhere in the string, etc.). |
…ic#171427) ## Summary This PR does NOT address elastic#158876, but helps reduce the confusion/cognitive dissonance of the async search results only matching on words from the start of the string, vs. `EuiComboBox` showing search results from anywhere in the string by default. Please see https://eui.elastic.co/#/forms/combo-box#async for more documentation on async searching. ### Before ![image](https://user-images.githubusercontent.com/924948/270275373-0d0df8c3-3a03-40e9-bc79-ea353147e419.gif) ### After ![image](https://user-images.githubusercontent.com/549407/280421058-a7476a75-bfbe-49c6-be81-7bd0b46e048c.gif) ### Checklist - ~[ ] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios~ No tests found - [x] Any UI touched in this PR is usable by keyboard only (learn more about [keyboard accessibility](https://webaim.org/techniques/keyboard/)) - [x] Any UI touched in this PR does not create any new axe failures (run axe in browser: [FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/), [Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US)) - [x] This renders correctly on smaller devices using a responsive layout. (You can test this [in your browser](https://www.browserstack.com/guide/responsive-testing-on-local-server)) - [x] This was checked for [cross-browser compatibility](https://www.elastic.co/support/matrix#matrix_browsers)
The Field autocomplete starts matching from the beginning of the field, but many long field names are only unique at the end of the field name. Think "cluster.host.name.id" where you want to search on just the "id".
Searching "devtiol" should match this field.
The text was updated successfully, but these errors were encountered: