[Webkit-unassigned] [Bug 256538] <option> elements do not render when <datalist> has style:"display: block"

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed May 10 21:25:15 PDT 2023


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

Karl Dubost <karlcow at apple.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |karlcow at apple.com

--- Comment #1 from Karl Dubost <karlcow at apple.com> ---
Created attachment 466312

  --> https://bugs.webkit.org/attachment.cgi?id=466312&action=review

rendering in safari, firefox, chrome

Hi, Thanks for the heads up.

I wonder what the spec is saying here. 
The datalist element is made to be a container for the input element, but not meant to be visible.

The `display: block` on datalist will generate nothing once it is attached to `input`.


```
<label for="ice-cream-choice">Choose a flavor:</label>
<input list="ice-cream-flavors" id="ice-cream-choice" name="ice-cream-choice">

<datalist id="ice-cream-flavors" style="display:block">
    <option value="Chocolate">
    <option value="Coconut">
    <option value="Mint">
    <option value="Strawberry">
    <option value="Vanilla">
</datalist>
```

Should that be considered a bug in Chrome and Firefox instead?
Do you have a specific case where it needs to be visible?

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20230511/9db2eedf/attachment.htm>


More information about the webkit-unassigned mailing list