Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Declarative modals on Android #7260

Merged
merged 51 commits into from
Oct 4, 2021
Merged

Declarative modals on Android #7260

merged 51 commits into from
Oct 4, 2021

Conversation

swabbass
Copy link
Contributor

Motivation

We have our own declarative style modals, which can be used like ReactNative modals.
When using ReactNative modals it causes a problematic behaviour since those components are displayed out of our rules (order of modals and overlays), on Android they use Dialog which creates a DecorView on top of all views.

Concept

We are defining a "Host" Component which will be the host of the modal content, and we will build a new component that "hunts" the host children and add them to a native view exported via a ViewManager, calling the internal show, dismiss APIs for modals when changing visible prop.

Demo

Screen.Recording.2021-09-16.at.8.19.48.mov

swabbass and others added 17 commits July 22, 2021 13:52
commit 9a975b4
Author: wixmobile <[email protected]>
Date:   Tue Sep 14 05:26:23 2021 -0400

    Update package.json version to 7.21.0 [ci skip]

commit 0f61d3f
Author: Sergei Butko <[email protected]>
Date:   Tue Sep 14 06:18:01 2021 +0300

    Fix left and right top bar buttons with component crash on Android (#7253)

    * Replace incorrect title bar react button view height measure spec

    * Fix right button with component incorrect ID while measuring its size

    * Add missing View import

    * Update TitleBarReactButtonView.java

    Co-authored-by: Ward Abbass <[email protected]>
    Co-authored-by: Ward Abbass <[email protected]>

commit 7351d0d
Author: Sergei Butko <[email protected]>
Date:   Mon Sep 13 23:08:31 2021 +0300

    Apply back button icon changes to scroll edge appearance (#7257)

commit 396879a
Author: wixmobile <[email protected]>
Date:   Sun Sep 5 07:14:47 2021 -0400

    Update package.json version to 7.20.0 [ci skip]

commit be858f8
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 13:09:30 2021 +0300

    Fix [RNNEnterExitAnimation elementTransitions] crash (#7249)

    Fix a crash caused by #7194 on `[RNNEnterExitAnimation elementTransitions]`.
    This is happening when trying to customize the modal animations.

    ```
    EXCEPTION
    NSInvalidArgumentException
    MESSAGE
    -[RNNEnterExitAnimation elementTransitions]: unrecognized selector sent to instance 0x29d8f8720
    ```

commit 1cd25e6
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 12:45:26 2021 +0300

    Fix color processing on iOS (#7250)

commit 8b4d033
Author: CursedWizard <[email protected]>
Date:   Sun Sep 5 10:55:51 2021 +0200

    docs: updated community libraries. (#7245)

    Couldn't find a ready-to-use solution for a bottom sheet component that would work seamlessly with react-native-navigation, so decided to write my own - [React Native Navigation Bottom Sheet Extension](https://github.com/CursedWizard/react-native-navigation-bottom-sheet). Added it to community libraries in docs.

    Also made the list of packages a little bit more organized.

    Co-authored-by: Yogev Ben David <[email protected]>

commit ba722f8
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 09:47:14 2021 +0300

    Support DynamicColorIOS (#7248)

    * Support DynamicColorIOS

    * Update OptionsProcessor.ts

commit 67b5798
Author: Sergei Butko <[email protected]>
Date:   Fri Sep 3 14:14:17 2021 +0300

    Add popToRoot option to bottomTab on Android (#7244)

commit e19ff8c
Author: Yogev Ben David <[email protected]>
Date:   Thu Sep 2 15:38:03 2021 +0300

    Fix remx optional dependency (#7241)

    Currently, remx is an optional peer dependency that is required for our mock consumers only. But it is actually being imported from our main `index.ts` which break users who don't import it even though they are not using mocks.
    The solution is to change the way users import our mocks and make it explicit.

    Mocks now should be imported from `react-native-navigation/Mock`.

    Co-authored-by: Carl-Gerhard Lindesvärd <[email protected]>

commit bb2b09e
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 14:46:34 2021 +0300

    Pop to root when tapping on active bottom tab on Android (#7239)

    * Pop to root when tapping on active bottom tab

    * Add missing imports

    * Add stack type checking before popping to root

commit 74c09f4
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 14:30:02 2021 +0300

    Add support to change the search bar's cancel button text on iOS (#7240)

    * Add support to change the search bar's cancel button text on iOS

    * Replace incorrectly used test option

commit 8831ccf
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 13:53:18 2021 +0300

    Change bottom tabs height constants value calculation to the dimen-based one (#7238)

    Co-authored-by: Ward Abbass <[email protected]>

commit d48e3d5
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 21:36:45 2021 +0300

    Changing StatusBar when unrelated mergeOptions Fix (#7237)

    # Issue:

    Each time `mergeOptions` is called, even with non `StatusBar` related options, the status bar state will change without taking defaults or static options into consideration.

    # Fix

    Check if options for `StatusBar` are present and then apply them on merge options.

    https://user-images.githubusercontent.com/7227793/131662099-09a91198-2033-4f50-a6f0-a29b70b5c5e5.mov

    Closing: #7232.

commit 537eb08
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 14:34:56 2021 +0300

    Component Lifecycle events fix onPause/onResume (#7235)

    * Add test cases for new issues

    * handle pause/resume in modal stack

    * Delete OverlayManager.java

    * pass pause/resume to modals/overlayes

    - overlays should always get the events since they are on top
    - modals basically covers the whole view behind
    - all other layers can handle events in this order

    * Update OverlayManager.kt

    * Update Navigator.java

    * add tests for overCurrentContext mode

    * add peekDisplayedOverCurrentContext

    * call root when top modal is overCurrentContext

    Co-authored-by: Guy Carmeli <[email protected]>

commit 97dd091
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 12:38:13 2021 +0300

    add studio npm shortcut

commit 3d10758
Author: Ward Abbass <[email protected]>
Date:   Tue Aug 31 11:34:53 2021 +0300

    Status bar updates causes ui freeze on some devices (#7231)

    Modify flags for DecorView in the global main thread handler caused ui to freeze when calling `mergeOptions` inside useEffect.
    This happens on Samsung devices with Android 9, that seems it has issues internally since it is not reproduce on emulator and other devices including Samsungs with new android versions.

    The workaround was to set the flags in a task to run in the DecorView MessageQueue in order to ensure flags are set when the DecorView is ready internally to accept changes.

    Co-authored-by: Yogev Ben David <[email protected]>

commit ec34501
Author: Yogev Ben David <[email protected]>
Date:   Tue Aug 31 10:09:34 2021 +0300

    Avoid calling AppRegistry.registerComponent in mocked mode (#7234)

commit dfdb451
Author: VNDRN <[email protected]>
Date:   Sun Aug 29 15:55:21 2021 +0200

    Update api-events.mdx (#7224)

    When testing the `registerModalAttemptedToDismissListener` event, I noticed that I had to set the `swipeToDismiss` flag to false. The docs currently falsely indicate it should be `true`

commit 1db86ce
Author: Ward Abbass <[email protected]>
Date:   Sun Aug 29 16:01:27 2021 +0300

    PlatformColor Support (#7216)

    Following the discussion here: #6618.

    ## Android
    - Colours are parsed natively.
    - Creating custom colour when a PlatformColor is passed to native.
    - Both light/dark values have the same res attribute resolved when `get` is called.

    ## IOS
    - Added a custom colour.
    - Changed storyboard splash screen.
    - Using `labelColor` as a test.

    CC: @yogevbd
    closes: #6618

    Co-authored-by: Yogev Ben David <[email protected]>

commit 0093684
Author: Yogev Ben David <[email protected]>
Date:   Sun Aug 29 13:27:12 2021 +0300

    Move remx to optional peer dependencies (#7230)

commit e3e7812
Author: wixmobile <[email protected]>
Date:   Mon Aug 23 05:38:37 2021 -0400

    Update package.json version to 7.19.0 [ci skip]
@d4vidi d4vidi closed this Sep 19, 2021
@d4vidi d4vidi reopened this Sep 19, 2021
swabbass and others added 11 commits October 3, 2021 11:59
commit 102b718
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 30 12:59:05 2021 +0300

    Add callback as optional parameter to updateProps (#7277)

    * Add callback as optional parameter to updateProps

    * Add optional callback to NavigationDelegate

    * Add tests to Store and ComponentWrapper

    Co-authored-by: Ward Abbass <[email protected]>

commit 92bbcc1
Author: Jordan Becker <[email protected]>
Date:   Thu Sep 30 10:32:22 2021 +0200

    Fix iOS 15 bars appearance (#7270)

    Following #7266 and especially [my comment there](#7266 (comment)), I'm opening this PR to provide a quick fix to people experiencing issues when building RNN using Xcode 13.

    This should be considered a fix PR rather than a feature PR, as what it's doing is basically duplicating the already set `standardAppearance` to a `scrollEdgeAppearance`. What this means is that the bars will have the same visual aspect whether they're displayed alongside the edge of a scroll view.

    In a future, more elaborate PR, we could imagine a way to be able to provide `scrollEdgeAppearance` values from JS for more control over the native bars.

    Fixes #7266
    Fixes #7268

    Co-authored-by: Yogev Ben David <[email protected]>

commit f87e1ca
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 30 01:06:36 2021 +0300

    Remove default splash layout color on Android (#7276)

    Co-authored-by: Ward Abbass <[email protected]>

commit a207f62
Author: Tom Spencer <[email protected]>
Date:   Wed Sep 29 15:44:15 2021 +0100

    Fix sideMenu docs (#7275)

    Updated the example using `Navigation.mergeOptions` to open the side menu with the correct first argument.
@swabbass swabbass marked this pull request as ready for review October 3, 2021 11:01
When changing state of RNNModal to not visible the props got unbound to native and the dismiss event will not be received in JS, suggested to call dismiss block after calling setState in RequestDismiss.
@@ -7,11 +7,14 @@
import com.facebook.react.bridge.Arguments;
import com.facebook.react.bridge.Promise;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.ReactContext;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should remove


const RNNModalViewManager = requireNativeComponent('RNNModalViewManager');

export class RNNModal extends React.Component<RNNModalProps> {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

renmae to modal

@swabbass swabbass requested a review from yogevbd October 4, 2021 09:17
@swabbass swabbass merged commit 588e908 into master Oct 4, 2021
rahulfancode pushed a commit to ds-fancode/react-native-navigation that referenced this pull request Mar 1, 2023
* tst

* sdfsdf

* bk

* builder

* Update pipeline.yml

* Update pipeline.yml

* Update pipeline.yml

* Update pipeline.yml

* Update pipeline.yml

* Update pipeline.yml

* Move remx to optional peer dependencies (#7230)

* PlatformColor Support (#7216)

Following the discussion here: #6618.

## Android
- Colours are parsed natively.
- Creating custom colour when a PlatformColor is passed to native.
- Both light/dark values have the same res attribute resolved when `get` is called.

## IOS
- Added a custom colour.
- Changed storyboard splash screen.
- Using `labelColor` as a test.


CC: @yogevbd 
closes: #6618

Co-authored-by: Yogev Ben David <[email protected]>

* Update api-events.mdx (#7224)

When testing the `registerModalAttemptedToDismissListener` event, I noticed that I had to set the `swipeToDismiss` flag to false. The docs currently falsely indicate it should be `true`

* reduce sim count

* Update test-e2e.js

* Update pipeline.yml

* Update pipeline.yml

* fix pipe

* Update ApplicationLifecycleTest.test.js

* Avoid calling AppRegistry.registerComponent in mocked mode (#7234)

* Status bar updates causes ui freeze on some devices (#7231)

Modify flags for DecorView in the global main thread handler caused ui to freeze when calling `mergeOptions` inside useEffect.
This happens on Samsung devices with Android 9, that seems it has issues internally since it is not reproduce on emulator and other devices including Samsungs with new android versions.

The workaround was to set the flags in a task to run in the DecorView MessageQueue in order to ensure flags are set when the DecorView is ready internally to accept changes.

Co-authored-by: Yogev Ben David <[email protected]>

* Update pipeline.yml

* Update pipeline.yml

* Update pipeline.yml

* add studio npm shortcut

* Component Lifecycle events fix onPause/onResume (#7235)

* Add test cases for new issues

* handle pause/resume in modal stack

* Delete OverlayManager.java

* pass pause/resume to modals/overlayes

- overlays should always get the events since they are on top
- modals basically covers the whole view behind
- all other layers can handle events in this order

* Update OverlayManager.kt

* Update Navigator.java

* add tests for overCurrentContext mode

* add peekDisplayedOverCurrentContext

* call root when top modal is overCurrentContext

Co-authored-by: Guy Carmeli <[email protected]>

* Changing StatusBar when unrelated mergeOptions Fix (#7237)

# Issue:

Each time `mergeOptions` is called, even with non `StatusBar` related options, the status bar state will change without taking defaults or static options into consideration.

# Fix

Check if options for `StatusBar` are present and then apply them on merge options. 


https://user-images.githubusercontent.com/7227793/131662099-09a91198-2033-4f50-a6f0-a29b70b5c5e5.mov


Closing: #7232.

* Change bottom tabs height constants value calculation to the dimen-based one (#7238)

Co-authored-by: Ward Abbass <[email protected]>

* Add support to change the search bar's cancel button text on iOS (#7240)

* Add support to change the search bar's cancel button text on iOS

* Replace incorrectly used test option

* Pop to root when tapping on active bottom tab on Android (#7239)

* Pop to root when tapping on active bottom tab

* Add missing imports

* Add stack type checking before popping to root

* Fix remx optional dependency (#7241)

Currently, remx is an optional peer dependency that is required for our mock consumers only. But it is actually being imported from our main `index.ts` which break users who don't import it even though they are not using mocks.
The solution is to change the way users import our mocks and make it explicit. 

Mocks now should be imported from `react-native-navigation/Mock`.


Co-authored-by: Carl-Gerhard Lindesvärd <[email protected]>

* Add popToRoot option to bottomTab on Android (#7244)

* Support DynamicColorIOS (#7248)

* Support DynamicColorIOS

* Update OptionsProcessor.ts

* docs: updated community libraries. (#7245)

Couldn't find a ready-to-use solution for a bottom sheet component that would work seamlessly with react-native-navigation, so decided to write my own - [React Native Navigation Bottom Sheet Extension](https://github.com/CursedWizard/react-native-navigation-bottom-sheet). Added it to community libraries in docs.

Also made the list of packages a little bit more organized.

Co-authored-by: Yogev Ben David <[email protected]>

* Fix color processing on iOS (#7250)

* Fix [RNNEnterExitAnimation elementTransitions] crash (#7249)

Fix a crash caused by #7194 on `[RNNEnterExitAnimation elementTransitions]`.
This is happening when trying to customize the modal animations.

```
EXCEPTION
NSInvalidArgumentException
MESSAGE
-[RNNEnterExitAnimation elementTransitions]: unrecognized selector sent to instance 0x29d8f8720
```

* Update package.json version to 7.20.0 [ci skip]

* Apply back button icon changes to scroll edge appearance (#7257)

* Fix left and right top bar buttons with component crash on Android (#7253)

* Replace incorrect title bar react button view height measure spec

* Fix right button with component incorrect ID while measuring its size

* Add missing View import

* Update TitleBarReactButtonView.java

Co-authored-by: Ward Abbass <[email protected]>
Co-authored-by: Ward Abbass <[email protected]>

* Update package.json version to 7.21.0 [ci skip]

* Fix sideMenu docs (#7275)

Updated the example using `Navigation.mergeOptions` to open the side menu with the correct first argument.

* Remove default splash layout color on Android (#7276)

Co-authored-by: Ward Abbass <[email protected]>

* Fix iOS 15 bars appearance (#7270)

Following #7266 and especially [my comment there](https://github.com/wix/react-native-navigation/issues/7266#issuecomment-925706532), I'm opening this PR to provide a quick fix to people experiencing issues when building RNN using Xcode 13.

This should be considered a fix PR rather than a feature PR, as what it's doing is basically duplicating the already set `standardAppearance` to a `scrollEdgeAppearance`. What this means is that the bars will have the same visual aspect whether they're displayed alongside the edge of a scroll view.

In a future, more elaborate PR, we could imagine a way to be able to provide `scrollEdgeAppearance` values from JS for more control over the native bars.

Fixes #7266
Fixes #7268

Co-authored-by: Yogev Ben David <[email protected]>

* Add callback as optional parameter to updateProps (#7277)

* Add callback as optional parameter to updateProps

* Add optional callback to NavigationDelegate

* Add tests to Store and ComponentWrapper

Co-authored-by: Ward Abbass <[email protected]>

* use HMSegmentedControl from pod instead of standalone file (#7279)

https://github.com/HeshamMegid/HMSegmentedControl
is available as a Pod and many libraries and frameworks use it from there. Using them along with ReactNativeNavigation causes duplicate symbols error when building the app. I have updated the library to use the class from pod instead of the standalone files embedded within the library.

* [Android][Accessibility] Prevent overwrite accessibilityLabel of BackButton  (#7282)

* [Android] Prevent overwrite accessibilityLabel of BackButton #7221

* Prevent overwrite topBar.backButton.accessibilityLabel after setDefaultOptions on Android

* Add unit tests

Co-authored-by: Ward Abbass <[email protected]>

* Declarative modals on Android (#7260)

* run modals and test overlays temp

* tmp

* modal component return null when not visible

* temp

* tmp

* use react context instead of activity

* Update DeclaredLayoutHost.kt

* showing modal + dismiss changing visible

* tmpo

* add events

* make children collapsable (native managed)

* Squashed commit of the following:

commit 9a975b4c55776ba3512e50caae1d7861a8feb1a4
Author: wixmobile <[email protected]>
Date:   Tue Sep 14 05:26:23 2021 -0400

    Update package.json version to 7.21.0 [ci skip]

commit 0f61d3ffcd0231785d212f7e4c1202c5bec98f96
Author: Sergei Butko <[email protected]>
Date:   Tue Sep 14 06:18:01 2021 +0300

    Fix left and right top bar buttons with component crash on Android (#7253)

    * Replace incorrect title bar react button view height measure spec

    * Fix right button with component incorrect ID while measuring its size

    * Add missing View import

    * Update TitleBarReactButtonView.java

    Co-authored-by: Ward Abbass <[email protected]>
    Co-authored-by: Ward Abbass <[email protected]>

commit 7351d0dd32170a81c5e5c06a2d253b4985e602f6
Author: Sergei Butko <[email protected]>
Date:   Mon Sep 13 23:08:31 2021 +0300

    Apply back button icon changes to scroll edge appearance (#7257)

commit 396879a655672cc0484e5a2a42c3483ac0a0642b
Author: wixmobile <[email protected]>
Date:   Sun Sep 5 07:14:47 2021 -0400

    Update package.json version to 7.20.0 [ci skip]

commit be858f8db9b49dd8a1761fc5c8453610d9db7c8e
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 13:09:30 2021 +0300

    Fix [RNNEnterExitAnimation elementTransitions] crash (#7249)

    Fix a crash caused by #7194 on `[RNNEnterExitAnimation elementTransitions]`.
    This is happening when trying to customize the modal animations.

    ```
    EXCEPTION
    NSInvalidArgumentException
    MESSAGE
    -[RNNEnterExitAnimation elementTransitions]: unrecognized selector sent to instance 0x29d8f8720
    ```

commit 1cd25e6f694ba0c8bd6bfe2c44ad507dabfff3fb
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 12:45:26 2021 +0300

    Fix color processing on iOS (#7250)

commit 8b4d03322ecda05b68d1ac04a43d3aed07e19a93
Author: CursedWizard <[email protected]>
Date:   Sun Sep 5 10:55:51 2021 +0200

    docs: updated community libraries. (#7245)

    Couldn't find a ready-to-use solution for a bottom sheet component that would work seamlessly with react-native-navigation, so decided to write my own - [React Native Navigation Bottom Sheet Extension](https://github.com/CursedWizard/react-native-navigation-bottom-sheet). Added it to community libraries in docs.

    Also made the list of packages a little bit more organized.

    Co-authored-by: Yogev Ben David <[email protected]>

commit ba722f8c36fb7675f7916c7d8be97e194645ff66
Author: Yogev Ben David <[email protected]>
Date:   Sun Sep 5 09:47:14 2021 +0300

    Support DynamicColorIOS (#7248)

    * Support DynamicColorIOS

    * Update OptionsProcessor.ts

commit 67b5798aa795235576f56c63ef7053247ba0a377
Author: Sergei Butko <[email protected]>
Date:   Fri Sep 3 14:14:17 2021 +0300

    Add popToRoot option to bottomTab on Android (#7244)

commit e19ff8ce7790dbb450e3e2928ff407f8cad24ccc
Author: Yogev Ben David <[email protected]>
Date:   Thu Sep 2 15:38:03 2021 +0300

    Fix remx optional dependency (#7241)

    Currently, remx is an optional peer dependency that is required for our mock consumers only. But it is actually being imported from our main `index.ts` which break users who don't import it even though they are not using mocks.
    The solution is to change the way users import our mocks and make it explicit.

    Mocks now should be imported from `react-native-navigation/Mock`.

    Co-authored-by: Carl-Gerhard Lindesvärd <[email protected]>

commit bb2b09eed05280d83abf1d850a856041c43a6afa
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 14:46:34 2021 +0300

    Pop to root when tapping on active bottom tab on Android (#7239)

    * Pop to root when tapping on active bottom tab

    * Add missing imports

    * Add stack type checking before popping to root

commit 74c09f4f8ea0eb4a234a35dd8e0dc95c5ab98d8b
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 14:30:02 2021 +0300

    Add support to change the search bar's cancel button text on iOS (#7240)

    * Add support to change the search bar's cancel button text on iOS

    * Replace incorrectly used test option

commit 8831ccf1fd7d6b95fed269f88e9a9613b01e0b28
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 2 13:53:18 2021 +0300

    Change bottom tabs height constants value calculation to the dimen-based one (#7238)

    Co-authored-by: Ward Abbass <[email protected]>

commit d48e3d5bfeaa1ef45e837ccee99d6f28e58dc7d1
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 21:36:45 2021 +0300

    Changing StatusBar when unrelated mergeOptions Fix (#7237)

    # Issue:

    Each time `mergeOptions` is called, even with non `StatusBar` related options, the status bar state will change without taking defaults or static options into consideration.

    # Fix

    Check if options for `StatusBar` are present and then apply them on merge options.

    https://user-images.githubusercontent.com/7227793/131662099-09a91198-2033-4f50-a6f0-a29b70b5c5e5.mov

    Closing: #7232.

commit 537eb08c8e2111afeac4c179cd20033fe7cb951e
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 14:34:56 2021 +0300

    Component Lifecycle events fix onPause/onResume (#7235)

    * Add test cases for new issues

    * handle pause/resume in modal stack

    * Delete OverlayManager.java

    * pass pause/resume to modals/overlayes

    - overlays should always get the events since they are on top
    - modals basically covers the whole view behind
    - all other layers can handle events in this order

    * Update OverlayManager.kt

    * Update Navigator.java

    * add tests for overCurrentContext mode

    * add peekDisplayedOverCurrentContext

    * call root when top modal is overCurrentContext

    Co-authored-by: Guy Carmeli <[email protected]>

commit 97dd091cbf9922f060b3764c1dadad1a4ad0f01f
Author: Ward Abbass <[email protected]>
Date:   Wed Sep 1 12:38:13 2021 +0300

    add studio npm shortcut

commit 3d10758d0c6315fddac4317aa1ef646a9c4e6a55
Author: Ward Abbass <[email protected]>
Date:   Tue Aug 31 11:34:53 2021 +0300

    Status bar updates causes ui freeze on some devices (#7231)

    Modify flags for DecorView in the global main thread handler caused ui to freeze when calling `mergeOptions` inside useEffect.
    This happens on Samsung devices with Android 9, that seems it has issues internally since it is not reproduce on emulator and other devices including Samsungs with new android versions.

    The workaround was to set the flags in a task to run in the DecorView MessageQueue in order to ensure flags are set when the DecorView is ready internally to accept changes.

    Co-authored-by: Yogev Ben David <[email protected]>

commit ec34501fb99a6bac070d692e9a36be618874f06c
Author: Yogev Ben David <[email protected]>
Date:   Tue Aug 31 10:09:34 2021 +0300

    Avoid calling AppRegistry.registerComponent in mocked mode (#7234)

commit dfdb451a7d6621d1af24149b02161b44226dd908
Author: VNDRN <[email protected]>
Date:   Sun Aug 29 15:55:21 2021 +0200

    Update api-events.mdx (#7224)

    When testing the `registerModalAttemptedToDismissListener` event, I noticed that I had to set the `swipeToDismiss` flag to false. The docs currently falsely indicate it should be `true`

commit 1db86ce376f677255196aa774c6d6cf4ae58c98b
Author: Ward Abbass <[email protected]>
Date:   Sun Aug 29 16:01:27 2021 +0300

    PlatformColor Support (#7216)

    Following the discussion here: #6618.

    ## Android
    - Colours are parsed natively.
    - Creating custom colour when a PlatformColor is passed to native.
    - Both light/dark values have the same res attribute resolved when `get` is called.

    ## IOS
    - Added a custom colour.
    - Changed storyboard splash screen.
    - Using `labelColor` as a test.

    CC: @yogevbd
    closes: #6618

    Co-authored-by: Yogev Ben David <[email protected]>

commit 00936844c8a21cb9a89272203c29cda5c565c0d3
Author: Yogev Ben David <[email protected]>
Date:   Sun Aug 29 13:27:12 2021 +0300

    Move remx to optional peer dependencies (#7230)

commit e3e7812b3169a460aa2f928a07d69a01c4a79ae0
Author: wixmobile <[email protected]>
Date:   Mon Aug 23 05:38:37 2021 -0400

    Update package.json version to 7.19.0 [ci skip]

* Rename and Refactor Declared to Modal

* Update NavigationReactInitializer.java

* Update ReactGateway.java

* Update NavigationReactInitializer.java

* Update NavigationReactInitializer.java

* Update CoordinatorLayoutUtils.java

* Update ModalStack.java

* Update ModalStack.java

* Update ModalStack.java

* Update Navigator.java

* Update TouchablePreview.tsx

* Update LayoutsScreen.tsx

* Update testIDs.ts

* Update TouchablePreview.tsx

* Update ModalScreen.tsx

* Update ModalScreen.tsx

* Update testIDs.ts

* add more e2e tests

* Update NavigationActivity.java

* fix tests

* Update build.gradle

* Squashed commit of the following:

commit 102b7184fc0cf1a1dfd177a8766cc463a72dfeb5
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 30 12:59:05 2021 +0300

    Add callback as optional parameter to updateProps (#7277)

    * Add callback as optional parameter to updateProps

    * Add optional callback to NavigationDelegate

    * Add tests to Store and ComponentWrapper

    Co-authored-by: Ward Abbass <[email protected]>

commit 92bbcc17c50d079617d2b8a03e8682faffd278aa
Author: Jordan Becker <[email protected]>
Date:   Thu Sep 30 10:32:22 2021 +0200

    Fix iOS 15 bars appearance (#7270)

    Following #7266 and especially [my comment there](https://github.com/wix/react-native-navigation/issues/7266#issuecomment-925706532), I'm opening this PR to provide a quick fix to people experiencing issues when building RNN using Xcode 13.

    This should be considered a fix PR rather than a feature PR, as what it's doing is basically duplicating the already set `standardAppearance` to a `scrollEdgeAppearance`. What this means is that the bars will have the same visual aspect whether they're displayed alongside the edge of a scroll view.

    In a future, more elaborate PR, we could imagine a way to be able to provide `scrollEdgeAppearance` values from JS for more control over the native bars.

    Fixes #7266
    Fixes #7268

    Co-authored-by: Yogev Ben David <[email protected]>

commit f87e1ca6b34e0942ee0826e72d25efd0c45edc55
Author: Sergei Butko <[email protected]>
Date:   Thu Sep 30 01:06:36 2021 +0300

    Remove default splash layout color on Android (#7276)

    Co-authored-by: Ward Abbass <[email protected]>

commit a207f62db83a496c7648c6bb66869946ad3bb545
Author: Tom Spencer <[email protected]>
Date:   Wed Sep 29 15:44:15 2021 +0100

    Fix sideMenu docs (#7275)

    Updated the example using `Navigation.mergeOptions` to open the side menu with the correct first argument.

* revert local changes

* remove unused event

When changing state of RNNModal to not visible the props got unbound to native and the dismiss event will not be received in JS, suggested to call dismiss block after calling setState in RequestDismiss.

* add missing props

* Update ModalViewManager.kt

* rename

* rename

* Update ModalLayoutController.kt

* Update NavigationModule.java

* update docs

* Fix empty dynamic colors object when using PlatformColors on iOS (#7259)

Fixes the original error mentioned here: https://github.com/wix/react-native-navigation/pull/7216#issuecomment-918975922

Co-authored-by: Ward Abbass <[email protected]>

* Fix dot indicator location on iOS (#7274)

- Fixes #6411 
- Fixes the crash if `dotIndicator` is applied without `icon` in tab

<img width="502" alt="image" src="https://user-images.githubusercontent.com/14828004/135261158-eec0d640-9220-4e1c-bbd1-46939b7b54de.png">

* Add SF Symbols support to bottom tab and top bar's back button (#7271)

Since SF Symbols are built in starting from iOS 13 it makes sense to use them as icons rather than creating PNGs which will increase app size.

<img width="502" alt="image" src="https://user-images.githubusercontent.com/14828004/134523928-2a5d19ff-a42a-445e-abf7-d4d64d222025.png">

<img width="502" alt="image" src="https://user-images.githubusercontent.com/14828004/134523961-24a521b1-bb69-43c6-9324-c91b64a4342c.png">


Co-authored-by: Yogev Ben David <[email protected]>
Co-authored-by: Ward Abbass <[email protected]>

* Fix Android project warnings (#7288)

* Rename o to others to fix problems when calling this function with named arguments

* Suppress unused parameters of TopBarAnimator

* Suppress unchecked cast of PropertyAnimatorCreator

* Remove unused import from ReactImageBoundsAnimator

* Remove redundant SAM-constructor

* Remove unused imports

* Remove unused imports

* Remove unused constant

* Fix raw use of ViewController

* Fix raw use of ViewController

* Fix raw use of ViewController

* Fix raw use of ViewController, remove unused imports

* Remove unused import

* Fix raw use of ViewController

* Fix raw use of ViewController

* Fix raw use of ViewController

* Fix raw use of ViewController

* Remove unused import

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Remove wrong return type condition

* Remove unused import

* Remove unused import

* Remove unused import

* Remove redundant semicolon

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use

* Fix raw ViewController use, remove unused imports

* Remove unused import

* Return TypeEvaluator

* Use View from React Native (#7286)

* Fix nullable dispatcher (#7287)

Co-authored-by: Ward Abbass <[email protected]>

* Update package.json version to 7.22.1 [ci skip]

* Remove hack

Now it does not cause infinite measurements

* Fix Null activity when having initial modal at startup (#7292)

* pass ReactContext instead of activity's navigator

It seems that ReactNative can call createViewManagers in a point that current activity is null, which can lean to null exception

* Use reactContext and navigator on demand

Since Navigator is bound to activity, which is the right thing to do since it's the UI component to do ui stuff not application, navigator will be determined on demand from the current activity checking for nulls and valid lifecycle state

* Update ModalViewManager.kt

* Update ModalViewManager.kt

* Fix documentation build in CI (#7293)

* Fix hardware back button event button id in docs (#7294)

Actual buttonId for hardware back button event is `RNN.hardwareBackButton`, not `RNN.hardwareBack` :-)

* Fix documentation build (#7296)

* Build docusaurus before releasing to npm

* Fix documentation build

* documentation build - npm install before creating docs

* Update package.json version to 7.22.3 [ci skip]

* Expose the testID to black-box testing frameworks on Android (#7298)

* Fix JS tests (#7297)

* Fix JS tests

* Fix tests

* Avoid processing undefined colors (#7310)

When passing undefined colors, we don't want to parse that as Null as it will reset the current visible colors.

* Update package.json version to 7.23.0 [ci skip]

* Small typo fix (#7308)

Adds a "to" in the sentence.

* Update style-statusbar.mdx

* Revert "Remove hack" (#7314)

This reverts commit ef60d316c1fc18f9ee48254704ce7cf2c2fc7777.

* Update package.json version to 7.23.1 [ci skip]

* Add react-native-template-strong to starter kits (#7309)



Co-authored-by: Ward Abbass <[email protected]>

* Add SF Symbols support to left/right top bar buttons (#7318)

![image](https://user-images.githubusercontent.com/14828004/137584651-49043bc7-4180-45d3-9917-f62352fbb7ad.png)

* Add custom component to TopBar when setting it in root on iOS (#7303)

Fixes: https://github.com/wix/react-native-navigation/issues/7301

Co-authored-by: Yogev Ben David <[email protected]>

* hello buildkite (#7326)

* fix merge options mock (#7323)

* Update LayoutStore.ts

* Update LayoutStore.ts

* Update LayoutStore.ts

Co-authored-by: Yogev Ben David <[email protected]>

* iOS Split (#7328)

* Update Detox to support iOS 15 (#7324)

Based to this discussion: https://github.com/wix/Detox/issues/2895#issuecomment-948440467
This version should fix issues with iOS 15

Co-authored-by: Yogev Ben David <[email protected]>
Co-authored-by: Yogev Ben David <[email protected]>

* Allow iOS Unit phase on any agent

* Keyboard demo playground  (#7331)

Adding a simple demo that can be used to demonstrate Keyboard show/dismiss when showing/dismissing modal when clicking on submit

Co-authored-by: Yogev Ben David <[email protected]>

* MergeOptions, buttons got cleared when animation enabled [Android] (#7330)

# Issue:
When having `animateLeftButtons` or `animateRightButtons` enabled, calling `mergeOptions` frequently to update button state like enabled, colour and text etc, caused the menu animation to mess out the views inside the menu.

# Diagnoses:

- Calling `mergeOptions` inside `componentDidUpdate`, which can be called frequently without any options changes deducted from props like calling setState for example or changing a prop that does not have something to do the merge options call.
- Every `mergeOptions` with buttons in it, would remove and re-add buttons to the toolbars which caused the animation to run, even if the change was updating button colour or enabled state.

# Fix:

- Introduce a more efficient way to detect updates and update each button in case there are no structural changes.
- Structural changes can be: reordering, removing, adding buttons or changing buttons with the same `button.id` but a different component with no stable `componentId`.
- Other changes mentioned above will call update buttons in place with no remove and re-add and no animation.
- Refactor the code and enhance single responsibilities for each controller.
- Added more test cases for such flows.

Note:

Android built-in menu, has its limits in terms of updating and rearranging action views inside it, it would be possible if we built a custom menu with an overflow that can support, order changes, and in-place updates, and that is a long road to walk.


Co-authored-by: Yogev Ben David <[email protected]>

* Fix missing props after setRoot for components with identical predefined id (#7329)

* Destroy buttons along with the main react view

* Revert "Destroy buttons along with the main react view"

This reverts commit 27e604db1686a12bfec737a657ad5c033857a887.

* Add pending props

* Fix android button components cache

Co-authored-by: Ward Abbass <[email protected]>
Co-authored-by: Ward Abbass <[email protected]>

* Remove manually dismissing all modals on setRoot (#7340)

Currently we manually dismiss all modals on `setRoot`, we should instead clear it from the modal manager so that those controllers will be automatically released by the reference count system.

* Android context crash when parsing options (#7342)

# Issue:

When parsing options, `ReactInstanceManager.getCurrentContext()` might return null, which caused color parsing to throw null exception since it assumes that context is not null.

# Diagnose:

This can be the case when Activity was killed but the Application still alive (Don't keep activity for example), and since js is bound to the Application lifecycle, opening the activity triggers recreating context in bg, in the meantime calling a command that requires reactContext can cause such crashes to unwanted behaviours when react context is needed.
This happens internally and it looks like it is some flow where calling navigation command when react is not ready. 

# Fix:
 
Since the issue did not happen before, and the crash occurred in parsing options that are independent of `ReactContext`, we can use Activity or Application as the context for such a case.

* React Native 66 (#7305)

* RN 65

React Native upgrade + babel unit tests running as expected

* RN66

- Normal unit tests working
- Upgrade to RN66.
- Move jest to jest config file.
- Use babel-test transformer to make unit tests working
- e2e tests that can run as unit wont work.

* disable running e2es as units

* use Hermes + Fix Reanimated

* update reanimated and use babel plugin

* Enable coverage

* Upgrade jest and babel to 27

* enable JS e2e add animatable to transform ignore

* use babel jest as transformer instead of the react native one

* update android to 30

* Fix overlay insets and use non deprecated methods

* Kotlin convert

* tmp status

* Update Detox to support iOS 15

* Fix e2e

* Revert "tmp status"

This reverts commit aff2b87bf8837f18abdf1164e415342c1376c04a.

* prevent ReactRootViews from having ids

* status bar utils static fields

* Squashed commit of the following:

commit 59596385b86af1b39417c14425af488b09250bf6
Author: Ward Abbass <[email protected]>
Date:   Wed Oct 27 13:04:00 2021 +0300

    Keyboard demo playground  (#7331)

    Adding a simple demo that can be used to demonstrate Keyboard show/dismiss when showing/dismissing modal when clicking on submit

    Co-authored-by: Yogev Ben David <[email protected]>

* wait for stack/modal to be shown to send didAppear

this happens since RN 64

* Fix tests

* Ensure modal is not already presented

* use 0.66.2

Co-authored-by: svbutko <[email protected]>
Co-authored-by: Yogev Ben David <[email protected]>

* Fix default font handling on android (#7333)

* Pass null font family into typeface loader if not set

ReactTypefaceUtils handles null font families to fall back to the default typeface

* Provide the default typeface when calling typeface loader

* Feed paint typeface as default typeface into typeface loader to support default fonts

* Support default font face via AHTextView in bottom tabs

* Move defaultTypeFace to typeFace loader

Co-authored-by: Ward Abbass <[email protected]>

* Fix Android unit tests (#7345)

- Mock default typeface.
- fix buttons adding and removing tests.

Co-authored-by: Yogev Ben David <[email protected]>

* Fix missing curly bracket leftButtons (#7347)

adding curly bracket leftButtons

* Update package.json (#7351)

* destroyAllOverlays crash [Android] (#7354)

* fix units tests

* prevent modifying overlays map while iterating

* fix units

* add enable/disable option to side menu (#7364)

* Timeout (#7356)

Buildkite right now don't have a convenient way to set a global timeout for whole build, so need to set it for every step separately.

* remove merge chance shield (#7325)

Merge chance is going to be deprecated soon.

Co-authored-by: Yogev Ben David <[email protected]>

* [Navigation Mock] Fix bottomTabPressed event (#7368)

* Fix dismissing modals with sideMenu (#7369)

Dismissing a modal that has a `sideMenu` layout exposed a bug we have where we look for the component in the top ViewController presented children, with `sideMenu` it's not enough because its children are not components. 
Instead, We should recursively look for that component in all of the top viewController children tree.

Closes #7367

* Fix fast refresh crash (#7371)

Closes #6176

* Update documentation (#7373)

* Fix statusBar blur option in dark mode (#7372)

* Fix missing options processing (#7370)

We missed `mergeOptions` processing on the following commands: `pop`, `popTo`, `popToRoot`, `dismissModal` and `dismissAllModals`. That resulted in a bug where using the old animations syntax didn't work.

* Fix playground reanimated animations (#7375)

* Upgrade Android unit tests tools (#7379)

* tmp

* Upgrade unit tests dependencies on android

* Android API 30 fixes (#7343)

Upgrading android target SDK to 30, to support android 12 changes.

- Refactor StatusBarUtil to SystemUIUtils to include status and navigation bars.
- Migrate deprecated code using flags to a modern one.
- Calculating WindowInsets per component where all views are laid as full screen.
- Keyboard enhancements to show hide keyboard.
- Fix applying Options of a child taking parent Options into consideration.
- Fix fixed status bar height and use a more elegant way.
- Add more tests for SystemUiUtils.
- Add a SystemUi screen to demonstrate system UI capabilities.
- Migrate Reanimated usage to support Reanimated 2.

Closes #7339.
Closes #7225.
Closes #7358.
Closes #7199.
Closes #7171.
Closes #7111.
Closes #6988.
Closes #4258.
Closes #7360.

Demo:

https://user-images.githubusercontent.com/7227793/142203865-d65b6910-21f8-4617-812e-b5576a6b58e4.mov





Co-authored-by: Ward Abbass <[email protected]>
Co-authored-by: Yogev Ben David <[email protected]>
Co-authored-by: svbutko <[email protected]>
Co-authored-by: Ward Abbass <[email protected]>

* Fix More tab appearance on iOS (#7378)

* Bottom tabs selection stack (HW button Android) (#7380)

* Bottom tabs test to kt

* implement flows of tab selection

* Update BottomTabsControllerTest.kt

* Squashed commit of the following:

commit 3368cda45b92361f398c916c7376e82699bc4382
Author: Ward Abbass <[email protected]>
Date:   Mon Nov 29 09:56:50 2021 +0200

    Upgrade unit tests dependencies on android

commit 7fe8421ee6536fe1e7b774c0059e56296a19cc32
Author: Ward Abbass <[email protected]>
Date:   Mon Nov 29 09:20:55 2021 +0200

    tmp

commit bcf0edb15b81d7d4f809c6902eda478cb31bdcee
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 13:32:27 2021 +0200

    Fix playground reanimated animations (#7375)

commit 623c2393fcbc1dfd9b55a014ca023ffe5ad88bed
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:37:42 2021 +0200

    Fix missing options processing (#7370)

    We missed `mergeOptions` processing on the following commands: `pop`, `popTo`, `popToRoot`, `dismissModal` and `dismissAllModals`. That resulted in a bug where using the old animations syntax didn't work.

commit e0da767c9170caf7d993626747eac5d909cdb9cd
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:37:13 2021 +0200

    Fix statusBar blur option in dark mode (#7372)

commit 74beb279efddf76507b7d1159463aee32337d769
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:36:56 2021 +0200

    Update documentation (#7373)

commit 6452157cef9c62faa2cae4d053e850ddf1d1616e
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 23:20:11 2021 +0200

    Fix fast refresh crash (#7371)

    Closes #6176

commit 709ddb8a5c0ee15fb55efba9b446240d6770f736
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 21:37:22 2021 +0200

    Fix dismissing modals with sideMenu (#7369)

    Dismissing a modal that has a `sideMenu` layout exposed a bug we have where we look for the component in the top ViewController presented children, with `sideMenu` it's not enough because its children are not components.
    Instead, We should recursively look for that component in all of the top viewController children tree.

    Closes #7367

commit 5cc967bf54831eee3eb42a1cb8ed89a6cfbe581d
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 15:26:08 2021 +0200

    [Navigation Mock] Fix bottomTabPressed event (#7368)

* add e2e

* add js option

* add more testing

* docs

* Squashed commit of the following:

commit 29ac5e486dc5f14a280599c45eb0ab6d35155d7e
Author: Ward Abbass <[email protected]>
Date:   Mon Nov 29 10:40:14 2021 +0200

    Upgrade Android unit tests tools (#7379)

    * tmp

    * Upgrade unit tests dependencies on android

commit bcf0edb15b81d7d4f809c6902eda478cb31bdcee
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 13:32:27 2021 +0200

    Fix playground reanimated animations (#7375)

commit 623c2393fcbc1dfd9b55a014ca023ffe5ad88bed
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:37:42 2021 +0200

    Fix missing options processing (#7370)

    We missed `mergeOptions` processing on the following commands: `pop`, `popTo`, `popToRoot`, `dismissModal` and `dismissAllModals`. That resulted in a bug where using the old animations syntax didn't work.

commit e0da767c9170caf7d993626747eac5d909cdb9cd
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:37:13 2021 +0200

    Fix statusBar blur option in dark mode (#7372)

commit 74beb279efddf76507b7d1159463aee32337d769
Author: Yogev Ben David <[email protected]>
Date:   Thu Nov 25 11:36:56 2021 +0200

    Update documentation (#7373)

commit 6452157cef9c62faa2cae4d053e850ddf1d1616e
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 23:20:11 2021 +0200

    Fix fast refresh crash (#7371)

    Closes #6176

commit 709ddb8a5c0ee15fb55efba9b446240d6770f736
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 21:37:22 2021 +0200

    Fix dismissing modals with sideMenu (#7369)

    Dismissing a modal that has a `sideMenu` layout exposed a bug we have where we look for the component in the top ViewController presented children, with `sideMenu` it's not enough because its children are not components.
    Instead, We should recursively look for that component in all of the top viewController children tree.

    Closes #7367

commit 5cc967bf54831eee3eb42a1cb8ed89a6cfbe581d
Author: Yogev Ben David <[email protected]>
Date:   Wed Nov 24 15:26:08 2021 +0200

    [Navigation Mock] Fix bottomTabPressed event (#7368)

* Update BottomTabs.test.js

* Update BottomTabs.test.js

* Update lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/bottomtabs/BottomTabsController.java

Co-authored-by: aliraza-noon <[email protected]>

* Squashed commit of the following:

commit eae58312ce997ed580163e2f1d5cb6c3ea1ec086
Author: Ward Abbass <[email protected]>
Date:   Tue Nov 30 08:55:13 2021 +0200

    Android API 30 fixes (#7343)

    Upgrading android target SDK to 30, to support android 12 changes.

    - Refactor StatusBarUtil to SystemUIUtils to include status and navigation bars.
    - Migrate deprecated code using flags to a modern one.
    - Calculating WindowInsets per component where all views are laid as full screen.
    - Keyboard enhancements to show hide keyboard.
    - Fix applying Options of a child taking parent Options into consideration.
    - Fix fixed status bar height and use a more elegant way.
    - Add more tests for SystemUiUtils.
    - Add a SystemUi screen to demonstrate system UI capabilities.
    - Migrate Reanimated usage to support Reanimated 2.

    Closes #7339.
    Closes #7225.
    Closes #7358.
    Closes #7199.
    Closes #7171.
    Closes #7111.
    Closes #6988.
    Closes #4258.
    Closes #7360.

    Demo:

    https://user-images.githubusercontent.com/7227793/142203865-d65b6910-21f8-4617-812e-b5576a6b58e4.mov

    Co-authored-by: Ward Abbass <[email protected]>
    Co-authored-by: Yogev Ben David <[email protected]>
    Co-authored-by: svbutko <[email protected]>
    Co-authored-by: Ward Abbass <[email protected]>

* Update BottomTabsControllerTest.kt

Co-authored-by: aliraza-noon <[email protected]>

* Fix lagging keyboard when using autoFocus (#7376)

When using TextInput's `autoFocus`, The keyboard view is trying to animate its slide-in transition within the context of a the screen push animation.
We solved this by swizzling RN code and delay the becomeFirstResponder to after the component is appeared.

Closes #7019

* Update typescript to 4.x.x (#7299)

TODO:
- [x] Update typescript
- [x] Update eslint plugins
- [x] Fix ts errors
- [x] Fix eslint errors


How was changed compilations output:

<details>
  <summary>diff: lib/dist</summary>
  
  ```diff
  index bb7566a47..32be1e8d4 100644
  --- a/lib/dist/Mock/Application.js
  +++ b/lib/dist/Mock/Application.js
  @@ -2,10 +2,10 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.Application = void 0;
   const tslib_1 = require("tslib");
  -const React = tslib_1.__importStar(require("react"));
  +const React = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const connect_1 = require("./connect");
  -exports.Application = connect_1.connect(class extends React.Component {
  +exports.Application = (0, connect_1.connect)(class extends React.Component {
       constructor(props) {
           super(props);
           props.entryPoint();
  diff --git a/lib/dist/Mock/Components/BottomTabs.js b/lib/dist/Mock/Components/BottomTabs.js
  index 0eacd9f6a..ffd403db7 100644
  --- a/lib/dist/Mock/Components/BottomTabs.js
  +++ b/lib/dist/Mock/Components/BottomTabs.js
  @@ -2,10 +2,10 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.BottomTabs = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const LayoutComponent_1 = require("./LayoutComponent");
   const connect_1 = require("../connect");
  -exports.BottomTabs = connect_1.connect(class extends react_1.Component {
  +exports.BottomTabs = (0, connect_1.connect)(class extends react_1.Component {
       render() {
           return this.props.layoutNode.children.map((child) => {
               return react_1.default.createElement(LayoutComponent_1.LayoutComponent, { key: child.nodeId, layoutNode: child });
  diff --git a/lib/dist/Mock/Components/ComponentScreen.js b/lib/dist/Mock/Components/ComponentScreen.js
  index c23f91d91..d030db91a 100644
  --- a/lib/dist/Mock/Components/ComponentScreen.js
  +++ b/lib/dist/Mock/Components/ComponentScreen.js
  @@ -2,14 +2,14 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.ComponentScreen = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const __1 = require("../..");
   const constants_1 = require("../constants");
   const LayoutStore_1 = require("../Stores/LayoutStore");
   const connect_1 = require("../connect");
   const TopBar_1 = require("./TopBar");
  -exports.ComponentScreen = connect_1.connect(class extends react_1.Component {
  +exports.ComponentScreen = (0, connect_1.connect)(class extends react_1.Component {
       constructor(props) {
           super(props);
       }
  diff --git a/lib/dist/Mock/Components/LayoutComponent.js b/lib/dist/Mock/Components/LayoutComponent.js
  index f29b2eb52..593382929 100644
  --- a/lib/dist/Mock/Components/LayoutComponent.js
  +++ b/lib/dist/Mock/Components/LayoutComponent.js
  @@ -2,12 +2,12 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.LayoutComponent = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const BottomTabs_1 = require("./BottomTabs");
   const ComponentScreen_1 = require("./ComponentScreen");
   const Stack_1 = require("./Stack");
  -exports.LayoutComponent = class extends react_1.Component {
  +const LayoutComponent = class extends react_1.Component {
       render() {
           switch (this.props.layoutNode.type) {
               case 'BottomTabs':
  @@ -20,3 +20,4 @@ exports.LayoutComponent = class extends react_1.Component {
           return react_1.default.createElement(react_native_1.View, null);
       }
   };
  +exports.LayoutComponent = LayoutComponent;
  diff --git a/lib/dist/Mock/Components/Modals.js b/lib/dist/Mock/Components/Modals.js
  index 8ac96a790..c6275458f 100644
  --- a/lib/dist/Mock/Components/Modals.js
  +++ b/lib/dist/Mock/Components/Modals.js
  @@ -2,12 +2,12 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.Modals = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const LayoutComponent_1 = require("./LayoutComponent");
   const LayoutStore_1 = require("../Stores/LayoutStore");
   const connect_1 = require("../connect");
  -exports.Modals = connect_1.connect(class extends react_1.Component {
  +exports.Modals = (0, connect_1.connect)(class extends react_1.Component {
       render() {
           const children = LayoutStore_1.LayoutStore.getModals();
           return (react_1.default.createElement(react_native_1.View, { testID: 'MODALS' }, children.map((child) => {
  diff --git a/lib/dist/Mock/Components/NavigationButton.js b/lib/dist/Mock/Components/NavigationButton.js
  index 2cb32877a..84ce46707 100644
  --- a/lib/dist/Mock/Components/NavigationButton.js
  +++ b/lib/dist/Mock/Components/NavigationButton.js
  @@ -2,15 +2,12 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.NavigationButton = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const __1 = require("../../");
   const EventsStore_1 = require("../Stores/EventsStore");
  -exports.NavigationButton = class extends react_1.Component {
  -    constructor() {
  -        super(...arguments);
  -        this.ref = undefined;
  -    }
  +const NavigationButton = class extends react_1.Component {
  +    ref = undefined;
       render() {
           const { button, componentId } = this.props;
           if (button.component)
  @@ -38,7 +35,7 @@ exports.NavigationButton = class extends react_1.Component {
                       componentId: componentId,
                   });
               }, testID: button.testID },
  -            react_1.default.createElement(Component, Object.assign({ key: buttonComponentId }, props, { componentId: buttonComponentId, ref: (ref) => (this.ref = ref) }))));
  +            react_1.default.createElement(Component, { key: buttonComponentId, ...props, componentId: buttonComponentId, ref: (ref) => (this.ref = ref) })));
       }
       invokeOnClick(stateNode) {
           if (stateNode.children) {
  @@ -53,3 +50,4 @@ exports.NavigationButton = class extends react_1.Component {
           }
       }
   };
  +exports.NavigationButton = NavigationButton;
  diff --git a/lib/dist/Mock/Components/Overlays.js b/lib/dist/Mock/Components/Overlays.js
  index f20cb399c..f9d336bd9 100644
  --- a/lib/dist/Mock/Components/Overlays.js
  +++ b/lib/dist/Mock/Components/Overlays.js
  @@ -2,13 +2,13 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.Overlays = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const constants_1 = require("../constants");
   const LayoutComponent_1 = require("./LayoutComponent");
   const LayoutStore_1 = require("../Stores/LayoutStore");
   const connect_1 = require("../connect");
  -exports.Overlays = connect_1.connect(class extends react_1.Component {
  +exports.Overlays = (0, connect_1.connect)(class extends react_1.Component {
       render() {
           const children = LayoutStore_1.LayoutStore.getOverlays();
           return (react_1.default.createElement(react_native_1.View, { testID: constants_1.VISIBLE_OVERLAY_TEST_ID }, children.map((child) => {
  diff --git a/lib/dist/Mock/Components/Stack.js b/lib/dist/Mock/Components/Stack.js
  index d2586c8b5..602089fc1 100644
  --- a/lib/dist/Mock/Components/Stack.js
  +++ b/lib/dist/Mock/Components/Stack.js
  @@ -2,10 +2,10 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.Stack = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const LayoutComponent_1 = require("./LayoutComponent");
   const connect_1 = require("../connect");
  -exports.Stack = connect_1.connect(class extends react_1.Component {
  +exports.Stack = (0, connect_1.connect)(class extends react_1.Component {
       render() {
           const children = this.props.layoutNode.children;
           return children.map((child, i) => {
  diff --git a/lib/dist/Mock/Components/TopBar.js b/lib/dist/Mock/Components/TopBar.js
  index 9482bc4d4..2140a3f3d 100644
  --- a/lib/dist/Mock/Components/TopBar.js
  +++ b/lib/dist/Mock/Components/TopBar.js
  @@ -2,14 +2,14 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.TopBar = void 0;
   const tslib_1 = require("tslib");
  -const react_1 = tslib_1.__importStar(require("react"));
  +const react_1 = (0, tslib_1.__importStar)(require("react"));
   const react_native_1 = require("react-native");
   const __1 = require("../..");
   const LayoutStore_1 = require("../Stores/LayoutStore");
   const NavigationButton_1 = require("./NavigationButton");
   const EventsStore_1 = require("../Stores/EventsStore");
   const DEFAULT_BACK_BUTTON_ID = 'RNN.back';
  -exports.TopBar = class extends react_1.Component {
  +const TopBar = class extends react_1.Component {
       constructor(props) {
           super(props);
       }
  @@ -57,6 +57,7 @@ exports.TopBar = class extends react_1.Component {
           const Component = __1.Navigation.mock.store.getComponentClassForName(name)();
           const props = __1.Navigation.mock.store.getPropsForId(id);
           return (react_1.default.createElement(react_native_1.View, { key: id, testID: testID },
  -            react_1.default.createElement(Component, Object.assign({}, props, { componentId: id }))));
  +            react_1.default.createElement(Component, { ...props, componentId: id })));
       }
   };
  +exports.TopBar = TopBar;
  diff --git a/lib/dist/Mock/Layouts/BottomTabsNode.js b/lib/dist/Mock/Layouts/BottomTabsNode.js
  index 82625609f..97a97df43 100644
  --- a/lib/dist/Mock/Layouts/BottomTabsNode.js
  +++ b/lib/dist/Mock/Layouts/BottomTabsNode.js
  @@ -1,13 +1,13 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   const tslib_1 = require("tslib");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
   const LayoutStore_1 = require("../Stores/LayoutStore");
  -const ParentNode_1 = tslib_1.__importDefault(require("./ParentNode"));
  +const ParentNode_1 = (0, tslib_1.__importDefault)(require("./ParentNode"));
   class BottomTabsNode extends ParentNode_1.default {
  +    selectedIndex = 0;
       constructor(layout, parentNode) {
           super(layout, 'BottomTabs', parentNode);
  -        this.selectedIndex = 0;
       }
       mergeOptions(options) {
           super.mergeOptions(options);
  diff --git a/lib/dist/Mock/Layouts/ComponentNode.js b/lib/dist/Mock/Layouts/ComponentNode.js
  index 6ff44f821..50f3629ec 100644
  --- a/lib/dist/Mock/Layouts/ComponentNode.js
  +++ b/lib/dist/Mock/Layouts/ComponentNode.js
  @@ -1,14 +1,14 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   const tslib_1 = require("tslib");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
   const EventsStore_1 = require("../Stores/EventsStore");
  -const ParentNode_1 = tslib_1.__importDefault(require("./ParentNode"));
  +const ParentNode_1 = (0, tslib_1.__importDefault)(require("./ParentNode"));
   class ComponentNode extends ParentNode_1.default {
  +    componentDidMountOnce = false;
  +    componentDidAppearPending = false;
       constructor(layout, parentNode) {
           super(layout, 'Component', parentNode);
  -        this.componentDidMountOnce = false;
  -        this.componentDidAppearPending = false;
       }
       componentDidMount() {
           this.componentDidMountOnce = true;
  diff --git a/lib/dist/Mock/Layouts/LayoutNodeFactory.js b/lib/dist/Mock/Layouts/LayoutNodeFactory.js
  index 2a5d9fa1a..1ea4e18b9 100644
  --- a/lib/dist/Mock/Layouts/LayoutNodeFactory.js
  +++ b/lib/dist/Mock/Layouts/LayoutNodeFactory.js
  @@ -1,9 +1,9 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   const tslib_1 = require("tslib");
  -const BottomTabsNode_1 = tslib_1.__importDefault(require("./BottomTabsNode"));
  -const ComponentNode_1 = tslib_1.__importDefault(require("./ComponentNode"));
  -const StackNode_1 = tslib_1.__importDefault(require("./StackNode"));
  +const BottomTabsNode_1 = (0, tslib_1.__importDefault)(require("./BottomTabsNode"));
  +const ComponentNode_1 = (0, tslib_1.__importDefault)(require("./ComponentNode"));
  +const StackNode_1 = (0, tslib_1.__importDefault)(require("./StackNode"));
   class LayoutNodeFactory {
       static create(layout, parentNode) {
           switch (layout.type) {
  diff --git a/lib/dist/Mock/Layouts/Node.js b/lib/dist/Mock/Layouts/Node.js
  index f03599138..04bc68354 100644
  --- a/lib/dist/Mock/Layouts/Node.js
  +++ b/lib/dist/Mock/Layouts/Node.js
  @@ -1,6 +1,11 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   class Node {
  +    nodeId;
  +    data;
  +    type;
  +    // options: Options;
  +    parentNode;
       constructor(layout, type, parentNode) {
           this.nodeId = layout.id;
           this.data = layout.data;
  diff --git a/lib/dist/Mock/Layouts/ParentNode.js b/lib/dist/Mock/Layouts/ParentNode.js
  index c446dcd8b..0ba4f703e 100644
  --- a/lib/dist/Mock/Layouts/ParentNode.js
  +++ b/lib/dist/Mock/Layouts/ParentNode.js
  @@ -1,11 +1,12 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   const tslib_1 = require("tslib");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
   const LayoutStore_1 = require("../Stores/LayoutStore");
  -const LayoutNodeFactory_1 = tslib_1.__importDefault(require("./LayoutNodeFactory"));
  -const Node_1 = tslib_1.__importDefault(require("./Node"));
  +const LayoutNodeFactory_1 = (0, tslib_1.__importDefault)(require("./LayoutNodeFactory"));
  +const Node_1 = (0, tslib_1.__importDefault)(require("./Node"));
   class ParentNode extends Node_1.default {
  +    children;
       constructor(layout, type, parentNode) {
           super(layout, type, parentNode);
           this.children = layout.children.map((childLayout) => LayoutNodeFactory_1.default.create(childLayout, this));
  diff --git a/lib/dist/Mock/Layouts/StackNode.js b/lib/dist/Mock/Layouts/StackNode.js
  index 2093e7b23..7d78383cf 100644
  --- a/lib/dist/Mock/Layouts/StackNode.js
  +++ b/lib/dist/Mock/Layouts/StackNode.js
  @@ -1,7 +1,7 @@
   "use strict";
   Object.defineProperty(exports, "__esModule", { value: true });
   const tslib_1 = require("tslib");
  -const ParentNode_1 = tslib_1.__importDefault(require("./ParentNode"));
  +const ParentNode_1 = (0, tslib_1.__importDefault)(require("./ParentNode"));
   class StackNode extends ParentNode_1.default {
       constructor(layout, parentNode) {
           super(layout, 'Stack', parentNode);
  diff --git a/lib/dist/Mock/Stores/LayoutStore.js b/lib/dist/Mock/Stores/LayoutStore.js
  index 1aa3bcde3..0bb08f41b 100644
  --- a/lib/dist/Mock/Stores/LayoutStore.js
  +++ b/lib/dist/Mock/Stores/LayoutStore.js
  @@ -2,8 +2,8 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.LayoutStore = void 0;
   const tslib_1 = require("tslib");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  -const LayoutNodeFactory_1 = tslib_1.__importDefault(require("../Layouts/LayoutNodeFactory"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
  +const LayoutNodeFactory_1 = (0, tslib_1.__importDefault)(require("../Layouts/LayoutNodeFactory"));
   const remx = require('remx');
   const state = remx.state({
       root: {},
  diff --git a/lib/dist/Mock/connect.js b/lib/dist/Mock/connect.js
  index ca7b3b493..c9fa9cdfa 100644
  --- a/lib/dist/Mock/connect.js
  +++ b/lib/dist/Mock/connect.js
  @@ -4,6 +4,6 @@ exports.connect = void 0;
   const remx_1 = require("remx");
   function connect(component) {
       // @ts-ignore
  -    return remx_1.connect()(component);
  +    return (0, remx_1.connect)()(component);
   }
   exports.connect = connect;
  diff --git a/lib/dist/Mock/index.js b/lib/dist/Mock/index.js
  index 3720f4cf6..26e72e816 100644
  --- a/lib/dist/Mock/index.js
  +++ b/lib/dist/Mock/index.js
  @@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
   exports.mockNativeComponents = exports.ApplicationMock = void 0;
   const tslib_1 = require("tslib");
   exports.ApplicationMock = require('./Application').Application;
  -tslib_1.__exportStar(require("./constants"), exports);
  +(0, tslib_1.__exportStar)(require("./constants"), exports);
   function mockNativeComponents() {
       const { NativeCommandsSender } = require('./mocks/NativeCommandsSender');
       const { NativeEventsReceiver } = require('./mocks/NativeEventsReceiver');
  diff --git a/lib/dist/Mock/mocks/NativeCommandsSender.js b/lib/dist/Mock/mocks/NativeCommandsSender.js
  index 145c82361..3d64226dd 100644
  --- a/lib/dist/Mock/mocks/NativeCommandsSender.js
  +++ b/lib/dist/Mock/mocks/NativeCommandsSender.js
  @@ -3,9 +3,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
   exports.NativeCommandsSender = void 0;
   const tslib_1 = require("tslib");
   const LayoutStore_1 = require("../Stores/LayoutStore");
  -const LayoutNodeFactory_1 = tslib_1.__importDefault(require("../Layouts/LayoutNodeFactory"));
  +const LayoutNodeFactory_1 = (0, tslib_1.__importDefault)(require("../Layouts/LayoutNodeFactory"));
   const EventsStore_1 = require("../Stores/EventsStore");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
   class NativeCommandsSender {
       constructor() { }
       setRoot(_commandId, layout) {
  diff --git a/lib/dist/Mock/mocks/NativeEventsReceiver.js b/lib/dist/Mock/mocks/NativeEventsReceiver.js
  index dcb7de6d1..513cfd44a 100644
  --- a/lib/dist/Mock/mocks/NativeEventsReceiver.js
  +++ b/lib/dist/Mock/mocks/NativeEventsReceiver.js
  @@ -2,7 +2,7 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.NativeEventsReceiver = void 0;
   const tslib_1 = require("tslib");
  -const lodash_1 = tslib_1.__importDefault(require("lodash"));
  +const lodash_1 = (0, tslib_1.__importDefault)(require("lodash"));
   const EventsStore_1 = require("./../Stores/EventsStore");
   class NativeEventsReceiver {
       registerAppLaunchedListener(callback) {
  diff --git a/lib/dist/Navigation.js b/lib/dist/Navigation.js
  index 200c8e56a..ceabecc4a 100644
  --- a/lib/dist/Navigation.js
  +++ b/lib/dist/Navigation.js
  @@ -2,7 +2,7 @@
   Object.defineProperty(exports, "__esModule", { value: true });
   exports.NavigationRoot = void 0;
   const tslib_1 = require("tslib");
  -const isArray_1 = tslib_1.__importDefault(require("lodash/isArray"));
  +const isArray_1 = (0, tslib_1.__importDefault)(require("lodash/isArray"));
   const UniqueIdProvider_1 = require("./adapters/UniqueIdProvider");
   const Store_1 = require("./components/Store");
   const OptionProcessorsStore_1 = require("./processors/OptionProcessorsStore");
  @@ -24,11 +24,27 @@ const LayoutProcessor_1 = require("./processors/LayoutProcessor");
   const LayoutProcessorsStore_1 = require("./processors/LayoutProcessorsStore");
   const OptionsCrawler_1 = require("./commands/OptionsCrawler");
   class NavigationRoot {
  +    nativeCommandsSender;
  +    nativeEventsReceiver;
  +    appRegistryService;
  +    TouchablePreview = TouchablePreview_1.TouchablePreview;
  +    store;
  +    optionProcessorsStore;
  +    layoutProcessorsStore;
  +    uniqueIdProvider;
  +    componentRegistry;
  +    layoutTreeParser;
  +    layoutTreeCrawler;
  +    commands;
  +    eventsRegistry;
  +    commandsObserver;
  +    componentEventsObserver;
  +    componentWrapper;
  +    optionsCrawler;
       constructor(nativeCommandsSender, nativeEventsReceiver, appRegistryService) {
           this.nativeCommandsSender = nativeCommandsSender;
           this.nativeEventsReceiver = nativeEventsReceiver;
           this.appRegistryService = appRegistryService;
  -        this.TouchablePreview = TouchablePreview_1.TouchablePreview;
           this.componentWrapper = new ComponentWrapper_1.ComponentWrapper();
           this.store = new Store_1.Store();
           this.optionProcessorsStore = new OptionProcessorsStore_1.OptionProcessorsStore();
  @@ -147,7 +163,7 @@ class NavigationRoot {
        * Sets new root component to stack.
        */
       setStackRoot(componentId, layout) {
  -        const children = isArray_1.default(layout) ? layout : [layout];
  +        const children = (0, isArray_1.default)(layout) ? layout : [layout];
           return this.commands.setStackRoot(componentId, children);
       }
       /**
  diff --git a/lib/dist/NavigationDelegate.js b/lib/dist/NavigationDelegate.js
  index 745e950d0..e4b83a973 100644
  --- a/lib/dist/NavigationDelegate.js
  +++ b/lib/dist/NavigationDelegate.js
  @@ -6,6 +6,7 @@ const NativeCommandsSender_1 = require("./adapters/NativeCommandsSender");
   const NativeEventsReceiver_1 = require("./adapters/NativeEventsReceiver");
   const AppRegistryService_1 = require("./adapters/AppRegistryService");
   class NavigationDelegate {
  +    concreteNavigation;
       constructor() {
           this.concreteNavigation = this.createConcreteNavigation(new NativeCommandsSender_1.NativeCommandsSender(), new NativeEventsReceiver_1.NativeEventsReceiver(), new AppRegistryService_1.AppRegistryService());
       }
  diff --git a/lib/dist/adapters/ColorService.d.ts b/lib/dist/adapters/ColorService.d.ts
  index ab3e0ca04..6af546721 100644
  --- a/lib/dist/adapters/ColorService.d.ts
  +++ b/lib/dist/adapters/ColorService.d.ts
  @@ -1,3 +1,3 @@
   export declare class ColorService {
  -    toNativeColor(inputColor: string): number | typeof import("react-native").OpaqueColorValue | null | undefined;
  +    toNativeColor(inputColor: string): import("react-native").ProcessedColorValue | null | undefined;
   }
  diff --git a/lib/dist/adapters/ColorService.js b/lib/dist/adapters/ColorService.js
  index b9ebf7fef..96fdc3fc8 100644
  --- a/lib/dist/adapters/ColorService.js
  +++ b/lib/dist/adapters/ColorService.js
  @@ -4,7 +4,7 @@ exports.ColorService = void 0;
   const react_native_1 = require("react-native");
   class ColorService {
       toNativeColor(inputColor) {
  -        return react_native_1.processColor(inputColor);
  +        return (0, react_native_1.processColor)(inputColor);
       }
   }
   exports.ColorService = ColorService;
  diff --git a/lib/dist/adapters/Constants.js b/lib/dist/adapters/Constants.js
  index dea12936d..114a4c85d 100644
  --- a/lib/dist/adapters/Constants.js
  +++ b/lib/dist/adapters/Constants.js
  @@ -3,12 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
   exports.Constants = void 0;
   const react_native_1 = require("react-native");
   class Constants {
  -    constructor(constants) {
  -        this.statusBarHeight = constants.statusBarHeight;
  -        this.topBarHeight = constants.topBarHeight;
  -        this.backButtonId = constants.backButtonId;
  -        this.bottomTabsHeight = constants.bottomTabsHeight;
  -    }
       static async get() {
           const constants = await react_native_1.NativeModules.RNNBridgeModule.getNavigationConstants();
           return new Constants(constants);
  @@ -16,5 +10,15 @@ class Constants {
       static getSync() {
           return new Constants(react_native_1.NativeModules.RNNBridgeModule.getNavigationConstantsSync());
       }
  +    statusBarHeight;
  +    backButtonId;
  +    t…
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants