elk icon indicating copy to clipboard operation
elk copied to clipboard

New hierarchyHandling strategy

Open soerendomroes opened this issue 3 years ago • 2 comments

hierarchyhandling: INCLUDE_CHILDREN is generally a little bit buggy and requires that the graphs are handled a little bit different than everything else, which often creates problems. As I see it one could introduce a different strategy, which instead of being aware of the inner/outer graph, just creates the necessary dummy ports to route the edges but still handles all levels separately. This would allow us to route edges through mixed directions and the graph is handled as if the hierarchical edges would not exist. The limitation would be that the dummy ports cannot be controlled and have to be free.

If different directions are used this might introduce bad layouts.

soerendomroes avatar Nov 17 '22 14:11 soerendomroes

In case anyone (like me) ends up finding this issue, I've created a two POCs (1 2) to show that this works for some use cases. I'm using ELKJS, so I ended up just creating the dummy ports myself in JS and then passing that layout to ELKJS.

nkalupahana avatar Sep 09 '24 22:09 nkalupahana

In case anyone (like me) ends up finding this issue, I've created a two POCs (1 2) to show that this works for some use cases. I'm using ELKJS, so I ended up just creating the dummy ports myself in JS and then passing that layout to ELKJS.

Interesting... This made me think of another approach, similar to POC 1, with an intermediate node to host the ports: sample

lredor avatar Sep 10 '24 09:09 lredor