aria-braille attributes must have a non-braille equivalent
How to Fix the Problem
-
The
aria-braillelabel
oraria-brailleroledescription
attribute may have been placed on the wrong element, such as a parent or child of the correct element. The attribute should be put on a different element. -
The element with
aria-braillelabel
attribute needs anaria-label
attribute or other attribute that gives it an accessible name. -
The element with
aria-brailleroledescription
attribute needs aaria-roledescription
attribute. -
The
aria-braillelabel
oraria-brailleroledescription
attribute serves no function and should be removed.
Good aria-braillelabel:
<button aria-braillelabel="****">
<img alt="4 stars" src="images/stars.jpg">
</button>
Bad aria-braillelabel:
<img alt="" aria-braillelabel="****" src="images/stars.jpg">
Good aria-brailleroledescription
<div
role="article" id="slide" aria-labelledby="slideheading"
aria-roledescription="slide"
aria-brailleroledescription="sld"
>
<h1 id="slideheading">My vacation in Rome</h1>
</div>
Bad aria-brailleroledescription
<div
role="article" id="slide" aria-labelledby="slideheading"
aria-brailleroledescription="slide"
>
<h1 id="slideheading">My vacation in Rome</h1>
</div>
Why it Matters
ARIA braille attributes were introduced to allow adjusting how labels and role descriptions are rendered on a braille display. They cannot be the only attribute providing a label, or a role description. When used without a corresponding label or role description ARIA says to ignore these attributes, although this may not happen consistently in screen readers and other assistive technologies.
Rule Description
WAI-ARIA requires that the aria-braillelabel
attribute is only
ever used on elements with an accessible name, such as from
aria-label
. Similarly,
aria-brailleroledescription
is required to only ever be used on
elements with aria-roledescription
.
The Algorithm (in simple terms)
Checks that aria-braillelabel
is only used on elements with a
non-empty label, and that aria-brailleroledescription
is only
used on elements with a non-empty aria-roledescription
.