Commit c08d031c authored by mikhail samoilov's avatar mikhail samoilov

Fill area chart to y coordinate axis, not to char boundary

parent 2fa9ce38
...@@ -791,10 +791,20 @@ ...@@ -791,10 +791,20 @@
})(); })();
var areaOnMain = (function () { var areaOnMain = (function () {
var area = d3.svg.area() var area;
.x(__axis_rotated ? function (d) { return getYScale(d.id)(d.value); } : xx)
.y0(__axis_rotated ? getCurrentWidth() : getCurrentHeight()) if (__axis_rotated) {
.y1(__axis_rotated ? xx : function (d) { return getYScale(d.id)(d.value); }); area = d3.svg.area()
.x0(function (d) { return getYScale(d.id)(0); })
.x1(function (d) { return getYScale(d.id)(d.value); })
.y(xx);
} else {
area = d3.svg.area()
.x(xx)
.y0(function (d) { return getYScale(d.id)(0); })
.y1(function (d) { return getYScale(d.id)(d.value); });
}
return function (d) { return function (d) {
var data = filterRemoveNull(d.values), x0, y0; var data = filterRemoveNull(d.values), x0, y0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment