Skip to content

Conversation

Hector-Zhuang
Copy link
Contributor

This PR fixes an error that occurs when dragging a block from one editor to another while using the multiple column extension.

How Has This Been Tested?

  • Dragging blocks within editor configured with multiple column extension
  • Dragging blocks from one editor to another

Video

Screen.Recording.2025-08-19.at.5.55.49.PM.mov

Root Cause

When a block is dragged from an editor, its ID is regenerated. After the block is dropped, the target editor attempts to delete a block with the same ID. However, since that ID does not exist in the target editor, this leads to an error.

image image

FIx

The fix ensures that the target editor checks whether the block exists before attempting to delete it.

Copy link

vercel bot commented Aug 19, 2025

Someone is attempting to deploy a commit to the TypeCell Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

pkg-pr-new bot commented Aug 19, 2025

Open in StackBlitz

@blocknote/ariakit

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/ariakit@1950

@blocknote/code-block

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/code-block@1950

@blocknote/core

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/core@1950

@blocknote/mantine

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/mantine@1950

@blocknote/react

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/react@1950

@blocknote/server-util

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/server-util@1950

@blocknote/shadcn

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/shadcn@1950

@blocknote/xl-ai

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-ai@1950

@blocknote/xl-docx-exporter

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-docx-exporter@1950

@blocknote/xl-email-exporter

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-email-exporter@1950

@blocknote/xl-multi-column

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-multi-column@1950

@blocknote/xl-odt-exporter

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-odt-exporter@1950

@blocknote/xl-pdf-exporter

npm i https://pkg.pr.new/TypeCellOS/BlockNote/@blocknote/xl-pdf-exporter@1950

commit: b43c88f

@Hector-Zhuang
Copy link
Contributor Author

Also, there's a miscalculation of the cursor position, as you can see in the video—the cursor should only appear in a single editor

Copy link

vercel bot commented Aug 22, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Updated (UTC)
blocknote Error Error Aug 22, 2025 0:59am

Copy link
Contributor

@nperez0111 nperez0111 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @Hector-Zhuang, this looks great. Thanks for your detailed description of the problem

@nperez0111 nperez0111 merged commit cd37586 into TypeCellOS:main Aug 22, 2025
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants