Skip to content

Commit 17c61c6

Browse files
committed
[css-content] more reorg
1 parent 0bdfdec commit 17c61c6

File tree

1 file changed

+66
-59
lines changed

1 file changed

+66
-59
lines changed

css-content/Overview.bs

Lines changed: 66 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ The 'content' property dictates what is rendered inside the element or pseudo-el
111111

112112
<dt><dfn type><<content-list>></dfn>
113113
<dd>
114-
[ <<string>> | contents | <<uri>> | <<quote>> | document-url | <<datetime>> | <<target>> | <<leader>> ]+
114+
[ <<string>> | contents | <<uri>> | <<quote>> | ''document-url'' | <<datetime>> | <<target>> | ''leader()'' ]+
115115

116116
See sections below for details on each of these.
117117

@@ -123,14 +123,18 @@ Issue: should the contents keyword be replaced with ''content()''
123123

124124

125125

126-
If the computed value of the part of the 'content' property that ends up being used is a single URI, then the element or pseudo-element is a replaced element. The box model defines different rules for the layout of replaced elements than normal elements. Replaced elements do not have '::before' and '::after' pseudo-elements; the 'content' property in the case of replaced content replaces the entire contents of the element's box.
126+
<p id="replacedContent">If the computed value of the part of the 'content' property that ends up being used is a single URI, then the element or pseudo-element is a replaced element. The box model defines different rules for the layout of replaced elements than normal elements. Replaced elements do not have '::before' and '::after' pseudo-elements; the 'content' property in the case of replaced content replaces the entire contents of the element's box.
127127

128128

129129

130130

131131
<h2 id="content-functions">
132132
Content Values and Functions</h2>
133133

134+
There are many ways of adding content to a document via the ''content'' property. This section describes them.
135+
136+
Issue: write better introduction to this section
137+
134138

135139
<h3 id="content-string">
136140
String</h3>
@@ -241,6 +245,43 @@ contents</h3>
241245
<h3 id="quotes">
242246
Quotes</h3>
243247

248+
HTML has long had the <code>q</code> element, used to delimit quotations. The ''quotes'' property, in conjunction with the various *-quote values of the ''content'' property, can be used to properly style such quotations.
249+
250+
251+
<h4 id="specifying-quotes">
252+
Specifying quotes with the 'quotes' property</h4>
253+
254+
255+
<pre class='propdef'>
256+
Name: quotes
257+
Value: [ <<string>> <<string>> ]+ | none
258+
Initial: depends on user agent
259+
Applies To: all elements
260+
Inherited: yes
261+
Percentages: n/a
262+
Computed Value: specified value
263+
Media: all
264+
</pre>
265+
266+
<p class="issue">The previous ED had an initial value of ''text'', which was an error. [[CSS21]] has initial value of "depends on user agent". Do we use <code>auto</code> for things like this, or is it just a UA stylesheet issue?
267+
268+
269+
This property specifies quotation marks for any number of embedded quotations. Values have the following meanings:
270+
271+
<dl dfn-type=value dfn-for=quotes>
272+
<dt><dfn>none</dfn>
273+
<dd>The ''open-quote'' and ''close-quote'' values of the 'content' property produce no quotations marks, as if they were ''no-open-quote'' and ''no-close-quote'' respectively.
274+
275+
<!--
276+
<dt><dfn>auto</dfn>
277+
<dd>TK
278+
-->
279+
280+
<dt>[ <<string>> <<string>> ]+
281+
<dd>Values for the ''open-quote'' and ''close-quote'' values of the 'content' property are taken from this list of pairs of quotation marks (opening and closing). The first (leftmost) pair represents the outermost level of quotation, the second pair the first level of embedding, etc. The user agent must apply the appropriate pair of quotation marks according to the level of embedding.
282+
</dl>
283+
284+
244285
<h4 id="inserting-quotes">
245286
The *-quote values of the content property
246287
</h4>
@@ -323,40 +364,6 @@ The *-quote values of the content property
323364
</pre>
324365
</div>
325366

326-
<h4 id="specifying-quotes">
327-
Specifying quotes with the 'quotes' property</h4>
328-
329-
HTML has long had the <code>q</code> element, used to delimit quotations. The ''quotes'' property, in conjunction with the various quote values of the content property, can be used to properly style such quotations.
330-
331-
332-
<pre class='propdef'>
333-
Name: quotes
334-
Value: [ <<string>> <<string>> ]+ | none
335-
Initial: depends on user agent
336-
Applies To: all elements
337-
Inherited: yes
338-
Percentages: n/a
339-
Computed Value: specified value
340-
Media: all
341-
</pre>
342-
343-
<p class="issue">The previous ED had an initial value of ''text'', which was an error. [[CSS21]] has initial value of "depends on user agent". Do we use <code>auto</code> for things like this, or is it just a UA stylesheet issue?
344-
345-
346-
This property specifies quotation marks for any number of embedded quotations. Values have the following meanings:
347-
348-
<dl dfn-type=value dfn-for=quotes>
349-
<dt><dfn>none</dfn>
350-
<dd>The ''open-quote'' and ''close-quote'' values of the 'content' property produce no quotations marks, as if they were ''no-open-quote'' and ''no-close-quote'' respectively.
351-
352-
<!--
353-
<dt><dfn>auto</dfn>
354-
<dd>TK
355-
-->
356-
357-
<dt>[ <<string>> <<string>> ]+
358-
<dd>Values for the ''open-quote'' and ''close-quote'' values of the 'content' property are taken from this list of pairs of quotation marks (opening and closing). The first (leftmost) pair represents the outermost level of quotation, the second pair the first level of embedding, etc. The user agent must apply the appropriate pair of quotation marks according to the level of embedding.
359-
</dl>
360367

361368

362369
<div class="example">
@@ -426,14 +433,19 @@ would produce:
426433
datetime
427434
</h3>
428435

436+
437+
<pre class="prod">
438+
<dfn>datetime</dfn> = [ date() | time() ];
439+
</pre>
440+
429441
<dl dfn-for="content, <content-list>" dfn-type=value>
430-
<dt><dfn><<datetime>></dfn>
442+
<dt>datetime
431443
<dd>Dates and times can be specified with two functions, 'date()' and 'time()'.
432444
</dl>
433445

434446
Issue: need more details on the separate functions. How are they defined? How are they formatted?
435447

436-
<h3>
448+
<h3 id="content-document-url">
437449
document-url
438450
</h3>
439451

@@ -451,9 +463,9 @@ document-url
451463
<h3 id="leaders">
452464
Leaders</h3>
453465

454-
A leader, sometimes known as a tab leader or a dot leader, is a repeating pattern used to visually connect content across horizontal spaces. They are most commonly used in tables of contents, between titles and page numbers. The ''leader()'' function, as a value for the content property, is used to create leaders in CSS. This function takes a string (the leader string), which describes the repeating pattern for the leader.
466+
A leader, sometimes known as a tab leader or a dot leader, is a repeating pattern used to visually connect content across horizontal spaces. They are most commonly used in tables of contents, between titles and page numbers. The ''leader()'' function, as a value for the content property, is used to create leaders in CSS. This function takes a string (the leader string), which describes the repeating pattern for the leader.
455467

456-
<h4>
468+
<h4 id="content-leader-function">
457469
The ''leader()'' function
458470
</h4>
459471

@@ -462,28 +474,23 @@ The ''leader()'' function
462474
<dd>Inserts a leader. See the section on <a href="#leaders">leaders</a> for more information.
463475
</dl>
464476

465-
466-
467-
468-
469-
470-
<pre class="prod">
477+
<pre class="prod">
471478
<dfn>leader()</dfn> = leader( dotted | solid | space | <<string>>);
472-
</pre>
479+
</pre>
473480

474-
Three keywords are shorthand values for common strings:
481+
Three keywords are shorthand values for common strings:
475482

476-
<dl dfn-type=value dfn-for="leader()">
477-
<dt><dfn>dotted</dfn>
478-
<dd>Equivalent to ''leader(".")''
479-
<dt><dfn>solid</dfn>
480-
<dd>Equivalent to ''leader("_")''
481-
<dt><dfn>space</dfn>
482-
<dd>Equivalent to ''leader(" ")''
483-
<dt><dfn><<string>></dfn>
484-
<dd>
483+
<dl dfn-type=value dfn-for="leader()">
484+
<dt><dfn>dotted</dfn>
485+
<dd>Equivalent to ''leader(".")''
486+
<dt><dfn>solid</dfn>
487+
<dd>Equivalent to ''leader("_")''
488+
<dt><dfn>space</dfn>
489+
<dd>Equivalent to ''leader(" ")''
490+
<dt><dfn><<string>></dfn>
491+
<dd>
485492
Issue: Define this.
486-
</dl>
493+
</dl>
487494

488495
<div class="example">
489496
<pre>
@@ -708,7 +715,7 @@ a::after { content: ", in the chapter entitled " target-text(attr(href url)) }
708715

709716

710717

711-
<h3 id="named-strings">
718+
<h3 id="named-strings-heading">
712719
Named strings</h3>
713720

714721
CSS3 introduces <dfn>named strings</dfn>, which are the textual equivalent of counters and which have a distinct namespace from counters. Named strings follow the same nesting rules as counters. The 'string-set' property accepts values similar to the 'content' property, including the extraction of the current value of counters.

0 commit comments

Comments
 (0)