fix: make top handles type=source so connections can be dragged from them
React Flow only allows initiating a drag from type=source handles. Top handles were type=target so users could never start a connection from the top of any node. With connectionMode=loose, source-to-source connections are already allowed, so all handles can now be source.
This commit is contained in:
@@ -38,7 +38,7 @@ export function BaseNode({ data, selected, icon: typeIcon }: BaseNodeProps) {
|
||||
minWidth: 140,
|
||||
}}
|
||||
>
|
||||
<Handle type="target" position={Position.Top} className="!bg-[#30363d] !border-[#8b949e]" />
|
||||
<Handle type="source" position={Position.Top} className="!bg-[#30363d] !border-[#8b949e]" />
|
||||
|
||||
{/* Icon */}
|
||||
<div
|
||||
|
||||
@@ -80,7 +80,7 @@ export function ProxmoxGroupNode(props: NodeProps<Node<NodeData>>) {
|
||||
<div className="flex-1 relative" />
|
||||
</div>
|
||||
|
||||
<Handle type="target" position={Position.Top} className="!bg-[#30363d] !border-[#8b949e]" />
|
||||
<Handle type="source" position={Position.Top} className="!bg-[#30363d] !border-[#8b949e]" />
|
||||
<Handle type="source" position={Position.Bottom} className="!bg-[#30363d] !border-[#8b949e]" />
|
||||
|
||||
{/* Cluster handles — left/right for same-cluster links */}
|
||||
|
||||
Reference in New Issue
Block a user