Added modalAttemptedToDismiss event with tests and docs (#5832)
* Added modalAttemptedToDismiss event with tests and docs
* Typo on pageSheet modal button label
* Update ModalScreen.js
* Fixed button testID
* Revert label to fix test cases
Co-authored-by: Guy Carmeli <guyca@users.noreply.github.com>
Co-authored-by: Yogev Ben David <yogevbd@wix.com>
Emit modalDismissed event before ViewController is destroyed (#5838)
This is required so that a component displayed in a modal can react to the dismiss of the modal it's presented in. This change aligns behaviour with iOS.
closes #5830
Send componentType field in componentDidAppear and componentDidDisappear events.
The new field is either:
- TopBarButton
- TopBarTitle
- TopBarBackground
- Component
This works around a rare edge case where applying the translucent flag
resulted in white screens when pushing or showing modals.
So far, I've managed to reproduce this only when when showing external component as modal in the Wix app.
closes #5742
Called each time a screen is popped, either due to `Navigation.pop` or pop gesture.
closes #3941
Navigation.events().registerScreenPoppedListener(({ componentId }) => {
});
Fix native image resource for bottom tab icon (#5775)
bottomTab.icon accepts a string as well as required asset - this was not reflected properly in TypeScript and implementation was missing from Android.
closes #5759
Add iOS support for `bottomTabs.attachMode`.
This property controls when BottomTabs children are attached to hierarchy and when their React views are created.
By default, RNN attaches all children at the same time which might impact loading time as a few screens are instantiated at once.
Using `afterInitialTab` or `onSwitchToTab` generally leads to improved start up time.