ARIA: term role
Theterm role can be used for a word or phrase with an optional correspondingdefinition.
In this article
Description
Theterm role can be used for a word or phrase with an optional correspondingdefinition. It is equivalent in semantics to the HTML<dfn> element and the definition term (<dt>) element within a definition list (<dl> ).
Theterm role is used to explicitly identify a word or phrase for which a definition has been provided by the author or is expected to be provided by the user. If there is an existing definition, or a form or form control to enter a definition, authors SHOULD setaria-details to point to the related element.
Don't use therole="term" on interactive elements like links because it can interfere with assistive technology users ability to interact with the element. Also, the term itself is the accessible name, so do not usearia-label oraria-labelledby.
Warning:The accessible name should be the term itself, so DO NOT usearia-label oraria-labelledby.
Associated WAI-ARIA roles, states, and properties
None.
Keyboard interactions
None.
Required JavaScript features
None.
Examples
<p> <span role="term">Mansplaining</span>, <span role="definition" >a portmanteau of "man" and "explain", is the patronizing act of explaining without being asked to do so, to someone already learned on the topic, often after someone has already explained it</span >.</p>Including better semantics, the above could also be written:
<p> <dfn role="term">Mansplaining</dfn>, <span role="definition" >a portmanteau of "man" and "explain", is the patronizing act of explaining without being asked to do so, to someone already learned on the topic, often after someone has already explained it</span >.</p>or without any ARIA (but possibly not how you want it presented)
<dl> <dt>Mansplaining</dt> <dd> A portmanteau of "man" and "explain", is the patronizing act of explaining without being asked to do so, to someone already learned on the topic, often after someone has already explained it. </dd></dl>Accessibility concerns
Don't use therole="term" on interactive elements such as links as it can interfere with the assistive technology user's ability to interact with the element.
Best practices
Allow the term itself to define the accessible name. Do not usearia-label oraria-labelledby.
Specifications
| Specification |
|---|
| Accessible Rich Internet Applications (WAI-ARIA)> # term> |
See also
- ARIA:
definitionrole. - The HTML
<dfn>element