Skip to content

Commit

Permalink
or else if otherwise sure?
Browse files Browse the repository at this point in the history
  • Loading branch information
scottaohara authored Nov 22, 2024
1 parent 89b18fb commit ec41dfc
Showing 1 changed file with 4 additions and 22 deletions.
26 changes: 4 additions & 22 deletions html-aam/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -870,29 +870,11 @@ <h4 id="el-autonomous-custom-element">autonomous custom element</h4>
explicit role for the element:
</p>
<ul>
<li>if the custom element is focusable: expose as <a class="core-mapping" href="#role-map-group">`group`</a> role</li>
<li>if the custom element has an `aria-live` attribute: expose as <a class="core-mapping" href="#role-map-generic">`generic`</a> role</li>
<li>if element internals are used to set a global ARIA property: expose as <a class="core-mapping" href="#role-map-generic">`generic`</a> role</li>
<li>if an author specifies an ARIA attribute on the custom element that creates a relation with another element: expose <a class="core-mapping" href="#role-map-generic">`group`</a> role</li>
<li>if the custom element is focusable: expose the <a class="core-mapping" href="#role-map-generic">`group`</a> role</li>
<li>else if an author specifies an ARIA attribute on the custom element that creates a relation with another element: expose the <a class="core-mapping" href="#role-map-generic">`group`</a> role</li>
<li>else if the custom element has an `aria-live` attribute: expose the <a class="core-mapping" href="#role-map-generic">`generic`</a> role</li>
<li>else if element internals are used to set a global ARIA property: expose the <a class="core-mapping" href="#role-map-generic">`generic`</a> role</li>
</ul>
<div class="example">
<p>The following are exmaples of an author specifiying a relationships between custom elements and other elements in the DOM.</p>
<pre><code>
&lt;my-element aria-details=ex>...&lt;/my-element>
...
&lt;div id=ex> &lt;!-- details for my-element --> &lt;/div>
...
&lt;ex-ample aria-owns=u>...&lt;/ex-ample>
...
&lt;div id=u> &lt;!-- becomes the last a11y child of ex-ample --> &lt;/div>

&lt;id-lement> ... &lt;/id-lement>
&lt;script>
...
document.querySelector('id-lement').ariaDescribedbyByElements = [ descElement ];
&lt;/script>
</code></pre>
</div>
</td>
</tr>
</tbody>
Expand Down

0 comments on commit ec41dfc

Please sign in to comment.