content/examples/alt-text

ID:
content/examples/alt-text
Automated score:
92.6
View JSON file

9 violations: Light: 3Dark: 3HC Light: 2HC Dark: 1

Ensure <img> elements have alternative text or a role of none or presentation. Images must have alternative text. Help URL

HTML

<img>

Target

a[href$="#using-<img>"] > img

Summary

Fix any of the following:

  • Element does not have an alt attribute
  • aria-label attribute does not exist or is empty
  • aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty
  • Element has no title attribute
  • Element's default semantics were not overridden with role="none" or role="presentation"

Ensure <img> elements have alternative text or a role of none or presentation. Images must have alternative text. Help URL

HTML

<img>

Target

a[href$="#using-<img>"] > img

Summary

Fix any of the following:

  • Element does not have an alt attribute
  • aria-label attribute does not exist or is empty
  • aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty
  • Element has no title attribute
  • Element's default semantics were not overridden with role="none" or role="presentation"

Ensure <img> elements have alternative text or a role of none or presentation. Images must have alternative text. Help URL

HTML

<img>

Target

a[href$="#using-<img>"] > img

Summary

Fix any of the following:

  • Element does not have an alt attribute
  • aria-label attribute does not exist or is empty
  • aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty
  • Element has no title attribute
  • Element's default semantics were not overridden with role="none" or role="presentation"

Ensure <img> elements have alternative text or a role of none or presentation. Images must have alternative text. Help URL

HTML

<img>

Target

a[href$="#using-<img>"] > img

Summary

Fix any of the following:

  • Element does not have an alt attribute
  • aria-label attribute does not exist or is empty
  • aria-labelledby attribute does not exist, references elements that do not exist or references elements that are empty
  • Element has no title attribute
  • Element's default semantics were not overridden with role="none" or role="presentation"

Ensures the contrast between foreground and background colors meets APCA custom level conformance minimums thresholds. Elements must meet APCA conformance minimums thresholds. Help URL

HTML

<code class="stacks-code bg-blue-300">alt=""</code>

Target

.bg-blue-300

Summary

Fix all of the following:

  • Element has insufficient APCA custom level contrast of 56.83Lc (foreground color: #3b4045, background color: #92c2f2, font size: 9.0pt (12px), font weight: 400). Expected minimum APCA lightness contrast of 60Lc

Ensures the contrast between foreground and background colors meets APCA custom level conformance minimums thresholds. Elements must meet APCA conformance minimums thresholds. Help URL

HTML

<code class="stacks-code bg-blue-300">alt=""</code>

Target

.bg-blue-300

Summary

Fix all of the following:

  • Element has insufficient APCA custom level contrast of 59.88Lc (foreground color: #e3e6e8, background color: #3d7ab8, font size: 9.0pt (12px), font weight: 400). Expected minimum APCA lightness contrast of 60Lc

Ensure the contrast between foreground and background colors meets WCAG 2 AAA enhanced contrast ratio thresholds. Elements must meet enhanced color contrast ratio thresholds. Help URL

HTML

<code class="stacks-code bg-blue-300">alt=""</code>

Target

.bg-blue-300

Summary

Fix any of the following:

  • Element has insufficient color contrast of 4.77 (foreground color: #000000, background color: #257ad0, font size: 9.0pt (12px), font weight: normal). Expected contrast ratio of 7:1

Ensure links are distinguished from surrounding text in a way that does not rely on color. Links must be distinguishable without relying on color. Help URL

HTML

<a href="https://axesslab.com/alt-texts/">Axess Lab</a>

Target

.fc-caption > a

Summary

Fix any of the following:

  • The link has insufficient color contrast of 1.15:1 with the surrounding text. (Minimum contrast is 3:1, link text: #1b75d0, surrounding text: #636b74)
  • The link has no styling (such as underline) to distinguish it from the surrounding text

Ensure links are distinguished from surrounding text in a way that does not rely on color. Links must be distinguishable without relying on color. Help URL

HTML

<a href="https://axesslab.com/alt-texts/">Axess Lab</a>

Target

.fc-caption > a

Summary

Fix any of the following:

  • The link has insufficient color contrast of 1.13:1 with the surrounding text. (Minimum contrast is 3:1, link text: #90c4f9, surrounding text: #c8ccd0)
  • The link has no styling (such as underline) to distinguish it from the surrounding text