All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.sonar.l10n.web.rules.Web.S6807.html Maven / Gradle / Ivy

The newest version!

Why is this an issue?

ARIA (Accessible Rich Internet Applications) attributes are used to enhance the accessibility of web content and web applications. These attributes provide additional information about an element’s role, state, properties, and values to assistive technologies like screen readers.

Each role in ARIA has a set of required attributes that must be included for the role to be properly understood by assistive technologies. These attributes are known as "required aria-* properties".

For example, if an element has a role of "checkbox", it must also include the aria-checked property. This property indicates whether the checkbox is checked (true), unchecked (false), or in a mixed state (mixed).

This rule checks that each element with a defined ARIA role also has all required attributes.

How to fix it

Check that each element with a defined ARIA role also has all required attributes.

<div role="checkbox">Unchecked</div> <!-- Noncompliant: aria-checked is missing -->

To fix the code add missing aria-* attributes.

<div role="checkbox" aria-checked="false">Unchecked</div>

Resources

Documentation

Standards





© 2015 - 2025 Weber Informatics LLC | Privacy Policy