Skip to content

Commit 9c74a5d

Browse files
authored
Editorial: revise redundant role declaration example (#482)
* Editorial: revise redundant role declaration example closes #478 * remove errant `;` closes #479
1 parent 60534de commit 9c74a5d

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

index.html

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -318,12 +318,11 @@

318318
<main role="Main">...</main>
319319
pre>
320320
<p>
321-
The following uses a `role=list` on an [^ul^] element. This is
322-
generally unnecessary, because the `ul` element is implicitly exposed
323-
as a `role=list`. However, some user agents suppress a list's
324-
implicit ARIA semantics if list markers are removed. Authors can
325-
use `role=list` to reinstate the role if necessary, though this
326-
practice would generally not be recommended, otherwise.
321+
The following uses a `role=list` on an [^ul^] element. As the `ul` element has an implicit role of `list`,
322+
explicitly adding the role would generally be considered redundant. However, some user agents suppress a list's
323+
implicit ARIA semantics if the list markers are removed from the visual presentation of the list items.
324+
Generally the redundant declaration of an element's implicit role would not be recommended, but in specific situations
325+
such as this, and where the role is necessary to expose, authors can explicitly add the role.
327326
p>
328327
<pre class="HTML example" title="Redundant role on list">
329328
<!-- Generally avoid doing this! -->
@@ -374,7 +373,7 @@

Adhere to the rules of ARIA

374373
p>
375374
<pre class="HTML example" title="Do not specify elements as generic">
376375
<!-- Avoid doing this! -->
377-
<article role="generic" ...>...</article>;
376+
<article role="generic" ...>...</article>
378377
pre>
379378
<p>
380379
Additionally, ARIA specifically mentions in <a data-cite="wai-aria-1.2/#host_general_conflict">Conflicts with Host Language Semanticsa>

0 commit comments

Comments
 (0)