Home Plugins empty alt image container swap
Empty Alt Image Container Swap logo

Empty Alt Image Container Swap

by Akari Doi on WordPress.org

This plugin improves accessibility by converting figure tags to div tags for image blocks with missing alt text and hides captions for these images.

(0)

This plugin enhances the accessibility of image blocks in the WordPress block editor by converting the wrapping

tags to
tags when the image has an empty alt attribute. Additionally, it hides the caption for images with empty alt text on the frontend.

Key features:
– Converts

tags to
tags for images with empty alt text
– Hides captions for images with empty alt text on the frontend (output a warning to the editor)
– Works dynamically without modifying stored content

Images that are purely decorative and lack an alt attribute do not contribute directly to the understanding of the content, and therefore, wrapping them in a

element is not appropriate.
By replacing
tags with
tags for images missing alt text, this plugin ensures proper HTML semantics.
elements are generic containers without implicit meaning, making them suitable for presenting images without associated descriptions.

Active installations0+
Weekly downloads
14-26.32%
Version1.1.0
Last updated7/29/2024
WordPress version5.0
Tested up to6.6.2
Tags
accessibilityAlt Textdivfigureimages