Open Jefferydo opened 2 years ago
The title attribute can be used for supplemental information.
I agree. Using the title attribute on images is not recommended.
Keep in mind that alt text should convey the meaning or essential content. It should be concise and short (less than 150 characters).
You can use <figcaption>
to provide context to describe information that isn't apparent from looking at the image. This includes the who, what, when, where, and/or why of an image.
For complex images, there are different approaches you can use to provide short and long descriptions.
Please refer to the ESDC self-paced web accessibility course for more details and examples:
Module 5 - Images - Informative images Module 5 - Images - Figure and figcaption Module 5 - Images - Complex images
The answer:
Using the title attribute on images is discouraged. From the HTML5 spec's images section:
The way it's written, the solution suggest the title attribute is required in the absence of an empty alt. An image with an empty alt is supposed to be ignored by AT.
More information suggest:
The spec mentions the title attribute in the context of images a few more times:
example of title as caption: