Artisanal label placement for d3 graphics
HTML JavaScript
Latest commit 386c2f3 Dec 8, 2016 @1wheel new text
Failed to load latest commit information.
lib lib swap Aug 11, 2016
.gitignore ignores zip Oct 25, 2016
LICENSE cleaning up root Mar 9, 2016 updates readme Mar 15, 2016
index.html new text Dec 8, 2016
index.js packified Oct 19, 2016
package.json v bump Oct 19, 2016
swoopy-drag.js packified Oct 19, 2016


The annotation layer is the most important thing we do

- Amanda Cox -


API Reference


Creates a new swoopyDrag.


Function called on each annotation object to determine its x position.


Function called on each annotation object to determine its y position.


Boolean. Pass true while adjusting annotations to enable dragging and add control points to paths.


Array of objects representing annotations. The path in each annotations will have its d attribute set to the path property. The text element will contain the text property and be translated by textOffset.

swoopyDrag.on('drag', [function])

Called as the labels or paths are dragged.