Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block Directory: Use the block's title for alt text on block directory plugin items. #19263


Copy link

StevenDufresne commented Dec 20, 2019


We currently have a less than useful placeholder text ( 'block icon' ) for the icon that is associated to the block directory plugin. This PR grabs the blocks title, which cannot be blank, localizes it and adds it as the alt text.

This suggestion was spun out of a PR that was accepted and closed. See here:


I considered removing the alt tag altogether but this image feels more like content than something ornamental. (ref:

How has this been tested?

The only applicable test is to inspect the <img> tag and locate the alt attribute.



Types of changes

Bug fix


  • My code is tested.
  • My code follows the WordPress code style.
  • My code follows the accessibility standards.
  • My code has proper inline documentation.
  • I've included developer documentation if appropriate.
  • I've updated all React Native files affected by any refactorings/renamings in this PR. .
@MarcoZehe MarcoZehe merged commit 0553213 into WordPress:master Dec 23, 2019
2 checks passed
2 checks passed
Travis CI - Pull Request Build Passed
@StevenDufresne StevenDufresne deleted the StevenDufresne:fix/block-directory-downloadable-block-header-img-alt branch Dec 24, 2019
@youknowriad youknowriad added this to the Gutenberg 7.2 milestone Jan 6, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
4 participants
You can’t perform that action at this time.