VizTooltips: Fix drag-zoom causing annotation init in other shared-cursor panels (#82986)

This commit is contained in:
Leon Sorokin 2024-02-17 00:35:41 -06:00 committed by GitHub
parent f23f50f58d
commit edb799bf82
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -341,8 +341,10 @@ export const TooltipPlugin2 = ({
});
config.addHook('setSelect', (u) => {
if (clientZoom || queryZoom != null) {
if (maybeZoomAction(u.cursor!.event)) {
let e = u.cursor!.event;
if (e != null && (clientZoom || queryZoom != null)) {
if (maybeZoomAction(e)) {
if (clientZoom && yDrag) {
if (u.select.height >= MIN_ZOOM_DIST) {
for (let key in u.scales!) {