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

Unique links should have unique, meaningful text #2483

Closed
alundgard opened this issue Jul 17, 2024 · 2 comments · Fixed by #2625
Closed

Unique links should have unique, meaningful text #2483

alundgard opened this issue Jul 17, 2024 · 2 comments · Fixed by #2625
Assignees
Labels

Comments

@alundgard
Copy link
Member

alundgard commented Jul 17, 2024

Current behavior

There are multiple unique IIIF Drag-n-drop links without unique, meaningful text. This could make it difficult to understand their behavior when navigating by screen reader. See WCAG SC 2.4.4 Link Purpose (Level A).

iiif-links

Steps to reproduce

Example page (/catalog): Parker Library - Search Results.

Possible solution

WCAG Level A: Understanding Success Criterion 2.4.4: Link Purpose (In Context).

See SODA's recommendations below.

Reported by SODA

Violation: Ensure link text is meaningful within context
Severity: Major

[Issue]
There are link elements that do not have meaningful text. There are multiple A element with an accessible name of 'iiif drag-n-drop' that is the same as another A element but doesn't go to the same HREF.

[User Impact]
Without meaningful text, screen reader users who navigate the page or navigate using a list of links (provided by their Assistive Technology, e.g., JAWS, VoiceOver, etc...) will not be able to discern the purpose of these links.

[Code Reference]

<div class="col-2 col-md-1">
  <a class="iiif-dnd float-right" data-turbolinks="false" href=...">
    <img alt="IIIF Drag-n-drop" src="..." width="30">
  </a>
</div>

[Recommendation]
Developers must ensure that links have meaningful text within context. This can be achieved by changing the ALT text or by using an aria-label, aria-labelledby to provide link purpose in context.

[ALT Text Example]

<div class="col-2 col-md-1">
  <a class="iiif-dnd float-right" data-turbolinks="false" href=...">
    <img alt="IIIF Drag-n-drop: Cambridge, Corpus Christi College, MS 002I: The Bury Bible" src="..." width="30">
  </a>
</div>

[ARIA-LABEL Example]

<div class="col-2 col-md-1">
  <a class="iiif-dnd float-right" data-turbolinks="false" href=..." aria-label=" Cambridge, Corpus Christi College, MS 002I: The Bury Bible">
    <img alt="IIIF Drag-n-drop" src="..." width="30">
  </a>
</div>

[ARIA-LABELLEDBY Example]

<h3 id="titleMs002I">Cambridge, Corpus Christi College, MS 002I: The Bury Bible</h3>
<div class="col-2 col-md-1">
  <a class="iiif-dnd float-right" data-turbolinks="false" href=..." id="linkMs002I" aria-labelledby="linkMs002I titleMs002I">
    <img alt="IIIF Drag-n-drop" src="..." width="30">
  </a>
</div>
@alundgard alundgard added the a11y label Jul 17, 2024
@corylown
Copy link
Contributor

corylown commented Oct 31, 2024

There's a similar issue filed with EarthWorks we should review: sul-dlss/earthworks#1430

@dnoneill dnoneill self-assigned this Nov 1, 2024
@dnoneill
Copy link
Contributor

dnoneill commented Nov 1, 2024

I went with aria-labeled by since I don't really think alt text is appropriate since it is supposed to describe the image not where the image is linking to.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants