@nascentdigital/funnel-apps 4.4.18
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/dist/react/app/domain/AppService.d.ts +19 -0
- package/dist/react/app/domain/AppService.js +19 -0
- package/dist/react/app/domain/AppServiceClient.d.ts +7 -0
- package/dist/react/app/domain/AppServiceClient.js +57 -0
- package/dist/react/app/domain/AppState.d.ts +1 -0
- package/dist/react/app/domain/AppState.js +2 -0
- package/dist/react/app/domain/index.d.ts +3 -0
- package/dist/react/app/domain/index.js +19 -0
- package/dist/react/app/server/AbstractAppService.d.ts +17 -0
- package/dist/react/app/server/AbstractAppService.js +24 -0
- package/dist/react/app/server/AppServices.d.ts +11 -0
- package/dist/react/app/server/AppServices.js +92 -0
- package/dist/react/app/server/index.d.ts +4 -0
- package/dist/react/app/server/index.js +20 -0
- package/dist/react/app/web/App.d.ts +38 -0
- package/dist/react/app/web/App.js +116 -0
- package/dist/react/app/web/AppContainer.d.ts +16 -0
- package/dist/react/app/web/AppContainer.js +109 -0
- package/dist/react/app/web/AppContext.d.ts +7 -0
- package/dist/react/app/web/AppContext.js +6 -0
- package/dist/react/app/web/AppLayout.d.ts +7 -0
- package/dist/react/app/web/AppLayout.js +34 -0
- package/dist/react/app/web/AppPage.d.ts +13 -0
- package/dist/react/app/web/AppPage.js +30 -0
- package/dist/react/app/web/AppRoot.d.ts +7 -0
- package/dist/react/app/web/AppRoot.js +43 -0
- package/dist/react/app/web/index.d.ts +5 -0
- package/dist/react/app/web/index.js +21 -0
- package/dist/react/app/web/useApp.d.ts +2 -0
- package/dist/react/app/web/useApp.js +33 -0
- package/dist/react/auth0/server/Auth0IdentityService.d.ts +25 -0
- package/dist/react/auth0/server/Auth0IdentityService.js +84 -0
- package/dist/react/auth0/server/Auth0Profile.d.ts +19 -0
- package/dist/react/auth0/server/Auth0Profile.js +108 -0
- package/dist/react/auth0/server/Auth0ProfileFactory.d.ts +15 -0
- package/dist/react/auth0/server/Auth0ProfileFactory.js +51 -0
- package/dist/react/auth0/server/Auth0ProfileManagementService.d.ts +17 -0
- package/dist/react/auth0/server/Auth0ProfileManagementService.js +127 -0
- package/dist/react/auth0/server/Auth0ProfileServices.d.ts +13 -0
- package/dist/react/auth0/server/Auth0ProfileServices.js +19 -0
- package/dist/react/auth0/server/Auth0ProfileStore.d.ts +17 -0
- package/dist/react/auth0/server/Auth0ProfileStore.js +83 -0
- package/dist/react/auth0/server/Auth0ProfileUserService.d.ts +16 -0
- package/dist/react/auth0/server/Auth0ProfileUserService.js +48 -0
- package/dist/react/auth0/server/index.d.ts +4 -0
- package/dist/react/auth0/server/index.js +20 -0
- package/dist/react/auth0/web/Auth0IdentityClient.d.ts +34 -0
- package/dist/react/auth0/web/Auth0IdentityClient.js +200 -0
- package/dist/react/auth0/web/Auth0IdentityClientProvider.d.ts +35 -0
- package/dist/react/auth0/web/Auth0IdentityClientProvider.js +67 -0
- package/dist/react/auth0/web/index.d.ts +1 -0
- package/dist/react/auth0/web/index.js +17 -0
- package/dist/react/bridge/core/BridgeConnection.d.ts +6 -0
- package/dist/react/bridge/core/BridgeConnection.js +2 -0
- package/dist/react/bridge/core/BridgeConstants.d.ts +7 -0
- package/dist/react/bridge/core/BridgeConstants.js +15 -0
- package/dist/react/bridge/core/BridgeEvent.d.ts +52 -0
- package/dist/react/bridge/core/BridgeEvent.js +28 -0
- package/dist/react/bridge/core/BridgeMethod.d.ts +12 -0
- package/dist/react/bridge/core/BridgeMethod.js +2 -0
- package/dist/react/bridge/core/BridgeMethodCall.d.ts +23 -0
- package/dist/react/bridge/core/BridgeMethodCall.js +37 -0
- package/dist/react/bridge/core/BridgeMethods.d.ts +35 -0
- package/dist/react/bridge/core/BridgeMethods.js +2 -0
- package/dist/react/bridge/core/BridgeState.d.ts +24 -0
- package/dist/react/bridge/core/BridgeState.js +2 -0
- package/dist/react/bridge/core/index.d.ts +7 -0
- package/dist/react/bridge/core/index.js +23 -0
- package/dist/react/bridge/web/Bridge.d.ts +32 -0
- package/dist/react/bridge/web/Bridge.js +183 -0
- package/dist/react/bridge/web/BridgeContext.d.ts +8 -0
- package/dist/react/bridge/web/BridgeContext.js +6 -0
- package/dist/react/bridge/web/BridgeGlobals.d.ts +12 -0
- package/dist/react/bridge/web/BridgeGlobals.js +2 -0
- package/dist/react/bridge/web/BridgeProvider.d.ts +7 -0
- package/dist/react/bridge/web/BridgeProvider.js +36 -0
- package/dist/react/bridge/web/index.d.ts +6 -0
- package/dist/react/bridge/web/index.js +22 -0
- package/dist/react/bridge/web/useBridge.d.ts +3 -0
- package/dist/react/bridge/web/useBridge.js +39 -0
- package/dist/react/bridge/web/useBridgeState.d.ts +2 -0
- package/dist/react/bridge/web/useBridgeState.js +43 -0
- package/dist/react/bridge/web/useSafeArea.d.ts +1 -0
- package/dist/react/bridge/web/useSafeArea.js +11 -0
- package/dist/react/content/core/AppContentClient.d.ts +14 -0
- package/dist/react/content/core/AppContentClient.js +51 -0
- package/dist/react/content/core/ContentClientContext.d.ts +7 -0
- package/dist/react/content/core/ContentClientContext.js +6 -0
- package/dist/react/content/core/index.d.ts +1 -0
- package/dist/react/content/core/index.js +17 -0
- package/dist/react/content/domain/ContentAppRequest.d.ts +20 -0
- package/dist/react/content/domain/ContentAppRequest.js +11 -0
- package/dist/react/content/domain/index.d.ts +1 -0
- package/dist/react/content/domain/index.js +17 -0
- package/dist/react/content/server/ContentAppService.d.ts +11 -0
- package/dist/react/content/server/ContentAppService.js +34 -0
- package/dist/react/content/server/index.d.ts +1 -0
- package/dist/react/content/server/index.js +17 -0
- package/dist/react/content/web/ContentProvider.d.ts +5 -0
- package/dist/react/content/web/ContentProvider.js +17 -0
- package/dist/react/content/web/index.d.ts +6 -0
- package/dist/react/content/web/index.js +22 -0
- package/dist/react/content/web/useCollection.d.ts +10 -0
- package/dist/react/content/web/useCollection.js +22 -0
- package/dist/react/content/web/useCollections.d.ts +10 -0
- package/dist/react/content/web/useCollections.js +32 -0
- package/dist/react/content/web/useContentClient.d.ts +1 -0
- package/dist/react/content/web/useContentClient.js +9 -0
- package/dist/react/cookies/web/CookieService.d.ts +25 -0
- package/dist/react/cookies/web/CookieService.js +45 -0
- package/dist/react/cookies/web/CookieServiceContext.d.ts +7 -0
- package/dist/react/cookies/web/CookieServiceContext.js +6 -0
- package/dist/react/cookies/web/CookieServiceProvider.d.ts +6 -0
- package/dist/react/cookies/web/CookieServiceProvider.js +16 -0
- package/dist/react/cookies/web/index.d.ts +3 -0
- package/dist/react/cookies/web/index.js +19 -0
- package/dist/react/cookies/web/useCookieService.d.ts +2 -0
- package/dist/react/cookies/web/useCookieService.js +29 -0
- package/dist/react/identity/core/AbstractIdentityClient.d.ts +22 -0
- package/dist/react/identity/core/AbstractIdentityClient.js +31 -0
- package/dist/react/identity/core/IdentityClient.d.ts +22 -0
- package/dist/react/identity/core/IdentityClient.js +13 -0
- package/dist/react/identity/core/IdentityClientContext.d.ts +7 -0
- package/dist/react/identity/core/IdentityClientContext.js +6 -0
- package/dist/react/identity/core/index.d.ts +6 -0
- package/dist/react/identity/core/index.js +22 -0
- package/dist/react/identity/core/useIdentity.d.ts +10 -0
- package/dist/react/identity/core/useIdentity.js +39 -0
- package/dist/react/identity/core/useIdentityClient.d.ts +2 -0
- package/dist/react/identity/core/useIdentityClient.js +17 -0
- package/dist/react/identity/domain/AnonymousIdentity.d.ts +15 -0
- package/dist/react/identity/domain/AnonymousIdentity.js +27 -0
- package/dist/react/identity/domain/AuthenticatedIdentity.d.ts +25 -0
- package/dist/react/identity/domain/AuthenticatedIdentity.js +32 -0
- package/dist/react/identity/domain/Identity.d.ts +6 -0
- package/dist/react/identity/domain/Identity.js +2 -0
- package/dist/react/identity/domain/IdentityAppRequest.d.ts +8 -0
- package/dist/react/identity/domain/IdentityAppRequest.js +10 -0
- package/dist/react/identity/domain/index.d.ts +4 -0
- package/dist/react/identity/domain/index.js +20 -0
- package/dist/react/identity/server/IdentityAppService.d.ts +9 -0
- package/dist/react/identity/server/IdentityAppService.js +32 -0
- package/dist/react/identity/server/IdentityService.d.ts +17 -0
- package/dist/react/identity/server/IdentityService.js +25 -0
- package/dist/react/identity/server/index.d.ts +4 -0
- package/dist/react/identity/server/index.js +20 -0
- package/dist/react/identity/web/WebIdentityClientProvider.d.ts +8 -0
- package/dist/react/identity/web/WebIdentityClientProvider.js +27 -0
- package/dist/react/identity/web/WebIdentityProvider.d.ts +5 -0
- package/dist/react/identity/web/WebIdentityProvider.js +21 -0
- package/dist/react/identity/web/bridge/AppBridgeIdentityClient.d.ts +14 -0
- package/dist/react/identity/web/bridge/AppBridgeIdentityClient.js +47 -0
- package/dist/react/identity/web/bridge/AppBridgeIdentityClientProvider.d.ts +2 -0
- package/dist/react/identity/web/bridge/AppBridgeIdentityClientProvider.js +28 -0
- package/dist/react/identity/web/bridge/index.d.ts +1 -0
- package/dist/react/identity/web/bridge/index.js +17 -0
- package/dist/react/identity/web/index.d.ts +3 -0
- package/dist/react/identity/web/index.js +19 -0
- package/dist/react/nav/core/SpecSourceContext.d.ts +7 -0
- package/dist/react/nav/core/SpecSourceContext.js +6 -0
- package/dist/react/nav/core/index.d.ts +2 -0
- package/dist/react/nav/core/index.js +18 -0
- package/dist/react/nav/core/useSpec.d.ts +3 -0
- package/dist/react/nav/core/useSpec.js +30 -0
- package/dist/react/nav/domain/Icon.d.ts +2 -0
- package/dist/react/nav/domain/Icon.js +2 -0
- package/dist/react/nav/domain/Modal.d.ts +25 -0
- package/dist/react/nav/domain/Modal.js +28 -0
- package/dist/react/nav/domain/Navigation.d.ts +13 -0
- package/dist/react/nav/domain/Navigation.js +2 -0
- package/dist/react/nav/domain/NavigationCommand.d.ts +14 -0
- package/dist/react/nav/domain/NavigationCommand.js +2 -0
- package/dist/react/nav/domain/Route.d.ts +12 -0
- package/dist/react/nav/domain/Route.js +2 -0
- package/dist/react/nav/domain/Routes.d.ts +6 -0
- package/dist/react/nav/domain/Routes.js +74 -0
- package/dist/react/nav/domain/Screen.d.ts +24 -0
- package/dist/react/nav/domain/Screen.js +28 -0
- package/dist/react/nav/domain/Skeleton.d.ts +26 -0
- package/dist/react/nav/domain/Skeleton.js +2 -0
- package/dist/react/nav/domain/Spec.d.ts +33 -0
- package/dist/react/nav/domain/Spec.js +124 -0
- package/dist/react/nav/domain/SpecSource.d.ts +21 -0
- package/dist/react/nav/domain/SpecSource.js +28 -0
- package/dist/react/nav/domain/Stack.d.ts +35 -0
- package/dist/react/nav/domain/Stack.js +44 -0
- package/dist/react/nav/domain/Tabs.d.ts +37 -0
- package/dist/react/nav/domain/Tabs.js +45 -0
- package/dist/react/nav/domain/icons/ImageIcon.d.ts +2 -0
- package/dist/react/nav/domain/icons/ImageIcon.js +7 -0
- package/dist/react/nav/domain/icons/LucideIcon.d.ts +2 -0
- package/dist/react/nav/domain/icons/LucideIcon.js +7 -0
- package/dist/react/nav/domain/icons/index.d.ts +2 -0
- package/dist/react/nav/domain/icons/index.js +18 -0
- package/dist/react/nav/domain/index.d.ts +14 -0
- package/dist/react/nav/domain/index.js +30 -0
- package/dist/react/nav/domain/sources/AbstractSpecSource.d.ts +23 -0
- package/dist/react/nav/domain/sources/AbstractSpecSource.js +64 -0
- package/dist/react/nav/domain/sources/StaticSpecSource.d.ts +9 -0
- package/dist/react/nav/domain/sources/StaticSpecSource.js +16 -0
- package/dist/react/nav/domain/sources/index.d.ts +2 -0
- package/dist/react/nav/domain/sources/index.js +18 -0
- package/dist/react/nav/server/SpecService.d.ts +9 -0
- package/dist/react/nav/server/SpecService.js +31 -0
- package/dist/react/nav/server/exports.d.ts +1 -0
- package/dist/react/nav/server/exports.js +17 -0
- package/dist/react/nav/server/index.d.ts +2 -0
- package/dist/react/nav/server/index.js +38 -0
- package/dist/react/nav/web/WebSpecProvider.d.ts +2 -0
- package/dist/react/nav/web/WebSpecProvider.js +41 -0
- package/dist/react/nav/web/index.d.ts +3 -0
- package/dist/react/nav/web/index.js +19 -0
- package/dist/react/nav/web/navigator/NativeNavigator.d.ts +13 -0
- package/dist/react/nav/web/navigator/NativeNavigator.js +47 -0
- package/dist/react/nav/web/navigator/Navigator.d.ts +7 -0
- package/dist/react/nav/web/navigator/Navigator.js +2 -0
- package/dist/react/nav/web/navigator/NavigatorContext.d.ts +7 -0
- package/dist/react/nav/web/navigator/NavigatorContext.js +6 -0
- package/dist/react/nav/web/navigator/WebNavigator.d.ts +13 -0
- package/dist/react/nav/web/navigator/WebNavigator.js +38 -0
- package/dist/react/nav/web/navigator/index.d.ts +5 -0
- package/dist/react/nav/web/navigator/index.js +21 -0
- package/dist/react/nav/web/navigator/useNavigator.d.ts +1 -0
- package/dist/react/nav/web/navigator/useNavigator.js +17 -0
- package/dist/react/nav.d.ts +1 -0
- package/dist/react/nav.js +37 -0
- package/dist/react/profile/core/AbstractProfileClient.d.ts +18 -0
- package/dist/react/profile/core/AbstractProfileClient.js +31 -0
- package/dist/react/profile/core/ProfileClient.d.ts +21 -0
- package/dist/react/profile/core/ProfileClient.js +2 -0
- package/dist/react/profile/core/ProfileClientContext.d.ts +7 -0
- package/dist/react/profile/core/ProfileClientContext.js +6 -0
- package/dist/react/profile/core/index.d.ts +6 -0
- package/dist/react/profile/core/index.js +22 -0
- package/dist/react/profile/core/useProfile.d.ts +9 -0
- package/dist/react/profile/core/useProfile.js +47 -0
- package/dist/react/profile/core/useProfileClient.d.ts +2 -0
- package/dist/react/profile/core/useProfileClient.js +17 -0
- package/dist/react/profile/core/useProfileStore.d.ts +2 -0
- package/dist/react/profile/core/useProfileStore.js +28 -0
- package/dist/react/profile/domain/Profile.d.ts +80 -0
- package/dist/react/profile/domain/Profile.js +209 -0
- package/dist/react/profile/domain/ProfileAppRequest.d.ts +15 -0
- package/dist/react/profile/domain/ProfileAppRequest.js +12 -0
- package/dist/react/profile/domain/ProfileStore.d.ts +65 -0
- package/dist/react/profile/domain/ProfileStore.js +180 -0
- package/dist/react/profile/domain/index.d.ts +3 -0
- package/dist/react/profile/domain/index.js +19 -0
- package/dist/react/profile/server/ProfileAppService.d.ts +11 -0
- package/dist/react/profile/server/ProfileAppService.js +49 -0
- package/dist/react/profile/server/ProfileManagementService.d.ts +28 -0
- package/dist/react/profile/server/ProfileManagementService.js +3 -0
- package/dist/react/profile/server/ProfileServices.d.ts +22 -0
- package/dist/react/profile/server/ProfileServices.js +24 -0
- package/dist/react/profile/server/ProfileUserService.d.ts +5 -0
- package/dist/react/profile/server/ProfileUserService.js +2 -0
- package/dist/react/profile/server/index.d.ts +5 -0
- package/dist/react/profile/server/index.js +21 -0
- package/dist/react/profile/web/WebProfile.d.ts +11 -0
- package/dist/react/profile/web/WebProfile.js +37 -0
- package/dist/react/profile/web/WebProfileClient.d.ts +9 -0
- package/dist/react/profile/web/WebProfileClient.js +76 -0
- package/dist/react/profile/web/WebProfileProvider.d.ts +5 -0
- package/dist/react/profile/web/WebProfileProvider.js +62 -0
- package/dist/react/profile/web/WebProfileStore.d.ts +8 -0
- package/dist/react/profile/web/WebProfileStore.js +32 -0
- package/dist/react/profile/web/index.d.ts +3 -0
- package/dist/react/profile/web/index.js +19 -0
- package/dist/react/push/domain/PushAppRequest.d.ts +13 -0
- package/dist/react/push/domain/PushAppRequest.js +12 -0
- package/dist/react/push/domain/PushStore.d.ts +7 -0
- package/dist/react/push/domain/PushStore.js +9 -0
- package/dist/react/push/domain/index.d.ts +2 -0
- package/dist/react/push/domain/index.js +18 -0
- package/dist/react/push/server/PushService.d.ts +22 -0
- package/dist/react/push/server/PushService.js +57 -0
- package/dist/react/push/server/index.d.ts +3 -0
- package/dist/react/push/server/index.js +19 -0
- package/dist/react/push/server/keygen.d.ts +1 -0
- package/dist/react/push/server/keygen.js +8 -0
- package/dist/react/push/web/PushClient.d.ts +35 -0
- package/dist/react/push/web/PushClient.js +204 -0
- package/dist/react/push/web/PushContext.d.ts +7 -0
- package/dist/react/push/web/PushContext.js +6 -0
- package/dist/react/push/web/PushProvider.d.ts +6 -0
- package/dist/react/push/web/PushProvider.js +42 -0
- package/dist/react/push/web/index.d.ts +4 -0
- package/dist/react/push/web/index.js +20 -0
- package/dist/react/push/web/usePushClient.d.ts +3 -0
- package/dist/react/push/web/usePushClient.js +40 -0
- package/dist/react/server.d.ts +7 -0
- package/dist/react/server.js +23 -0
- package/dist/react/ui/web/HideSplash.d.ts +1 -0
- package/dist/react/ui/web/HideSplash.js +28 -0
- package/dist/react/ui/web/Link.d.ts +6 -0
- package/dist/react/ui/web/Link.js +12 -0
- package/dist/react/ui/web/SafeArea.d.ts +9 -0
- package/dist/react/ui/web/SafeArea.js +26 -0
- package/dist/react/ui/web/index.d.ts +3 -0
- package/dist/react/ui/web/index.js +19 -0
- package/dist/react/web.d.ts +10 -0
- package/dist/react/web.js +26 -0
- package/dist/reactnative/app/domain/AppService.d.ts +19 -0
- package/dist/reactnative/app/domain/AppService.js +19 -0
- package/dist/reactnative/app/domain/AppServiceClient.d.ts +7 -0
- package/dist/reactnative/app/domain/AppServiceClient.js +57 -0
- package/dist/reactnative/app/domain/AppState.d.ts +1 -0
- package/dist/reactnative/app/domain/AppState.js +2 -0
- package/dist/reactnative/app/domain/index.d.ts +3 -0
- package/dist/reactnative/app/domain/index.js +19 -0
- package/dist/reactnative/app/rn/AppContainer.d.ts +10 -0
- package/dist/reactnative/app/rn/AppContainer.js +77 -0
- package/dist/reactnative/app/rn/AppRoot.d.ts +5 -0
- package/dist/reactnative/app/rn/AppRoot.js +22 -0
- package/dist/reactnative/app/rn/AppServiceClient.d.ts +4 -0
- package/dist/reactnative/app/rn/AppServiceClient.js +44 -0
- package/dist/reactnative/app/rn/index.d.ts +5 -0
- package/dist/reactnative/app/rn/index.js +22 -0
- package/dist/reactnative/auth0/rn/Auth0IdentityClient.d.ts +33 -0
- package/dist/reactnative/auth0/rn/Auth0IdentityClient.js +234 -0
- package/dist/reactnative/auth0/rn/Auth0IdentityClientProvider.d.ts +27 -0
- package/dist/reactnative/auth0/rn/Auth0IdentityClientProvider.js +60 -0
- package/dist/reactnative/auth0/rn/index.d.ts +2 -0
- package/dist/reactnative/auth0/rn/index.js +18 -0
- package/dist/reactnative/bridge/core/BridgeConnection.d.ts +6 -0
- package/dist/reactnative/bridge/core/BridgeConnection.js +2 -0
- package/dist/reactnative/bridge/core/BridgeConstants.d.ts +7 -0
- package/dist/reactnative/bridge/core/BridgeConstants.js +15 -0
- package/dist/reactnative/bridge/core/BridgeEvent.d.ts +52 -0
- package/dist/reactnative/bridge/core/BridgeEvent.js +28 -0
- package/dist/reactnative/bridge/core/BridgeMethod.d.ts +12 -0
- package/dist/reactnative/bridge/core/BridgeMethod.js +2 -0
- package/dist/reactnative/bridge/core/BridgeMethodCall.d.ts +23 -0
- package/dist/reactnative/bridge/core/BridgeMethodCall.js +37 -0
- package/dist/reactnative/bridge/core/BridgeMethods.d.ts +35 -0
- package/dist/reactnative/bridge/core/BridgeMethods.js +2 -0
- package/dist/reactnative/bridge/core/BridgeState.d.ts +24 -0
- package/dist/reactnative/bridge/core/BridgeState.js +2 -0
- package/dist/reactnative/bridge/core/index.d.ts +7 -0
- package/dist/reactnative/bridge/core/index.js +23 -0
- package/dist/reactnative/bridge/rn/BridgeProxy.d.ts +35 -0
- package/dist/reactnative/bridge/rn/BridgeProxy.js +331 -0
- package/dist/reactnative/bridge/rn/BridgeProxyContext.d.ts +8 -0
- package/dist/reactnative/bridge/rn/BridgeProxyContext.js +6 -0
- package/dist/reactnative/bridge/rn/BridgeProxyProvider.d.ts +8 -0
- package/dist/reactnative/bridge/rn/BridgeProxyProvider.js +39 -0
- package/dist/reactnative/bridge/rn/BridgeWebview.d.ts +7 -0
- package/dist/reactnative/bridge/rn/BridgeWebview.js +51 -0
- package/dist/reactnative/bridge/rn/index.d.ts +7 -0
- package/dist/reactnative/bridge/rn/index.js +23 -0
- package/dist/reactnative/bridge/rn/useBridgeProxy.d.ts +3 -0
- package/dist/reactnative/bridge/rn/useBridgeProxy.js +38 -0
- package/dist/reactnative/bridge/rn/useBridgeProxyCalls.d.ts +3 -0
- package/dist/reactnative/bridge/rn/useBridgeProxyCalls.js +32 -0
- package/dist/reactnative/bridge/rn/useBridgeProxyState.d.ts +2 -0
- package/dist/reactnative/bridge/rn/useBridgeProxyState.js +46 -0
- package/dist/reactnative/identity/core/AbstractIdentityClient.d.ts +22 -0
- package/dist/reactnative/identity/core/AbstractIdentityClient.js +31 -0
- package/dist/reactnative/identity/core/IdentityClient.d.ts +22 -0
- package/dist/reactnative/identity/core/IdentityClient.js +13 -0
- package/dist/reactnative/identity/core/IdentityClientContext.d.ts +7 -0
- package/dist/reactnative/identity/core/IdentityClientContext.js +6 -0
- package/dist/reactnative/identity/core/index.d.ts +6 -0
- package/dist/reactnative/identity/core/index.js +22 -0
- package/dist/reactnative/identity/core/useIdentity.d.ts +10 -0
- package/dist/reactnative/identity/core/useIdentity.js +39 -0
- package/dist/reactnative/identity/core/useIdentityClient.d.ts +2 -0
- package/dist/reactnative/identity/core/useIdentityClient.js +17 -0
- package/dist/reactnative/identity/domain/AnonymousIdentity.d.ts +15 -0
- package/dist/reactnative/identity/domain/AnonymousIdentity.js +27 -0
- package/dist/reactnative/identity/domain/AuthenticatedIdentity.d.ts +25 -0
- package/dist/reactnative/identity/domain/AuthenticatedIdentity.js +32 -0
- package/dist/reactnative/identity/domain/Identity.d.ts +6 -0
- package/dist/reactnative/identity/domain/Identity.js +2 -0
- package/dist/reactnative/identity/domain/IdentityAppRequest.d.ts +8 -0
- package/dist/reactnative/identity/domain/IdentityAppRequest.js +10 -0
- package/dist/reactnative/identity/domain/index.d.ts +4 -0
- package/dist/reactnative/identity/domain/index.js +20 -0
- package/dist/reactnative/identity/rn/RNIdentityClientProvider.d.ts +8 -0
- package/dist/reactnative/identity/rn/RNIdentityClientProvider.js +22 -0
- package/dist/reactnative/identity/rn/RNIdentityProvider.d.ts +5 -0
- package/dist/reactnative/identity/rn/RNIdentityProvider.js +14 -0
- package/dist/reactnative/identity/rn/index.d.ts +3 -0
- package/dist/reactnative/identity/rn/index.js +19 -0
- package/dist/reactnative/nav/core/SpecSourceContext.d.ts +7 -0
- package/dist/reactnative/nav/core/SpecSourceContext.js +6 -0
- package/dist/reactnative/nav/core/index.d.ts +2 -0
- package/dist/reactnative/nav/core/index.js +18 -0
- package/dist/reactnative/nav/core/useSpec.d.ts +3 -0
- package/dist/reactnative/nav/core/useSpec.js +30 -0
- package/dist/reactnative/nav/domain/Icon.d.ts +2 -0
- package/dist/reactnative/nav/domain/Icon.js +2 -0
- package/dist/reactnative/nav/domain/Modal.d.ts +25 -0
- package/dist/reactnative/nav/domain/Modal.js +28 -0
- package/dist/reactnative/nav/domain/Navigation.d.ts +13 -0
- package/dist/reactnative/nav/domain/Navigation.js +2 -0
- package/dist/reactnative/nav/domain/NavigationCommand.d.ts +14 -0
- package/dist/reactnative/nav/domain/NavigationCommand.js +2 -0
- package/dist/reactnative/nav/domain/Route.d.ts +12 -0
- package/dist/reactnative/nav/domain/Route.js +2 -0
- package/dist/reactnative/nav/domain/Routes.d.ts +6 -0
- package/dist/reactnative/nav/domain/Routes.js +74 -0
- package/dist/reactnative/nav/domain/Screen.d.ts +24 -0
- package/dist/reactnative/nav/domain/Screen.js +28 -0
- package/dist/reactnative/nav/domain/Skeleton.d.ts +26 -0
- package/dist/reactnative/nav/domain/Skeleton.js +2 -0
- package/dist/reactnative/nav/domain/Spec.d.ts +33 -0
- package/dist/reactnative/nav/domain/Spec.js +124 -0
- package/dist/reactnative/nav/domain/SpecSource.d.ts +21 -0
- package/dist/reactnative/nav/domain/SpecSource.js +28 -0
- package/dist/reactnative/nav/domain/Stack.d.ts +35 -0
- package/dist/reactnative/nav/domain/Stack.js +44 -0
- package/dist/reactnative/nav/domain/Tabs.d.ts +37 -0
- package/dist/reactnative/nav/domain/Tabs.js +45 -0
- package/dist/reactnative/nav/domain/icons/ImageIcon.d.ts +2 -0
- package/dist/reactnative/nav/domain/icons/ImageIcon.js +7 -0
- package/dist/reactnative/nav/domain/icons/LucideIcon.d.ts +2 -0
- package/dist/reactnative/nav/domain/icons/LucideIcon.js +7 -0
- package/dist/reactnative/nav/domain/icons/index.d.ts +2 -0
- package/dist/reactnative/nav/domain/icons/index.js +18 -0
- package/dist/reactnative/nav/domain/index.d.ts +14 -0
- package/dist/reactnative/nav/domain/index.js +30 -0
- package/dist/reactnative/nav/domain/sources/AbstractSpecSource.d.ts +23 -0
- package/dist/reactnative/nav/domain/sources/AbstractSpecSource.js +64 -0
- package/dist/reactnative/nav/domain/sources/StaticSpecSource.d.ts +9 -0
- package/dist/reactnative/nav/domain/sources/StaticSpecSource.js +16 -0
- package/dist/reactnative/nav/domain/sources/index.d.ts +2 -0
- package/dist/reactnative/nav/domain/sources/index.js +18 -0
- package/dist/reactnative/nav/rn/NavigationEngine.d.ts +1 -0
- package/dist/reactnative/nav/rn/NavigationEngine.js +155 -0
- package/dist/reactnative/nav/rn/NavigationScreen.d.ts +9 -0
- package/dist/reactnative/nav/rn/NavigationScreen.js +215 -0
- package/dist/reactnative/nav/rn/RNSpecProvider.d.ts +2 -0
- package/dist/reactnative/nav/rn/RNSpecProvider.js +30 -0
- package/dist/reactnative/nav/rn/RNSpecSource.d.ts +5 -0
- package/dist/reactnative/nav/rn/RNSpecSource.js +30 -0
- package/dist/reactnative/nav/rn/index.d.ts +4 -0
- package/dist/reactnative/nav/rn/index.js +20 -0
- package/dist/reactnative/profile/domain/Profile.d.ts +80 -0
- package/dist/reactnative/profile/domain/Profile.js +209 -0
- package/dist/reactnative/profile/domain/ProfileAppRequest.d.ts +15 -0
- package/dist/reactnative/profile/domain/ProfileAppRequest.js +12 -0
- package/dist/reactnative/profile/domain/ProfileStore.d.ts +65 -0
- package/dist/reactnative/profile/domain/ProfileStore.js +180 -0
- package/dist/reactnative/profile/domain/index.d.ts +3 -0
- package/dist/reactnative/profile/domain/index.js +19 -0
- package/dist/reactnative/push/domain/PushAppRequest.d.ts +13 -0
- package/dist/reactnative/push/domain/PushAppRequest.js +12 -0
- package/dist/reactnative/push/domain/PushStore.d.ts +7 -0
- package/dist/reactnative/push/domain/PushStore.js +9 -0
- package/dist/reactnative/push/domain/index.d.ts +2 -0
- package/dist/reactnative/push/domain/index.js +18 -0
- package/dist/reactnative/push/rn/PushClient.d.ts +32 -0
- package/dist/reactnative/push/rn/PushClient.js +247 -0
- package/dist/reactnative/push/rn/PushContext.d.ts +7 -0
- package/dist/reactnative/push/rn/PushContext.js +6 -0
- package/dist/reactnative/push/rn/PushProvider.d.ts +2 -0
- package/dist/reactnative/push/rn/PushProvider.js +45 -0
- package/dist/reactnative/push/rn/index.d.ts +3 -0
- package/dist/reactnative/push/rn/index.js +19 -0
- package/dist/reactnative/push/rn/usePushClient.d.ts +3 -0
- package/dist/reactnative/push/rn/usePushClient.js +40 -0
- package/dist/reactnative/rn.d.ts +7 -0
- package/dist/reactnative/rn.js +23 -0
- package/dist/reactnative/ui/rn/Tailwind.d.ts +175 -0
- package/dist/reactnative/ui/rn/Tailwind.js +211 -0
- package/dist/reactnative/ui/rn/atomic/Button.d.ts +97 -0
- package/dist/reactnative/ui/rn/atomic/Button.js +75 -0
- package/dist/reactnative/ui/rn/atomic/TextField.d.ts +112 -0
- package/dist/reactnative/ui/rn/atomic/TextField.js +135 -0
- package/dist/reactnative/ui/rn/atomic/index.d.ts +2 -0
- package/dist/reactnative/ui/rn/atomic/index.js +18 -0
- package/dist/reactnative/ui/rn/index.d.ts +1 -0
- package/dist/reactnative/ui/rn/index.js +17 -0
- package/dist/styles/rn/_index.css +2 -0
- package/dist/styles/rn/atomic/Button.css +54 -0
- package/dist/styles/rn/atomic/TextField.css +77 -0
- package/dist/styles/rn/atomic/_index.css +2 -0
- package/dist/styles/rn/base/_index.css +1 -0
- package/dist/styles/rn/base/tailwind.css +3 -0
- package/dist/styles/rn.css +1 -0
- package/dist/styles/web/_index.css +1 -0
- package/dist/styles/web/layout/SafeArea.css +17 -0
- package/dist/styles/web/layout/_index.css +1 -0
- package/dist/styles/web.css +1 -0
- package/package.json +87 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
|
3
|
+
var t = {};
|
|
4
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
5
|
+
t[p] = s[p];
|
|
6
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
7
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
8
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
9
|
+
t[p[i]] = s[p[i]];
|
|
10
|
+
}
|
|
11
|
+
return t;
|
|
12
|
+
};
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.Tabs = void 0;
|
|
15
|
+
// class
|
|
16
|
+
class Tabs {
|
|
17
|
+
constructor(args) {
|
|
18
|
+
var _a;
|
|
19
|
+
this.__type = 'tabs';
|
|
20
|
+
// initialize instance variables
|
|
21
|
+
this.variant = (_a = args.variant) !== null && _a !== void 0 ? _a : 'bottom';
|
|
22
|
+
this.items = args.items;
|
|
23
|
+
}
|
|
24
|
+
toData() {
|
|
25
|
+
const { __type, variant, items } = this;
|
|
26
|
+
return {
|
|
27
|
+
__type,
|
|
28
|
+
variant,
|
|
29
|
+
items: Object.entries(items).reduce((data, [key, itemRaw]) => {
|
|
30
|
+
// transform item
|
|
31
|
+
const { content } = itemRaw, item = __rest(itemRaw, ["content"]);
|
|
32
|
+
data[key] = Object.assign(Object.assign({}, item), { content: content.toData() });
|
|
33
|
+
// keep reducing
|
|
34
|
+
return data;
|
|
35
|
+
}, {})
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
toJSON() {
|
|
39
|
+
return JSON.parse(JSON.stringify(this.toData()));
|
|
40
|
+
}
|
|
41
|
+
static create(args) {
|
|
42
|
+
return new Tabs(args);
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
exports.Tabs = Tabs;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./ImageIcon"), exports);
|
|
18
|
+
__exportStar(require("./LucideIcon"), exports);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export * from './icons';
|
|
2
|
+
export * from './sources';
|
|
3
|
+
export * from './Icon';
|
|
4
|
+
export * from './Modal';
|
|
5
|
+
export * from './Navigation';
|
|
6
|
+
export * from './NavigationCommand';
|
|
7
|
+
export * from './Route';
|
|
8
|
+
export * from './Routes';
|
|
9
|
+
export * from './Screen';
|
|
10
|
+
export * from './Skeleton';
|
|
11
|
+
export * from './Spec';
|
|
12
|
+
export * from './SpecSource';
|
|
13
|
+
export * from './Stack';
|
|
14
|
+
export * from './Tabs';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./icons"), exports);
|
|
18
|
+
__exportStar(require("./sources"), exports);
|
|
19
|
+
__exportStar(require("./Icon"), exports);
|
|
20
|
+
__exportStar(require("./Modal"), exports);
|
|
21
|
+
__exportStar(require("./Navigation"), exports);
|
|
22
|
+
__exportStar(require("./NavigationCommand"), exports);
|
|
23
|
+
__exportStar(require("./Route"), exports);
|
|
24
|
+
__exportStar(require("./Routes"), exports);
|
|
25
|
+
__exportStar(require("./Screen"), exports);
|
|
26
|
+
__exportStar(require("./Skeleton"), exports);
|
|
27
|
+
__exportStar(require("./Spec"), exports);
|
|
28
|
+
__exportStar(require("./SpecSource"), exports);
|
|
29
|
+
__exportStar(require("./Stack"), exports);
|
|
30
|
+
__exportStar(require("./Tabs"), exports);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Result } from '@nascentdigital/funnel-core';
|
|
2
|
+
import { BehaviorSubject, Observable } from 'rxjs';
|
|
3
|
+
import type { Navigation } from '../Navigation';
|
|
4
|
+
import type { Spec } from '../Spec';
|
|
5
|
+
import type { SpecSource } from '../SpecSource';
|
|
6
|
+
export declare abstract class AbstractSpecSource<TNavigation extends Navigation> implements SpecSource<TNavigation> {
|
|
7
|
+
protected readonly _result$: BehaviorSubject<Result<Spec<TNavigation>>>;
|
|
8
|
+
protected _syncing$: BehaviorSubject<boolean>;
|
|
9
|
+
protected constructor({ spec }?: AbstractSpecSource.ConstructorArgs<TNavigation>);
|
|
10
|
+
get result$(): Observable<Result<Spec<TNavigation>>>;
|
|
11
|
+
get result(): Result<Spec<TNavigation>>;
|
|
12
|
+
protected set result(result: Result<Spec<TNavigation>>);
|
|
13
|
+
syncing$(): Observable<boolean>;
|
|
14
|
+
get syncing(): boolean;
|
|
15
|
+
protected set syncing(syncing: boolean);
|
|
16
|
+
sync(args: SpecSource.Sync.Args): Promise<Result.Completion<Spec<TNavigation>>>;
|
|
17
|
+
protected abstract onSync(args: SpecSource.Sync.Args): Promise<Spec<TNavigation>>;
|
|
18
|
+
}
|
|
19
|
+
export declare namespace AbstractSpecSource {
|
|
20
|
+
type ConstructorArgs<TNavigation extends Navigation> = {
|
|
21
|
+
spec?: Spec<TNavigation>;
|
|
22
|
+
};
|
|
23
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AbstractSpecSource = void 0;
|
|
4
|
+
const funnel_core_1 = require("@nascentdigital/funnel-core");
|
|
5
|
+
const rxjs_1 = require("rxjs");
|
|
6
|
+
// base class
|
|
7
|
+
class AbstractSpecSource {
|
|
8
|
+
constructor({ spec } = {}) {
|
|
9
|
+
// initialize instance variables
|
|
10
|
+
this._result$ = new rxjs_1.BehaviorSubject(spec
|
|
11
|
+
? { __type: 'success', result: spec }
|
|
12
|
+
: { __type: 'pending' });
|
|
13
|
+
this._syncing$ = new rxjs_1.BehaviorSubject(false);
|
|
14
|
+
}
|
|
15
|
+
get result$() {
|
|
16
|
+
return this._result$.asObservable();
|
|
17
|
+
}
|
|
18
|
+
get result() {
|
|
19
|
+
return this._result$.getValue();
|
|
20
|
+
}
|
|
21
|
+
set result(result) {
|
|
22
|
+
this._result$.next(result);
|
|
23
|
+
}
|
|
24
|
+
syncing$() {
|
|
25
|
+
return this._syncing$;
|
|
26
|
+
}
|
|
27
|
+
get syncing() {
|
|
28
|
+
return this._syncing$.getValue();
|
|
29
|
+
}
|
|
30
|
+
set syncing(syncing) {
|
|
31
|
+
this._syncing$.next(syncing);
|
|
32
|
+
}
|
|
33
|
+
async sync(args) {
|
|
34
|
+
// try to fetch spec
|
|
35
|
+
try {
|
|
36
|
+
// mark as syncing
|
|
37
|
+
this.syncing = true;
|
|
38
|
+
// parse spec
|
|
39
|
+
const result = {
|
|
40
|
+
__type: 'success',
|
|
41
|
+
result: await this.onSync(args)
|
|
42
|
+
};
|
|
43
|
+
this.result = result;
|
|
44
|
+
// return result
|
|
45
|
+
return result;
|
|
46
|
+
}
|
|
47
|
+
// handle error
|
|
48
|
+
catch (e) {
|
|
49
|
+
// set result to an error
|
|
50
|
+
const result = {
|
|
51
|
+
__type: 'failure',
|
|
52
|
+
error: funnel_core_1.IsometricErrorUtils.coerceError(e)
|
|
53
|
+
};
|
|
54
|
+
this.result = result;
|
|
55
|
+
// return result
|
|
56
|
+
return result;
|
|
57
|
+
}
|
|
58
|
+
// clear sync on completion
|
|
59
|
+
finally {
|
|
60
|
+
this.syncing = false;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
exports.AbstractSpecSource = AbstractSpecSource;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Navigation } from '../Navigation';
|
|
2
|
+
import type { Spec } from '../Spec';
|
|
3
|
+
import type { SpecSource } from '../SpecSource';
|
|
4
|
+
import { AbstractSpecSource } from './AbstractSpecSource';
|
|
5
|
+
export declare class StaticSpecSource<TNavigation extends Navigation = Navigation> extends AbstractSpecSource<TNavigation> {
|
|
6
|
+
private readonly spec;
|
|
7
|
+
constructor(spec: Spec<TNavigation>);
|
|
8
|
+
protected onSync(args: SpecSource.Sync.Args): Promise<Spec<TNavigation>>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.StaticSpecSource = void 0;
|
|
4
|
+
const AbstractSpecSource_1 = require("./AbstractSpecSource");
|
|
5
|
+
// class
|
|
6
|
+
class StaticSpecSource extends AbstractSpecSource_1.AbstractSpecSource {
|
|
7
|
+
constructor(spec) {
|
|
8
|
+
// construct base
|
|
9
|
+
super({ spec });
|
|
10
|
+
this.spec = spec;
|
|
11
|
+
}
|
|
12
|
+
async onSync(args) {
|
|
13
|
+
return this.spec;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
exports.StaticSpecSource = StaticSpecSource;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./AbstractSpecSource"), exports);
|
|
18
|
+
__exportStar(require("./StaticSpecSource"), exports);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import 'server-only';
|
|
2
|
+
import { JsonValue } from 'type-fest';
|
|
3
|
+
import { AbstractAppService } from '../../app/server/AbstractAppService';
|
|
4
|
+
import { Identity } from '../../identity/domain';
|
|
5
|
+
import { Spec } from '../domain';
|
|
6
|
+
export declare class SpecService extends AbstractAppService<Spec.Request> {
|
|
7
|
+
constructor();
|
|
8
|
+
onExecute(request: Spec.Request.GetSpec, identity?: Identity): Promise<JsonValue>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SpecService = void 0;
|
|
4
|
+
require("server-only");
|
|
5
|
+
const AbstractAppService_1 = require("../../app/server/AbstractAppService");
|
|
6
|
+
const domain_1 = require("../domain");
|
|
7
|
+
// class
|
|
8
|
+
class SpecService extends AbstractAppService_1.AbstractAppService {
|
|
9
|
+
constructor() {
|
|
10
|
+
// construct base
|
|
11
|
+
super({
|
|
12
|
+
id: '_nd-nav',
|
|
13
|
+
name: 'AppNav Spec Service'
|
|
14
|
+
});
|
|
15
|
+
}
|
|
16
|
+
async onExecute(request, identity) {
|
|
17
|
+
// get spec from provider
|
|
18
|
+
const specSource = domain_1.SpecSource.get();
|
|
19
|
+
const specResult = await specSource.sync({ identity });
|
|
20
|
+
console.debug('[AppNav.SpecService] fetched spec', { identity, specResult });
|
|
21
|
+
// throw if failed
|
|
22
|
+
if (specResult.__type === 'failure') {
|
|
23
|
+
throw specResult.error;
|
|
24
|
+
}
|
|
25
|
+
// or return result
|
|
26
|
+
else {
|
|
27
|
+
return specResult.result.toJSON();
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
exports.SpecService = SpecService;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './SpecService';
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./SpecService"), exports);
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.AppNav = void 0;
|
|
37
|
+
require("server-only");
|
|
38
|
+
exports.AppNav = __importStar(require("./exports"));
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WebSpecProvider = WebSpecProvider;
|
|
4
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
const router_1 = require("next/router");
|
|
6
|
+
const react_1 = require("react");
|
|
7
|
+
const web_1 = require("../../bridge/web");
|
|
8
|
+
const core_1 = require("../../identity/core");
|
|
9
|
+
const core_2 = require("../core");
|
|
10
|
+
const domain_1 = require("../domain");
|
|
11
|
+
const index_1 = require("./navigator/index");
|
|
12
|
+
function WebSpecProvider({ children }) {
|
|
13
|
+
// bind context
|
|
14
|
+
const specSource = (0, react_1.useMemo)(() => domain_1.SpecSource.get(), []);
|
|
15
|
+
const specContext = (0, react_1.useMemo)(() => ({ specSource }), [specSource]);
|
|
16
|
+
const { pathname, query } = (0, router_1.useRouter)();
|
|
17
|
+
const { identity } = (0, core_1.useIdentity)();
|
|
18
|
+
const bridge = (0, web_1.useBridge)();
|
|
19
|
+
const nativeNavigator = (0, react_1.useMemo)(() => new index_1.NativeNavigator(bridge), [bridge]);
|
|
20
|
+
const webNavigator = (0, react_1.useMemo)(() => new index_1.WebNavigator(), []);
|
|
21
|
+
const router = (0, router_1.useRouter)();
|
|
22
|
+
const navigator = bridge.isNative
|
|
23
|
+
? nativeNavigator
|
|
24
|
+
: webNavigator;
|
|
25
|
+
const navigatorContext = (0, react_1.useMemo)(() => ({ navigator }), [navigator]);
|
|
26
|
+
// always bind router to web navigator
|
|
27
|
+
webNavigator.bind(router);
|
|
28
|
+
// sync spec when identity changes
|
|
29
|
+
(0, react_1.useEffect)(() => {
|
|
30
|
+
// fetch spec
|
|
31
|
+
const specSource = domain_1.SpecSource.get();
|
|
32
|
+
specSource.sync({ identity })
|
|
33
|
+
.then(spec => {
|
|
34
|
+
console.debug('[WebSpecProvider] resolved spec ', spec);
|
|
35
|
+
})
|
|
36
|
+
.catch(e => console.error('[WebSpecProvider] failed to get spec', e));
|
|
37
|
+
// TODO: continue sync?
|
|
38
|
+
}, [identity]);
|
|
39
|
+
// render
|
|
40
|
+
return ((0, jsx_runtime_1.jsx)(core_2.SpecSourceContext.Provider, { value: specContext, children: (0, jsx_runtime_1.jsx)(index_1.NavigatorContext.Provider, { value: navigatorContext, children: children }) }));
|
|
41
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("../core"), exports);
|
|
18
|
+
__exportStar(require("./navigator/index"), exports);
|
|
19
|
+
__exportStar(require("./WebSpecProvider"), exports);
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Bridge } from '../../../bridge/web';
|
|
2
|
+
import { Navigator } from './Navigator';
|
|
3
|
+
export declare class NativeNavigator implements Navigator {
|
|
4
|
+
private _bridge?;
|
|
5
|
+
constructor(_bridge?: Bridge | undefined);
|
|
6
|
+
protected get bridge(): Bridge;
|
|
7
|
+
bind(bridge: Bridge): void;
|
|
8
|
+
reload(): void;
|
|
9
|
+
forward(): void;
|
|
10
|
+
back(): void;
|
|
11
|
+
push(url: string): Promise<void>;
|
|
12
|
+
replace(url: string): Promise<void>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.NativeNavigator = void 0;
|
|
4
|
+
const funnel_core_1 = require("@nascentdigital/funnel-core");
|
|
5
|
+
// class
|
|
6
|
+
class NativeNavigator {
|
|
7
|
+
constructor(_bridge) {
|
|
8
|
+
this._bridge = _bridge;
|
|
9
|
+
}
|
|
10
|
+
get bridge() {
|
|
11
|
+
// throw if there's no bridge
|
|
12
|
+
const { _bridge } = this;
|
|
13
|
+
if (!_bridge) {
|
|
14
|
+
throw new funnel_core_1.InvalidOperationError('Cannot access NativeNavigator before call to bind()');
|
|
15
|
+
}
|
|
16
|
+
// or return it
|
|
17
|
+
return _bridge;
|
|
18
|
+
}
|
|
19
|
+
bind(bridge) {
|
|
20
|
+
// set bridge
|
|
21
|
+
this._bridge = bridge;
|
|
22
|
+
}
|
|
23
|
+
reload() {
|
|
24
|
+
throw new funnel_core_1.NotImplementedError();
|
|
25
|
+
}
|
|
26
|
+
forward() {
|
|
27
|
+
throw new funnel_core_1.NotImplementedError();
|
|
28
|
+
}
|
|
29
|
+
back() {
|
|
30
|
+
this.bridge.call('app.navigate', {
|
|
31
|
+
__type: 'back'
|
|
32
|
+
});
|
|
33
|
+
}
|
|
34
|
+
async push(url) {
|
|
35
|
+
await this.bridge.call('app.navigate', {
|
|
36
|
+
__type: 'push',
|
|
37
|
+
url
|
|
38
|
+
});
|
|
39
|
+
}
|
|
40
|
+
async replace(url) {
|
|
41
|
+
await this.bridge.call('app.navigate', {
|
|
42
|
+
__type: 'replace',
|
|
43
|
+
url
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
exports.NativeNavigator = NativeNavigator;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { NextRouter } from 'next/router';
|
|
2
|
+
import { Navigator } from './Navigator';
|
|
3
|
+
export declare class WebNavigator implements Navigator {
|
|
4
|
+
private _router?;
|
|
5
|
+
constructor(_router?: NextRouter | undefined);
|
|
6
|
+
protected get router(): NextRouter;
|
|
7
|
+
bind(router: NextRouter): void;
|
|
8
|
+
reload(): void;
|
|
9
|
+
forward(): void;
|
|
10
|
+
back(): void;
|
|
11
|
+
push(url: string): Promise<void>;
|
|
12
|
+
replace(url: string): Promise<void>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.WebNavigator = void 0;
|
|
4
|
+
const funnel_core_1 = require("@nascentdigital/funnel-core");
|
|
5
|
+
// class
|
|
6
|
+
class WebNavigator {
|
|
7
|
+
constructor(_router) {
|
|
8
|
+
this._router = _router;
|
|
9
|
+
}
|
|
10
|
+
get router() {
|
|
11
|
+
// throw if there's no router
|
|
12
|
+
const { _router } = this;
|
|
13
|
+
if (!_router) {
|
|
14
|
+
throw new funnel_core_1.InvalidOperationError('Cannot access WebNavigator before call to bind()');
|
|
15
|
+
}
|
|
16
|
+
// or return it
|
|
17
|
+
return _router;
|
|
18
|
+
}
|
|
19
|
+
bind(router) {
|
|
20
|
+
this._router = router;
|
|
21
|
+
}
|
|
22
|
+
reload() {
|
|
23
|
+
this.router.reload();
|
|
24
|
+
}
|
|
25
|
+
forward() {
|
|
26
|
+
this.router.forward();
|
|
27
|
+
}
|
|
28
|
+
back() {
|
|
29
|
+
this.router.back();
|
|
30
|
+
}
|
|
31
|
+
async push(url) {
|
|
32
|
+
await this.router.push(`/app${url}`);
|
|
33
|
+
}
|
|
34
|
+
async replace(url) {
|
|
35
|
+
await this.router.replace(`/app${url}`);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
exports.WebNavigator = WebNavigator;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./Navigator"), exports);
|
|
18
|
+
__exportStar(require("./NavigatorContext"), exports);
|
|
19
|
+
__exportStar(require("./NativeNavigator"), exports);
|
|
20
|
+
__exportStar(require("./useNavigator"), exports);
|
|
21
|
+
__exportStar(require("./WebNavigator"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function useNavigator(): import("./Navigator").Navigator;
|