Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add notes for focus & non-"fully active" documents #6696

Merged
merged 3 commits into from
Oct 14, 2021
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions source
Original file line number Diff line number Diff line change
Expand Up @@ -73805,6 +73805,10 @@ END:VCARD</pre>
area of the document</dfn>. Which control is so designated changes over time, based on algorithms
in this specification.</p>

<p class="note">Even if a document is not <span>fully active</span> and not shown to the user, it
can still have a <span>focused area of the document</span>. If a document's <span>fully
active</span> state changed, its <span>focused area of the document</span> will stay the same.</p>
rakina marked this conversation as resolved.
Show resolved Hide resolved

<p>The <dfn>currently focused area of a top-level browsing context</dfn> <var>topLevelBC</var> at
any particular time is the <span>focusable area</span>-or-null returned by this algorithm:</p>

Expand Down Expand Up @@ -113972,6 +113976,10 @@ console.assert(container.firstChild instanceof SuperP);
means the element is not <span>being rendered</span>, though this might be overridden by the style
sheets.</p>

<p class="note">The <span>fully active</span> state does not affect wheter an element is
rakina marked this conversation as resolved.
Show resolved Hide resolved
<span>being rendered</span> or not. Even if a document is not <span>fully active</span> and not
shown at all to the user, elements within it can still qualify as "being rendered".</p>

<p>An element is said to <dfn>intersect the viewport</dfn> when it is <span>being rendered</span>
and its associated CSS layout box intersects the <span>viewport</span>.</p>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder what the viewport is for non-fully active documents... probably it stays the same? Otherwise a bunch of IntersectionObservers would fire whenever you enter bfcache.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, interesting. I read https://drafts.csswg.org/css2/#viewport a little bit, it doesn't really say much about the interaction with the document, but I think it should stay the same. Should we add a note here too?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I think something here would be good. I was thinking of maybe a note here plus a normative update to CSS2, but CSS2 is so environment-agnostic that maybe it makes sense to put something normative here instead, since HTML kind of "owns" the notion of what a viewport means for web browsers?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, added a note, PTAL :)


Expand Down