فهرست منبع

fix: stop click event bubbling in FlowNodeCard to allow node selection

Node selection was immediately cleared because onMouseDown set the
selectedNodeId but the click event bubbled up to the canvas which
reset it to null. Adding onClick stopPropagation fixes node properties
panel visibility.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Tony T 5 روز پیش
والد
کامیت
26ea965c07
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      client/src/pages/WorkflowDesigner.tsx

+ 1 - 0
client/src/pages/WorkflowDesigner.tsx

@@ -328,6 +328,7 @@ function FlowNodeCard({
       className="absolute cursor-move select-none"
       style={{ left: node.x, top: node.y, zIndex: isSelected ? 20 : 10 }}
       onMouseDown={(e) => { e.stopPropagation(); onDragStart(e); onSelect(); }}
+      onClick={(e) => e.stopPropagation()}
     >
       <div
         className="w-44 rounded-xl border-2 shadow-sm transition-shadow hover:shadow-md overflow-hidden"