From ac9967e49f67471f7795caf80ed8339177bc62d3 Mon Sep 17 00:00:00 2001
From: Florian Rivoal
Date: Thu, 15 Feb 2018 15:35:34 +0900
Subject: [PATCH 1/2] Move effects of containment on regions from
[css-contain-1] to [css-regions-1]
---
css-contain-1/Overview.bs | 16 ++++++----------
css-regions-1/Overview.bs | 38 +++++++++++++++++++++++++++-----------
2 files changed, 33 insertions(+), 21 deletions(-)
diff --git a/css-contain-1/Overview.bs b/css-contain-1/Overview.bs
index 9a21f92d290..c4603c0ffcc 100644
--- a/css-contain-1/Overview.bs
+++ b/css-contain-1/Overview.bs
@@ -224,15 +224,8 @@ Layout Containment
they remain part of the fragmentation context,
but do not receive any content from the fragmented flow.
- Specifically:
- - CSS Regions following the one which traps the content
- are still considered part of the region chain
- as returned by the {{NamedFlow/getRegions()}} method
- of the {{NamedFlow}} interface.
- - the {{Region/regionOverset}} attribute of the {{Region}} interface
- of the region which traps the content
- is set to ''overset'' if the content doesn't fit,
- even if it is not the last region in the region chain.
+ Note: [[CSS-REGIONS-1]] has details over how layout containment affects
+ regions.
3. If the contents of the element overflow the element,
they must be treated as ink overflow.
@@ -261,9 +254,11 @@ Style Containment
Giving an element style containment has the following effects:
- 1. The 'counter-increment', 'counter-set', 'flow-from', 'flow-into', and content (for the purpose of ''content/open-quote''/etc values) properties
+ 1. The 'counter-increment', 'counter-set', and content (for the purpose of ''content/open-quote''/etc values) properties
must be scoped to the element's sub-tree.
+ Note: [[CSS-REGIONS-1]] has normative requirements on how style containment affects regions.
+
A scoped property has its effects scoped to a particular element or subtree.
It must act as if the scoping element was the root of the document
for the purpose of evaluating the property's effects:
@@ -416,6 +411,7 @@ This appendix is informative.
Clarify to which box paint containment clips.
Move the interaction between containment and the bookmark-* and string-set properties to [[CSS-CONTENT-3]]
Remove the effects of style containment on the "break-*" properties.
+ Move the description of the effects of containement on regions from this specification to [[CSS-REGIONS-1]].
Changes from the
diff --git a/css-regions-1/Overview.bs b/css-regions-1/Overview.bs
index 1f01e79ed90..8b20666f95b 100644
--- a/css-regions-1/Overview.bs
+++ b/css-regions-1/Overview.bs
@@ -274,6 +274,14 @@ Region chain
into a region chain
according to the document order.
+
+Last region
+
+ A CSS region is deemed to be the last usable region
+ in a region chain
+ if it is the first region in that chain to have layout containment,
+ or the last region in the chain if none of them have layout containment.
+
Named flows
@@ -322,12 +330,12 @@ Regions flow breaking rules
at which point the next region
in the region chain
becomes the current region.
- If there are no more CSS Regions
+ If there are no more usable CSS Regions
in the region chain
and there is still content in the flow,
the positioning of the remaining content
is controlled by the 'region-fragment' property
- on the last CSS Region in the chain.
+ on the last usable CSS Region in the chain.
The CSS regions module follows
the fragmentation rules defined
@@ -462,6 +470,9 @@ The 'flow-into' property
The writing mode
on subsequent regions is ignored.
+ If an element has style containment (See [[!CSS-CONTAIN-1]]),
+ then the 'flow-into' property must be scoped to that element.
+
Note
The 'flow-into' property moves an element into the flow
@@ -607,6 +618,9 @@ The 'flow-from' property
which is an update to the behavior
described in [[!CSS21]].
+ If an element has
style containment (See [[!CSS-CONTAIN-1]]),
+ then the 'flow-from' property must be
scoped to that element.
+
Note
A block container becomes a
CSS Region
@@ -903,7 +917,7 @@ The region-fragment property
The 'region-fragment' property controls the behavior
- of the
last region
+ of the
last usable region
associated with a
named flow.
@@ -915,7 +929,7 @@ The region-fragment property
it is subject to the
overflow
property's computed value on the CSS Region.
- Region breaks must be ignored on the last region.
+ Region breaks must be ignored on the last usable region.
- break
@@ -929,7 +943,7 @@ The region-fragment property
See the breaking rules section.
A forced region break takes precedence over a natural break point.
- Flow content that follows the last break in the last region is not rendered.
+ Flow content that follows the last break in the last usable region is not rendered.
@@ -1152,6 +1166,7 @@ The NamedFlow interface
method returns the sequence
of regions in the
region chain
associated with the
named flow.
+ Regions after the
last usable region, if any, are included.
Note that the returned values
is a static sequence
in document order.
@@ -1240,7 +1255,7 @@ The Region interface
''overset''
- The region is the last one in the
+ The region is the last usable region in the
region chain and
not able to fit the remaining content from the named flow.
Note that the region's
@@ -1249,7 +1264,7 @@ The Region interface
property value can be used to control the
visibility of the overflowing content and the
'region-fragment' property controls whether or not fragmentation happens
- on the content that overflows the last region.
+ on the content that overflows the last usable region.
''fit''
@@ -1258,11 +1273,11 @@ The Region interface
The region's flow fragment content
fits into the region's
content box.
- If the region is the last one
+ If the region is the
last usable region
in the
region chain,
it means that the content
fits without overflowing.
- If the region is not the last one
+ If the region is not the
last usable region
in the
region chain,
that means the
named flow content
may be further fitted in subsequent regions.
@@ -1317,7 +1332,7 @@ The Region interface
is the first
Node
in the
named flow
and the
startOffset is zero.
- If the region is the last region
+ If the region is the
last usable region
in the
region chain
(but not the first and only one),
the
startContainer
@@ -1501,7 +1516,7 @@ Multi-column regions
the remaining
region chain.
However,
if a multicol region
- is the last region
+ is the
last usable region
in a
region chain,
then the multicol region must follow the
overflow column rules
@@ -2136,6 +2151,7 @@ Changes from
Febr
- Added three simpler examples to the introduction
- Moved complex example to the CSSWG wiki
+ - Moved the effects of CSS containment to this specification from [[CSS-CONTAIN-1]].
From 15b6dc130057eb0241e32fe85424d2a6a1a184d5 Mon Sep 17 00:00:00 2001
From: Florian Rivoal
Date: Fri, 16 Feb 2018 10:55:33 +0900
Subject: [PATCH 2/2] [css-regions-1] Add explicit reference to css-contain
---
css-regions-1/Overview.bs | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/css-regions-1/Overview.bs b/css-regions-1/Overview.bs
index 8b20666f95b..f05c192d6e3 100644
--- a/css-regions-1/Overview.bs
+++ b/css-regions-1/Overview.bs
@@ -280,7 +280,8 @@ Last region
A CSS region is deemed to be the
last usable region
in a
region chain
if it is the first region in that chain to have
layout containment,
- or the last region in the chain if none of them have
layout containment.
+ or the last region in the chain if none of them have
layout containment
+ (See [[!CSS-CONTAIN-1]]).
Named flows