1- /**
2- * Sample React Native App
3- * https://github.com/facebook/react-native
4- *
5- * Generated with the TypeScript template
6- * https://github.com/react-native-community/react-native-template-typescript
7- *
8- * @format
9- */
1+ import React from 'react' ;
2+ import { useColorScheme } from 'react-native' ;
103
11- import React , { type PropsWithChildren } from 'react' ;
12- import {
13- SafeAreaView ,
14- ScrollView ,
15- StatusBar ,
16- StyleSheet ,
17- Text ,
18- useColorScheme ,
19- View ,
20- } from 'react-native' ;
21-
22- import {
23- Colors ,
24- DebugInstructions ,
25- Header ,
26- LearnMoreLinks ,
27- ReloadInstructions ,
28- } from 'react-native/Libraries/NewAppScreen' ;
29-
30- const Section : React . FC <
31- PropsWithChildren < {
32- title : string ;
33- } >
34- > = ( { children, title} ) => {
35- const isDarkMode = useColorScheme ( ) === 'dark' ;
36- return (
37- < View style = { styles . sectionContainer } >
38- < Text
39- style = { [
40- styles . sectionTitle ,
41- {
42- color : isDarkMode ? Colors . white : Colors . black ,
43- } ,
44- ] } >
45- { title }
46- </ Text >
47- < Text
48- style = { [
49- styles . sectionDescription ,
50- {
51- color : isDarkMode ? Colors . light : Colors . dark ,
52- } ,
53- ] } >
54- { children }
55- </ Text >
56- </ View >
57- ) ;
58- } ;
4+ import { Colors } from 'react-native/Libraries/NewAppScreen' ;
5+ import Navigation from './src/navigation' ;
596
607const App = ( ) => {
618 const isDarkMode = useColorScheme ( ) === 'dark' ;
@@ -65,56 +12,10 @@ const App = () => {
6512 } ;
6613
6714 return (
68- < SafeAreaView style = { backgroundStyle } >
69- < StatusBar
70- barStyle = { isDarkMode ? 'light-content' : 'dark-content' }
71- backgroundColor = { backgroundStyle . backgroundColor }
72- />
73- < ScrollView
74- contentInsetAdjustmentBehavior = "automatic"
75- style = { backgroundStyle } >
76- < Header />
77- < View
78- style = { {
79- backgroundColor : isDarkMode ? Colors . black : Colors . white ,
80- } } >
81- < Section title = "Step One" >
82- Edit < Text style = { styles . highlight } > App.tsx</ Text > to change this
83- screen and then come back to see your edits.
84- </ Section >
85- < Section title = "See Your Changes" >
86- < ReloadInstructions />
87- </ Section >
88- < Section title = "Debug" >
89- < DebugInstructions />
90- </ Section >
91- < Section title = "Learn More" >
92- Read the docs to discover what to do next:
93- </ Section >
94- < LearnMoreLinks />
95- </ View >
96- </ ScrollView >
97- </ SafeAreaView >
15+ < >
16+ < Navigation />
17+ </ >
9818 ) ;
9919} ;
10020
101- const styles = StyleSheet . create ( {
102- sectionContainer : {
103- marginTop : 32 ,
104- paddingHorizontal : 24 ,
105- } ,
106- sectionTitle : {
107- fontSize : 24 ,
108- fontWeight : '600' ,
109- } ,
110- sectionDescription : {
111- marginTop : 8 ,
112- fontSize : 18 ,
113- fontWeight : '400' ,
114- } ,
115- highlight : {
116- fontWeight : '700' ,
117- } ,
118- } ) ;
119-
12021export default App ;
0 commit comments