0

Looking for a way that can help me 'cluster' some children nodes in their parent, and on a click event paper.on('cell:pointerdblclick', function(cellView,qqq,x,y));. expand or collapse them, depending in which state they are in, while the parent node remains intact.

Could not find it in the API, examples or anywhere I searched really. Any help would be appreciated.

filipbarak
  • 1,835
  • 2
  • 17
  • 28

1 Answers1

0

There is very little detail here to answer but i will give it a shot. Assuming you already figured out how to parent nodes, on cell double click of each child node you could resize it and reposition it to a vertex of the parent node and vice versa if you store the original positions of each

child node.
element.resize(,)
element.attr('position/x',value)
element.attr('position/y',value)

x and y can be calculated based on the parent node x and y size.