From f357e50196992447548fbc654655a0d60bce8c44 Mon Sep 17 00:00:00 2001 From: satelllte <20585619+satelllte@users.noreply.github.com> Date: Tue, 30 Apr 2024 12:46:06 +0300 Subject: [PATCH] fix(OrbitControls): make "wheel" listener passive (#353) --- src/controls/OrbitControls.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controls/OrbitControls.ts b/src/controls/OrbitControls.ts index 87af957d..0dab03b6 100644 --- a/src/controls/OrbitControls.ts +++ b/src/controls/OrbitControls.ts @@ -409,7 +409,7 @@ class OrbitControls extends EventDispatcher { scope.domElement.addEventListener('contextmenu', onContextMenu) scope.domElement.addEventListener('pointerdown', onPointerDown) scope.domElement.addEventListener('pointercancel', onPointerCancel) - scope.domElement.addEventListener('wheel', onMouseWheel) + scope.domElement.addEventListener('wheel', onMouseWheel, { passive: true }) } this.dispose = (): void => {