Skip to content

Combining vertical and horizontal layout in organization charts #4218

Answered by chrtze
godiagonal asked this question in Layouting
Discussion options

You must be logged in to vote

Hey @godiagonal! I think this is a tough problem to achieve with a layouting library. Maybe it's possible for you to handle the placement of the sub nodes yourself? We found that it's often times easier to do the general layout with a library and then do some adaptions. Alternatively, I tried to reproduce your problem using ELKjs. Maybe this can be a starting point to configure your layout.

You can check it out by pasting this markup into the elkjs playground:

elk.direction: DOWN
nodePlacement.strategy: NETWORK_SIMPLEX

node n1
node n2
node n3 {
    portConstraints: FIXED_SIDE
    elk.direction: RIGHT
    
    port a1 {
        ^port.side: NORTH
    }

    node n6
    node n7
    node n8
…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@godiagonal
Comment options

Answer selected by godiagonal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants