-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
🪟 🎉 Disable deselection of cursor field/primary key in the UI #20844
Merged
Merged
Changes from 1 commit
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
bc8425f
pull up field toggling callback to parent
josephkmh 8fc0e41
add unit tests to pk & cursor selection
josephkmh cd6d546
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh 6d41589
only prevent pk & cursor deselection if enabled
josephkmh e204121
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh 1069460
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh ccdb29e
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh b53c2a8
fix source defined pk and cursors
josephkmh 8a94cd9
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh 31c95c8
add comment
josephkmh 27218cd
fix typo
josephkmh ea5900e
prevent rendering new react node
josephkmh 9cbe65a
fix fieldSelection behavior with one unselected field
josephkmh 9d6e375
add comment
josephkmh 06f1a05
rename method
josephkmh 6ac4dc6
Merge branch 'master' into joey/column-selection-unit-tests
josephkmh d193819
fix merging duplicates of complex fieldPaths
josephkmh File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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.
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 converts the
fieldPath
(e.g.['path', 'to', 'field']
) into a string (e.g."[\"path\",\"to\",\"field\"]"
) so that we can add it as a unique value to the set. It gets converted back into an array before returning.This conversion between
String[]
>String
>String[]
might seem expensive, but it allows us use aSet
to avoid duplicates when merging, which avoids a lot of nested comparisons of arrays.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.
I think that's a reasonable tradeoff. It sounds like it would still be more efficient for a large sync catalog or a sync catalog with a lot of changes than what this was doing before, correct?
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.
Yes, at least as efficient, and in the best case more efficient 👍