BeBuilder linked images: hard-coded accessibility label
Hello,
PageSpeed flags linked image elements under “Identical links have the same purpose”, identifying a failure to follow accessibility best practice. The reported elements have this markup:
role="link" aria-label="Image with links" tabindex="0"
In the BeTheme 28.5.9.1 source, this label is hard-coded in sc_image() in functions/theme-shortcodes.php, around line 10024.
The image element’s custom $link_title is already applied to the inner anchors, but the keyboard-focusable wrapper retains the generic “Image with links” description. This means the supplied link title does not provide a meaningful accessible name for that wrapper.
Could the wrapper’s aria-label use the custom link title when supplied, with an appropriate fallback when it is empty? For example, a linked logo could use “Visit our home page”.
You can see this at [Links visible only for registered users]
Thank you.
While waiting for a response from one of our team members, we recommend to check Support Center where it is highly likely that you will find the answer to your question in no time.
FAQ | Video Tutorials | How to