|
@@ -7,8 +7,10 @@ import {Navigation} from 'react-native-navigation';
|
7
|
7
|
import {registerScreens} from './screens';
|
8
|
8
|
registerScreens();
|
9
|
9
|
|
|
10
|
+const SHOW_SHARED_ELEMENT_SCREENS = false;
|
|
11
|
+
|
10
|
12
|
const createTabs = () => {
|
11
|
|
- let tabs = [
|
|
13
|
+ const sharedElementScreens = [
|
12
|
14
|
{
|
13
|
15
|
label: 'Card',
|
14
|
16
|
screen: 'example.CardScreen',
|
|
@@ -20,7 +22,10 @@ const createTabs = () => {
|
20
|
22
|
screen: 'example.ListScreen',
|
21
|
23
|
icon: require('../img/list.png'),
|
22
|
24
|
title: 'Shared Element Transition'
|
23
|
|
- },
|
|
25
|
+ }
|
|
26
|
+ ];
|
|
27
|
+
|
|
28
|
+ let tabs = [
|
24
|
29
|
{
|
25
|
30
|
label: 'One',
|
26
|
31
|
screen: 'example.FirstTabScreen',
|
|
@@ -46,6 +51,9 @@ const createTabs = () => {
|
46
|
51
|
icon: require('../img/one.png'),
|
47
|
52
|
title: 'Collapsing',
|
48
|
53
|
});
|
|
54
|
+ if (SHOW_SHARED_ELEMENT_SCREENS) {
|
|
55
|
+ tabs = [...sharedElementScreens, ...tabs];
|
|
56
|
+ }
|
49
|
57
|
}
|
50
|
58
|
return tabs;
|
51
|
59
|
};
|