@ohos-ports/react-native-navigation 8.9.0-beta.0
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.
- package/LICENSE +21 -0
- package/README.md +37 -0
- package/lib/android/app/src/main/java/com/reactnativenavigation/viewcontrollers/statusbar/StatusBarPresenter.kt +212 -0
- package/lib/module/ARCHITECTURE.md +331 -0
- package/lib/module/Mock/Application.js +33 -0
- package/lib/module/Mock/Application.js.map +1 -0
- package/lib/module/Mock/ComponentProps.js +4 -0
- package/lib/module/Mock/ComponentProps.js.map +1 -0
- package/lib/module/Mock/Components/BottomTabs.js +16 -0
- package/lib/module/Mock/Components/BottomTabs.js.map +1 -0
- package/lib/module/Mock/Components/ComponentScreen.js +101 -0
- package/lib/module/Mock/Components/ComponentScreen.js.map +1 -0
- package/lib/module/Mock/Components/LayoutComponent.js +50 -0
- package/lib/module/Mock/Components/LayoutComponent.js.map +1 -0
- package/lib/module/Mock/Components/Modals.js +22 -0
- package/lib/module/Mock/Components/Modals.js.map +1 -0
- package/lib/module/Mock/Components/NavigationButton.js +72 -0
- package/lib/module/Mock/Components/NavigationButton.js.map +1 -0
- package/lib/module/Mock/Components/Overlays.js +23 -0
- package/lib/module/Mock/Components/Overlays.js.map +1 -0
- package/lib/module/Mock/Components/SideMenu.js +29 -0
- package/lib/module/Mock/Components/SideMenu.js.map +1 -0
- package/lib/module/Mock/Components/Stack.js +18 -0
- package/lib/module/Mock/Components/Stack.js.map +1 -0
- package/lib/module/Mock/Components/TopBar.js +81 -0
- package/lib/module/Mock/Components/TopBar.js.map +1 -0
- package/lib/module/Mock/Layouts/BottomTabsNode.js +30 -0
- package/lib/module/Mock/Layouts/BottomTabsNode.js.map +1 -0
- package/lib/module/Mock/Layouts/ComponentNode.js +102 -0
- package/lib/module/Mock/Layouts/ComponentNode.js.map +1 -0
- package/lib/module/Mock/Layouts/LayoutNodeFactory.js +28 -0
- package/lib/module/Mock/Layouts/LayoutNodeFactory.js.map +1 -0
- package/lib/module/Mock/Layouts/Node.js +14 -0
- package/lib/module/Mock/Layouts/Node.js.map +1 -0
- package/lib/module/Mock/Layouts/ParentNode.js +66 -0
- package/lib/module/Mock/Layouts/ParentNode.js.map +1 -0
- package/lib/module/Mock/Layouts/SideMenu.js +72 -0
- package/lib/module/Mock/Layouts/SideMenu.js.map +1 -0
- package/lib/module/Mock/Layouts/StackNode.js +12 -0
- package/lib/module/Mock/Layouts/StackNode.js.map +1 -0
- package/lib/module/Mock/Stores/EventsStore.js +53 -0
- package/lib/module/Mock/Stores/EventsStore.js.map +1 -0
- package/lib/module/Mock/Stores/LayoutStore.js +176 -0
- package/lib/module/Mock/Stores/LayoutStore.js.map +1 -0
- package/lib/module/Mock/actions/layoutActions.js +19 -0
- package/lib/module/Mock/actions/layoutActions.js.map +1 -0
- package/lib/module/Mock/connect.js +8 -0
- package/lib/module/Mock/connect.js.map +1 -0
- package/lib/module/Mock/constants.js +5 -0
- package/lib/module/Mock/constants.js.map +1 -0
- package/lib/module/Mock/index.js +20 -0
- package/lib/module/Mock/index.js.map +1 -0
- package/lib/module/Mock/mocks/AppRegistryService.js +6 -0
- package/lib/module/Mock/mocks/AppRegistryService.js.map +1 -0
- package/lib/module/Mock/mocks/NativeCommandsSender.js +146 -0
- package/lib/module/Mock/mocks/NativeCommandsSender.js.map +1 -0
- package/lib/module/Mock/mocks/NativeEventsReceiver.js +103 -0
- package/lib/module/Mock/mocks/NativeEventsReceiver.js.map +1 -0
- package/lib/module/Navigation.js +250 -0
- package/lib/module/Navigation.js.map +1 -0
- package/lib/module/NavigationDelegate.js +210 -0
- package/lib/module/NavigationDelegate.js.map +1 -0
- package/lib/module/adapters/AndroidCustomRowForwarder.js +75 -0
- package/lib/module/adapters/AndroidCustomRowForwarder.js.map +1 -0
- package/lib/module/adapters/AppRegistryService.js +9 -0
- package/lib/module/adapters/AppRegistryService.js.map +1 -0
- package/lib/module/adapters/AssetResolver.js +9 -0
- package/lib/module/adapters/AssetResolver.js.map +1 -0
- package/lib/module/adapters/ColorService.js +9 -0
- package/lib/module/adapters/ColorService.js.map +1 -0
- package/lib/module/adapters/Constants.js +19 -0
- package/lib/module/adapters/Constants.js.map +1 -0
- package/lib/module/adapters/NativeCommandsSender.js +60 -0
- package/lib/module/adapters/NativeCommandsSender.js.map +1 -0
- package/lib/module/adapters/NativeEventsReceiver.js +65 -0
- package/lib/module/adapters/NativeEventsReceiver.js.map +1 -0
- package/lib/module/adapters/NativeEventsReceiver.mock.js +6 -0
- package/lib/module/adapters/NativeEventsReceiver.mock.js.map +1 -0
- package/lib/module/adapters/NativeRNNTurboEventEmitter.js +7 -0
- package/lib/module/adapters/NativeRNNTurboEventEmitter.js.map +1 -0
- package/lib/module/adapters/NativeRNNTurboModule.js +6 -0
- package/lib/module/adapters/NativeRNNTurboModule.js.map +1 -0
- package/lib/module/adapters/TouchablePreview.js +115 -0
- package/lib/module/adapters/TouchablePreview.js.map +1 -0
- package/lib/module/adapters/UniqueIdProvider.js +9 -0
- package/lib/module/adapters/UniqueIdProvider.js.map +1 -0
- package/lib/module/commands/Commands.js +241 -0
- package/lib/module/commands/Commands.js.map +1 -0
- package/lib/module/commands/Commands.test.js +759 -0
- package/lib/module/commands/Commands.test.js.map +1 -0
- package/lib/module/commands/Deprecations.js +66 -0
- package/lib/module/commands/Deprecations.js.map +1 -0
- package/lib/module/commands/LayoutTreeCrawler.js +32 -0
- package/lib/module/commands/LayoutTreeCrawler.js.map +1 -0
- package/lib/module/commands/LayoutTreeCrawler.test.js +82 -0
- package/lib/module/commands/LayoutTreeCrawler.test.js.map +1 -0
- package/lib/module/commands/LayoutTreeParser.js +130 -0
- package/lib/module/commands/LayoutTreeParser.js.map +1 -0
- package/lib/module/commands/LayoutTreeParser.test.js +359 -0
- package/lib/module/commands/LayoutTreeParser.test.js.map +1 -0
- package/lib/module/commands/LayoutType.js +16 -0
- package/lib/module/commands/LayoutType.js.map +1 -0
- package/lib/module/commands/LayoutType.test.js +12 -0
- package/lib/module/commands/LayoutType.test.js.map +1 -0
- package/lib/module/commands/OptionsCrawler.js +72 -0
- package/lib/module/commands/OptionsCrawler.js.map +1 -0
- package/lib/module/commands/OptionsCrawler.test.js +351 -0
- package/lib/module/commands/OptionsCrawler.test.js.map +1 -0
- package/lib/module/commands/OptionsProcessor.js +300 -0
- package/lib/module/commands/OptionsProcessor.js.map +1 -0
- package/lib/module/commands/OptionsProcessor.test.js +1234 -0
- package/lib/module/commands/OptionsProcessor.test.js.map +1 -0
- package/lib/module/components/ComponentRegistry.js +25 -0
- package/lib/module/components/ComponentRegistry.js.map +1 -0
- package/lib/module/components/ComponentRegistry.test.js +57 -0
- package/lib/module/components/ComponentRegistry.test.js.map +1 -0
- package/lib/module/components/ComponentWrapper.js +80 -0
- package/lib/module/components/ComponentWrapper.js.map +1 -0
- package/lib/module/components/ComponentWrapper.test.js +333 -0
- package/lib/module/components/ComponentWrapper.test.js.map +1 -0
- package/lib/module/components/Modal.js +125 -0
- package/lib/module/components/Modal.js.map +1 -0
- package/lib/module/components/Store.js +71 -0
- package/lib/module/components/Store.js.map +1 -0
- package/lib/module/components/Store.test.js +148 -0
- package/lib/module/components/Store.test.js.map +1 -0
- package/lib/module/events/CommandsObserver.js +19 -0
- package/lib/module/events/CommandsObserver.js.map +1 -0
- package/lib/module/events/CommandsObserver.test.js +43 -0
- package/lib/module/events/CommandsObserver.test.js.map +1 -0
- package/lib/module/events/ComponentEventsObserver.js +94 -0
- package/lib/module/events/ComponentEventsObserver.js.map +1 -0
- package/lib/module/events/ComponentEventsObserver.test.js +391 -0
- package/lib/module/events/ComponentEventsObserver.test.js.map +1 -0
- package/lib/module/events/EventsRegistry.js +64 -0
- package/lib/module/events/EventsRegistry.js.map +1 -0
- package/lib/module/events/EventsRegistry.test.js +131 -0
- package/lib/module/events/EventsRegistry.test.js.map +1 -0
- package/lib/module/index.js +22 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/interfaces/CommandName.js +22 -0
- package/lib/module/interfaces/CommandName.js.map +1 -0
- package/lib/module/interfaces/ComponentEvents.js +2 -0
- package/lib/module/interfaces/ComponentEvents.js.map +1 -0
- package/lib/module/interfaces/EventSubscription.js +2 -0
- package/lib/module/interfaces/EventSubscription.js.map +1 -0
- package/lib/module/interfaces/Events.js +2 -0
- package/lib/module/interfaces/Events.js.map +1 -0
- package/lib/module/interfaces/Layout.js +4 -0
- package/lib/module/interfaces/Layout.js.map +1 -0
- package/lib/module/interfaces/NavigationComponent.js +21 -0
- package/lib/module/interfaces/NavigationComponent.js.map +1 -0
- package/lib/module/interfaces/NavigationComponentListener.js +4 -0
- package/lib/module/interfaces/NavigationComponentListener.js.map +1 -0
- package/lib/module/interfaces/NavigationComponentProps.js +2 -0
- package/lib/module/interfaces/NavigationComponentProps.js.map +1 -0
- package/lib/module/interfaces/NavigationFunctionComponent.js +4 -0
- package/lib/module/interfaces/NavigationFunctionComponent.js.map +1 -0
- package/lib/module/interfaces/Options.js +47 -0
- package/lib/module/interfaces/Options.js.map +1 -0
- package/lib/module/interfaces/ProcessorSubscription.js +2 -0
- package/lib/module/interfaces/ProcessorSubscription.js.map +1 -0
- package/lib/module/interfaces/Processors.js +4 -0
- package/lib/module/interfaces/Processors.js.map +1 -0
- package/lib/module/linking/DeferredLinkQueue.js +52 -0
- package/lib/module/linking/DeferredLinkQueue.js.map +1 -0
- package/lib/module/linking/DeferredLinkQueue.test.js +54 -0
- package/lib/module/linking/DeferredLinkQueue.test.js.map +1 -0
- package/lib/module/linking/LinkingHandler.js +139 -0
- package/lib/module/linking/LinkingHandler.js.map +1 -0
- package/lib/module/linking/LinkingHandler.test.js +384 -0
- package/lib/module/linking/LinkingHandler.test.js.map +1 -0
- package/lib/module/linking/ModalLayoutBuilder.js +56 -0
- package/lib/module/linking/ModalLayoutBuilder.js.map +1 -0
- package/lib/module/linking/ModalLayoutBuilder.test.js +154 -0
- package/lib/module/linking/ModalLayoutBuilder.test.js.map +1 -0
- package/lib/module/linking/RouteMatcher.js +104 -0
- package/lib/module/linking/RouteMatcher.js.map +1 -0
- package/lib/module/linking/RouteMatcher.test.js +164 -0
- package/lib/module/linking/RouteMatcher.test.js.map +1 -0
- package/lib/module/linking/URLParser.js +56 -0
- package/lib/module/linking/URLParser.js.map +1 -0
- package/lib/module/linking/URLParser.test.js +100 -0
- package/lib/module/linking/URLParser.test.js.map +1 -0
- package/lib/module/linking/types.js +4 -0
- package/lib/module/linking/types.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/processors/LayoutProcessor.js +15 -0
- package/lib/module/processors/LayoutProcessor.js.map +1 -0
- package/lib/module/processors/LayoutProcessor.test.js +53 -0
- package/lib/module/processors/LayoutProcessor.test.js.map +1 -0
- package/lib/module/processors/LayoutProcessorsStore.js +18 -0
- package/lib/module/processors/LayoutProcessorsStore.js.map +1 -0
- package/lib/module/processors/LayoutProcessorsStore.test.js +31 -0
- package/lib/module/processors/LayoutProcessorsStore.test.js.map +1 -0
- package/lib/module/processors/OptionProcessorsStore.js +19 -0
- package/lib/module/processors/OptionProcessorsStore.js.map +1 -0
- package/lib/module/processors/OptionProcessorsStore.test.js +31 -0
- package/lib/module/processors/OptionProcessorsStore.test.js.map +1 -0
- package/lib/module/types.js +2 -0
- package/lib/module/types.js.map +1 -0
- package/lib/typescript/Mock/Application.d.ts +30 -0
- package/lib/typescript/Mock/Application.d.ts.map +1 -0
- package/lib/typescript/Mock/ComponentProps.d.ts +6 -0
- package/lib/typescript/Mock/ComponentProps.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/BottomTabs.d.ts +47 -0
- package/lib/typescript/Mock/Components/BottomTabs.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/ComponentScreen.d.ts +29 -0
- package/lib/typescript/Mock/Components/ComponentScreen.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/LayoutComponent.d.ts +47 -0
- package/lib/typescript/Mock/Components/LayoutComponent.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/Modals.d.ts +47 -0
- package/lib/typescript/Mock/Components/Modals.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/NavigationButton.d.ts +58 -0
- package/lib/typescript/Mock/Components/NavigationButton.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/Overlays.d.ts +47 -0
- package/lib/typescript/Mock/Components/Overlays.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/SideMenu.d.ts +179 -0
- package/lib/typescript/Mock/Components/SideMenu.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/Stack.d.ts +47 -0
- package/lib/typescript/Mock/Components/Stack.d.ts.map +1 -0
- package/lib/typescript/Mock/Components/TopBar.d.ts +37 -0
- package/lib/typescript/Mock/Components/TopBar.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/BottomTabsNode.d.ts +9 -0
- package/lib/typescript/Mock/Layouts/BottomTabsNode.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/ComponentNode.d.ts +16 -0
- package/lib/typescript/Mock/Layouts/ComponentNode.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/LayoutNodeFactory.d.ts +9 -0
- package/lib/typescript/Mock/Layouts/LayoutNodeFactory.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/Node.d.ts +16 -0
- package/lib/typescript/Mock/Layouts/Node.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/ParentNode.d.ts +21 -0
- package/lib/typescript/Mock/Layouts/ParentNode.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/SideMenu.d.ts +32 -0
- package/lib/typescript/Mock/Layouts/SideMenu.d.ts.map +1 -0
- package/lib/typescript/Mock/Layouts/StackNode.d.ts +6 -0
- package/lib/typescript/Mock/Layouts/StackNode.d.ts.map +1 -0
- package/lib/typescript/Mock/Stores/EventsStore.d.ts +22 -0
- package/lib/typescript/Mock/Stores/EventsStore.d.ts.map +1 -0
- package/lib/typescript/Mock/Stores/LayoutStore.d.ts +2 -0
- package/lib/typescript/Mock/Stores/LayoutStore.d.ts.map +1 -0
- package/lib/typescript/Mock/actions/layoutActions.d.ts +6 -0
- package/lib/typescript/Mock/actions/layoutActions.d.ts.map +1 -0
- package/lib/typescript/Mock/connect.d.ts +2 -0
- package/lib/typescript/Mock/connect.d.ts.map +1 -0
- package/lib/typescript/Mock/constants.d.ts +3 -0
- package/lib/typescript/Mock/constants.d.ts.map +1 -0
- package/lib/typescript/Mock/index.d.ts +4 -0
- package/lib/typescript/Mock/index.d.ts.map +1 -0
- package/lib/typescript/Mock/mocks/AppRegistryService.d.ts +5 -0
- package/lib/typescript/Mock/mocks/AppRegistryService.d.ts.map +1 -0
- package/lib/typescript/Mock/mocks/NativeCommandsSender.d.ts +28 -0
- package/lib/typescript/Mock/mocks/NativeCommandsSender.d.ts.map +1 -0
- package/lib/typescript/Mock/mocks/NativeEventsReceiver.d.ts +21 -0
- package/lib/typescript/Mock/mocks/NativeEventsReceiver.d.ts.map +1 -0
- package/lib/typescript/Navigation.d.ts +152 -0
- package/lib/typescript/Navigation.d.ts.map +1 -0
- package/lib/typescript/NavigationDelegate.d.ts +128 -0
- package/lib/typescript/NavigationDelegate.d.ts.map +1 -0
- package/lib/typescript/adapters/AndroidCustomRowForwarder.d.ts +23 -0
- package/lib/typescript/adapters/AndroidCustomRowForwarder.d.ts.map +1 -0
- package/lib/typescript/adapters/AppRegistryService.d.ts +5 -0
- package/lib/typescript/adapters/AppRegistryService.d.ts.map +1 -0
- package/lib/typescript/adapters/AssetResolver.d.ts +5 -0
- package/lib/typescript/adapters/AssetResolver.d.ts.map +1 -0
- package/lib/typescript/adapters/ColorService.d.ts +4 -0
- package/lib/typescript/adapters/ColorService.d.ts.map +1 -0
- package/lib/typescript/adapters/Constants.d.ts +17 -0
- package/lib/typescript/adapters/Constants.d.ts.map +1 -0
- package/lib/typescript/adapters/NativeCommandsSender.d.ts +62 -0
- package/lib/typescript/adapters/NativeCommandsSender.d.ts.map +1 -0
- package/lib/typescript/adapters/NativeEventsReceiver.d.ts +23 -0
- package/lib/typescript/adapters/NativeEventsReceiver.d.ts.map +1 -0
- package/lib/typescript/adapters/NativeEventsReceiver.mock.d.ts +2 -0
- package/lib/typescript/adapters/NativeEventsReceiver.mock.d.ts.map +1 -0
- package/lib/typescript/adapters/NativeRNNTurboEventEmitter.d.ts +8 -0
- package/lib/typescript/adapters/NativeRNNTurboEventEmitter.d.ts.map +1 -0
- package/lib/typescript/adapters/NativeRNNTurboModule.d.ts +28 -0
- package/lib/typescript/adapters/NativeRNNTurboModule.d.ts.map +1 -0
- package/lib/typescript/adapters/TouchablePreview.d.ts +44 -0
- package/lib/typescript/adapters/TouchablePreview.d.ts.map +1 -0
- package/lib/typescript/adapters/UniqueIdProvider.d.ts +4 -0
- package/lib/typescript/adapters/UniqueIdProvider.d.ts.map +1 -0
- package/lib/typescript/commands/Commands.d.ts +41 -0
- package/lib/typescript/commands/Commands.d.ts.map +1 -0
- package/lib/typescript/commands/Commands.test.d.ts +2 -0
- package/lib/typescript/commands/Commands.test.d.ts.map +1 -0
- package/lib/typescript/commands/Deprecations.d.ts +10 -0
- package/lib/typescript/commands/Deprecations.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutTreeCrawler.d.ts +25 -0
- package/lib/typescript/commands/LayoutTreeCrawler.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutTreeCrawler.test.d.ts +2 -0
- package/lib/typescript/commands/LayoutTreeCrawler.test.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutTreeParser.d.ts +17 -0
- package/lib/typescript/commands/LayoutTreeParser.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutTreeParser.test.d.ts +2 -0
- package/lib/typescript/commands/LayoutTreeParser.test.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutType.d.ts +13 -0
- package/lib/typescript/commands/LayoutType.d.ts.map +1 -0
- package/lib/typescript/commands/LayoutType.test.d.ts +2 -0
- package/lib/typescript/commands/LayoutType.test.d.ts.map +1 -0
- package/lib/typescript/commands/OptionsCrawler.d.ts +20 -0
- package/lib/typescript/commands/OptionsCrawler.d.ts.map +1 -0
- package/lib/typescript/commands/OptionsCrawler.test.d.ts +2 -0
- package/lib/typescript/commands/OptionsCrawler.test.d.ts.map +1 -0
- package/lib/typescript/commands/OptionsProcessor.d.ts +40 -0
- package/lib/typescript/commands/OptionsProcessor.d.ts.map +1 -0
- package/lib/typescript/commands/OptionsProcessor.test.d.ts +2 -0
- package/lib/typescript/commands/OptionsProcessor.test.d.ts.map +1 -0
- package/lib/typescript/components/ComponentRegistry.d.ts +14 -0
- package/lib/typescript/components/ComponentRegistry.d.ts.map +1 -0
- package/lib/typescript/components/ComponentRegistry.test.d.ts +2 -0
- package/lib/typescript/components/ComponentRegistry.test.d.ts.map +1 -0
- package/lib/typescript/components/ComponentWrapper.d.ts +13 -0
- package/lib/typescript/components/ComponentWrapper.d.ts.map +1 -0
- package/lib/typescript/components/ComponentWrapper.test.d.ts +2 -0
- package/lib/typescript/components/ComponentWrapper.test.d.ts.map +1 -0
- package/lib/typescript/components/Modal.d.ts +21 -0
- package/lib/typescript/components/Modal.d.ts.map +1 -0
- package/lib/typescript/components/Store.d.ts +27 -0
- package/lib/typescript/components/Store.d.ts.map +1 -0
- package/lib/typescript/components/Store.test.d.ts +2 -0
- package/lib/typescript/components/Store.test.d.ts.map +1 -0
- package/lib/typescript/events/CommandsObserver.d.ts +11 -0
- package/lib/typescript/events/CommandsObserver.d.ts.map +1 -0
- package/lib/typescript/events/CommandsObserver.test.d.ts +2 -0
- package/lib/typescript/events/CommandsObserver.test.d.ts.map +1 -0
- package/lib/typescript/events/ComponentEventsObserver.d.ts +29 -0
- package/lib/typescript/events/ComponentEventsObserver.d.ts.map +1 -0
- package/lib/typescript/events/ComponentEventsObserver.test.d.ts +2 -0
- package/lib/typescript/events/ComponentEventsObserver.test.d.ts.map +1 -0
- package/lib/typescript/events/EventsRegistry.d.ts +34 -0
- package/lib/typescript/events/EventsRegistry.d.ts.map +1 -0
- package/lib/typescript/events/EventsRegistry.test.d.ts +2 -0
- package/lib/typescript/events/EventsRegistry.test.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +19 -0
- package/lib/typescript/index.d.ts.map +1 -0
- package/lib/typescript/interfaces/CommandName.d.ts +19 -0
- package/lib/typescript/interfaces/CommandName.d.ts.map +1 -0
- package/lib/typescript/interfaces/ComponentEvents.d.ts +43 -0
- package/lib/typescript/interfaces/ComponentEvents.d.ts.map +1 -0
- package/lib/typescript/interfaces/EventSubscription.d.ts +4 -0
- package/lib/typescript/interfaces/EventSubscription.d.ts.map +1 -0
- package/lib/typescript/interfaces/Events.d.ts +16 -0
- package/lib/typescript/interfaces/Events.d.ts.map +1 -0
- package/lib/typescript/interfaces/Layout.d.ts +190 -0
- package/lib/typescript/interfaces/Layout.d.ts.map +1 -0
- package/lib/typescript/interfaces/NavigationComponent.d.ts +22 -0
- package/lib/typescript/interfaces/NavigationComponent.d.ts.map +1 -0
- package/lib/typescript/interfaces/NavigationComponentListener.d.ts +14 -0
- package/lib/typescript/interfaces/NavigationComponentListener.d.ts.map +1 -0
- package/lib/typescript/interfaces/NavigationComponentProps.d.ts +11 -0
- package/lib/typescript/interfaces/NavigationComponentProps.d.ts.map +1 -0
- package/lib/typescript/interfaces/NavigationFunctionComponent.d.ts +7 -0
- package/lib/typescript/interfaces/NavigationFunctionComponent.d.ts.map +1 -0
- package/lib/typescript/interfaces/Options.d.ts +1738 -0
- package/lib/typescript/interfaces/Options.d.ts.map +1 -0
- package/lib/typescript/interfaces/ProcessorSubscription.d.ts +4 -0
- package/lib/typescript/interfaces/ProcessorSubscription.d.ts.map +1 -0
- package/lib/typescript/interfaces/Processors.d.ts +9 -0
- package/lib/typescript/interfaces/Processors.d.ts.map +1 -0
- package/lib/typescript/linking/DeferredLinkQueue.d.ts +26 -0
- package/lib/typescript/linking/DeferredLinkQueue.d.ts.map +1 -0
- package/lib/typescript/linking/DeferredLinkQueue.test.d.ts +2 -0
- package/lib/typescript/linking/DeferredLinkQueue.test.d.ts.map +1 -0
- package/lib/typescript/linking/LinkingHandler.d.ts +71 -0
- package/lib/typescript/linking/LinkingHandler.d.ts.map +1 -0
- package/lib/typescript/linking/LinkingHandler.test.d.ts +2 -0
- package/lib/typescript/linking/LinkingHandler.test.d.ts.map +1 -0
- package/lib/typescript/linking/ModalLayoutBuilder.d.ts +21 -0
- package/lib/typescript/linking/ModalLayoutBuilder.d.ts.map +1 -0
- package/lib/typescript/linking/ModalLayoutBuilder.test.d.ts +2 -0
- package/lib/typescript/linking/ModalLayoutBuilder.test.d.ts.map +1 -0
- package/lib/typescript/linking/RouteMatcher.d.ts +23 -0
- package/lib/typescript/linking/RouteMatcher.d.ts.map +1 -0
- package/lib/typescript/linking/RouteMatcher.test.d.ts +2 -0
- package/lib/typescript/linking/RouteMatcher.test.d.ts.map +1 -0
- package/lib/typescript/linking/URLParser.d.ts +16 -0
- package/lib/typescript/linking/URLParser.d.ts.map +1 -0
- package/lib/typescript/linking/URLParser.test.d.ts +2 -0
- package/lib/typescript/linking/URLParser.test.d.ts.map +1 -0
- package/lib/typescript/linking/types.d.ts +107 -0
- package/lib/typescript/linking/types.d.ts.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/processors/LayoutProcessor.d.ts +9 -0
- package/lib/typescript/processors/LayoutProcessor.d.ts.map +1 -0
- package/lib/typescript/processors/LayoutProcessor.test.d.ts +2 -0
- package/lib/typescript/processors/LayoutProcessor.test.d.ts.map +1 -0
- package/lib/typescript/processors/LayoutProcessorsStore.d.ts +9 -0
- package/lib/typescript/processors/LayoutProcessorsStore.d.ts.map +1 -0
- package/lib/typescript/processors/LayoutProcessorsStore.test.d.ts +2 -0
- package/lib/typescript/processors/LayoutProcessorsStore.test.d.ts.map +1 -0
- package/lib/typescript/processors/OptionProcessorsStore.d.ts +9 -0
- package/lib/typescript/processors/OptionProcessorsStore.d.ts.map +1 -0
- package/lib/typescript/processors/OptionProcessorsStore.test.d.ts +2 -0
- package/lib/typescript/processors/OptionProcessorsStore.test.d.ts.map +1 -0
- package/lib/typescript/types.d.ts +5 -0
- package/lib/typescript/types.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Application.d.ts +30 -0
- package/lib/typescript/typescript/Mock/Application.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/ComponentProps.d.ts +6 -0
- package/lib/typescript/typescript/Mock/ComponentProps.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/BottomTabs.d.ts +47 -0
- package/lib/typescript/typescript/Mock/Components/BottomTabs.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/ComponentScreen.d.ts +29 -0
- package/lib/typescript/typescript/Mock/Components/ComponentScreen.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/LayoutComponent.d.ts +47 -0
- package/lib/typescript/typescript/Mock/Components/LayoutComponent.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/Modals.d.ts +47 -0
- package/lib/typescript/typescript/Mock/Components/Modals.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/NavigationButton.d.ts +58 -0
- package/lib/typescript/typescript/Mock/Components/NavigationButton.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/Overlays.d.ts +47 -0
- package/lib/typescript/typescript/Mock/Components/Overlays.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/SideMenu.d.ts +179 -0
- package/lib/typescript/typescript/Mock/Components/SideMenu.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/Stack.d.ts +47 -0
- package/lib/typescript/typescript/Mock/Components/Stack.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Components/TopBar.d.ts +37 -0
- package/lib/typescript/typescript/Mock/Components/TopBar.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/BottomTabsNode.d.ts +9 -0
- package/lib/typescript/typescript/Mock/Layouts/BottomTabsNode.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/ComponentNode.d.ts +16 -0
- package/lib/typescript/typescript/Mock/Layouts/ComponentNode.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/LayoutNodeFactory.d.ts +9 -0
- package/lib/typescript/typescript/Mock/Layouts/LayoutNodeFactory.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/Node.d.ts +16 -0
- package/lib/typescript/typescript/Mock/Layouts/Node.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/ParentNode.d.ts +21 -0
- package/lib/typescript/typescript/Mock/Layouts/ParentNode.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/SideMenu.d.ts +32 -0
- package/lib/typescript/typescript/Mock/Layouts/SideMenu.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Layouts/StackNode.d.ts +6 -0
- package/lib/typescript/typescript/Mock/Layouts/StackNode.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Stores/EventsStore.d.ts +22 -0
- package/lib/typescript/typescript/Mock/Stores/EventsStore.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/Stores/LayoutStore.d.ts +2 -0
- package/lib/typescript/typescript/Mock/Stores/LayoutStore.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/actions/layoutActions.d.ts +6 -0
- package/lib/typescript/typescript/Mock/actions/layoutActions.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/connect.d.ts +2 -0
- package/lib/typescript/typescript/Mock/connect.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/constants.d.ts +3 -0
- package/lib/typescript/typescript/Mock/constants.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/index.d.ts +4 -0
- package/lib/typescript/typescript/Mock/index.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/mocks/AppRegistryService.d.ts +5 -0
- package/lib/typescript/typescript/Mock/mocks/AppRegistryService.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/mocks/NativeCommandsSender.d.ts +28 -0
- package/lib/typescript/typescript/Mock/mocks/NativeCommandsSender.d.ts.map +1 -0
- package/lib/typescript/typescript/Mock/mocks/NativeEventsReceiver.d.ts +21 -0
- package/lib/typescript/typescript/Mock/mocks/NativeEventsReceiver.d.ts.map +1 -0
- package/lib/typescript/typescript/Navigation.d.ts +152 -0
- package/lib/typescript/typescript/Navigation.d.ts.map +1 -0
- package/lib/typescript/typescript/NavigationDelegate.d.ts +128 -0
- package/lib/typescript/typescript/NavigationDelegate.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/AndroidCustomRowForwarder.d.ts +23 -0
- package/lib/typescript/typescript/adapters/AndroidCustomRowForwarder.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/AppRegistryService.d.ts +5 -0
- package/lib/typescript/typescript/adapters/AppRegistryService.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/AssetResolver.d.ts +5 -0
- package/lib/typescript/typescript/adapters/AssetResolver.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/ColorService.d.ts +4 -0
- package/lib/typescript/typescript/adapters/ColorService.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/Constants.d.ts +17 -0
- package/lib/typescript/typescript/adapters/Constants.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/NativeCommandsSender.d.ts +62 -0
- package/lib/typescript/typescript/adapters/NativeCommandsSender.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/NativeEventsReceiver.d.ts +23 -0
- package/lib/typescript/typescript/adapters/NativeEventsReceiver.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/NativeEventsReceiver.mock.d.ts +2 -0
- package/lib/typescript/typescript/adapters/NativeEventsReceiver.mock.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/NativeRNNTurboEventEmitter.d.ts +8 -0
- package/lib/typescript/typescript/adapters/NativeRNNTurboEventEmitter.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/NativeRNNTurboModule.d.ts +28 -0
- package/lib/typescript/typescript/adapters/NativeRNNTurboModule.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/TouchablePreview.d.ts +44 -0
- package/lib/typescript/typescript/adapters/TouchablePreview.d.ts.map +1 -0
- package/lib/typescript/typescript/adapters/UniqueIdProvider.d.ts +4 -0
- package/lib/typescript/typescript/adapters/UniqueIdProvider.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/Commands.d.ts +41 -0
- package/lib/typescript/typescript/commands/Commands.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/Commands.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/Commands.test.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/Deprecations.d.ts +10 -0
- package/lib/typescript/typescript/commands/Deprecations.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutTreeCrawler.d.ts +25 -0
- package/lib/typescript/typescript/commands/LayoutTreeCrawler.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutTreeCrawler.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/LayoutTreeCrawler.test.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutTreeParser.d.ts +17 -0
- package/lib/typescript/typescript/commands/LayoutTreeParser.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutTreeParser.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/LayoutTreeParser.test.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutType.d.ts +13 -0
- package/lib/typescript/typescript/commands/LayoutType.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/LayoutType.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/LayoutType.test.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/OptionsCrawler.d.ts +20 -0
- package/lib/typescript/typescript/commands/OptionsCrawler.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/OptionsCrawler.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/OptionsCrawler.test.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/OptionsProcessor.d.ts +40 -0
- package/lib/typescript/typescript/commands/OptionsProcessor.d.ts.map +1 -0
- package/lib/typescript/typescript/commands/OptionsProcessor.test.d.ts +2 -0
- package/lib/typescript/typescript/commands/OptionsProcessor.test.d.ts.map +1 -0
- package/lib/typescript/typescript/components/ComponentRegistry.d.ts +14 -0
- package/lib/typescript/typescript/components/ComponentRegistry.d.ts.map +1 -0
- package/lib/typescript/typescript/components/ComponentRegistry.test.d.ts +2 -0
- package/lib/typescript/typescript/components/ComponentRegistry.test.d.ts.map +1 -0
- package/lib/typescript/typescript/components/ComponentWrapper.d.ts +13 -0
- package/lib/typescript/typescript/components/ComponentWrapper.d.ts.map +1 -0
- package/lib/typescript/typescript/components/ComponentWrapper.test.d.ts +2 -0
- package/lib/typescript/typescript/components/ComponentWrapper.test.d.ts.map +1 -0
- package/lib/typescript/typescript/components/Modal.d.ts +21 -0
- package/lib/typescript/typescript/components/Modal.d.ts.map +1 -0
- package/lib/typescript/typescript/components/Store.d.ts +27 -0
- package/lib/typescript/typescript/components/Store.d.ts.map +1 -0
- package/lib/typescript/typescript/components/Store.test.d.ts +2 -0
- package/lib/typescript/typescript/components/Store.test.d.ts.map +1 -0
- package/lib/typescript/typescript/events/CommandsObserver.d.ts +11 -0
- package/lib/typescript/typescript/events/CommandsObserver.d.ts.map +1 -0
- package/lib/typescript/typescript/events/CommandsObserver.test.d.ts +2 -0
- package/lib/typescript/typescript/events/CommandsObserver.test.d.ts.map +1 -0
- package/lib/typescript/typescript/events/ComponentEventsObserver.d.ts +29 -0
- package/lib/typescript/typescript/events/ComponentEventsObserver.d.ts.map +1 -0
- package/lib/typescript/typescript/events/ComponentEventsObserver.test.d.ts +2 -0
- package/lib/typescript/typescript/events/ComponentEventsObserver.test.d.ts.map +1 -0
- package/lib/typescript/typescript/events/EventsRegistry.d.ts +34 -0
- package/lib/typescript/typescript/events/EventsRegistry.d.ts.map +1 -0
- package/lib/typescript/typescript/events/EventsRegistry.test.d.ts +2 -0
- package/lib/typescript/typescript/events/EventsRegistry.test.d.ts.map +1 -0
- package/lib/typescript/typescript/index.d.ts +19 -0
- package/lib/typescript/typescript/index.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/CommandName.d.ts +19 -0
- package/lib/typescript/typescript/interfaces/CommandName.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/ComponentEvents.d.ts +43 -0
- package/lib/typescript/typescript/interfaces/ComponentEvents.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/EventSubscription.d.ts +4 -0
- package/lib/typescript/typescript/interfaces/EventSubscription.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/Events.d.ts +16 -0
- package/lib/typescript/typescript/interfaces/Events.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/Layout.d.ts +190 -0
- package/lib/typescript/typescript/interfaces/Layout.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/NavigationComponent.d.ts +22 -0
- package/lib/typescript/typescript/interfaces/NavigationComponent.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/NavigationComponentListener.d.ts +14 -0
- package/lib/typescript/typescript/interfaces/NavigationComponentListener.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/NavigationComponentProps.d.ts +11 -0
- package/lib/typescript/typescript/interfaces/NavigationComponentProps.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/NavigationFunctionComponent.d.ts +7 -0
- package/lib/typescript/typescript/interfaces/NavigationFunctionComponent.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/Options.d.ts +1738 -0
- package/lib/typescript/typescript/interfaces/Options.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/ProcessorSubscription.d.ts +4 -0
- package/lib/typescript/typescript/interfaces/ProcessorSubscription.d.ts.map +1 -0
- package/lib/typescript/typescript/interfaces/Processors.d.ts +9 -0
- package/lib/typescript/typescript/interfaces/Processors.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/DeferredLinkQueue.d.ts +26 -0
- package/lib/typescript/typescript/linking/DeferredLinkQueue.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/DeferredLinkQueue.test.d.ts +2 -0
- package/lib/typescript/typescript/linking/DeferredLinkQueue.test.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/LinkingHandler.d.ts +71 -0
- package/lib/typescript/typescript/linking/LinkingHandler.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/LinkingHandler.test.d.ts +2 -0
- package/lib/typescript/typescript/linking/LinkingHandler.test.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/ModalLayoutBuilder.d.ts +21 -0
- package/lib/typescript/typescript/linking/ModalLayoutBuilder.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/ModalLayoutBuilder.test.d.ts +2 -0
- package/lib/typescript/typescript/linking/ModalLayoutBuilder.test.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/RouteMatcher.d.ts +23 -0
- package/lib/typescript/typescript/linking/RouteMatcher.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/RouteMatcher.test.d.ts +2 -0
- package/lib/typescript/typescript/linking/RouteMatcher.test.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/URLParser.d.ts +16 -0
- package/lib/typescript/typescript/linking/URLParser.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/URLParser.test.d.ts +2 -0
- package/lib/typescript/typescript/linking/URLParser.test.d.ts.map +1 -0
- package/lib/typescript/typescript/linking/types.d.ts +107 -0
- package/lib/typescript/typescript/linking/types.d.ts.map +1 -0
- package/lib/typescript/typescript/package.json +1 -0
- package/lib/typescript/typescript/processors/LayoutProcessor.d.ts +9 -0
- package/lib/typescript/typescript/processors/LayoutProcessor.d.ts.map +1 -0
- package/lib/typescript/typescript/processors/LayoutProcessor.test.d.ts +2 -0
- package/lib/typescript/typescript/processors/LayoutProcessor.test.d.ts.map +1 -0
- package/lib/typescript/typescript/processors/LayoutProcessorsStore.d.ts +9 -0
- package/lib/typescript/typescript/processors/LayoutProcessorsStore.d.ts.map +1 -0
- package/lib/typescript/typescript/processors/LayoutProcessorsStore.test.d.ts +2 -0
- package/lib/typescript/typescript/processors/LayoutProcessorsStore.test.d.ts.map +1 -0
- package/lib/typescript/typescript/processors/OptionProcessorsStore.d.ts +9 -0
- package/lib/typescript/typescript/processors/OptionProcessorsStore.d.ts.map +1 -0
- package/lib/typescript/typescript/processors/OptionProcessorsStore.test.d.ts +2 -0
- package/lib/typescript/typescript/processors/OptionProcessorsStore.test.d.ts.map +1 -0
- package/lib/typescript/typescript/types.d.ts +5 -0
- package/lib/typescript/typescript/types.d.ts.map +1 -0
- package/package.json +56 -0
- package/scripts/setup-esm-shim.js +102 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2016 Wix.com
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
[](https://vshymanskyy.github.io/StandWithUkraine)
|
|
2
|
+
|
|
3
|
+
<h1 align="center">
|
|
4
|
+
<img src=".logo.png"/><br/>
|
|
5
|
+
React Native Navigation
|
|
6
|
+
</h1>
|
|
7
|
+
|
|
8
|
+
<p align="center">
|
|
9
|
+
<a href="https://www.npmjs.com/package/react-native-navigation"><img src="https://img.shields.io/npm/dw/react-native-navigation.svg?style=flat-square" alt="NPM downloads"></a>
|
|
10
|
+
<a href="https://www.npmjs.com/package/react-native-navigation"><img src="https://img.shields.io/npm/v/react-native-navigation/latest.svg?style=flat-square" alt="NPM latest version"></a>
|
|
11
|
+
<a href="https://www.npmjs.com/package/react-native-navigation"><img src="https://img.shields.io/npm/v/react-native-navigation/snapshot.svg?style=flat-square" alt="NPM snapshot version"></a>
|
|
12
|
+
<a href="https://jenkins-oss.wixpress.com/job/multi-react-native-navigation-master/"><img src="https://img.shields.io/jenkins/s/http/jenkins-oss.wixpress.com:8080/job/multi-react-native-navigation-master.svg?style=flat-square" alt="NPM snapshot version"></a>
|
|
13
|
+
|
|
14
|
+
</p>
|
|
15
|
+
<p align="center">
|
|
16
|
+
<a href="https://twitter.com/reactnativenav"><img src="https://img.shields.io/twitter/follow/reactnativenav.svg?style=flat-square&colorA=1da1f2&colorB=&label=Follow%20us%20on%20Twitter" alt="Follow on Twitter"></a>
|
|
17
|
+
<a href="https://discord.gg/DhkZjq2"><img src="https://img.shields.io/discord/242515947020222464.svg?color=%237289da&label=Chat%20on%20Discrd&style=flat-square" alt="Chat on Discord"></a>
|
|
18
|
+
<a href="https://stackoverflow.com/questions/tagged/wix-react-native-navigation"><img src="https://img.shields.io/stackexchange/stackoverflow/t/wix-react-native-navigation.svg?style=flat-square" alt="StackExchange"></a>
|
|
19
|
+
</p>
|
|
20
|
+
|
|
21
|
+
React Native Navigation provides 100% native platform navigation on both iOS and Android for React Native apps. The JavaScript API is simple and cross-platform - just install it in your app and give your users the native feel they deserve. Ready to get started? Check out the [docs](https://wix.github.io/react-native-navigation/).
|
|
22
|
+
|
|
23
|
+
# Quick Links
|
|
24
|
+
|
|
25
|
+
- [Documentation](https://wix.github.io/react-native-navigation/)
|
|
26
|
+
- [Changelog](https://github.com/wix/react-native-navigation/blob/master/CHANGELOG.md)
|
|
27
|
+
- [Stack Overflow](http://stackoverflow.com/questions/tagged/wix-react-native-navigation)
|
|
28
|
+
- [Chat with us](https://discord.gg/DhkZjq2)
|
|
29
|
+
- [Contributing](https://wix.github.io/react-native-navigation/docs/meta-contributing)
|
|
30
|
+
|
|
31
|
+
# Requirements
|
|
32
|
+
|
|
33
|
+
Apps using React Native Navigation may target iOS 11 and Android 5.0 (API 21). You may use Windows, macOS or Linux as your development operating system.
|
|
34
|
+
|
|
35
|
+
# Installation
|
|
36
|
+
|
|
37
|
+
As `react-native-navigation` is a native navigation library - integrating it into your app will require editing native files. Follow the installation guides in the [documentation](https://wix.github.io/react-native-navigation/).
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
package com.reactnativenavigation.viewcontrollers.statusbar
|
|
2
|
+
|
|
3
|
+
import android.animation.Animator
|
|
4
|
+
import android.app.Activity
|
|
5
|
+
import android.graphics.Color
|
|
6
|
+
import android.view.View
|
|
7
|
+
import android.view.Window
|
|
8
|
+
import com.reactnativenavigation.RNNFeatureToggles.isEnabled
|
|
9
|
+
import com.reactnativenavigation.RNNToggles
|
|
10
|
+
import com.reactnativenavigation.options.Options
|
|
11
|
+
import com.reactnativenavigation.options.StatusBarOptions
|
|
12
|
+
import com.reactnativenavigation.options.StatusBarOptions.TextColorScheme
|
|
13
|
+
import com.reactnativenavigation.options.params.Bool
|
|
14
|
+
import com.reactnativenavigation.utils.ColorUtils.isColorLight
|
|
15
|
+
import com.reactnativenavigation.utils.StubAnimationListener.Companion.onAnimatorEnd
|
|
16
|
+
import com.reactnativenavigation.utils.SystemUiUtils.clearStatusBarTranslucency
|
|
17
|
+
import com.reactnativenavigation.utils.SystemUiUtils.getStatusBarColor
|
|
18
|
+
import com.reactnativenavigation.utils.SystemUiUtils.hideStatusBar
|
|
19
|
+
import com.reactnativenavigation.utils.SystemUiUtils.isTranslucent
|
|
20
|
+
import com.reactnativenavigation.utils.SystemUiUtils.setStatusBarColor
|
|
21
|
+
import com.reactnativenavigation.utils.SystemUiUtils.setStatusBarColorScheme
|
|
22
|
+
import com.reactnativenavigation.utils.SystemUiUtils.setStatusBarTranslucent
|
|
23
|
+
import com.reactnativenavigation.utils.SystemUiUtils.showStatusBar
|
|
24
|
+
import com.reactnativenavigation.viewcontrollers.viewcontroller.StatusBarColorAnimator
|
|
25
|
+
import com.reactnativenavigation.viewcontrollers.viewcontroller.ViewController
|
|
26
|
+
import java.lang.ref.WeakReference
|
|
27
|
+
|
|
28
|
+
class StatusBarPresenter private constructor(
|
|
29
|
+
activity: Activity,
|
|
30
|
+
private val sbColorAnimator: StatusBarColorAnimator = StatusBarColorAnimator(activity)) {
|
|
31
|
+
|
|
32
|
+
private val window = WeakReference(activity.window)
|
|
33
|
+
private var hasPendingColorAnim = false
|
|
34
|
+
|
|
35
|
+
fun applyOptions(viewController: ViewController<*>, options: StatusBarOptions) {
|
|
36
|
+
if (!hasPendingColorAnim) {
|
|
37
|
+
setStatusBarBackgroundColor(options)
|
|
38
|
+
setTranslucent(options)
|
|
39
|
+
}
|
|
40
|
+
setTextColorScheme(options)
|
|
41
|
+
setStatusBarVisible(viewController, options.visible)
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
fun mergeOptions(view: View, statusBar: StatusBarOptions) {
|
|
45
|
+
mergeStatusBarBackgroundColor(statusBar)
|
|
46
|
+
mergeTextColorScheme(statusBar)
|
|
47
|
+
mergeTranslucent(statusBar)
|
|
48
|
+
mergeStatusBarVisible(view, statusBar.visible)
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
fun onConfigurationChanged(options: StatusBarOptions) {
|
|
52
|
+
setStatusBarBackgroundColor(options)
|
|
53
|
+
setTextColorScheme(options)
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
fun bindViewController(newOptions: StatusBarOptions) {
|
|
57
|
+
if (!isEnabled(RNNToggles.TOP_BAR_COLOR_ANIMATION__TABS)) {
|
|
58
|
+
return
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
if (newOptions.backgroundColor.canApplyValue()) {
|
|
62
|
+
val currentColor = getCurrentStatusBarBackgroundColor() ?: return
|
|
63
|
+
val newColor = getStatusBarBackgroundColor(newOptions)
|
|
64
|
+
createStatusBarColorAnimation(
|
|
65
|
+
from = currentColor,
|
|
66
|
+
to = newColor,
|
|
67
|
+
translucent = newOptions.translucent.isTrue,
|
|
68
|
+
).start()
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
fun getStatusBarPushAnimation(appearingOptions: Options): Animator? =
|
|
73
|
+
if (isEnabled(RNNToggles.TOP_BAR_COLOR_ANIMATION__PUSH)) {
|
|
74
|
+
getStatusBarColorAnimation(appearingOptions.statusBar)
|
|
75
|
+
} else null
|
|
76
|
+
|
|
77
|
+
fun getStatusBarPopAnimation(appearingOptions: Options, disappearingOptions: Options): Animator? =
|
|
78
|
+
if (isEnabled(RNNToggles.TOP_BAR_COLOR_ANIMATION__PUSH)) {
|
|
79
|
+
getStatusBarColorAnimation(appearingOptions.statusBar)
|
|
80
|
+
} else null
|
|
81
|
+
|
|
82
|
+
private fun setStatusBarBackgroundColor(statusBar: StatusBarOptions) {
|
|
83
|
+
if (statusBar.backgroundColor.canApplyValue()) {
|
|
84
|
+
val statusBarBackgroundColor: Int = getStatusBarBackgroundColor(statusBar)
|
|
85
|
+
setStatusBarBackgroundColor(statusBarBackgroundColor, statusBar.translucent.isTrue)
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
private fun setStatusBarBackgroundColor(color: Int, translucent: Boolean) {
|
|
90
|
+
setStatusBarColor(window.get(), color, translucent)
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
private fun getStatusBarBackgroundColor(statusBar: StatusBarOptions): Int {
|
|
94
|
+
val defaultColor =
|
|
95
|
+
if (statusBar.visible.isTrueOrUndefined) Color.BLACK else Color.TRANSPARENT
|
|
96
|
+
return statusBar.backgroundColor.get(defaultColor)!!
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
private fun setTextColorScheme(statusBar: StatusBarOptions) {
|
|
100
|
+
val view = window.get()?.decorView
|
|
101
|
+
//View.post is a Workaround, added to solve internal Samsung
|
|
102
|
+
//Android 9 issues. For more info see https://github.com/wix/react-native-navigation/pull/7231
|
|
103
|
+
view?.post {
|
|
104
|
+
setStatusBarColorScheme(
|
|
105
|
+
window.get(),
|
|
106
|
+
view,
|
|
107
|
+
isDarkTextColorScheme(statusBar)
|
|
108
|
+
)
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
private fun setTranslucent(options: StatusBarOptions) {
|
|
113
|
+
val window = window.get()
|
|
114
|
+
if (options.translucent.isTrue) {
|
|
115
|
+
setStatusBarTranslucent(window)
|
|
116
|
+
} else if (isTranslucent(window)) {
|
|
117
|
+
clearStatusBarTranslucency(window)
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
private fun setStatusBarVisible(viewController: ViewController<*>, visible: Bool) {
|
|
122
|
+
val window = window.get() ?: return
|
|
123
|
+
val view = if (viewController.view != null) viewController.view else window.decorView
|
|
124
|
+
if (visible.isFalse) {
|
|
125
|
+
hideStatusBar(window, view)
|
|
126
|
+
} else {
|
|
127
|
+
showStatusBar(window, view)
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
private fun mergeStatusBarBackgroundColor(statusBar: StatusBarOptions) {
|
|
132
|
+
if (statusBar.backgroundColor.hasValue()) {
|
|
133
|
+
val statusBarBackgroundColor = getStatusBarBackgroundColor(statusBar)
|
|
134
|
+
setStatusBarColor(
|
|
135
|
+
window.get(), statusBarBackgroundColor,
|
|
136
|
+
statusBar.translucent.isTrue
|
|
137
|
+
)
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
private fun mergeTextColorScheme(statusBar: StatusBarOptions) {
|
|
142
|
+
if (!statusBar.textColorScheme.hasValue()) return
|
|
143
|
+
setTextColorScheme(statusBar)
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
private fun mergeTranslucent(options: StatusBarOptions) {
|
|
147
|
+
val window: Window = window.get() ?: return
|
|
148
|
+
if (options.translucent.isTrue) {
|
|
149
|
+
setStatusBarTranslucent(window)
|
|
150
|
+
} else if (options.translucent.isFalse && isTranslucent(window)) {
|
|
151
|
+
clearStatusBarTranslucency(window)
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
private fun mergeStatusBarVisible(view: View, visible: Bool) {
|
|
156
|
+
if (visible.hasValue()) {
|
|
157
|
+
if (visible.isTrue) {
|
|
158
|
+
showStatusBar(window.get(), view)
|
|
159
|
+
} else {
|
|
160
|
+
hideStatusBar(window.get(), view)
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
private fun isDarkTextColorScheme(statusBar: StatusBarOptions): Boolean {
|
|
166
|
+
if (statusBar.textColorScheme == TextColorScheme.Dark) {
|
|
167
|
+
return true
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
if (statusBar.textColorScheme == TextColorScheme.Light) {
|
|
171
|
+
return false
|
|
172
|
+
}
|
|
173
|
+
return isColorLight(getStatusBarBackgroundColor(statusBar))
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
private fun getStatusBarColorAnimation(statusBarOptions: StatusBarOptions): Animator? {
|
|
177
|
+
if (isEnabled(RNNToggles.TOP_BAR_COLOR_ANIMATION__TABS)) {
|
|
178
|
+
getCurrentStatusBarBackgroundColor()?.let { currentColor ->
|
|
179
|
+
val targetColor = statusBarOptions.backgroundColor
|
|
180
|
+
|
|
181
|
+
if (targetColor.hasValue()) {
|
|
182
|
+
val translucent = statusBarOptions.translucent.isTrue
|
|
183
|
+
return createStatusBarColorAnimation(
|
|
184
|
+
from = currentColor,
|
|
185
|
+
to = targetColor.get(),
|
|
186
|
+
translucent = translucent,
|
|
187
|
+
)
|
|
188
|
+
}
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
return null
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
private fun createStatusBarColorAnimation(from: Int, to: Int, translucent: Boolean): Animator =
|
|
195
|
+
sbColorAnimator.getAnimator(from, to, translucent).apply {
|
|
196
|
+
addListener(onAnimatorEnd {
|
|
197
|
+
hasPendingColorAnim = false
|
|
198
|
+
})
|
|
199
|
+
hasPendingColorAnim = true
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
private fun getCurrentStatusBarBackgroundColor() =
|
|
203
|
+
getStatusBarColor(window.get())
|
|
204
|
+
|
|
205
|
+
companion object {
|
|
206
|
+
lateinit var instance: StatusBarPresenter
|
|
207
|
+
|
|
208
|
+
fun init(activity: Activity) {
|
|
209
|
+
instance = StatusBarPresenter(activity)
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
}
|
|
@@ -0,0 +1,331 @@
|
|
|
1
|
+
# JavaScript/TypeScript Architecture
|
|
2
|
+
|
|
3
|
+
The JavaScript layer provides the public API and orchestrates communication between React components and native navigation implementations.
|
|
4
|
+
|
|
5
|
+
## Entry Point
|
|
6
|
+
|
|
7
|
+
`index.ts` exports the `Navigation` singleton (a `NavigationDelegate` instance) along with re-exports from `Modal`, `EventsRegistry`, `Constants`, and all interfaces. Applications use `Navigation.*` for commands and `Navigation.events().*` for event subscriptions.
|
|
8
|
+
|
|
9
|
+
## Module Structure
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
src/
|
|
13
|
+
├── index.ts # Main entry point, exports Navigation singleton
|
|
14
|
+
├── Navigation.ts # NavigationRoot - core orchestrator
|
|
15
|
+
├── NavigationDelegate.ts # Public API facade
|
|
16
|
+
├── adapters/ # Native bridge layer
|
|
17
|
+
├── commands/ # Command processing
|
|
18
|
+
├── components/ # React component management
|
|
19
|
+
├── events/ # Event system
|
|
20
|
+
├── interfaces/ # TypeScript type definitions
|
|
21
|
+
├── linking/ # Deep-linking framework (URL → command)
|
|
22
|
+
└── processors/ # Extensibility hooks
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## Core Classes
|
|
26
|
+
|
|
27
|
+
### NavigationDelegate (Public API)
|
|
28
|
+
**File**: `NavigationDelegate.ts`
|
|
29
|
+
|
|
30
|
+
Facade providing the public `Navigation` API. All methods proxy to `NavigationRoot`.
|
|
31
|
+
|
|
32
|
+
```typescript
|
|
33
|
+
// Usage
|
|
34
|
+
import { Navigation } from 'react-native-navigation';
|
|
35
|
+
Navigation.setRoot({ root: { stack: { children: [...] } } });
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
### NavigationRoot (Core Orchestrator)
|
|
39
|
+
**File**: `Navigation.ts`
|
|
40
|
+
|
|
41
|
+
Coordinates all subsystems. Constructed with dependencies:
|
|
42
|
+
- `NativeCommandsSender` - sends commands to native
|
|
43
|
+
- `NativeEventsReceiver` - receives events from native
|
|
44
|
+
- `AppRegistryService` - manages React Native component registry
|
|
45
|
+
|
|
46
|
+
Initializes and coordinates:
|
|
47
|
+
- `Store` - component instance & props storage
|
|
48
|
+
- `ComponentRegistry` - component registration
|
|
49
|
+
- `LayoutTreeParser` - converts layouts to internal nodes
|
|
50
|
+
- `LayoutTreeCrawler` - processes layout trees
|
|
51
|
+
- `Commands` - command execution
|
|
52
|
+
- `EventsRegistry` - event subscriptions
|
|
53
|
+
- `OptionsProcessor` - option processing
|
|
54
|
+
- `LayoutProcessor` - layout transformations
|
|
55
|
+
|
|
56
|
+
## Adapters Layer
|
|
57
|
+
|
|
58
|
+
Bridge between JavaScript and native/React Native APIs.
|
|
59
|
+
|
|
60
|
+
| Adapter | Purpose |
|
|
61
|
+
|---------|---------|
|
|
62
|
+
| `NativeCommandsSender` | Wraps TurboModule for command dispatch |
|
|
63
|
+
| `NativeEventsReceiver` | Wraps NativeEventEmitter for events |
|
|
64
|
+
| `NativeRNNTurboModule` | TurboModule spec interface |
|
|
65
|
+
| `NativeRNNTurboEventEmitter` | TurboModule event emitter spec |
|
|
66
|
+
| `UniqueIdProvider` | Generates unique component/command IDs |
|
|
67
|
+
| `ColorService` | Converts colors to native format |
|
|
68
|
+
| `AssetResolver` | Resolves require() image assets (class: AssetService) |
|
|
69
|
+
| `AppRegistryService` | Registers components with React Native |
|
|
70
|
+
| `Constants` | Platform dimension constants |
|
|
71
|
+
| `TouchablePreview` | 3D Touch / Haptic preview handling |
|
|
72
|
+
|
|
73
|
+
## Commands Layer
|
|
74
|
+
|
|
75
|
+
### Commands Class
|
|
76
|
+
**File**: `commands/Commands.ts`
|
|
77
|
+
|
|
78
|
+
Central command dispatcher. Each navigation command:
|
|
79
|
+
1. Validates input
|
|
80
|
+
2. Processes layout through pipeline
|
|
81
|
+
3. Sends to native via adapter
|
|
82
|
+
4. Returns promise with result
|
|
83
|
+
|
|
84
|
+
### Processing Pipeline
|
|
85
|
+
|
|
86
|
+
The pipeline executes in this exact order:
|
|
87
|
+
|
|
88
|
+
```
|
|
89
|
+
Input Layout (from API)
|
|
90
|
+
↓
|
|
91
|
+
1. OptionsCrawler.crawl() # Extract static options from component classes
|
|
92
|
+
↓
|
|
93
|
+
2. LayoutProcessor.process() # Apply registered layout processors
|
|
94
|
+
↓
|
|
95
|
+
3. LayoutTreeParser.parse() # Convert to internal LayoutNode tree
|
|
96
|
+
↓
|
|
97
|
+
4. LayoutTreeCrawler.crawl() # Process options, save props to Store
|
|
98
|
+
↓
|
|
99
|
+
5. OptionsProcessor (during crawl) # Resolve colors, assets, custom processors
|
|
100
|
+
↓
|
|
101
|
+
6. NativeCommandsSender # Send to native module
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
### LayoutNode (Internal Tree)
|
|
105
|
+
```typescript
|
|
106
|
+
interface LayoutNode {
|
|
107
|
+
id: string; // Unique identifier
|
|
108
|
+
type: LayoutType; // Component|Stack|BottomTabs|etc
|
|
109
|
+
data: {
|
|
110
|
+
name?: string; // Component name
|
|
111
|
+
options?: any; // Processed options
|
|
112
|
+
passProps?: any; // Component props (cleared before native)
|
|
113
|
+
};
|
|
114
|
+
children: LayoutNode[];
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
### LayoutType Enum
|
|
119
|
+
```typescript
|
|
120
|
+
enum LayoutType {
|
|
121
|
+
Component = 'Component',
|
|
122
|
+
Stack = 'Stack',
|
|
123
|
+
BottomTabs = 'BottomTabs',
|
|
124
|
+
SideMenuRoot = 'SideMenuRoot',
|
|
125
|
+
SideMenuCenter = 'SideMenuCenter',
|
|
126
|
+
SideMenuLeft = 'SideMenuLeft',
|
|
127
|
+
SideMenuRight = 'SideMenuRight',
|
|
128
|
+
TopTabs = 'TopTabs',
|
|
129
|
+
ExternalComponent = 'ExternalComponent',
|
|
130
|
+
SplitView = 'SplitView',
|
|
131
|
+
}
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
## Components Layer
|
|
135
|
+
|
|
136
|
+
### ComponentRegistry
|
|
137
|
+
**File**: `components/ComponentRegistry.ts`
|
|
138
|
+
|
|
139
|
+
Manages React component registration and wrapping.
|
|
140
|
+
|
|
141
|
+
```typescript
|
|
142
|
+
Navigation.registerComponent('ScreenName', () => MyComponent);
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
### ComponentWrapper
|
|
146
|
+
**File**: `components/ComponentWrapper.tsx`
|
|
147
|
+
|
|
148
|
+
Higher-order component that:
|
|
149
|
+
- Wraps original component with lifecycle management
|
|
150
|
+
- Stores instance in `Store` for event dispatch
|
|
151
|
+
- Injects `componentId` and `componentName` props
|
|
152
|
+
|
|
153
|
+
### Store
|
|
154
|
+
**File**: `components/Store.ts`
|
|
155
|
+
|
|
156
|
+
Centralized storage for:
|
|
157
|
+
- `componentsByName` - registered component providers
|
|
158
|
+
- `componentsInstancesById` - mounted component instances
|
|
159
|
+
- `propsById` - static props by component ID
|
|
160
|
+
- `pendingPropsById` - props awaiting component mount
|
|
161
|
+
- `wrappedComponents` - cached wrapped components
|
|
162
|
+
- `lazyRegistratorFn` - function for lazy component registration
|
|
163
|
+
|
|
164
|
+
## Events Layer
|
|
165
|
+
|
|
166
|
+
### EventsRegistry
|
|
167
|
+
**File**: `events/EventsRegistry.ts`
|
|
168
|
+
|
|
169
|
+
Public API for event subscriptions:
|
|
170
|
+
|
|
171
|
+
```typescript
|
|
172
|
+
Navigation.events().registerComponentDidAppearListener(({ componentId }) => {});
|
|
173
|
+
Navigation.events().registerCommandCompletedListener(({ commandId }) => {});
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
### ComponentEventsObserver
|
|
177
|
+
**File**: `events/ComponentEventsObserver.ts`
|
|
178
|
+
|
|
179
|
+
Dispatches events to component instance methods:
|
|
180
|
+
- `componentWillAppear()`
|
|
181
|
+
- `componentDidAppear()`
|
|
182
|
+
- `componentDidDisappear()`
|
|
183
|
+
- `navigationButtonPressed()`
|
|
184
|
+
- `screenPopped()`
|
|
185
|
+
|
|
186
|
+
### CommandsObserver
|
|
187
|
+
**File**: `events/CommandsObserver.ts`
|
|
188
|
+
|
|
189
|
+
Notifies listeners of command lifecycle (start, complete).
|
|
190
|
+
|
|
191
|
+
## Events (Native → JS)
|
|
192
|
+
|
|
193
|
+
| Event | Description |
|
|
194
|
+
|-------|-------------|
|
|
195
|
+
| `RNN.AppLaunched` | App initialization complete |
|
|
196
|
+
| `RNN.ComponentWillAppear` | Component about to appear |
|
|
197
|
+
| `RNN.ComponentDidAppear` | Component now visible |
|
|
198
|
+
| `RNN.ComponentDidDisappear` | Component hidden |
|
|
199
|
+
| `RNN.NavigationButtonPressed` | TopBar button tapped |
|
|
200
|
+
| `RNN.BottomTabPressed` | Tab pressed (even if selected) |
|
|
201
|
+
| `RNN.BottomTabSelected` | Tab selection changed |
|
|
202
|
+
| `RNN.BottomTabLongPressed` | Tab long-pressed |
|
|
203
|
+
| `RNN.ModalDismissed` | Modal was dismissed |
|
|
204
|
+
| `RNN.ModalAttemptedToDismiss` | Swipe-to-dismiss attempted |
|
|
205
|
+
| `RNN.ScreenPopped` | Screen removed from stack |
|
|
206
|
+
| `RNN.SearchBarUpdated` | Search text changed |
|
|
207
|
+
| `RNN.SearchBarCancelPressed` | Search cancelled |
|
|
208
|
+
| `RNN.PreviewCompleted` | 3D Touch preview completed |
|
|
209
|
+
| `RNN.CommandCompleted` | Navigation command finished |
|
|
210
|
+
|
|
211
|
+
## Linking Layer
|
|
212
|
+
|
|
213
|
+
Implements URL-to-screen routing on top of the standard command pipeline. The whole feature is JS-only; it consumes URLs from RN's `Linking` module and dispatches `showModal` (or a user-supplied command) when a match is found.
|
|
214
|
+
|
|
215
|
+
**Public surface** (proxied through `NavigationDelegate`):
|
|
216
|
+
- `Navigation.setLinking(config)` — configure prefixes, screen map, and customization hooks
|
|
217
|
+
- `Navigation.handleDeepLink(url)` — manually feed a URL (push notifications, branch.io, App Clips)
|
|
218
|
+
- `Navigation.setLinkingReady(ready)` — user-controlled gate for deferred deep links
|
|
219
|
+
|
|
220
|
+
**Internal modules** (`src/linking/`):
|
|
221
|
+
|
|
222
|
+
| File | Purpose |
|
|
223
|
+
|------|---------|
|
|
224
|
+
| `LinkingHandler.ts` | Orchestrator. Subscribes to `Linking.url`/`getInitialURL`, drives the queue, dispatches matches. Instantiated by `NavigationRoot`. |
|
|
225
|
+
| `URLParser.ts` | Strips prefix (longest match), removes fragment, decodes path segments + query params. |
|
|
226
|
+
| `RouteMatcher.ts` | Compiles `ScreensConfig` into a `RouteNode` tree; matches paths to screen chains with parameter extraction. |
|
|
227
|
+
| `DeferredLinkQueue.ts` | FIFO queue. Holds URLs until both gates open (root-ready + user-ready). |
|
|
228
|
+
| `ModalLayoutBuilder.ts` | Default presentation: wraps the matched chain in a `stack`, merges params into `passProps`, filters React-reserved keys (`ref`, `key`). |
|
|
229
|
+
| `types.ts` | Public types: `LinkingConfig`, `RouteMatch`, `ScreensConfig`, etc. (re-exported via `src/index.ts`). |
|
|
230
|
+
|
|
231
|
+
**Readiness gates** — a URL is dispatched only when both are true:
|
|
232
|
+
1. **Root-ready** (automatic): the first `Navigation.setRoot()` has resolved. `NavigationRoot.setRoot` calls `linkingHandler.setRootReady()` after the promise resolves.
|
|
233
|
+
2. **User-ready** (optional): `config.isReady()` returns `true`, or `setLinkingReady(true)` was called.
|
|
234
|
+
|
|
235
|
+
**Resolution priority** when a match is found:
|
|
236
|
+
1. `config.onLink(match)` — full escape hatch, RNN does nothing else
|
|
237
|
+
2. `config.getModal(match)` — custom modal layout
|
|
238
|
+
3. Default `ModalLayoutBuilder` output
|
|
239
|
+
|
|
240
|
+
## Processors Layer
|
|
241
|
+
|
|
242
|
+
### OptionProcessorsStore
|
|
243
|
+
**File**: `processors/OptionProcessorsStore.ts`
|
|
244
|
+
|
|
245
|
+
Registers custom option processors:
|
|
246
|
+
|
|
247
|
+
```typescript
|
|
248
|
+
Navigation.addOptionProcessor('topBar.title.text', (value, commandName) => {
|
|
249
|
+
return value.toUpperCase(); // Transform all titles
|
|
250
|
+
});
|
|
251
|
+
```
|
|
252
|
+
|
|
253
|
+
### LayoutProcessorsStore
|
|
254
|
+
**File**: `processors/LayoutProcessorsStore.ts`
|
|
255
|
+
|
|
256
|
+
Registers layout transformers:
|
|
257
|
+
|
|
258
|
+
```typescript
|
|
259
|
+
Navigation.addLayoutProcessor((layout, commandName) => {
|
|
260
|
+
// Add default options to all components
|
|
261
|
+
return layout;
|
|
262
|
+
});
|
|
263
|
+
```
|
|
264
|
+
|
|
265
|
+
## Interfaces
|
|
266
|
+
|
|
267
|
+
### Layout Types
|
|
268
|
+
**File**: `interfaces/Layout.ts`
|
|
269
|
+
|
|
270
|
+
```typescript
|
|
271
|
+
interface LayoutRoot {
|
|
272
|
+
root: Layout;
|
|
273
|
+
modals?: any[];
|
|
274
|
+
overlays?: any[];
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
type Layout = {
|
|
278
|
+
component?: LayoutComponent;
|
|
279
|
+
stack?: LayoutStack;
|
|
280
|
+
bottomTabs?: LayoutBottomTabs;
|
|
281
|
+
sideMenu?: LayoutSideMenu;
|
|
282
|
+
splitView?: LayoutSplitView;
|
|
283
|
+
topTabs?: LayoutTopTabs;
|
|
284
|
+
externalComponent?: ExternalComponent;
|
|
285
|
+
}
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
### Options Interface
|
|
289
|
+
**File**: `interfaces/Options.ts` (comprehensive)
|
|
290
|
+
|
|
291
|
+
Contains all configuration options for:
|
|
292
|
+
- Status bar, navigation bars
|
|
293
|
+
- Top bar (buttons, title, search)
|
|
294
|
+
- Bottom tabs
|
|
295
|
+
- Side menus
|
|
296
|
+
- Modals, overlays
|
|
297
|
+
- Animations
|
|
298
|
+
- Layout parameters
|
|
299
|
+
|
|
300
|
+
### NavigationComponent
|
|
301
|
+
**File**: `interfaces/NavigationComponent.ts`
|
|
302
|
+
|
|
303
|
+
Base class for navigation-aware components:
|
|
304
|
+
|
|
305
|
+
```typescript
|
|
306
|
+
class MyScreen extends NavigationComponent<Props> {
|
|
307
|
+
static options: Options = { ... };
|
|
308
|
+
|
|
309
|
+
componentDidAppear(event) { }
|
|
310
|
+
navigationButtonPressed(event) { }
|
|
311
|
+
}
|
|
312
|
+
```
|
|
313
|
+
|
|
314
|
+
## Dependencies
|
|
315
|
+
|
|
316
|
+
**Production**:
|
|
317
|
+
- `lodash` - utility functions
|
|
318
|
+
- `hoist-non-react-statics` - HOC support
|
|
319
|
+
- `react-lifecycles-compat` - lifecycle polyfill
|
|
320
|
+
- `tslib` - TypeScript helpers
|
|
321
|
+
|
|
322
|
+
**Peer**:
|
|
323
|
+
- `react`, `react-native` (required)
|
|
324
|
+
- `remx` (optional state management)
|
|
325
|
+
|
|
326
|
+
## Build Output
|
|
327
|
+
|
|
328
|
+
Uses `react-native-builder-bob`:
|
|
329
|
+
- **Source**: `src/`
|
|
330
|
+
- **Output**: `lib/`
|
|
331
|
+
- **Targets**: ESM modules + TypeScript declarations
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
import { connect } from "./connect.js";
|
|
6
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
7
|
+
export const Application = connect(class extends React.Component {
|
|
8
|
+
constructor(props) {
|
|
9
|
+
super(props);
|
|
10
|
+
props.entryPoint();
|
|
11
|
+
}
|
|
12
|
+
render() {
|
|
13
|
+
const {
|
|
14
|
+
LayoutComponent
|
|
15
|
+
} = require('./Components/LayoutComponent');
|
|
16
|
+
const {
|
|
17
|
+
LayoutStore
|
|
18
|
+
} = require('./Stores/LayoutStore');
|
|
19
|
+
const {
|
|
20
|
+
Modals
|
|
21
|
+
} = require('./Components/Modals');
|
|
22
|
+
const {
|
|
23
|
+
Overlays
|
|
24
|
+
} = require('./Components/Overlays');
|
|
25
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
26
|
+
testID: 'Application',
|
|
27
|
+
children: [/*#__PURE__*/_jsx(LayoutComponent, {
|
|
28
|
+
layoutNode: LayoutStore.getLayout()
|
|
29
|
+
}), /*#__PURE__*/_jsx(Modals, {}), /*#__PURE__*/_jsx(Overlays, {})]
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
//# sourceMappingURL=Application.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","View","connect","jsx","_jsx","jsxs","_jsxs","Application","Component","constructor","props","entryPoint","render","LayoutComponent","require","LayoutStore","Modals","Overlays","testID","children","layoutNode","getLayout"],"sourceRoot":"../../../src","sources":["Mock/Application.tsx"],"mappings":";;AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,OAAO,QAAQ,cAAW;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAMpC,OAAO,MAAMC,WAAW,GAAGL,OAAO,CAChC,cAAcF,KAAK,CAACQ,SAAS,CAAmB;EAC9CC,WAAWA,CAACC,KAAuB,EAAE;IACnC,KAAK,CAACA,KAAK,CAAC;IACZA,KAAK,CAACC,UAAU,CAAC,CAAC;EACpB;EAEAC,MAAMA,CAAA,EAAG;IACP,MAAM;MAAEC;IAAgB,CAAC,GAAGC,OAAO,CAAC,8BAA8B,CAAC;IACnE,MAAM;MAAEC;IAAY,CAAC,GAAGD,OAAO,CAAC,sBAAsB,CAAC;IACvD,MAAM;MAAEE;IAAO,CAAC,GAAGF,OAAO,CAAC,qBAAqB,CAAC;IACjD,MAAM;MAAEG;IAAS,CAAC,GAAGH,OAAO,CAAC,uBAAuB,CAAC;IACrD,oBACER,KAAA,CAACL,IAAI;MAACiB,MAAM,EAAE,aAAc;MAAAC,QAAA,gBAC1Bf,IAAA,CAACS,eAAe;QAACO,UAAU,EAAEL,WAAW,CAACM,SAAS,CAAC;MAAE,CAAE,CAAC,eACxDjB,IAAA,CAACY,MAAM,IAAE,CAAC,eACVZ,IAAA,CAACa,QAAQ,IAAE,CAAC;IAAA,CACR,CAAC;EAEX;AACF,CACF,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../src","sources":["Mock/ComponentProps.tsx"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { Component } from 'react';
|
|
4
|
+
import { LayoutComponent } from "./LayoutComponent.js";
|
|
5
|
+
import { connect } from "../connect.js";
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
export const BottomTabs = connect(class extends Component {
|
|
8
|
+
render() {
|
|
9
|
+
return this.props.layoutNode.children.map(child => {
|
|
10
|
+
return /*#__PURE__*/_jsx(LayoutComponent, {
|
|
11
|
+
layoutNode: child
|
|
12
|
+
}, child.nodeId);
|
|
13
|
+
});
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
//# sourceMappingURL=BottomTabs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","Component","LayoutComponent","connect","jsx","_jsx","BottomTabs","render","props","layoutNode","children","map","child","nodeId"],"sourceRoot":"../../../../src","sources":["Mock/Components/BottomTabs.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,SAAS,QAAQ,OAAO;AACxC,SAASC,eAAe,QAAQ,sBAAmB;AAEnD,SAASC,OAAO,QAAQ,eAAY;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAErC,OAAO,MAAMC,UAAU,GAAGH,OAAO,CAC/B,cAAcF,SAAS,CAAiB;EACtCM,MAAMA,CAAA,EAAG;IACP,OAAO,IAAI,CAACC,KAAK,CAACC,UAAU,CAACC,QAAQ,CAACC,GAAG,CAAEC,KAAK,IAAK;MACnD,oBAAOP,IAAA,CAACH,eAAe;QAAoBO,UAAU,EAAEG;MAAM,GAAhCA,KAAK,CAACC,MAA4B,CAAC;IAClE,CAAC,CAAC;EACJ;AACF,CACF,CAAC","ignoreList":[]}
|