Add d3 package, move percolate code into client