Bug 219536

Summary: Disabled select options are still selectable when optgroups are used in MobileSafari
Product: WebKit Reporter: Kris Breuker <kris>
Component: FormsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED DUPLICATE    
Severity: Normal CC: cdumez, smoley, wenson_hsieh
Priority: P2    
Version: Safari 14   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=69014
Attachments:
Description Flags
test case none

Description Kris Breuker 2020-12-04 03:26:22 PST
MobileSafari doesn't seem to honour the disabled attribute on optgroups, see for example the example at https://developer.mozilla.org/en-US/docs/Web/HTML/Element/optgroup#Examples where the options in the third (disabled) optgroup are enabled in Safari on iOS.

Also, when optgroups are used, disabled options are still selectable, whether they are within an optgroup or outside of it. In the following examples the disabled option is rendered as disabled, but still selectable (and once selected, they are no longer rendered as being disabled):

<select>
  <optgroup label="My group">
    <option>My selectable option</option>
    <option disabled>My disabled option</option>
  </optgroup>
</select>

<select>
  <option>My selectable option</option>
  <option disabled>My disabled option</option>
  <optgroup label="My group" />
</select>

Tested using iOS 14.2 on iPhone 11 Pro and iOS 14.2, 13.7 and 12.4 in the iOS Simulator.
Comment 1 Smoley 2020-12-07 12:00:55 PST
Created attachment 415570 [details]
test case
Comment 2 Smoley 2020-12-07 12:04:51 PST

*** This bug has been marked as a duplicate of bug 201458 ***