Skip to content

Commit

Permalink
[c] (2) Change how the content models of <title> and <option> are def…
Browse files Browse the repository at this point in the history
…ined (move from prose additions to more formal content model descriptions, and tighten up the requirements)

Affected topics: HTML

git-svn-id: http://svn.whatwg.org/webapps@8147 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Aug 20, 2013
1 parent b34eec6 commit 31647fc
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 17 deletions.
13 changes: 7 additions & 6 deletions complete.html
Expand Up @@ -256,7 +256,7 @@

<header class=head id=head><p><a href=http://www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
<hgroup><h1 class=allcaps>HTML</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 19 August 2013</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 20 August 2013</h2>
</hgroup><dl><dt><strong>Web developer edition:</strong></dt>
<dd><strong><a href=http://developers.whatwg.org/>http://developers.whatwg.org/</a></strong></dd>
<dt>Multiple-page version:</dt>
Expand Down Expand Up @@ -11190,6 +11190,7 @@ <h5 id=paragraphs><span class=secno>3.2.5.3 </span>Paragraphs</h5>

<h4 id=requirements-relating-to-bidirectional-algorithm-formatting-characters><span class=secno>3.2.6 </span>Requirements relating to bidirectional-algorithm formatting characters</h4>

<!--CLEANUP-->
<p><a href=#text-content>Text content</a> in <a href=#html-elements>HTML elements</a> with <code><a href=#text>Text</a></code> nodes in their <a href=#concept-html-contents title=concept-html-contents>contents</a>, and
text in attributes of <a href=#html-elements>HTML elements</a> that allow free-form text, may contain characters
in the ranges U+202A to U+202E and U+2066 to U+2069 (the bidirectional-algorithm formatting
Expand Down Expand Up @@ -12398,7 +12399,7 @@ <h4 id=the-title-element><span class=secno>4.2.2 </span>The <dfn><code>title</co
<dt><a href=#element-dfn-contexts title=element-dfn-contexts>Contexts in which this element can be used</a>:</dt>
<dd>In a <code><a href=#the-head-element>head</a></code> element containing no other <code><a href=#the-title-element>title</a></code> elements.</dd>
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#text-content title="text content">Text</a>.</dd>
<dd><a href=#text-content title="text content">Text</a> that is not <a href=#inter-element-whitespace>inter-element whitespace</a>.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>Neither tag is omissible.</dd>
<dt><a href=#element-dfn-attributes title=element-dfn-attributes>Content attributes</a>:</dt>
Expand All @@ -12417,8 +12418,6 @@ <h4 id=the-title-element><span class=secno>4.2.2 </span>The <dfn><code>title</co

<p>There must be no more than one <code><a href=#the-title-element>title</a></code> element per document.</p>

<p>The <code><a href=#the-title-element>title</a></code> element must not be empty.</p>

<p class=note>If it's reasonable for the <code><a href=#document>Document</a></code> to have no title, then the
<code><a href=#the-title-element>title</a></code> element is probably not required. See the <code><a href=#the-head-element>head</a></code> element's content
model for a description of when the element is required.</p>
Expand Down Expand Up @@ -51314,7 +51313,9 @@ <h4 id=the-option-element><span class=secno>4.10.12 </span>The <dfn><code>option
<dd>As a child of a <code><a href=#the-datalist-element>datalist</a></code> element.</dd>
<dd>As a child of an <code><a href=#the-optgroup-element>optgroup</a></code> element.</dd>
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#text-content title="text content">Text</a>.</dd>
<dd>If the element has a <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute and a <code title=attr-option-value><a href=#attr-option-value>value</a></code> attribute: Empty.</dd>
<dd>If the element has a <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute but no <code title=attr-option-value><a href=#attr-option-value>value</a></code> attribute: <a href=#text-content title="text content">Text</a>.</dd>
<dd>If the element has no <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute: <a href=#text-content title="text content">Text</a> that is not <a href=#inter-element-whitespace>inter-element whitespace</a>.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>An <code><a href=#the-option-element>option</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> can be omitted if
the <code><a href=#the-option-element>option</a></code> element is immediately followed by another <code><a href=#the-option-element>option</a></code> element, or
Expand Down Expand Up @@ -51370,7 +51371,7 @@ <h4 id=the-option-element><span class=secno>4.10.12 </span>The <dfn><code>option
attribute.</p>

<p>The <code title=attr-option-label><a href=#attr-option-label>label</a></code> content attribute, if specified, must not be
empty. If the attribute is not specified, then the element itself must not be empty.</p>
empty.</p>

<p>The <dfn id=attr-option-value title=attr-option-value><code>value</code></dfn> attribute provides a value for
element. The <dfn id=concept-option-value title=concept-option-value>value</dfn> of an <code><a href=#the-option-element>option</a></code> element is
Expand Down
13 changes: 7 additions & 6 deletions index
Expand Up @@ -256,7 +256,7 @@

<header class=head id=head><p><a href=http://www.whatwg.org/ class=logo><img width=101 src=/images/logo alt=WHATWG height=101></a></p>
<hgroup><h1 class=allcaps>HTML</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 19 August 2013</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 20 August 2013</h2>
</hgroup><dl><dt><strong>Web developer edition:</strong></dt>
<dd><strong><a href=http://developers.whatwg.org/>http://developers.whatwg.org/</a></strong></dd>
<dt>Multiple-page version:</dt>
Expand Down Expand Up @@ -11190,6 +11190,7 @@ http://software.hixie.ch/utilities/js/live-dom-viewer/?%3C%21DOCTYPE%20HTML%3E%0

<h4 id=requirements-relating-to-bidirectional-algorithm-formatting-characters><span class=secno>3.2.6 </span>Requirements relating to bidirectional-algorithm formatting characters</h4>

<!--CLEANUP-->
<p><a href=#text-content>Text content</a> in <a href=#html-elements>HTML elements</a> with <code><a href=#text>Text</a></code> nodes in their <a href=#concept-html-contents title=concept-html-contents>contents</a>, and
text in attributes of <a href=#html-elements>HTML elements</a> that allow free-form text, may contain characters
in the ranges U+202A to U+202E and U+2066 to U+2069 (the bidirectional-algorithm formatting
Expand Down Expand Up @@ -12398,7 +12399,7 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p&gt;
<dt><a href=#element-dfn-contexts title=element-dfn-contexts>Contexts in which this element can be used</a>:</dt>
<dd>In a <code><a href=#the-head-element>head</a></code> element containing no other <code><a href=#the-title-element>title</a></code> elements.</dd>
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#text-content title="text content">Text</a>.</dd>
<dd><a href=#text-content title="text content">Text</a> that is not <a href=#inter-element-whitespace>inter-element whitespace</a>.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>Neither tag is omissible.</dd>
<dt><a href=#element-dfn-attributes title=element-dfn-attributes>Content attributes</a>:</dt>
Expand All @@ -12417,8 +12418,6 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p&gt;

<p>There must be no more than one <code><a href=#the-title-element>title</a></code> element per document.</p>

<p>The <code><a href=#the-title-element>title</a></code> element must not be empty.</p>

<p class=note>If it's reasonable for the <code><a href=#document>Document</a></code> to have no title, then the
<code><a href=#the-title-element>title</a></code> element is probably not required. See the <code><a href=#the-head-element>head</a></code> element's content
model for a description of when the element is required.</p>
Expand Down Expand Up @@ -51314,7 +51313,9 @@ You cannot submit this form when the field is incorrect.</samp></pre>
<dd>As a child of a <code><a href=#the-datalist-element>datalist</a></code> element.</dd>
<dd>As a child of an <code><a href=#the-optgroup-element>optgroup</a></code> element.</dd>
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#text-content title="text content">Text</a>.</dd>
<dd>If the element has a <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute and a <code title=attr-option-value><a href=#attr-option-value>value</a></code> attribute: Empty.</dd>
<dd>If the element has a <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute but no <code title=attr-option-value><a href=#attr-option-value>value</a></code> attribute: <a href=#text-content title="text content">Text</a>.</dd>
<dd>If the element has no <code title=attr-option-label><a href=#attr-option-label>label</a></code> attribute: <a href=#text-content title="text content">Text</a> that is not <a href=#inter-element-whitespace>inter-element whitespace</a>.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>An <code><a href=#the-option-element>option</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> can be omitted if
the <code><a href=#the-option-element>option</a></code> element is immediately followed by another <code><a href=#the-option-element>option</a></code> element, or
Expand Down Expand Up @@ -51370,7 +51371,7 @@ interface <dfn id=htmloptionelement>HTMLOptionElement</dfn> : <a href=#htmleleme
attribute.</p>

<p>The <code title=attr-option-label><a href=#attr-option-label>label</a></code> content attribute, if specified, must not be
empty. If the attribute is not specified, then the element itself must not be empty.</p>
empty.</p>

<p>The <dfn id=attr-option-value title=attr-option-value><code>value</code></dfn> attribute provides a value for
element. The <dfn id=concept-option-value title=concept-option-value>value</dfn> of an <code><a href=#the-option-element>option</a></code> element is
Expand Down
11 changes: 6 additions & 5 deletions source
Expand Up @@ -11247,6 +11247,7 @@ http://software.hixie.ch/utilities/js/live-dom-viewer/?%3C%21DOCTYPE%20HTML%3E%0

<h4>Requirements relating to bidirectional-algorithm formatting characters</h4>

<!--CLEANUP-->
<p><span>Text content</span> in <span>HTML elements</span> with <code>Text</code> nodes in their <span title="concept-html-contents">contents</span>, and
text in attributes of <span>HTML elements</span> that allow free-form text, may contain characters
in the ranges U+202A to U+202E and U+2066 to U+2069 (the bidirectional-algorithm formatting
Expand Down Expand Up @@ -12632,7 +12633,7 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p>
<dt><span title="element-dfn-contexts">Contexts in which this element can be used</span>:</dt>
<dd>In a <code>head</code> element containing no other <code>title</code> elements.</dd>
<dt><span title="element-dfn-content-model">Content model</span>:</dt>
<dd><span title="text content">Text</span>.</dd>
<dd><span title="text content">Text</span> that is not <span>inter-element whitespace</span>.</dd>
<dt><span title="element-dfn-attributes">Content attributes</span>:</dt>
<dd><span>Global attributes</span></dd>
<dt><span title="element-dfn-dom">DOM interface</span>:</dt><!--TOPIC:DOM APIs-->
Expand All @@ -12651,8 +12652,6 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p>

<p>There must be no more than one <code>title</code> element per document.</p>

<p>The <code>title</code> element must not be empty.</p>

<p class="note">If it's reasonable for the <code>Document</code> to have no title, then the
<code>title</code> element is probably not required. See the <code>head</code> element's content
model for a description of when the element is required.</p>
Expand Down Expand Up @@ -56348,7 +56347,9 @@ You cannot submit this form when the field is incorrect.</samp></pre>
<dd>As a child of a <code>datalist</code> element.</dd>
<dd>As a child of an <code>optgroup</code> element.</dd>
<dt><span title="element-dfn-content-model">Content model</span>:</dt>
<dd><span title="text content">Text</span>.</dd>
<dd>If the element has a <code title="attr-option-label">label</code> attribute and a <code title="attr-option-value">value</code> attribute: Empty.</dd>
<dd>If the element has a <code title="attr-option-label">label</code> attribute but no <code title="attr-option-value">value</code> attribute: <span title="text content">Text</span>.</dd>
<dd>If the element has no <code title="attr-option-label">label</code> attribute: <span title="text content">Text</span> that is not <span>inter-element whitespace</span>.</dd>
<dt><span title="element-dfn-attributes">Content attributes</span>:</dt>
<dd><span>Global attributes</span></dd>
<dd><code title="attr-option-disabled">disabled</code></dd>
Expand Down Expand Up @@ -56403,7 +56404,7 @@ interface <dfn>HTMLOptionElement</dfn> : <span>HTMLElement</span> {
attribute.</p>

<p>The <code title="attr-option-label">label</code> content attribute, if specified, must not be
empty. If the attribute is not specified, then the element itself must not be empty.</p>
empty.</p>

<p>The <dfn title="attr-option-value"><code>value</code></dfn> attribute provides a value for
element. The <dfn title="concept-option-value">value</dfn> of an <code>option</code> element is
Expand Down

0 comments on commit 31647fc

Please sign in to comment.