Commit 458e721
committed
Rustdoc accessibility: use real headers for doc items
This is a pretty annoying workaround: the specifications literally
contradict each other on the matter of whether headers may be nested
inside of summaries. We need the headers for people who use outline
mode to browse rustdoc, mostly in screen readers, and the headers
need to be inside the summary tag so that they're visible when the
details tag is collapsed.
HTML5 says it's okay, but the ordinary button semantics in ARIA say
that headers nested in buttons are ignored, and summary is a button.
Which means some screen readers, like NVDA, work, while others,
like JAWS, don't.1 parent e742158 commit 458e721
File tree
4 files changed
+26
-18
lines changed- src/librustdoc/html
- render
- static
- css
- js
4 files changed
+26
-18
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1350 | 1350 | | |
1351 | 1351 | | |
1352 | 1352 | | |
1353 | | - | |
| 1353 | + | |
1354 | 1354 | | |
1355 | 1355 | | |
1356 | 1356 | | |
1357 | 1357 | | |
1358 | 1358 | | |
1359 | 1359 | | |
1360 | 1360 | | |
1361 | | - | |
| 1361 | + | |
1362 | 1362 | | |
1363 | 1363 | | |
1364 | 1364 | | |
| |||
1371 | 1371 | | |
1372 | 1372 | | |
1373 | 1373 | | |
1374 | | - | |
| 1374 | + | |
1375 | 1375 | | |
1376 | 1376 | | |
1377 | 1377 | | |
| |||
1381 | 1381 | | |
1382 | 1382 | | |
1383 | 1383 | | |
1384 | | - | |
| 1384 | + | |
1385 | 1385 | | |
1386 | 1386 | | |
1387 | 1387 | | |
| |||
1394 | 1394 | | |
1395 | 1395 | | |
1396 | 1396 | | |
1397 | | - | |
| 1397 | + | |
1398 | 1398 | | |
1399 | 1399 | | |
1400 | 1400 | | |
| |||
1404 | 1404 | | |
1405 | 1405 | | |
1406 | 1406 | | |
1407 | | - | |
| 1407 | + | |
1408 | 1408 | | |
1409 | 1409 | | |
1410 | 1410 | | |
1411 | 1411 | | |
1412 | 1412 | | |
1413 | 1413 | | |
1414 | 1414 | | |
1415 | | - | |
| 1415 | + | |
1416 | 1416 | | |
1417 | 1417 | | |
1418 | 1418 | | |
| |||
1422 | 1422 | | |
1423 | 1423 | | |
1424 | 1424 | | |
1425 | | - | |
| 1425 | + | |
1426 | 1426 | | |
1427 | 1427 | | |
1428 | 1428 | | |
| |||
1613 | 1613 | | |
1614 | 1614 | | |
1615 | 1615 | | |
1616 | | - | |
| 1616 | + | |
1617 | 1617 | | |
1618 | 1618 | | |
1619 | 1619 | | |
| |||
1629 | 1629 | | |
1630 | 1630 | | |
1631 | 1631 | | |
1632 | | - | |
| 1632 | + | |
1633 | 1633 | | |
1634 | 1634 | | |
1635 | 1635 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
621 | 621 | | |
622 | 622 | | |
623 | 623 | | |
624 | | - | |
| 624 | + | |
625 | 625 | | |
626 | | - | |
| 626 | + | |
627 | 627 | | |
628 | 628 | | |
629 | 629 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
146 | 146 | | |
147 | 147 | | |
148 | 148 | | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
149 | 156 | | |
150 | 157 | | |
151 | 158 | | |
| |||
233 | 240 | | |
234 | 241 | | |
235 | 242 | | |
236 | | - | |
| 243 | + | |
237 | 244 | | |
238 | 245 | | |
239 | 246 | | |
| |||
520 | 527 | | |
521 | 528 | | |
522 | 529 | | |
523 | | - | |
| 530 | + | |
524 | 531 | | |
525 | 532 | | |
526 | 533 | | |
| |||
536 | 543 | | |
537 | 544 | | |
538 | 545 | | |
539 | | - | |
| 546 | + | |
540 | 547 | | |
541 | 548 | | |
542 | 549 | | |
| |||
742 | 749 | | |
743 | 750 | | |
744 | 751 | | |
745 | | - | |
| 752 | + | |
746 | 753 | | |
747 | 754 | | |
748 | 755 | | |
| |||
1103 | 1110 | | |
1104 | 1111 | | |
1105 | 1112 | | |
1106 | | - | |
| 1113 | + | |
1107 | 1114 | | |
1108 | 1115 | | |
1109 | 1116 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
706 | 706 | | |
707 | 707 | | |
708 | 708 | | |
709 | | - | |
| 709 | + | |
710 | 710 | | |
| 711 | + | |
711 | 712 | | |
712 | 713 | | |
713 | 714 | | |
| |||
0 commit comments