From fc3262ffbd8f410f16417158097e445ed0b3748c Mon Sep 17 00:00:00 2001 From: Nick the Sick Date: Mon, 21 Jul 2025 16:10:12 +0200 Subject: [PATCH 1/2] fix: allow dragging between blocks again --- packages/core/src/extensions/SideMenu/SideMenuPlugin.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts b/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts index 6b2060d73c..b499a43a0c 100644 --- a/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts +++ b/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts @@ -498,7 +498,7 @@ export class SideMenuView< } const { isDropPoint, isDropWithinEditorBounds, isDragOrigin } = context; - if (!isDropWithinEditorBounds) { + if (!isDropWithinEditorBounds && isDropPoint) { // Any time that the drop event is outside of the editor bounds (but still close to an editor instance) // We dispatch a synthetic event that is in the bounds of the editor instance, to have the correct drop point this.dispatchSyntheticEvent(event); From 9ef143e05bf392d8d439737c33ccc0318158994e Mon Sep 17 00:00:00 2001 From: Nick the Sick Date: Mon, 21 Jul 2025 16:18:12 +0200 Subject: [PATCH 2/2] fix: always try to collapse the selection, unless text is being dragged --- .../core/src/extensions/SideMenu/SideMenuPlugin.ts | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts b/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts index b499a43a0c..7a744540bf 100644 --- a/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts +++ b/packages/core/src/extensions/SideMenu/SideMenuPlugin.ts @@ -504,15 +504,13 @@ export class SideMenuView< this.dispatchSyntheticEvent(event); } - if (isDropPoint && isDragOrigin) { - // The current instance is both the drop point and the drag origin - // no-op, normal drop handling will take over - return; - } - if (isDropPoint) { - // The current instance is the drop point, but not the drag origin + // The current instance is the drop point + if (this.pmView.dragging) { + // Do not collapse selection when text content is being dragged + return; + } // Because the editor selection is unrelated to the dragged content, we // don't want PM to delete its content. Therefore, we collapse the // selection.