[Webkit-unassigned] [Bug 43887] New: HTMLSelectElement.size defaults to 0

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Aug 11 16:02:05 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=43887

           Summary: HTMLSelectElement.size defaults to 0
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Macintosh Intel
               URL: http://jsbin.com/aqana/2/
        OS/Version: Mac OS X 10.6
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: HTML DOM
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: miketaylr at gmail.com


Per the HTML5 spec, a select element without a required attribute should have its size attribute default to 1. 

(http://www.whatwg.org/specs/web-apps/current-work/complete.html#the-select-element)

`The size attribute gives the number of options to show to the user. The size attribute, if specified, must have a value that is a valid non-negative integer greater than zero. If the multiple attribute is present, then the size attribute's default value is 4. If the multiple attribute is absent, then the size attribute's default value is 1.`

Current builds default to 0.

Code used in test case (http://jsbin.com/aqana/2/edit):

var select = document.createElement('select');
function testSize(el) {
  return el.size == 1;
}

testSize(select); // false

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list