8000 Mouse events & disabled form controls · Issue #2368 · whatwg/html · GitHub
[go: up one dir, main page]

Skip to content

Mouse events & disabled form controls #2368

@jakearchibald

Description

@jakearchibald

Test: http://jsbin.com/botohet/edit?js,output

https://html.spec.whatwg.org/multipage/forms.html#enabling-and-disabling-form-controls:-the-disabled-attribute says:

A form control that is disabled must prevent any click events that are queued on the user interaction task source from being dispatched on the element.

I guess this is weird legacy behaviour, as it completely prevents the event, rather than stopping propagation during the bubbling phase.

Currently Chrome, Edge & Safari apply the same behaviour to all mouse events. I'd much prefer that all browsers switched Firefox's behaviour, but if it's too late to do this, the weird behaviour should probably become part of the spec.

Unfortunately Chrome & Edge do the same for pointer events, but hopefully that can be changed w3c/pointerevents#177. This was fixed for pointer events.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0