Skip to content

Commit

Permalink
Add ARIA role to sidebar toggle in Rustdoc
Browse files Browse the repository at this point in the history
This indicates that the div is an interactive element, and makes the
sidebar toggle "clickable" in assistive technologies.

Fixes #82582
  • Loading branch information
tazjin committed Feb 27, 2021
1 parent 0846043 commit e026e18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/librustdoc/html/layout.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ crate fn render<T: Print, S: Print>(
<![endif]-->\
{before_content}\
<nav class=\"sidebar\">\
<div class=\"sidebar-menu\">&#9776;</div>\
<div class=\"sidebar-menu\" role=\"button\">&#9776;</div>\
{logo}\
{sidebar}\
</nav>\
Expand Down

0 comments on commit e026e18

Please sign in to comment.