Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
fix(subflows): make edges inside subflows directly clickable
Edges inside subflows defaulted to z-index 0, causing the subflow body
area (pointer-events: auto) to intercept clicks. Derive edge z-index
from the container's depth so edges sit just above their parent container
but below canvas blocks and child blocks.
  • Loading branch information
waleedlatif1 committed Apr 5, 2026
commit 2c12f499a6bb61adb21cbae5e290d530db663770
Original file line number Diff line number Diff line change
Expand Up @@ -3807,9 +3807,17 @@ const WorkflowContent = React.memo(
(targetNode?.zIndex ?? 21) + 1
)

// Edges inside subflows need a z-index above the container's body area
// (which has pointer-events: auto) so they're directly clickable.
// Derive from the container's depth-based zIndex (+1) so the edge sits
// just above its parent container but below canvas blocks (z-21+) and
// child blocks (z-1000).
const containerNode = parentLoopId ? nodeMap.get(parentLoopId) : null
const baseZIndex = containerNode ? (containerNode.zIndex ?? 0) + 1 : 0

return {
...edge,
zIndex: connectedToElevated ? elevatedZIndex : 0,
zIndex: connectedToElevated ? elevatedZIndex : baseZIndex,
data: {
...edge.data,
isSelected: selectedEdges.has(edgeContextId),
Expand Down
Loading