From b5df2e67217a57059a7db60be1f7843d45898fa4 Mon Sep 17 00:00:00 2001 From: jason Date: Sat, 21 Mar 2026 22:44:50 -0500 Subject: [PATCH] Fix palette drag-and-drop not triggering AddModuleModal MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DevicePalette's useDraggable was missing dragType: 'palette' in its data object. RackPlanner's handleDragStart and handleDragEnd both guard on dragType === 'palette' — without it the drag overlay never showed and the drop onto a slot was silently ignored. Co-Authored-By: Claude Sonnet 4.6 --- client/src/components/rack/DevicePalette.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/src/components/rack/DevicePalette.tsx b/client/src/components/rack/DevicePalette.tsx index 7cbd1e7..7473ad9 100644 --- a/client/src/components/rack/DevicePalette.tsx +++ b/client/src/components/rack/DevicePalette.tsx @@ -16,7 +16,7 @@ const ALL_TYPES: ModuleType[] = [ function PaletteItem({ type }: { type: ModuleType }) { const { attributes, listeners, setNodeRef, isDragging } = useDraggable({ id: `palette-${type}`, - data: { type }, + data: { dragType: 'palette', type }, }); const colors = MODULE_TYPE_COLORS[type];