Skip to content

Block locking on grid block - unable to drag and drop #67869

Description

@pdewouters

Description

When I set the locking option on a group (grid) block, with "Disable movement" UNchecked, to allow only moving child blocks, it doesn't seem to work as expected:
Moving blocks around with the toolbar arrows works, but drag and drop within the toolbar or the sidebar does not allow moving blocks.

Step-by-step reproduction instructions

  1. Open a page in the editor
  2. Add a group block (I tested with the grid variant)
  3. Add 3 images as child blocks
  4. Drag and drop child blocks in sidebar, and notice this works as expected
  5. Set the group lock option to "prevent removal" and apply to all blocks inside
  6. Try drag and drop again, it does not work, but the toolbar arrows do work

Screenshots, screen recording, code snippet

https://imgur.com/a/YaBJbEO

Environment info

WordPress 6.7.1

Macbook Pro

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

[Block] GroupAffects the Group Block (and row, stack and grid variants)[Feature] Block LockingThe API allowing for the ability to lock/unlock blocks[Feature] Drag and DropDrag and drop functionality when working with blocks[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