Skip to content

[accessibility] Use aria-disabled to convey the disabled state #98

@Malvoz

Description

@Malvoz

aria-hidden is used in the disabled state:

this.button.setAttribute('aria-hidden', 'false');

this.button.setAttribute('aria-hidden', 'true');

which only hides the content from screen readers, but the button remains focusable, and because it is aria-hidden="true" nothing is announced to the user when it is focused.

I suggest replacing aria-hidden with aria-disabled to convey to screen readers that the button is currently disabled.
See related Leaflet issue: Leaflet/Leaflet#7211 / PR: https://github.com/Leaflet/Leaflet/pull/7280/files.


Other potentially helpful resources:

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions