kristw
Joined 13 years ago
Karma
18
Submissions
17
Member since
Dec 4
Visualize data at @twitter during the day. Battle with open data and code random stuffs at night.
View on Hacker NewsJoined 13 years ago
http://twitter.github.io/labella.js/with_text.html
The max width parameter is optional. I am not sure what are you trying to do with the graphs though. This library is not for graphs or trees. It's for points on single axis.
This example might be a more likely use case for left/right (all labels usually have same height)
But it won't support placing label on a zigzag path.
However, you have the choice to draw it your own way. https://github.com/twitter/labella.js/blob/master/docs/Rende...
renderer.getWaypoints(node) will give you the positions on the route and you can draw the connector as you like.