Bug 153519 - Setting HTMLInputElement.value to null to set its value to the empty string
Summary: Setting HTMLInputElement.value to null to set its value to the empty string
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL: https://html.spec.whatwg.org/#htmlinp...
Keywords: WebExposed
Depends on:
Blocks: 153504
  Show dependency treegraph
 
Reported: 2016-01-26 15:43 PST by Chris Dumez
Modified: 2016-01-26 17:16 PST (History)
2 users (show)

See Also:


Attachments
Patch (4.26 KB, patch)
2016-01-26 15:46 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2016-01-26 15:43:10 PST
Setting HTMLInputElement.value to null to set its value to the empty string:
- https://html.spec.whatwg.org/#htmlinputelement
- http://heycam.github.io/webidl/#TreatNullAs

WebKit currently unsets the value attribute instead, which causes us to fallback to input.defaultValue if set.

Firefox and Chrome behave correctly.
Comment 1 Chris Dumez 2016-01-26 15:46:01 PST
Created attachment 269938 [details]
Patch
Comment 2 WebKit Commit Bot 2016-01-26 17:16:25 PST
Comment on attachment 269938 [details]
Patch

Clearing flags on attachment: 269938

Committed r195642: <http://trac.webkit.org/changeset/195642>
Comment 3 WebKit Commit Bot 2016-01-26 17:16:29 PST
All reviewed patches have been landed.  Closing bug.