-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathApp.tsx
More file actions
35 lines (31 loc) · 954 Bytes
/
App.tsx
File metadata and controls
35 lines (31 loc) · 954 Bytes
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
import React from 'react';
import { SafeAreaView, StyleSheet, useColorScheme } from 'react-native';
import { Chip, Container, ThemeProvider } from './src/packages/react-native-material-elements';
import MaterialIcons from 'react-native-vector-icons/MaterialIcons';
function App(): React.JSX.Element {
const colorScheme = useColorScheme();
const isDarkMode = colorScheme === 'dark';
return (
<ThemeProvider>
<SafeAreaView style={{ flex: 1 }}>
<Container flex={1} style={isDarkMode ? styles.dark : styles.light}>
<Chip
label="Save"
color="warning"
onPress={() => {}}
endIcon={<MaterialIcons name="keyboard-arrow-down" size={20} />}
/>
</Container>
</SafeAreaView>
</ThemeProvider>
);
}
const styles = StyleSheet.create({
dark: {
backgroundColor: '#000000',
},
light: {
backgroundColor: '#ffffff',
},
});
export default App;