-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Dragging blocks stops their selection highlight #9027
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
Labels
Comments
This is almost certainly caused by focus being lost during drag and the auto-selection mechanism in I'm uncertain why focus is lost--that requires more digging. |
1 task
NB: This is also broken for workspace comments (and technically bubbles, though they don't have an actual highlight to show). |
BenHenning
added a commit
that referenced
this issue
May 13, 2025
## The basics - [x] I [validated my changes](https://developers.google.com/blockly/guides/contribute/core#making_and_verifying_a_change) ## The details ### Resolves Fixes #9027 ### Proposed Changes Ensure that a block being dragged is properly focused mid-drag. ### Reason for Changes Focus seems to be lost due to the block being moved to the drag layer, so re-focusing the block ensures that it remains both actively focused and selected while dragging. The regression was likely caused when block selection was moved to be fully synced based on active focus. ### Test Coverage This has been manually verified in Core's simple playground. At the time of the PR being opened, this couldn't be tested in the test environment for the experimental keyboard navigation plugin since there's a navigation connection issue there that needs to be resolved to test movement. It would be helpful to add a new test case for the underlying problem (i.e. ensuring that the block holds focus mid-drag) as part of resolving #8915. ### Documentation No new documentation should need to be added. ### Additional Information This was found during the development of google/blockly-keyboard-experimentation#511.
Fixed in #9034. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Check for duplicates
Description
Attempting to drag a block results in the block's selection highlight disappearing until dragging finishes (at which point it's restored).
Reproduction steps
Stack trace
Screenshots
No response
Browsers
No response
The text was updated successfully, but these errors were encountered: