Re:Writing - Human Interface Guidelines
by ryanjamurphy on Monday March 06, 2023 @07:58AM
(#35040430)
Huh, this is a good tip. I've always provided a rich description of decorative images, because I didn't want screen readers to "miss out," but apparently that was a bad idea!
Re:Writing - Human Interface Guidelines
by snowwrestler on Monday March 06, 2023 @08:50AM
(#35040941)
Well the logo might not be a great example, as it is often clickable to the home page and should have alt text so people know what it is.
A better example is when a site has little stock photo thumbnails with article titles on a navigational page. The screen reader can read the title text; knowing what’s in the thumbnail adds nothing.
Images should only have alt text when they contain “real” content (for example if it is an original photo that is relevant to the associated story).
A logo is a perfect example because so many sites are failing to do it correctly. When you do
<h1><img src alt="ACME logo">ACME</h1>
What gets rendered and read is what you would never want ACME logoACME
If you don't have or use actual text nearby then you just do this: <h1><img src alt="ACME"></h1>
Re:Writing - Human Interface Guidelines
by snowwrestler on Monday March 06, 2023 @02:09PM
(#35046055)
Got it, thanks for following up
Don't do: <h1><img src alt="ACME logo">ACME</h1>.