bkrem/react-d3-tree

Longer vertical path

Momen-Mawad opened this issue · 2 comments

Hello,

how do I make the vertical path longer when pathFunc="step" ?

jp1357 commented

I had set the nodeSize (directly as an attribute of Tree)

<Tree
...
nodeSize={{ x: 220, y: 200 }}
/>

I'm pretty sure there is a better way to do it, but this works

Hello @jp1357,
thank you for your reply.

This indeed will reduce the size of nodes, letting the paths look bigger. But it because I have a picture plus a caption underneath it on top of each node, this solution was not flexible enough.

I was hoping for a way to lengthen the path vertically or horizontally.