Your music, beautifully tracked. All yours. (coming soon) teal.fm
teal-fm atproto

hide tab bar if not logged in

+3 -3
+3 -3
apps/amethyst/app/(tabs)/_layout.tsx
··· 5 6 import Colors from "../../constants/Colors"; 7 import { Icon, iconWithClassName } from "../../lib/icons/iconWithClassName"; 8 - import useIsMobile from "@/hooks/useIsMobile"; 9 import { useStore } from "@/stores/mainStore"; 10 import { useColorScheme } from "nativewind"; 11 ··· 19 const { colorScheme } = useColorScheme(); 20 const authStatus = useStore((state) => state.status); 21 // if we are on web but not native and web width is greater than 1024px 22 - const hideTabBar = useIsMobile() || authStatus !== "loggedIn"; 23 24 return ( 25 <Tabs ··· 33 tabBarShowLabel: true, 34 tabBarStyle: { 35 //height: 75, 36 - display: "flex", 37 }, 38 }} 39 >
··· 5 6 import Colors from "../../constants/Colors"; 7 import { Icon, iconWithClassName } from "../../lib/icons/iconWithClassName"; 8 + //import useIsMobile from "@/hooks/useIsMobile"; 9 import { useStore } from "@/stores/mainStore"; 10 import { useColorScheme } from "nativewind"; 11 ··· 19 const { colorScheme } = useColorScheme(); 20 const authStatus = useStore((state) => state.status); 21 // if we are on web but not native and web width is greater than 1024px 22 + const hideTabBar = authStatus !== "loggedIn"; // || useIsMobile() 23 24 return ( 25 <Tabs ··· 33 tabBarShowLabel: true, 34 tabBarStyle: { 35 //height: 75, 36 + display: hideTabBar ? "none" : "flex", 37 }, 38 }} 39 >