Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ function CloseButton() {
return (
<button
type="button"
aria-label="Close navigation bar"
className="clean-btn navbar-sidebar__close"
onClick={() => mobileSidebar.toggle()}>
<IconClose color="var(--ifm-color-emphasis-600)" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,14 @@ import {useNavbarMobileSidebar} from '@docusaurus/theme-common/internal';
import IconMenu from '@theme/Icon/Menu';

export default function MobileSidebarToggle(): JSX.Element {
const mobileSidebar = useNavbarMobileSidebar();
const {toggle, shown} = useNavbarMobileSidebar();
return (
<button
onClick={mobileSidebar.toggle}
onKeyDown={mobileSidebar.toggle}
onClick={toggle}
aria-label="Navigation bar toggle"
aria-expanded={shown}
className="navbar__toggle clean-btn"
type="button"
tabIndex={0}>
type="button">
<IconMenu />
</button>
);
Expand Down