Skip to content

fix: Fix bug that could cause unintend block movements#9818

Open
gonfunko wants to merge 1 commit intov13from
i-dont-like-to-move-it-move-it
Open

fix: Fix bug that could cause unintend block movements#9818
gonfunko wants to merge 1 commit intov13from
i-dont-like-to-move-it-move-it

Conversation

@gonfunko
Copy link
Copy Markdown
Contributor

@gonfunko gonfunko commented May 5, 2026

The basics

The details

Resolves

Fixes #9708

Proposed Changes

This PR fixes a bug that caused unintended block movements in Chrome. When blocks are focused, they scroll themselves into view, so that keyboard navigation doesn't focus an offscreen block. Now, blocks only do so if there was already a focused node - this still works in the keyboard nav case (if the block gains focus via a click, it must have been on screen, and if it gains focus via the keyboard, something else e.g. the workspace or another block had to have focus first), but avoids a situation where blocks would try to refocus themselves or focus during intermediate transition states between the drag layer and main workspace layer where focus could be lost as elements were added and removed from the DOM.

@gonfunko gonfunko requested a review from a team as a code owner May 5, 2026 22:18
@gonfunko gonfunko requested a review from mikeharv May 5, 2026 22:18
@github-actions github-actions Bot added the PR: fix Fixes a bug label May 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

PR: fix Fixes a bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants