Commits

Ralph Bean committed f3e96d8

Gave up on floating text values. There is definitely a bug in d3.

  • Participants
  • Parent commits b5bca8c

Comments (0)

Files changed (2)

tw2/d3/static/ext/bar.css

     fill: steelblue;
 }
 
-text.value {
-    fill: white;
-}
-
 .axis {
     shape-rendering: crispEdges;
 }

tw2/d3/static/ext/bar.js

                 .attr("class", "bar")
                 .append("rect");
 
-                bar.enter().append("text")
-                .attr("class", "value")
-                .attr("dx", -3)
-                .attr("dy", ".35em")
-                .attr("text-anchor", "end");
-
                 bar.exit().remove();
 
                 bar.transition().duration(750).attr("transform", function(d) {
                 .transition()
                 .attr("width", function(d) { return x(d.value); });
 
-                // This is not working yet.
-//                svg.selectAll("text.value")
-//                .data(data)
-//                .attr("y", y.rangeBand() / 2)
-//                .attr("x", function(d) { return x(d.value); })
-//                .text(function(d) { return format(d.value); });
-
                 svg.selectAll("g.x").transition().duration(750).call(xAxis);
                 svg.selectAll("g.y").transition().duration(750).call(yAxis);