Skip to content

Commit b458bf2

Browse files
committed
[css-content] reorganizing away
1 parent 4c6a411 commit b458bf2

File tree

1 file changed

+59
-55
lines changed

1 file changed

+59
-55
lines changed

css-content/Overview.bs

Lines changed: 59 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -263,63 +263,8 @@ Inserting quotes with the 'content' property
263263

264264
</dl>
265265

266-
Quotation marks are inserted in appropriate places in a document with the ''open-quote'' and ''close-quote'' values of the 'content' property. Each occurrence of ''open-quote'' or ''close-quote'' is replaced by one of the strings from the value of 'quotes', based on the depth of nesting.
267-
268-
''open-quote'' refers to the first of a pair of quotes, ''close-quote'' refers to the second. Which pair of quotes is used depends on the nesting level of quotes: the number of occurrences of ''open-quote'' in all generated text before the current occurrence, minus the number of occurrences of ''close-quote''. If the depth is 0, the first pair is used, if the depth is 1, the second pair is used, etc. If the depth is greater than the number of pairs, the last pair is repeated.
269-
270-
Note that this quoting depth is independent of the nesting of the source document or the formatting structure.
271-
272-
Some typographic styles require open quotation marks to be repeated before every paragraph of a quote spanning several paragraphs, but only the last paragraph ends with a closing quotation mark. In CSS, this can be achieved by inserting "phantom" closing quotes. The keyword ''no-close-quote'' decrements the quoting level, but does not insert a quotation mark.
273266

274267

275-
<div class="example">
276-
The following style sheet puts opening quotation marks on every paragraph in a <code>blockquote</code>, and inserts a single closing quote at the end:
277-
278-
<pre>
279-
blockquote p:before { content: open-quote }
280-
blockquote p:after { content: no-close-quote }
281-
blockquote p:last-child::after { content: close-quote }
282-
</pre>
283-
284-
</div>
285-
286-
For symmetry, there is also a ''no-open-quote'' keyword, which inserts nothing, but increments the quotation depth by one.
287-
288-
<div class="note">If a quotation is in a different language than the surrounding text, it is customary to quote the text with the quote marks of the language of the surrounding text, not the language of the quotation itself.
289-
</div>
290-
291-
<div class="example">
292-
For example, French inside English:
293-
294-
<blockquote>
295-
The device of the order of the garter is “Honi soit qui mal y pense.”
296-
</blockquote>
297-
298-
English inside French:
299-
300-
<blockquote>
301-
Il disait: «&#8197;Il faut mettre l’action en ‹&#8197;fast
302-
forward&#8197;›.&#8197;»
303-
</blockquote>
304-
305-
A style sheet like the following will set the 'quotes' property so that ''open-quote'' and ''close-quote'' will work correctly on all elements. These rules are for documents that contain only English, French, or both. One rule is needed for every additional language. Note the use of the child combinator (">") to set quotes on elements based on the language of the surrounding text:
306-
307-
<pre>
308-
:lang(fr) > * { quotes: "\00AB\2005" "\2005\00BB" "\2039\2005" "\2005\203A" }
309-
:lang(en) > * { quotes: "\201C" "\201D" "\2018" "\2019" }
310-
</pre>
311-
312-
313-
314-
The quotation marks are shown here in a form that most people will be able to type. If you can type them directly, they will look like this:
315-
316-
<pre>
317-
:lang(fr) > * { quotes: "« " " »" "‹ " " ›" }
318-
:lang(en) > * { quotes: "&#8220;" "&#8221;" "&#8216;" "&#8217;" }
319-
320-
</pre>
321-
</div>
322-
323268
<h3 id=content-datetime>
324269
datetime
325270
</h3>
@@ -789,6 +734,65 @@ Automatic counters and numbering: the 'counter-increment' and 'counter-reset' pr
789734
<h2 id="quotes">
790735
Quotes</h2>
791736

737+
738+
739+
Quotation marks are inserted in appropriate places in a document with the ''open-quote'' and ''close-quote'' values of the 'content' property. Each occurrence of ''open-quote'' or ''close-quote'' is replaced by one of the strings from the value of 'quotes', based on the depth of nesting.
740+
741+
''open-quote'' refers to the first of a pair of quotes, ''close-quote'' refers to the second. Which pair of quotes is used depends on the nesting level of quotes: the number of occurrences of ''open-quote'' in all generated text before the current occurrence, minus the number of occurrences of ''close-quote''. If the depth is 0, the first pair is used, if the depth is 1, the second pair is used, etc. If the depth is greater than the number of pairs, the last pair is repeated.
742+
743+
Note that this quoting depth is independent of the nesting of the source document or the formatting structure.
744+
745+
Some typographic styles require open quotation marks to be repeated before every paragraph of a quote spanning several paragraphs, but only the last paragraph ends with a closing quotation mark. In CSS, this can be achieved by inserting "phantom" closing quotes. The keyword ''no-close-quote'' decrements the quoting level, but does not insert a quotation mark.
746+
747+
748+
<div class="example">
749+
The following style sheet puts opening quotation marks on every paragraph in a <code>blockquote</code>, and inserts a single closing quote at the end:
750+
751+
<pre>
752+
blockquote p:before { content: open-quote }
753+
blockquote p:after { content: no-close-quote }
754+
blockquote p:last-child::after { content: close-quote }
755+
</pre>
756+
757+
</div>
758+
759+
For symmetry, there is also a ''no-open-quote'' keyword, which inserts nothing, but increments the quotation depth by one.
760+
761+
<div class="note">If a quotation is in a different language than the surrounding text, it is customary to quote the text with the quote marks of the language of the surrounding text, not the language of the quotation itself.
762+
</div>
763+
764+
<div class="example">
765+
For example, French inside English:
766+
767+
<blockquote>
768+
The device of the order of the garter is “Honi soit qui mal y pense.”
769+
</blockquote>
770+
771+
English inside French:
772+
773+
<blockquote>
774+
Il disait: «&#8197;Il faut mettre l’action en ‹&#8197;fast
775+
forward&#8197;›.&#8197;»
776+
</blockquote>
777+
778+
A style sheet like the following will set the 'quotes' property so that ''open-quote'' and ''close-quote'' will work correctly on all elements. These rules are for documents that contain only English, French, or both. One rule is needed for every additional language. Note the use of the child combinator (">") to set quotes on elements based on the language of the surrounding text:
779+
780+
<pre>
781+
:lang(fr) > * { quotes: "\00AB\2005" "\2005\00BB" "\2039\2005" "\2005\203A" }
782+
:lang(en) > * { quotes: "\201C" "\201D" "\2018" "\2019" }
783+
</pre>
784+
785+
786+
787+
The quotation marks are shown here in a form that most people will be able to type. If you can type them directly, they will look like this:
788+
789+
<pre>
790+
:lang(fr) > * { quotes: "« " " »" "‹ " " ›" }
791+
:lang(en) > * { quotes: "&#8220;" "&#8221;" "&#8216;" "&#8217;" }
792+
793+
</pre>
794+
</div>
795+
792796
<h4 id="specifying-quotes">
793797
Specifying quotes with the 'quotes' property</h4>
794798

0 commit comments

Comments
 (0)