@onairos/react-native 3.1.12 → 3.1.13
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/lib/commonjs/api/index.js +75 -1
- package/lib/commonjs/api/index.js.map +1 -1
- package/lib/commonjs/assets/fonts/EBGaramond-VariableFont_wght.ttf +0 -0
- package/lib/commonjs/assets/fonts/IBMPlexSans-VariableFont_wdth,wght.ttf +0 -0
- package/lib/commonjs/assets/icons/Facebookicon.png +0 -0
- package/lib/commonjs/assets/icons/Gmail.png +0 -0
- package/lib/commonjs/assets/icons/Linkedinicon.png +0 -0
- package/lib/commonjs/assets/icons/Redditicon.png +0 -0
- package/lib/commonjs/assets/icons/YouTubeicon2.png +0 -0
- package/lib/commonjs/assets/icons/YouTubeicon3.png +0 -0
- package/lib/commonjs/assets/icons/farcaster.png +0 -0
- package/lib/commonjs/assets/icons/instagram.png +0 -0
- package/lib/commonjs/assets/icons/pinterest.png +0 -0
- package/lib/commonjs/assets/icons/swerv_logo.png +0 -0
- package/lib/commonjs/assets/icons/twitter.jpg +0 -0
- package/lib/commonjs/assets/images/Checkbox.svg +3 -0
- package/lib/commonjs/assets/images/EnochE.svg +19 -0
- package/lib/commonjs/assets/images/Enochicon1.png +0 -0
- package/lib/commonjs/assets/images/Face_ID_logo.png +0 -0
- package/lib/commonjs/assets/images/Facebookicon.png +0 -0
- package/lib/commonjs/assets/images/Gmail.png +0 -0
- package/lib/commonjs/assets/images/Googlelogo.png +0 -0
- package/lib/commonjs/assets/images/Linkedinicon.png +0 -0
- package/lib/commonjs/assets/images/Onairoslogo.png +0 -0
- package/lib/commonjs/assets/images/Personalityprofile.svg +3 -0
- package/lib/commonjs/assets/images/Personalitytraits.svg +3 -0
- package/lib/commonjs/assets/images/Redditicon.png +0 -0
- package/lib/commonjs/assets/images/Userpreferences.svg +3 -0
- package/lib/commonjs/assets/images/YouTubeicon3.png +0 -0
- package/lib/commonjs/assets/images/arrow.svg +20 -0
- package/lib/commonjs/assets/images/basicproficon.svg +43 -0
- package/lib/commonjs/assets/images/basicprofile.svg +3 -0
- package/lib/commonjs/assets/images/checkmark.svg +4 -0
- package/lib/commonjs/assets/images/contentanalysis.svg +3 -0
- package/lib/commonjs/assets/images/contenticon.svg +23 -0
- package/lib/commonjs/assets/images/persona1.png +0 -0
- package/lib/commonjs/assets/images/persona2.png +0 -0
- package/lib/commonjs/assets/images/persona3.png +0 -0
- package/lib/commonjs/assets/images/persona4.png +0 -0
- package/lib/commonjs/assets/images/persona5.png +0 -0
- package/lib/commonjs/assets/images/personalityicon.svg +18 -0
- package/lib/commonjs/assets/images/x-close.svg +3 -0
- package/lib/commonjs/components/BodyText.js +27 -0
- package/lib/commonjs/components/BodyText.js.map +1 -0
- package/lib/commonjs/components/BrandMark.js +44 -0
- package/lib/commonjs/components/BrandMark.js.map +1 -0
- package/lib/commonjs/components/CodeInput.js +30 -0
- package/lib/commonjs/components/CodeInput.js.map +1 -0
- package/lib/commonjs/components/EmailInput.js +30 -0
- package/lib/commonjs/components/EmailInput.js.map +1 -0
- package/lib/commonjs/components/ExistingUserDataConfirmation.js +474 -0
- package/lib/commonjs/components/ExistingUserDataConfirmation.js.map +1 -0
- package/lib/commonjs/components/GoogleButton.js +55 -0
- package/lib/commonjs/components/GoogleButton.js.map +1 -0
- package/lib/commonjs/components/HeadingGroup.js +43 -0
- package/lib/commonjs/components/HeadingGroup.js.map +1 -0
- package/lib/commonjs/components/ModalHeader.js +99 -0
- package/lib/commonjs/components/ModalHeader.js.map +1 -0
- package/lib/commonjs/components/ModalSheet.js +41 -0
- package/lib/commonjs/components/ModalSheet.js.map +1 -0
- package/lib/commonjs/components/Onairos.js +1 -3
- package/lib/commonjs/components/Onairos.js.map +1 -1
- package/lib/commonjs/components/OnairosButton.js +171 -190
- package/lib/commonjs/components/OnairosButton.js.map +1 -1
- package/lib/commonjs/components/OnairosSignInButton.js +169 -0
- package/lib/commonjs/components/OnairosSignInButton.js.map +1 -0
- package/lib/commonjs/components/Overlay.js +5 -5
- package/lib/commonjs/components/Overlay.js.map +1 -1
- package/lib/commonjs/components/PersonaImage.js +60 -0
- package/lib/commonjs/components/PersonaImage.js.map +1 -0
- package/lib/commonjs/components/PersonaLoadingScreen.js +156 -0
- package/lib/commonjs/components/PersonaLoadingScreen.js.map +1 -0
- package/lib/commonjs/components/PersonalizationConsentScreen.js +316 -0
- package/lib/commonjs/components/PersonalizationConsentScreen.js.map +1 -0
- package/lib/commonjs/components/PinCreationScreen.js +393 -0
- package/lib/commonjs/components/PinCreationScreen.js.map +1 -0
- package/lib/commonjs/components/PinInput.js +282 -120
- package/lib/commonjs/components/PinInput.js.map +1 -1
- package/lib/commonjs/components/PlatformConnectorsStep.js +828 -0
- package/lib/commonjs/components/PlatformConnectorsStep.js.map +1 -0
- package/lib/commonjs/components/PlatformToggle.js +180 -0
- package/lib/commonjs/components/PlatformToggle.js.map +1 -0
- package/lib/commonjs/components/PrimaryButton.js +180 -0
- package/lib/commonjs/components/PrimaryButton.js.map +1 -0
- package/lib/commonjs/components/SignInMatchAnimation.js +197 -0
- package/lib/commonjs/components/SignInMatchAnimation.js.map +1 -0
- package/lib/commonjs/components/SignInStep.js +179 -0
- package/lib/commonjs/components/SignInStep.js.map +1 -0
- package/lib/commonjs/components/TrainingModal.js +808 -563
- package/lib/commonjs/components/TrainingModal.js.map +1 -1
- package/lib/commonjs/components/UniversalOnboarding.js +2304 -1283
- package/lib/commonjs/components/UniversalOnboarding.js.map +1 -1
- package/lib/commonjs/components/VerificationStep.js +154 -0
- package/lib/commonjs/components/VerificationStep.js.map +1 -0
- package/lib/commonjs/components/WelcomeScreen.js +385 -0
- package/lib/commonjs/components/WelcomeScreen.js.map +1 -0
- package/lib/commonjs/components/icons/Basicproficon.js +37 -0
- package/lib/commonjs/components/icons/Basicproficon.js.map +1 -0
- package/lib/commonjs/components/icons/Basicprofile.js +21 -0
- package/lib/commonjs/components/icons/Basicprofile.js.map +1 -0
- package/lib/commonjs/components/icons/Checkbox.js +21 -0
- package/lib/commonjs/components/icons/Checkbox.js.map +1 -0
- package/lib/commonjs/components/icons/Checkmark.js +27 -0
- package/lib/commonjs/components/icons/Checkmark.js.map +1 -0
- package/lib/commonjs/components/icons/Contentanalysis.js +21 -0
- package/lib/commonjs/components/icons/Contentanalysis.js.map +1 -0
- package/lib/commonjs/components/icons/Contenticon.js +39 -0
- package/lib/commonjs/components/icons/Contenticon.js.map +1 -0
- package/lib/commonjs/components/icons/EnochE.js +41 -0
- package/lib/commonjs/components/icons/EnochE.js.map +1 -0
- package/lib/commonjs/components/icons/Personalityicon.js +30 -0
- package/lib/commonjs/components/icons/Personalityicon.js.map +1 -0
- package/lib/commonjs/components/icons/Personalityprofile.js +21 -0
- package/lib/commonjs/components/icons/Personalityprofile.js.map +1 -0
- package/lib/commonjs/components/icons/Personalitytraits.js +21 -0
- package/lib/commonjs/components/icons/Personalitytraits.js.map +1 -0
- package/lib/commonjs/components/icons/Userpreferences.js +21 -0
- package/lib/commonjs/components/icons/Userpreferences.js.map +1 -0
- package/lib/commonjs/components/icons/index.js +84 -0
- package/lib/commonjs/components/icons/index.js.map +1 -0
- package/lib/commonjs/components/onboarding/OAuthWebView.js +134 -743
- package/lib/commonjs/components/onboarding/OAuthWebView.js.map +1 -1
- package/lib/commonjs/config/api.js +34 -0
- package/lib/commonjs/config/api.js.map +1 -0
- package/lib/commonjs/context/AuthContext.js +345 -0
- package/lib/commonjs/context/AuthContext.js.map +1 -0
- package/lib/commonjs/hooks/useConnectedAccounts.js +111 -0
- package/lib/commonjs/hooks/useConnectedAccounts.js.map +1 -0
- package/lib/commonjs/hooks/useConnections.js +120 -125
- package/lib/commonjs/hooks/useConnections.js.map +1 -1
- package/lib/commonjs/hooks/useUserConnections.js +148 -0
- package/lib/commonjs/hooks/useUserConnections.js.map +1 -0
- package/lib/commonjs/index.js +149 -27
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/services/apiClient.js +302 -0
- package/lib/commonjs/services/apiClient.js.map +1 -0
- package/lib/commonjs/services/apiKeyService.js +8 -9
- package/lib/commonjs/services/apiKeyService.js.map +1 -1
- package/lib/commonjs/services/authService.js +935 -0
- package/lib/commonjs/services/authService.js.map +1 -0
- package/lib/commonjs/services/biometricPinService.js +184 -0
- package/lib/commonjs/services/biometricPinService.js.map +1 -0
- package/lib/commonjs/services/connectedAccountsService.js +268 -0
- package/lib/commonjs/services/connectedAccountsService.js.map +1 -0
- package/lib/commonjs/services/googleAuthService.js +268 -0
- package/lib/commonjs/services/googleAuthService.js.map +1 -0
- package/lib/commonjs/services/imageCompressionService.js +260 -0
- package/lib/commonjs/services/imageCompressionService.js.map +1 -0
- package/lib/commonjs/services/jwtStorageService.js +256 -0
- package/lib/commonjs/services/jwtStorageService.js.map +1 -0
- package/lib/commonjs/services/mobileTrainingService.js +185 -0
- package/lib/commonjs/services/mobileTrainingService.js.map +1 -0
- package/lib/commonjs/services/pinEncryptionService.js +84 -0
- package/lib/commonjs/services/pinEncryptionService.js.map +1 -0
- package/lib/commonjs/services/pinStorageUtils.js +105 -0
- package/lib/commonjs/services/pinStorageUtils.js.map +1 -0
- package/lib/commonjs/services/platformAuthService.js +956 -722
- package/lib/commonjs/services/platformAuthService.js.map +1 -1
- package/lib/commonjs/services/storageService.js +404 -0
- package/lib/commonjs/services/storageService.js.map +1 -0
- package/lib/commonjs/services/trainingApiHelpers.js +73 -0
- package/lib/commonjs/services/trainingApiHelpers.js.map +1 -0
- package/lib/commonjs/services/userConnectionsService.js +486 -0
- package/lib/commonjs/services/userConnectionsService.js.map +1 -0
- package/lib/commonjs/services/youtubeMigrationService.js +415 -0
- package/lib/commonjs/services/youtubeMigrationService.js.map +1 -0
- package/lib/commonjs/theme/index.js +249 -0
- package/lib/commonjs/theme/index.js.map +1 -0
- package/lib/commonjs/utils/eventUtils.js +288 -0
- package/lib/commonjs/utils/eventUtils.js.map +1 -0
- package/lib/commonjs/utils/haptics.js +66 -0
- package/lib/commonjs/utils/haptics.js.map +1 -0
- package/lib/commonjs/utils/imagePreloader.js +6 -0
- package/lib/commonjs/utils/imagePreloader.js.map +1 -0
- package/lib/module/api/index.js +72 -0
- package/lib/module/api/index.js.map +1 -1
- package/lib/module/assets/fonts/EBGaramond-VariableFont_wght.ttf +0 -0
- package/lib/module/assets/fonts/IBMPlexSans-VariableFont_wdth,wght.ttf +0 -0
- package/lib/module/assets/icons/Facebookicon.png +0 -0
- package/lib/module/assets/icons/Gmail.png +0 -0
- package/lib/module/assets/icons/Linkedinicon.png +0 -0
- package/lib/module/assets/icons/Redditicon.png +0 -0
- package/lib/module/assets/icons/YouTubeicon2.png +0 -0
- package/lib/module/assets/icons/YouTubeicon3.png +0 -0
- package/lib/module/assets/icons/farcaster.png +0 -0
- package/lib/module/assets/icons/instagram.png +0 -0
- package/lib/module/assets/icons/pinterest.png +0 -0
- package/lib/module/assets/icons/swerv_logo.png +0 -0
- package/lib/module/assets/icons/twitter.jpg +0 -0
- package/lib/module/assets/images/Checkbox.svg +3 -0
- package/lib/module/assets/images/EnochE.svg +19 -0
- package/lib/module/assets/images/Enochicon1.png +0 -0
- package/lib/module/assets/images/Face_ID_logo.png +0 -0
- package/lib/module/assets/images/Facebookicon.png +0 -0
- package/lib/module/assets/images/Gmail.png +0 -0
- package/lib/module/assets/images/Googlelogo.png +0 -0
- package/lib/module/assets/images/Linkedinicon.png +0 -0
- package/lib/module/assets/images/Onairoslogo.png +0 -0
- package/lib/module/assets/images/Personalityprofile.svg +3 -0
- package/lib/module/assets/images/Personalitytraits.svg +3 -0
- package/lib/module/assets/images/Redditicon.png +0 -0
- package/lib/module/assets/images/Userpreferences.svg +3 -0
- package/lib/module/assets/images/YouTubeicon3.png +0 -0
- package/lib/module/assets/images/arrow.svg +20 -0
- package/lib/module/assets/images/basicproficon.svg +43 -0
- package/lib/module/assets/images/basicprofile.svg +3 -0
- package/lib/module/assets/images/checkmark.svg +4 -0
- package/lib/module/assets/images/contentanalysis.svg +3 -0
- package/lib/module/assets/images/contenticon.svg +23 -0
- package/lib/module/assets/images/persona1.png +0 -0
- package/lib/module/assets/images/persona2.png +0 -0
- package/lib/module/assets/images/persona3.png +0 -0
- package/lib/module/assets/images/persona4.png +0 -0
- package/lib/module/assets/images/persona5.png +0 -0
- package/lib/module/assets/images/personalityicon.svg +18 -0
- package/lib/module/assets/images/x-close.svg +3 -0
- package/lib/module/components/BodyText.js +20 -0
- package/lib/module/components/BodyText.js.map +1 -0
- package/lib/module/components/BrandMark.js +37 -0
- package/lib/module/components/BrandMark.js.map +1 -0
- package/lib/module/components/CodeInput.js +23 -0
- package/lib/module/components/CodeInput.js.map +1 -0
- package/lib/module/components/EmailInput.js +23 -0
- package/lib/module/components/EmailInput.js.map +1 -0
- package/lib/module/components/ExistingUserDataConfirmation.js +465 -0
- package/lib/module/components/ExistingUserDataConfirmation.js.map +1 -0
- package/lib/module/components/GoogleButton.js +48 -0
- package/lib/module/components/GoogleButton.js.map +1 -0
- package/lib/module/components/HeadingGroup.js +36 -0
- package/lib/module/components/HeadingGroup.js.map +1 -0
- package/lib/module/components/ModalHeader.js +92 -0
- package/lib/module/components/ModalHeader.js.map +1 -0
- package/lib/module/components/ModalSheet.js +34 -0
- package/lib/module/components/ModalSheet.js.map +1 -0
- package/lib/module/components/Onairos.js +1 -3
- package/lib/module/components/Onairos.js.map +1 -1
- package/lib/module/components/OnairosButton.js +172 -192
- package/lib/module/components/OnairosButton.js.map +1 -1
- package/lib/module/components/OnairosSignInButton.js +160 -0
- package/lib/module/components/OnairosSignInButton.js.map +1 -0
- package/lib/module/components/Overlay.js +5 -5
- package/lib/module/components/Overlay.js.map +1 -1
- package/lib/module/components/PersonaImage.js +53 -0
- package/lib/module/components/PersonaImage.js.map +1 -0
- package/lib/module/components/PersonaLoadingScreen.js +148 -0
- package/lib/module/components/PersonaLoadingScreen.js.map +1 -0
- package/lib/module/components/PersonalizationConsentScreen.js +309 -0
- package/lib/module/components/PersonalizationConsentScreen.js.map +1 -0
- package/lib/module/components/PinCreationScreen.js +386 -0
- package/lib/module/components/PinCreationScreen.js.map +1 -0
- package/lib/module/components/PinInput.js +283 -120
- package/lib/module/components/PinInput.js.map +1 -1
- package/lib/module/components/PlatformConnectorsStep.js +820 -0
- package/lib/module/components/PlatformConnectorsStep.js.map +1 -0
- package/lib/module/components/PlatformToggle.js +173 -0
- package/lib/module/components/PlatformToggle.js.map +1 -0
- package/lib/module/components/PrimaryButton.js +172 -0
- package/lib/module/components/PrimaryButton.js.map +1 -0
- package/lib/module/components/SignInMatchAnimation.js +189 -0
- package/lib/module/components/SignInMatchAnimation.js.map +1 -0
- package/lib/module/components/SignInStep.js +171 -0
- package/lib/module/components/SignInStep.js.map +1 -0
- package/lib/module/components/TrainingModal.js +809 -565
- package/lib/module/components/TrainingModal.js.map +1 -1
- package/lib/module/components/UniversalOnboarding.js +2307 -1284
- package/lib/module/components/UniversalOnboarding.js.map +1 -1
- package/lib/module/components/VerificationStep.js +146 -0
- package/lib/module/components/VerificationStep.js.map +1 -0
- package/lib/module/components/WelcomeScreen.js +378 -0
- package/lib/module/components/WelcomeScreen.js.map +1 -0
- package/lib/module/components/icons/Basicproficon.js +30 -0
- package/lib/module/components/icons/Basicproficon.js.map +1 -0
- package/lib/module/components/icons/Basicprofile.js +14 -0
- package/lib/module/components/icons/Basicprofile.js.map +1 -0
- package/lib/module/components/icons/Checkbox.js +14 -0
- package/lib/module/components/icons/Checkbox.js.map +1 -0
- package/lib/module/components/icons/Checkmark.js +20 -0
- package/lib/module/components/icons/Checkmark.js.map +1 -0
- package/lib/module/components/icons/Contentanalysis.js +14 -0
- package/lib/module/components/icons/Contentanalysis.js.map +1 -0
- package/lib/module/components/icons/Contenticon.js +32 -0
- package/lib/module/components/icons/Contenticon.js.map +1 -0
- package/lib/module/components/icons/EnochE.js +34 -0
- package/lib/module/components/icons/EnochE.js.map +1 -0
- package/lib/module/components/icons/Personalityicon.js +23 -0
- package/lib/module/components/icons/Personalityicon.js.map +1 -0
- package/lib/module/components/icons/Personalityprofile.js +14 -0
- package/lib/module/components/icons/Personalityprofile.js.map +1 -0
- package/lib/module/components/icons/Personalitytraits.js +14 -0
- package/lib/module/components/icons/Personalitytraits.js.map +1 -0
- package/lib/module/components/icons/Userpreferences.js +14 -0
- package/lib/module/components/icons/Userpreferences.js.map +1 -0
- package/lib/module/components/icons/index.js +13 -0
- package/lib/module/components/icons/index.js.map +1 -0
- package/lib/module/components/onboarding/OAuthWebView.js +136 -744
- package/lib/module/components/onboarding/OAuthWebView.js.map +1 -1
- package/lib/module/config/api.js +26 -0
- package/lib/module/config/api.js.map +1 -0
- package/lib/module/context/AuthContext.js +335 -0
- package/lib/module/context/AuthContext.js.map +1 -0
- package/lib/module/hooks/useConnectedAccounts.js +106 -0
- package/lib/module/hooks/useConnectedAccounts.js.map +1 -0
- package/lib/module/hooks/useConnections.js +119 -125
- package/lib/module/hooks/useConnections.js.map +1 -1
- package/lib/module/hooks/useUserConnections.js +140 -0
- package/lib/module/hooks/useUserConnections.js.map +1 -0
- package/lib/module/index.js +51 -15
- package/lib/module/index.js.map +1 -1
- package/lib/module/services/apiClient.js +298 -0
- package/lib/module/services/apiClient.js.map +1 -0
- package/lib/module/services/apiKeyService.js +8 -9
- package/lib/module/services/apiKeyService.js.map +1 -1
- package/lib/module/services/authService.js +905 -0
- package/lib/module/services/authService.js.map +1 -0
- package/lib/module/services/biometricPinService.js +173 -0
- package/lib/module/services/biometricPinService.js.map +1 -0
- package/lib/module/services/connectedAccountsService.js +255 -0
- package/lib/module/services/connectedAccountsService.js.map +1 -0
- package/lib/module/services/googleAuthService.js +258 -0
- package/lib/module/services/googleAuthService.js.map +1 -0
- package/lib/module/services/imageCompressionService.js +250 -0
- package/lib/module/services/imageCompressionService.js.map +1 -0
- package/lib/module/services/jwtStorageService.js +239 -0
- package/lib/module/services/jwtStorageService.js.map +1 -0
- package/lib/module/services/mobileTrainingService.js +172 -0
- package/lib/module/services/mobileTrainingService.js.map +1 -0
- package/lib/module/services/pinEncryptionService.js +75 -0
- package/lib/module/services/pinEncryptionService.js.map +1 -0
- package/lib/module/services/pinStorageUtils.js +93 -0
- package/lib/module/services/pinStorageUtils.js.map +1 -0
- package/lib/module/services/platformAuthService.js +943 -704
- package/lib/module/services/platformAuthService.js.map +1 -1
- package/lib/module/services/storageService.js +383 -0
- package/lib/module/services/storageService.js.map +1 -0
- package/lib/module/services/trainingApiHelpers.js +67 -0
- package/lib/module/services/trainingApiHelpers.js.map +1 -0
- package/lib/module/services/userConnectionsService.js +476 -0
- package/lib/module/services/userConnectionsService.js.map +1 -0
- package/lib/module/services/youtubeMigrationService.js +404 -0
- package/lib/module/services/youtubeMigrationService.js.map +1 -0
- package/lib/module/theme/index.js +244 -0
- package/lib/module/theme/index.js.map +1 -0
- package/lib/module/utils/eventUtils.js +270 -0
- package/lib/module/utils/eventUtils.js.map +1 -0
- package/lib/module/utils/haptics.js +59 -0
- package/lib/module/utils/haptics.js.map +1 -0
- package/lib/module/utils/imagePreloader.js +3 -0
- package/lib/module/utils/imagePreloader.js.map +1 -0
- package/lib/typescript/api/index.d.ts +8 -0
- package/lib/typescript/api/index.d.ts.map +1 -1
- package/lib/typescript/components/BodyText.d.ts +10 -0
- package/lib/typescript/components/BodyText.d.ts.map +1 -0
- package/lib/typescript/components/BrandMark.d.ts +11 -0
- package/lib/typescript/components/BrandMark.d.ts.map +1 -0
- package/lib/typescript/components/CodeInput.d.ts +10 -0
- package/lib/typescript/components/CodeInput.d.ts.map +1 -0
- package/lib/typescript/components/EmailInput.d.ts +8 -0
- package/lib/typescript/components/EmailInput.d.ts.map +1 -0
- package/lib/typescript/components/ExistingUserDataConfirmation.d.ts +12 -0
- package/lib/typescript/components/ExistingUserDataConfirmation.d.ts.map +1 -0
- package/lib/typescript/components/GoogleButton.d.ts +11 -0
- package/lib/typescript/components/GoogleButton.d.ts.map +1 -0
- package/lib/typescript/components/HeadingGroup.d.ts +11 -0
- package/lib/typescript/components/HeadingGroup.d.ts.map +1 -0
- package/lib/typescript/components/ModalHeader.d.ts +11 -0
- package/lib/typescript/components/ModalHeader.d.ts.map +1 -0
- package/lib/typescript/components/ModalSheet.d.ts +13 -0
- package/lib/typescript/components/ModalSheet.d.ts.map +1 -0
- package/lib/typescript/components/Onairos.d.ts.map +1 -1
- package/lib/typescript/components/OnairosButton.d.ts +29 -4
- package/lib/typescript/components/OnairosButton.d.ts.map +1 -1
- package/lib/typescript/components/OnairosSignInButton.d.ts +14 -0
- package/lib/typescript/components/OnairosSignInButton.d.ts.map +1 -0
- package/lib/typescript/components/PersonaImage.d.ts +8 -0
- package/lib/typescript/components/PersonaImage.d.ts.map +1 -0
- package/lib/typescript/components/PersonaLoadingScreen.d.ts +10 -0
- package/lib/typescript/components/PersonaLoadingScreen.d.ts.map +1 -0
- package/lib/typescript/components/PersonalizationConsentScreen.d.ts +10 -0
- package/lib/typescript/components/PersonalizationConsentScreen.d.ts.map +1 -0
- package/lib/typescript/components/PinCreationScreen.d.ts +10 -0
- package/lib/typescript/components/PinCreationScreen.d.ts.map +1 -0
- package/lib/typescript/components/PinInput.d.ts +11 -1
- package/lib/typescript/components/PinInput.d.ts.map +1 -1
- package/lib/typescript/components/PlatformConnectorsStep.d.ts +11 -0
- package/lib/typescript/components/PlatformConnectorsStep.d.ts.map +1 -0
- package/lib/typescript/components/PlatformToggle.d.ts +20 -0
- package/lib/typescript/components/PlatformToggle.d.ts.map +1 -0
- package/lib/typescript/components/PrimaryButton.d.ts +22 -0
- package/lib/typescript/components/PrimaryButton.d.ts.map +1 -0
- package/lib/typescript/components/SignInMatchAnimation.d.ts +9 -0
- package/lib/typescript/components/SignInMatchAnimation.d.ts.map +1 -0
- package/lib/typescript/components/SignInStep.d.ts +12 -0
- package/lib/typescript/components/SignInStep.d.ts.map +1 -0
- package/lib/typescript/components/TrainingModal.d.ts +12 -1
- package/lib/typescript/components/TrainingModal.d.ts.map +1 -1
- package/lib/typescript/components/UniversalOnboarding.d.ts +14 -1
- package/lib/typescript/components/UniversalOnboarding.d.ts.map +1 -1
- package/lib/typescript/components/VerificationStep.d.ts +13 -0
- package/lib/typescript/components/VerificationStep.d.ts.map +1 -0
- package/lib/typescript/components/WelcomeScreen.d.ts +9 -0
- package/lib/typescript/components/WelcomeScreen.d.ts.map +1 -0
- package/lib/typescript/components/icons/Basicproficon.d.ts +5 -0
- package/lib/typescript/components/icons/Basicproficon.d.ts.map +1 -0
- package/lib/typescript/components/icons/Basicprofile.d.ts +5 -0
- package/lib/typescript/components/icons/Basicprofile.d.ts.map +1 -0
- package/lib/typescript/components/icons/Checkbox.d.ts +5 -0
- package/lib/typescript/components/icons/Checkbox.d.ts.map +1 -0
- package/lib/typescript/components/icons/Checkmark.d.ts +5 -0
- package/lib/typescript/components/icons/Checkmark.d.ts.map +1 -0
- package/lib/typescript/components/icons/Contentanalysis.d.ts +5 -0
- package/lib/typescript/components/icons/Contentanalysis.d.ts.map +1 -0
- package/lib/typescript/components/icons/Contenticon.d.ts +5 -0
- package/lib/typescript/components/icons/Contenticon.d.ts.map +1 -0
- package/lib/typescript/components/icons/EnochE.d.ts +5 -0
- package/lib/typescript/components/icons/EnochE.d.ts.map +1 -0
- package/lib/typescript/components/icons/Personalityicon.d.ts +5 -0
- package/lib/typescript/components/icons/Personalityicon.d.ts.map +1 -0
- package/lib/typescript/components/icons/Personalityprofile.d.ts +5 -0
- package/lib/typescript/components/icons/Personalityprofile.d.ts.map +1 -0
- package/lib/typescript/components/icons/Personalitytraits.d.ts +5 -0
- package/lib/typescript/components/icons/Personalitytraits.d.ts.map +1 -0
- package/lib/typescript/components/icons/Userpreferences.d.ts +5 -0
- package/lib/typescript/components/icons/Userpreferences.d.ts.map +1 -0
- package/lib/typescript/components/icons/index.d.ts +12 -0
- package/lib/typescript/components/icons/index.d.ts.map +1 -0
- package/lib/typescript/components/onboarding/OAuthWebView.d.ts.map +1 -1
- package/lib/typescript/config/api.d.ts +24 -0
- package/lib/typescript/config/api.d.ts.map +1 -0
- package/lib/typescript/context/AuthContext.d.ts +34 -0
- package/lib/typescript/context/AuthContext.d.ts.map +1 -0
- package/lib/typescript/hooks/useConnectedAccounts.d.ts +11 -0
- package/lib/typescript/hooks/useConnectedAccounts.d.ts.map +1 -0
- package/lib/typescript/hooks/useConnections.d.ts +10 -5
- package/lib/typescript/hooks/useConnections.d.ts.map +1 -1
- package/lib/typescript/hooks/useUserConnections.d.ts +12 -0
- package/lib/typescript/hooks/useUserConnections.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +24 -6
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/services/apiClient.d.ts +91 -0
- package/lib/typescript/services/apiClient.d.ts.map +1 -0
- package/lib/typescript/services/apiKeyService.d.ts.map +1 -1
- package/lib/typescript/services/authService.d.ts +216 -0
- package/lib/typescript/services/authService.d.ts.map +1 -0
- package/lib/typescript/services/biometricPinService.d.ts +29 -0
- package/lib/typescript/services/biometricPinService.d.ts.map +1 -0
- package/lib/typescript/services/connectedAccountsService.d.ts +56 -0
- package/lib/typescript/services/connectedAccountsService.d.ts.map +1 -0
- package/lib/typescript/services/googleAuthService.d.ts +63 -0
- package/lib/typescript/services/googleAuthService.d.ts.map +1 -0
- package/lib/typescript/services/imageCompressionService.d.ts +37 -0
- package/lib/typescript/services/imageCompressionService.d.ts.map +1 -0
- package/lib/typescript/services/jwtStorageService.d.ts +86 -0
- package/lib/typescript/services/jwtStorageService.d.ts.map +1 -0
- package/lib/typescript/services/mobileTrainingService.d.ts +45 -0
- package/lib/typescript/services/mobileTrainingService.d.ts.map +1 -0
- package/lib/typescript/services/pinEncryptionService.d.ts +17 -0
- package/lib/typescript/services/pinEncryptionService.d.ts.map +1 -0
- package/lib/typescript/services/pinStorageUtils.d.ts +25 -0
- package/lib/typescript/services/pinStorageUtils.d.ts.map +1 -0
- package/lib/typescript/services/platformAuthService.d.ts +34 -109
- package/lib/typescript/services/platformAuthService.d.ts.map +1 -1
- package/lib/typescript/services/storageService.d.ts +128 -0
- package/lib/typescript/services/storageService.d.ts.map +1 -0
- package/lib/typescript/services/trainingApiHelpers.d.ts +38 -0
- package/lib/typescript/services/trainingApiHelpers.d.ts.map +1 -0
- package/lib/typescript/services/userConnectionsService.d.ts +90 -0
- package/lib/typescript/services/userConnectionsService.d.ts.map +1 -0
- package/lib/typescript/services/youtubeMigrationService.d.ts +12 -0
- package/lib/typescript/services/youtubeMigrationService.d.ts.map +1 -0
- package/lib/typescript/theme/index.d.ts +416 -0
- package/lib/typescript/theme/index.d.ts.map +1 -0
- package/lib/typescript/types/index.d.ts +39 -0
- package/lib/typescript/types/index.d.ts.map +1 -1
- package/lib/typescript/utils/eventUtils.d.ts +108 -0
- package/lib/typescript/utils/eventUtils.d.ts.map +1 -0
- package/lib/typescript/utils/haptics.d.ts +11 -0
- package/lib/typescript/utils/haptics.d.ts.map +1 -0
- package/lib/typescript/utils/imagePreloader.d.ts +2 -0
- package/lib/typescript/utils/imagePreloader.d.ts.map +1 -0
- package/package.json +158 -145
- package/src/api/index.ts +41 -0
- package/src/assets/fonts/EBGaramond-VariableFont_wght.ttf +0 -0
- package/src/assets/fonts/IBMPlexSans-VariableFont_wdth,wght.ttf +0 -0
- package/src/assets/icons/Facebookicon.png +0 -0
- package/src/assets/icons/Gmail.png +0 -0
- package/src/assets/icons/Linkedinicon.png +0 -0
- package/src/assets/icons/Redditicon.png +0 -0
- package/src/assets/icons/YouTubeicon2.png +0 -0
- package/src/assets/icons/YouTubeicon3.png +0 -0
- package/src/assets/icons/farcaster.png +0 -0
- package/src/assets/icons/instagram.png +0 -0
- package/src/assets/icons/pinterest.png +0 -0
- package/src/assets/icons/swerv_logo.png +0 -0
- package/src/assets/icons/twitter.jpg +0 -0
- package/src/assets/images/Checkbox.svg +3 -0
- package/src/assets/images/EnochE.svg +19 -0
- package/src/assets/images/Enochicon1.png +0 -0
- package/src/assets/images/Face_ID_logo.png +0 -0
- package/src/assets/images/Facebookicon.png +0 -0
- package/src/assets/images/Gmail.png +0 -0
- package/src/assets/images/Googlelogo.png +0 -0
- package/src/assets/images/Linkedinicon.png +0 -0
- package/src/assets/images/Onairoslogo.png +0 -0
- package/src/assets/images/Personalityprofile.svg +3 -0
- package/src/assets/images/Personalitytraits.svg +3 -0
- package/src/assets/images/Redditicon.png +0 -0
- package/src/assets/images/Userpreferences.svg +3 -0
- package/src/assets/images/YouTubeicon3.png +0 -0
- package/src/assets/images/arrow.svg +20 -0
- package/src/assets/images/basicproficon.svg +43 -0
- package/src/assets/images/basicprofile.svg +3 -0
- package/src/assets/images/checkmark.svg +4 -0
- package/src/assets/images/contentanalysis.svg +3 -0
- package/src/assets/images/contenticon.svg +23 -0
- package/src/assets/images/persona1.png +0 -0
- package/src/assets/images/persona2.png +0 -0
- package/src/assets/images/persona3.png +0 -0
- package/src/assets/images/persona4.png +0 -0
- package/src/assets/images/persona5.png +0 -0
- package/src/assets/images/personalityicon.svg +18 -0
- package/src/assets/images/x-close.svg +3 -0
- package/src/components/BodyText.tsx +33 -0
- package/src/components/BrandMark.tsx +62 -0
- package/src/components/CodeInput.tsx +32 -0
- package/src/components/EmailInput.tsx +31 -0
- package/src/components/ExistingUserDataConfirmation.tsx +507 -0
- package/src/components/GoogleButton.tsx +55 -0
- package/src/components/HeadingGroup.tsx +49 -0
- package/src/components/ModalHeader.tsx +125 -0
- package/src/components/ModalSheet.tsx +57 -0
- package/src/components/Onairos.tsx +422 -424
- package/src/components/OnairosButton.tsx +339 -359
- package/src/components/OnairosSignInButton.tsx +166 -0
- package/src/components/Overlay.tsx +506 -506
- package/src/components/PersonaImage.tsx +79 -0
- package/src/components/PersonaLoadingScreen.tsx +201 -0
- package/src/components/PersonalizationConsentScreen.tsx +410 -0
- package/src/components/PinCreationScreen.tsx +492 -0
- package/src/components/PinInput.tsx +555 -343
- package/src/components/PlatformConnectorsStep.tsx +892 -0
- package/src/components/PlatformToggle.tsx +226 -0
- package/src/components/PrimaryButton.tsx +214 -0
- package/src/components/SignInMatchAnimation.tsx +225 -0
- package/src/components/SignInStep.tsx +217 -0
- package/src/components/TrainingModal.tsx +1047 -737
- package/src/components/UniversalOnboarding.tsx +2888 -1820
- package/src/components/VerificationStep.tsx +198 -0
- package/src/components/WelcomeScreen.tsx +473 -0
- package/src/components/icons/Basicproficon.tsx +30 -0
- package/src/components/icons/Basicprofile.tsx +17 -0
- package/src/components/icons/Checkbox.tsx +17 -0
- package/src/components/icons/Checkmark.tsx +24 -0
- package/src/components/icons/Contentanalysis.tsx +17 -0
- package/src/components/icons/Contenticon.tsx +30 -0
- package/src/components/icons/EnochE.tsx +39 -0
- package/src/components/icons/Personalityicon.tsx +22 -0
- package/src/components/icons/Personalityprofile.tsx +17 -0
- package/src/components/icons/Personalitytraits.tsx +17 -0
- package/src/components/icons/Userpreferences.tsx +17 -0
- package/src/components/icons/index.ts +12 -0
- package/src/components/onboarding/OAuthWebView.tsx +232 -838
- package/src/config/api.ts +25 -0
- package/src/context/AuthContext.tsx +393 -0
- package/src/hooks/useConnectedAccounts.ts +139 -0
- package/src/hooks/useConnections.ts +129 -131
- package/src/hooks/useUserConnections.ts +166 -0
- package/src/index.ts +94 -49
- package/src/services/apiClient.ts +337 -0
- package/src/services/apiKeyService.ts +9 -11
- package/src/services/authService.ts +1008 -0
- package/src/services/biometricPinService.ts +193 -0
- package/src/services/connectedAccountsService.ts +290 -0
- package/src/services/googleAuthService.ts +279 -0
- package/src/services/imageCompressionService.ts +303 -0
- package/src/services/jwtStorageService.ts +257 -0
- package/src/services/mobileTrainingService.ts +204 -0
- package/src/services/pinEncryptionService.ts +76 -0
- package/src/services/pinStorageUtils.ts +97 -0
- package/src/services/platformAuthService.ts +1346 -1113
- package/src/services/storageService.ts +452 -0
- package/src/services/trainingApiHelpers.ts +67 -0
- package/src/services/userConnectionsService.ts +557 -0
- package/src/services/youtubeMigrationService.ts +454 -0
- package/src/theme/index.ts +239 -0
- package/src/types/index.ts +265 -238
- package/src/utils/eventUtils.ts +303 -0
- package/src/utils/haptics.ts +59 -0
- package/src/utils/imagePreloader.ts +2 -0
- package/README.md +0 -375
- package/lib/commonjs/assets/images/email.png +0 -0
- package/lib/commonjs/assets/images/linkedin.png +0 -0
- package/lib/commonjs/assets/images/reddit.png +0 -0
- package/lib/commonjs/assets/images/youtube.png +0 -0
- package/lib/commonjs/components/UniversalOnboarding.tsx.new +0 -455
- package/lib/module/assets/images/email.png +0 -0
- package/lib/module/assets/images/linkedin.png +0 -0
- package/lib/module/assets/images/reddit.png +0 -0
- package/lib/module/assets/images/youtube.png +0 -0
- package/lib/module/components/UniversalOnboarding.tsx.new +0 -455
- package/src/assets/images/email.png +0 -0
- package/src/assets/images/linkedin.png +0 -0
- package/src/assets/images/reddit.png +0 -0
- package/src/assets/images/youtube.png +0 -0
- package/src/components/UniversalOnboarding.tsx.new +0 -455
|
@@ -0,0 +1,415 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.shouldShowYouTubeMigrationWarning = exports.reconnectYouTube = exports.getYouTubeConnectionStatus = exports.checkYouTubeMigrationNeeded = exports.checkAndFixYouTubeConnection = void 0;
|
|
7
|
+
var _googleSignin = require("@react-native-google-signin/google-signin");
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _asyncStorage = _interopRequireDefault(require("@react-native-async-storage/async-storage"));
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
// 🔑 CRITICAL: Using the same client ID for both web and iOS to avoid audience errors
|
|
12
|
+
const WEB_CLIENT_ID = '1030678346906-lovkuds2ouqmoc8eu5qpo98spa6edv4o.apps.googleusercontent.com';
|
|
13
|
+
const IOS_CLIENT_ID = '1030678346906-lovkuds2ouqmoc8eu5qpo98spa6edv4o.apps.googleusercontent.com';
|
|
14
|
+
|
|
15
|
+
// Configuration for Google Sign-In with refresh token support
|
|
16
|
+
const configureGoogleSignInForRefreshTokens = () => {
|
|
17
|
+
_googleSignin.GoogleSignin.configure({
|
|
18
|
+
webClientId: WEB_CLIENT_ID,
|
|
19
|
+
// ✅ CRITICAL: Web client ID for refresh tokens
|
|
20
|
+
iosClientId: IOS_CLIENT_ID,
|
|
21
|
+
// ✅ iOS client ID for native auth
|
|
22
|
+
|
|
23
|
+
// 🔑 CRITICAL: These are the missing parameters that fix the refresh token issue
|
|
24
|
+
offlineAccess: true,
|
|
25
|
+
// ← Enables refresh tokens
|
|
26
|
+
forceCodeForRefreshToken: true,
|
|
27
|
+
// ← Forces refresh token generation
|
|
28
|
+
|
|
29
|
+
// ✅ Enhanced scopes for YouTube
|
|
30
|
+
scopes: ['https://www.googleapis.com/auth/youtube.readonly', 'openid', 'profile', 'email'],
|
|
31
|
+
// 🚀 Additional settings (helps with refresh tokens)
|
|
32
|
+
hostedDomain: '',
|
|
33
|
+
accountName: ''
|
|
34
|
+
});
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
// Check if user needs YouTube migration
|
|
38
|
+
const checkYouTubeMigrationNeeded = async username => {
|
|
39
|
+
try {
|
|
40
|
+
const response = await fetch(`https://api2.onairos.uk/youtube/validate-connection/${username}`);
|
|
41
|
+
const result = await response.json();
|
|
42
|
+
if (result.success && result.validation) {
|
|
43
|
+
var _result$validation, _result$temporaryMode, _result$temporaryMode2;
|
|
44
|
+
// ✅ NEW: Check if this is temporary mode (matches exact backend response fields)
|
|
45
|
+
const isTemporaryMode = ((_result$validation = result.validation) === null || _result$validation === void 0 ? void 0 : _result$validation.isTemporaryMode) === true || ((_result$temporaryMode = result.temporaryMode) === null || _result$temporaryMode === void 0 ? void 0 : _result$temporaryMode.enabled) === true || result.isTemporaryMode === true || result.message && result.message.includes('temporary access token mode');
|
|
46
|
+
const needsReconnection = result.validation.needsReconnection;
|
|
47
|
+
const hasRefreshToken = result.validation.hasRefreshToken;
|
|
48
|
+
console.log('🔍 YouTube migration check:', {
|
|
49
|
+
username,
|
|
50
|
+
needsReconnection,
|
|
51
|
+
hasRefreshToken,
|
|
52
|
+
isTemporaryMode,
|
|
53
|
+
temporaryModeEnabled: (_result$temporaryMode2 = result.temporaryMode) === null || _result$temporaryMode2 === void 0 ? void 0 : _result$temporaryMode2.enabled,
|
|
54
|
+
message: result.message
|
|
55
|
+
});
|
|
56
|
+
if (isTemporaryMode) {
|
|
57
|
+
console.log('🔄 User using temporary mode - connection working correctly');
|
|
58
|
+
console.log('⚠️ No refresh capability but training can proceed');
|
|
59
|
+
return false; // Don't flag temporary mode as needing migration
|
|
60
|
+
} else if (needsReconnection) {
|
|
61
|
+
console.log('🔧 User needs YouTube migration for refresh token');
|
|
62
|
+
return true; // Only flag genuinely old connections
|
|
63
|
+
} else {
|
|
64
|
+
console.log('✅ YouTube connection fully working with refresh tokens');
|
|
65
|
+
return false; // Connection is perfect
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
return false;
|
|
69
|
+
} catch (error) {
|
|
70
|
+
console.error('❌ Error checking YouTube migration status:', error);
|
|
71
|
+
return false;
|
|
72
|
+
}
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
// ✅ NEW: Enhanced function to get detailed YouTube connection status
|
|
76
|
+
exports.checkYouTubeMigrationNeeded = checkYouTubeMigrationNeeded;
|
|
77
|
+
const getYouTubeConnectionStatus = async username => {
|
|
78
|
+
try {
|
|
79
|
+
const response = await fetch(`https://api2.onairos.uk/youtube/validate-connection/${username}`);
|
|
80
|
+
const result = await response.json();
|
|
81
|
+
console.log('📋 Complete YouTube status response:', result);
|
|
82
|
+
if (result.success && result.validation) {
|
|
83
|
+
var _result$validation2, _result$temporaryMode3;
|
|
84
|
+
// Check for temporary mode (prioritize exact backend fields)
|
|
85
|
+
const isTemporaryMode = ((_result$validation2 = result.validation) === null || _result$validation2 === void 0 ? void 0 : _result$validation2.isTemporaryMode) === true || ((_result$temporaryMode3 = result.temporaryMode) === null || _result$temporaryMode3 === void 0 ? void 0 : _result$temporaryMode3.enabled) === true || result.isTemporaryMode === true || result.message && result.message.includes('temporary access token mode');
|
|
86
|
+
const hasRefreshToken = result.validation.hasRefreshToken === true;
|
|
87
|
+
const needsReconnection = result.validation.needsReconnection === true;
|
|
88
|
+
if (isTemporaryMode) {
|
|
89
|
+
console.log('🔄 YouTube connected in temporary mode');
|
|
90
|
+
console.log('✅ Training will work, but connection expires in ~1 hour');
|
|
91
|
+
return {
|
|
92
|
+
isReady: true,
|
|
93
|
+
mode: 'temporary',
|
|
94
|
+
needsMigration: false,
|
|
95
|
+
trainingReady: true,
|
|
96
|
+
details: result
|
|
97
|
+
};
|
|
98
|
+
} else if (hasRefreshToken) {
|
|
99
|
+
console.log('✅ YouTube connected with refresh tokens');
|
|
100
|
+
return {
|
|
101
|
+
isReady: true,
|
|
102
|
+
mode: 'full',
|
|
103
|
+
needsMigration: false,
|
|
104
|
+
trainingReady: true,
|
|
105
|
+
details: result
|
|
106
|
+
};
|
|
107
|
+
} else if (needsReconnection) {
|
|
108
|
+
console.log('⚠️ YouTube connected but needs migration');
|
|
109
|
+
return {
|
|
110
|
+
isReady: false,
|
|
111
|
+
mode: 'limited',
|
|
112
|
+
needsMigration: true,
|
|
113
|
+
trainingReady: false,
|
|
114
|
+
details: result
|
|
115
|
+
};
|
|
116
|
+
} else {
|
|
117
|
+
console.log('❓ YouTube connection status unclear');
|
|
118
|
+
return {
|
|
119
|
+
isReady: false,
|
|
120
|
+
mode: 'none',
|
|
121
|
+
needsMigration: false,
|
|
122
|
+
trainingReady: false,
|
|
123
|
+
details: result
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
console.log('❌ No YouTube connection found');
|
|
128
|
+
return {
|
|
129
|
+
isReady: false,
|
|
130
|
+
mode: 'none',
|
|
131
|
+
needsMigration: false,
|
|
132
|
+
trainingReady: false,
|
|
133
|
+
details: result
|
|
134
|
+
};
|
|
135
|
+
} catch (error) {
|
|
136
|
+
console.error('❌ Error getting YouTube connection status:', error);
|
|
137
|
+
return {
|
|
138
|
+
isReady: false,
|
|
139
|
+
mode: 'none',
|
|
140
|
+
needsMigration: false,
|
|
141
|
+
trainingReady: false,
|
|
142
|
+
details: {
|
|
143
|
+
error: error instanceof Error ? error.message : String(error)
|
|
144
|
+
}
|
|
145
|
+
};
|
|
146
|
+
}
|
|
147
|
+
};
|
|
148
|
+
|
|
149
|
+
// Show user-friendly migration prompt
|
|
150
|
+
exports.getYouTubeConnectionStatus = getYouTubeConnectionStatus;
|
|
151
|
+
const showYouTubeMigrationPrompt = async () => {
|
|
152
|
+
return new Promise(resolve => {
|
|
153
|
+
_reactNative.Alert.alert('YouTube Connection Upgrade', 'To improve your training experience, we need to upgrade your YouTube connection. This prevents interruptions during data collection.\n\n✅ One-time upgrade\n✅ Takes 30 seconds\n✅ No data loss\n\nUpgrade now?', [{
|
|
154
|
+
text: 'Skip for Now',
|
|
155
|
+
style: 'cancel',
|
|
156
|
+
onPress: () => resolve(false)
|
|
157
|
+
}, {
|
|
158
|
+
text: 'Upgrade Now',
|
|
159
|
+
style: 'default',
|
|
160
|
+
onPress: () => resolve(true)
|
|
161
|
+
}]);
|
|
162
|
+
});
|
|
163
|
+
};
|
|
164
|
+
|
|
165
|
+
// Force YouTube reconnection with consent screen
|
|
166
|
+
const forceYouTubeReconnection = async username => {
|
|
167
|
+
try {
|
|
168
|
+
var _user, _user2, _user3, _user4;
|
|
169
|
+
console.log('🔄 Starting YouTube migration for user:', username);
|
|
170
|
+
|
|
171
|
+
// 1. Configure for refresh tokens
|
|
172
|
+
configureGoogleSignInForRefreshTokens();
|
|
173
|
+
|
|
174
|
+
// 2. Complete sign out to clear cached consent
|
|
175
|
+
await _googleSignin.GoogleSignin.signOut();
|
|
176
|
+
console.log('✅ Signed out - consent cache cleared');
|
|
177
|
+
|
|
178
|
+
// 3. Clear cached tokens if available
|
|
179
|
+
try {
|
|
180
|
+
const existingTokens = await _googleSignin.GoogleSignin.getTokens();
|
|
181
|
+
if (existingTokens.accessToken) {
|
|
182
|
+
await _googleSignin.GoogleSignin.clearCachedAccessToken(existingTokens.accessToken);
|
|
183
|
+
console.log('✅ Token cache cleared');
|
|
184
|
+
}
|
|
185
|
+
} catch (clearError) {
|
|
186
|
+
console.log('ℹ️ No token cache to clear');
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
// 4. Check Google Play Services
|
|
190
|
+
await _googleSignin.GoogleSignin.hasPlayServices();
|
|
191
|
+
|
|
192
|
+
// 5. Sign in (this will show consent screen)
|
|
193
|
+
console.log('🔐 Initiating sign-in - consent screen should appear...');
|
|
194
|
+
const userInfo = await _googleSignin.GoogleSignin.signIn();
|
|
195
|
+
|
|
196
|
+
// 6. Get tokens after consent
|
|
197
|
+
const tokens = await _googleSignin.GoogleSignin.getTokens();
|
|
198
|
+
const currentUser = await _googleSignin.GoogleSignin.getCurrentUser();
|
|
199
|
+
|
|
200
|
+
// 7. Analyze tokens thoroughly (serverAuthCode is the refresh token mechanism in React Native)
|
|
201
|
+
let finalRefreshToken = null;
|
|
202
|
+
let refreshTokenSource = 'None';
|
|
203
|
+
|
|
204
|
+
// Check for server auth code from sign-in response (primary method)
|
|
205
|
+
if (userInfo.serverAuthCode) {
|
|
206
|
+
finalRefreshToken = userInfo.serverAuthCode;
|
|
207
|
+
refreshTokenSource = 'Server auth code from sign-in';
|
|
208
|
+
}
|
|
209
|
+
// Check current user server auth code (backup method)
|
|
210
|
+
else if (currentUser !== null && currentUser !== void 0 && currentUser.serverAuthCode) {
|
|
211
|
+
finalRefreshToken = currentUser.serverAuthCode;
|
|
212
|
+
refreshTokenSource = 'Current user server auth code';
|
|
213
|
+
}
|
|
214
|
+
console.log('🔍 Token Analysis:', {
|
|
215
|
+
hasAccessToken: !!tokens.accessToken,
|
|
216
|
+
hasIdToken: !!tokens.idToken,
|
|
217
|
+
hasServerAuthCode: !!userInfo.serverAuthCode,
|
|
218
|
+
hasCurrentUserAuthCode: !!(currentUser !== null && currentUser !== void 0 && currentUser.serverAuthCode),
|
|
219
|
+
refreshTokenSource: refreshTokenSource,
|
|
220
|
+
finalRefreshToken: finalRefreshToken ? 'Available' : 'MISSING!',
|
|
221
|
+
userEmail: (_user = userInfo.user) === null || _user === void 0 ? void 0 : _user.email
|
|
222
|
+
});
|
|
223
|
+
if (!finalRefreshToken) {
|
|
224
|
+
console.error('❌ No refresh token received - Google Console configuration may be incorrect');
|
|
225
|
+
console.error('💡 This usually means:');
|
|
226
|
+
console.error(' 1. offlineAccess: true is missing from configuration');
|
|
227
|
+
console.error(' 2. forceCodeForRefreshToken: true is missing');
|
|
228
|
+
console.error(' 3. User did not grant offline access permission');
|
|
229
|
+
return false;
|
|
230
|
+
}
|
|
231
|
+
console.log('✅ Got refresh token after consent:', finalRefreshToken.substring(0, 20) + '...');
|
|
232
|
+
console.log('🔑 Refresh token source:', refreshTokenSource);
|
|
233
|
+
|
|
234
|
+
// 8. Get existing authentication token
|
|
235
|
+
let authToken = (await _asyncStorage.default.getItem('onairos_jwt_token')) || (await _asyncStorage.default.getItem('enoch_token')) || (await _asyncStorage.default.getItem('auth_token'));
|
|
236
|
+
if (!authToken) {
|
|
237
|
+
console.warn('⚠️ No authentication token found for YouTube migration');
|
|
238
|
+
authToken = 'migration_token_placeholder';
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
// 9. Send enhanced payload to backend
|
|
242
|
+
const backendPayload = {
|
|
243
|
+
session: {
|
|
244
|
+
username: username,
|
|
245
|
+
platform: 'youtube',
|
|
246
|
+
channelName: ((_user2 = userInfo.user) === null || _user2 === void 0 ? void 0 : _user2.name) || 'YouTube Channel',
|
|
247
|
+
channelId: null
|
|
248
|
+
},
|
|
249
|
+
googleUser: userInfo.user,
|
|
250
|
+
accessToken: tokens.accessToken,
|
|
251
|
+
idToken: tokens.idToken,
|
|
252
|
+
refreshToken: finalRefreshToken,
|
|
253
|
+
serverAuthCode: userInfo.serverAuthCode,
|
|
254
|
+
userAccountInfo: {
|
|
255
|
+
username: username,
|
|
256
|
+
email: (_user3 = userInfo.user) === null || _user3 === void 0 ? void 0 : _user3.email,
|
|
257
|
+
authToken: authToken,
|
|
258
|
+
channelName: ((_user4 = userInfo.user) === null || _user4 === void 0 ? void 0 : _user4.name) || 'YouTube Channel',
|
|
259
|
+
channelId: null
|
|
260
|
+
}
|
|
261
|
+
};
|
|
262
|
+
console.log('📤 Sending migration payload to backend...');
|
|
263
|
+
|
|
264
|
+
// 10. Send to backend
|
|
265
|
+
const response = await fetch('https://api2.onairos.uk/youtube/native-auth', {
|
|
266
|
+
method: 'POST',
|
|
267
|
+
headers: {
|
|
268
|
+
'Content-Type': 'application/json',
|
|
269
|
+
'x-api-key': 'your-api-key',
|
|
270
|
+
// Use your existing API key if needed
|
|
271
|
+
...(authToken !== 'migration_token_placeholder' && {
|
|
272
|
+
'Authorization': `Bearer ${authToken}`
|
|
273
|
+
})
|
|
274
|
+
},
|
|
275
|
+
body: JSON.stringify(backendPayload)
|
|
276
|
+
});
|
|
277
|
+
const result = await response.json();
|
|
278
|
+
if (result.success) {
|
|
279
|
+
console.log('✅ YouTube migration successful');
|
|
280
|
+
|
|
281
|
+
// Track migration success
|
|
282
|
+
await trackMigrationAttempt(username, true);
|
|
283
|
+
return true;
|
|
284
|
+
} else {
|
|
285
|
+
console.error('❌ Backend rejected YouTube migration:', result.error);
|
|
286
|
+
await trackMigrationAttempt(username, false, result.error);
|
|
287
|
+
return false;
|
|
288
|
+
}
|
|
289
|
+
} catch (error) {
|
|
290
|
+
console.error('❌ YouTube migration failed:', error);
|
|
291
|
+
await trackMigrationAttempt(username, false, error instanceof Error ? error.message : 'Unknown error');
|
|
292
|
+
return false;
|
|
293
|
+
}
|
|
294
|
+
};
|
|
295
|
+
|
|
296
|
+
// Track migration attempts for monitoring
|
|
297
|
+
const trackMigrationAttempt = async (username, success, error) => {
|
|
298
|
+
try {
|
|
299
|
+
await fetch('https://api2.onairos.uk/youtube/migration-status', {
|
|
300
|
+
method: 'POST',
|
|
301
|
+
headers: {
|
|
302
|
+
'Content-Type': 'application/json'
|
|
303
|
+
},
|
|
304
|
+
body: JSON.stringify({
|
|
305
|
+
username,
|
|
306
|
+
success,
|
|
307
|
+
error: error || null,
|
|
308
|
+
timestamp: new Date().toISOString()
|
|
309
|
+
})
|
|
310
|
+
});
|
|
311
|
+
} catch (trackError) {
|
|
312
|
+
console.error('❌ Failed to track migration attempt:', trackError);
|
|
313
|
+
}
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
// ✅ NEW: Explicit function to check if user should see migration warnings
|
|
317
|
+
const shouldShowYouTubeMigrationWarning = async username => {
|
|
318
|
+
try {
|
|
319
|
+
console.log('🔍 [MIGRATION WARNING] Checking if user should see migration warning:', username);
|
|
320
|
+
const response = await fetch(`https://api2.onairos.uk/youtube/validate-connection/${username}`);
|
|
321
|
+
const result = await response.json();
|
|
322
|
+
if (result.success && result.validation) {
|
|
323
|
+
var _result$validation3, _result$temporaryMode4;
|
|
324
|
+
// Check for temporary mode (prioritize exact backend fields)
|
|
325
|
+
const isTemporaryMode = ((_result$validation3 = result.validation) === null || _result$validation3 === void 0 ? void 0 : _result$validation3.isTemporaryMode) === true || ((_result$temporaryMode4 = result.temporaryMode) === null || _result$temporaryMode4 === void 0 ? void 0 : _result$temporaryMode4.enabled) === true || result.isTemporaryMode === true;
|
|
326
|
+
const hasAccessToken = result.validation.hasAccessToken === true;
|
|
327
|
+
const hasRefreshToken = result.validation.hasRefreshToken === true;
|
|
328
|
+
const needsReconnection = result.validation.needsReconnection === true;
|
|
329
|
+
console.log('📊 [MIGRATION WARNING] Status check:', {
|
|
330
|
+
username,
|
|
331
|
+
hasAccessToken,
|
|
332
|
+
hasRefreshToken,
|
|
333
|
+
needsReconnection,
|
|
334
|
+
isTemporaryMode,
|
|
335
|
+
connectedAt: result.validation.connectedAt
|
|
336
|
+
});
|
|
337
|
+
if (isTemporaryMode) {
|
|
338
|
+
console.log('🚫 [MIGRATION WARNING] NO WARNING - user is in temporary mode (working correctly)');
|
|
339
|
+
return false; // Don't show migration warning
|
|
340
|
+
} else if (hasAccessToken && !hasRefreshToken && needsReconnection) {
|
|
341
|
+
console.log('⚠️ [MIGRATION WARNING] SHOW WARNING - genuinely old connection needs update');
|
|
342
|
+
return true; // Show migration warning for genuinely broken connections
|
|
343
|
+
} else {
|
|
344
|
+
console.log('✅ [MIGRATION WARNING] NO WARNING - connection is working properly');
|
|
345
|
+
return false; // Don't show warning for working connections
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
console.log('ℹ️ [MIGRATION WARNING] NO WARNING - no YouTube connection found');
|
|
349
|
+
return false; // Don't show warning if no connection
|
|
350
|
+
} catch (error) {
|
|
351
|
+
console.error('❌ [MIGRATION WARNING] Error checking migration warning status:', error);
|
|
352
|
+
return false; // Don't show warning on error
|
|
353
|
+
}
|
|
354
|
+
};
|
|
355
|
+
|
|
356
|
+
// Main function to check and fix YouTube connection
|
|
357
|
+
exports.shouldShowYouTubeMigrationWarning = shouldShowYouTubeMigrationWarning;
|
|
358
|
+
const checkAndFixYouTubeConnection = async username => {
|
|
359
|
+
try {
|
|
360
|
+
console.log('🔄 Checking YouTube connection for user:', username);
|
|
361
|
+
|
|
362
|
+
// 1. First check if user should see migration warning at all
|
|
363
|
+
const shouldShowWarning = await shouldShowYouTubeMigrationWarning(username);
|
|
364
|
+
if (!shouldShowWarning) {
|
|
365
|
+
console.log('🚫 [MIGRATION] NO MIGRATION NEEDED - user connection is working correctly');
|
|
366
|
+
console.log('✅ [MIGRATION] User can proceed with training normally');
|
|
367
|
+
return true; // Return success - no migration needed
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
// 2. Double-check migration is actually needed (for safety)
|
|
371
|
+
const needsMigration = await checkYouTubeMigrationNeeded(username);
|
|
372
|
+
if (!needsMigration) {
|
|
373
|
+
console.log('✅ [MIGRATION] YouTube connection working properly - no migration needed');
|
|
374
|
+
return true;
|
|
375
|
+
}
|
|
376
|
+
console.log('🔧 [MIGRATION] User needs YouTube migration for refresh token (genuinely old connection)');
|
|
377
|
+
|
|
378
|
+
// 2. Show user-friendly prompt
|
|
379
|
+
const userConfirmed = await showYouTubeMigrationPrompt();
|
|
380
|
+
if (!userConfirmed) {
|
|
381
|
+
console.log('ℹ️ User declined YouTube migration');
|
|
382
|
+
return false;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
// 3. Attempt migration
|
|
386
|
+
const migrationSuccess = await forceYouTubeReconnection(username);
|
|
387
|
+
if (migrationSuccess) {
|
|
388
|
+
// Show success message
|
|
389
|
+
_reactNative.Alert.alert('YouTube Upgraded! ✅', 'Your YouTube connection has been upgraded successfully. Training will now work seamlessly without interruptions.', [{
|
|
390
|
+
text: 'Great!',
|
|
391
|
+
style: 'default'
|
|
392
|
+
}]);
|
|
393
|
+
return true;
|
|
394
|
+
} else {
|
|
395
|
+
// Show failure message
|
|
396
|
+
_reactNative.Alert.alert('Upgrade Failed ❌', 'YouTube connection upgrade failed. Please try again later or contact support if the problem persists.', [{
|
|
397
|
+
text: 'OK',
|
|
398
|
+
style: 'default'
|
|
399
|
+
}]);
|
|
400
|
+
return false;
|
|
401
|
+
}
|
|
402
|
+
} catch (error) {
|
|
403
|
+
console.error('❌ Error in YouTube connection check:', error);
|
|
404
|
+
return false;
|
|
405
|
+
}
|
|
406
|
+
};
|
|
407
|
+
|
|
408
|
+
// Optional: Reconnect function for manual use
|
|
409
|
+
exports.checkAndFixYouTubeConnection = checkAndFixYouTubeConnection;
|
|
410
|
+
const reconnectYouTube = async username => {
|
|
411
|
+
console.log('🔄 Manual YouTube reconnection requested for:', username);
|
|
412
|
+
return await forceYouTubeReconnection(username);
|
|
413
|
+
};
|
|
414
|
+
exports.reconnectYouTube = reconnectYouTube;
|
|
415
|
+
//# sourceMappingURL=youtubeMigrationService.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_googleSignin","require","_reactNative","_asyncStorage","_interopRequireDefault","e","__esModule","default","WEB_CLIENT_ID","IOS_CLIENT_ID","configureGoogleSignInForRefreshTokens","GoogleSignin","configure","webClientId","iosClientId","offlineAccess","forceCodeForRefreshToken","scopes","hostedDomain","accountName","checkYouTubeMigrationNeeded","username","response","fetch","result","json","success","validation","_result$validation","_result$temporaryMode","_result$temporaryMode2","isTemporaryMode","temporaryMode","enabled","message","includes","needsReconnection","hasRefreshToken","console","log","temporaryModeEnabled","error","exports","getYouTubeConnectionStatus","_result$validation2","_result$temporaryMode3","isReady","mode","needsMigration","trainingReady","details","Error","String","showYouTubeMigrationPrompt","Promise","resolve","Alert","alert","text","style","onPress","forceYouTubeReconnection","_user","_user2","_user3","_user4","signOut","existingTokens","getTokens","accessToken","clearCachedAccessToken","clearError","hasPlayServices","userInfo","signIn","tokens","currentUser","getCurrentUser","finalRefreshToken","refreshTokenSource","serverAuthCode","hasAccessToken","hasIdToken","idToken","hasServerAuthCode","hasCurrentUserAuthCode","userEmail","user","email","substring","authToken","AsyncStorage","getItem","warn","backendPayload","session","platform","channelName","name","channelId","googleUser","refreshToken","userAccountInfo","method","headers","body","JSON","stringify","trackMigrationAttempt","timestamp","Date","toISOString","trackError","shouldShowYouTubeMigrationWarning","_result$validation3","_result$temporaryMode4","connectedAt","checkAndFixYouTubeConnection","shouldShowWarning","userConfirmed","migrationSuccess","reconnectYouTube"],"sourceRoot":"..\\..\\..\\src","sources":["services/youtubeMigrationService.ts"],"mappings":";;;;;;AAAA,IAAAA,aAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,aAAA,GAAAC,sBAAA,CAAAH,OAAA;AAAqE,SAAAG,uBAAAC,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAErE;AACA,MAAMG,aAAa,GAAG,2EAA2E;AACjG,MAAMC,aAAa,GAAG,2EAA2E;;AAEjG;AACA,MAAMC,qCAAqC,GAAGA,CAAA,KAAM;EAClDC,0BAAY,CAACC,SAAS,CAAC;IACrBC,WAAW,EAAEL,aAAa;IAAS;IACnCM,WAAW,EAAEL,aAAa;IAAS;;IAEnC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G,EACvG,CAAC;QAAEC,IAAI,EAAE,IAAI;QAAEC,KAAK,EAAE;MAAU,CAAC,CACnC,CAAC;MAED,OAAO,KAAK;IACd;EAEF,CAAC,CAAC,OAAOlB,KAAK,EAAE;IACdH,OAAO,CAACG,KAAK,CAAC,sCAAsC,EAAEA,KAAK,CAAC;IAC5D,OAAO,KAAK;EACd;AACF,CAAC;;AAED;AAAAC,OAAA,CAAA2E,4BAAA,GAAAA,4BAAA;AACO,MAAMI,gBAAgB,GAAG,MAAOpG,QAAgB,IAAuB;EAC5EiB,OAAO,CAACC,GAAG,CAAC,+CAA+C,EAAElB,QAAQ,CAAC;EACtE,OAAO,MAAMwC,wBAAwB,CAACxC,QAAQ,CAAC;AACjD,CAAC;AAACqB,OAAA,CAAA+E,gBAAA,GAAAA,gBAAA","ignoreList":[]}
|
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.TEXT_STYLES = exports.SPACING = exports.SHADOWS = exports.FONTS = exports.COLORS = exports.BORDER_RADIUS = void 0;
|
|
7
|
+
var _reactNative = require("react-native");
|
|
8
|
+
// Color Tokens as specified in the design brief
|
|
9
|
+
const COLORS = exports.COLORS = {
|
|
10
|
+
// Welcome Screen Specific Colors
|
|
11
|
+
surface: '#FAFAFA',
|
|
12
|
+
grey400: '#9CA3AF',
|
|
13
|
+
grey500: '#86888E',
|
|
14
|
+
grey600: '#62646C',
|
|
15
|
+
grey700: '#374151',
|
|
16
|
+
grey800: '#1F242F',
|
|
17
|
+
// PrimaryButton exact tokens
|
|
18
|
+
btnGradStart: '#29292B',
|
|
19
|
+
btnGradEnd: '#17181C',
|
|
20
|
+
btnBorder: 'rgba(0,0,0,0.20)',
|
|
21
|
+
btnShadowOuter: 'rgba(0,0,0,0.10)',
|
|
22
|
+
btnInnerShadow: 'rgba(0,0,0,0.06)',
|
|
23
|
+
btnLabel: '#FFFFFF',
|
|
24
|
+
iconCircleGradientStart: '#0A090E',
|
|
25
|
+
iconCircleGradientEnd: '#17171B',
|
|
26
|
+
// Legacy colors (preserved for backward compatibility)
|
|
27
|
+
primary: '#FFD700',
|
|
28
|
+
primaryDark: '#E9B104',
|
|
29
|
+
primaryLight: '#FFDF33',
|
|
30
|
+
background: {
|
|
31
|
+
dark: '#000000',
|
|
32
|
+
medium: '#121212',
|
|
33
|
+
light: '#1C2526'
|
|
34
|
+
},
|
|
35
|
+
text: {
|
|
36
|
+
primary: '#FFFFFF',
|
|
37
|
+
secondary: '#B0B0B0',
|
|
38
|
+
tertiary: '#808080',
|
|
39
|
+
gold: '#FFD700'
|
|
40
|
+
},
|
|
41
|
+
ui: {
|
|
42
|
+
cardBackground: 'rgba(255, 255, 255, 0.1)',
|
|
43
|
+
divider: 'rgba(255, 255, 255, 0.1)',
|
|
44
|
+
inputBackground: 'rgba(255, 255, 255, 0.1)',
|
|
45
|
+
buttonBackground: 'rgba(255, 255, 255, 0.1)'
|
|
46
|
+
},
|
|
47
|
+
status: {
|
|
48
|
+
success: '#4BB543',
|
|
49
|
+
error: '#FF3B30',
|
|
50
|
+
warning: '#FF9500',
|
|
51
|
+
info: '#5AC8FA'
|
|
52
|
+
},
|
|
53
|
+
transparent: 'transparent',
|
|
54
|
+
overlay: 'rgba(0, 0, 0, 0.7)'
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
// Typography - Font families and weights as specified
|
|
58
|
+
const FONTS = exports.FONTS = {
|
|
59
|
+
families: {
|
|
60
|
+
ibmPlexSans: _reactNative.Platform.OS === 'ios' ? 'IBM Plex Sans' : 'IBM Plex Sans',
|
|
61
|
+
ibmPlexSansBold: _reactNative.Platform.OS === 'ios' ? 'IBM Plex Sans' : 'IBM Plex Sans',
|
|
62
|
+
inter: _reactNative.Platform.OS === 'ios' ? 'Inter' : 'Inter-Regular',
|
|
63
|
+
// Legacy families
|
|
64
|
+
base: _reactNative.Platform.OS === 'ios' ? 'System' : 'Roboto',
|
|
65
|
+
serif: _reactNative.Platform.OS === 'ios' ? 'Georgia' : 'serif'
|
|
66
|
+
},
|
|
67
|
+
weights: {
|
|
68
|
+
light: '300',
|
|
69
|
+
regular: '400',
|
|
70
|
+
medium: '500',
|
|
71
|
+
semibold: '600',
|
|
72
|
+
bold: '700'
|
|
73
|
+
},
|
|
74
|
+
sizes: {
|
|
75
|
+
xs: 12,
|
|
76
|
+
sm: 14,
|
|
77
|
+
md: 16,
|
|
78
|
+
lg: 18,
|
|
79
|
+
xl: 20,
|
|
80
|
+
xxl: 24,
|
|
81
|
+
xxxl: 28,
|
|
82
|
+
title: 32,
|
|
83
|
+
large: 42,
|
|
84
|
+
// Welcome screen specific sizes
|
|
85
|
+
kicker: 18,
|
|
86
|
+
welcomeTitle: 48,
|
|
87
|
+
body: 16,
|
|
88
|
+
buttonLabel: 16
|
|
89
|
+
},
|
|
90
|
+
lineHeights: {
|
|
91
|
+
// Welcome screen specific line heights
|
|
92
|
+
kicker: 20,
|
|
93
|
+
// 111%
|
|
94
|
+
welcomeTitle: 54,
|
|
95
|
+
// 112.5%
|
|
96
|
+
body: 24,
|
|
97
|
+
// 150%
|
|
98
|
+
// Legacy line heights
|
|
99
|
+
sm: 16,
|
|
100
|
+
md: 20,
|
|
101
|
+
lg: 24,
|
|
102
|
+
xl: 28
|
|
103
|
+
},
|
|
104
|
+
letterSpacing: {
|
|
105
|
+
kicker: -0.24,
|
|
106
|
+
tight: -0.5,
|
|
107
|
+
normal: 0,
|
|
108
|
+
wide: 0.5
|
|
109
|
+
}
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
// Spacing tokens
|
|
113
|
+
const SPACING = exports.SPACING = {
|
|
114
|
+
xs: 4,
|
|
115
|
+
sm: 8,
|
|
116
|
+
md: 16,
|
|
117
|
+
lg: 24,
|
|
118
|
+
xl: 32,
|
|
119
|
+
xxl: 48,
|
|
120
|
+
xxxl: 64,
|
|
121
|
+
// Welcome screen specific spacing
|
|
122
|
+
modalTopPadding: 118,
|
|
123
|
+
modalHorizontal: 24
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
// Border radius tokens
|
|
127
|
+
const BORDER_RADIUS = exports.BORDER_RADIUS = {
|
|
128
|
+
xs: 4,
|
|
129
|
+
sm: 8,
|
|
130
|
+
md: 16,
|
|
131
|
+
lg: 24,
|
|
132
|
+
xl: 32,
|
|
133
|
+
pill: 100,
|
|
134
|
+
circle: 999,
|
|
135
|
+
// Welcome screen specific radii
|
|
136
|
+
modalTop: 24,
|
|
137
|
+
buttonPill: 100
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
// Shadow tokens
|
|
141
|
+
const SHADOWS = exports.SHADOWS = {
|
|
142
|
+
small: {
|
|
143
|
+
shadowColor: COLORS.primary,
|
|
144
|
+
shadowOffset: {
|
|
145
|
+
width: 0,
|
|
146
|
+
height: 2
|
|
147
|
+
},
|
|
148
|
+
shadowOpacity: 0.3,
|
|
149
|
+
shadowRadius: 4,
|
|
150
|
+
elevation: 3
|
|
151
|
+
},
|
|
152
|
+
medium: {
|
|
153
|
+
shadowColor: COLORS.primary,
|
|
154
|
+
shadowOffset: {
|
|
155
|
+
width: 0,
|
|
156
|
+
height: 4
|
|
157
|
+
},
|
|
158
|
+
shadowOpacity: 0.5,
|
|
159
|
+
shadowRadius: 8,
|
|
160
|
+
elevation: 5
|
|
161
|
+
},
|
|
162
|
+
large: {
|
|
163
|
+
shadowColor: COLORS.primary,
|
|
164
|
+
shadowOffset: {
|
|
165
|
+
width: 0,
|
|
166
|
+
height: 6
|
|
167
|
+
},
|
|
168
|
+
shadowOpacity: 0.8,
|
|
169
|
+
shadowRadius: 16,
|
|
170
|
+
elevation: 8
|
|
171
|
+
},
|
|
172
|
+
// Welcome screen specific shadows
|
|
173
|
+
button: {
|
|
174
|
+
// Inner shadow (simulated via overlay)
|
|
175
|
+
inner: {
|
|
176
|
+
shadowColor: COLORS.btnInnerShadow,
|
|
177
|
+
shadowOffset: {
|
|
178
|
+
width: 0,
|
|
179
|
+
height: -36
|
|
180
|
+
},
|
|
181
|
+
shadowOpacity: 1,
|
|
182
|
+
shadowRadius: 21.1
|
|
183
|
+
},
|
|
184
|
+
// Outer shadow
|
|
185
|
+
outer: {
|
|
186
|
+
shadowColor: COLORS.btnShadowOuter,
|
|
187
|
+
shadowOffset: {
|
|
188
|
+
width: 20,
|
|
189
|
+
height: 30
|
|
190
|
+
},
|
|
191
|
+
shadowOpacity: 1,
|
|
192
|
+
shadowRadius: 40,
|
|
193
|
+
elevation: 8
|
|
194
|
+
}
|
|
195
|
+
},
|
|
196
|
+
brandMark: {
|
|
197
|
+
shadowColor: '#000000',
|
|
198
|
+
shadowOffset: {
|
|
199
|
+
width: 0,
|
|
200
|
+
height: 4
|
|
201
|
+
},
|
|
202
|
+
shadowOpacity: 0.1,
|
|
203
|
+
shadowRadius: 8,
|
|
204
|
+
elevation: 4
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
|
|
208
|
+
// Typography style objects for easy use
|
|
209
|
+
const TEXT_STYLES = exports.TEXT_STYLES = {
|
|
210
|
+
// Welcome screen typography
|
|
211
|
+
kicker: {
|
|
212
|
+
fontFamily: FONTS.families.ibmPlexSansBold,
|
|
213
|
+
fontWeight: FONTS.weights.bold,
|
|
214
|
+
fontSize: FONTS.sizes.kicker,
|
|
215
|
+
lineHeight: FONTS.lineHeights.kicker,
|
|
216
|
+
letterSpacing: FONTS.letterSpacing.kicker,
|
|
217
|
+
color: COLORS.grey500
|
|
218
|
+
},
|
|
219
|
+
welcomeTitle: {
|
|
220
|
+
fontFamily: FONTS.families.ibmPlexSansBold,
|
|
221
|
+
fontWeight: FONTS.weights.bold,
|
|
222
|
+
fontSize: FONTS.sizes.welcomeTitle,
|
|
223
|
+
lineHeight: FONTS.lineHeights.welcomeTitle,
|
|
224
|
+
color: COLORS.grey800
|
|
225
|
+
},
|
|
226
|
+
body: {
|
|
227
|
+
fontFamily: FONTS.families.inter,
|
|
228
|
+
fontWeight: FONTS.weights.regular,
|
|
229
|
+
fontSize: FONTS.sizes.body,
|
|
230
|
+
lineHeight: FONTS.lineHeights.body,
|
|
231
|
+
textAlign: 'center',
|
|
232
|
+
color: COLORS.grey600
|
|
233
|
+
},
|
|
234
|
+
buttonLabel: {
|
|
235
|
+
fontFamily: FONTS.families.inter,
|
|
236
|
+
fontWeight: FONTS.weights.semibold,
|
|
237
|
+
fontSize: FONTS.sizes.buttonLabel,
|
|
238
|
+
color: COLORS.btnLabel
|
|
239
|
+
}
|
|
240
|
+
};
|
|
241
|
+
var _default = exports.default = {
|
|
242
|
+
COLORS,
|
|
243
|
+
FONTS,
|
|
244
|
+
SPACING,
|
|
245
|
+
BORDER_RADIUS,
|
|
246
|
+
SHADOWS,
|
|
247
|
+
TEXT_STYLES
|
|
248
|
+
};
|
|
249
|
+
//# sourceMappingURL=index.js.map
|