Skip to content

Commit e3fb955

Browse files
domenicinikulin
authored andcommitted
Clarify the value comparison in input.value's setter
This is a follow-up to whatwg#2437, which introduced the value comparison and its impact on selection. See web-platform-tests/wpt#5147 (comment).
1 parent 92fda18 commit e3fb955

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

source

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48656,10 +48656,11 @@ You cannot submit this form when the field is incorrect.</samp></pre>
4865648656
<li><p>Invoke the <span>value sanitization algorithm</span>, if the element's <code
4865748657
data-x="attr-input-type">type</code> attribute's current state defines one.</p></li>
4865848658

48659-
<li><p>If the new value is different from <var>oldValue</var> and the element has a text entry
48660-
cursor position, move the text entry cursor position to the end of the text control,
48661-
unselecting any selected text and <span data-x="set the selection direction">resetting the
48662-
selection direction</span> to "<code data-x="">none</code>".</p></li>
48659+
<li><p>If the element's <span data-x="concept-fe-value">value</span> (after applying the
48660+
<span>value sanitization algorithm</span>) is different from <var>oldValue</var>, and the
48661+
element has a text entry cursor position, move the text entry cursor position to the end of the
48662+
text control, unselecting any selected text and <span data-x="set the selection
48663+
direction">resetting the selection direction</span> to "<code data-x="">none</code>".</p></li>
4866348664
</ol>
4866448665
</dd>
4866548666

0 commit comments

Comments
 (0)