We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b83a5a9 + b5b0baa commit bd1ae0dCopy full SHA for bd1ae0d
src/features/dashboard/components/stepper-text-field/stepper-text-field.tsx
@@ -27,6 +27,22 @@ const StepperTextField: React.FC<StepperTextFieldProps> = ({
27
const { register, watch } = useFormContext();
28
const value = watch(name);
29
30
+ const handleWheel = (event: WheelEvent) => {
31
+ event.preventDefault();
32
+ };
33
+
34
+ React.useEffect(() => {
35
+ const input = document.querySelector('.stepper_text_field');
36
+ if (input) {
37
+ input.addEventListener('wheel', handleWheel, { passive: false });
38
+ }
39
+ return () => {
40
41
+ input.removeEventListener('wheel', handleWheel);
42
43
44
+ }, []);
45
46
return (
47
<div className='stepper_text_field'>
48
<div className='stepper_text_field__main'>
0 commit comments