question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

'aria-allowed-attr' fails instead of returning "needs review" when generic elements use 'aria-label' and 'aria-labelledby'

See original GitHub issue

aria-allowed-attr fails a few use cases of generic elements using aria-label , aria-labelledby and returns incomplete for a few other cases

Cases 1 to 6 in the examples below should return incomplete instead of a failure

Demo link: https://codepen.io/iamrafan/full/abJdjYw

Product: axe-core

Expectation: Return all the usages of ARIA 1.2 prohibited states and properties on generic elements as needs review

Motivation: Let the users review the issues instead of failing them


axe-core version: axe-core 4.2.0-canary.43394bc
axe version: axe-coconut 4.8.6.11818

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
WilcoFierscommented, May 13, 2021

@iamrafan Thank you for reporting the issue. I’m not sure how that slipped by us but I’m going to try to have a fix ready and released ASAP.

0reactions
strakercommented, Jul 20, 2021

This should be out in the latest version 4.3.1. aria-label is not allowed on div elements in ARIA 1.2 as they are prohibited attributes and screen readers do not announce the value.

Read more comments on GitHub >

github_iconTop Results From Across the Web

aria-labelledby - Accessibility - MDN Web Docs
The aria-labelledby property enables authors to reference other elements on the page to define an accessible name. This is useful when using ......
Read more >
ARIA Techniques for WCAG 2.0 - W3C
The WCAG Working Group plans to review which WAI-ARIA techniques are sufficient ... the aria-labelledby attribute should be used instead of aria-label ....
Read more >
Elements must only use allowed ARIA attributes | Axe Rules
ARIA explicitly defines which attributes are allowed for any given role and for every attribute, where that attribute may be used.
Read more >
Aria-labelledby vs. Aria-describedby vs. Aria-label
Section 1 -- aria-labelledby -- this is where one element is used to provide a label or an accessible name for another element,...
Read more >
Add aria-label or aria-describedby attributes to all <nav ...
Coming from [#2045039-7] @terrill: That said, I still think we should add aria-label attributes to all elements. There are many of these on ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found