@oxyhq/services 22.12.4 → 22.12.7
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/README.md +16 -46
- package/lib/commonjs/index.js +84 -10
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/notifications/deviceNotifications.js +380 -0
- package/lib/commonjs/notifications/deviceNotifications.js.map +1 -0
- package/lib/commonjs/ui/boot/runProviderColdBoot.js +51 -9
- package/lib/commonjs/ui/boot/runProviderColdBoot.js.map +1 -1
- package/lib/commonjs/ui/client.js +0 -13
- package/lib/commonjs/ui/client.js.map +1 -1
- package/lib/commonjs/ui/components/AvatarCameraBadge.js +3 -2
- package/lib/commonjs/ui/components/AvatarCameraBadge.js.map +1 -1
- package/lib/commonjs/ui/components/OxyAccountDialogScreen.js +14 -3
- package/lib/commonjs/ui/components/OxyAccountDialogScreen.js.map +1 -1
- package/lib/commonjs/ui/components/OxyAuthChooser.js +70 -1121
- package/lib/commonjs/ui/components/OxyAuthChooser.js.map +1 -1
- package/lib/commonjs/ui/components/OxyConsentScreen.js +50 -12
- package/lib/commonjs/ui/components/OxyConsentScreen.js.map +1 -1
- package/lib/commonjs/ui/components/OxyProvider.js +4 -4
- package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
- package/lib/commonjs/ui/components/OxySignInButton.js +74 -40
- package/lib/commonjs/ui/components/OxySignInButton.js.map +1 -1
- package/lib/commonjs/ui/components/OxySignInRequestSurface.js +147 -0
- package/lib/commonjs/ui/components/OxySignInRequestSurface.js.map +1 -0
- package/lib/commonjs/ui/components/ProfileButton.js +4 -3
- package/lib/commonjs/ui/components/ProfileButton.js.map +1 -1
- package/lib/commonjs/ui/components/SettingsIcon.js +3 -2
- package/lib/commonjs/ui/components/SettingsIcon.js.map +1 -1
- package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js +527 -0
- package/lib/commonjs/ui/components/authChooser/AccountsMenuView.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/SignInEntryView.js +90 -0
- package/lib/commonjs/ui/components/authChooser/SignInEntryView.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/SignInRequestView.js +106 -0
- package/lib/commonjs/ui/components/authChooser/SignInRequestView.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/SignUpView.js +188 -0
- package/lib/commonjs/ui/components/authChooser/SignUpView.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/TroubleDisclosure.js +61 -0
- package/lib/commonjs/ui/components/authChooser/TroubleDisclosure.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/primitives.js +170 -0
- package/lib/commonjs/ui/components/authChooser/primitives.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/requestSurfaces.js +153 -0
- package/lib/commonjs/ui/components/authChooser/requestSurfaces.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/signInProgress.js +54 -0
- package/lib/commonjs/ui/components/authChooser/signInProgress.js.map +1 -0
- package/lib/commonjs/ui/components/{oxyAuthChooserStyles.js → authChooser/styles.js} +19 -1
- package/lib/commonjs/ui/components/authChooser/styles.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/types.js +70 -0
- package/lib/commonjs/ui/components/authChooser/types.js.map +1 -0
- package/lib/commonjs/ui/components/authChooser/useUsernameAvailability.js +50 -0
- package/lib/commonjs/ui/components/authChooser/useUsernameAvailability.js.map +1 -0
- package/lib/commonjs/ui/components/fileManagement/AnimatedButton.js +3 -2
- package/lib/commonjs/ui/components/fileManagement/AnimatedButton.js.map +1 -1
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js +3 -2
- package/lib/commonjs/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
- package/lib/commonjs/ui/components/fileManagement/FileViewer.js +15 -14
- package/lib/commonjs/ui/components/fileManagement/FileViewer.js.map +1 -1
- package/lib/commonjs/ui/components/fileManagement/UploadPreview.js +6 -5
- package/lib/commonjs/ui/components/fileManagement/UploadPreview.js.map +1 -1
- package/lib/commonjs/ui/components/modals/DeleteAccountModal.js +3 -2
- package/lib/commonjs/ui/components/modals/DeleteAccountModal.js.map +1 -1
- package/lib/commonjs/ui/components/payment/PaymentDetailsStep.js +6 -6
- package/lib/commonjs/ui/components/payment/PaymentDetailsStep.js.map +1 -1
- package/lib/commonjs/ui/components/payment/PaymentMethodStep.js +5 -5
- package/lib/commonjs/ui/components/payment/PaymentMethodStep.js.map +1 -1
- package/lib/commonjs/ui/components/payment/PaymentReviewStep.js +10 -9
- package/lib/commonjs/ui/components/payment/PaymentReviewStep.js.map +1 -1
- package/lib/commonjs/ui/components/payment/PaymentSuccessStep.js +4 -3
- package/lib/commonjs/ui/components/payment/PaymentSuccessStep.js.map +1 -1
- package/lib/commonjs/ui/components/payment/PaymentSummaryStep.js +6 -5
- package/lib/commonjs/ui/components/payment/PaymentSummaryStep.js.map +1 -1
- package/lib/commonjs/ui/context/OxyContext.js +200 -29
- package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
- package/lib/commonjs/ui/context/commitSessionFlow.js +43 -0
- package/lib/commonjs/ui/context/commitSessionFlow.js.map +1 -1
- package/lib/commonjs/ui/context/useOxyAccountGraph.js +13 -5
- package/lib/commonjs/ui/context/useOxyAccountGraph.js.map +1 -1
- package/lib/commonjs/ui/hooks/useSwitchableAccounts.js +6 -1
- package/lib/commonjs/ui/hooks/useSwitchableAccounts.js.map +1 -1
- package/lib/commonjs/ui/index.js +0 -13
- package/lib/commonjs/ui/index.js.map +1 -1
- package/lib/commonjs/ui/oauth/browserAuthTransport.js +168 -0
- package/lib/commonjs/ui/oauth/browserAuthTransport.js.map +1 -0
- package/lib/commonjs/ui/oauth/completeOAuthCode.js +78 -0
- package/lib/commonjs/ui/oauth/completeOAuthCode.js.map +1 -0
- package/lib/commonjs/ui/oauth/legacyRedirectLanes.js +48 -0
- package/lib/commonjs/ui/oauth/legacyRedirectLanes.js.map +1 -0
- package/lib/commonjs/ui/oauth/oauthHandshake.js +53 -0
- package/lib/commonjs/ui/oauth/oauthHandshake.js.map +1 -0
- package/lib/commonjs/ui/oauth/oauthPopup.js +229 -0
- package/lib/commonjs/ui/oauth/oauthPopup.js.map +1 -0
- package/lib/commonjs/ui/oauth/oauthPopupMessages.js +141 -0
- package/lib/commonjs/ui/oauth/oauthPopupMessages.js.map +1 -0
- package/lib/commonjs/ui/oauth/types.js +2 -0
- package/lib/commonjs/ui/oauth/types.js.map +1 -0
- package/lib/commonjs/ui/screens/AccountMembersScreen.js +4 -3
- package/lib/commonjs/ui/screens/AccountMembersScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/CreateAccountScreen.js +7 -6
- package/lib/commonjs/ui/screens/CreateAccountScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/EditProfileFieldScreen.js +4 -3
- package/lib/commonjs/ui/screens/EditProfileFieldScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FAQScreen.js +3 -2
- package/lib/commonjs/ui/screens/FAQScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FeedbackScreen.js +11 -10
- package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/FileManagementScreen.js +19 -18
- package/lib/commonjs/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js +4 -3
- package/lib/commonjs/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ManageAccountScreen.js +2 -2
- package/lib/commonjs/ui/screens/ManageAccountScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +3 -3
- package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js +9 -8
- package/lib/commonjs/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/ProfileScreen.js +10 -10
- package/lib/commonjs/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/UserListScreen.js +3 -3
- package/lib/commonjs/ui/screens/UserListScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js +3 -2
- package/lib/commonjs/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/FileLibraryError.js +4 -3
- package/lib/commonjs/ui/screens/fileManagement/FileLibraryError.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/FileListSection.js +4 -3
- package/lib/commonjs/ui/screens/fileManagement/FileListSection.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/PhotoPickerSection.js +4 -3
- package/lib/commonjs/ui/screens/fileManagement/PhotoPickerSection.js.map +1 -1
- package/lib/commonjs/ui/screens/fileManagement/UploadBar.js +3 -2
- package/lib/commonjs/ui/screens/fileManagement/UploadBar.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js +3 -2
- package/lib/commonjs/ui/screens/trust/TrustCenterScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js +4 -3
- package/lib/commonjs/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
- package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js +4 -3
- package/lib/commonjs/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
- package/lib/commonjs/ui/server.js +2 -5
- package/lib/commonjs/ui/server.js.map +1 -1
- package/lib/commonjs/ui/session/authStore.js +6 -75
- package/lib/commonjs/ui/session/authStore.js.map +1 -1
- package/lib/commonjs/ui/session/createSessionClient.js +11 -3
- package/lib/commonjs/ui/session/createSessionClient.js.map +1 -1
- package/lib/commonjs/ui/session/identityBinding.js +95 -0
- package/lib/commonjs/ui/session/identityBinding.js.map +1 -0
- package/lib/commonjs/ui/session/index.js +13 -0
- package/lib/commonjs/ui/session/index.js.map +1 -1
- package/lib/commonjs/ui/session/nativeSecureStorage.js +90 -0
- package/lib/commonjs/ui/session/nativeSecureStorage.js.map +1 -0
- package/lib/commonjs/ui/session/tokenTransport.js +11 -1
- package/lib/commonjs/ui/session/tokenTransport.js.map +1 -1
- package/lib/commonjs/ui/utils/crossOriginRestore.js +3 -2
- package/lib/commonjs/ui/utils/crossOriginRestore.js.map +1 -1
- package/lib/commonjs/ui/utils/deliveryPlatform.js +58 -0
- package/lib/commonjs/ui/utils/deliveryPlatform.js.map +1 -0
- package/lib/commonjs/ui/utils/oauthReturn.js +70 -46
- package/lib/commonjs/ui/utils/oauthReturn.js.map +1 -1
- package/lib/module/index.js +27 -4
- package/lib/module/index.js.map +1 -1
- package/lib/module/notifications/deviceNotifications.js +371 -0
- package/lib/module/notifications/deviceNotifications.js.map +1 -0
- package/lib/module/ui/boot/runProviderColdBoot.js +51 -9
- package/lib/module/ui/boot/runProviderColdBoot.js.map +1 -1
- package/lib/module/ui/client.js +0 -1
- package/lib/module/ui/client.js.map +1 -1
- package/lib/module/ui/components/AvatarCameraBadge.js +1 -1
- package/lib/module/ui/components/AvatarCameraBadge.js.map +1 -1
- package/lib/module/ui/components/OxyAccountDialogScreen.js +14 -3
- package/lib/module/ui/components/OxyAccountDialogScreen.js.map +1 -1
- package/lib/module/ui/components/OxyAuthChooser.js +74 -1126
- package/lib/module/ui/components/OxyAuthChooser.js.map +1 -1
- package/lib/module/ui/components/OxyConsentScreen.js +50 -12
- package/lib/module/ui/components/OxyConsentScreen.js.map +1 -1
- package/lib/module/ui/components/OxyProvider.js +4 -4
- package/lib/module/ui/components/OxyProvider.js.map +1 -1
- package/lib/module/ui/components/OxySignInButton.js +76 -42
- package/lib/module/ui/components/OxySignInButton.js.map +1 -1
- package/lib/module/ui/components/OxySignInRequestSurface.js +141 -0
- package/lib/module/ui/components/OxySignInRequestSurface.js.map +1 -0
- package/lib/module/ui/components/ProfileButton.js +1 -1
- package/lib/module/ui/components/ProfileButton.js.map +1 -1
- package/lib/module/ui/components/SettingsIcon.js +1 -1
- package/lib/module/ui/components/SettingsIcon.js.map +1 -1
- package/lib/module/ui/components/authChooser/AccountsMenuView.js +523 -0
- package/lib/module/ui/components/authChooser/AccountsMenuView.js.map +1 -0
- package/lib/module/ui/components/authChooser/SignInEntryView.js +85 -0
- package/lib/module/ui/components/authChooser/SignInEntryView.js.map +1 -0
- package/lib/module/ui/components/authChooser/SignInRequestView.js +101 -0
- package/lib/module/ui/components/authChooser/SignInRequestView.js.map +1 -0
- package/lib/module/ui/components/authChooser/SignUpView.js +184 -0
- package/lib/module/ui/components/authChooser/SignUpView.js.map +1 -0
- package/lib/module/ui/components/authChooser/TroubleDisclosure.js +57 -0
- package/lib/module/ui/components/authChooser/TroubleDisclosure.js.map +1 -0
- package/lib/module/ui/components/authChooser/primitives.js +163 -0
- package/lib/module/ui/components/authChooser/primitives.js.map +1 -0
- package/lib/module/ui/components/authChooser/requestSurfaces.js +143 -0
- package/lib/module/ui/components/authChooser/requestSurfaces.js.map +1 -0
- package/lib/module/ui/components/authChooser/signInProgress.js +50 -0
- package/lib/module/ui/components/authChooser/signInProgress.js.map +1 -0
- package/lib/module/ui/components/{oxyAuthChooserStyles.js → authChooser/styles.js} +19 -1
- package/lib/module/ui/components/authChooser/styles.js.map +1 -0
- package/lib/module/ui/components/authChooser/types.js +66 -0
- package/lib/module/ui/components/authChooser/types.js.map +1 -0
- package/lib/module/ui/components/authChooser/useUsernameAvailability.js +46 -0
- package/lib/module/ui/components/authChooser/useUsernameAvailability.js.map +1 -0
- package/lib/module/ui/components/fileManagement/AnimatedButton.js +1 -1
- package/lib/module/ui/components/fileManagement/AnimatedButton.js.map +1 -1
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js +1 -1
- package/lib/module/ui/components/fileManagement/FileDetailsModal.js.map +1 -1
- package/lib/module/ui/components/fileManagement/FileViewer.js +1 -1
- package/lib/module/ui/components/fileManagement/FileViewer.js.map +1 -1
- package/lib/module/ui/components/fileManagement/UploadPreview.js +1 -1
- package/lib/module/ui/components/fileManagement/UploadPreview.js.map +1 -1
- package/lib/module/ui/components/modals/DeleteAccountModal.js +1 -1
- package/lib/module/ui/components/modals/DeleteAccountModal.js.map +1 -1
- package/lib/module/ui/components/payment/PaymentDetailsStep.js +1 -1
- package/lib/module/ui/components/payment/PaymentDetailsStep.js.map +1 -1
- package/lib/module/ui/components/payment/PaymentMethodStep.js +1 -1
- package/lib/module/ui/components/payment/PaymentMethodStep.js.map +1 -1
- package/lib/module/ui/components/payment/PaymentReviewStep.js +1 -1
- package/lib/module/ui/components/payment/PaymentReviewStep.js.map +1 -1
- package/lib/module/ui/components/payment/PaymentSuccessStep.js +1 -1
- package/lib/module/ui/components/payment/PaymentSuccessStep.js.map +1 -1
- package/lib/module/ui/components/payment/PaymentSummaryStep.js +1 -1
- package/lib/module/ui/components/payment/PaymentSummaryStep.js.map +1 -1
- package/lib/module/ui/context/OxyContext.js +203 -32
- package/lib/module/ui/context/OxyContext.js.map +1 -1
- package/lib/module/ui/context/commitSessionFlow.js +42 -0
- package/lib/module/ui/context/commitSessionFlow.js.map +1 -1
- package/lib/module/ui/context/useOxyAccountGraph.js +13 -5
- package/lib/module/ui/context/useOxyAccountGraph.js.map +1 -1
- package/lib/module/ui/hooks/useSwitchableAccounts.js +6 -1
- package/lib/module/ui/hooks/useSwitchableAccounts.js.map +1 -1
- package/lib/module/ui/index.js +0 -1
- package/lib/module/ui/index.js.map +1 -1
- package/lib/module/ui/oauth/browserAuthTransport.js +165 -0
- package/lib/module/ui/oauth/browserAuthTransport.js.map +1 -0
- package/lib/module/ui/oauth/completeOAuthCode.js +75 -0
- package/lib/module/ui/oauth/completeOAuthCode.js.map +1 -0
- package/lib/module/ui/oauth/legacyRedirectLanes.js +44 -0
- package/lib/module/ui/oauth/legacyRedirectLanes.js.map +1 -0
- package/lib/module/ui/oauth/oauthHandshake.js +50 -0
- package/lib/module/ui/oauth/oauthHandshake.js.map +1 -0
- package/lib/module/ui/oauth/oauthPopup.js +221 -0
- package/lib/module/ui/oauth/oauthPopup.js.map +1 -0
- package/lib/module/ui/oauth/oauthPopupMessages.js +135 -0
- package/lib/module/ui/oauth/oauthPopupMessages.js.map +1 -0
- package/lib/module/ui/oauth/types.js +2 -0
- package/lib/module/ui/oauth/types.js.map +1 -0
- package/lib/module/ui/screens/AccountMembersScreen.js +1 -1
- package/lib/module/ui/screens/AccountMembersScreen.js.map +1 -1
- package/lib/module/ui/screens/CreateAccountScreen.js +1 -1
- package/lib/module/ui/screens/CreateAccountScreen.js.map +1 -1
- package/lib/module/ui/screens/EditProfileFieldScreen.js +1 -1
- package/lib/module/ui/screens/EditProfileFieldScreen.js.map +1 -1
- package/lib/module/ui/screens/FAQScreen.js +1 -1
- package/lib/module/ui/screens/FAQScreen.js.map +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js +1 -1
- package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
- package/lib/module/ui/screens/FileManagementScreen.js +2 -1
- package/lib/module/ui/screens/FileManagementScreen.js.map +1 -1
- package/lib/module/ui/screens/LanguageSelectorScreen.js +1 -1
- package/lib/module/ui/screens/LanguageSelectorScreen.js.map +1 -1
- package/lib/module/ui/screens/ManageAccountScreen.js +1 -1
- package/lib/module/ui/screens/ManageAccountScreen.js.map +1 -1
- package/lib/module/ui/screens/PaymentGatewayScreen.js +1 -1
- package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js +1 -1
- package/lib/module/ui/screens/PremiumSubscriptionScreen.js.map +1 -1
- package/lib/module/ui/screens/ProfileScreen.js +1 -1
- package/lib/module/ui/screens/ProfileScreen.js.map +1 -1
- package/lib/module/ui/screens/UserListScreen.js +1 -1
- package/lib/module/ui/screens/UserListScreen.js.map +1 -1
- package/lib/module/ui/screens/WelcomeNewUserScreen.js +1 -1
- package/lib/module/ui/screens/WelcomeNewUserScreen.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/FileLibraryError.js +1 -1
- package/lib/module/ui/screens/fileManagement/FileLibraryError.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/FileListSection.js +1 -1
- package/lib/module/ui/screens/fileManagement/FileListSection.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/PhotoPickerSection.js +2 -1
- package/lib/module/ui/screens/fileManagement/PhotoPickerSection.js.map +1 -1
- package/lib/module/ui/screens/fileManagement/UploadBar.js +1 -1
- package/lib/module/ui/screens/fileManagement/UploadBar.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustCenterScreen.js +1 -1
- package/lib/module/ui/screens/trust/TrustCenterScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js +1 -1
- package/lib/module/ui/screens/trust/TrustLeaderboardScreen.js.map +1 -1
- package/lib/module/ui/screens/trust/TrustRewardsScreen.js +1 -1
- package/lib/module/ui/screens/trust/TrustRewardsScreen.js.map +1 -1
- package/lib/module/ui/server.js +0 -2
- package/lib/module/ui/server.js.map +1 -1
- package/lib/module/ui/session/authStore.js +5 -75
- package/lib/module/ui/session/authStore.js.map +1 -1
- package/lib/module/ui/session/createSessionClient.js +11 -3
- package/lib/module/ui/session/createSessionClient.js.map +1 -1
- package/lib/module/ui/session/identityBinding.js +89 -0
- package/lib/module/ui/session/identityBinding.js.map +1 -0
- package/lib/module/ui/session/index.js +5 -2
- package/lib/module/ui/session/index.js.map +1 -1
- package/lib/module/ui/session/nativeSecureStorage.js +88 -0
- package/lib/module/ui/session/nativeSecureStorage.js.map +1 -0
- package/lib/module/ui/session/tokenTransport.js +11 -1
- package/lib/module/ui/session/tokenTransport.js.map +1 -1
- package/lib/module/ui/utils/crossOriginRestore.js +4 -3
- package/lib/module/ui/utils/crossOriginRestore.js.map +1 -1
- package/lib/module/ui/utils/deliveryPlatform.js +55 -0
- package/lib/module/ui/utils/deliveryPlatform.js.map +1 -0
- package/lib/module/ui/utils/oauthReturn.js +70 -46
- package/lib/module/ui/utils/oauthReturn.js.map +1 -1
- package/lib/typescript/commonjs/index.d.ts +9 -1
- package/lib/typescript/commonjs/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/notifications/deviceNotifications.d.ts +141 -0
- package/lib/typescript/commonjs/notifications/deviceNotifications.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/boot/runProviderColdBoot.d.ts +34 -2
- package/lib/typescript/commonjs/ui/boot/runProviderColdBoot.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/client.d.ts +0 -1
- package/lib/typescript/commonjs/ui/client.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts +16 -29
- package/lib/typescript/commonjs/ui/components/OxyAuthChooser.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxyConsentScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxyProvider.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxySignInButton.d.ts +17 -12
- package/lib/typescript/commonjs/ui/components/OxySignInButton.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/OxySignInRequestSurface.d.ts +108 -0
- package/lib/typescript/commonjs/ui/components/OxySignInRequestSurface.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/SettingsIcon.d.ts +1 -1
- package/lib/typescript/commonjs/ui/components/SettingsIcon.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/components/authChooser/AccountsMenuView.d.ts +38 -0
- package/lib/typescript/commonjs/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts +32 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignInEntryView.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignInRequestView.d.ts +34 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignInRequestView.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts +34 -0
- package/lib/typescript/commonjs/ui/components/authChooser/SignUpView.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/TroubleDisclosure.d.ts +36 -0
- package/lib/typescript/commonjs/ui/components/authChooser/TroubleDisclosure.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts +55 -0
- package/lib/typescript/commonjs/ui/components/authChooser/primitives.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/requestSurfaces.d.ts +58 -0
- package/lib/typescript/commonjs/ui/components/authChooser/requestSurfaces.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/signInProgress.d.ts +26 -0
- package/lib/typescript/commonjs/ui/components/authChooser/signInProgress.d.ts.map +1 -0
- package/lib/typescript/{module/ui/components/oxyAuthChooserStyles.d.ts → commonjs/ui/components/authChooser/styles.d.ts} +19 -1
- package/lib/typescript/commonjs/ui/components/authChooser/styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/types.d.ts +103 -0
- package/lib/typescript/commonjs/ui/components/authChooser/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/authChooser/useUsernameAvailability.d.ts +16 -0
- package/lib/typescript/commonjs/ui/components/authChooser/useUsernameAvailability.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/components/payment/types.d.ts +1 -1
- package/lib/typescript/commonjs/ui/components/payment/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts +40 -0
- package/lib/typescript/commonjs/ui/context/commitSessionFlow.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts +44 -1
- package/lib/typescript/commonjs/ui/context/oxyContextTypes.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/context/useOxyAccountGraph.d.ts +7 -1
- package/lib/typescript/commonjs/ui/context/useOxyAccountGraph.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/hooks/useSwitchableAccounts.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/index.d.ts +0 -1
- package/lib/typescript/commonjs/ui/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts +56 -0
- package/lib/typescript/commonjs/ui/oauth/browserAuthTransport.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/completeOAuthCode.d.ts +49 -0
- package/lib/typescript/commonjs/ui/oauth/completeOAuthCode.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts +40 -0
- package/lib/typescript/commonjs/ui/oauth/legacyRedirectLanes.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts +50 -0
- package/lib/typescript/commonjs/ui/oauth/oauthHandshake.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts +77 -0
- package/lib/typescript/commonjs/ui/oauth/oauthPopup.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/oauthPopupMessages.d.ts +67 -0
- package/lib/typescript/commonjs/ui/oauth/oauthPopupMessages.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/oauth/types.d.ts +176 -0
- package/lib/typescript/commonjs/ui/oauth/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/screens/fileManagement/PhotoPickerSection.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/server.d.ts +0 -2
- package/lib/typescript/commonjs/ui/server.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/session/authStore.d.ts +3 -7
- package/lib/typescript/commonjs/ui/session/authStore.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts +8 -1
- package/lib/typescript/commonjs/ui/session/createSessionClient.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/session/identityBinding.d.ts +66 -0
- package/lib/typescript/commonjs/ui/session/identityBinding.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/session/index.d.ts +6 -2
- package/lib/typescript/commonjs/ui/session/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/session/nativeSecureStorage.d.ts +25 -0
- package/lib/typescript/commonjs/ui/session/nativeSecureStorage.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts +8 -1
- package/lib/typescript/commonjs/ui/session/tokenTransport.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/types/navigation.d.ts +44 -0
- package/lib/typescript/commonjs/ui/types/navigation.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/utils/crossOriginRestore.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/utils/deliveryPlatform.d.ts +33 -0
- package/lib/typescript/commonjs/ui/utils/deliveryPlatform.d.ts.map +1 -0
- package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts +1 -1
- package/lib/typescript/commonjs/ui/utils/fileManagement.d.ts.map +1 -1
- package/lib/typescript/commonjs/ui/utils/oauthReturn.d.ts +30 -16
- package/lib/typescript/commonjs/ui/utils/oauthReturn.d.ts.map +1 -1
- package/lib/typescript/module/index.d.ts +9 -1
- package/lib/typescript/module/index.d.ts.map +1 -1
- package/lib/typescript/module/notifications/deviceNotifications.d.ts +141 -0
- package/lib/typescript/module/notifications/deviceNotifications.d.ts.map +1 -0
- package/lib/typescript/module/ui/boot/runProviderColdBoot.d.ts +34 -2
- package/lib/typescript/module/ui/boot/runProviderColdBoot.d.ts.map +1 -1
- package/lib/typescript/module/ui/client.d.ts +0 -1
- package/lib/typescript/module/ui/client.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxyAccountDialogScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts +16 -29
- package/lib/typescript/module/ui/components/OxyAuthChooser.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxyConsentScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxyProvider.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxySignInButton.d.ts +17 -12
- package/lib/typescript/module/ui/components/OxySignInButton.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/OxySignInRequestSurface.d.ts +108 -0
- package/lib/typescript/module/ui/components/OxySignInRequestSurface.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/SettingsIcon.d.ts +1 -1
- package/lib/typescript/module/ui/components/SettingsIcon.d.ts.map +1 -1
- package/lib/typescript/module/ui/components/authChooser/AccountsMenuView.d.ts +38 -0
- package/lib/typescript/module/ui/components/authChooser/AccountsMenuView.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts +32 -0
- package/lib/typescript/module/ui/components/authChooser/SignInEntryView.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/SignInRequestView.d.ts +34 -0
- package/lib/typescript/module/ui/components/authChooser/SignInRequestView.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts +34 -0
- package/lib/typescript/module/ui/components/authChooser/SignUpView.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/TroubleDisclosure.d.ts +36 -0
- package/lib/typescript/module/ui/components/authChooser/TroubleDisclosure.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/primitives.d.ts +55 -0
- package/lib/typescript/module/ui/components/authChooser/primitives.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/requestSurfaces.d.ts +58 -0
- package/lib/typescript/module/ui/components/authChooser/requestSurfaces.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/signInProgress.d.ts +26 -0
- package/lib/typescript/module/ui/components/authChooser/signInProgress.d.ts.map +1 -0
- package/lib/typescript/{commonjs/ui/components/oxyAuthChooserStyles.d.ts → module/ui/components/authChooser/styles.d.ts} +19 -1
- package/lib/typescript/module/ui/components/authChooser/styles.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/types.d.ts +103 -0
- package/lib/typescript/module/ui/components/authChooser/types.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/authChooser/useUsernameAvailability.d.ts +16 -0
- package/lib/typescript/module/ui/components/authChooser/useUsernameAvailability.d.ts.map +1 -0
- package/lib/typescript/module/ui/components/payment/types.d.ts +1 -1
- package/lib/typescript/module/ui/components/payment/types.d.ts.map +1 -1
- package/lib/typescript/module/ui/context/OxyContext.d.ts.map +1 -1
- package/lib/typescript/module/ui/context/commitSessionFlow.d.ts +40 -0
- package/lib/typescript/module/ui/context/commitSessionFlow.d.ts.map +1 -1
- package/lib/typescript/module/ui/context/oxyContextTypes.d.ts +44 -1
- package/lib/typescript/module/ui/context/oxyContextTypes.d.ts.map +1 -1
- package/lib/typescript/module/ui/context/useOxyAccountGraph.d.ts +7 -1
- package/lib/typescript/module/ui/context/useOxyAccountGraph.d.ts.map +1 -1
- package/lib/typescript/module/ui/hooks/useSwitchableAccounts.d.ts.map +1 -1
- package/lib/typescript/module/ui/index.d.ts +0 -1
- package/lib/typescript/module/ui/index.d.ts.map +1 -1
- package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts +56 -0
- package/lib/typescript/module/ui/oauth/browserAuthTransport.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/completeOAuthCode.d.ts +49 -0
- package/lib/typescript/module/ui/oauth/completeOAuthCode.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts +40 -0
- package/lib/typescript/module/ui/oauth/legacyRedirectLanes.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts +50 -0
- package/lib/typescript/module/ui/oauth/oauthHandshake.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/oauthPopup.d.ts +77 -0
- package/lib/typescript/module/ui/oauth/oauthPopup.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/oauthPopupMessages.d.ts +67 -0
- package/lib/typescript/module/ui/oauth/oauthPopupMessages.d.ts.map +1 -0
- package/lib/typescript/module/ui/oauth/types.d.ts +176 -0
- package/lib/typescript/module/ui/oauth/types.d.ts.map +1 -0
- package/lib/typescript/module/ui/screens/FeedbackScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/FileManagementScreen.d.ts.map +1 -1
- package/lib/typescript/module/ui/screens/fileManagement/PhotoPickerSection.d.ts.map +1 -1
- package/lib/typescript/module/ui/server.d.ts +0 -2
- package/lib/typescript/module/ui/server.d.ts.map +1 -1
- package/lib/typescript/module/ui/session/authStore.d.ts +3 -7
- package/lib/typescript/module/ui/session/authStore.d.ts.map +1 -1
- package/lib/typescript/module/ui/session/createSessionClient.d.ts +8 -1
- package/lib/typescript/module/ui/session/createSessionClient.d.ts.map +1 -1
- package/lib/typescript/module/ui/session/identityBinding.d.ts +66 -0
- package/lib/typescript/module/ui/session/identityBinding.d.ts.map +1 -0
- package/lib/typescript/module/ui/session/index.d.ts +6 -2
- package/lib/typescript/module/ui/session/index.d.ts.map +1 -1
- package/lib/typescript/module/ui/session/nativeSecureStorage.d.ts +25 -0
- package/lib/typescript/module/ui/session/nativeSecureStorage.d.ts.map +1 -0
- package/lib/typescript/module/ui/session/tokenTransport.d.ts +8 -1
- package/lib/typescript/module/ui/session/tokenTransport.d.ts.map +1 -1
- package/lib/typescript/module/ui/types/navigation.d.ts +44 -0
- package/lib/typescript/module/ui/types/navigation.d.ts.map +1 -1
- package/lib/typescript/module/ui/utils/crossOriginRestore.d.ts.map +1 -1
- package/lib/typescript/module/ui/utils/deliveryPlatform.d.ts +33 -0
- package/lib/typescript/module/ui/utils/deliveryPlatform.d.ts.map +1 -0
- package/lib/typescript/module/ui/utils/fileManagement.d.ts +1 -1
- package/lib/typescript/module/ui/utils/fileManagement.d.ts.map +1 -1
- package/lib/typescript/module/ui/utils/oauthReturn.d.ts +30 -16
- package/lib/typescript/module/ui/utils/oauthReturn.d.ts.map +1 -1
- package/package.json +15 -7
- package/src/index.ts +50 -5
- package/src/notifications/deviceNotifications.ts +395 -0
- package/src/ui/boot/__tests__/coldBootWebAuthMode.test.ts +281 -0
- package/src/ui/boot/runProviderColdBoot.ts +83 -13
- package/src/ui/client.ts +0 -1
- package/src/ui/components/AvatarCameraBadge.tsx +1 -1
- package/src/ui/components/OxyAccountDialogScreen.tsx +20 -3
- package/src/ui/components/OxyAuthChooser.tsx +91 -1230
- package/src/ui/components/OxyConsentScreen.tsx +56 -13
- package/src/ui/components/OxyProvider.tsx +4 -4
- package/src/ui/components/OxySignInButton.tsx +119 -78
- package/src/ui/components/OxySignInRequestSurface.tsx +202 -0
- package/src/ui/components/ProfileButton.tsx +1 -1
- package/src/ui/components/SettingsIcon.tsx +1 -1
- package/src/ui/components/__tests__/OxyConsentScreen.test.tsx +27 -0
- package/src/ui/components/authChooser/AccountsMenuView.tsx +569 -0
- package/src/ui/components/authChooser/SignInEntryView.tsx +121 -0
- package/src/ui/components/authChooser/SignInRequestView.tsx +130 -0
- package/src/ui/components/authChooser/SignUpView.tsx +174 -0
- package/src/ui/components/authChooser/TroubleDisclosure.tsx +73 -0
- package/src/ui/components/authChooser/primitives.tsx +144 -0
- package/src/ui/components/authChooser/requestSurfaces.tsx +120 -0
- package/src/ui/components/authChooser/signInProgress.ts +54 -0
- package/src/ui/components/{oxyAuthChooserStyles.ts → authChooser/styles.ts} +18 -0
- package/src/ui/components/authChooser/types.ts +120 -0
- package/src/ui/components/authChooser/useUsernameAvailability.ts +60 -0
- package/src/ui/components/fileManagement/AnimatedButton.tsx +1 -1
- package/src/ui/components/fileManagement/FileDetailsModal.tsx +1 -1
- package/src/ui/components/fileManagement/FileViewer.tsx +1 -1
- package/src/ui/components/fileManagement/UploadPreview.tsx +1 -1
- package/src/ui/components/modals/DeleteAccountModal.tsx +1 -1
- package/src/ui/components/payment/PaymentDetailsStep.tsx +1 -1
- package/src/ui/components/payment/PaymentMethodStep.tsx +1 -1
- package/src/ui/components/payment/PaymentReviewStep.tsx +1 -1
- package/src/ui/components/payment/PaymentSuccessStep.tsx +1 -1
- package/src/ui/components/payment/PaymentSummaryStep.tsx +1 -1
- package/src/ui/components/payment/types.ts +1 -1
- package/src/ui/context/OxyContext.tsx +220 -24
- package/src/ui/context/__tests__/commitSessionFlow.test.ts +89 -0
- package/src/ui/context/commitSessionFlow.ts +61 -0
- package/src/ui/context/oxyContextTypes.ts +45 -1
- package/src/ui/context/useOxyAccountGraph.ts +19 -5
- package/src/ui/hooks/useSwitchableAccounts.ts +12 -1
- package/src/ui/index.ts +0 -1
- package/src/ui/oauth/__tests__/browserAuthTransport.test.ts +335 -0
- package/src/ui/oauth/__tests__/completeOAuthCode.test.ts +142 -0
- package/src/ui/oauth/__tests__/oauthPopup.test.ts +326 -0
- package/src/ui/oauth/__tests__/oauthPopupMessages.test.ts +189 -0
- package/src/ui/oauth/__tests__/sharedCompletionPath.test.ts +174 -0
- package/src/ui/oauth/browserAuthTransport.ts +187 -0
- package/src/ui/oauth/completeOAuthCode.ts +93 -0
- package/src/ui/oauth/legacyRedirectLanes.ts +43 -0
- package/src/ui/oauth/oauthHandshake.ts +74 -0
- package/src/ui/oauth/oauthPopup.ts +219 -0
- package/src/ui/oauth/oauthPopupMessages.ts +136 -0
- package/src/ui/oauth/types.ts +150 -0
- package/src/ui/screens/AccountMembersScreen.tsx +1 -1
- package/src/ui/screens/CreateAccountScreen.tsx +1 -1
- package/src/ui/screens/EditProfileFieldScreen.tsx +1 -1
- package/src/ui/screens/FAQScreen.tsx +1 -1
- package/src/ui/screens/FeedbackScreen.tsx +2 -1
- package/src/ui/screens/FileManagementScreen.tsx +2 -1
- package/src/ui/screens/LanguageSelectorScreen.tsx +1 -1
- package/src/ui/screens/ManageAccountScreen.tsx +1 -1
- package/src/ui/screens/PaymentGatewayScreen.tsx +1 -1
- package/src/ui/screens/PremiumSubscriptionScreen.tsx +1 -1
- package/src/ui/screens/ProfileScreen.tsx +1 -1
- package/src/ui/screens/UserListScreen.tsx +1 -1
- package/src/ui/screens/WelcomeNewUserScreen.tsx +1 -1
- package/src/ui/screens/fileManagement/FileLibraryError.tsx +1 -1
- package/src/ui/screens/fileManagement/FileListSection.tsx +1 -1
- package/src/ui/screens/fileManagement/PhotoPickerSection.tsx +2 -1
- package/src/ui/screens/fileManagement/UploadBar.tsx +1 -1
- package/src/ui/screens/trust/TrustCenterScreen.tsx +1 -1
- package/src/ui/screens/trust/TrustLeaderboardScreen.tsx +1 -1
- package/src/ui/screens/trust/TrustRewardsScreen.tsx +1 -1
- package/src/ui/server.ts +0 -2
- package/src/ui/session/__tests__/createSessionClient.test.ts +26 -0
- package/src/ui/session/__tests__/tokenTransport.test.ts +34 -0
- package/src/ui/session/authStore.ts +5 -89
- package/src/ui/session/createSessionClient.ts +15 -2
- package/src/ui/session/identityBinding.ts +116 -0
- package/src/ui/session/index.ts +6 -2
- package/src/ui/session/nativeSecureStorage.ts +98 -0
- package/src/ui/session/tokenTransport.ts +14 -1
- package/src/ui/types/navigation.ts +44 -1
- package/src/ui/utils/crossOriginRestore.ts +4 -7
- package/src/ui/utils/deliveryPlatform.ts +65 -0
- package/src/ui/utils/fileManagement.ts +1 -1
- package/src/ui/utils/oauthReturn.ts +74 -65
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
- package/lib/commonjs/assets/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
- package/lib/commonjs/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/commonjs/ui/components/FontLoader.js +0 -35
- package/lib/commonjs/ui/components/FontLoader.js.map +0 -1
- package/lib/commonjs/ui/components/FontLoader.native.js +0 -88
- package/lib/commonjs/ui/components/FontLoader.native.js.map +0 -1
- package/lib/commonjs/ui/components/oxyAuthChooserStyles.js.map +0 -1
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
- package/lib/module/assets/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
- package/lib/module/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
- package/lib/module/ui/components/FontLoader.js +0 -29
- package/lib/module/ui/components/FontLoader.js.map +0 -1
- package/lib/module/ui/components/FontLoader.native.js +0 -83
- package/lib/module/ui/components/FontLoader.native.js.map +0 -1
- package/lib/module/ui/components/oxyAuthChooserStyles.js.map +0 -1
- package/lib/typescript/commonjs/ui/components/FontLoader.d.ts +0 -24
- package/lib/typescript/commonjs/ui/components/FontLoader.d.ts.map +0 -1
- package/lib/typescript/commonjs/ui/components/FontLoader.native.d.ts +0 -13
- package/lib/typescript/commonjs/ui/components/FontLoader.native.d.ts.map +0 -1
- package/lib/typescript/commonjs/ui/components/oxyAuthChooserStyles.d.ts.map +0 -1
- package/lib/typescript/module/ui/components/FontLoader.d.ts +0 -24
- package/lib/typescript/module/ui/components/FontLoader.d.ts.map +0 -1
- package/lib/typescript/module/ui/components/FontLoader.native.d.ts +0 -13
- package/lib/typescript/module/ui/components/FontLoader.native.d.ts.map +0 -1
- package/lib/typescript/module/ui/components/oxyAuthChooserStyles.d.ts.map +0 -1
- package/src/assets/fonts/Inter/Inter_18pt-Black.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-Bold.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-ExtraBold.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-Light.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-Medium.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-Regular.ttf +0 -0
- package/src/assets/fonts/Inter/Inter_18pt-SemiBold.ttf +0 -0
- package/src/ui/components/FontLoader.native.tsx +0 -88
- package/src/ui/components/FontLoader.tsx +0 -27
|
@@ -0,0 +1,380 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.getExpoPushToken = getExpoPushToken;
|
|
7
|
+
exports.hasNotificationPermission = hasNotificationPermission;
|
|
8
|
+
exports.installForegroundNotificationHandler = installForegroundNotificationHandler;
|
|
9
|
+
exports.pushTokenPlatform = pushTokenPlatform;
|
|
10
|
+
exports.requestNotificationPermission = requestNotificationPermission;
|
|
11
|
+
exports.subscribeToNotificationResponses = subscribeToNotificationResponses;
|
|
12
|
+
exports.takeLaunchNotificationData = takeLaunchNotificationData;
|
|
13
|
+
var _core = require("@oxyhq/core");
|
|
14
|
+
var _reactNative = require("react-native");
|
|
15
|
+
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); } /**
|
|
16
|
+
* The ONE place `@oxyhq/services` touches `expo-notifications`.
|
|
17
|
+
*
|
|
18
|
+
* Every Oxy app that receives push needs the identical adapter — native-only,
|
|
19
|
+
* dynamically imported, reading the OS permission and minting an EXPO push
|
|
20
|
+
* token — so it lives here instead of being copied into each app. The
|
|
21
|
+
* bearer-authenticated transport (`registerPushToken` / `unregisterPushToken`)
|
|
22
|
+
* already lives in `@oxyhq/core`; core may never import an `expo-*` module, and
|
|
23
|
+
* this adapter is the Expo-side half that closes that gap.
|
|
24
|
+
*
|
|
25
|
+
* ## Native-only by construction
|
|
26
|
+
*
|
|
27
|
+
* Every entry point resolves its null/no-op result from `Platform.OS` BEFORE the
|
|
28
|
+
* dynamic `import()`, so a web bundle never requests `expo-notifications` at all.
|
|
29
|
+
* `expo-notifications` and `expo-constants` are OPTIONAL peer dependencies: an
|
|
30
|
+
* app that does not use push never installs them, and a build without them
|
|
31
|
+
* degrades to "notifications unavailable" rather than throwing at
|
|
32
|
+
* module-evaluation time.
|
|
33
|
+
*
|
|
34
|
+
* ## The token is an EXPO push token — never a raw device token
|
|
35
|
+
*
|
|
36
|
+
* {@link getExpoPushToken} calls `getExpoPushTokenAsync()`, which returns the
|
|
37
|
+
* `ExponentPushToken[…]` handle Expo's push service delivers through — the only
|
|
38
|
+
* form it accepts. `getDevicePushTokenAsync()` — the raw APNs/FCM token — is
|
|
39
|
+
* deliberately NOT used anywhere: registering one of those looks entirely
|
|
40
|
+
* successful (the row is stored, the endpoint returns 200) and then every push
|
|
41
|
+
* silently fails at delivery time. `@oxyhq/core`'s `registerPushToken` rejects a
|
|
42
|
+
* raw device token before sending, and this module is the reason it never has to.
|
|
43
|
+
*
|
|
44
|
+
* ## The payload is untrusted
|
|
45
|
+
*
|
|
46
|
+
* Nothing here surfaces a notification's `title` / `body` / `subtitle`. The only
|
|
47
|
+
* payload that leaves this module is the raw `content.data` — the routing keys —
|
|
48
|
+
* typed `unknown`, so a caller has to validate it before acting on it and there
|
|
49
|
+
* is no exported shape that invites rendering push-delivered text. The
|
|
50
|
+
* foreground handler likewise answers with a visibility verdict and nothing else.
|
|
51
|
+
*/
|
|
52
|
+
const log = (0, _core.createLogger)('deviceNotifications');
|
|
53
|
+
function isRecord(value) {
|
|
54
|
+
return typeof value === 'object' && value !== null;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Load `expo-notifications`, or `null` when it cannot serve this platform/build.
|
|
59
|
+
*
|
|
60
|
+
* The web guard runs before the `import()`, so a web bundle never reaches for the
|
|
61
|
+
* native module. The dynamic import is intentional: the module registry caches
|
|
62
|
+
* it, so repeated calls are cheap and no module-level mutable cache is
|
|
63
|
+
* introduced here.
|
|
64
|
+
*/
|
|
65
|
+
async function loadNotifications() {
|
|
66
|
+
if (_reactNative.Platform.OS === 'web') {
|
|
67
|
+
return null;
|
|
68
|
+
}
|
|
69
|
+
try {
|
|
70
|
+
return await Promise.resolve().then(() => _interopRequireWildcard(require('expo-notifications')));
|
|
71
|
+
} catch (error) {
|
|
72
|
+
log.warn('expo-notifications is unavailable in this build — push is disabled', {
|
|
73
|
+
method: 'loadNotifications'
|
|
74
|
+
}, error);
|
|
75
|
+
return null;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* The EAS project id an Expo push token is minted against, or `null` when the
|
|
81
|
+
* app config carries none.
|
|
82
|
+
*
|
|
83
|
+
* Resolved exactly the way `expo-notifications` resolves it internally
|
|
84
|
+
* (`easConfig.projectId`, then `expoConfig.extra.eas.projectId`) and then handed
|
|
85
|
+
* BACK to `getExpoPushTokenAsync` explicitly, so the two can never disagree.
|
|
86
|
+
* Reading it here is what turns "no project id" from an opaque
|
|
87
|
+
* `ERR_NOTIFICATIONS_NO_EXPERIENCE_ID` rejection into a named, actionable state
|
|
88
|
+
* instead of one more entry in the indistinguishable "permission denied /
|
|
89
|
+
* offline" bucket.
|
|
90
|
+
*
|
|
91
|
+
* A missing `expo-constants` lands on the same `null` outcome — the single
|
|
92
|
+
* actionable warning is emitted once by the caller, so this path only records
|
|
93
|
+
* the extra detail at debug level rather than warning twice for one condition.
|
|
94
|
+
*/
|
|
95
|
+
async function easProjectId() {
|
|
96
|
+
let constants;
|
|
97
|
+
try {
|
|
98
|
+
constants = (await Promise.resolve().then(() => _interopRequireWildcard(require('expo-constants')))).default;
|
|
99
|
+
} catch (error) {
|
|
100
|
+
log.debug('expo-constants is unavailable in this build — no EAS project id can be resolved', {
|
|
101
|
+
method: 'easProjectId'
|
|
102
|
+
}, error);
|
|
103
|
+
return null;
|
|
104
|
+
}
|
|
105
|
+
const fromEasConfig = constants.easConfig?.projectId;
|
|
106
|
+
if (typeof fromEasConfig === 'string' && fromEasConfig.length > 0) {
|
|
107
|
+
return fromEasConfig;
|
|
108
|
+
}
|
|
109
|
+
const extra = constants.expoConfig?.extra;
|
|
110
|
+
const eas = isRecord(extra) ? extra.eas : undefined;
|
|
111
|
+
const projectId = isRecord(eas) ? eas.projectId : undefined;
|
|
112
|
+
return typeof projectId === 'string' && projectId.length > 0 ? projectId : null;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* The platform tag the push-token registry stores this installation under, or
|
|
117
|
+
* `null` on a platform Oxy does not deliver push to.
|
|
118
|
+
*
|
|
119
|
+
* Synchronous and import-free — the answer is a property of the bundle, not of
|
|
120
|
+
* any native module.
|
|
121
|
+
*
|
|
122
|
+
* Web is `null` on purpose: the registry accepts a `web` platform, but browser
|
|
123
|
+
* push needs a VAPID key + service-worker subscription no Oxy app has wired, so
|
|
124
|
+
* there is no token to register and claiming otherwise would store a row nothing
|
|
125
|
+
* can ever deliver to.
|
|
126
|
+
*/
|
|
127
|
+
function pushTokenPlatform() {
|
|
128
|
+
return _reactNative.Platform.OS === 'ios' || _reactNative.Platform.OS === 'android' ? _reactNative.Platform.OS : null;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* Whether the OS notification permission is ALREADY granted.
|
|
133
|
+
*
|
|
134
|
+
* Never prompts, so an app can re-check on every cold boot without ever asking
|
|
135
|
+
* the user twice. Use {@link requestNotificationPermission} for the one place
|
|
136
|
+
* that is allowed to show the system dialog.
|
|
137
|
+
*/
|
|
138
|
+
async function hasNotificationPermission() {
|
|
139
|
+
const notifications = await loadNotifications();
|
|
140
|
+
if (!notifications) {
|
|
141
|
+
return false;
|
|
142
|
+
}
|
|
143
|
+
try {
|
|
144
|
+
const permissions = await notifications.getPermissionsAsync();
|
|
145
|
+
return permissions.granted === true;
|
|
146
|
+
} catch (error) {
|
|
147
|
+
log.warn('could not read the notification permission', {
|
|
148
|
+
method: 'hasNotificationPermission'
|
|
149
|
+
}, error);
|
|
150
|
+
return false;
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* Ensure the OS notification permission, prompting at most once.
|
|
156
|
+
*
|
|
157
|
+
* An installation that already answered the system dialog is never asked again:
|
|
158
|
+
* an already-granted permission resolves `true` without a second dialog, and a
|
|
159
|
+
* denial with `canAskAgain: false` resolves `false` without issuing a request
|
|
160
|
+
* the OS would silently ignore.
|
|
161
|
+
*
|
|
162
|
+
* @returns Whether notifications are granted once this call is done.
|
|
163
|
+
*/
|
|
164
|
+
async function requestNotificationPermission() {
|
|
165
|
+
const notifications = await loadNotifications();
|
|
166
|
+
if (!notifications) {
|
|
167
|
+
return false;
|
|
168
|
+
}
|
|
169
|
+
try {
|
|
170
|
+
const existing = await notifications.getPermissionsAsync();
|
|
171
|
+
if (existing.granted === true) {
|
|
172
|
+
return true;
|
|
173
|
+
}
|
|
174
|
+
if (existing.canAskAgain === false) {
|
|
175
|
+
return false;
|
|
176
|
+
}
|
|
177
|
+
const requested = await notifications.requestPermissionsAsync();
|
|
178
|
+
return requested.granted === true;
|
|
179
|
+
} catch (error) {
|
|
180
|
+
log.warn('the notification permission could not be resolved', {
|
|
181
|
+
method: 'requestNotificationPermission'
|
|
182
|
+
}, error);
|
|
183
|
+
return false;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/**
|
|
188
|
+
* This installation's Expo push token (`ExponentPushToken[…]`), or `null` when
|
|
189
|
+
* one cannot be minted.
|
|
190
|
+
*
|
|
191
|
+
* Deliberately `getExpoPushTokenAsync` — see the module header for why the raw
|
|
192
|
+
* device-token variant is never used.
|
|
193
|
+
*
|
|
194
|
+
* Every `null` is logged with the reason it happened. A missing EAS project id
|
|
195
|
+
* in particular is a BUILD MISCONFIGURATION, not a user state: no token can ever
|
|
196
|
+
* be minted, so push is off for every install of that build until the config is
|
|
197
|
+
* fixed. It is reported as such rather than blending into the
|
|
198
|
+
* indistinguishable "permission denied / offline" bucket.
|
|
199
|
+
*/
|
|
200
|
+
async function getExpoPushToken() {
|
|
201
|
+
const notifications = await loadNotifications();
|
|
202
|
+
if (!notifications) {
|
|
203
|
+
return null;
|
|
204
|
+
}
|
|
205
|
+
const projectId = await easProjectId();
|
|
206
|
+
if (!projectId) {
|
|
207
|
+
log.warn('no EAS project id in the app config (expo.extra.eas.projectId) — an Expo push token cannot be minted, so push is disabled for this build', {
|
|
208
|
+
method: 'getExpoPushToken'
|
|
209
|
+
});
|
|
210
|
+
return null;
|
|
211
|
+
}
|
|
212
|
+
try {
|
|
213
|
+
const token = await notifications.getExpoPushTokenAsync({
|
|
214
|
+
projectId
|
|
215
|
+
});
|
|
216
|
+
if (token.data.length === 0) {
|
|
217
|
+
log.warn('the Expo push service returned an empty token', {
|
|
218
|
+
method: 'getExpoPushToken'
|
|
219
|
+
});
|
|
220
|
+
return null;
|
|
221
|
+
}
|
|
222
|
+
return token.data;
|
|
223
|
+
} catch (error) {
|
|
224
|
+
log.warn('could not mint an Expo push token', {
|
|
225
|
+
method: 'getExpoPushToken'
|
|
226
|
+
}, error);
|
|
227
|
+
return null;
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
/**
|
|
232
|
+
* Take the payload of the notification that COLD-LAUNCHED the app, if any.
|
|
233
|
+
*
|
|
234
|
+
* "Take" is literal: the response is cleared from `expo-notifications` once
|
|
235
|
+
* read, so a listener attached later in the same launch is not handed the same
|
|
236
|
+
* tap again. Clearing is best-effort across OS/module versions, so a caller that
|
|
237
|
+
* must not act twice still needs its own idempotency ledger.
|
|
238
|
+
*
|
|
239
|
+
* @returns The raw, untrusted `content.data` of the launching notification, or
|
|
240
|
+
* `null`. Parsing/validation is the caller's job.
|
|
241
|
+
*/
|
|
242
|
+
async function takeLaunchNotificationData() {
|
|
243
|
+
const notifications = await loadNotifications();
|
|
244
|
+
if (!notifications) {
|
|
245
|
+
return null;
|
|
246
|
+
}
|
|
247
|
+
try {
|
|
248
|
+
const response = notifications.getLastNotificationResponse();
|
|
249
|
+
if (!response) {
|
|
250
|
+
return null;
|
|
251
|
+
}
|
|
252
|
+
const data = response.notification.request.content.data;
|
|
253
|
+
try {
|
|
254
|
+
notifications.clearLastNotificationResponse();
|
|
255
|
+
} catch (clearError) {
|
|
256
|
+
log.warn('could not clear the launching notification response', {
|
|
257
|
+
method: 'takeLaunchNotificationData'
|
|
258
|
+
}, clearError);
|
|
259
|
+
}
|
|
260
|
+
return data;
|
|
261
|
+
} catch (error) {
|
|
262
|
+
log.warn('could not read the launching notification', {
|
|
263
|
+
method: 'takeLaunchNotificationData'
|
|
264
|
+
}, error);
|
|
265
|
+
return null;
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
|
|
269
|
+
/**
|
|
270
|
+
* What the OS should do with a notification that arrives while the app is
|
|
271
|
+
* FOREGROUNDED.
|
|
272
|
+
*
|
|
273
|
+
* `'suppress'` is `expo-notifications`' own default for a foregrounded app, so a
|
|
274
|
+
* decision function that only ever returns `'show'` for the payloads it
|
|
275
|
+
* recognises leaves every other notification exactly as it behaves today.
|
|
276
|
+
*/
|
|
277
|
+
|
|
278
|
+
/**
|
|
279
|
+
* Whether the process-wide foreground handler has already been ATTEMPTED.
|
|
280
|
+
*
|
|
281
|
+
* `setNotificationHandler` is global, last-writer-wins process state, so this is
|
|
282
|
+
* a one-shot install rather than something a mount/unmount cycle owns. A failed
|
|
283
|
+
* attempt is deliberately not retried: the only failure modes are permanent for
|
|
284
|
+
* the life of the process (web, a build without the native module, a native
|
|
285
|
+
* module that threw on registration).
|
|
286
|
+
*
|
|
287
|
+
* Module-scoped and only ever touched from an async install call — never read
|
|
288
|
+
* during render, so the React Compiler has no memoizable position to freeze it
|
|
289
|
+
* into.
|
|
290
|
+
*/
|
|
291
|
+
let foregroundHandlerAttempted = false;
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* Install the ONE process-wide handler that decides whether an incoming
|
|
295
|
+
* notification is shown while the app is in the FOREGROUND.
|
|
296
|
+
*
|
|
297
|
+
* Without a handler, `expo-notifications` shows nothing at all while the app is
|
|
298
|
+
* open — which is exactly when a time-critical notification (a "Sign in with
|
|
299
|
+
* Oxy" approval request, say) matters most, because the user is already holding
|
|
300
|
+
* the phone.
|
|
301
|
+
*
|
|
302
|
+
* The handler ONLY decides visibility. It never navigates, never acts on the
|
|
303
|
+
* notification, and never reads the payload for display — `decide` is handed the
|
|
304
|
+
* raw, untrusted `content.data` and may answer nothing but `'show'` /
|
|
305
|
+
* `'suppress'`. Acting on a notification stays with a TAP, routed by
|
|
306
|
+
* {@link subscribeToNotificationResponses}. No notification actions/categories
|
|
307
|
+
* are registered here, so the banner cannot carry an action button.
|
|
308
|
+
*
|
|
309
|
+
* The one-shot latch is set BEFORE the first `await`, so concurrent callers
|
|
310
|
+
* cannot both reach `setNotificationHandler`.
|
|
311
|
+
*
|
|
312
|
+
* @param decide - Maps the raw, untrusted payload to a presentation verdict.
|
|
313
|
+
* Must not throw; a throw is reported by the OS as a handling error and the
|
|
314
|
+
* notification is dropped.
|
|
315
|
+
* @returns Whether a handler was installed by THIS call (`false` on a repeat
|
|
316
|
+
* call, on web, or when the native module is unavailable).
|
|
317
|
+
*/
|
|
318
|
+
async function installForegroundNotificationHandler(decide) {
|
|
319
|
+
if (foregroundHandlerAttempted) {
|
|
320
|
+
return false;
|
|
321
|
+
}
|
|
322
|
+
foregroundHandlerAttempted = true;
|
|
323
|
+
const notifications = await loadNotifications();
|
|
324
|
+
if (!notifications) {
|
|
325
|
+
return false;
|
|
326
|
+
}
|
|
327
|
+
try {
|
|
328
|
+
notifications.setNotificationHandler({
|
|
329
|
+
handleNotification: async notification => {
|
|
330
|
+
const data = notification.request.content.data;
|
|
331
|
+
const show = decide(data) === 'show';
|
|
332
|
+
return {
|
|
333
|
+
// Banner: the whole point — make the notification visible on screen.
|
|
334
|
+
shouldShowBanner: show,
|
|
335
|
+
// Notification centre: so the user can still review it after
|
|
336
|
+
// dismissing the banner.
|
|
337
|
+
shouldShowList: show,
|
|
338
|
+
// No sound: the app is foregrounded, so the user is already looking at
|
|
339
|
+
// the screen the banner appears on.
|
|
340
|
+
shouldPlaySound: false,
|
|
341
|
+
// Badging is an app-level unread concept this adapter has no view of.
|
|
342
|
+
shouldSetBadge: false
|
|
343
|
+
};
|
|
344
|
+
}
|
|
345
|
+
});
|
|
346
|
+
return true;
|
|
347
|
+
} catch (error) {
|
|
348
|
+
log.warn('could not install the foreground notification handler', {
|
|
349
|
+
method: 'installForegroundNotificationHandler'
|
|
350
|
+
}, error);
|
|
351
|
+
return false;
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
/**
|
|
356
|
+
* Subscribe to notification TAPS (responses) while the app is running.
|
|
357
|
+
*
|
|
358
|
+
* @param listener - Receives the raw, untrusted `content.data` of the tapped
|
|
359
|
+
* notification. Parsing/validation is the caller's job.
|
|
360
|
+
* @returns An unsubscribe function. Safe to call even if the subscription could
|
|
361
|
+
* not be established.
|
|
362
|
+
*/
|
|
363
|
+
async function subscribeToNotificationResponses(listener) {
|
|
364
|
+
const notifications = await loadNotifications();
|
|
365
|
+
if (!notifications) {
|
|
366
|
+
return () => undefined;
|
|
367
|
+
}
|
|
368
|
+
try {
|
|
369
|
+
const subscription = notifications.addNotificationResponseReceivedListener(response => {
|
|
370
|
+
listener(response.notification.request.content.data);
|
|
371
|
+
});
|
|
372
|
+
return () => subscription.remove();
|
|
373
|
+
} catch (error) {
|
|
374
|
+
log.warn('could not subscribe to notification taps', {
|
|
375
|
+
method: 'subscribeToNotificationResponses'
|
|
376
|
+
}, error);
|
|
377
|
+
return () => undefined;
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
//# sourceMappingURL=deviceNotifications.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_core","require","_reactNative","_interopRequireWildcard","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","log","createLogger","isRecord","value","loadNotifications","Platform","OS","Promise","resolve","then","error","warn","method","easProjectId","constants","debug","fromEasConfig","easConfig","projectId","length","extra","expoConfig","eas","undefined","pushTokenPlatform","hasNotificationPermission","notifications","permissions","getPermissionsAsync","granted","requestNotificationPermission","existing","canAskAgain","requested","requestPermissionsAsync","getExpoPushToken","token","getExpoPushTokenAsync","data","takeLaunchNotificationData","response","getLastNotificationResponse","notification","request","content","clearLastNotificationResponse","clearError","foregroundHandlerAttempted","installForegroundNotificationHandler","decide","setNotificationHandler","handleNotification","show","shouldShowBanner","shouldShowList","shouldPlaySound","shouldSetBadge","subscribeToNotificationResponses","listener","subscription","addNotificationResponseReceivedListener","remove"],"sourceRoot":"../../../src","sources":["notifications/deviceNotifications.ts"],"mappings":";;;;;;;;;;;;AAsCA,IAAAA,KAAA,GAAAC,OAAA;AAEA,IAAAC,YAAA,GAAAD,OAAA;AAAwC,SAAAE,wBAAAC,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAH,uBAAA,YAAAA,CAAAC,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA,KAxCxC;AACA;AACA;AACA;AACA;AACA;AACA;AAC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AY,CAACE,MAAM,CAAC,CAAC;EACpC,CAAC,CAAC,OAAOnD,KAAK,EAAE;IACdV,GAAG,CAACW,IAAI,CACN,0CAA0C,EAC1C;MAAEC,MAAM,EAAE;IAAmC,CAAC,EAC9CF,KACF,CAAC;IACD,OAAO,MAAMa,SAAS;EACxB;AACF","ignoreList":[]}
|
|
@@ -10,6 +10,7 @@ var _deviceCredential = require("../utils/deviceCredential.js");
|
|
|
10
10
|
var _crossOriginRestore = require("../utils/crossOriginRestore.js");
|
|
11
11
|
var _oauthReturn = require("../utils/oauthReturn.js");
|
|
12
12
|
var _isWebBrowser = require("../utils/isWebBrowser.js");
|
|
13
|
+
var _legacyRedirectLanes = require("../oauth/legacyRedirectLanes.js");
|
|
13
14
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
|
|
14
15
|
/** How long the cold boot waits for the post-boot SessionClient handoff (ms). */
|
|
15
16
|
const SESSION_HANDOFF_DEADLINE_MS = exports.SESSION_HANDOFF_DEADLINE_MS = 6000;
|
|
@@ -68,8 +69,18 @@ async function detectOfflineHint() {
|
|
|
68
69
|
*
|
|
69
70
|
* Ordered pipeline:
|
|
70
71
|
* 1. Complete OAuth authorization-code return (web)
|
|
71
|
-
* 2. `runSessionColdBoot` — device-secret mint (+ native shared-key
|
|
72
|
+
* 2. `runSessionColdBoot` — device-secret mint (+ native shared-key, or the
|
|
73
|
+
* primary-identity-key lane in `sessionMode: 'identity'`)
|
|
72
74
|
* 3. Silent OAuth for all web apps when mint finds no session
|
|
75
|
+
*
|
|
76
|
+
* Steps 1 and 3 are ACCOUNT-MODE ONLY: both commit whichever account the IdP
|
|
77
|
+
* resolves, which for an identity-bound client is somebody else's account by
|
|
78
|
+
* construction. In `'identity'` mode the boot is exactly step 2.
|
|
79
|
+
*
|
|
80
|
+
* Step 3 is additionally REDIRECT-MODE ONLY: it navigates the top-level window
|
|
81
|
+
* with no user gesture behind it, which `webAuthMode: 'popup'` exists to
|
|
82
|
+
* eliminate. In popup mode the boot is steps 1 and 2, and a domain with no local
|
|
83
|
+
* credential simply resolves signed out. See `allowsAutomaticIdpRedirect`.
|
|
73
84
|
*/
|
|
74
85
|
async function runProviderColdBoot(opts) {
|
|
75
86
|
const {
|
|
@@ -78,17 +89,34 @@ async function runProviderColdBoot(opts) {
|
|
|
78
89
|
clientId,
|
|
79
90
|
authRedirectUri,
|
|
80
91
|
authorizeBaseUrl,
|
|
92
|
+
sessionMode = 'account',
|
|
93
|
+
identity,
|
|
94
|
+
webAuthMode = 'redirect',
|
|
81
95
|
sessionClient,
|
|
82
96
|
syncDeviceCredentialToHost,
|
|
83
97
|
commitSession,
|
|
84
98
|
markAuthResolved,
|
|
85
99
|
setTokenReady
|
|
86
100
|
} = opts;
|
|
101
|
+
const identityBound = sessionMode === 'identity';
|
|
87
102
|
setTokenReady(false);
|
|
88
103
|
try {
|
|
104
|
+
// MODE-INDEPENDENT URL cleanup, deliberately so: both consume query params a
|
|
105
|
+
// PREVIOUS redirect-mode session left in the address bar (`?error=login_required`
|
|
106
|
+
// from a silent authorize, `?hub_sync=failed` from the hub) and restore the
|
|
107
|
+
// page the visit started on. Flipping an app to popup mode must not strand
|
|
108
|
+
// those params, so neither is gated on `webAuthMode`. Neither starts a
|
|
109
|
+
// navigation — they only rewrite the URL via `history.replaceState`.
|
|
89
110
|
(0, _crossOriginRestore.consumeSilentOAuthError)();
|
|
90
111
|
(0, _oauthReturn.consumeHubSyncFailure)();
|
|
91
|
-
|
|
112
|
+
|
|
113
|
+
// The redirect transport's RETURN leg — also NOT gated on `webAuthMode`. A
|
|
114
|
+
// popup-mode app legitimately lands here with `?code=` whenever the browser
|
|
115
|
+
// blocked the popup and `startWebOAuthSignIn` fell back to a full-page
|
|
116
|
+
// redirect (`popup-blocked` / `popup-navigation-failed`), and an app that
|
|
117
|
+
// switched modes mid-flight must not be stranded with a dead `?code=`
|
|
118
|
+
// either. It consumes a code already on the URL; it never starts one.
|
|
119
|
+
const oauthCompleted = identityBound ? false : await (0, _oauthReturn.tryCompleteOAuthReturn)({
|
|
92
120
|
oxyServices,
|
|
93
121
|
clientId,
|
|
94
122
|
authRedirectUri,
|
|
@@ -115,6 +143,8 @@ async function runProviderColdBoot(opts) {
|
|
|
115
143
|
isWeb: (0, _isWebBrowser.isWebBrowser)(),
|
|
116
144
|
isNative: !(0, _isWebBrowser.isWebBrowser)()
|
|
117
145
|
},
|
|
146
|
+
sessionMode,
|
|
147
|
+
identity,
|
|
118
148
|
overallDeadlineMs: COLD_BOOT_OVERALL_DEADLINE_MS,
|
|
119
149
|
isOffline: () => offline,
|
|
120
150
|
onStepDeadline: stepId => {
|
|
@@ -169,14 +199,26 @@ async function runProviderColdBoot(opts) {
|
|
|
169
199
|
}
|
|
170
200
|
});
|
|
171
201
|
|
|
172
|
-
// Silent cross-origin OAuth restore (web cross-app SSO)
|
|
173
|
-
//
|
|
174
|
-
//
|
|
175
|
-
//
|
|
176
|
-
//
|
|
177
|
-
//
|
|
202
|
+
// Silent cross-origin OAuth restore (web cross-app SSO): a full-page
|
|
203
|
+
// `prompt=none` bounce to the IdP when the mint found no local session.
|
|
204
|
+
//
|
|
205
|
+
// TRANSPORT gate (`allowsAutomaticIdpRedirect`): `webAuthMode: 'popup'`
|
|
206
|
+
// FORBIDS this lane. It navigates the top-level window with no user gesture
|
|
207
|
+
// behind it, which is precisely what popup mode exists to eliminate — a
|
|
208
|
+
// popup-mode domain without a local credential resolves signed out right
|
|
209
|
+
// here and waits for the user's next explicit "Continue with Oxy" (issue
|
|
210
|
+
// #691, "Cold boot and cross-domain behavior"). `'redirect'` — still the
|
|
211
|
+
// default and the compatibility path — reaches this lane unchanged, and this
|
|
212
|
+
// whole block disappears with the transport in phase 7b.
|
|
213
|
+
//
|
|
214
|
+
// ORIGIN gate: same as the hub-sync WRITE side (`syncHubAfterSignIn`) —
|
|
215
|
+
// official web origins only, never the IdP hub itself, and — unlike the
|
|
216
|
+
// write side — never a loopback / local-dev origin (which must not be
|
|
217
|
+
// bounced to a hosted IdP on cold boot). The authorize endpoint is
|
|
218
|
+
// env-configurable so a local/staging app targets its own IdP instead of
|
|
219
|
+
// production.
|
|
178
220
|
const webOrigin = (0, _isWebBrowser.isWebBrowser)() ? globalThis.location?.origin : undefined;
|
|
179
|
-
if (clientId && outcome.kind !== 'session' && webOrigin && (0, _crossOriginRestore.isSilentRestoreEligibleOrigin)(webOrigin)) {
|
|
221
|
+
if (!identityBound && (0, _legacyRedirectLanes.allowsAutomaticIdpRedirect)(webAuthMode) && clientId && outcome.kind !== 'session' && webOrigin && (0, _crossOriginRestore.isSilentRestoreEligibleOrigin)(webOrigin)) {
|
|
180
222
|
const redirected = await (0, _crossOriginRestore.maybeStartSilentOAuthRestore)({
|
|
181
223
|
oxyServices,
|
|
182
224
|
clientId,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_core","require","_deviceCredential","_crossOriginRestore","_oauthReturn","_isWebBrowser","_interopRequireWildcard","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","SESSION_HANDOFF_DEADLINE_MS","exports","COLD_BOOT_OVERALL_DEADLINE_MS","OFFLINE_PROBE_TIMEOUT_MS","detectOfflineHint","isWebBrowser","online","globalThis","navigator","onLine","NetInfo","Promise","resolve","then","state","race","fetch","setTimeout","isConnected","runProviderColdBoot","opts","oxyServices","authStore","clientId","authRedirectUri","authorizeBaseUrl","sessionClient","syncDeviceCredentialToHost","commitSession","markAuthResolved","setTokenReady","consumeSilentOAuthError","consumeHubSyncFailure","oauthCompleted","tryCompleteOAuthReturn","input","activate","hubSync","offline","outcome","runSessionColdBoot","oxy","store","platform","isWeb","isNative","overallDeadlineMs","isOffline","onStepDeadline","stepId","loggerUtil","warn","component","method","onSession","session","handoff","sessionId","accessToken","userId","handoffDeadlineId","finally","undefined","clearTimeout","onSignedOut","cred","loadPersistedDeviceCredential","start","socketError","__DEV__","debug","onStepError","id","error","webOrigin","location","origin","kind","isSilentRestoreEligibleOrigin","redirected","maybeStartSilentOAuthRestore","redirectUri","Error","String"],"sourceRoot":"../../../../src","sources":["ui/boot/runProviderColdBoot.ts"],"mappings":";;;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;
|
|
1
|
+
{"version":3,"names":["_core","require","_deviceCredential","_crossOriginRestore","_oauthReturn","_isWebBrowser","_legacyRedirectLanes","_interopRequireWildcard","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","SESSION_HANDOFF_DEADLINE_MS","exports","COLD_BOOT_OVERALL_DEADLINE_MS","OFFLINE_PROBE_TIMEOUT_MS","detectOfflineHint","isWebBrowser","online","globalThis","navigator","onLine","NetInfo","Promise","resolve","then","state","race","fetch","setTimeout","isConnected","runProviderColdBoot","opts","oxyServices","authStore","clientId","authRedirectUri","authorizeBaseUrl","sessionMode","identity","webAuthMode","sessionClient","syncDeviceCredentialToHost","commitSession","markAuthResolved","setTokenReady","identityBound","consumeSilentOAuthError","consumeHubSyncFailure","oauthCompleted","tryCompleteOAuthReturn","input","activate","hubSync","offline","outcome","runSessionColdBoot","oxy","store","platform","isWeb","isNative","overallDeadlineMs","isOffline","onStepDeadline","stepId","loggerUtil","warn","component","method","onSession","session","handoff","sessionId","accessToken","userId","handoffDeadlineId","finally","undefined","clearTimeout","onSignedOut","cred","loadPersistedDeviceCredential","start","socketError","__DEV__","debug","onStepError","id","error","webOrigin","location","origin","allowsAutomaticIdpRedirect","kind","isSilentRestoreEligibleOrigin","redirected","maybeStartSilentOAuthRestore","redirectUri","Error","String"],"sourceRoot":"../../../../src","sources":["ui/boot/runProviderColdBoot.ts"],"mappings":";;;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AASA,IAAAC,iBAAA,GAAAD,OAAA;AACA,IAAAE,mBAAA,GAAAF,OAAA;AAKA,IAAAG,YAAA,GAAAH,OAAA;AACA,IAAAI,aAAA,GAAAJ,OAAA;AACA,IAAAK,oBAAA,GAAAL,OAAA;AAA0E,SAAAM,wBAAAC,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAH,uBAAA,YAAAA,CAAAC,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD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AAK,KAAK;QAC1B,IAAIJ,OAAO,EAAE;UACXnB,YAAU,CAACoB,KAAK,CACd,mBAAmBE,EAAE,wCAAwC,EAC7D;YAAEpB,SAAS,EAAE;UAAsB,CAAC,EACpCqB,KACF,CAAC;QACH;MACF;IACF,CAAC,CAAC;;IAEF;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA;IACA,MAAMC,SAAS,GAAG,IAAAzE,0BAAY,EAAC,CAAC,GAC3BE,UAAU,CAA6BwE,QAAQ,EAAEC,MAAM,GACxDd,SAAS;IACb,IACE,CAAChC,aAAa,IACd,IAAA+C,+CAA0B,EAACrD,WAAW,CAAC,IACvCL,QAAQ,IACRoB,OAAO,CAACuC,IAAI,KAAK,SAAS,IAC1BJ,SAAS,IACT,IAAAK,iDAA6B,EAACL,SAAS,CAAC,EACxC;MACA,MAAMM,UAAU,GAAG,MAAM,IAAAC,gDAA4B,EAAC;QACpDhE,WAAW;QACXE,QAAQ;QACR+D,WAAW,EAAE9D,eAAe;QAC5BC;MACF,CAAC,CAAC;MACF,IAAI2D,UAAU,EAAE;QACd;MACF;IACF;EACF,CAAC,CAAC,OAAOP,KAAK,EAAE;IACd,IAAIJ,OAAO,EAAE;MACXnB,YAAU,CAACuB,KAAK,CACd,iBAAiB,EACjBA,KAAK,YAAYU,KAAK,GAAGV,KAAK,GAAG,IAAIU,KAAK,CAACC,MAAM,CAACX,KAAK,CAAC,CAAC,EACzD;QAAErB,SAAS,EAAE;MAAsB,CACrC,CAAC;IACH;EACF,CAAC,SAAS;IACRxB,gBAAgB,CAAC,CAAC;EACpB;AACF","ignoreList":[]}
|
|
@@ -9,12 +9,6 @@ Object.defineProperty(exports, "FollowButton", {
|
|
|
9
9
|
return _FollowButton.default;
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
Object.defineProperty(exports, "FontLoader", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _FontLoader.FontLoader;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
12
|
Object.defineProperty(exports, "LogoIcon", {
|
|
19
13
|
enumerable: true,
|
|
20
14
|
get: function () {
|
|
@@ -87,12 +81,6 @@ Object.defineProperty(exports, "isTimeoutOrNetworkError", {
|
|
|
87
81
|
return _errorHandlers.isTimeoutOrNetworkError;
|
|
88
82
|
}
|
|
89
83
|
});
|
|
90
|
-
Object.defineProperty(exports, "setupFonts", {
|
|
91
|
-
enumerable: true,
|
|
92
|
-
get: function () {
|
|
93
|
-
return _FontLoader.setupFonts;
|
|
94
|
-
}
|
|
95
|
-
});
|
|
96
84
|
Object.defineProperty(exports, "useAccountStore", {
|
|
97
85
|
enumerable: true,
|
|
98
86
|
get: function () {
|
|
@@ -136,7 +124,6 @@ var _LogoIcon = require("./components/logo/LogoIcon.js");
|
|
|
136
124
|
var _LogoText = require("./components/logo/LogoText.js");
|
|
137
125
|
var _FollowButton = _interopRequireDefault(require("./components/FollowButton.js"));
|
|
138
126
|
var _OxyPayButton = _interopRequireDefault(require("./components/OxyPayButton.js"));
|
|
139
|
-
var _FontLoader = require("./components/FontLoader");
|
|
140
127
|
var _OxyContext = require("./context/OxyContext.js");
|
|
141
128
|
var _useAuth = require("./hooks/useAuth.js");
|
|
142
129
|
var _useFollow = require("./hooks/useFollow.js");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_OxyProvider","_interopRequireDefault","require","_OxySignInButton","_OxyAuthPrompt","_LogoIcon","_LogoText","_FollowButton","_OxyPayButton","
|
|
1
|
+
{"version":3,"names":["_OxyProvider","_interopRequireDefault","require","_OxySignInButton","_OxyAuthPrompt","_LogoIcon","_LogoText","_FollowButton","_OxyPayButton","_OxyContext","_useAuth","_useFollow","_useStorage","_ProfileScreen","_ManageAccountScreen","_authStore","_accountStore","_errorHandlers","e","__esModule","default"],"sourceRoot":"../../../src","sources":["ui/client.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAWA,IAAAA,YAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,gBAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,cAAA,GAAAH,sBAAA,CAAAC,OAAA;AAEA,IAAAG,SAAA,GAAAH,OAAA;AACA,IAAAI,SAAA,GAAAJ,OAAA;AACA,IAAAK,aAAA,GAAAN,sBAAA,CAAAC,OAAA;AACA,IAAAM,aAAA,GAAAP,sBAAA,CAAAC,OAAA;AAGA,IAAAO,WAAA,GAAAP,OAAA;AAGA,IAAAQ,QAAA,GAAAR,OAAA;AAEA,IAAAS,UAAA,GAAAT,OAAA;AACA,IAAAU,WAAA,GAAAV,OAAA;AAIA,IAAAW,cAAA,GAAAZ,sBAAA,CAAAC,OAAA;AACA,IAAAY,oBAAA,GAAAb,sBAAA,CAAAC,OAAA;AAGA,IAAAa,UAAA,GAAAb,OAAA;AACA,IAAAc,aAAA,GAAAd,OAAA;AAGA,IAAAe,cAAA,GAAAf,OAAA;AAK+B,SAAAD,uBAAAiB,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA","ignoreList":[]}
|
|
@@ -5,9 +5,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _reactNative = require("react-native");
|
|
8
|
-
var
|
|
8
|
+
var _Ionicons = _interopRequireDefault(require("@expo/vector-icons/Ionicons"));
|
|
9
9
|
var _theme = require("@oxyhq/bloom/theme");
|
|
10
10
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
12
|
/**
|
|
12
13
|
* The camera overlay badge on a pressable avatar — the "tap to change your
|
|
13
14
|
* photo" affordance. Shared verbatim by {@link ProfileSummaryCard} (ManageAccount
|
|
@@ -31,7 +32,7 @@ const AvatarCameraBadge = () => {
|
|
|
31
32
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
|
32
33
|
style: badgeStyle,
|
|
33
34
|
className: "bg-fill-brand border-border-image",
|
|
34
|
-
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
35
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Ionicons.default, {
|
|
35
36
|
name: "camera",
|
|
36
37
|
size: 14,
|
|
37
38
|
color: theme.colors.primaryForeground
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_reactNative","require","
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_Ionicons","_interopRequireDefault","_theme","_jsxRuntime","e","__esModule","default","badgeStyle","position","right","bottom","width","height","borderRadius","alignItems","justifyContent","borderWidth","AvatarCameraBadge","theme","useTheme","jsx","View","style","className","children","name","size","color","colors","primaryForeground","_default","exports"],"sourceRoot":"../../../../src","sources":["ui/components/AvatarCameraBadge.tsx"],"mappings":";;;;;;AACA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,SAAA,GAAAC,sBAAA,CAAAF,OAAA;AACA,IAAAG,MAAA,GAAAH,OAAA;AAA8C,IAAAI,WAAA,GAAAJ,OAAA;AAAA,SAAAE,uBAAAG,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAE9C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GACA,MAAMG,UAAqB,GAAG;EAC5BC,QAAQ,EAAE,UAAU;EACpBC,KAAK,EAAE,CAAC;EACRC,MAAM,EAAE,CAAC;EACTC,KAAK,EAAE,EAAE;EACTC,MAAM,EAAE,EAAE;EACVC,YAAY,EAAE,EAAE;EAChBC,UAAU,EAAE,QAAQ;EACpBC,cAAc,EAAE,QAAQ;EACxBC,WAAW,EAAE;AACf,CAAC;AAED,MAAMC,iBAA2B,GAAGA,CAAA,KAAM;EACxC,MAAMC,KAAK,GAAG,IAAAC,eAAQ,EAAC,CAAC;EACxB,oBACE,IAAAhB,WAAA,CAAAiB,GAAA,EAACtB,YAAA,CAAAuB,IAAI;IAACC,KAAK,EAAEf,UAAW;IAACgB,SAAS,EAAC,mCAAmC;IAAAC,QAAA,eACpE,IAAArB,WAAA,CAAAiB,GAAA,EAACpB,SAAA,CAAAM,OAAQ;MAACmB,IAAI,EAAC,QAAQ;MAACC,IAAI,EAAE,EAAG;MAACC,KAAK,EAAET,KAAK,CAACU,MAAM,CAACC;IAAkB,CAAE;EAAC,CACvE,CAAC;AAEX,CAAC;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAzB,OAAA,GAEaW,iBAAiB","ignoreList":[]}
|
|
@@ -117,10 +117,16 @@ const OxyAccountDialogScreen = ({
|
|
|
117
117
|
|
|
118
118
|
function headerCopy(view, accountCount, t) {
|
|
119
119
|
switch (view) {
|
|
120
|
+
// The ACTIVE REQUEST. Its header is deliberately route-AGNOSTIC: Oxy picks
|
|
121
|
+
// the delivery route (QR here, a push to the user's phone, or opening
|
|
122
|
+
// Commons on this device — issue #691), so naming one of them in the bar
|
|
123
|
+
// would contradict the other two. The route-specific status line lives in
|
|
124
|
+
// the body, derived from `signIn.progress`, and is the only thing that
|
|
125
|
+
// describes HOW the request is travelling.
|
|
120
126
|
case 'qr':
|
|
121
127
|
return {
|
|
122
|
-
title: t('accountSwitcher.
|
|
123
|
-
subtitle:
|
|
128
|
+
title: t('accountSwitcher.signInWithOxy') || 'Sign in with Oxy',
|
|
129
|
+
subtitle: null
|
|
124
130
|
};
|
|
125
131
|
case 'signup':
|
|
126
132
|
return {
|
|
@@ -149,7 +155,12 @@ const EMPTY_SNAPSHOT = {
|
|
|
149
155
|
authorizeCode: null,
|
|
150
156
|
qrPayload: null,
|
|
151
157
|
expiresAt: null,
|
|
152
|
-
error: null
|
|
158
|
+
error: null,
|
|
159
|
+
route: null,
|
|
160
|
+
routeFailed: false,
|
|
161
|
+
pushSentAt: null,
|
|
162
|
+
openedAt: null,
|
|
163
|
+
progress: 'idle'
|
|
153
164
|
},
|
|
154
165
|
commonsAvailability: 'unknown'
|
|
155
166
|
};
|