Permalink
Browse files

[] (0) WF2: <input type=email>.

git-svn-id: http://svn.whatwg.org/webapps@2227 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information...
1 parent c67bb31 commit cf37ff8165912fefeeb6711e64d5fba63ee24fc8 @Hixie Hixie committed Sep 24, 2008
Showing with 212 additions and 22 deletions.
  1. +109 −11 index
  2. +103 −11 source
View
120 index
@@ -28585,7 +28585,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -28714,7 +28714,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=no> &middot; <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -28800,7 +28800,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -28929,7 +28929,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -28973,7 +28973,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -29016,7 +29016,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -29059,7 +29059,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=yes> Yes <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -29363,7 +29363,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=no> &middot; <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -29407,7 +29407,7 @@ function AddCloud(data, x, y) { ... }</pre>
<td class=no> &middot; <!-- Password -->
- <td class=no> &middot; <!-- E-mail -->
+ <td class=yes> Yes <!-- E-mail -->
<td class=no> &middot; <!-- URL -->
@@ -29850,7 +29850,102 @@ function AddCloud(data, x, y) { ... }</pre>
href="#email">email</a></code>, it is in the <a href="#e-mail0"
title=attr-input-type-email>E-mail</a> state.
- <p class=big-issue>...
+ <p>When an <code><a href="#input0">input</a></code> element's <code
+ title=attr-input-type><a href="#type14">type</a></code> attribute is in
+ the <a href="#e-mail0" title=attr-input-type-email>E-mail</a> state, the
+ element represents a control for editing a single e-mail address given in
+ the element's <a href="#value12" title=concept-fe-value>value</a>.
+
+ <p>If an <code><a href="#input0">input</a></code> element whose <code
+ title=attr-input-type><a href="#type14">type</a></code> attribute is in
+ the <a href="#e-mail0" title=attr-input-type-email>E-mail</a> state is <i
+ title=concept-input-mutable><a href="#mutable">mutable</a></i>, the user
+ should allow the user to change the e-mail address represented by its <a
+ href="#value12" title=concept-fe-value>value</a>. User agents may allow
+ the user to set the <a href="#value12" title=concept-fe-value>value</a> to
+ a string that is not an e-mail address. User agents should allow the user
+ to set the <a href="#value12" title=concept-fe-value>value</a> to the
+ empty string. User agents must not allow users to insert U+000A LINE FEED
+ (LF) or U+000D CARRIAGE RETURN (CR) characters into the <a href="#value12"
+ title=concept-fe-value>value</a> of such <code><a
+ href="#input0">input</a></code> elements.
+
+ <p><strong>The <a href="#e-mail0" title=attr-input-type-email>E-mail</a>
+ state's <a href="#control0">control initialization algorithm</a> is as
+ follows:</strong> <a href="#strip">Strip line breaks from the value</a>.</p>
+ <!-- XXX autocomplete? -->
+
+ <p><strong>The <a href="#e-mail0" title=attr-input-type-email>E-mail</a>
+ state's <a href="#default2">default value change algorithm</a> is as
+ follows:</strong> If the <code><a href="#input0">input</a></code> element
+ is not <i title=concept-input-dirty><a href="#dirty0">dirty</a></i> then
+ set the <a href="#value12" title=concept-fe-value>value</a> of the element
+ to the value of the <code title=attr-input-value><a
+ href="#value8">value</a></code> content attribute and <a
+ href="#strip">strip line breaks from the value</a>.
+
+ <p><strong>The <a href="#e-mail0" title=attr-input-type-email>E-mail</a>
+ state's <a href="#value10"><code title=dom-input-value>value</code> setter
+ algorithm</a> is as follows:</strong> Set the <a href="#value12"
+ title=concept-fe-value>value</a> of the element to the new value and <a
+ href="#strip">strip line breaks from the value</a>.
+
+ <p><strong>Constraint validation:</strong> While the <a href="#value12"
+ title=concept-fe-value>value</a> of the element does not match the
+ <code>addr-spec</code> token defined in RFC 2822 section 3.4.1, excluding
+ the <code>CFWS</code> subtoken everywhere, and excluding the
+ <code>FWS</code> subtoken everywhere except in the
+ <code>quoted-string</code> subtoken, the element is <a
+ href="#suffering">suffering from a type mismatch</a>. <a
+ href="#refsRFC2822">[RFC2822]</a>
+
+ <p>When an <code><a href="#input0">input</a></code> element's <code
+ title=attr-input-type><a href="#type14">type</a></code> attribute is in
+ the <a href="#e-mail0" title=attr-input-type-email>E-mail</a> state, the
+ following common <code><a href="#input0">input</a></code> element content
+ attributes, DOM attributes, and methods apply to the element: <code
+ title=attr-input-autocomplete><a
+ href="#autocomplete0">autocomplete</a></code>, <code
+ title=attr-input-list>list</code>, <code
+ title=attr-input-maxlength>maxlength</code>, <code
+ title=attr-input-pattern>pattern</code>, <code
+ title=attr-input-readonly><a href="#readonly0">readonly</a></code>, <code
+ title=attr-input-required>required</code>, and <code
+ title=attr-input-size>size</code> content attributes; <code
+ title=dom-input-list><a href="#list">list</a></code>, and <code
+ title=dom-input-selectedOption><a
+ href="#selectedoption">selectedOption</a></code> DOM attributes.
+
+ <p>When an <code><a href="#input0">input</a></code> element's <code
+ title=attr-input-type><a href="#type14">type</a></code> attribute is in
+ the <a href="#e-mail0" title=attr-input-type-email>E-mail</a> state, the
+ following content attributes must not be specified and do not apply to the
+ element: <code class=no-backref title=attr-input-accept><a
+ href="#accept0">accept</a></code>, <code class=no-backref
+ title=attr-input-alt>alt</code>, <code class=no-backref
+ title=attr-input-checked>checked</code>, <code class=no-backref
+ title=attr-input-max>max</code>, <code class=no-backref
+ title=attr-input-min>min</code>, <code class=no-backref
+ title=attr-input-src>src</code>, <code class=no-backref
+ title=attr-input-step>step</code>, <code class=no-backref
+ title=attr-fs-target><a href="#target3">target</a></code>, <code
+ class=no-backref title=attr-fs-method><a href="#method">method</a></code>,
+ <code class=no-backref title=attr-fs-enctype><a
+ href="#enctype">enctype</a></code>, and <code class=no-backref
+ title=attr-fs-action><a href="#action">action</a></code>.
+
+ <p>When an <code><a href="#input0">input</a></code> element's <code
+ title=attr-input-type><a href="#type14">type</a></code> attribute is in
+ the <a href="#e-mail0" title=attr-input-type-email>E-mail</a> state, the
+ following DOM attributes and methods do not apply to the element: <code
+ class=no-backref title=dom-input-checked><a
+ href="#checked1">checked</a></code>, <code class=no-backref
+ title=dom-input-valueAsDate><a href="#valueasdate">valueAsDate</a></code>,
+ <code class=no-backref title=dom-input-valueAsNumber><a
+ href="#valueasnumber">valueAsNumber</a></code>, <code class=no-backref
+ title=dom-input-stepUp><a href="#stepup">stepUp()</a></code>, and <code
+ class=no-backref title=dom-input-stepDown><a
+ href="#stepdown">stepDown()</a></code>.
<h6 id=url-state><span class=secno>4.10.4.1.4. </span><dfn id=url2
title=attr-input-type-url>URL</dfn> state</h6>
@@ -31052,6 +31147,9 @@ interface <dfn id=htmloptionelement>HTMLOptionElement</dfn> : <a href="#htmlelem
<p class=big-issue>An element <dfn id=satisfies
title=concept-fv-valid>satisfies its constraints</dfn> if ...
+ <p class=big-issue>... <dfn id=suffering>suffering from a type
+ mismatch</dfn>
+
<h5 id=constraint><span class=secno>4.10.15.2. </span>Constraint validation</h5>
<p>When the user agent is required to <dfn id=statically>statically
@@ -60921,7 +61019,7 @@ TODO (or delay):
<input type="text" group="contact" name="voicephone"> Voice phone
<input type="text" group="contact" name="fax"> Fax
<input type="text" group="contact" name="mobile"> Mobile phone
- <input type="text" group="contact" name="email"> Email
+ <input type="text" group="contact" name="email"> E-mail
if the user fills out none of the form fields in the "contact"
group, an error message is shown and the form is not submitted.
- Peter-Paul Koch
View
114 source
@@ -25552,7 +25552,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-autocomplete">autocomplete</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25621,7 +25621,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-list">list</code>
<td class="yes"> Yes <!-- Text -->
<td class="no"> &middot; <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25667,7 +25667,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-maxlength">maxlength</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25736,7 +25736,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-pattern">pattern</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25759,7 +25759,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-readonly">readonly</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25782,7 +25782,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-required">required</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25805,7 +25805,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="attr-input-size">size</code>
<td class="yes"> Yes <!-- Text -->
<td class="yes"> Yes <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25966,7 +25966,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="dom-input-list">list</code>
<td class="yes"> Yes <!-- Text -->
<td class="no"> &middot; <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -25989,7 +25989,7 @@ function AddCloud(data, x, y) { ... }</pre>
<th> <code title="dom-input-selectedOption">selectedOption</code>
<td class="yes"> Yes <!-- Text -->
<td class="no"> &middot; <!-- Password -->
- <td class="no"> &middot; <!-- E-mail -->
+ <td class="yes"> Yes <!-- E-mail -->
<td class="no"> &middot; <!-- URL -->
<td class="no"> &middot; <!-- Date and Time -->
<td class="no"> &middot; <!-- Local Date and Time -->
@@ -26350,7 +26350,96 @@ function AddCloud(data, x, y) { ... }</pre>
attribute has the value <code title="attr-input-type-email-keyword">email</code>,
it is in the <span title="attr-input-type-email">E-mail</span> state.</p>
- <p class="big-issue">...</p>
+ <p>When an <code>input</code> element's <code
+ title="attr-input-type">type</code> attribute is in the <span
+ title="attr-input-type-email">E-mail</span> state, the element
+ represents a control for editing a single e-mail address given in
+ the element's <span title="concept-fe-value">value</span>.</p>
+
+ <p>If an <code>input</code> element whose <code
+ title="attr-input-type">type</code> attribute is in the <span
+ title="attr-input-type-email">E-mail</span> state is <i
+ title="concept-input-mutable">mutable</i>, the user should allow the
+ user to change the e-mail address represented by its <span
+ title="concept-fe-value">value</span>. User agents may allow the
+ user to set the <span title="concept-fe-value">value</span> to a
+ string that is not an e-mail address. User agents should allow the
+ user to set the <span title="concept-fe-value">value</span> to the
+ empty string. User agents must not allow users to insert U+000A LINE
+ FEED (LF) or U+000D CARRIAGE RETURN (CR) characters into the <span
+ title="concept-fe-value">value</span> of such <code>input</code>
+ elements.</p>
+
+ <p><strong>The <span title="attr-input-type-email">E-mail</span>
+ state's <span>control initialization algorithm</span> is as
+ follows:</strong> <span>Strip line breaks from the
+ value</span>.</p>
+
+ <!-- XXX autocomplete? -->
+
+ <p><strong>The <span title="attr-input-type-email">E-mail</span>
+ state's <span>default value change algorithm</span> is as
+ follows:</strong> If the <code>input</code> element is not <i
+ title="concept-input-dirty">dirty</i> then set the <span
+ title="concept-fe-value">value</span> of the element to the value of
+ the <code title="attr-input-value">value</code> content attribute
+ and <span>strip line breaks from the value</span>.</p>
+
+ <p><strong>The <span title="attr-input-type-email">E-mail</span>
+ state's <span><code title="dom-input-value">value</code> setter
+ algorithm</span> is as follows:</strong> Set the <span
+ title="concept-fe-value">value</span> of the element to the new
+ value and <span>strip line breaks from the value</span>.</p>
+
+ <p><strong>Constraint validation:</strong> While the <span
+ title="concept-fe-value">value</span> of the element does not match
+ the <code>addr-spec</code> token defined in RFC 2822 section 3.4.1,
+ excluding the <code>CFWS</code> subtoken everywhere, and excluding
+ the <code>FWS</code> subtoken everywhere except in the
+ <code>quoted-string</code> subtoken, the element is <span>suffering
+ from a type mismatch</span>. <a href="#refsRFC2822">[RFC2822]</a>
+
+ <p>When an <code>input</code> element's <code
+ title="attr-input-type">type</code> attribute is in the <span
+ title="attr-input-type-email">E-mail</span> state, the following common
+ <code>input</code> element content attributes, DOM attributes, and
+ methods apply to the element:
+ <code title="attr-input-autocomplete">autocomplete</code>,
+ <code title="attr-input-list">list</code>,
+ <code title="attr-input-maxlength">maxlength</code>,
+ <code title="attr-input-pattern">pattern</code>,
+ <code title="attr-input-readonly">readonly</code>,
+ <code title="attr-input-required">required</code>, and
+ <code title="attr-input-size">size</code> content attributes;
+ <code title="dom-input-list">list</code>, and
+ <code title="dom-input-selectedOption">selectedOption</code> DOM attributes.
+
+ <p>When an <code>input</code> element's <code
+ title="attr-input-type">type</code> attribute is in the <span
+ title="attr-input-type-email">E-mail</span> state, the following
+ content attributes must not be specified and do not apply to the
+ element:
+ <code class="no-backref" title="attr-input-accept">accept</code>,
+ <code class="no-backref" title="attr-input-alt">alt</code>,
+ <code class="no-backref" title="attr-input-checked">checked</code>,
+ <code class="no-backref" title="attr-input-max">max</code>,
+ <code class="no-backref" title="attr-input-min">min</code>,
+ <code class="no-backref" title="attr-input-src">src</code>,
+ <code class="no-backref" title="attr-input-step">step</code>,
+ <code class="no-backref" title="attr-fs-target">target</code>,
+ <code class="no-backref" title="attr-fs-method">method</code>,
+ <code class="no-backref" title="attr-fs-enctype">enctype</code>, and
+ <code class="no-backref" title="attr-fs-action">action</code>.</p>
+
+ <p>When an <code>input</code> element's <code
+ title="attr-input-type">type</code> attribute is in the <span
+ title="attr-input-type-email">E-mail</span> state, the following DOM
+ attributes and methods do not apply to the element:
+ <code class="no-backref" title="dom-input-checked">checked</code>,
+ <code class="no-backref" title="dom-input-valueAsDate">valueAsDate</code>,
+ <code class="no-backref" title="dom-input-valueAsNumber">valueAsNumber</code>,
+ <code class="no-backref" title="dom-input-stepUp">stepUp()</code>, and
+ <code class="no-backref" title="dom-input-stepDown">stepDown()</code>.</p>
@@ -27384,6 +27473,9 @@ interface <dfn>HTMLOptionElement</dfn> : <span>HTMLElement</span> {
<p class="big-issue">An element <dfn
title="concept-fv-valid">satisfies its constraints</dfn> if ...</p>
+ <p class="big-issue">... <dfn>suffering from a type
+ mismatch</dfn></p>
+
<h5>Constraint validation</h5>
@@ -54701,7 +54793,7 @@ TODO (or delay):
<input type="text" group="contact" name="voicephone"> Voice phone
<input type="text" group="contact" name="fax"> Fax
<input type="text" group="contact" name="mobile"> Mobile phone
- <input type="text" group="contact" name="email"> Email
+ <input type="text" group="contact" name="email"> E-mail
if the user fills out none of the form fields in the "contact"
group, an error message is shown and the form is not submitted.
- Peter-Paul Koch

0 comments on commit cf37ff8

Please sign in to comment.