From 1190bfc62e94f9d7dded3297d25d386f9373bbc4 Mon Sep 17 00:00:00 2001 From: Justin Edmund Date: Mon, 3 Nov 2025 23:03:07 -0800 Subject: [PATCH] fix: enable drag and drop reordering in Edra editor Add return false to drop handler so ProseMirror's Dropcursor extension can handle the actual node movement. Previously the handler would intercept drops but not perform any movement. --- src/lib/components/edra/extensions/drag-handle/index.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/lib/components/edra/extensions/drag-handle/index.ts b/src/lib/components/edra/extensions/drag-handle/index.ts index d8fbdaa..486a32d 100644 --- a/src/lib/components/edra/extensions/drag-handle/index.ts +++ b/src/lib/components/edra/extensions/drag-handle/index.ts @@ -387,6 +387,10 @@ export function DragHandlePlugin(options: GlobalDragHandleOptions & { pluginKey: const slice = new Slice(Fragment.from(newList), 0, 0) view.dragging = { slice, move: event.ctrlKey } } + + // Return false to let ProseMirror's default drop handler (from Dropcursor) take over + // This allows the actual node movement to happen + return false }, dragend: (view) => { view.dom.classList.remove('dragging')