From 9b233bfda6cb92d0db3902eb91cbb48db2504926 Mon Sep 17 00:00:00 2001 From: PT10 <38748694+PT10@users.noreply.github.com> Date: Tue, 16 Jun 2020 18:06:55 +0530 Subject: [PATCH] Removing pre filter on drag and applying it while points traversal (#2795) --- src/drag.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/drag.js b/src/drag.js index 28300d9c5..bc552195b 100644 --- a/src/drag.js +++ b/src/drag.js @@ -38,10 +38,10 @@ ChartInternal.prototype.drag = function(mouse) { main .selectAll('.' + CLASS.shapes) .selectAll('.' + CLASS.shape) - .filter(function(d) { - return config.data_selection_isselectable(d) - }) .each(function(d, i) { + if (!config.data_selection_isselectable(d)) { + return + } var shape = d3.select(this), isSelected = shape.classed(CLASS.SELECTED), isIncluded = shape.classed(CLASS.INCLUDED),