66 lines
1.3 KiB
JavaScript
66 lines
1.3 KiB
JavaScript
import 'react-native-gesture-handler';
|
|
import React from 'react';
|
|
|
|
import {
|
|
SafeArea,
|
|
SafeAreaView,
|
|
ScrollView,
|
|
StatusBar,
|
|
StyleSheet,
|
|
Text,
|
|
useColorScheme,
|
|
View,
|
|
} from 'react-native';
|
|
|
|
import {
|
|
Colors,
|
|
DebugInstructions,
|
|
LearnMoreLinks,
|
|
ReloadInstructions,
|
|
} from 'react-native/Libraries/NewAppScreen';
|
|
import { NavigationContainer } from '@react-navigation/native';
|
|
import { createStackNavigator } from '@react-navigation/stack';
|
|
import { enableScreens } from 'react-native-screens';
|
|
import HomeScreen from './components/HomeScreen'
|
|
import BottomTab from './components/BottomTab'
|
|
const Section = ({children, title}): Node => {
|
|
const isDarkMode = useColorScheme() === 'dark';
|
|
return (
|
|
<View style={styles.sectionContainer}>
|
|
<Text
|
|
style={[
|
|
styles.sectionTitle,
|
|
{
|
|
color: isDarkMode ? Colors.white : Colors.black,
|
|
},
|
|
]}>
|
|
{title}
|
|
</Text>
|
|
<Text
|
|
style={[
|
|
styles.sectionDescription,
|
|
{
|
|
color: isDarkMode ? Colors.light : Colors.dark,
|
|
},
|
|
]}>
|
|
{children}
|
|
</Text>
|
|
</View>
|
|
);
|
|
};
|
|
|
|
const Stack = createStackNavigator();
|
|
|
|
const App = () => {
|
|
|
|
enableScreens();
|
|
return (
|
|
<NavigationContainer>
|
|
<BottomTab />
|
|
</NavigationContainer>
|
|
|
|
);
|
|
};
|
|
|
|
export default App;
|