Commit 45dbaa2
authored
Update the algorithm to handle roles where naming is not supported (#53)
Add a statement to the end of Step 1 (stating that if the root node's
role doesn't support naming, return the empty string. At the present time,
this impacts nothing because all roles currently support naming. If that
changes within the ARIA spec, this modification is meant to accomplish
the following:
<span aria-label="bar">foo</span>: The span has no name.
<button><span aria-label="bar">foo</span></button>: The button's
accessible name is "bar" (but the span itself has no name).
In other words, it prohibits generic elements themselves from getting
names, but preserves the name calculation results authors might be
expecting in currently-deployed content.1 parent d8a7a71 commit 45dbaa2
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
252 | | - | |
| 252 | + | |
253 | 253 | | |
254 | 254 | | |
255 | 255 | | |
| |||
386 | 386 | | |
387 | 387 | | |
388 | 388 | | |
| 389 | + | |
389 | 390 | | |
390 | 391 | | |
391 | 392 | | |
| |||
0 commit comments