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.

Heading ad hoc tools not displaying the updated aria-level of a heading

See original GitHub issue

Describe the bug

Headings which have had their implicit level overwritten by use of an explicit aria-level are still showing up with their implicit level when using a11y insights’ ad hoc tools to highlight headings.

CodePen repro example

Go to the codepen: https://codepen.io/scottohara/full/qBpyeNW turn on the a11y insights for web ad hoc feature to display the headings of the page.

The first two elements of the codepen demo are h1 elements which have been modified with ARIA to be exposed as heading level 3s. The third element is a div with role=heading and aria-level=3. The div is being highlighted with the correct heading level by a11y insights.

Expected behavior

heading elements which have had their levels overwritten by aria-level should be labeled to match the level that is exposed in the browser’s accessibility tree.

Context (please complete the following information)

Did you search for similar existing issues?

Possibly similar to https://github.com/microsoft/accessibility-insights-web/issues/5126, but since the <div role=heading aria-level=3> did get flagged by a11yInsights as an h3, thought a new issue would be best.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
ferBonnincommented, Apr 12, 2022

Reviewed with Peter, the aria-level should be the one we consider if we have both a native heading level and an explicit aria-level

Also interesting is that the H3 in the div has a lowercase ‘h’. Ran the same visualization in accessibilityinsights.io/docs, all the Hx have an uppercase ‘H’

1reaction
scottaoharacommented, May 24, 2022

thank you @ThanyaLeif

i don’t have the canary build of a11y insights, but reviewing the PR you linked to, the changes look like they address the issue i raised. so thank you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ARIA12: Using role=heading to identify headings | WAI - W3C
This example demonstrates how to implement a level 7 heading using role="heading" and the aria-level attribute. Since HTML only supports headings through level ......
Read more >
5 heading accessibility issues and how to fix them
Headings are the main navigation method for assistive tech users, so learn how to make them accessible and fix any inaccessible headings.
Read more >
Tested on web only: Headings - Digital.NSW
Method 2: Use a tool. The Accessibility Insights for Web tool can show where headings are. In the extension, click "ad-hoc tools" and...
Read more >
Untitled
Beko dsfs 6835 x instrukcja, Action not words def leppard mp3, Jordan farmar ... Mw2 title and emblems, Drug sensitive nail polish, Legion...
Read more >
Safari Technology Preview Release Notes - Apple Developer
Fixed dynamic aria-disabled changes not updating enabled status for ... Menu when sharing an image to show a preview of the image and...
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