import { useLayoutEffect } from "react"; import { View } from "react-native"; import stylesheet from "./stylesheet"; import { NCoreUIKitLocalize, NCoreUIKitTheme, SystemToolbar, PageContainer, CodeViewer, Header, Text } from "ncore-ui-kit"; import { useNavigation } from "@react-navigation/native"; import type RootStackParamList from "../../../navigation/type"; import type { NativeStackNavigationProp } from "@react-navigation/native-stack"; import { SettingsIcon, LogOutIcon, UserIcon, MenuIcon, HomeIcon } from "lucide-react-native"; const SystemToolbarPage = () => { const { radiuses, borders, spaces, colors } = NCoreUIKitTheme.useContext(); const { localize } = NCoreUIKitLocalize.useContext(); const navigation = useNavigation>(); useLayoutEffect(() => { navigation.setOptions({ header: () =>
, headerShown: true }); }, [ navigation, localize ]); return {localize("systemToolbar-desc")} console.log("Settings pressed"), icon: ({ color, size }) => , titleKey: "menu-settings" }, { content: [ { icon: ({ color, size }) => , onPress: () => console.log("Home"), titleKey: "menu-home" }, { icon: ({ color, size }) => , onPress: () => console.log("Logout"), titleKey: "close" } ], icon: ({ color, size }) => , titleKey: "avatar-title" } ]} icon={({ color, size }) => } titleKey="menu-title" /> {localize("usage")} }\n actions={[\n {\n titleKey: \"menu-settings\",\n icon: ({ color, size }) => ,\n onPress: () => console.log(\"Settings pressed\")\n }\n ]}\n/>"} language="tsx" /> ; }; export default SystemToolbarPage;