Testing solutions for saving svg that contains external styles
The colours of the circles are set via css classes (not inline via d3) Just the svg node is saved, whilst keeping the external css using saveSvgAsPng (all client side)
Note: You can drag the circles and the image save the current interaction/render
Updated missing url https://rawgit.com/exupero/saveSvgAsPng/gh-pages/saveSvgAsPng.js to https://cdn.jsdelivr.net/gh/exupero/savesvgaspng/gh-pages/savesvgaspng.js
https://d3js.org/d3.v4.min.js
https://rawgit.com/exupero/saveSvgAsPng/gh-pages/saveSvgAsPng.js