Skip to content

HTML <datalist> #1402

Open
Open

Description

@asuh

Description

As the web's native combobox, <input list> combined with <datalist> behaves inconsistently across browser engines and platforms. All modern browsers implement <datalist>, minus a few areas of support on Firefox, but vary in styling and behavior.

The proposed scope for this investigation:

  • Popup rendering
    • Styling and positioning consistency
    • Desktop and mobile keyboard-suggestions displays
  • Filtering behavior
    • How options are filtered against value
    • Case matching differences
  • Display consistency when <option> text and value differ
  • Affordance styling (the popup indicator icon)
    • Does this follow same convention of <select>?
  • Browser engine consistency
    • Working as more than a text box
    • Options availability in landscape mode
    • Mobile landscape behavior
  • A11y - roles and names as exposed to screen readers, keyboard navigation, escape behavior, and voice-control
  • A11y - Page Zoom and text styling in popup
  • A11y - AT inconsistencies

Rationale

Many of the identified issues are listed in Adrian Roselli's "Under-Engineered Comboboxen".

Web developer usage from State of HTML survey is very low year after year

APG provides custom combobox patterns as a good informative pattern but shouldn't be treated as normative. Extending these patterns can and does introduce new a11y issues.

Investigation Roadmap

Specification

https://html.spec.whatwg.org/multipage/form-elements.html#the-datalist-element

Web platform

https://web-platform-dx.github.io/web-features-explorer/features/datalist/
https://wpt.fyi/results/html/semantics/forms/the-datalist-element/datalistoptions.html?label=experimental&label=master&aligned&q=datalist

Test links

https://github.com/web-platform-tests/wpt/tree/master/html/semantics/forms/the-datalist-element

Adoption of <datalist> is low, according to Chrome Platform Status.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    investigation-effort-proposal

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions