In VoiceOver, fancybox gallery is fully keyboard navigable and mostly screen reader friendly; the exception is that when the screen reader gets to the gallery of thumbnails (which pops in on the right), it reads each of them as "link". (So it goes "link, link, link, link," as you tab through.)
It would be best if these said "View image 1, View image 2, View image 3," etc. We decided in Teams on 2025-12-02 that we should write our own tweak/override for fancybox to solve this problem. If we can use some logic to generate the #, giving the link a title of "View image {#}" should be sufficient. (Just FYI, the images do not need alt text.)
Suggested Fixes
- Add a
title attribute to the link, like so: <a href="..." title="View image 1">
OR
- Add link text that is visually hidden (but available to screen readers) using the
sr-only class, like so: <a href="..."><span class="sr-only">View image 1</span></a>
In VoiceOver, fancybox gallery is fully keyboard navigable and mostly screen reader friendly; the exception is that when the screen reader gets to the gallery of thumbnails (which pops in on the right), it reads each of them as "link". (So it goes "link, link, link, link," as you tab through.)
It would be best if these said "View image 1, View image 2, View image 3," etc. We decided in Teams on 2025-12-02 that we should write our own tweak/override for fancybox to solve this problem. If we can use some logic to generate the #, giving the link a title of "View image {#}" should be sufficient. (Just FYI, the images do not need alt text.)
Suggested Fixes
titleattribute to the link, like so:<a href="..." title="View image 1">OR
sr-onlyclass, like so:<a href="..."><span class="sr-only">View image 1</span></a>