I have a div for which pointer events is set to "none". I can click through to elements underneath fine, but if I right click an element and inspect it with Chrome, it gives me the div that's on top. Does anyone else have this issue? I don't remember it being an issue before.
Asked
Active
Viewed 1,641 times
2 Answers
6
Per this Chromium issue comment, you can hold Shift while using Chrome's inspect element from devtools, which will highlight elements (with parent element in red) even when they have pointer-events: none
on them.

Timo Tijhof
- 10,032
- 6
- 34
- 48

Rod911
- 752
- 5
- 14
-
1See also Firefox request: https://bugzilla.mozilla.org/show_bug.cgi?id=1129488 – Timo Tijhof Nov 11 '21 at 20:31
3
According to this https://code.google.com/p/chromium/issues/detail?id=136887 it is proper behaivor. What was before (when you can't inspect elements with "pointer-events:none") was a bug.
Chromium has tests for this fix: https://chromium.googlesource.com/chromium/blink.git/+/dfcf6a3782dcae5dd16baec94040b931b0791fa6/LayoutTests/inspector/elements/inspect-pointer-events-none.html

Vitaliy Z
- 133
- 5
-
I don't think it should be a bug, but this does answer my question. Thanks! – jshou Oct 10 '13 at 21:19