mirror of
https://github.com/standardnotes/app
synced 2026-10-21 06:03:17 -04:00
23 lines
735 B
TypeScript
23 lines
735 B
TypeScript
import RoundIconButton from '../Button/RoundIconButton'
|
|
import { AppPaneId } from '../ResponsivePane/AppPaneMetadata'
|
|
import { useResponsiveAppPane } from '../ResponsivePane/ResponsivePaneProvider'
|
|
|
|
export const NavigationMenuButton = () => {
|
|
const { selectedPane, toggleAppPane } = useResponsiveAppPane()
|
|
|
|
return (
|
|
<RoundIconButton
|
|
className="mr-3 md:hidden pointer-coarse:md-only:flex pointer-coarse:lg-only:flex"
|
|
onClick={() => {
|
|
if (selectedPane === AppPaneId.Items || selectedPane === AppPaneId.Editor) {
|
|
toggleAppPane(AppPaneId.Navigation)
|
|
} else {
|
|
toggleAppPane(AppPaneId.Items)
|
|
}
|
|
}}
|
|
label="Open navigation menu"
|
|
icon="menu-variant"
|
|
/>
|
|
)
|
|
}
|