daniel-lewis-ab / litegraph.js

A graph node engine and editor written in Javascript similar to PD or UDK Blueprints, comes with its own editor in HTML5 Canvas2D. The engine can run client side or server side using Node. It allows to export graphs as JSONs to be included in applications independently.
MIT License
16 stars 3 forks source link

Behavior difference in removing a link #20

Open liusida opened 4 months ago

liusida commented 4 months ago

If the user drag the end of the link from the input slot of the next node out (I usually remove links this way), the behavior is different from the original repo.

Original LiteGraph.js:

Screenshot 2024-06-05 193713

Here:

Screenshot 2024-06-05 193816

liusida commented 4 months ago

Also, clicking the middle point of a link produces a javascript error:

[Uncaught](lgraphcanvas.js:5621 Uncaught)
ReferenceError: options is not defined
atlasan commented 3 months ago

There is a LiteGraph property controlling the link behavior: LiteGraph.shift_click_do_break_link_from = false; // [false!] prefer false if too easy to break links - implement with ALT or TODO custom keys We could move back to default and put false, that's an option each editor could set itself. Middle click should work on forwardcompatible