Re: [csswg-drafts] [css-position-3] Containing block of dialog fixed position children (#8040)

> It also changes the containing block of the elements in a way that it escapes transformed ancestors etc.

Yes, it does, but that is on purpose and a good thing, because it lets the top layer render on top and outside of its parented boxes (by reparenting the boxes in the layout tree. I think that is well-defined and makes sense because the top layer is a special stacking context on top of and outside of other page contents.

> It also causes layout ordering issues in some cases. E.g., if you have a top layer with a regular fixed-pos inside, what is the hypothetical position of that fixed-pos?

The containing block of that fixed position element's box is the containing box that is a container for fixed position (*not* the containing DOM element). So if there was a transformed element ancestor box of it *within* the top layer then the fixed position element would be contained by it. Otherwise it would be contained by the root (aka LayoutView in Chromium, aka viewport).

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


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

Received on Friday, 10 May 2024 21:32:06 UTC