react-native-navigation 99.99.9 → 999.999.1-test

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (68) hide show
  1. package/CHANGELOG.md +1854 -1
  2. package/lib/Mock/Components/ComponentScreen.tsx +15 -29
  3. package/lib/Mock/Components/LayoutComponent.tsx +2 -2
  4. package/lib/Mock/index.js +2 -2
  5. package/lib/android/app/build.gradle +0 -1
  6. package/lib/android/app/src/main/java/com/reactnativenavigation/NavigationApplication.java +4 -20
  7. package/lib/android/app/src/main/java/com/reactnativenavigation/options/ValueAnimationOptions.kt +3 -3
  8. package/lib/android/app/src/main/java/com/reactnativenavigation/react/ReactView.java +3 -3
  9. package/lib/android/app/src/main/java/com/reactnativenavigation/react/modal/ModalHostLayout.kt +1 -1
  10. package/lib/android/app/src/main/java/com/reactnativenavigation/utils/ReactTypefaceUtils.java +2 -3
  11. package/lib/android/app/src/main/java/com/reactnativenavigation/utils/ReactViewGroup.kt +2 -4
  12. package/lib/android/app/src/main/java/com/reactnativenavigation/utils/SystemUiUtils.kt +10 -16
  13. package/lib/android/app/src/main/java/com/reactnativenavigation/utils/ViewUtils.java +4 -6
  14. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/bottomtabs/BottomTabsAnimator.kt +2 -2
  15. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/child/ChildController.java +14 -7
  16. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/component/ComponentViewController.java +13 -37
  17. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/StackController.java +11 -24
  18. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/StackPresenter.java +10 -13
  19. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/topbar/{TopBarAppearanceAnimator.kt → TopBarAnimator.kt} +2 -4
  20. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/topbar/TopBarCollapseBehavior.kt +1 -1
  21. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/topbar/TopBarController.kt +27 -122
  22. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/viewcontroller/LayoutDirectionApplier.kt +4 -8
  23. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/viewcontroller/Presenter.java +6 -79
  24. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/viewcontroller/RootPresenter.java +1 -1
  25. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/viewcontroller/ViewController.java +0 -5
  26. package/lib/android/app/src/main/java/com/reactnativenavigation/views/animations/{BaseViewAppearanceAnimator.kt → BaseViewAnimator.kt} +4 -4
  27. package/lib/android/app/src/main/java/com/reactnativenavigation/views/animations/DefaultViewAnimatorCreator.kt +8 -8
  28. package/lib/android/app/src/main/java/com/reactnativenavigation/views/animations/ViewAnimatorCreator.kt +2 -2
  29. package/lib/android/app/src/main/java/com/reactnativenavigation/views/element/animators/BackgroundColorAnimator.kt +4 -6
  30. package/lib/android/app/src/main/java/com/reactnativenavigation/views/element/animators/BackgroundColorEvaluator.kt +2 -4
  31. package/lib/android/app/src/reactNative71/java/com/reactnativenavigation/react/modal/ModalContentLayout.kt +6 -6
  32. package/lib/dist/Mock/Application.d.ts +6 -4
  33. package/lib/dist/Mock/Components/BottomTabs.d.ts +13 -9
  34. package/lib/dist/Mock/Components/ComponentScreen.d.ts +7 -5
  35. package/lib/dist/Mock/Components/ComponentScreen.js +3 -10
  36. package/lib/dist/Mock/Components/LayoutComponent.d.ts +13 -9
  37. package/lib/dist/Mock/Components/Modals.d.ts +13 -9
  38. package/lib/dist/Mock/Components/NavigationButton.d.ts +15 -11
  39. package/lib/dist/Mock/Components/Overlays.d.ts +13 -9
  40. package/lib/dist/Mock/Components/Stack.d.ts +13 -9
  41. package/lib/dist/Mock/Components/TopBar.d.ts +9 -7
  42. package/lib/dist/Mock/connect.js +1 -2
  43. package/lib/dist/Mock/index.js +2 -2
  44. package/lib/dist/src/adapters/NativeEventsReceiver.js +1 -1
  45. package/lib/dist/src/adapters/TouchablePreview.d.ts +2 -2
  46. package/lib/dist/src/commands/LayoutType.js +1 -1
  47. package/lib/dist/src/commands/OptionsProcessor.js +1 -8
  48. package/lib/dist/src/components/Modal.d.ts +1 -1
  49. package/lib/dist/src/interfaces/CommandName.js +1 -1
  50. package/lib/dist/src/interfaces/Options.d.ts +3 -33
  51. package/lib/dist/src/interfaces/Options.js +2 -2
  52. package/lib/dist/src/types.d.ts +0 -1
  53. package/lib/ios/BottomTabsBasePresenter.m +2 -3
  54. package/lib/ios/RNNAppDelegate.mm +2 -1
  55. package/lib/ios/RNNConvert.h +0 -2
  56. package/lib/ios/RNNConvert.m +0 -4
  57. package/lib/ios/RNNStackPresenter.m +2 -3
  58. package/lib/src/adapters/NativeEventsReceiver.ts +3 -3
  59. package/lib/src/adapters/TouchablePreview.tsx +3 -3
  60. package/lib/src/commands/OptionsProcessor.ts +2 -13
  61. package/lib/src/interfaces/Options.ts +3 -38
  62. package/package.json +31 -37
  63. package/lib/android/app/src/main/java/com/reactnativenavigation/FeatureToggles.kt +0 -60
  64. package/lib/android/app/src/main/java/com/reactnativenavigation/utils/StubAnimationListener.kt +0 -19
  65. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/statusbar/StatusBarController.kt +0 -9
  66. package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/stack/statusbar/StatusBarPresenter.kt +0 -9
  67. package/lib/android/app/src/main/java/com/reactnativenavigation/views/animations/ColorAnimator.kt +0 -22
  68. package/lib/android/app/src/main/java/com/reactnativenavigation/views/animations/ViewBkgColorProperty.kt +0 -17
@@ -4,12 +4,14 @@ export declare const ComponentScreen: {
4
4
  new (props: ComponentProps): {
5
5
  componentDidMount(): void;
6
6
  isVisible(): boolean;
7
- renderTabBar(): React.JSX.Element | null;
8
- render(): React.JSX.Element;
9
- context: unknown;
7
+ renderTabBar(): JSX.Element | null;
8
+ render(): JSX.Element;
9
+ context: any;
10
10
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
11
11
  forceUpdate(callback?: (() => void) | undefined): void;
12
- readonly props: Readonly<ComponentProps>;
12
+ readonly props: Readonly<ComponentProps> & Readonly<{
13
+ children?: React.ReactNode;
14
+ }>;
13
15
  state: Readonly<{}>;
14
16
  refs: {
15
17
  [key: string]: React.ReactInstance;
@@ -26,5 +28,5 @@ export declare const ComponentScreen: {
26
28
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
27
29
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
28
30
  };
29
- contextType?: React.Context<any> | undefined;
31
+ contextType?: React.Context<any>;
30
32
  };
@@ -34,9 +34,7 @@ exports.ComponentScreen = (0, connect_1.connect)(class extends react_1.Component
34
34
  return null;
35
35
  const buttons = bottomTabs.children.map((child, i) => {
36
36
  const bottomTabOptions = child.resolveOptions().bottomTab;
37
- const icon = bottomTabs.selectedIndex === i
38
- ? bottomTabOptions?.selectedIcon
39
- : bottomTabOptions?.icon;
37
+ const icon = bottomTabs.selectedIndex === i ? bottomTabOptions?.selectedIcon : bottomTabOptions?.icon;
40
38
  const iconURI = isURISource(icon) ? icon.uri : undefined;
41
39
  return (react_1.default.createElement(react_native_1.View, { key: `tab-${i}` },
42
40
  react_1.default.createElement(react_native_1.TouchableOpacity, { style: { padding: 10 }, testID: bottomTabOptions?.testID, onPress: () => {
@@ -48,15 +46,10 @@ exports.ComponentScreen = (0, connect_1.connect)(class extends react_1.Component
48
46
  } },
49
47
  react_1.default.createElement(react_native_1.View, { style: { justifyContent: 'center', alignItems: 'center' } },
50
48
  react_1.default.createElement(react_native_1.Text, null, bottomTabOptions?.badge),
51
- iconURI && (react_1.default.createElement(react_native_1.Image, { style: { width: 18, height: 18, marginBottom: 5 }, source: { uri: iconURI } })),
49
+ iconURI && react_1.default.createElement(react_native_1.Image, { style: { width: 18, height: 18, marginBottom: 5 }, source: { uri: iconURI } }),
52
50
  react_1.default.createElement(react_native_1.Text, { style: { fontSize: 12 } }, bottomTabOptions?.text || '')))));
53
51
  });
54
- return (react_1.default.createElement(react_native_1.View, { testID: bottomTabsOptions?.testID, style: {
55
- flexDirection: 'row',
56
- justifyContent: 'center',
57
- width: '100%',
58
- backgroundColor: '#F0F2F5',
59
- } }, buttons));
52
+ return (react_1.default.createElement(react_native_1.View, { testID: bottomTabsOptions?.testID, style: { flexDirection: 'row', justifyContent: 'center', width: '100%', backgroundColor: '#F0F2F5' } }, buttons));
60
53
  }
61
54
  render() {
62
55
  const Component = react_native_navigation_1.Navigation.mock.store.getWrappedComponent(this.props.layoutNode.data.name);
@@ -1,13 +1,15 @@
1
1
  import React from 'react';
2
2
  import { ComponentProps } from '../ComponentProps';
3
3
  export declare const LayoutComponent: {
4
- new (props: ComponentProps): {
5
- render(): React.JSX.Element;
4
+ new (props: Readonly<ComponentProps>): {
5
+ render(): JSX.Element;
6
6
  componentDidCatch(error: Error, errorInfo: React.ErrorInfo): void;
7
- context: unknown;
7
+ context: any;
8
8
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
9
9
  forceUpdate(callback?: (() => void) | undefined): void;
10
- readonly props: Readonly<ComponentProps>;
10
+ readonly props: Readonly<ComponentProps> & Readonly<{
11
+ children?: React.ReactNode;
12
+ }>;
11
13
  state: Readonly<{}>;
12
14
  refs: {
13
15
  [key: string]: React.ReactInstance;
@@ -24,13 +26,15 @@ export declare const LayoutComponent: {
24
26
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
25
27
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
26
28
  };
27
- new (props: ComponentProps, context: any): {
28
- render(): React.JSX.Element;
29
+ new (props: ComponentProps, context?: any): {
30
+ render(): JSX.Element;
29
31
  componentDidCatch(error: Error, errorInfo: React.ErrorInfo): void;
30
- context: unknown;
32
+ context: any;
31
33
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
32
34
  forceUpdate(callback?: (() => void) | undefined): void;
33
- readonly props: Readonly<ComponentProps>;
35
+ readonly props: Readonly<ComponentProps> & Readonly<{
36
+ children?: React.ReactNode;
37
+ }>;
34
38
  state: Readonly<{}>;
35
39
  refs: {
36
40
  [key: string]: React.ReactInstance;
@@ -47,5 +51,5 @@ export declare const LayoutComponent: {
47
51
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
48
52
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
49
53
  };
50
- contextType?: React.Context<any> | undefined;
54
+ contextType?: React.Context<any>;
51
55
  };
@@ -1,12 +1,14 @@
1
1
  import React from 'react';
2
2
  import { ComponentProps } from '../ComponentProps';
3
3
  export declare const Modals: {
4
- new (props: ComponentProps): {
5
- render(): React.JSX.Element;
6
- context: unknown;
4
+ new (props: Readonly<ComponentProps>): {
5
+ render(): JSX.Element;
6
+ context: any;
7
7
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
8
8
  forceUpdate(callback?: (() => void) | undefined): void;
9
- readonly props: Readonly<ComponentProps>;
9
+ readonly props: Readonly<ComponentProps> & Readonly<{
10
+ children?: React.ReactNode;
11
+ }>;
10
12
  state: Readonly<{}>;
11
13
  refs: {
12
14
  [key: string]: React.ReactInstance;
@@ -24,12 +26,14 @@ export declare const Modals: {
24
26
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
25
27
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
26
28
  };
27
- new (props: ComponentProps, context: any): {
28
- render(): React.JSX.Element;
29
- context: unknown;
29
+ new (props: ComponentProps, context?: any): {
30
+ render(): JSX.Element;
31
+ context: any;
30
32
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
31
33
  forceUpdate(callback?: (() => void) | undefined): void;
32
- readonly props: Readonly<ComponentProps>;
34
+ readonly props: Readonly<ComponentProps> & Readonly<{
35
+ children?: React.ReactNode;
36
+ }>;
33
37
  state: Readonly<{}>;
34
38
  refs: {
35
39
  [key: string]: React.ReactInstance;
@@ -47,5 +51,5 @@ export declare const Modals: {
47
51
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
48
52
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
49
53
  };
50
- contextType?: React.Context<any> | undefined;
54
+ contextType?: React.Context<any>;
51
55
  };
@@ -5,15 +5,17 @@ interface ButtonProps {
5
5
  componentId: string;
6
6
  }
7
7
  export declare const NavigationButton: {
8
- new (props: ButtonProps): {
8
+ new (props: Readonly<ButtonProps>): {
9
9
  ref: undefined;
10
- render(): React.JSX.Element;
11
- renderButtonComponent(): React.JSX.Element;
10
+ render(): JSX.Element;
11
+ renderButtonComponent(): JSX.Element;
12
12
  invokeOnClick(stateNode: any): void;
13
- context: unknown;
13
+ context: any;
14
14
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ButtonProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
15
15
  forceUpdate(callback?: (() => void) | undefined): void;
16
- readonly props: Readonly<ButtonProps>;
16
+ readonly props: Readonly<ButtonProps> & Readonly<{
17
+ children?: React.ReactNode;
18
+ }>;
17
19
  state: Readonly<{}>;
18
20
  refs: {
19
21
  [key: string]: React.ReactInstance;
@@ -31,15 +33,17 @@ export declare const NavigationButton: {
31
33
  componentWillUpdate?(nextProps: Readonly<ButtonProps>, nextState: Readonly<{}>, nextContext: any): void;
32
34
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ButtonProps>, nextState: Readonly<{}>, nextContext: any): void;
33
35
  };
34
- new (props: ButtonProps, context: any): {
36
+ new (props: ButtonProps, context?: any): {
35
37
  ref: undefined;
36
- render(): React.JSX.Element;
37
- renderButtonComponent(): React.JSX.Element;
38
+ render(): JSX.Element;
39
+ renderButtonComponent(): JSX.Element;
38
40
  invokeOnClick(stateNode: any): void;
39
- context: unknown;
41
+ context: any;
40
42
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ButtonProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
41
43
  forceUpdate(callback?: (() => void) | undefined): void;
42
- readonly props: Readonly<ButtonProps>;
44
+ readonly props: Readonly<ButtonProps> & Readonly<{
45
+ children?: React.ReactNode;
46
+ }>;
43
47
  state: Readonly<{}>;
44
48
  refs: {
45
49
  [key: string]: React.ReactInstance;
@@ -57,6 +61,6 @@ export declare const NavigationButton: {
57
61
  componentWillUpdate?(nextProps: Readonly<ButtonProps>, nextState: Readonly<{}>, nextContext: any): void;
58
62
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ButtonProps>, nextState: Readonly<{}>, nextContext: any): void;
59
63
  };
60
- contextType?: React.Context<any> | undefined;
64
+ contextType?: React.Context<any>;
61
65
  };
62
66
  export {};
@@ -1,12 +1,14 @@
1
1
  import React from 'react';
2
2
  import { ComponentProps } from '../ComponentProps';
3
3
  export declare const Overlays: {
4
- new (props: ComponentProps): {
5
- render(): React.JSX.Element;
6
- context: unknown;
4
+ new (props: Readonly<ComponentProps>): {
5
+ render(): JSX.Element;
6
+ context: any;
7
7
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
8
8
  forceUpdate(callback?: (() => void) | undefined): void;
9
- readonly props: Readonly<ComponentProps>;
9
+ readonly props: Readonly<ComponentProps> & Readonly<{
10
+ children?: React.ReactNode;
11
+ }>;
10
12
  state: Readonly<{}>;
11
13
  refs: {
12
14
  [key: string]: React.ReactInstance;
@@ -24,12 +26,14 @@ export declare const Overlays: {
24
26
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
25
27
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
26
28
  };
27
- new (props: ComponentProps, context: any): {
28
- render(): React.JSX.Element;
29
- context: unknown;
29
+ new (props: ComponentProps, context?: any): {
30
+ render(): JSX.Element;
31
+ context: any;
30
32
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
31
33
  forceUpdate(callback?: (() => void) | undefined): void;
32
- readonly props: Readonly<ComponentProps>;
34
+ readonly props: Readonly<ComponentProps> & Readonly<{
35
+ children?: React.ReactNode;
36
+ }>;
33
37
  state: Readonly<{}>;
34
38
  refs: {
35
39
  [key: string]: React.ReactInstance;
@@ -47,5 +51,5 @@ export declare const Overlays: {
47
51
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
48
52
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
49
53
  };
50
- contextType?: React.Context<any> | undefined;
54
+ contextType?: React.Context<any>;
51
55
  };
@@ -1,12 +1,14 @@
1
1
  import React from 'react';
2
2
  import { ComponentProps } from '../ComponentProps';
3
3
  export declare const Stack: {
4
- new (props: ComponentProps): {
5
- render(): React.JSX.Element[];
6
- context: unknown;
4
+ new (props: Readonly<ComponentProps>): {
5
+ render(): JSX.Element[];
6
+ context: any;
7
7
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
8
8
  forceUpdate(callback?: (() => void) | undefined): void;
9
- readonly props: Readonly<ComponentProps>;
9
+ readonly props: Readonly<ComponentProps> & Readonly<{
10
+ children?: React.ReactNode;
11
+ }>;
10
12
  state: Readonly<{}>;
11
13
  refs: {
12
14
  [key: string]: React.ReactInstance;
@@ -24,12 +26,14 @@ export declare const Stack: {
24
26
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
25
27
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
26
28
  };
27
- new (props: ComponentProps, context: any): {
28
- render(): React.JSX.Element[];
29
- context: unknown;
29
+ new (props: ComponentProps, context?: any): {
30
+ render(): JSX.Element[];
31
+ context: any;
30
32
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<ComponentProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
31
33
  forceUpdate(callback?: (() => void) | undefined): void;
32
- readonly props: Readonly<ComponentProps>;
34
+ readonly props: Readonly<ComponentProps> & Readonly<{
35
+ children?: React.ReactNode;
36
+ }>;
33
37
  state: Readonly<{}>;
34
38
  refs: {
35
39
  [key: string]: React.ReactInstance;
@@ -47,5 +51,5 @@ export declare const Stack: {
47
51
  componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
48
52
  UNSAFE_componentWillUpdate?(nextProps: Readonly<ComponentProps>, nextState: Readonly<{}>, nextContext: any): void;
49
53
  };
50
- contextType?: React.Context<any> | undefined;
54
+ contextType?: React.Context<any>;
51
55
  };
@@ -8,15 +8,17 @@ export interface TopBarProps {
8
8
  }
9
9
  export declare const TopBar: {
10
10
  new (props: TopBarProps): {
11
- render(): React.JSX.Element | null;
11
+ render(): JSX.Element | null;
12
12
  shouldRenderBackButton(layoutNode: ParentNode): boolean;
13
- renderButtons(buttons?: OptionsTopBarButton[]): React.JSX.Element[];
14
- renderBackButton(): React.JSX.Element;
15
- renderComponent(id: string, name: string, testID?: string): React.JSX.Element;
16
- context: unknown;
13
+ renderButtons(buttons?: OptionsTopBarButton[]): JSX.Element[];
14
+ renderBackButton(): JSX.Element;
15
+ renderComponent(id: string, name: string, testID?: string): JSX.Element;
16
+ context: any;
17
17
  setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: Readonly<TopBarProps>) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
18
18
  forceUpdate(callback?: (() => void) | undefined): void;
19
- readonly props: Readonly<TopBarProps>;
19
+ readonly props: Readonly<TopBarProps> & Readonly<{
20
+ children?: React.ReactNode;
21
+ }>;
20
22
  state: Readonly<{}>;
21
23
  refs: {
22
24
  [key: string]: React.ReactInstance;
@@ -34,5 +36,5 @@ export declare const TopBar: {
34
36
  componentWillUpdate?(nextProps: Readonly<TopBarProps>, nextState: Readonly<{}>, nextContext: any): void;
35
37
  UNSAFE_componentWillUpdate?(nextProps: Readonly<TopBarProps>, nextState: Readonly<{}>, nextContext: any): void;
36
38
  };
37
- contextType?: React.Context<any> | undefined;
39
+ contextType?: React.Context<any>;
38
40
  };
@@ -1,9 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.connect = void 0;
3
+ exports.connect = connect;
4
4
  const remx_1 = require("remx");
5
5
  function connect(component) {
6
6
  // @ts-ignore
7
7
  return (0, remx_1.connect)()(component);
8
8
  }
9
- exports.connect = connect;
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.mockNativeComponents = exports.ApplicationMock = void 0;
3
+ exports.ApplicationMock = void 0;
4
+ exports.mockNativeComponents = mockNativeComponents;
4
5
  const tslib_1 = require("tslib");
5
6
  exports.ApplicationMock = require('./Application').Application;
6
7
  tslib_1.__exportStar(require("./constants"), exports);
@@ -11,4 +12,3 @@ function mockNativeComponents() {
11
12
  const { Navigation } = require('react-native-navigation');
12
13
  Navigation.mockNativeComponents(new NativeCommandsSender(), new NativeEventsReceiver(), new AppRegistryService());
13
14
  }
14
- exports.mockNativeComponents = mockNativeComponents;
@@ -8,7 +8,7 @@ class NativeEventsReceiver {
8
8
  try {
9
9
  this.emitter = new react_native_1.NativeEventEmitter(react_native_1.NativeModules.RNNEventEmitter);
10
10
  }
11
- catch {
11
+ catch (e) {
12
12
  this.emitter = {
13
13
  addListener: () => {
14
14
  return {
@@ -8,7 +8,7 @@ interface GestureResponderEventWithForce extends NativeSyntheticEvent<NativeTouc
8
8
  }
9
9
  export interface Props {
10
10
  children?: React.ReactNode;
11
- touchableComponent?: typeof TouchableHighlight | typeof TouchableOpacity | TouchableNativeFeedback | TouchableWithoutFeedback | React.ReactNode;
11
+ touchableComponent?: TouchableHighlight | TouchableOpacity | TouchableNativeFeedback | TouchableWithoutFeedback | React.ReactNode;
12
12
  onPress?: () => void;
13
13
  onPressIn?: (payload: {
14
14
  reactTag: number | null;
@@ -38,6 +38,6 @@ export declare class TouchablePreview extends React.PureComponent<Props> {
38
38
  onTouchStart: (event: GestureResponderEvent) => void;
39
39
  onTouchMove: (event: GestureResponderEventWithForce) => void;
40
40
  onTouchEnd: () => void;
41
- render(): React.JSX.Element;
41
+ render(): JSX.Element;
42
42
  }
43
43
  export {};
@@ -13,4 +13,4 @@ var LayoutType;
13
13
  LayoutType["TopTabs"] = "TopTabs";
14
14
  LayoutType["ExternalComponent"] = "ExternalComponent";
15
15
  LayoutType["SplitView"] = "SplitView";
16
- })(LayoutType = exports.LayoutType || (exports.LayoutType = {}));
16
+ })(LayoutType || (exports.LayoutType = LayoutType = {}));
@@ -68,7 +68,7 @@ class OptionsProcessor {
68
68
  return path;
69
69
  }
70
70
  processColor(key, value, options) {
71
- if (((0, isEqual_1.default)(key, 'color') || (0, endsWith_1.default)(key, 'Color')) && !(0, isEqual_1.default)(key, 'bkgColor')) {
71
+ if ((0, isEqual_1.default)(key, 'color') || (0, endsWith_1.default)(key, 'Color')) {
72
72
  if (react_native_1.Platform.OS === 'ios')
73
73
  this.processColorIOS(key, value, options);
74
74
  else
@@ -313,13 +313,6 @@ class OptionsProcessor {
313
313
  enter: animation.topBar,
314
314
  };
315
315
  }
316
- if (animation.statusBar &&
317
- !(0, has_1.default)(animation, 'statusBar.enter') &&
318
- !(0, has_1.default)(animation, 'statusBar.exit')) {
319
- parentOptions.push.statusBar = {
320
- enter: animation.statusBar,
321
- };
322
- }
323
316
  if (animation.bottomTabs &&
324
317
  !(0, has_1.default)(animation, 'bottomTabs.enter') &&
325
318
  !(0, has_1.default)(animation, 'bottomTabs.exit')) {
@@ -15,6 +15,6 @@ export declare class Modal extends React.Component<RNNModalProps> {
15
15
  animationType: string;
16
16
  };
17
17
  constructor(props: RNNModalProps);
18
- render(): React.JSX.Element | null;
18
+ render(): JSX.Element | null;
19
19
  private proccessProps;
20
20
  }
@@ -19,4 +19,4 @@ var CommandName;
19
19
  CommandName["DismissOverlay"] = "dismissOverlay";
20
20
  CommandName["DismissAllOverlays"] = "dismissAllOverlays";
21
21
  CommandName["GetLaunchArgs"] = "getLaunchArgs";
22
- })(CommandName = exports.CommandName || (exports.CommandName = {}));
22
+ })(CommandName || (exports.CommandName = CommandName = {}));
@@ -1166,34 +1166,12 @@ export interface IconInsets {
1166
1166
  */
1167
1167
  right?: number;
1168
1168
  }
1169
- export interface ColorAnimationOptions {
1170
- /**
1171
- * Color duration time; Default is as determined by the OS
1172
- */
1173
- duration?: number;
1174
- }
1175
1169
  export interface ViewAnimationOptions extends ScreenAnimationOptions {
1176
1170
  /**
1177
1171
  * ID of the Top Bar we want to animate
1178
1172
  */
1179
1173
  id?: string;
1180
1174
  }
1181
- export interface TopBarAnimationOptions extends ViewAnimationOptions {
1182
- /**
1183
- * Animation of the top-bar's background color, in case the top-bar background color
1184
- * has been explicitly specified.
1185
- *
1186
- * Applicable only in transition of screens with color (non-component) backgrounds.
1187
- */
1188
- bkgColor?: ColorAnimationOptions;
1189
- }
1190
- export interface StatusBarAnimationOptions extends ViewAnimationOptions {
1191
- /**
1192
- * Animation of the status-bar's background color, in case its background color
1193
- * has been explicitly specified.
1194
- */
1195
- bkgColor?: ColorAnimationOptions;
1196
- }
1197
1175
  export interface EnterExitAnimationOptions {
1198
1176
  /**
1199
1177
  * Animate opening component
@@ -1248,17 +1226,9 @@ export interface StackAnimationOptions {
1248
1226
  /**
1249
1227
  * Configure animations for the top bar
1250
1228
  */
1251
- topBar?: TopBarAnimationOptions | {
1252
- enter?: TopBarAnimationOptions;
1253
- exit?: TopBarAnimationOptions;
1254
- };
1255
- /**
1256
- * Configure animations for the status bar (typically aligned
1257
- * with the top-bar's)
1258
- */
1259
- statusBar?: StatusBarAnimationOptions | {
1260
- enter?: StatusBarAnimationOptions;
1261
- exit?: StatusBarAnimationOptions;
1229
+ topBar?: ViewAnimationOptions | {
1230
+ enter?: ViewAnimationOptions;
1231
+ exit?: ViewAnimationOptions;
1262
1232
  };
1263
1233
  /**
1264
1234
  * Configure animations for the bottom tabs
@@ -11,11 +11,11 @@ var OptionsModalPresentationStyle;
11
11
  OptionsModalPresentationStyle["popover"] = "popover";
12
12
  OptionsModalPresentationStyle["fullScreen"] = "fullScreen";
13
13
  OptionsModalPresentationStyle["none"] = "none";
14
- })(OptionsModalPresentationStyle = exports.OptionsModalPresentationStyle || (exports.OptionsModalPresentationStyle = {}));
14
+ })(OptionsModalPresentationStyle || (exports.OptionsModalPresentationStyle = OptionsModalPresentationStyle = {}));
15
15
  var OptionsModalTransitionStyle;
16
16
  (function (OptionsModalTransitionStyle) {
17
17
  OptionsModalTransitionStyle["coverVertical"] = "coverVertical";
18
18
  OptionsModalTransitionStyle["crossDissolve"] = "crossDissolve";
19
19
  OptionsModalTransitionStyle["flipHorizontal"] = "flipHorizontal";
20
20
  OptionsModalTransitionStyle["partialCurl"] = "partialCurl";
21
- })(OptionsModalTransitionStyle = exports.OptionsModalTransitionStyle || (exports.OptionsModalTransitionStyle = {}));
21
+ })(OptionsModalTransitionStyle || (exports.OptionsModalTransitionStyle = OptionsModalTransitionStyle = {}));
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  declare module 'react-lifecycles-compat' {
3
2
  import * as React from 'react';
4
3
  function polyfill(component: React.ComponentClass<any>): void;
@@ -1,6 +1,5 @@
1
1
  #import "BottomTabsBasePresenter.h"
2
2
  #import "RNNBottomTabsController.h"
3
- #import "RNNConvert.h"
4
3
  #import "UIImage+utils.h"
5
4
 
6
5
  @implementation BottomTabsBasePresenter
@@ -30,7 +29,7 @@
30
29
  [self applyBackgroundColor:[withDefault.bottomTabs.backgroundColor withDefault:nil]
31
30
  translucent:[withDefault.bottomTabs.translucent withDefault:NO]];
32
31
  [bottomTabs setTabBarHideShadow:[withDefault.bottomTabs.hideShadow withDefault:NO]];
33
- [bottomTabs setTabBarStyle:[RNNConvert UIBarStyle:[withDefault.bottomTabs.barStyle
32
+ [bottomTabs setTabBarStyle:[RCTConvert UIBarStyle:[withDefault.bottomTabs.barStyle
34
33
  withDefault:@"default"]]];
35
34
  [self applyTabBarBorder:withDefault.bottomTabs];
36
35
  [self applyTabBarShadow:withDefault.bottomTabs.shadow];
@@ -61,7 +60,7 @@
61
60
  }
62
61
 
63
62
  if (mergeOptions.bottomTabs.barStyle.hasValue) {
64
- [bottomTabs setTabBarStyle:[RNNConvert UIBarStyle:mergeOptions.bottomTabs.barStyle.get]];
63
+ [bottomTabs setTabBarStyle:[RCTConvert UIBarStyle:mergeOptions.bottomTabs.barStyle.get]];
65
64
  }
66
65
 
67
66
  if (mergeOptions.bottomTabs.translucent.hasValue) {
@@ -2,7 +2,8 @@
2
2
  #import <ReactNativeNavigation/ReactNativeNavigation.h>
3
3
 
4
4
  #if RCT_NEW_ARCH_ENABLED
5
-
5
+ #import "RCTAppSetupUtils.h"
6
+ #import "RCTLegacyInteropComponents.h"
6
7
  #import <React/CoreModulesPlugins.h>
7
8
  #import <React/RCTCxxBridgeDelegate.h>
8
9
  #import <React/RCTLegacyViewManagerInteropComponentView.h>
@@ -7,6 +7,4 @@
7
7
 
8
8
  + (UIModalTransitionStyle)UIModalTransitionStyle:(id)json;
9
9
 
10
- + (UIBarStyle)UIBarStyle:(id)json;
11
-
12
10
  @end
@@ -32,8 +32,4 @@ RCT_ENUM_CONVERTER(UIModalPresentationStyle, (@{
32
32
  }),
33
33
  UIModalPresentationFullScreen, integerValue)
34
34
 
35
- RCT_ENUM_CONVERTER(UIBarStyle,
36
- (@{@"default" : @(UIBarStyleDefault), @"black" : @(UIBarStyleBlack)}),
37
- UIBarStyleDefault, integerValue)
38
-
39
35
  @end
@@ -1,6 +1,5 @@
1
1
  #import "RNNStackPresenter.h"
2
2
  #import "InteractivePopGestureDelegate.h"
3
- #import "RNNConvert.h"
4
3
  #import "RNNCustomTitleView.h"
5
4
  #import "RNNReactBackgroundView.h"
6
5
  #import "RNNStackController.h"
@@ -69,7 +68,7 @@
69
68
  stack.interactivePopGestureRecognizer.delegate = _interactivePopGestureDelegate;
70
69
 
71
70
  [stack
72
- setBarStyle:[RNNConvert UIBarStyle:[withDefault.topBar.barStyle withDefault:@"default"]]];
71
+ setBarStyle:[RCTConvert UIBarStyle:[withDefault.topBar.barStyle withDefault:@"default"]]];
73
72
  [stack setRootBackgroundImage:[withDefault.rootBackgroundImage withDefault:nil]];
74
73
  [stack setNavigationBarTestId:[withDefault.topBar.testID withDefault:nil]];
75
74
  [stack setNavigationBarVisible:[withDefault.topBar.visible withDefault:YES]
@@ -127,7 +126,7 @@
127
126
  }
128
127
 
129
128
  if (mergeOptions.topBar.barStyle.hasValue) {
130
- [stack setBarStyle:[RNNConvert UIBarStyle:mergeOptions.topBar.barStyle.get]];
129
+ [stack setBarStyle:[RCTConvert UIBarStyle:mergeOptions.topBar.barStyle.get]];
131
130
  }
132
131
 
133
132
  if (mergeOptions.topBar.background.clipToBounds.hasValue) {
@@ -23,14 +23,14 @@ export class NativeEventsReceiver {
23
23
  constructor() {
24
24
  try {
25
25
  this.emitter = new NativeEventEmitter(NativeModules.RNNEventEmitter);
26
- } catch {
27
- this.emitter = {
26
+ } catch (e) {
27
+ this.emitter = ({
28
28
  addListener: () => {
29
29
  return {
30
30
  remove: () => undefined,
31
31
  };
32
32
  },
33
- } as any as NativeEventEmitter;
33
+ } as any) as NativeEventEmitter;
34
34
  }
35
35
  }
36
36
 
@@ -22,8 +22,8 @@ interface GestureResponderEventWithForce extends NativeSyntheticEvent<NativeTouc
22
22
  export interface Props {
23
23
  children?: React.ReactNode;
24
24
  touchableComponent?:
25
- | typeof TouchableHighlight
26
- | typeof TouchableOpacity
25
+ | TouchableHighlight
26
+ | TouchableOpacity
27
27
  | TouchableNativeFeedback
28
28
  | TouchableWithoutFeedback
29
29
  | React.ReactNode;
@@ -121,7 +121,7 @@ export class TouchablePreview extends React.PureComponent<Props> {
121
121
  const Touchable =
122
122
  Platform.OS === 'ios' && touchableComponent instanceof TouchableNativeFeedback
123
123
  ? TouchableWithoutFeedback
124
- : (touchableComponent as React.Component);
124
+ : (touchableComponent as typeof React.Component);
125
125
 
126
126
  // Wrap component with Touchable for handling platform touches
127
127
  // and a single react View for detecting force and timing.