Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

link-name rule fails when it contains landmarks #1461

Closed
WilcoFiers opened this issue Mar 26, 2019 · 6 comments
Closed

link-name rule fails when it contains landmarks #1461

WilcoFiers opened this issue Mar 26, 2019 · 6 comments
Assignees
Labels
fix Bug fixes rules Issue or false result from an axe-core rule
Milestone

Comments

@WilcoFiers
Copy link
Contributor

Found the following example which seemed to fail axe-core:

<a href="...">
  <article><div>
    <div><img src="..." alt=""></div>
    <p class="card-description">Some card</p>
  </div></article>
</a>

As far as I can tell this link should and does not have an accessible name, but in a quick test with VO that doesn't seem to be a problem.

axe-core: 3.2.2

@WilcoFiers WilcoFiers added fix Bug fixes rules Issue or false result from an axe-core rule labels Mar 26, 2019
@drewlee
Copy link

drewlee commented Mar 28, 2019

We've noticed this issue as well after upgrading to v3.2.2. Links which had previously passed are now getting flagged as violations. Are there any workarounds aside from excluding the element or rule from the audit?

@WilcoFiers
Copy link
Contributor Author

WilcoFiers commented Apr 3, 2019

We've done a little more testing. Here are the results so far:

AT + UA method announcement
VO + Sarari Tabbing "Some card"
VO + Sarari Reading "Some card"
VO + Sarari Link list "Some card"
NVDA + FF Tabbing "Some card"
NVDA + FF Reading "Some card"
NVDA + Chrome Tabbing "Some card"
NVDA + Chrome Reading "Some card"
JAWS + IE Tabbing ""
JAWS + IE Reading "Some card"

@straker can you do some more testing for this, complete this table? Tabbing to the link with JAWS does seem to cause problems, so that suggests there is at least some sort of issue here. I want to get a better sense of the problem before we decide whether or not we let axe fail this, warn about it, or let it pass.

@WilcoFiers
Copy link
Contributor Author

@drewlee What element are you using inside links that is causing this behaviour? I think the way to fix it is to not use that element.

@drewlee
Copy link

drewlee commented Apr 10, 2019

@WilcoFiers, that's much easier said than done. The contention seems to be around our usage of a definition list, but unordered/ordered lists are failing as well. From a semantic perspective, our usage is completely justifiable and makes more sense than a hierarchy of divs. I'd also like to point out that in accordance with the HTML5 specification, it is perfectly acceptable to encompass complex semantics within anchors: https://www.w3.org/TR/html52/textlevel-semantics.html#elementdef-a. To paraphrase: "the <a> element may be wrapped around entire paragraphs, lists, tables, and so forth, even entire sections, so long as there is no interactive content within (e.g., buttons or other links)."

The specific JAWS+IE failure in the matrix above seems like a vendor deficiency. If a user interface is built in accordance to the specification, and a vendor fails to properly implement it, then it's rather heavy handed and overtly opinionated to flag this as a failure for the majority of use cases. I don't think this rule is very effective or useful if it's intent is to force all developers to limit anchor usage to simple text strings.

@dylanb
Copy link
Contributor

dylanb commented Jun 16, 2019

As sad as this may seem to all the JAWS users out there, it is not required for meeting accessibility supported.

@WilcoFiers WilcoFiers added fix Bug fixes and removed accessibility support labels Jan 6, 2020
@WilcoFiers WilcoFiers added this to the Axe-core 4.0 milestone Jan 6, 2020
@WilcoFiers WilcoFiers modified the milestones: Axe-core 4.0, axe-core 4.1 Apr 28, 2020
@straker straker removed their assignment Jun 17, 2020
@WilcoFiers WilcoFiers self-assigned this Nov 2, 2020
@padmavemulapati
Copy link

padmavemulapati commented Nov 12, 2020

Verified in the latest develop code of axe-core(v4.0.2),
Test snippet:
`

Some card

` Not seeing any failure for `link-name`

image

@straker straker closed this as completed Nov 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fixes rules Issue or false result from an axe-core rule
Projects
None yet
Development

No branches or pull requests

5 participants