47 lines
1.2 KiB
TypeScript
47 lines
1.2 KiB
TypeScript
import { Ionicons } from "@expo/vector-icons";
|
|
import { Tabs } from "expo-router";
|
|
import { useThemeColor } from "heroui-native";
|
|
|
|
export default function TabLayout() {
|
|
const themeColorForeground = useThemeColor("foreground");
|
|
const themeColorBackground = useThemeColor("background");
|
|
|
|
return (
|
|
<Tabs
|
|
screenOptions={{
|
|
headerShown: false,
|
|
headerStyle: {
|
|
backgroundColor: themeColorBackground,
|
|
},
|
|
headerTintColor: themeColorForeground,
|
|
headerTitleStyle: {
|
|
color: themeColorForeground,
|
|
fontWeight: "600",
|
|
},
|
|
tabBarStyle: {
|
|
backgroundColor: themeColorBackground,
|
|
},
|
|
}}
|
|
>
|
|
<Tabs.Screen
|
|
name="index"
|
|
options={{
|
|
title: "Home",
|
|
tabBarIcon: ({ color, size }: { color: string; size: number }) => (
|
|
<Ionicons name="home" size={size} color={color} />
|
|
),
|
|
}}
|
|
/>
|
|
<Tabs.Screen
|
|
name="two"
|
|
options={{
|
|
title: "Explore",
|
|
tabBarIcon: ({ color, size }: { color: string; size: number }) => (
|
|
<Ionicons name="compass" size={size} color={color} />
|
|
),
|
|
}}
|
|
/>
|
|
</Tabs>
|
|
);
|
|
}
|