|
@@ -29,7 +29,7 @@ const KeyboardScreen = require('./KeyboardScreen');
|
29
|
29
|
const BottomTabSideMenuScreen = require('./complexlayouts/BottomTabSideMenuScreen');
|
30
|
30
|
const FlatListScreen = require('./FlatListScreen');
|
31
|
31
|
const ContextScreen = require('./ContextScreen');
|
32
|
|
-const { TitleContext } = require('../context');
|
|
32
|
+const { ContextProvider } = require('../context');
|
33
|
33
|
|
34
|
34
|
function registerScreens() {
|
35
|
35
|
Navigation.registerComponent(`navigation.playground.CustomTransitionDestination`, () => CustomTransitionDestination);
|
|
@@ -40,12 +40,12 @@ function registerScreens() {
|
40
|
40
|
Navigation.registerComponent(`navigation.playground.LifecycleScreen`, () => LifecycleScreen);
|
41
|
41
|
Navigation.registerComponent(`navigation.playground.StaticLifecycleOverlay`, () => StaticLifecycleOverlay);
|
42
|
42
|
Navigation.registerComponent(`navigation.playground.TextScreen`, () => TextScreen);
|
43
|
|
- Navigation.registerComponent(`navigation.playground.PushedScreen`, () => PushedScreen);
|
44
|
|
- Navigation.registerComponent('navigation.playground.ContextScreen', () => (props) => (
|
45
|
|
- <TitleContext.Provider value={'Title from Provider'}>
|
|
43
|
+ Navigation.registerComponent('navigation.playground.PushedScreen', () => PushedScreen);
|
|
44
|
+ Navigation.registerComponent('navigation.playground.ContextScreen',() => (props) =>
|
|
45
|
+ <ContextProvider>
|
46
|
46
|
<ContextScreen {...props} />
|
47
|
|
- </TitleContext.Provider>
|
48
|
|
- ), () => ContextScreen);
|
|
47
|
+ </ContextProvider>,
|
|
48
|
+ () => ContextScreen);
|
49
|
49
|
Navigation.registerComponent(`navigation.playground.OptionsScreen`, () => OptionsScreen);
|
50
|
50
|
Navigation.registerComponent(`navigation.playground.OrientationSelectScreen`, () => OrientationSelectScreen);
|
51
|
51
|
Navigation.registerComponent(`navigation.playground.OrientationDetectScreen`, () => OrientationDetectScreen);
|