Skip to content

Commit 8b34a5b

Browse files
committed
[css-regions] add note about whitespace and named flows
1 parent 60c3e1b commit 8b34a5b

2 files changed

Lines changed: 38 additions & 1 deletion

File tree

css3-regions/Overview.html

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -817,6 +817,23 @@ <h3 id=the-flow-into-property><span class=secno>3.1. </span>The ‘<a
817817
results.
818818
</div>
819819

820+
<div class=note><span class=note-prefix>Note </span>
821+
<p>Another consequence of moving elements into named flows is that
822+
surrounding whitespace is not moved into the named flow. If you have code
823+
like this:
824+
825+
<pre>span {flow-into: span-content}
826+
&lt;span&gt;one&lt;/span&gt;
827+
&lt;span&gt;two&lt;/span&gt;
828+
</pre>
829+
Then the ‘<code class=property>span-content</code>’ named flow
830+
contents will contain this:
831+
<pre>&lt;span&gt;one&lt;/span&gt;&lt;span&gt;two&lt;/span&gt;
832+
</pre>
833+
Which will change the display from "one two" to "onetwo". If whitespace is
834+
significant, then moving the parent that contains the whitespace to the
835+
named flow is required.</div>
836+
820837
<h3 id=the-flow-from-property><span class=secno>3.2. </span>The ‘<a
821838
href="#flow-from"><code class=property>flow-from</code></a>’ property</h3>
822839

css3-regions/Overview.src.html

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -611,7 +611,27 @@ <h3 id="the-flow-into-property">The 'flow-into' property</h3>
611611
to avoid unintended results.</p>
612612
</div>
613613

614-
614+
<div class="note"><span class="note-prefix">Note </span>
615+
<p>Another consequence of moving elements
616+
into named flows is that surrounding whitespace
617+
is not moved into the named flow.
618+
If you have code like this:
619+
<pre>span {flow-into: span-content}
620+
&lt;span&gt;one&lt;/span&gt;
621+
&lt;span&gt;two&lt;/span&gt;
622+
</pre>
623+
Then the 'span-content' named flow contents
624+
will contain this:
625+
<pre>&lt;span&gt;one&lt;/span&gt;&lt;span&gt;two&lt;/span&gt;
626+
</pre>
627+
Which will change the display
628+
from "one two" to "onetwo".
629+
If whitespace is significant,
630+
then moving the parent
631+
that contains the whitespace
632+
to the named flow
633+
is required.
634+
</div>
615635

616636

617637
<h3 id="the-flow-from-property">The 'flow-from' property</h3>

0 commit comments

Comments
 (0)