What fresh hell is THIS now? - Patrick Lauke
<image of the park>
<citation for the image>
<caption for the image>
I have used <figcaption> for a citation or for a caption with a citation for the caption, but never a citation for the image separate from the caption.
<figure> <img src="..." aria-labelledby="my-caption" /> <figcaption id="my-caption">Caption</figcaption> </figure>
<figure> <span> <img src="path/to/image" aria-labeledby="caption-x"> <cite>Photo by...</cite> </span> <figcaption id="caption-x">Children playing...</figcaption> </figure>
alt="Children playing.."
or a presentational alt=""
?
<span>
around the <img>
and <cite>
does not add any semantic relationship. You would probably want to add an aria-describedby to point to the <cite>
but you would have to test that to see whether it works in all screen readers. Technically the <figure>
should relate all these things together but there is not enough support for that right now
aria-labelledby
taking precedence over aria-label
, followed by alt
, so having no alt
or an empty alt
would be fine
aria-labelledby
for the <figcaption>
and then aria-describedby
for the <cite>
?
aria-labelledby
with two ls
<figure> <p> <img src="path/to/image” alt=“” aria-labelledby="caption-x-citation" aria-describedby="caption-x-caption"> <cite id="caption-x-citation">Photo by...</cite> </p> <figcaption id="caption-x-caption">Children playing...</figcaption> </figure>
<figure id="caption-x"> <p> <img src="path/to/image" aria-labelledby="caption-x-caption" aria-describedby="caption-x-citation"> <cite id="caption-x-citation">Photo by...</cite> </p> <figcaption id="caption-x-caption">Children playing...</figcaption> </figure>
[Andrea Skeries, a11y] The web design trend now seems to be having large video that plays automatically with text over the top (Example: http://www.palmettohealth.org/).
Do you think this falls into the WCAG 2.2.2 in that we should provide a way for users to stop/pause the video so they can read the content over top of it without distraction? It doesn't seem to exactly fit with this guideline but its very similar.
@jonathantneal you could make it slightly more usable by adding some aria-hidden attributes
<figure id="caption-x"> <p> <img src="path/to/image" aria-labelledby="caption-x-caption" aria-describedby="caption-x-citation"> <cite id="caption-x-citation" aria-hidden="true">Photo by...</cite> </p> <figcaption id="caption-x-caption" aria-hidden="true">Children playing...</figcaption> </figure>
I have tested support for this in VO, not sure about JAWS and NVDA at this point
aria-hidden
to those elements, they will be read twice in which AT? @LjWatson, if I add aria-hidden
to those elements, they will not be read at all in which AT?
aria-hidden
EVER for text that should be read aloud, even if it is used by aria-*by
?
Skip hidden elements unless the author specifies to use them via an aria-labelledby or aria-describedby being used in the current computation
aria-hidden=“true”
is how it should be, but just know that it will not work in any current AT. Is that right?