This repository has been archived by the owner on Apr 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 320
fix: LEAP-218: Improve performance of search #1601
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bmartel
approved these changes
Oct 24, 2023
bmartel
reviewed
Oct 24, 2023
Codecov ReportAttention:
📢 Thoughts on this report? Let us know!. |
hlomzik
reviewed
Oct 27, 2023
hlomzik
suggested changes
Oct 30, 2023
Contributor
Author
/git merge master
|
hlomzik
reviewed
Oct 30, 2023
Co-authored-by: hlomzik <[email protected]>
Co-authored-by: hlomzik <[email protected]>
Co-authored-by: hlomzik <[email protected]>
Co-authored-by: hlomzik <[email protected]>
Co-authored-by: hlomzik <[email protected]>
Co-authored-by: hlomzik <[email protected]>
hlomzik
approved these changes
Oct 30, 2023
Co-authored-by: hlomzik <[email protected]>
MasherJames
pushed a commit
to HelloPareto/label-studio-frontend
that referenced
this pull request
Feb 29, 2024
* fix: LEAP-218: Improve performance of search * add new tests to see how it works between the original ui and our own search * working with external input search * implements new search and fix UI * split taxonomy and taxonomy search * add spacing line in the end of the file * add tests * change the expandedKeys method from its own method to filterDataTree * fix tests * add ff and fix some UX problems * remove useless function * expand just the mached value * fix small bugs and add comments * stop digging if it doesnt have chindrens * remove preset ff * check if is leaf * Update src/components/NewTaxonomy/NewTaxonomy.tsx Co-authored-by: hlomzik <[email protected]> * Update src/components/NewTaxonomy/TaxonomySearch.tsx Co-authored-by: hlomzik <[email protected]> * Update src/components/NewTaxonomy/TaxonomySearch.tsx Co-authored-by: hlomzik <[email protected]> * Update src/components/NewTaxonomy/TaxonomySearch.tsx Co-authored-by: hlomzik <[email protected]> * Update src/components/NewTaxonomy/TaxonomySearch.tsx Co-authored-by: hlomzik <[email protected]> * Update src/components/NewTaxonomy/NewTaxonomy.tsx Co-authored-by: hlomzik <[email protected]> * change changeValue method name to resetValue * Update src/components/NewTaxonomy/TaxonomySearch.tsx Co-authored-by: hlomzik <[email protected]> --------- Co-authored-by: juliosgarbi <[email protected]> Co-authored-by: hlomzik <[email protected]>
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR fulfills these requirements
[fix|feat|ci|chore|doc]: TICKET-ID: Short description of change made
ex.fix: DEV-XXXX: Removed inconsistent code usage causing intermittent errors
Change has impacts in these area(s)
(check all that apply)
Describe the reason for change
The original search tool from
antd tree-select
was having problem with performance when it was being used with a long list of choices, as the list was being highlighted, a lot of elements was being changed at the same time creating a big performance problemWhat does this fix?
We decided to stop using the original search tool and create our own search tool and attach to tree-select, with our own search tool we have more flexibility and we was able to fix the performance problem removing the highlight when the search matches with the choice item.
What libraries were added/updated?
none
Does this change affect performance?
As the search tool isn't highlighting the matches values, the performance is way better. Now we are using our own search tool to filter the results so we have more flexibility to treat the result as we want
Does this change affect security?
no
What alternative approaches were there?
We have spent some time trying different approaches, but unfortunately the component
tree-select
fromantd
doesn't give us a lot of options, we were able to change the way that the search was being done, but it's impossible to deactivate the highlight. Even though that would be possible to improve the performance changing the way that the search works, the items being highlighted would keep being a problem to the performance.What feature flags were used to cover this change?
fflag_feat_front_lsdv_5451_async_taxonomy_110823_short
Does this PR introduce a breaking change?
(check only one)
What level of testing was included in the change?
(check all that apply)