close
Skip to content

Block editor: Notify on block paste, matching copy and cut - #80910

Open
dhruvikpatel18 wants to merge 1 commit into
WordPress:trunkfrom
dhruvikpatel18:add/notify-on-block-paste
Open

Block editor: Notify on block paste, matching copy and cut#80910
dhruvikpatel18 wants to merge 1 commit into
WordPress:trunkfrom
dhruvikpatel18:add/notify-on-block-paste

Conversation

@dhruvikpatel18

Copy link
Copy Markdown
Contributor

What?

Closes #63964

Pasting whole blocks now shows a snackbar notice confirming the action, Pasted "Paragraph". for a single block, Pasted 3 blocks. for several matching the notice already shown on copy and cut. Applies to both the canvas and the List View.

Why?

Issue reports that duplicating a grid item in manual mode places the copy on top of the existing block, so there's no way to tell whether the action worked. Looking into it surfaced a broader, related gap: pasting blocks anywhere in the editor gives no confirmation at all, even though copy and cut both do.

The inconsistency exists even within paste itself:

Action Notice today
Copy block Copied "Paragraph" to clipboard.
Cut block Moved "Paragraph" to clipboard.
Copy styles Styles copied to clipboard.
Paste styles Pasted styles to Paragraph.
Paste block ❌ nothing

Testing Instructions

  1. Create a new post and add a Paragraph block with some text.
  2. Select the whole block (press Esc from inside it, or click its edge) and copy it.
  3. Paste. → A snackbar reads Pasted "Paragraph".
  4. Select two or more blocks, copy, then paste. → A snackbar reads Pasted 2 blocks.
  5. Open the List View, focus a row, copy it, focus another row, and paste. → The same notice appears.

Screenshots or screencast

Use of AI Tools

The Claude Code investigated the existing copy/cut notice paths, identified the four insertion sites, wrote useNotifyPaste, the handler call sites, the changelog entry, and the two e2e tests, and ran the verification below.

@github-actions github-actions Bot added the [Package] Block editor /packages/block-editor label Jul 30, 2026
@dhruvikpatel18 dhruvikpatel18 changed the title Block editor: Confirm whole-block pastes with a snackbar notice Block editor: Notify on block paste, matching copy and cut Jul 30, 2026
@dhruvikpatel18
dhruvikpatel18 marked this pull request as ready for review July 30, 2026 07:04
@dhruvikpatel18
dhruvikpatel18 requested a review from ellatrix as a code owner July 30, 2026 07:04
@github-actions

Copy link
Copy Markdown

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: dhruvikpatel18 <dhruvik18@git.wordpress.org>
Co-authored-by: noisysocks <noisysocks@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@shail-mehta shail-mehta added [Type] Bug An existing feature does not function as intended [Feature] Layout Layout block support, its UI controls, and style output. labels Jul 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

[Feature] Layout Layout block support, its UI controls, and style output. [Package] Block editor /packages/block-editor [Type] Bug An existing feature does not function as intended

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Grid: Unclear UX when duplicating a grid item in manual mode

2 participants