diff options
author | Eric Bailey <git@esb.lol> | 2023-11-21 16:58:13 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-21 16:58:13 -0600 |
commit | 47d2d3cbf289ebb2e893e07b5265aad8fcd64cb1 (patch) | |
tree | 240fa451bea159796c25180bc0501a6190c6c629 /src/view/shell/index.web.tsx | |
parent | 4c4ba553bdc4029e78eaf2ccf0f9df12e41a1b01 (diff) | |
download | voidsky-47d2d3cbf289ebb2e893e07b5265aad8fcd64cb1.tar.zst |
[PWI] Shell (#1967)
* Sidebars * Bottom bar * Drawer * Translate * Spacing fix * Fix responsive regression * Fix nit
Diffstat (limited to 'src/view/shell/index.web.tsx')
-rw-r--r-- | src/view/shell/index.web.tsx | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/view/shell/index.web.tsx b/src/view/shell/index.web.tsx index 09f8ba983..e833a08bf 100644 --- a/src/view/shell/index.web.tsx +++ b/src/view/shell/index.web.tsx @@ -21,8 +21,8 @@ import { useSetDrawerOpen, useOnboardingState, } from '#/state/shell' -import {useSession} from '#/state/session' import {useCloseAllActiveElements} from '#/state/util' +import {useLoggedOutView} from '#/state/shell/logged-out' function ShellInner() { const isDrawerOpen = useIsDrawerOpen() @@ -30,8 +30,8 @@ function ShellInner() { const onboardingState = useOnboardingState() const {isDesktop, isMobile} = useWebMediaQueries() const navigator = useNavigation<NavigationProp>() - const {hasSession} = useSession() const closeAllActiveElements = useCloseAllActiveElements() + const {showLoggedOut} = useLoggedOutView() useAuxClick() @@ -42,7 +42,7 @@ function ShellInner() { }, [navigator, closeAllActiveElements]) const showBottomBar = isMobile && !onboardingState.isActive - const showSideNavs = !isMobile && hasSession && !onboardingState.isActive + const showSideNavs = !isMobile && !onboardingState.isActive && !showLoggedOut return ( <View style={[s.hContentRegion, {overflow: 'hidden'}]}> <View style={s.hContentRegion}> @@ -50,16 +50,22 @@ function ShellInner() { <FlatNavigator /> </ErrorBoundary> </View> + {showSideNavs && ( <> <DesktopLeftNav /> <DesktopRightNav /> </> )} + <Composer winHeight={0} /> + {showBottomBar && <BottomBarWeb />} + <ModalsContainer /> + <Lightbox /> + {!isDesktop && isDrawerOpen && ( <TouchableOpacity onPress={() => setDrawerOpen(false)} |