Re: [csswg-drafts] [css-contain] Top layer interactions with content-visibility: hidden. (#6728)

The CSS Working Group just discussed `[css-contain] Top layer interactions with content-visibility: hidden`, and agreed to the following:

* `RESOLVED: Elements with ancestors of content-visbility:hidden will have no boxes while in top layer. If removed from top layer they get their box back`

<details><summary>The full IRC log of that discussion</summary>
&lt;dael> Topic: [css-contain] Top layer interactions with content-visibility: hidden<br>
&lt;dael> github: https://github.com/w3c/csswg-drafts/issues/6728<br>
&lt;dael> vlad: Content-visibility: hidden skip their contents meaning they don't paint. When element is in top layer changes topology of the tree so element is hoisted to root level<br>
&lt;dael> vlad: Prop is we should say it doesn't paint or generate layout box<br>
&lt;Rossen_> q?<br>
&lt;smfr> q+<br>
&lt;dael> vlad: could ensure it does generate and paint, but precludes a lot of the optimization<br>
&lt;TabAtkins> q+<br>
&lt;dael> vlad: Another is we refuse to allow in top layer, but also seems inconsistent<br>
&lt;Rossen_> ack smfr<br>
&lt;dael> smfr: The top layer spec says that top layer elements, containg block is inital contain block. Hoisted out of anything they're inside of. Why is content-visbility different?<br>
&lt;chrishtr> q+<br>
&lt;dael> vlad: It's hoisted out of all containment. There's no way to optimize performance of this b/c then have to always keep rendering up to date. Not sure how common case is. I was hoping this could have the same rule as display:none<br>
&lt;dael> smfr: That means we need a new concept in css that not containing block or z-order<br>
&lt;dael> TabAtkins: Just say decendents don't generate boxes liked display:none.<br>
&lt;Rossen_> q?<br>
&lt;dael> smfr: How does that impact rest of the dialog?<br>
&lt;dael> TabAtkins: You can't focus something that doesn't have a box. That gets skipped<br>
&lt;dael> smfr: I guess same as calling show dialog on display:none<br>
&lt;dael> TabAtkins: yes<br>
&lt;Rossen_> ack TabAtkins<br>
&lt;dael> TabAtkins: I put a comment in the issue. Except explicit difference in spec, anything that diverges from display:none should be looked at with suspicion. If there's no reason for difference should be same as display:none<br>
&lt;dael> chrishtr: I agree with that outcome<br>
&lt;Rossen_> ack chrishtr<br>
&lt;dael> chrishtr: Whated to clarify tricky situation is you have an element skipped by virtue of having and ancestor. You have a skipped thing with an unskipped ancestor which is bad. That's why Vlad said we'd lose optimizations. If you treat like dsiplay:none where it has a box but if in top layer it becomes like display:none<br>
&lt;Rossen_> q?<br>
&lt;dael> chrishtr: Consistent and simple. I don't think there's a concept to hoist something to the top of tree and make it visible<br>
&lt;dael> Rossen_: Validating an assumption, none of the content elements are a11y, right?<br>
&lt;dael> vlad: correct. Can be targets of aria label, but not exposed<br>
&lt;dael> Rossen_: Cool<br>
&lt;dael> Rossen_: Sounds like a good approach. Other thoughts?<br>
&lt;dael> smfr: content-visbility: auto implications?<br>
&lt;dael> vlad: That's the next issue<br>
&lt;dael> Rossen_: What is resolution?<br>
&lt;dael> Rossen_: Option 1?<br>
&lt;dael> vlad: yes<br>
&lt;dael> chrishtr: If there is a content-visbility ancestor there is no box. It's in the top layer, but has no box<br>
&lt;smfr> is the “it’s in the top layer” observable?<br>
&lt;dael> Rossen_: Prop: Elements with ancestors of content-visbility:hidden will have no boxes while in top layer. If removed from top layer they get their box back<br>
&lt;dael> Rossen_: Obj?<br>
&lt;dael> Rossen_: smfr does the irc question you have?<br>
&lt;dael> smfr: chrishtr said in the top layer, is that observable? If so, through dom?<br>
&lt;dael> chrishtr: Discussed if it was observable, but not sure<br>
&lt;dael> vlad: Right, I don't know the answer to this<br>
&lt;dael> chrishtr: Might be if you try...don't know<br>
&lt;dael> smfr: If it has a backdrop is that display:none too?<br>
&lt;dael> vlad: yeah, it would be same<br>
&lt;dael> chrishtr: Backdrop pseudo spec has an immediately proceeding box. And there's not box. Might need to clarify text but should be same<br>
&lt;dael> Rossen_: Obj?<br>
&lt;dael> RESOLVED: Elements with ancestors of content-visbility:hidden will have no boxes while in top layer. If removed from top layer they get their box back<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6728#issuecomment-960257101 using your GitHub account


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

Received on Wednesday, 3 November 2021 22:51:47 UTC