Reputation: 307
I want to get list of all parallel edges within a collection and give them seperate color
My code is
cy.elements().parallelEdges().animate({ 'style':{'line-color':'coral', 'width': '10px'} }, {duration: 1000 })
But it end up in coloring all edges....
Upvotes: 0
Views: 345
Reputation: 6074
You call the function on all elements in cytoscape, the documentation implys, that you have to callthe function on edges.
cy.edges().parallelEdges().animate();
Edit: cy.edges() wont work, the funciton is designed to give you the parallel edges to a set collection of edges, so if you want to achieve this, I think you have to:
Upvotes: 1