-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathApp.tsx
56 lines (51 loc) · 1.7 KB
/
App.tsx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import * as eva from '@eva-design/eva';
import * as fal from '@fal-ai/serverless-client';
import { createDrawerNavigator } from '@react-navigation/drawer';
import { NavigationContainer } from '@react-navigation/native';
import { ApplicationProvider, useTheme } from '@ui-kitten/components';
import React from 'react';
import { appTheme } from '~/components/theme';
import { DrawingScreen } from '~/screens/drawing';
import { HomeScreen } from '~/screens/home';
const Drawer = createDrawerNavigator();
fal.config({
proxyUrl: 'http://localhost:3333/api/fal/proxy',
});
function App() {
return (
<ApplicationProvider {...eva} theme={appTheme}>
<Navigation />
</ApplicationProvider>
);
}
function Navigation() {
const theme = useTheme();
return (
<NavigationContainer>
<Drawer.Navigator
initialRouteName="Home"
screenOptions={{
headerStyle: {
// shadowColor: theme['border-basic-color-4'],
backgroundColor: theme['background-basic-color-1'],
},
headerTitleStyle: {
color: theme['text-basic-color'],
},
headerTintColor: theme['color-primary-500'],
sceneContainerStyle: {
backgroundColor: theme['background-basic-color-3'],
},
drawerStyle: {
backgroundColor: theme['background-basic-color-1'],
},
drawerInactiveTintColor: theme['text-basic-color'],
drawerActiveTintColor: theme['color-primary-500'],
}}>
<Drawer.Screen name="Home" component={HomeScreen} />
<Drawer.Screen name="Drawing" component={DrawingScreen} />
</Drawer.Navigator>
</NavigationContainer>
);
}
export default App;