Skip to content

Commit

Permalink
Update: acknowledge the image role (#533)
Browse files Browse the repository at this point in the history
* Update: acknowledge the image role

role=`image` is the preferred default role, over the previous and still valid `img` role.

update the spec to call out the existence / allowance of the `image` role.

* add changelog
  • Loading branch information
scottaohara authored Dec 13, 2024
1 parent ca48852 commit 7f7718c
Showing 1 changed file with 14 additions and 7 deletions.
21 changes: 14 additions & 7 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@
the following substantive additions and/or corrections have been proposed:
</p>
<ul>
<li>
<a href="https://github.com/w3c/html-aria/pull/533">13 December 2024 - Addition:</a>
Update to include the `image` role as preferred synonym to the `img` role.
</li>
<li>
<a href="https://github.com/w3c/html-aria/pull/507">13 December 2024 - Addition:</a>
Clarify the allowance for `aria-hidden` when used with the `hidden` attribute.
Expand Down Expand Up @@ -1217,6 +1221,7 @@ <h2 id="docconformance">
<a href="#index-aria-application">`application`</a>,
<a href="#index-aria-document">`document`</a>,
<a href="#index-aria-img">`img`</a>,
<a href="#index-aria-img">`image`</a>,
<a href="#index-aria-none">`none`</a>
or <a href="#index-aria-presentation">`presentation`</a>.
</p>
Expand Down Expand Up @@ -1563,6 +1568,7 @@ <h2 id="docconformance">
<a href="#index-aria-application">`application`</a>,
<a href="#index-aria-document">`document`</a>,
<a href="#index-aria-img">`img`</a>,
<a href="#index-aria-img">`image`</a>,
<a href="#index-aria-none">`none`</a>
or <a href="#index-aria-presentation">`presentation`</a>.
</p>
Expand All @@ -1581,7 +1587,7 @@ <h2 id="docconformance">
<td>
If the `img` has non-empty [^img/alt^] (`alt="some text"`) or an accessible name is provided another
<a data-cite="html-aam-1.0#img-element-accessible-name-computation">`img` naming method</a>:<br>
<code>role=<a href="#index-aria-img">img</a></code>
<code>role=<a href="#index-aria-img">img or image</a></code>
</td>
<td>
<p>
Expand All @@ -1605,7 +1611,7 @@ <h2 id="docconformance">
<a href="#index-aria-slider">`slider`</a>,
<a href="#index-aria-switch">`switch`</a>,
<a href="#index-aria-tab">`tab`</a> or
<a href="#index-aria-treeitem">`treeitem`</a>. (<code><a href="#index-aria-img">img</a></code> is also allowed, but NOT RECOMMENDED.)
<a href="#index-aria-treeitem">`treeitem`</a>. (<code><a href="#index-aria-img">img or image</a></code> is also allowed, but NOT RECOMMENDED.)
</p>
<p>
DPub Role:
Expand All @@ -1632,7 +1638,7 @@ <h2 id="docconformance">
<p id="el-img-no-alt" tabindex="-1">
If the `img` <a data-cite="html/images.html#unknown-images">lacks an `alt` attribute</a> and lacks any other
<a data-cite="html-aam-1.0#img-element-accessible-name-computation">`img` naming methods</a>:<br>
<code>role=<a href="#index-aria-img">img</a></code>
<code>role=<a href="#index-aria-img">img or image</a></code>
</p>
</div>
</td>
Expand All @@ -1642,7 +1648,7 @@ <h2 id="docconformance">
If the `img` has no `alt` attribute or accessible name:
<a><strong class="nosupport">No `role`</strong></a> other than the
<code>role=<a href="#index-aria-none">none</a></code> or <code><a href="#index-aria-presentation">presentation</a></code> roles.
(<code>role=<a href="#index-aria-img">img</a></code> is also allowed, but NOT RECOMMENDED.)
(<code>role=<a href="#index-aria-img">img or image</a></code> is also allowed, but NOT RECOMMENDED.)
</p>
<p>
If the `img` has an empty `alt=""` attribute and no `aria-label` or `aria-labelledby` attributes to provide it an accessible name:
Expand Down Expand Up @@ -2476,8 +2482,9 @@ <h2 id="docconformance">
<p>
Roles:
<a href="#index-aria-application">`application`</a>,
<a href="#index-aria-document">`document`</a>
or <a href="#index-aria-img">`img`</a>.
<a href="#index-aria-document">`document`</a>,
<a href="#index-aria-img">`img`</a>
or <a href="#index-aria-img">`image`</a>.
</p>
<p>
<a data-cite="wai-aria-1.2#global_states">Global `aria-*` attributes</a> and
Expand Down Expand Up @@ -4416,7 +4423,7 @@ <h2>
</tr>
<tr>
<th tabindex="-1" id="index-aria-img">
<a data-cite="wai-aria-1.2#img">`img`</a>
<a data-cite="wai-aria-1.2#img">`img` or `image`</a>
</th>
<td>
<ul>
Expand Down

0 comments on commit 7f7718c

Please sign in to comment.