w3c/csswg-drafts

[cssom-view] elementFromPoint, elementsFromPoint, and caretPositionFromPoint should not return an element inside a shadow tree

Open

#556 建立於 2016年9月30日

在 GitHub 查看
 (54 留言) (0 反應) (0 負責人)HTML (545 fork)batch import
Help WantedNeeds EditsNeeds Testcase (WPT)cssom-view-1topic: shadow

倉庫指標

Star
 (3,546 star)
PR 合併指標
 (平均合併 87天 7小時) (30 天內合併 24 個 PR)

描述

elementFromPoint and elementsFromPoint should not return an element inside a shadow tree. Instead, it should look for the highest shadow host of the element and return that instead so that it doesn't leak an element in shadow trees.

See the shadow DOM specification.

More precisely, once these methods are added on DocumentOrShadowRoot interface, then we need to retarget the element we found against the context object.

貢獻者指南