You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Chrome, using event.preventDefault() and/or event.nativeEvent.preventDefault() within onWheel handler of an input[type=number] does not prevent number scrolling.
I would expect the same behaviour as shown in the HTML & JS example above.
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
Tested in react@16.8.5, react-dom@16.8.5 and Chrome v73. I'm unsure if previous versions are affected.
The text was updated successfully, but these errors were encountered:
jjenzz
changed the title
Cannot preventDefault onWheel event on input[type=number] in Chrome
Cannot preventDefault input[type=number] onWheel event in Chrome
Mar 23, 2019
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
In Chrome, using
event.preventDefault()
and/orevent.nativeEvent.preventDefault()
withinonWheel
handler of aninput[type=number]
does not prevent number scrolling.https://www.chromestatus.com/features/6662647093133312
React example: https://codesandbox.io/s/00kx423nyl
HTML & JS example for comparison: https://jsbin.com/warerunitu/edit?html,js,output
What is the expected behavior?
I would expect the same behaviour as shown in the HTML & JS example above.
Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?
Tested in
react@16.8.5
,react-dom@16.8.5
and Chrome v73. I'm unsure if previous versions are affected.The text was updated successfully, but these errors were encountered: