-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Hi,
While testing SnapLinks, I noticed an issue related to checkboxes that have pointer-events: none.
Observed behavior
- A checkbox with pointer-events: none is not detected/selected by SnapLinks.
- However, if the same checkbox is wrapped inside a
<label>element, SnapLinks works as expected.
Minimal example
<input checked type="checkbox" value="0" style="pointer-events: none;">
Checkbox with pointer-events: none
<br>
<label>
<input checked type="checkbox" value="0" style="pointer-events: none;">
Checkbox with pointer-events: none inside a label
</label>Possible cause
The issue may be related to this condition in content-scripts/ElementIndexer.js:
if (elPoint != elem && !elem.contains(elPoint) && elPoint.tagName !== 'LABEL')Reproducible demo
https://codesandbox.io/p/sandbox/funny-elion-wqpf2r
Additional notes
- I'm happy to help investigate or test potential fixes if needed.
- I was testing 3.1.16 version
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels