Skip to content

Should <input type=hidden> match :optional? #11273

@Gingeh

Description

@Gingeh

What is the issue with the HTML Standard?

The :optional pseudo-class is specified to only match input elements to which the required attribute applies, this excludes hidden inputs.
However, https://wpt.live/html/semantics/selectors/pseudo-classes/required-optional-hidden.html expects hidden inputs to match the :optional pseudo-class regardless of any required attribute, and both Chromium and Webkit implement that behaviour while Firefox does not.

Metadata

Metadata

Assignees

No one assigned

    Labels

    interopImplementations are not interoperable with each othertopic: selectors

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions