()
| 150 | })) |
| 151 | |
| 152 | export function MobileNavigation() { |
| 153 | let isInsideMobileNavigation = useIsInsideMobileNavigation() |
| 154 | let { isOpen, toggle, close } = useMobileNavigationStore() |
| 155 | let ToggleIcon = isOpen ? XIcon : MenuIcon |
| 156 | |
| 157 | return ( |
| 158 | <IsInsideMobileNavigationContext.Provider value={true}> |
| 159 | <button |
| 160 | type="button" |
| 161 | className="flex h-6 w-10 items-center justify-center rounded-md transition hover:bg-zinc-900/5 dark:hover:bg-white/5" |
| 162 | aria-label="Toggle navigation" |
| 163 | onClick={toggle} |
| 164 | > |
| 165 | <ToggleIcon className="w-3 stroke-zinc-900 dark:stroke-white" /> |
| 166 | </button> |
| 167 | {!isInsideMobileNavigation && ( |
| 168 | <Suspense fallback={null}> |
| 169 | <MobileNavigationDialog isOpen={isOpen} close={close} /> |
| 170 | </Suspense> |
| 171 | )} |
| 172 | </IsInsideMobileNavigationContext.Provider> |
| 173 | ) |
| 174 | } |
nothing calls this directly
no test coverage detected