-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
fix: LEAP-1615: LEAP-456: Fix tool unselect #6630
Conversation
Pan was blocking the app upon unselection, because there were no tools selected after this. When drawing tools are not displayed (like in usual RectangleLabels case) then it's hard to start drawing again.
✅ Deploy Preview for label-studio-docs-new-theme canceled.
|
✅ Deploy Preview for heartex-docs canceled.
|
The same way as Pan tool: default tool will be selected.
If user clicks on exact icon in popup panel the next tool is actually selected, because there are two handlers active at this moment. Fix this by blocking the more general one, used to rotate through all smart tools.
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.
approved! one point - isSeparated and iconComponent are both removed - are they no longer used anywhere?
as an aside, its been a long time since i touched anything editor and I dont remember off hand if we have tests specifically for the different tools and tags - if not would be great to see more tests for that in a seperate ticket
/git merge
|
It's used in tests and they are failing now, because naming was changed
@yyassi-heartex they are used when we render base tool via |
Pan was blocking the app upon unselection, because there were no tools selected after this. When drawing tools are not displayed (like in usual RectangleLabels case) then it's hard to start drawing again.
Also Selection tool (aka Move tool) was switched to the same behavior, allowing users to unselect it. The default tool will be selected then.
Also Smart tools selection is fixed — when you click on exact tool it's selected without weird jumps and rotation through other tools.
tools-improved.mov
PR fulfills these requirements
Change has impacts in these area(s)
Describe the reason for change
Users can be stuck after using Pan tool and unselecting it. Also that's inconsistent with Move tool.
Does this change affect performance?
nope
Does this change affect security?
nope
What alternative approaches were there?
Make Pan tool also not unselectable like Move tool. But for cases without drawing tools visible that would make it worse.
Does this PR introduce a breaking change?