Source code
Revision control
Copy as Markdown
Other Tools
Test Info: Warnings
- This test has a WPT meta file that expects 1 subtest issues.
- This WPT test may be referenced by the following Test IDs:
- /dom/events/non-cancelable-when-passive/passive-wheel-event-listener-on-div.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<title>passive wheel event listener on div</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-actions.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<script src="resources/scrolling.js"></script>
<style>
html, body {
overflow: hidden;
margin: 0;
}
#div {
position: fixed;
top: 0;
right: 0;
bottom: 0;
left: 0;
overflow: scroll;
}
</style>
<div class=remove-on-cleanup id=div>
<div style="height: 200vh"></div>
</div>
<script>
document.body.onload = () => runTest({
target: document.getElementById('div'),
eventName: 'wheel',
passive: true,
expectCancelable: false,
});
</script>