- From: CSS Meeting Bot via GitHub <sysbot+gh@w3.org>
- Date: Thu, 15 Sep 2022 16:17:39 +0000
- To: public-css-archive@w3.org
The CSS Working Group just discussed `Approaches for dispatching highlight pointer events`, and agreed to the following: * `RESOLVED: Add the highlightFromPoint() API to CSS.highlights or DocumentOrShadowRoot` <details><summary>The full IRC log of that discussion</summary> <heycam> Topic: Approaches for dispatching highlight pointer events<br> <heycam> dandclark: problem we're trying to solve is making custom highlights interactives<br> <heycam> ... for scenarios like custom spell check, annotation popups over words<br> <heycam> ... a few months ago I came to the WG with a proposal for adding eventing for highlights<br> <heycam> ... when tehre's a pointer event, a highlight, we get a first crack at it<br> <heycam> ... dispatch events at highlights in priority order<br> <heycam> ... if none preventDefault() it, we give it to the normal DOM element<br> <florian> github: https://github.com/w3c/csswg-drafts/issues/7513<br> <heycam> ... goal here would be to allow non-coordinating highlight libraries to do reasonable things<br> <Rossen_> q?<br> <heycam> ... if you have say a spell check library, and a annotation library running, stopping propagation of an event would avoid two popups at once<br> <heycam> ... normal event propagation would allow this coordination without the 2 librariers knowing about each other<br> <heycam> ... however this is somewhat complicated, there was a simpler competing proposal<br> <heycam> ... providing "highlightsFromPoint", put a click event on the body, when there's a click pass the coordinates into this function<br> <heycam> ... some discussion for coming up with schemes where the events could then be dispatched in a manual way to highlights<br> <heycam> ... discussed in the issue, not a great way for non-coordinated libraries to coordinate an event loop<br> <heycam> ... that said, I think it's maybe worth pursuing this as a MVP API<br> <heycam> ... seems like a useful addition to the platform<br> <heycam> ... if in practice there turns out to be issues with non-coordinating highlight libraries working together, we then go back to pursue highlighting events in addition to that<br> <heycam> ... CSS.highlights.highlightFromPoint()<br> <heycam> ... some issues with shadow DOM<br> <TabAtkins> Seems useful to me. The coordination issue still needs to be addressed, but I don't think that blocks this as a useful ability. I like the API discussed.<br> <heycam> ... first let's get some feedback from the group. is this worth it as an initial step?<br> <Rossen_> q?<br> <flackr> +1 MVP of highlights from points seems useful even if we add events<br> <heycam> TabAtkins: seems useful to me. agree the coordination issue needs to be resolved, but that shouldn't block this useful primitive<br> <heycam> ... if this blocks general abilities, I still think it's worthwhile<br> <heycam> ... I like the API shape in the proposal<br> <TabAtkins> s/this blocks/this unblocks/<br> <heycam> olli: I agree this is probably good enough for now<br> <heycam> ... might need to think about shadow DOM for now, but we can tweak the proposal for that<br> <Rossen_> q?<br> <heycam> s/olli/smaug/<br> <heycam> dandclark: seem to have agreement on adding this<br> <heycam> ... would be good to dig into the shadow DOM issue<br> <heycam> ... does it go on DocumentOrShadowRoot?<br> <heycam> Rossen: let's resolve on adding the API, if we still have time at the end of this slot, we can come back to this issue<br> <dbaron> (My initial reaction is that DocumentOrShadowRoot is a good location because then it lives next to elementFromPoint, which it is similar to.)<br> <heycam> RESOLVED: Add the highlightFromPoint() API to CSS.highlights or DocumentOrShadowRoot<br> </details> -- GitHub Notification of comment by css-meeting-bot Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7513#issuecomment-1248320696 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 15 September 2022 16:17:41 UTC