Content injected with Document.insertAnonymousContent should be able to receive mouse events
Categories
(Core :: Layout, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox68 | --- | fixed |
People
(Reporter: mconley, Assigned: smaug)
References
Details
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
I'm using Document.insertAnonymousContent to insert a toggle to open Picture-in-Picture in bug 1535354.
I'm using nsIDOMWindowUtils.loadSheetUsingURIString to use an author stylesheet to style the toggle.
I need this toggle to be able to be styled differently on :hover, and I also need it to be able to respond to click events.
smaug suggested that the latter would be pretty straight-forward. I hope the former is also possible, since I'd rather not do mousemove hacks.
Reporter | ||
Comment 1•6 years ago
|
||
Hey smaug, you said that adding the ability to respond to click events on anonymous content would be straight forward, and only a few lines to add... do you have the ability to do that, or can you coach me on how to do that? And is supporting :hover possible?
Assignee | ||
Comment 2•6 years ago
|
||
html.css or ua.css can use pointer-events: auto; for the inserted content to get events. Not, also selection handling gets enabled, so perhaps better to play with other CSS stuff too.
Assignee | ||
Comment 3•6 years ago
|
||
Comment 4•6 years ago
|
||
Triaging to P3 to get this off the AWTY list :)
Assignee | ||
Comment 5•6 years ago
|
||
Mike, is the API any good for your use case?
Comment 8•6 years ago
|
||
bugherder |
Description
•