Skip to content

Commit abdb55d

Browse files
lillestabatkins
andauthored
[css-conditional-5] Size query containers and box tree re-ordering #11213 (#12960)
* [css-conditional-5] Size query containers and box tree re-ordering #11213 Per resolution: #11213 (comment) * Apply suggestion from @tabatkins --------- Co-authored-by: Tab Atkins Jr. <jackalmage@gmail.com>
1 parent 9829054 commit abdb55d

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

css-conditional-5/Overview.bs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,6 +437,22 @@ Container Queries</h2>
437437
can be conditioned by querying against it,
438438
using the ''@container'' [=conditional group rule=].
439439

440+
An ancestor element that generates a box is not an eligible container for
441+
[=container size queries=] if that box is not an ancestor box of any boxes
442+
generated by the querying element.
443+
444+
<div class=note>
445+
There are cases where the box for a [=pseudo-element=] is generated as a
446+
sibling box of its originating element's box. If we allowed querying the size
447+
of a sibling box, it would introduce layout cycles.
448+
449+
For example, the ''::scroll-marker-group'' and ''::scroll-button()'' pseudo-elements
450+
generate sibling boxes of their originating element's box.
451+
These pseudo-elements will not be able to query their originating scroller
452+
for [=container size queries=]. They will, however, be able to query other
453+
eligible [=query container=] ancestors.
454+
</div>
455+
440456
<div class=example>
441457
For example, we can define the main content area and sidebar as containers,
442458
and then describe a ''.media-object'' that changes

0 commit comments

Comments
 (0)