From: Tanner Linsley Date: Wed, 17 Feb 2016 19:42:29 +0000 (-0700) Subject: Tooltips now respect stacked ordering X-Git-Tag: v2.0.0~37^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F2027%2Fhead;p=thirdparty%2FChart.js.git Tooltips now respect stacked ordering Tooltips detect the stacked scale property now, reversing when appropriate --- diff --git a/src/core/core.tooltip.js b/src/core/core.tooltip.js index b99d05c87..ae3e2d58a 100644 --- a/src/core/core.tooltip.js +++ b/src/core/core.tooltip.js @@ -253,7 +253,7 @@ module.exports = function(Chart) { datasetIndex: datasetIndex }); } - }); + }, null, element._yScale.options.stacked); helpers.each(this._active, function(active) { if (active) { @@ -262,7 +262,7 @@ module.exports = function(Chart) { backgroundColor: active._view.backgroundColor }); } - }); + }, null, element._yScale.options.stacked); tooltipPosition = this.getAveragePosition(this._active); tooltipPosition.y = this._active[0]._yScale.getPixelForDecimal(0.5); @@ -609,4 +609,4 @@ module.exports = function(Chart) { } } }); -}; \ No newline at end of file +};