chore: non-passive
This commit is contained in:
parent
92a451419b
commit
76703cebf3
|
@ -68,7 +68,7 @@ export default class InputNormalizer extends decorate(Class) {
|
|||
this.target.addEventListener('touchmove', this.onTouchMove);
|
||||
window.addEventListener('touchend', this.onTouchEnd);
|
||||
}
|
||||
this.target.addEventListener('wheel', this.onWheel);
|
||||
this.target.addEventListener('wheel', this.onWheel, {passive: false});
|
||||
}
|
||||
|
||||
onAxisChange({index, value}) {
|
||||
|
@ -205,7 +205,7 @@ export default class InputNormalizer extends decorate(Class) {
|
|||
this.target.removeEventListener('touchmove', this.onTouchMove);
|
||||
window.removeEventListener('touchend', this.onTouchEnd);
|
||||
}
|
||||
this.target.removeEventListener('wheel', this.onWheel);
|
||||
this.target.removeEventListener('wheel', this.onWheel, {passive: false});
|
||||
this.target = undefined;
|
||||
this.targetForKeyUp = undefined;
|
||||
}
|
||||
|
|
|
@ -44,9 +44,9 @@ const Number = ({
|
|||
return undefined;
|
||||
}
|
||||
const input = inputRef.current;
|
||||
input.addEventListener('wheel', onWheel);
|
||||
input.addEventListener('wheel', onWheel, {passive: false});
|
||||
return () => {
|
||||
input.removeEventListener('wheel', onWheel);
|
||||
input.removeEventListener('wheel', onWheel, {passive: false});
|
||||
};
|
||||
});
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
|
|
Loading…
Reference in New Issue
Block a user