d2
d2 copied to clipboard
layout: fix dagre container-child connections
dagre doesn't handle container connections so the solution is to connect to a container's child, then cut the edge at the container's border. This works well if something outside is connecting to the container, but if it is from a child/descendant, then it will show up as an edge between descendants. Perhaps we can add a dummy node outside the container, and use that for connections going to a container from a descendant.
example:
container.first -> container.second: 1->2
container -> container.second: container->2
dagre layout (incorrect edge)

tala layout
