Skip to content

Commit 7a5aa81

Browse files
authored
Correction for HTML element role mapping (#550)
Correction for HTML element role mapping per w3c/aria#2504 - the html element doesn't actually map to the `document` role - rather a parent `document node` to the `html` element is what exposes the `document` role of a web page. This update fixes the spec to match the updated HTML aam mapping / matches reality. The `generic` role is being added as an "allowed" but not recommended role to the `html` element. The `document` role is being kept as an allowed role for the `html` element. The rational there being that this has been in the spec for a long time and even when specified on the html element, from what i can tell, there's no pro/con to its inclusion.
1 parent a4ba0a6 commit 7a5aa81

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

index.html

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!DOCTYPE html>
2-
<html lang="en-US">
2+
<html lang="en-us">
33
<head>
44
<meta charset="utf-8">
55
<title>ARIA in HTML</title>
@@ -64,6 +64,11 @@
6464
the following substantive additions and/or corrections have been proposed:
6565
</p>
6666
<ul>
67+
<li>
68+
<a href="https://github.com/w3c/html-aria/pull/550">23 July 2025 - Correction:</a>
69+
Clarify that the <a href="#el-html">`html`</a> element is a `generic` element, and that
70+
neither the `document` or `generic` roles are recommended to be used on the element.
71+
</li>
6772
<li>
6873
<a href="https://github.com/w3c/html-aria/pull/525">23 December 2024 - Addition:</a>
6974
Update the <a href="#el-img">`img`</a> element to allow the `math` role.
@@ -1532,11 +1537,12 @@ <h2 id="docconformance">
15321537
[^html^]
15331538
</th>
15341539
<td>
1535-
<code>role=<a href="#index-aria-document">document</a></code>
1540+
<code>role=<a href="#index-aria-generic">generic</a></code>
15361541
</td>
15371542
<td>
15381543
<p>
1539-
<a><strong class="nosupport">No `role`</strong></a> other than <code><a href="#index-aria-document">document</a></code>, which is NOT RECOMMENDED.
1544+
<a><strong class="nosupport">No `role`</strong></a> other than <code><a href="#index-aria-document">document</a></code>
1545+
or <code><a href="#index-aria-generic">generic</a></code>, which are NOT RECOMMENDED.
15401546
</p>
15411547
<p>
15421548
<strong>No `aria-*` attributes</strong>.

0 commit comments

Comments
 (0)