newcat / baklavajs

Graph / node editor in the browser using VueJS
http://baklava.tech
MIT License
1.6k stars 117 forks source link

flow visualization (Feature request) #250

Open CTB-Software opened 1 year ago

CTB-Software commented 1 year ago

Hi I am using V2 (Beta/Preview). is there a way of changing the the colour of the SVG Wire that connected 2 nodes when the calculate function runs. like for example an if node

calculate(inputs) { let result = 0; if(inputs.operation == "True") { this.input.input1.setWireColour("yellow"); <== idea this.input.input2.setWireColour("white"); <== idea result = inputs.input1; } else { this.input.input1.setWireColour("white"); <== idea this.input.input2.setWireColour("yellow"); <== idea result = inputs.input2; } return { result }; }

image

lublak commented 11 months ago

It would be nice to have a combination of both: https://github.com/newcat/baklavajs/issues/213 So possibly that the lines are animated in the direction in which the data flows.