Skip to content

Shift-click breaks edit mode #34118

@k-boikov

Description

@k-boikov

Description

Accidental shift click on a single blocks without selecting another block switches the editor to Select mode (no caret on clicking, no way to edit text). Switching manually to Edit mode (top left button) does not exit Select mode (nor pressing Esc or clicking somewhere else). The only way to exit the Select mode is to shift click again on another block so multi block selection is triggered. The bug is only observed if no caret is present (no block has ever been selected).

Step-by-step reproduction instructions

  1. Add two paragraphs with random text
  2. Save draft
  3. Reload editor (F5)
  4. Without selecting anything hold shift and left click on the first paragraph, release shift
  5. Left click on the second paragraph or just try to edit the same one - only blue borders appear, no caret

Screenshots, screen recording, code snippet

Screenshot from 2021-08-17 16-54-47

Environment info

WordPress 5.9-alpha-51611
Gutenberg Version 11.3.0-rc.1
Chrome 91.0.4472.77
Ubuntu 20.04
(using npm run wp-env)
Issue was reported to me by a colleague running WP 5.7.2 and Gutenberg 11.2.1 on Chrome on Windows 10

Pre-checks

  • I have searched the existing issues.
  • I have tested with all plugins deactivated except Gutenberg.

Metadata

Metadata

Assignees

Labels

[Feature] Block Multi SelectionThe ability to select and manipulate multiple blocks[Feature] BlocksOverall functionality of blocks[Priority] HighUsed to indicate top priority items that need quick attention[Status] In ProgressTracking issues with work in progress[Type] BugAn existing feature does not function as intended

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions