-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Allow short search strings on new workspace page #20415
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
Conversation
|
|
||
| const filteredRepos = useMemo(() => { | ||
| const repos = [suggestedQuery.data || [], searchQuery.data || [], flattenedConfigurations ?? []].flat(); | ||
| const repos = [suggestedQuery.data || [], flattenedConfigurations ?? [], searchQuery.data || []].flat(); |
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.
This is done to artificially boost the priority of imported repos vs SCM-provided results.
Every time I change this, I think about how much we need to get rid of it entirely and just let listSuggestedRepositories receive a search string, which will do all deduplication and ordering by itself.
components/dashboard/src/data/git-providers/search-repositories-query.ts
Outdated
Show resolved
Hide resolved
Co-authored-by: Gero Posmyk-Leinemann <[email protected]>
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.
Code LGTM, tested and works ✔️
Co-authored-by: Gero Posmyk-Leinemann <[email protected]>
Description
Make it possible to search for repos that are 1 or 2 characters in length by removing the "please type at least 3 characters to search" limit.
Related Issue(s)
Fixes CLC-945
Builds on top of investigations done in #20413
How to test