Commit 1bb3cf1c by Marcus Efraimsson Committed by Alexander Zobnin

keep legend scroll position when series are toggled (#12845)

parent b9f46668
......@@ -70,9 +70,9 @@ module.directive('graphLegend', function(popoverSrv, $timeout) {
var el = $(e.currentTarget);
var index = getSeriesIndexForElement(el);
var seriesInfo = seriesList[index];
var scrollPosition = $(elem.children('tbody')).scrollTop();
const scrollPosition = legendScrollbar.scroller.scrollTop;
ctrl.toggleSeries(seriesInfo, e);
$(elem.children('tbody')).scrollTop(scrollPosition);
legendScrollbar.scroller.scrollTop = scrollPosition;
}
function sortLegend(e) {
......
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