I know that in theory you shouldn't hide active elements... But... What if the link is repeated twice?
To clarify the link is on the picture which has no additional information value. A separate link is on a text and the url is the same as on the picture. The problem is that the picture is a separate component for the text link. So I can only surround the picture with an element (div). I have limited options to change the structure of the picture component.
It seems to me that the UX of a person with a screen reader will be better if redundant links are hidden. Formally, however, it is not recommended. Not sure what to do?
Rough structure is something like this:
<div role="listitem"> <div aria-hidden="true"> <fileComponent name="Wikipedia-logo.png" link="w:Some article"/> </div> <p> <linkComponent url="w:Some article" label="Wikipedia"/> </p> </div>
I have the option to add
fileComponent, but not more advanced attributes.
PS: To give more context... Actual code is from Wikipedia. And to clarify I do want links on both the image and text.
<div role="listitem"> <div aria-hidden="true">[[Plik:Wikipedia-logo.png|50px|link=w:]]</div> <p>[[w:|'''Wikipedia''']]</p> </div> <div role="listitem"> <div aria-hidden="true">[[Plik:Wikiquote-logo.svg|50px|link=q:]]</div> <p>[[q:|'''Wikiquote''']]</p> </div>