{"id":1702,"date":"2023-05-22T19:27:51","date_gmt":"2023-05-22T23:27:51","guid":{"rendered":"https:\/\/timtanhuynh.com\/ux\/?p=1702"},"modified":"2023-05-22T19:38:26","modified_gmt":"2023-05-22T23:38:26","slug":"alt-text","status":"publish","type":"post","link":"http:\/\/timtanhuynh.com\/ux\/fail\/alt-text\/","title":{"rendered":"<em>Alt<\/em> text"},"content":{"rendered":"<p><a href=\"https:\/\/accessibility.day\">Global Accessibility Awareness Day<\/a> has come and gone. The cynical part of me views it as another obscure Awareness Day that shouldn&#8217;t exist. However, the optimistic part of me views it as chance to highlight <del>ignorance<\/del> learning and, thus, it should exist. I&#8217;ve done HTML coding for years, and I know that implementing <em>alt<\/em> attribute values is easy to do, yet tricky to do well (consistently). I&#8217;ve reached the conclusion that there are no rules, only guidelines.<\/p>\n<p>Still, I&#8217;m surprised that some people fail to understand the purpose of <em>alt<\/em> text for image elements. I avoid social-media platforms, so I&#8217;ve missed the recent trend of <a href=\"https:\/\/www.bbc.com\/news\/newsbeat-65473838\">using the <em>alt<\/em> attribute to display the punchlines of jokes<\/a>. This usage accidentally-on-purpose excludes persons who rely on screen-reading technology because of visual impairment. They can&#8217;t perceive the first part of jokes that are images of text instead of machine-readable text.<\/p>\n<p>Even <a href=\"https:\/\/www.bbc.com\/news\/newsbeat-65644575\">(staff of) the British Prime Minister has used the attribute in a way that&#8217;s not useful<\/a>. &#8220;We&#8217;re growing the economy&#8221; is a vague description. It doesn&#8217;t benefit any user&#8217;s experience; imagine it being displayed as regular text, four times in a row. Moreover, the tweet has similar text as the description: &#8220;We are working day-in and day-out to grow the economy.&#8221; I would use a null (empty) description if the image needs to be split into quadrants as shown.<\/p>\n<p>In the interest of learning and growth, here are some useful resources.<\/p>\n<ol class=\"concise\">\n<li><a href=\"https:\/\/www.w3.org\/WAI\/tutorials\/images\/tips\/\">Tips and Tricks<\/a> (W3C)<\/li>\n<li><a href=\"https:\/\/accessibility.huit.harvard.edu\/describe-content-images\">Write good Alt Text to describe images<\/a> (Harvard University)<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>In HTML, the <em>alt<\/em> attribute is an abbreviation for <em>alternative<\/em> text. The value of any <em>alt<\/em> instance should replace (describe) the image to which it applies. The description, if justifiable, should benefit the experience of persons who have visual impairment.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[27,33],"class_list":["post-1702","post","type-post","status-publish","format-standard","hentry","category-fail","tag-accessibility","tag-html"],"_links":{"self":[{"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/posts\/1702","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/comments?post=1702"}],"version-history":[{"count":50,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/posts\/1702\/revisions"}],"predecessor-version":[{"id":1751,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/posts\/1702\/revisions\/1751"}],"wp:attachment":[{"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/media?parent=1702"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/categories?post=1702"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/timtanhuynh.com\/ux\/wp-json\/wp\/v2\/tags?post=1702"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}