You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1. The element[=establishes an independent formatting context=].
546
+
1. The [=layout-containment/containing box=][=establishes an independent formatting context=].
543
547
544
548
<wpt>
545
549
contain-layout-ifc-022.html
@@ -548,10 +552,10 @@ Layout Containment</h3>
548
552
</wpt>
549
553
550
554
2. If at least one [=fragmentation container=] of a [=fragmentation context=] has [=layout containment=],
551
-
or if at least one [=fragmentation container=] of a [=fragmentation context=] is a descendant of an element with layout containment
555
+
or if at least one [=fragmentation container=] of a [=fragmentation context=] is a descendant of [=layout-containment/containing box=] for layout containment
552
556
<strong>and</strong> at least one subsequent [=fragmentation container=] of the same [=fragmentation context=]
553
557
is not a descendant of that same element with layout containment,
554
-
then the first element with[=layout containment=]
558
+
then the first [=layout-containment/containing box=] for[=layout containment=]
555
559
which is either a [=fragmentation container=] itself
556
560
or is an ancestor of a [=fragmentation container=]
557
561
must “trap” the remainder of the [=fragmented flow=]:
@@ -604,7 +608,7 @@ Layout Containment</h3>
604
608
In this [[CSS-REGIONS-1]] example,
605
609
content can flow from <code>#a</code> to <code>#b</code>,
606
610
from <code>#b</code> to <code>#c</code>.
607
-
However as <code>#c</code> is the last fragment container in the first layout-contained element,
611
+
However as <code>#c</code> is the last fragment container in the first containing box for layout containment,
608
612
it traps all the remaining content,
609
613
and nothing gets flowed into <code>#d</code>, <code>#e</code>, or <code>#f</code>.
610
614
</div>
@@ -624,7 +628,7 @@ Layout Containment</h3>
624
628
contain-layout-ink-overflow-020.html
625
629
</wpt>
626
630
627
-
4. The element acts as a containing block for absolutely positioned and fixed positioned descendants.
631
+
4. The [=layout-containment/containing box=] acts as a containing block for absolutely positioned and fixed positioned descendants.
628
632
629
633
<wpt>
630
634
contain-layout-006.html
@@ -633,15 +637,15 @@ Layout Containment</h3>
633
637
contain-layout-cell-002.html
634
638
</wpt>
635
639
636
-
5. The element creates a <a>stacking context</a>.
640
+
5. The [=layout-containment/containing box=] creates a <a>stacking context</a>.
637
641
638
642
<wpt>
639
643
contain-layout-016.html
640
644
contain-layout-017.html
641
645
contain-layout-018.html
642
646
</wpt>
643
647
644
-
6. [=Forced breaks=] are allowed within elements with[=layout containment=],
648
+
6. [=Forced breaks=] are allowed within [=layout-containment/containing boxes=] for[=layout containment=],
645
649
but do not propagate to the parent as otherwise described in [[CSS-BREAK-3#break-between]].
646
650
647
651
<wpt>
@@ -654,9 +658,9 @@ Layout Containment</h3>
654
658
655
659
7. For the purpose of the 'vertical-align' property,
656
660
or any other property whose effects
657
-
need to relate the position of the containing element's baseline
661
+
need to relate the position of the [=layout-containment/containing box=]'s baseline
658
662
to something other than its descendants,
659
-
the containing element is treated as having no baseline.
663
+
the [=layout-containment/containing box=] is treated as having no baseline.
660
664
661
665
<wpt>
662
666
contain-layout-baseline-001.html
@@ -672,16 +676,16 @@ Layout Containment</h3>
672
676
Possible optimizations that can be enabled by <a>layout containment</a> include (but are not limited to):
673
677
674
678
1. When laying out the page,
675
-
the contents of separate containing elements
679
+
the contents of separate containing boxes
676
680
can be laid out in parallel,
677
681
as they're guaranteed not to affect each other.
678
682
679
683
2. When laying out the page,
680
-
if the containing element is off-screen or obscured
681
-
and the layout of the visible parts of the screen do not depend on the size of the containing element
682
-
(for example, if the containing element is near the end of a block container,
684
+
if the containing box is off-screen or obscured
685
+
and the layout of the visible parts of the screen do not depend on the size of the containing box
686
+
(for example, if the containing box is near the end of a block container,
683
687
and you're viewing the beginning of the block container),
684
-
the layout of the containing elements' contents can be delayed or done at a lower priority.
688
+
the layout of the containing box' contents can be delayed or done at a lower priority.
685
689
686
690
(When paired with <a>size containment</a>,
687
691
this optimization can be applied more liberally.)
@@ -691,7 +695,8 @@ Style Containment</h3>
691
695
692
696
Note: Style Containment is at-risk.
693
697
694
-
Giving an element <dfn export>style containment</dfn> has the following effects:
698
+
Giving an element <dfn export>style containment</dfn>
699
+
and has the following effects:
695
700
696
701
1. The 'counter-increment' and 'counter-set' properties
697
702
must be <a for=property>scoped to the element's sub-tree</a>
@@ -782,19 +787,21 @@ Style Containment</h3>
782
787
783
788
Possible optimizations that can be enabled by <a>style containment</a> include (but are not limited to):
784
789
785
-
1. Whenever a property is changed on a descendant of the containing element,
790
+
1. Whenever a property is changed on a descendant of an element with [=style containment=],
786
791
calculating what part of the DOM tree is "dirtied" and might need to have its style recalculated
787
-
can stop at the containing element.
792
+
can stop at the containing box.
788
793
789
794
<h3 id='containment-paint'>
790
795
Paint Containment</h3>
791
796
792
797
If the element does not generate a <a>principal box</a> (as is the case with 'display' values of ''display/contents'' or ''display/none''),
793
-
or if the element is an <a spec="css-display-3">internal table element</a> other than ''display/table-cell'',
794
-
or if the element is an <a spec="css-display-3">internal ruby element</a>,
795
-
or if the element's <a>principal box</a> is a <a spec="css-display-3" lt="atomic inline">non-atomic</a><a spec="css-display-3">inline-level</a> box,
798
+
or its [=principal box=] is an <a spec="css-display-3">internal table box</a> other than ''display/table-cell'',
799
+
or an <a spec="css-display-3">internal ruby box</a>,
800
+
or a <a spec="css-display-3" lt="atomic inline">non-atomic</a><a spec="css-display-3">inline-level</a> box,
796
801
paint containment has no effect.
797
-
Otherwise, giving an element <dfn export>paint containment</dfn> has the following effects:
802
+
Otherwise, giving an element <dfn export>paint containment</dfn>
803
+
makes its [=principal box=] a <dfn for=paint-containment>containing box</dfn> for [=paint containment=]
804
+
and has the following effects:
798
805
799
806
<wpt>
800
807
contain-paint-002.html
@@ -815,7 +822,7 @@ Paint Containment</h3>
815
822
816
823
1. The contents of the element
817
824
including both the paint of the descendants and their geometry
818
-
must be clipped to the <a>padding edge</a> of the element's <a>principal box</a>,
825
+
must be clipped to the <a>padding edge</a> of the [=paint-containment/containing box=],
819
826
taking <a>corner clipping</a> into account.
820
827
This does not include the creation of any mechanism
821
828
to access or indicate the presence of the clipped content;
@@ -840,7 +847,7 @@ Paint Containment</h3>
840
847
contain-paint-clip-018.html
841
848
contain-paint-clip-019.html
842
849
</wpt>
843
-
2. The element acts as a containing block for absolutely positioned and fixed positioned descendants.
850
+
2. The [=paint-containment/containing box=] acts as a containing block for absolutely positioned and fixed positioned descendants.
844
851
845
852
<wpt>
846
853
contain-paint-009.html
@@ -849,14 +856,14 @@ Paint Containment</h3>
849
856
contain-paint-023.html
850
857
contain-paint-024.html
851
858
</wpt>
852
-
3. The element creates a <a>stacking context</a>.
859
+
3. The [=paint-containment/containing box=] creates a <a>stacking context</a>.
853
860
854
861
<wpt>
855
862
contain-paint-020.html
856
863
contain-paint-021.html
857
864
contain-paint-025.html
858
865
</wpt>
859
-
4. The element[=establishes an independent formatting context=].
866
+
4. The [=paint-containment/containing box=][=establishes an independent formatting context=].
860
867
861
868
<wpt>
862
869
contain-paint-ifc-011.html
@@ -871,13 +878,13 @@ Paint Containment</h3>
871
878
<div class=informative>
872
879
Possible optimizations that can be enabled by <a>paint containment</a> include (but are not limited to):
873
880
874
-
1. If the containing element is off-screen or obscured,
881
+
1. If the containing box is off-screen or obscured,
875
882
the UA can directly skip trying to paint its contents,
876
883
as they're guaranteed to be off-screen/obscured as well.
877
884
878
885
2. Unless the clipped content is made accessible via a separate mechanism
879
886
such as the 'overflow', 'resize', or 'text-overflow' properties,
880
-
the UA can reserve "canvas" space for the element exactly the element's size.
887
+
the UA can reserve "canvas" space for the box exactly the box's size.
881
888
(In similar, scrollable, situations, like ''overflow: hidden'',
882
889
it's possible to scroll to the currently-clipped content,
0 commit comments