@onairos/react-native 3.7.1 → 3.7.3
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 +219 -9
- package/lib/commonjs/assets/icons/spotify.png +0 -0
- package/lib/commonjs/assets/images/spotify.png +0 -0
- package/lib/commonjs/components/BodyText.js +27 -9
- package/lib/commonjs/components/BrandMark.js +111 -10
- package/lib/commonjs/components/CodeInput.js +116 -9
- package/lib/commonjs/components/EmailInput.js +30 -8
- package/lib/commonjs/components/GoogleButton.js +56 -9
- package/lib/commonjs/components/HeadingGroup.js +43 -9
- package/lib/commonjs/components/LLMDataInputModal.js +664 -14
- package/lib/commonjs/components/ModalHeader.js +99 -9
- package/lib/commonjs/components/ModalSheet.js +47 -9
- package/lib/commonjs/components/Onairos.js +380 -14
- package/lib/commonjs/components/OnairosButton.js +313 -13
- package/lib/commonjs/components/OnairosSignInButton.js +130 -12
- package/lib/commonjs/components/Overlay.js +465 -13
- package/lib/commonjs/components/PersonaImage.js +137 -10
- package/lib/commonjs/components/PersonaLoadingScreen.js +318 -12
- package/lib/commonjs/components/PersonalizationConsentScreen.js +467 -13
- package/lib/commonjs/components/PinCreationScreen.js +403 -12
- package/lib/commonjs/components/PinInput.js +464 -9
- package/lib/commonjs/components/PlatformConnectorsStep.js +1311 -23
- package/lib/commonjs/components/PlatformList.js +137 -10
- package/lib/commonjs/components/PlatformToggle.js +180 -9
- package/lib/commonjs/components/PrimaryButton.js +180 -10
- package/lib/commonjs/components/SignInMatchAnimation.js +197 -9
- package/lib/commonjs/components/SignInStep.js +345 -12
- package/lib/commonjs/components/UniversalOnboarding.js +2780 -30
- package/lib/commonjs/components/VerificationStep.js +176 -11
- package/lib/commonjs/components/WelcomeScreen.js +461 -22
- package/lib/commonjs/components/icons/Basicproficon.js +37 -8
- package/lib/commonjs/components/icons/Basicprofile.js +21 -8
- package/lib/commonjs/components/icons/Checkbox.js +21 -8
- package/lib/commonjs/components/icons/Checkmark.js +27 -8
- package/lib/commonjs/components/icons/Contentanalysis.js +21 -8
- package/lib/commonjs/components/icons/Contenticon.js +39 -8
- package/lib/commonjs/components/icons/EnochE.js +41 -8
- package/lib/commonjs/components/icons/Personalityicon.js +30 -8
- package/lib/commonjs/components/icons/Personalityprofile.js +21 -8
- package/lib/commonjs/components/icons/Personalitytraits.js +21 -8
- package/lib/commonjs/components/icons/Userpreferences.js +21 -8
- package/lib/commonjs/components/icons/index.js +84 -17
- package/lib/commonjs/components/onboarding/OAuthWebView.js +1754 -18
- package/lib/commonjs/components/onboarding/OnboardingHeader.js +74 -10
- package/lib/commonjs/components/onboarding/PinInput.js +283 -10
- package/lib/commonjs/components/onboarding/PlatformConnector.js +249 -11
- package/lib/commonjs/config/PLATFORM_APIS.md +849 -0
- package/lib/commonjs/config/api.js +56 -7
- package/lib/commonjs/constants/index.js +120 -7
- package/lib/commonjs/context/AuthContext.js +345 -10
- package/lib/commonjs/hooks/useConnectedAccounts.js +111 -9
- package/lib/commonjs/hooks/useConnections.js +102 -8
- package/lib/commonjs/hooks/useCredentials.js +178 -10
- package/lib/commonjs/hooks/useUserConnections.js +148 -10
- package/lib/commonjs/index.js +439 -34
- package/lib/commonjs/services/apiClient.js +298 -8
- package/lib/commonjs/services/biometricPinService.js +180 -8
- package/lib/commonjs/services/chatGPTConversationExtractor.js +155 -8
- package/lib/commonjs/services/chatGPTConversationService.js +275 -9
- package/lib/commonjs/services/claudeConversationExtractor.js +103 -8
- package/lib/commonjs/services/claudeConversationService.js +158 -9
- package/lib/commonjs/services/connectedAccountsService.js +310 -10
- package/lib/commonjs/services/googleAuthService.js +252 -11
- package/lib/commonjs/services/hingeDataExtractor.js +105 -8
- package/lib/commonjs/services/hingeDataService.js +150 -9
- package/lib/commonjs/services/imageCompressionService.js +260 -7
- package/lib/commonjs/services/instagramDataExtractor.js +126 -8
- package/lib/commonjs/services/instagramDataService.js +163 -9
- package/lib/commonjs/services/jwtStorageService.js +276 -7
- package/lib/commonjs/services/linkedinDOMExtractor.js +245 -7
- package/lib/commonjs/services/linkedinProfileService.js +222 -9
- package/lib/commonjs/services/linkedinScrapingService.js +230 -8
- package/lib/commonjs/services/llmDataStorage.js +294 -8
- package/lib/commonjs/services/mobileTrainingService.js +186 -8
- package/lib/commonjs/services/netflixDataExtractor.js +120 -8
- package/lib/commonjs/services/netflixDataService.js +198 -9
- package/lib/commonjs/services/pinEncryptionService.js +84 -8
- package/lib/commonjs/services/pinStorageUtils.js +105 -7
- package/lib/commonjs/services/platformAuthService.js +1484 -12
- package/lib/commonjs/services/sephoraDataExtractor.js +140 -8
- package/lib/commonjs/services/sephoraDataService.js +200 -9
- package/lib/commonjs/services/spotifyDataExtractor.js +148 -8
- package/lib/commonjs/services/spotifyDataService.js +241 -9
- package/lib/commonjs/services/storageService.js +404 -8
- package/lib/commonjs/services/telegramDataExtractor.js +115 -8
- package/lib/commonjs/services/telegramDataService.js +499 -9
- package/lib/commonjs/services/trainingApiHelpers.js +73 -7
- package/lib/commonjs/services/userConnectionsService.js +340 -10
- package/lib/commonjs/services/youtubeMigrationService.js +416 -10
- package/lib/commonjs/theme/index.js +250 -7
- package/lib/commonjs/types/ambient.d.js +2 -1
- package/lib/commonjs/types/declarations.d.js +2 -1
- package/lib/commonjs/types/index.js +6 -1
- package/lib/commonjs/types/node-fix.d.js +2 -1
- package/lib/commonjs/types/node-override.d.js +2 -1
- package/lib/commonjs/types/opacity.d.js +2 -1
- package/lib/commonjs/types.js +14 -1
- package/lib/commonjs/utils/Portal.js +98 -8
- package/lib/commonjs/utils/api.js +130 -9
- package/lib/commonjs/utils/assetRegistry.js +210 -35
- package/lib/commonjs/utils/auth.js +112 -9
- package/lib/commonjs/utils/connectorTests.js +613 -29
- package/lib/commonjs/utils/crypto.js +62 -8
- package/lib/commonjs/utils/debugHelper.js +64 -1
- package/lib/commonjs/utils/encryption.js +76 -7
- package/lib/commonjs/utils/eventUtils.js +288 -1
- package/lib/commonjs/utils/haptics.js +66 -9
- package/lib/commonjs/utils/imagePreloader.js +6 -1
- package/lib/commonjs/utils/networkDiagnostics.js +226 -8
- package/lib/commonjs/utils/onairosApi.js +350 -9
- package/lib/commonjs/utils/programmaticFlow.js +117 -9
- package/lib/commonjs/utils/retryHelper.js +220 -1
- package/lib/commonjs/utils/secureStorage.js +349 -10
- package/lib/commonjs/utils/webviewScripts/chatgpt.js +551 -1
- package/lib/commonjs/utils/webviewScripts/claude.js +376 -1
- package/lib/commonjs/utils/webviewScripts/hinge.js +411 -1
- package/lib/commonjs/utils/webviewScripts/index.js +698 -15
- package/lib/commonjs/utils/webviewScripts/instagram.js +454 -1
- package/lib/commonjs/utils/webviewScripts/linkedin.js +880 -1
- package/lib/commonjs/utils/webviewScripts/netflix.js +382 -1
- package/lib/commonjs/utils/webviewScripts/sephora.js +516 -1
- package/lib/commonjs/utils/webviewScripts/spotify.js +419 -1
- package/lib/commonjs/utils/webviewScripts/telegram.js +678 -1
- package/lib/module/api/index.js +211 -1
- package/lib/module/assets/icons/spotify.png +0 -0
- package/lib/module/assets/images/spotify.png +0 -0
- package/lib/module/components/BodyText.js +20 -1
- package/lib/module/components/BrandMark.js +104 -1
- package/lib/module/components/CodeInput.js +109 -1
- package/lib/module/components/EmailInput.js +23 -1
- package/lib/module/components/GoogleButton.js +49 -1
- package/lib/module/components/HeadingGroup.js +36 -1
- package/lib/module/components/LLMDataInputModal.js +656 -7
- package/lib/module/components/ModalHeader.js +92 -1
- package/lib/module/components/ModalSheet.js +39 -1
- package/lib/module/components/Onairos.js +373 -1
- package/lib/module/components/OnairosButton.js +305 -1
- package/lib/module/components/OnairosSignInButton.js +121 -1
- package/lib/module/components/Overlay.js +456 -1
- package/lib/module/components/PersonaImage.js +129 -1
- package/lib/module/components/PersonaLoadingScreen.js +310 -1
- package/lib/module/components/PersonalizationConsentScreen.js +460 -1
- package/lib/module/components/PinCreationScreen.js +396 -1
- package/lib/module/components/PinInput.js +456 -1
- package/lib/module/components/PlatformConnectorsStep.js +1302 -6
- package/lib/module/components/PlatformList.js +129 -1
- package/lib/module/components/PlatformToggle.js +173 -1
- package/lib/module/components/PrimaryButton.js +172 -1
- package/lib/module/components/SignInMatchAnimation.js +189 -1
- package/lib/module/components/SignInStep.js +338 -1
- package/lib/module/components/UniversalOnboarding.js +2770 -1
- package/lib/module/components/VerificationStep.js +168 -1
- package/lib/module/components/WelcomeScreen.js +453 -1
- package/lib/module/components/icons/Basicproficon.js +30 -1
- package/lib/module/components/icons/Basicprofile.js +14 -1
- package/lib/module/components/icons/Checkbox.js +14 -1
- package/lib/module/components/icons/Checkmark.js +20 -1
- package/lib/module/components/icons/Contentanalysis.js +14 -1
- package/lib/module/components/icons/Contenticon.js +32 -1
- package/lib/module/components/icons/EnochE.js +34 -1
- package/lib/module/components/icons/Personalityicon.js +23 -1
- package/lib/module/components/icons/Personalityprofile.js +14 -1
- package/lib/module/components/icons/Personalitytraits.js +14 -1
- package/lib/module/components/icons/Userpreferences.js +14 -1
- package/lib/module/components/icons/index.js +13 -1
- package/lib/module/components/onboarding/OAuthWebView.js +1746 -1
- package/lib/module/components/onboarding/OnboardingHeader.js +66 -1
- package/lib/module/components/onboarding/PinInput.js +274 -1
- package/lib/module/components/onboarding/PlatformConnector.js +240 -1
- package/lib/module/config/PLATFORM_APIS.md +849 -0
- package/lib/module/config/api.js +47 -1
- package/lib/module/constants/index.js +114 -1
- package/lib/module/context/AuthContext.js +335 -1
- package/lib/module/hooks/useConnectedAccounts.js +106 -1
- package/lib/module/hooks/useConnections.js +95 -1
- package/lib/module/hooks/useCredentials.js +171 -6
- package/lib/module/hooks/useUserConnections.js +140 -1
- package/lib/module/index.js +172 -1
- package/lib/module/services/apiClient.js +295 -1
- package/lib/module/services/biometricPinService.js +169 -1
- package/lib/module/services/chatGPTConversationExtractor.js +149 -1
- package/lib/module/services/chatGPTConversationService.js +268 -1
- package/lib/module/services/claudeConversationExtractor.js +97 -1
- package/lib/module/services/claudeConversationService.js +151 -1
- package/lib/module/services/connectedAccountsService.js +293 -1
- package/lib/module/services/googleAuthService.js +241 -1
- package/lib/module/services/hingeDataExtractor.js +99 -1
- package/lib/module/services/hingeDataService.js +143 -1
- package/lib/module/services/imageCompressionService.js +250 -1
- package/lib/module/services/instagramDataExtractor.js +120 -1
- package/lib/module/services/instagramDataService.js +156 -1
- package/lib/module/services/jwtStorageService.js +257 -1
- package/lib/module/services/linkedinDOMExtractor.js +234 -1
- package/lib/module/services/linkedinProfileService.js +210 -1
- package/lib/module/services/linkedinScrapingService.js +219 -1
- package/lib/module/services/llmDataStorage.js +277 -1
- package/lib/module/services/mobileTrainingService.js +173 -1
- package/lib/module/services/netflixDataExtractor.js +114 -1
- package/lib/module/services/netflixDataService.js +191 -1
- package/lib/module/services/pinEncryptionService.js +74 -6
- package/lib/module/services/pinStorageUtils.js +93 -1
- package/lib/module/services/platformAuthService.js +1461 -1
- package/lib/module/services/sephoraDataExtractor.js +134 -1
- package/lib/module/services/sephoraDataService.js +193 -1
- package/lib/module/services/spotifyDataExtractor.js +142 -1
- package/lib/module/services/spotifyDataService.js +234 -1
- package/lib/module/services/storageService.js +383 -1
- package/lib/module/services/telegramDataExtractor.js +109 -1
- package/lib/module/services/telegramDataService.js +493 -1
- package/lib/module/services/trainingApiHelpers.js +67 -1
- package/lib/module/services/userConnectionsService.js +329 -1
- package/lib/module/services/youtubeMigrationService.js +405 -1
- package/lib/module/theme/index.js +245 -1
- package/lib/module/types.js +10 -1
- package/lib/module/utils/Portal.js +90 -1
- package/lib/module/utils/api.js +118 -1
- package/lib/module/utils/assetRegistry.js +200 -34
- package/lib/module/utils/auth.js +100 -1
- package/lib/module/utils/connectorTests.js +600 -27
- package/lib/module/utils/crypto.js +54 -1
- package/lib/module/utils/debugHelper.js +54 -1
- package/lib/module/utils/encryption.js +67 -1
- package/lib/module/utils/eventUtils.js +270 -1
- package/lib/module/utils/haptics.js +59 -8
- package/lib/module/utils/imagePreloader.js +3 -1
- package/lib/module/utils/networkDiagnostics.js +217 -1
- package/lib/module/utils/onairosApi.js +333 -1
- package/lib/module/utils/programmaticFlow.js +111 -1
- package/lib/module/utils/retryHelper.js +211 -1
- package/lib/module/utils/secureStorage.js +330 -6
- package/lib/module/utils/webviewScripts/chatgpt.js +545 -1
- package/lib/module/utils/webviewScripts/claude.js +370 -1
- package/lib/module/utils/webviewScripts/hinge.js +405 -1
- package/lib/module/utils/webviewScripts/index.js +434 -1
- package/lib/module/utils/webviewScripts/instagram.js +448 -1
- package/lib/module/utils/webviewScripts/linkedin.js +874 -1
- package/lib/module/utils/webviewScripts/netflix.js +376 -1
- package/lib/module/utils/webviewScripts/sephora.js +510 -1
- package/lib/module/utils/webviewScripts/spotify.js +413 -1
- package/lib/module/utils/webviewScripts/telegram.js +672 -1
- package/package.json +2 -2
|
@@ -1,11 +1,176 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
Object['defineProperty'](exports,_0x2596(0x0),{'value':!![]}),exports[_0x2596(0x1)]=exports[_0x2596(0x2)]=void 0x0;var _react=_interopRequireWildcard(__ONAIROS_REQ_FUNC__(0x0)),_reactNative=__ONAIROS_REQ_FUNC__(0x1),_theme=__ONAIROS_REQ_FUNC__(0x2),_CodeInput=_interopRequireDefault(__ONAIROS_REQ_FUNC__(0x3)),_PrimaryButton=_interopRequireDefault(__ONAIROS_REQ_FUNC__(0x4));function _0x5ca9(){var _0x4cd75b=['__esModule','default','VerificationStep','object','function','KSzuy','cRkZB','PjubT','nJwxr','PAhFM','has','set','PigdU','call','defineProperty','get','dxyxl','TjurG','DLUEp','height','We\x27ve\x20sent\x20a\x206-digit\x20code\x20to\x20','Back','Didn\x27t\x20receive\x20the\x20code?\x20','Resend\x20Code','BlsNw','ios','padding','useState','nWsYT','DvoMr','length','DZpbV','createElement','KeyboardAvoidingView','Platform','xnnHE','View','headingContainer','Text','lHJgb','hFUSk','errorText','continueContainer','Continue','backButtonContainer','backButtonText','backButtonDisabled','exQlq','resendContainer','resendText','TouchableOpacity','resendButton','resendLink','UfqnM','spacer','TKYxl','cjtFw','PvVTn','container','content','title','codeContainer','ELKxa','kyBsc','resendLinkDisabled','StyleSheet','create','100%','COLORS','grey800','left','Inter','400','#DC3545','center','row','grey600','500','#D4A536','underline','grey400','none','grey500'];_0x5ca9=function(){return _0x4cd75b;};return _0x5ca9();}function _interopRequireDefault(_0x2db02f){return _0x2db02f&&_0x2db02f[_0x2596(0x0)]?_0x2db02f:{'default':_0x2db02f};}function _interopRequireWildcard(_0x5eb29a,_0x462f45){var _0x13fe08={'PjubT':function(_0x33681a,_0x48a454){return _0x33681a&&_0x48a454;},'nJwxr':function(_0x209788,_0xb2d25a){return _0x209788!=_0xb2d25a;},'sXqdu':_0x2596(0x3),'PAhFM':function(_0x32703d,_0x817a90){return _0x32703d!=_0x817a90;},'cRkZB':_0x2596(0x4),'PigdU':function(_0x461232,_0xbe9507){return _0x461232!==_0xbe9507;},'PVPDb':_0x2596(0x1),'dxyxl':function(_0x4f5993,_0x3be786,_0x125307,_0x19ca07){return _0x4f5993(_0x3be786,_0x125307,_0x19ca07);},'KSzuy':function(_0x1e4931,_0xa1a010){return _0x1e4931==_0xa1a010;}};if(_0x13fe08[_0x2596(0x5)](_0x13fe08[_0x2596(0x6)],typeof WeakMap))var _0x206ba7=new WeakMap(),_0x44659c=new WeakMap();return(_interopRequireWildcard=function(_0x342f3d,_0x10466b){if(_0x13fe08[_0x2596(0x7)](!_0x10466b,_0x342f3d)&&_0x342f3d[_0x2596(0x0)])return _0x342f3d;var _0x13c792,_0x84d9b4,_0x6fbc4b={'__proto__':null,'default':_0x342f3d};if(null===_0x342f3d||_0x13fe08[_0x2596(0x8)](_0x13fe08['sXqdu'],typeof _0x342f3d)&&_0x13fe08[_0x2596(0x9)](_0x13fe08[_0x2596(0x6)],typeof _0x342f3d))return _0x6fbc4b;if(_0x13c792=_0x10466b?_0x44659c:_0x206ba7){if(_0x13c792[_0x2596(0xa)](_0x342f3d))return _0x13c792['get'](_0x342f3d);_0x13c792[_0x2596(0xb)](_0x342f3d,_0x6fbc4b);}for(const _0x3810bb in _0x342f3d)_0x13fe08[_0x2596(0xc)](_0x13fe08['PVPDb'],_0x3810bb)&&{}['hasOwnProperty'][_0x2596(0xd)](_0x342f3d,_0x3810bb)&&((_0x84d9b4=(_0x13c792=Object[_0x2596(0xe)])&&Object['getOwnPropertyDescriptor'](_0x342f3d,_0x3810bb))&&(_0x84d9b4[_0x2596(0xf)]||_0x84d9b4[_0x2596(0xb)])?_0x13fe08[_0x2596(0x10)](_0x13c792,_0x6fbc4b,_0x3810bb,_0x84d9b4):_0x6fbc4b[_0x3810bb]=_0x342f3d[_0x3810bb]);return _0x6fbc4b;})(_0x5eb29a,_0x462f45);}function _0x2596(_0x5ca9dc,_0x2596c9){_0x5ca9dc=_0x5ca9dc-0x0;var _0x574618=_0x5ca9();var _0x3f6da3=_0x574618[_0x5ca9dc];return _0x3f6da3;}const VerificationStep=({email:_0x1652fd,onCodeSubmit:_0x4c9d15,onBack:_0x2d157b,loading:loading=![],error:error='',onResendCode:_0x4f10c5})=>{var _0x90f6b6={'DvoMr':function(_0x28593c,_0x5ac340){return _0x28593c(_0x5ac340);},'kwGBr':_0x2596(0x11),'nWsYT':_0x2596(0x12),'xnnHE':_0x2596(0x13),'lHJgb':'Enter\x20verification\x20code','hFUSk':_0x2596(0x14),'exQlq':_0x2596(0x15),'kyBsc':_0x2596(0x16),'UfqnM':_0x2596(0x17),'ELKxa':function(_0x46988b,_0x1fb0c6){return _0x46988b!==_0x1fb0c6;},'hmjdK':_0x2596(0x18),'Olrzt':'DmWVj','dBCJK':function(_0x5748aa,_0x273c5e){return _0x5748aa===_0x273c5e;},'DZpbV':function(_0x4bf517,_0x3c0bbc){return _0x4bf517(_0x3c0bbc);},'TKYxl':function(_0x54c156,_0x17dc0a){return _0x54c156===_0x17dc0a;},'cjtFw':_0x2596(0x19),'PvVTn':_0x2596(0x1a),'HWOQr':'Continue'};const [_0x4c0d8f,_0x2cdf62]=(0x0,_react[_0x2596(0x1b)])(''),_0x30de5c=_0x44e4ca=>{_0x90f6b6['kwGBr']===_0x90f6b6[_0x2596(0x1c)]?_0x90f6b6[_0x2596(0x1d)](_0x4e8401,_0x5548a0):_0x90f6b6[_0x2596(0x1d)](_0x2cdf62,_0x44e4ca);},_0x4daf9d=()=>{if(_0x90f6b6['ELKxa'](_0x90f6b6['hmjdK'],_0x90f6b6['Olrzt']))_0x90f6b6['dBCJK'](_0x4c0d8f[_0x2596(0x1e)],0x6)&&_0x90f6b6[_0x2596(0x1f)](_0x4c9d15,_0x4c0d8f);else{const [_0x4c3aca,_0x125e1a]=(0x0,_0x41216b[_0x2596(0x1b)])(''),_0x2b412c=_0x927925=>{_0x125e1a(_0x927925);},_0x160fef=()=>{_0x4c3aca[_0x2596(0x1e)]===0x6&&_0x2a6383(_0x4c3aca);};return _0x347218['default'][_0x2596(0x20)](_0x1e2967[_0x2596(0x21)],{'behavior':_0x4ed7e8[_0x2596(0x22)]['OS']===_0x2596(0x19)?_0x2596(0x1a):_0x90f6b6[_0x2596(0x23)],'style':_0x14c225['container']},_0x1a86a0[_0x2596(0x1)][_0x2596(0x20)](_0x402175[_0x2596(0x24)],{'style':_0x752986['content']},_0x45c1fc[_0x2596(0x1)]['createElement'](_0x595207[_0x2596(0x24)],{'style':_0x439e06[_0x2596(0x25)]},_0xc653ea[_0x2596(0x1)][_0x2596(0x20)](_0x4bc614[_0x2596(0x26)],{'style':_0x3db510['title']},_0x90f6b6[_0x2596(0x27)]),_0x3ce0c8[_0x2596(0x1)]['createElement'](_0x519d32[_0x2596(0x26)],{'style':_0x370e65['subtitle']},_0x90f6b6[_0x2596(0x28)],_0x49c83a)),_0x11abf6[_0x2596(0x1)][_0x2596(0x20)](_0x4989ae[_0x2596(0x24)],{'style':_0x346d6f['codeContainer']},_0xf70463[_0x2596(0x1)][_0x2596(0x20)](_0x389292['default'],{'length':0x6,'onCodeChange':_0x2b412c}),_0x368614?_0x5d783e[_0x2596(0x1)][_0x2596(0x20)](_0x577ee4[_0x2596(0x26)],{'style':_0x4200e5[_0x2596(0x29)]},_0x3d7f78):null),_0x267585[_0x2596(0x1)]['createElement'](_0x1b83f9[_0x2596(0x24)],{'style':_0x14e7e0[_0x2596(0x2a)]},_0x46ca35['default'][_0x2596(0x20)](_0x4e3aa2[_0x2596(0x1)],{'label':_0x2596(0x2b),'onPress':_0x160fef,'disabled':_0x444faa||_0x4c3aca[_0x2596(0x1e)]!==0x6,'loading':_0x2261c0})),_0x2d6668[_0x2596(0x1)][_0x2596(0x20)](_0x314f92['TouchableOpacity'],{'onPress':_0x5e5cea,'disabled':_0x420756,'style':_0x34f7a0[_0x2596(0x2c)]},_0x4f2578[_0x2596(0x1)][_0x2596(0x20)](_0x156fc2[_0x2596(0x26)],{'style':[_0x549c7f[_0x2596(0x2d)],_0x1e5e3d&&_0x1c8f02[_0x2596(0x2e)]]},_0x90f6b6[_0x2596(0x2f)])),_0x494a69&&_0x2fc7c5[_0x2596(0x1)][_0x2596(0x20)](_0xe25f49['View'],{'style':_0x486df0[_0x2596(0x30)]},_0x5584c6[_0x2596(0x1)][_0x2596(0x20)](_0x48b1fa[_0x2596(0x26)],{'style':_0xe005dc[_0x2596(0x31)]},_0x90f6b6['kyBsc']),_0x3f5945[_0x2596(0x1)][_0x2596(0x20)](_0x42e9ff[_0x2596(0x32)],{'onPress':_0x3ab64e,'disabled':_0x4a7a84,'style':_0x58517d[_0x2596(0x33)]},_0x407650[_0x2596(0x1)][_0x2596(0x20)](_0x2bb4cb[_0x2596(0x26)],{'style':[_0x4f27f7[_0x2596(0x34)],_0x441341&&_0x3d3c1a['resendLinkDisabled']]},_0x90f6b6[_0x2596(0x35)]))),_0x148b5e[_0x2596(0x1)][_0x2596(0x20)](_0x5562e0[_0x2596(0x24)],{'style':_0x4421aa[_0x2596(0x36)]})));}};return _react['default'][_0x2596(0x20)](_reactNative[_0x2596(0x21)],{'behavior':_0x90f6b6[_0x2596(0x37)](_reactNative['Platform']['OS'],_0x90f6b6[_0x2596(0x38)])?_0x90f6b6[_0x2596(0x39)]:_0x90f6b6[_0x2596(0x23)],'style':styles[_0x2596(0x3a)]},_react[_0x2596(0x1)]['createElement'](_reactNative['View'],{'style':styles[_0x2596(0x3b)]},_react['default'][_0x2596(0x20)](_reactNative[_0x2596(0x24)],{'style':styles[_0x2596(0x25)]},_react['default'][_0x2596(0x20)](_reactNative[_0x2596(0x26)],{'style':styles[_0x2596(0x3c)]},_0x90f6b6[_0x2596(0x27)]),_react['default'][_0x2596(0x20)](_reactNative['Text'],{'style':styles['subtitle']},'We\x27ve\x20sent\x20a\x206-digit\x20code\x20to\x20',_0x1652fd)),_react['default'][_0x2596(0x20)](_reactNative['View'],{'style':styles[_0x2596(0x3d)]},_react['default'][_0x2596(0x20)](_CodeInput[_0x2596(0x1)],{'length':0x6,'onCodeChange':_0x30de5c}),error?_react[_0x2596(0x1)][_0x2596(0x20)](_reactNative[_0x2596(0x26)],{'style':styles[_0x2596(0x29)]},error):null),_react[_0x2596(0x1)][_0x2596(0x20)](_reactNative[_0x2596(0x24)],{'style':styles[_0x2596(0x2a)]},_react[_0x2596(0x1)][_0x2596(0x20)](_PrimaryButton['default'],{'label':_0x90f6b6['HWOQr'],'onPress':_0x4daf9d,'disabled':loading||_0x90f6b6[_0x2596(0x3e)](_0x4c0d8f[_0x2596(0x1e)],0x6),'loading':loading})),_react['default']['createElement'](_reactNative[_0x2596(0x32)],{'onPress':_0x2d157b,'disabled':loading,'style':styles['backButtonContainer']},_react['default'][_0x2596(0x20)](_reactNative[_0x2596(0x26)],{'style':[styles[_0x2596(0x2d)],loading&&styles[_0x2596(0x2e)]]},_0x90f6b6[_0x2596(0x2f)])),_0x4f10c5&&_react[_0x2596(0x1)][_0x2596(0x20)](_reactNative['View'],{'style':styles[_0x2596(0x30)]},_react['default'][_0x2596(0x20)](_reactNative[_0x2596(0x26)],{'style':styles[_0x2596(0x31)]},_0x90f6b6[_0x2596(0x3f)]),_react[_0x2596(0x1)]['createElement'](_reactNative['TouchableOpacity'],{'onPress':_0x4f10c5,'disabled':loading,'style':styles['resendButton']},_react[_0x2596(0x1)][_0x2596(0x20)](_reactNative['Text'],{'style':[styles[_0x2596(0x34)],loading&&styles[_0x2596(0x40)]]},_0x2596(0x17)))),_react[_0x2596(0x1)]['createElement'](_reactNative[_0x2596(0x24)],{'style':styles[_0x2596(0x36)]})));};exports[_0x2596(0x2)]=VerificationStep;const styles=_reactNative[_0x2596(0x41)][_0x2596(0x42)]({'container':{'flex':0x1},'content':{'flex':0x1,'paddingTop':0x18,'paddingHorizontal':0x18},'headingContainer':{'width':_0x2596(0x43),'marginBottom':0x28,'paddingHorizontal':0x0},'title':{'fontFamily':'IBM\x20Plex\x20Sans','fontWeight':'700','fontSize':0x18,'lineHeight':0x20,'color':_theme[_0x2596(0x44)][_0x2596(0x45)],'textAlign':_0x2596(0x46),'marginBottom':0x2},'subtitle':{'fontFamily':_0x2596(0x47),'fontWeight':_0x2596(0x48),'fontSize':0x10,'lineHeight':0x18,'color':_theme[_0x2596(0x44)]['grey600'],'textAlign':'left','marginBottom':0x8},'codeContainer':{'paddingHorizontal':0x10,'marginBottom':0x18},'spacer':{'flex':0x1,'minHeight':0x14},'continueContainer':{'paddingHorizontal':0x0,'marginBottom':0x18},'errorText':{'fontSize':0xe,'fontFamily':'Inter','fontWeight':_0x2596(0x48),'color':_0x2596(0x49),'marginTop':0xc,'textAlign':_0x2596(0x4a)},'resendContainer':{'flexDirection':_0x2596(0x4b),'justifyContent':_0x2596(0x4a),'alignItems':_0x2596(0x4a),'marginTop':0x10,'paddingHorizontal':0x0},'resendText':{'fontSize':0xe,'fontFamily':_0x2596(0x47),'fontWeight':_0x2596(0x48),'color':_theme[_0x2596(0x44)][_0x2596(0x4c)]},'resendButton':{},'resendLink':{'fontSize':0xe,'fontFamily':_0x2596(0x47),'fontWeight':_0x2596(0x4d),'color':_0x2596(0x4e),'textDecorationLine':_0x2596(0x4f)},'resendLinkDisabled':{'color':_theme[_0x2596(0x44)][_0x2596(0x50)],'textDecorationLine':_0x2596(0x51)},'backButtonContainer':{'alignItems':_0x2596(0x4a),'justifyContent':'center','paddingVertical':0x8,'marginTop':-0x8,'marginBottom':0x10},'backButtonText':{'fontSize':0xe,'fontFamily':_0x2596(0x47),'fontWeight':'400','color':_theme['COLORS'][_0x2596(0x52)]},'backButtonDisabled':{'color':_theme[_0x2596(0x44)]['grey300']}});var _default=exports[_0x2596(0x1)]=VerificationStep;
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.VerificationStep = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _theme = require("../theme");
|
|
10
|
+
var _CodeInput = _interopRequireDefault(require("./CodeInput"));
|
|
11
|
+
var _PrimaryButton = _interopRequireDefault(require("./PrimaryButton"));
|
|
12
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
13
|
+
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
|
+
const VerificationStep = ({
|
|
15
|
+
email,
|
|
16
|
+
onCodeSubmit,
|
|
17
|
+
onBack,
|
|
18
|
+
loading = false,
|
|
19
|
+
error = '',
|
|
20
|
+
onResendCode
|
|
21
|
+
}) => {
|
|
22
|
+
const [code, setCode] = (0, _react.useState)('');
|
|
23
|
+
const handleCodeChange = newCode => {
|
|
24
|
+
setCode(newCode);
|
|
25
|
+
};
|
|
26
|
+
const handleContinue = () => {
|
|
27
|
+
if (code.length === 6) {
|
|
28
|
+
onCodeSubmit(code);
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
return /*#__PURE__*/_react.default.createElement(_reactNative.KeyboardAvoidingView, {
|
|
32
|
+
behavior: _reactNative.Platform.OS === 'ios' ? 'padding' : 'height',
|
|
33
|
+
style: styles.container
|
|
34
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
35
|
+
style: styles.content
|
|
36
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
37
|
+
style: styles.headingContainer
|
|
38
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
39
|
+
style: styles.title
|
|
40
|
+
}, "Enter verification code"), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
41
|
+
style: styles.subtitle
|
|
42
|
+
}, "We've sent a 6-digit code to ", email)), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
43
|
+
style: styles.codeContainer
|
|
44
|
+
}, /*#__PURE__*/_react.default.createElement(_CodeInput.default, {
|
|
45
|
+
length: 6,
|
|
46
|
+
onCodeChange: handleCodeChange
|
|
47
|
+
}), error ? /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
48
|
+
style: styles.errorText
|
|
49
|
+
}, error) : null), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
50
|
+
style: styles.continueContainer
|
|
51
|
+
}, /*#__PURE__*/_react.default.createElement(_PrimaryButton.default, {
|
|
52
|
+
label: "Continue",
|
|
53
|
+
onPress: handleContinue,
|
|
54
|
+
disabled: loading || code.length !== 6,
|
|
55
|
+
loading: loading
|
|
56
|
+
})), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
57
|
+
onPress: onBack,
|
|
58
|
+
disabled: loading,
|
|
59
|
+
style: styles.backButtonContainer
|
|
60
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
61
|
+
style: [styles.backButtonText, loading && styles.backButtonDisabled]
|
|
62
|
+
}, "Back")), onResendCode && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
63
|
+
style: styles.resendContainer
|
|
64
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
65
|
+
style: styles.resendText
|
|
66
|
+
}, "Didn't receive the code? "), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
|
|
67
|
+
onPress: onResendCode,
|
|
68
|
+
disabled: loading,
|
|
69
|
+
style: styles.resendButton
|
|
70
|
+
}, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
|
|
71
|
+
style: [styles.resendLink, loading && styles.resendLinkDisabled]
|
|
72
|
+
}, "Resend Code"))), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
|
|
73
|
+
style: styles.spacer
|
|
74
|
+
})));
|
|
75
|
+
};
|
|
76
|
+
exports.VerificationStep = VerificationStep;
|
|
77
|
+
const styles = _reactNative.StyleSheet.create({
|
|
78
|
+
container: {
|
|
79
|
+
flex: 1
|
|
80
|
+
},
|
|
81
|
+
content: {
|
|
82
|
+
flex: 1,
|
|
83
|
+
paddingTop: 24,
|
|
84
|
+
paddingHorizontal: 24
|
|
85
|
+
},
|
|
86
|
+
headingContainer: {
|
|
87
|
+
width: '100%',
|
|
88
|
+
marginBottom: 40,
|
|
89
|
+
paddingHorizontal: 0
|
|
90
|
+
},
|
|
91
|
+
title: {
|
|
92
|
+
fontFamily: 'IBM Plex Sans',
|
|
93
|
+
fontWeight: '700',
|
|
94
|
+
fontSize: 24,
|
|
95
|
+
lineHeight: 32,
|
|
96
|
+
color: _theme.COLORS.grey800,
|
|
97
|
+
textAlign: 'left',
|
|
98
|
+
marginBottom: 2
|
|
99
|
+
},
|
|
100
|
+
subtitle: {
|
|
101
|
+
fontFamily: 'Inter',
|
|
102
|
+
fontWeight: '400',
|
|
103
|
+
fontSize: 16,
|
|
104
|
+
lineHeight: 24,
|
|
105
|
+
color: _theme.COLORS.grey600,
|
|
106
|
+
textAlign: 'left',
|
|
107
|
+
marginBottom: 8
|
|
108
|
+
},
|
|
109
|
+
codeContainer: {
|
|
110
|
+
paddingHorizontal: 16,
|
|
111
|
+
marginBottom: 24 // Reduced spacing to bring Continue button closer
|
|
112
|
+
},
|
|
113
|
+
spacer: {
|
|
114
|
+
flex: 1,
|
|
115
|
+
minHeight: 20
|
|
116
|
+
},
|
|
117
|
+
continueContainer: {
|
|
118
|
+
paddingHorizontal: 0,
|
|
119
|
+
marginBottom: 24 // Add spacing below Continue button
|
|
120
|
+
},
|
|
121
|
+
errorText: {
|
|
122
|
+
fontSize: 14,
|
|
123
|
+
fontFamily: 'Inter',
|
|
124
|
+
fontWeight: '400',
|
|
125
|
+
color: '#DC3545',
|
|
126
|
+
// Red color for errors
|
|
127
|
+
marginTop: 12,
|
|
128
|
+
textAlign: 'center'
|
|
129
|
+
},
|
|
130
|
+
resendContainer: {
|
|
131
|
+
flexDirection: 'row',
|
|
132
|
+
justifyContent: 'center',
|
|
133
|
+
alignItems: 'center',
|
|
134
|
+
marginTop: 16,
|
|
135
|
+
paddingHorizontal: 0
|
|
136
|
+
},
|
|
137
|
+
resendText: {
|
|
138
|
+
fontSize: 14,
|
|
139
|
+
fontFamily: 'Inter',
|
|
140
|
+
fontWeight: '400',
|
|
141
|
+
color: _theme.COLORS.grey600
|
|
142
|
+
},
|
|
143
|
+
resendButton: {
|
|
144
|
+
// No additional padding - let the text handle touch target
|
|
145
|
+
},
|
|
146
|
+
resendLink: {
|
|
147
|
+
fontSize: 14,
|
|
148
|
+
fontFamily: 'Inter',
|
|
149
|
+
fontWeight: '500',
|
|
150
|
+
color: '#D4A536',
|
|
151
|
+
// Brand color
|
|
152
|
+
textDecorationLine: 'underline'
|
|
153
|
+
},
|
|
154
|
+
resendLinkDisabled: {
|
|
155
|
+
color: _theme.COLORS.grey400,
|
|
156
|
+
textDecorationLine: 'none'
|
|
157
|
+
},
|
|
158
|
+
backButtonContainer: {
|
|
159
|
+
alignItems: 'center',
|
|
160
|
+
justifyContent: 'center',
|
|
161
|
+
paddingVertical: 8,
|
|
162
|
+
marginTop: -8,
|
|
163
|
+
marginBottom: 16
|
|
164
|
+
},
|
|
165
|
+
backButtonText: {
|
|
166
|
+
fontSize: 14,
|
|
167
|
+
fontFamily: 'Inter',
|
|
168
|
+
fontWeight: '400',
|
|
169
|
+
color: _theme.COLORS.grey500
|
|
170
|
+
},
|
|
171
|
+
backButtonDisabled: {
|
|
172
|
+
color: _theme.COLORS.grey300
|
|
173
|
+
}
|
|
174
|
+
});
|
|
175
|
+
var _default = exports.default = VerificationStep;
|
|
176
|
+
//# sourceMappingURL=VerificationStep.js.map
|