Intent to prototype: Document as explicit root of an intersection observer
75 views
Skip to first unread message
Frédéric Wang
unread,
Feb 24, 2020, 3:51:28 AM2/24/20
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Sign in to report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to
Summary: This is an enhancement to the IntersectionObserver API.
Currently, it is possible to use the top level document (implicit root)
or to specify an Element (e.g. {root: document.scrollingElement}). None
of these options provides a way to specify a root corresponding to the
bounding box of an iframe's window. This proposal is about allowing an
explicit Document root, in order to cover that case.
Secure contexts: Same as IntersectionObserver
Is this feature enabled by default in sandboxed iframes: Same as
IntersectionObserver
As mentioned in the original intent-to thread, the root can be in a
different-origin document so there is some security aspect to consider
here. AFAIK, the proposal does not make the situation worse though. I
can't find any conclusion on the security aspect in the original
intent-to thread, so I guess someone more knowledgeable than me on this
should comment.