New issue
Advanced search Search tips

Issue 902290 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Nov 6
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

IntersectionObserver inside iFrame uses frame as ImplicitRoot, not the parent

Reported by dschub...@mozilla.com, Nov 6

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:65.0) Gecko/20100101 Firefox/65.0

Steps to reproduce the problem:
1. Open https://jsfiddle.net/8f9whxbk/11/
2. Observe that the intersectionRect is being reported as left=8, top=8

What is the expected behavior?
intersectionRect should represent the position within the parent document.

What went wrong?
According to the spec (https://w3c.github.io/IntersectionObserver/#intersectionobserver-implicit-root):

> or else the top-level browsing context’s document node (referred to as the implicit root) if the root attribute is null.

So Blink's behavior of using the frame's boundaries as root is probably wrong.

Did this work before? N/A 

Does this work in other browsers? N/A

Chrome version: 72.0.3603.0  Channel: n/a
OS Version: OS X 10.14
Flash Version: 

Firefox uses the parent document's boundaries.
 
Cc: szager@chromium.org
Components: Blink>Layout
Labels: Hotlist-Interop
Status: WontFix (was: Unconfirmed)
The parent document *is* being used as the implicit root; however, the intersection rect is reported in the coordinate system of the iframe document. From the spec:

"6. Map intersectionRect to the coordinate space of the viewport of the Document containing the target."

https://w3c.github.io/IntersectionObserver/#calculate-intersection-rect-algo

Ah thanks, I totally missed that.

Sign in to add a comment