Test inverted d3 text, clean up JS