Skip to content

Accessibility suggestion (aria roles) #260

@michaelbourne

Description

@michaelbourne

Howdy,

From a recent 3rd party audit with credentialed accessibility auditors, they had the following to say:

Success criteria

4.1.2 Name, Role, Value (WCAG 2.0 A)

Native Widgets: Link Function & Role

If an anchor element () is coded to function as something other than a link, it must have the correct ARIA widget role.

The image components on this page are coded as links but functions more appropriately as buttons.

Note: When these components are activated they expose a modal.

Remediation Recommendation

Native HTML elements should always be used if possible (eg. use for button functionality).

If you must use an anchor element to function as a button, for example, add role=“button” to the element and then ensure it can be activated with the spacebar (in addition to the return/enter key)

For your consideration, could you also consider adding the ability to add the button role, and possible an event listener for the space button as well to trigger the modal?

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions