Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Multi-editor drag & drop #1341

Merged
merged 9 commits into from
Jan 14, 2025
Merged

fix: Multi-editor drag & drop #1341

merged 9 commits into from
Jan 14, 2025

Conversation

matthewlipski
Copy link
Collaborator

@matthewlipski matthewlipski commented Dec 24, 2024

This PR fixes dragging & dropping blocks between different editors, and the sideMenuDetection option has been added. sideMenuDetection can be set to "viewport" or "editor" ("viewport" by default), and sets the detection area for showing the side menu.

Setting it to "viewport" makes the side menu appear whenever the cursor is beside a block, anywhere on the page. Setting it to "editor" makes the side menu only appear when the cursor is over the editor, or slightly to the left to account for the side menu area.

The same goes for dragging and dropping blocks, where "viewport" will clamp the mouse x-coordinate to the side of the editor.

Closes #657
Closes #1194
Closes #1246

Copy link

vercel bot commented Dec 24, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
blocknote ✅ Ready (Inspect) Visit Preview Jan 14, 2025 11:16am
blocknote-website ✅ Ready (Inspect) Visit Preview Jan 14, 2025 11:16am

Copy link
Collaborator

@YousefED YousefED left a comment

Choose a reason for hiding this comment

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

nice! left some quick comments

@matthewlipski matthewlipski merged commit 82e068c into main Jan 14, 2025
4 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
2 participants