-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added @react-navigation/native v6 (#7)
* react-navigation rnative * rnative react-navigation init * init react native with navigation * xpo react navigation testing * expo working again - needed react 17.0.2 * working with newer react native version * working build with react native bump in xpo * read me update
- Loading branch information
Enrico Valbuena
authored
Dec 30, 2021
1 parent
3808b9b
commit f09ad3f
Showing
25 changed files
with
668 additions
and
625 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/** | ||
* Sample React Native App | ||
* https://github.com/facebook/react-native | ||
* | ||
* Generated with the TypeScript template | ||
* https://github.com/react-native-community/react-native-template-typescript | ||
* | ||
* @format | ||
*/ | ||
|
||
import * as React from 'react'; | ||
import {StatusBar as RNStatusBar, useColorScheme} from 'react-native'; | ||
|
||
const StatusBar = () => { | ||
const isDarkMode = useColorScheme() === 'dark'; | ||
|
||
return ( | ||
<RNStatusBar barStyle={isDarkMode ? 'light-content' : 'dark-content'} /> | ||
); | ||
}; | ||
|
||
export default StatusBar; |
35 changes: 35 additions & 0 deletions
35
apps/rnative/src/screens/DefaultReactNativeScreen/components/Section.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
import * as React from 'react'; | ||
import {Text, useColorScheme, View} from 'react-native'; | ||
import {Colors} from 'react-native/Libraries/NewAppScreen'; | ||
import {styles} from './styles'; | ||
|
||
type SectionProps = { | ||
title?: string; | ||
children?: React.ReactNode; | ||
}; | ||
|
||
export const Section: React.FC<SectionProps> = ({children, title}) => { | ||
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> | ||
); | ||
}; |
Oops, something went wrong.