-
-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[RNKC-053] - native-stack + statusBarTranslucent issue (#50)
## Description Added integration of `native-stack` into example application. ## Motivation and Context This example shows, that `statusBarTranslucent` + `native-stack` + `react-native 0.69` doesn't work together 😄 ## Changelog ### JS - added `native-stack` example; ## How Has This Been Tested? Tested manually :) ## Screenshots (if appropriate): |Expected|Actual| |---------|-------| |<img width="255" alt="image" src="https://user-images.githubusercontent.com/22820318/184424127-5e5912f8-acc8-4135-8d75-844797cbaeb1.png">|<img width="260" alt="image" src="https://user-images.githubusercontent.com/22820318/184427263-44435502-58df-471f-b749-0d9b7f7b868b.png">| Pay an attention to the position of yellow TextInput and bubbles. In Actual result it seems like window is shrinking, that's why they are displaying higher, than expected. ## Checklist - [x] CI successfully passed
- Loading branch information
1 parent
e34cbad
commit b8f1240
Showing
12 changed files
with
128 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import React from 'react'; | ||
|
||
import { | ||
createNativeStackNavigator, | ||
NativeStackNavigationOptions, | ||
} from '@react-navigation/native-stack'; | ||
|
||
import { ScreenNames } from '../../constants/screenNames'; | ||
import KeyboardAnimation from '../../screens/Examples/KeyboardAnimation'; | ||
|
||
export type NativeStackParamList = { | ||
[ScreenNames.NATIVE_STACK]: {}; | ||
}; | ||
|
||
const Stack = createNativeStackNavigator<NativeStackParamList>(); | ||
|
||
const options: Record<string, NativeStackNavigationOptions> = { | ||
[ScreenNames.NATIVE_STACK]: { | ||
headerShown: false, | ||
statusBarTranslucent: true, | ||
}, | ||
}; | ||
|
||
const NativeStack = () => ( | ||
<Stack.Navigator initialRouteName={ScreenNames.NATIVE_STACK}> | ||
<Stack.Screen | ||
name={ScreenNames.NATIVE_STACK} | ||
component={KeyboardAnimation} | ||
options={options[ScreenNames.NATIVE_STACK]} | ||
/> | ||
</Stack.Navigator> | ||
); | ||
|
||
export default NativeStack; |
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,34 @@ | ||
import React from 'react'; | ||
|
||
import { | ||
createNativeStackNavigator, | ||
NativeStackNavigationOptions, | ||
} from '@react-navigation/native-stack'; | ||
|
||
import { ScreenNames } from '../../constants/screenNames'; | ||
import KeyboardAnimation from '../../screens/Examples/KeyboardAnimation'; | ||
|
||
export type NativeStackParamList = { | ||
[ScreenNames.NATIVE_STACK]: {}; | ||
}; | ||
|
||
const Stack = createNativeStackNavigator<NativeStackParamList>(); | ||
|
||
const options: Record<string, NativeStackNavigationOptions> = { | ||
[ScreenNames.NATIVE_STACK]: { | ||
headerShown: false, | ||
statusBarTranslucent: true, | ||
}, | ||
}; | ||
|
||
const NativeStack = () => ( | ||
<Stack.Navigator initialRouteName={ScreenNames.NATIVE_STACK}> | ||
<Stack.Screen | ||
name={ScreenNames.NATIVE_STACK} | ||
component={KeyboardAnimation} | ||
options={options[ScreenNames.NATIVE_STACK]} | ||
/> | ||
</Stack.Navigator> | ||
); | ||
|
||
export default NativeStack; |
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