Skip to content
Snippets Groups Projects
Commit 30a6b7be authored by kaniini's avatar kaniini
Browse files

attachment: add support for rendering alt text on images

parent 673f0fca
No related branches found
No related tags found
No related merge requests found
Pipeline #
......@@ -10,7 +10,7 @@
<a href="#" @click.prevent="toggleHidden()">Hide</a>
</div>
<a v-if="type === 'image' && !hidden" class="image-attachment" :href="attachment.url" target="_blank">
<a v-if="type === 'image' && !hidden" class="image-attachment" :href="attachment.url" target="_blank" :title="attachment.description">
<StillImage :class="{'small': isSmall}" referrerpolicy="no-referrer" :mimetype="attachment.mimetype" :src="attachment.large_thumb_url || attachment.url"/>
</a>
......
  • nia @scarlett ·
    Contributor

    MDN recommends against using the title attribute for image descriptions, linking to this article: https://developer.paciellogroup.com/blog/2013/01/using-the-html-title-attribute-updated/

  • Maintainer

    Yes, it should be a alt attribute on the image instead.

  • Author Contributor

    that doesn't work because of the canvas. if you can find an alternative way of solving it, i'll merge it.

0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment