[csswg-drafts] [css-highlight-api] HighlightsFromPoint: Not dealing with invalid static ranges (#12003)

jnjaeschke has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-highlight-api] HighlightsFromPoint: Not dealing with invalid static ranges ==
The spec creates [temporary ranges for `StaticRange`s](https://drafts.csswg.org/css-highlight-api-1/#dom-highlightregistry-highlightsfrompoint:~:text=Let%20range%20be%20a%20Range%20object%20whose%20start%20node%20and%20end%20node%20are%20set%20to%20abstractRange%E2%80%99s%20start%20node%20and%20end%20node%20respectively%2C%20and%20start%20offset%20and%20end%20offset%20are%20set%20to%20abstractRange%E2%80%99s%20start%20offset%20and%20end%20offset%20respectively%2E) because `StaticRange`s currently don't support `getClientRect()`. However, this step assumes that creating a temp range succeeds, and also does not cover the case where an underlying `StaticRange` may be [invalid](https://dom.spec.whatwg.org/#staticrange-valid).

cc @ffiori @stephanieyzhang @smaug----

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12003 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 25 March 2025 13:05:10 UTC