Merge branch 'main' into refactor/d3-drag

This commit is contained in:
moklick
2022-05-17 00:19:58 +02:00
4 changed files with 18 additions and 7 deletions
+10 -1
View File
@@ -16,7 +16,16 @@ const ColorSelectorNode: FC<NodeProps> = ({ data, isConnectable }) => {
Custom Color Picker Node: <strong>{data.color}</strong>
</div>
<input className="nodrag" type="color" onChange={data.onChange} defaultValue={data.color} />
<Handle type="source" position={Position.Right} id="a" style={sourceHandleStyleA} isConnectable={isConnectable} />
<Handle
type="source"
position={Position.Right}
id="a"
style={sourceHandleStyleA}
isConnectable={isConnectable}
onMouseDown={(e) => {
console.log('You trigger mousedown event', e);
}}
/>
<Handle type="source" position={Position.Right} id="b" style={sourceHandleStyleB} isConnectable={isConnectable} />
</>
);