Skip to content

Commit 2ccfdfd

Browse files
committed
use zoomRect when zoomEnabled is true
1 parent 3213e49 commit 2ccfdfd

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/modules/ZoomPanSelection.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -682,7 +682,9 @@ export default class ZoomPanSelection extends Toolbar {
682682
const toolbar = this.ctx.toolbar
683683

684684
// Use boundingRect for final selection area
685-
const selRect = me.selectionRect.node.getBoundingClientRect()
685+
const selRect = w.globals.zoomEnabled
686+
? me.zoomRect.node.getBoundingClientRect()
687+
: me.selectionRect.node.getBoundingClientRect()
686688
const gridRectDim = me.gridRect.getBoundingClientRect()
687689

688690
// Local coords in the chart's grid

0 commit comments

Comments
 (0)