RFC14 Autocomplete Suggestions - Front-End
Created by: ghost
RFC 14: Improve autocomplete suggestions
Changes:
- Updated suggestions mechanism of app search,
<QueryInput>
, to use new suggestions format - Some suggestions now static and some dynamic
Selecting a repo no longer goes to URL, only adds suggestion to input (need to review this)
TODO:
-
Tests / Fix minor bugs 🐛 🔍 -
@unknwon can we create a [standard format][baseSuggestions] for suggestions? -
Implement fuzzy-search together with filters selection (see below, update 29/Oct/19) -
Review which suggestions are shown
I'll be trying to fix the overflow to implement the keyword highlighting. Please give any feedback on this initial implementation PR. I took a while to get going but now everything is working well locally and I've found my way around the code.
This implementation should help align back-end x front-end, but as we have more time till 3.10 maybe we can discuss refactoring or any improvements to the search component?
Updates:
-
21/Oct/19: Keyword highlighting to be implemented in separate PR
-
29/Oct/2019: @lguychard @christinaforney and @hadrian-git reviewed the current implementation and decided on joining it with the current fuzzy-search implementation. @hadrian-git will work on using the current fuzzy-search API with new filter suggestions UX and receive feedback afterwards.
- When a new word is being typed, show suggestions from fuzzy-search and filter types, with filters shown on top.
- If a filter type is selected and it has static values, show static suggestions
- If a filter type is selected and it has dynamic values, fetch suggestions from back-end
- Try to use current fuzzy-search API to fetch these dynamic values
- If filters were selected in the query, and a word is typed, do a scoped fuzzy-search
-
12/Nov/2019: @christinaforney, @unknwon and @hadrian-git discussed on keyword highlighting and decided to have developed only the “invalid token” highlighting (described in the RFC as “squiggly underline”). The other feature of “boxing” filters/values will be revisited after the “invalid token” highlighting is done.
-
19/Nov/2019: Fixes for release 3.10: #6662 #6685