Skip to content

List View: Slow group deletion #34310

@gwwar

Description

@gwwar

Description

In larger posts, if we delete nested blocks we can see the block icon and title disappearing before the rows are removed. Ideal behavior would quickly remove all deleted nodes in the list view.

Note that we can see a "fast" delete if we perform an action like, undo, then delete, or paste then delete.

I dug a bit into this one, and what's happening is that the clientIdsTree in ListView is only updated after all child buttons/block titles update. 🤔 I didn't have much luck with triggering a parent update, even when selecting for additional data like block order. We may want to dig into why behavior is different for a paste -> delete, or undo -> delete.

Step-by-step reproduction instructions

Screen Shot 2021-08-25 at 3 34 22 PM

  1. Open the post editor
  2. Open list view
  3. Make sure the post is somewhat larger, with a lot of nested content. (Drag a few patterns)
  4. Delete a block with a lot of children

Expected: The rows are quickly removed in one go.
Actual: The block icon and title disappears first. Removal of rows is slow.

Screenshots, screen recording, code snippet

slow.remove.mp4

Environment info

Gutenberg master (3f2593f)

Pre-checks

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

Metadata

Metadata

Assignees

Labels

[Feature] List ViewMenu item in the top toolbar to select blocks from a list of links.[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