This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 10600 - Strong semantics role="presentation" for <img alt="<empty>"> is wrong or inaccurate
Summary: Strong semantics role="presentation" for <img alt="<empty>"> is wrong or inac...
Status: RESOLVED WONTFIX
Alias: None
Product: HTML WG
Classification: Unclassified
Component: pre-LC1 HTML5 spec (editor: Ian Hickson) (show other bugs)
Version: unspecified
Hardware: PC All
: P1 major
Target Milestone: LC
Assignee: Ian 'Hixie' Hickson
QA Contact: HTML WG Bugzilla archive list
URL: http://dev.w3.org/html5/spec/content-...
Whiteboard:
Keywords: a11y, aria
Depends on:
Blocks: 10066
  Show dependency treegraph
 
Reported: 2010-09-10 15:05 UTC by Leif Halvard Silli
Modified: 2010-10-12 15:14 UTC (History)
9 users (show)

See Also:


Attachments

Description Leif Halvard Silli 2010-09-10 15:05:04 UTC
Spec says:

]] img element whose alt attribute's value is empty  =  presentation role [[

This means that it would be illegal to do the following

<img role="img" alt="" aria-labelledby="label" src="*">
<p id="label">Lorem ipsum</p>

That particular issue could be fixed by adding more conditions for when the strong semantics applies. E.g. setting the condition to something like this:

]] img element whose alt attribute's value is empty and which doesn't have an non-empty @aria-labelledby or @aria-describedby or @longdesc  =  presentation role [[

However, it could be argued that strong semantics still is wrong: The author might want to make sure that an empty <img> is announced to the user, by setting its role to role="img", even if the alt="" is empty.

Therefore, in addition specifying the conditions for when @alt=<empty> implies role="presentation", I also suggest that "img element whose alt attribute's is empty" is moved from the strong table to the weak/default semantics table.
Comment 1 Leif Halvard Silli 2010-09-10 15:26:55 UTC
One use case for <img role="img" alt="" src="*"> could for instance be to make sure that it is possible for the user to download the image.
Comment 2 steve faulkner 2010-09-10 15:31:55 UTC
(In reply to comment #1)
> One use case for <img role="img" alt="" src="*"> could for instance be to make
> sure that it is possible for the user to download the image.

Note that on the Mac although there appears no way for the voiceover user with vision impairement to be alerted that an image is present when its alt="" other users are able to see the image and open the context image contect menu.
Comment 3 Leif Halvard Silli 2010-09-10 17:13:57 UTC
(In reply to comment #2)

> Note that on the Mac although there appears no way for the voiceover user with
> vision impairement to be alerted that an image is present when its alt="" other
> users are able to see the image and open the context image contect menu.

Setting the role of <img alt=""> to role="img" _does_ provide a way for the the VoiceOver user with vision impairement to be alerted that an image is present. So, I suppose you wanted to point out that this is a thing which could justify role="img" when then the @alt is empty.
Comment 4 Ian 'Hixie' Hickson 2010-09-26 22:07:48 UTC
(In reply to comment #0)
> 
> ]] img element whose alt attribute's value is empty  =  presentation role [[
> 
> This means that it would be illegal to do the following
> 
> <img role="img" alt="" aria-labelledby="label" src="*">
> <p id="label">Lorem ipsum</p>

If the image is presentational or completely redundant with other text on the page (as indicated by alt=""), why would the user ever need to be able to interact with that image? How would aria-labelledby="" in any way improve accessibility in this case? It seems like it would just taunt the user.


EDITOR'S RESPONSE: This is an Editor's Response to your comment. If you are satisfied with this response, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document:
   http://dev.w3.org/html5/decision-policy/decision-policy.html

Status: Rejected
Change Description: no spec change
Rationale: It's intentional.
Comment 5 Joshue O Connor 2010-10-12 15:14:51 UTC
Bug Triage sub Team thinks Ian's response is appropriate. We don't think the TF needs to take up this issue.