This module aims to bridge the gap between embedding media within a WYSIWYG such as ckeditor and having a fully accessible website using context sensitive alt tags for that embedded media.

When is this module needed?

This module is useful for Drupal <= 8.7, Drupal 8.8 media has the ability to correctly update alt descriptive text each time media is embedded.

What's the problem?

Currently you add an alt tag to an image when adding an image to the media library and this alt tag is used each time the media is embedded within some content.

The issue comes when you compare this with the WCAG 2.0 guidelines (https://www.w3.org/WAI/tutorials/images/), where a media image's context gives a requirement to change the alt text for different situations. For example an image may be used in one place as decorative and then in a different situation as functional such as being part of a link. Given these requirements we need to be able to change the alt text for these different situations.

What this module does

This module adds additional options to the entity embed form so alt text can be unique each time the media is embedded. A filter is also included to replace the alt text with the overriding alt text specified.

Usage

Install as you would normally install a contributed Drupal module. Visit: https://www.drupal.org/docs/8/extending-drupal-8/installing-drupal-8-mod... for further information.

Then enable the Context sensitive alt for media filter under Configuration > Text formats and editors. This should always run after the Display embedded entities filter.

Requirements

This module relies on the entity embed module being installed.

Supporting organizations: 
Contributed time and sourced external dedicated team training for accessibility

Project information

Releases