Re: [csswg-drafts] [css-contain] Should scrollIntoView scroll to content-visibility: hidden subtree elements (#6529)

I think this may be a little more subtle than I first described. The question is do these hidden elements have a layout box? Well, we do want getBoundingClientRect to compute the right value for them since one of the use cases is to measure layout in a hidden subtree. So, when we call getBoundingClientRect we may update the rendering and generate a layout box. 

However, we don't want to do this for fragment link navigation (or any user controlled behavior), since these elements are not meant to be exposed to the user in any way. [Fragment link algorithm, step 3.4](https://html.spec.whatwg.org/multipage/browsing-the-web.html#scroll-to-fragid) uses scroll into view though, so we kind of don't want scroll into view to do anything whether or not there is a layout box generated here.

So the initial proposal is still the same: scroll into view or any scroll into view reliant algorithm has no effect on content-visibility hidden subtree, but the reasoning I think is a bit more subtle

-- 
GitHub Notification of comment by vmpstr
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6529#issuecomment-904660940 using your GitHub account


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

Received on Tuesday, 24 August 2021 13:50:57 UTC