@onairos/react-native 3.7.2 → 3.7.4

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.
Files changed (237) hide show
  1. package/lib/commonjs/api/index.js +219 -9
  2. package/lib/commonjs/components/BodyText.js +27 -9
  3. package/lib/commonjs/components/BrandMark.js +111 -10
  4. package/lib/commonjs/components/CodeInput.js +120 -9
  5. package/lib/commonjs/components/EmailInput.js +30 -8
  6. package/lib/commonjs/components/GoogleButton.js +56 -9
  7. package/lib/commonjs/components/HeadingGroup.js +43 -9
  8. package/lib/commonjs/components/LLMDataInputModal.js +664 -14
  9. package/lib/commonjs/components/ModalHeader.js +99 -9
  10. package/lib/commonjs/components/ModalSheet.js +47 -9
  11. package/lib/commonjs/components/Onairos.js +380 -14
  12. package/lib/commonjs/components/OnairosButton.js +313 -13
  13. package/lib/commonjs/components/OnairosSignInButton.js +130 -12
  14. package/lib/commonjs/components/Overlay.js +465 -13
  15. package/lib/commonjs/components/PersonaImage.js +137 -10
  16. package/lib/commonjs/components/PersonaLoadingScreen.js +318 -12
  17. package/lib/commonjs/components/PersonalizationConsentScreen.js +467 -13
  18. package/lib/commonjs/components/PinCreationScreen.js +403 -12
  19. package/lib/commonjs/components/PinInput.js +464 -9
  20. package/lib/commonjs/components/PlatformConnectorsStep.js +1311 -23
  21. package/lib/commonjs/components/PlatformList.js +137 -10
  22. package/lib/commonjs/components/PlatformToggle.js +180 -9
  23. package/lib/commonjs/components/PrimaryButton.js +180 -10
  24. package/lib/commonjs/components/SignInMatchAnimation.js +197 -9
  25. package/lib/commonjs/components/SignInStep.js +345 -12
  26. package/lib/commonjs/components/UniversalOnboarding.js +2780 -30
  27. package/lib/commonjs/components/VerificationStep.js +176 -11
  28. package/lib/commonjs/components/WelcomeScreen.js +461 -22
  29. package/lib/commonjs/components/icons/Basicproficon.js +37 -8
  30. package/lib/commonjs/components/icons/Basicprofile.js +21 -8
  31. package/lib/commonjs/components/icons/Checkbox.js +21 -8
  32. package/lib/commonjs/components/icons/Checkmark.js +27 -8
  33. package/lib/commonjs/components/icons/Contentanalysis.js +21 -8
  34. package/lib/commonjs/components/icons/Contenticon.js +39 -8
  35. package/lib/commonjs/components/icons/EnochE.js +41 -8
  36. package/lib/commonjs/components/icons/Personalityicon.js +30 -8
  37. package/lib/commonjs/components/icons/Personalityprofile.js +21 -8
  38. package/lib/commonjs/components/icons/Personalitytraits.js +21 -8
  39. package/lib/commonjs/components/icons/Userpreferences.js +21 -8
  40. package/lib/commonjs/components/icons/index.js +84 -17
  41. package/lib/commonjs/components/onboarding/OAuthWebView.js +1754 -18
  42. package/lib/commonjs/components/onboarding/OnboardingHeader.js +74 -10
  43. package/lib/commonjs/components/onboarding/PinInput.js +283 -10
  44. package/lib/commonjs/components/onboarding/PlatformConnector.js +249 -11
  45. package/lib/commonjs/config/PLATFORM_APIS.md +849 -0
  46. package/lib/commonjs/config/api.js +56 -7
  47. package/lib/commonjs/constants/index.js +120 -7
  48. package/lib/commonjs/context/AuthContext.js +345 -10
  49. package/lib/commonjs/hooks/useConnectedAccounts.js +111 -9
  50. package/lib/commonjs/hooks/useConnections.js +102 -8
  51. package/lib/commonjs/hooks/useCredentials.js +178 -10
  52. package/lib/commonjs/hooks/useUserConnections.js +148 -10
  53. package/lib/commonjs/index.js +439 -34
  54. package/lib/commonjs/services/apiClient.js +298 -8
  55. package/lib/commonjs/services/biometricPinService.js +180 -8
  56. package/lib/commonjs/services/chatGPTConversationExtractor.js +155 -8
  57. package/lib/commonjs/services/chatGPTConversationService.js +275 -9
  58. package/lib/commonjs/services/claudeConversationExtractor.js +103 -8
  59. package/lib/commonjs/services/claudeConversationService.js +158 -9
  60. package/lib/commonjs/services/connectedAccountsService.js +310 -10
  61. package/lib/commonjs/services/googleAuthService.js +252 -11
  62. package/lib/commonjs/services/hingeDataExtractor.js +105 -8
  63. package/lib/commonjs/services/hingeDataService.js +150 -9
  64. package/lib/commonjs/services/imageCompressionService.js +260 -7
  65. package/lib/commonjs/services/instagramDataExtractor.js +126 -8
  66. package/lib/commonjs/services/instagramDataService.js +163 -9
  67. package/lib/commonjs/services/jwtStorageService.js +276 -7
  68. package/lib/commonjs/services/linkedinDOMExtractor.js +245 -7
  69. package/lib/commonjs/services/linkedinProfileService.js +222 -9
  70. package/lib/commonjs/services/linkedinScrapingService.js +230 -8
  71. package/lib/commonjs/services/llmDataStorage.js +294 -8
  72. package/lib/commonjs/services/mobileTrainingService.js +186 -8
  73. package/lib/commonjs/services/netflixDataExtractor.js +120 -8
  74. package/lib/commonjs/services/netflixDataService.js +198 -9
  75. package/lib/commonjs/services/pinEncryptionService.js +84 -8
  76. package/lib/commonjs/services/pinStorageUtils.js +105 -7
  77. package/lib/commonjs/services/platformAuthService.js +1484 -12
  78. package/lib/commonjs/services/sephoraDataExtractor.js +140 -8
  79. package/lib/commonjs/services/sephoraDataService.js +200 -9
  80. package/lib/commonjs/services/spotifyDataExtractor.js +148 -8
  81. package/lib/commonjs/services/spotifyDataService.js +241 -9
  82. package/lib/commonjs/services/storageService.js +404 -8
  83. package/lib/commonjs/services/telegramDataExtractor.js +115 -8
  84. package/lib/commonjs/services/telegramDataService.js +499 -9
  85. package/lib/commonjs/services/trainingApiHelpers.js +73 -7
  86. package/lib/commonjs/services/userConnectionsService.js +340 -10
  87. package/lib/commonjs/services/youtubeMigrationService.js +416 -10
  88. package/lib/commonjs/theme/index.js +250 -7
  89. package/lib/commonjs/types/ambient.d.js +2 -1
  90. package/lib/commonjs/types/declarations.d.js +2 -1
  91. package/lib/commonjs/types/index.js +6 -1
  92. package/lib/commonjs/types/node-fix.d.js +2 -1
  93. package/lib/commonjs/types/node-override.d.js +2 -1
  94. package/lib/commonjs/types/opacity.d.js +2 -1
  95. package/lib/commonjs/types.js +14 -1
  96. package/lib/commonjs/utils/Portal.js +98 -8
  97. package/lib/commonjs/utils/api.js +130 -9
  98. package/lib/commonjs/utils/assetRegistry.js +210 -35
  99. package/lib/commonjs/utils/auth.js +112 -9
  100. package/lib/commonjs/utils/connectorTests.js +613 -29
  101. package/lib/commonjs/utils/crypto.js +62 -8
  102. package/lib/commonjs/utils/debugHelper.js +64 -1
  103. package/lib/commonjs/utils/encryption.js +76 -7
  104. package/lib/commonjs/utils/eventUtils.js +288 -1
  105. package/lib/commonjs/utils/haptics.js +66 -9
  106. package/lib/commonjs/utils/imagePreloader.js +6 -1
  107. package/lib/commonjs/utils/networkDiagnostics.js +226 -8
  108. package/lib/commonjs/utils/onairosApi.js +350 -9
  109. package/lib/commonjs/utils/programmaticFlow.js +117 -9
  110. package/lib/commonjs/utils/retryHelper.js +220 -1
  111. package/lib/commonjs/utils/secureStorage.js +349 -10
  112. package/lib/commonjs/utils/webviewScripts/chatgpt.js +551 -1
  113. package/lib/commonjs/utils/webviewScripts/claude.js +376 -1
  114. package/lib/commonjs/utils/webviewScripts/hinge.js +411 -1
  115. package/lib/commonjs/utils/webviewScripts/index.js +698 -15
  116. package/lib/commonjs/utils/webviewScripts/instagram.js +454 -1
  117. package/lib/commonjs/utils/webviewScripts/linkedin.js +880 -1
  118. package/lib/commonjs/utils/webviewScripts/netflix.js +382 -1
  119. package/lib/commonjs/utils/webviewScripts/sephora.js +516 -1
  120. package/lib/commonjs/utils/webviewScripts/spotify.js +419 -1
  121. package/lib/commonjs/utils/webviewScripts/telegram.js +678 -1
  122. package/lib/module/api/index.js +211 -1
  123. package/lib/module/components/BodyText.js +20 -1
  124. package/lib/module/components/BrandMark.js +104 -1
  125. package/lib/module/components/CodeInput.js +113 -1
  126. package/lib/module/components/EmailInput.js +23 -1
  127. package/lib/module/components/GoogleButton.js +49 -1
  128. package/lib/module/components/HeadingGroup.js +36 -1
  129. package/lib/module/components/LLMDataInputModal.js +656 -7
  130. package/lib/module/components/ModalHeader.js +92 -1
  131. package/lib/module/components/ModalSheet.js +39 -1
  132. package/lib/module/components/Onairos.js +373 -1
  133. package/lib/module/components/OnairosButton.js +305 -1
  134. package/lib/module/components/OnairosSignInButton.js +121 -1
  135. package/lib/module/components/Overlay.js +456 -1
  136. package/lib/module/components/PersonaImage.js +129 -1
  137. package/lib/module/components/PersonaLoadingScreen.js +310 -1
  138. package/lib/module/components/PersonalizationConsentScreen.js +460 -1
  139. package/lib/module/components/PinCreationScreen.js +396 -1
  140. package/lib/module/components/PinInput.js +456 -1
  141. package/lib/module/components/PlatformConnectorsStep.js +1302 -6
  142. package/lib/module/components/PlatformList.js +129 -1
  143. package/lib/module/components/PlatformToggle.js +173 -1
  144. package/lib/module/components/PrimaryButton.js +172 -1
  145. package/lib/module/components/SignInMatchAnimation.js +189 -1
  146. package/lib/module/components/SignInStep.js +338 -1
  147. package/lib/module/components/UniversalOnboarding.js +2770 -1
  148. package/lib/module/components/VerificationStep.js +168 -1
  149. package/lib/module/components/WelcomeScreen.js +453 -1
  150. package/lib/module/components/icons/Basicproficon.js +30 -1
  151. package/lib/module/components/icons/Basicprofile.js +14 -1
  152. package/lib/module/components/icons/Checkbox.js +14 -1
  153. package/lib/module/components/icons/Checkmark.js +20 -1
  154. package/lib/module/components/icons/Contentanalysis.js +14 -1
  155. package/lib/module/components/icons/Contenticon.js +32 -1
  156. package/lib/module/components/icons/EnochE.js +34 -1
  157. package/lib/module/components/icons/Personalityicon.js +23 -1
  158. package/lib/module/components/icons/Personalityprofile.js +14 -1
  159. package/lib/module/components/icons/Personalitytraits.js +14 -1
  160. package/lib/module/components/icons/Userpreferences.js +14 -1
  161. package/lib/module/components/icons/index.js +13 -1
  162. package/lib/module/components/onboarding/OAuthWebView.js +1746 -1
  163. package/lib/module/components/onboarding/OnboardingHeader.js +66 -1
  164. package/lib/module/components/onboarding/PinInput.js +274 -1
  165. package/lib/module/components/onboarding/PlatformConnector.js +240 -1
  166. package/lib/module/config/PLATFORM_APIS.md +849 -0
  167. package/lib/module/config/api.js +47 -1
  168. package/lib/module/constants/index.js +114 -1
  169. package/lib/module/context/AuthContext.js +335 -1
  170. package/lib/module/hooks/useConnectedAccounts.js +106 -1
  171. package/lib/module/hooks/useConnections.js +95 -1
  172. package/lib/module/hooks/useCredentials.js +171 -6
  173. package/lib/module/hooks/useUserConnections.js +140 -1
  174. package/lib/module/index.js +172 -1
  175. package/lib/module/services/apiClient.js +295 -1
  176. package/lib/module/services/biometricPinService.js +169 -1
  177. package/lib/module/services/chatGPTConversationExtractor.js +149 -1
  178. package/lib/module/services/chatGPTConversationService.js +268 -1
  179. package/lib/module/services/claudeConversationExtractor.js +97 -1
  180. package/lib/module/services/claudeConversationService.js +151 -1
  181. package/lib/module/services/connectedAccountsService.js +293 -1
  182. package/lib/module/services/googleAuthService.js +241 -1
  183. package/lib/module/services/hingeDataExtractor.js +99 -1
  184. package/lib/module/services/hingeDataService.js +143 -1
  185. package/lib/module/services/imageCompressionService.js +250 -1
  186. package/lib/module/services/instagramDataExtractor.js +120 -1
  187. package/lib/module/services/instagramDataService.js +156 -1
  188. package/lib/module/services/jwtStorageService.js +257 -1
  189. package/lib/module/services/linkedinDOMExtractor.js +234 -1
  190. package/lib/module/services/linkedinProfileService.js +210 -1
  191. package/lib/module/services/linkedinScrapingService.js +219 -1
  192. package/lib/module/services/llmDataStorage.js +277 -1
  193. package/lib/module/services/mobileTrainingService.js +173 -1
  194. package/lib/module/services/netflixDataExtractor.js +114 -1
  195. package/lib/module/services/netflixDataService.js +191 -1
  196. package/lib/module/services/pinEncryptionService.js +74 -6
  197. package/lib/module/services/pinStorageUtils.js +93 -1
  198. package/lib/module/services/platformAuthService.js +1461 -1
  199. package/lib/module/services/sephoraDataExtractor.js +134 -1
  200. package/lib/module/services/sephoraDataService.js +193 -1
  201. package/lib/module/services/spotifyDataExtractor.js +142 -1
  202. package/lib/module/services/spotifyDataService.js +234 -1
  203. package/lib/module/services/storageService.js +383 -1
  204. package/lib/module/services/telegramDataExtractor.js +109 -1
  205. package/lib/module/services/telegramDataService.js +493 -1
  206. package/lib/module/services/trainingApiHelpers.js +67 -1
  207. package/lib/module/services/userConnectionsService.js +329 -1
  208. package/lib/module/services/youtubeMigrationService.js +405 -1
  209. package/lib/module/theme/index.js +245 -1
  210. package/lib/module/types.js +10 -1
  211. package/lib/module/utils/Portal.js +90 -1
  212. package/lib/module/utils/api.js +118 -1
  213. package/lib/module/utils/assetRegistry.js +200 -34
  214. package/lib/module/utils/auth.js +100 -1
  215. package/lib/module/utils/connectorTests.js +600 -27
  216. package/lib/module/utils/crypto.js +54 -1
  217. package/lib/module/utils/debugHelper.js +54 -1
  218. package/lib/module/utils/encryption.js +67 -1
  219. package/lib/module/utils/eventUtils.js +270 -1
  220. package/lib/module/utils/haptics.js +59 -8
  221. package/lib/module/utils/imagePreloader.js +3 -1
  222. package/lib/module/utils/networkDiagnostics.js +217 -1
  223. package/lib/module/utils/onairosApi.js +333 -1
  224. package/lib/module/utils/programmaticFlow.js +111 -1
  225. package/lib/module/utils/retryHelper.js +211 -1
  226. package/lib/module/utils/secureStorage.js +330 -6
  227. package/lib/module/utils/webviewScripts/chatgpt.js +545 -1
  228. package/lib/module/utils/webviewScripts/claude.js +370 -1
  229. package/lib/module/utils/webviewScripts/hinge.js +405 -1
  230. package/lib/module/utils/webviewScripts/index.js +434 -1
  231. package/lib/module/utils/webviewScripts/instagram.js +448 -1
  232. package/lib/module/utils/webviewScripts/linkedin.js +874 -1
  233. package/lib/module/utils/webviewScripts/netflix.js +376 -1
  234. package/lib/module/utils/webviewScripts/sephora.js +510 -1
  235. package/lib/module/utils/webviewScripts/spotify.js +413 -1
  236. package/lib/module/utils/webviewScripts/telegram.js +672 -1
  237. package/package.json +2 -2
@@ -1,10 +1,74 @@
1
- 'use strict';
2
- // Onairos SDK - Asset Registry (auto-generated)
3
- var __ONAIROS_REQ_REGISTRY__ = [
4
- require("react"),
5
- require("react-native"),
6
- require("react-native-vector-icons/MaterialIcons"),
7
- require("../../constants")
8
- ];
9
- function __ONAIROS_REQ_FUNC__(i) { return __ONAIROS_REQ_REGISTRY__[i]; }
10
- function _0x18df(_0x558025,_0x18df94){_0x558025=_0x558025-0x0;var _0x25dd2e=_0x5580();var _0x4ca77d=_0x25dd2e[_0x558025];return _0x4ca77d;}function _0x5580(){var _0x224a30=['OnboardingHeader','__esModule','#000','close','createElement','View','backButton','default','arrow-back','titleContainer','Text','title','TouchableOpacity','closeButton','tDNxJ','StyleSheet','create','center','COLORS','headerBg','600','#666'];_0x5580=function(){return _0x224a30;};return _0x5580();}Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[_0x18df(0x0)]=void 0x0;var _react=_interopRequireDefault(__ONAIROS_REQ_FUNC__(0x0)),_reactNative=__ONAIROS_REQ_FUNC__(0x1),_MaterialIcons=_interopRequireDefault(__ONAIROS_REQ_FUNC__(0x2)),_constants=__ONAIROS_REQ_FUNC__(0x3);function _interopRequireDefault(_0x5482be){return _0x5482be&&_0x5482be[_0x18df(0x1)]?_0x5482be:{'default':_0x5482be};}const OnboardingHeader=({title:_0xe525b0,subtitle:_0x5574cf,showBackButton:showBackButton=![],onBack:_0x1447e1,onClose:_0x2696cb})=>{var _0x28c82d={'wqXya':_0x18df(0x2),'tDNxJ':_0x18df(0x3)};return _react['default'][_0x18df(0x4)](_reactNative[_0x18df(0x5)],{'style':styles['header']},showBackButton&&_react['default'][_0x18df(0x4)](_reactNative['TouchableOpacity'],{'style':styles[_0x18df(0x6)],'onPress':_0x1447e1},_react[_0x18df(0x7)]['createElement'](_MaterialIcons[_0x18df(0x7)],{'name':_0x18df(0x8),'size':0x18,'color':_0x28c82d['wqXya']})),_react[_0x18df(0x7)]['createElement'](_reactNative['View'],{'style':styles[_0x18df(0x9)]},_react[_0x18df(0x7)][_0x18df(0x4)](_reactNative[_0x18df(0xa)],{'style':styles[_0x18df(0xb)]},_0xe525b0),_0x5574cf&&_react[_0x18df(0x7)]['createElement'](_reactNative[_0x18df(0xa)],{'style':styles['subtitle']},_0x5574cf)),_react[_0x18df(0x7)]['createElement'](_reactNative[_0x18df(0xc)],{'style':styles[_0x18df(0xd)],'onPress':_0x2696cb},_react['default'][_0x18df(0x4)](_MaterialIcons[_0x18df(0x7)],{'name':_0x28c82d[_0x18df(0xe)],'size':0x18,'color':_0x18df(0x2)})));};exports[_0x18df(0x0)]=OnboardingHeader;const styles=_reactNative[_0x18df(0xf)][_0x18df(0x10)]({'header':{'flexDirection':'row','alignItems':_0x18df(0x11),'padding':0x10,'backgroundColor':_constants[_0x18df(0x12)][_0x18df(0x13)],'borderTopLeftRadius':0x10,'borderTopRightRadius':0x10},'backButton':{'padding':0x8,'marginRight':0x8},'titleContainer':{'flex':0x1},'title':{'fontSize':0x12,'fontWeight':_0x18df(0x14),'color':_0x18df(0x2)},'subtitle':{'fontSize':0xe,'color':_0x18df(0x15),'marginTop':0x4},'closeButton':{'padding':0x8}});
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.OnboardingHeader = void 0;
7
+ var _react = _interopRequireDefault(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _MaterialIcons = _interopRequireDefault(require("react-native-vector-icons/MaterialIcons"));
10
+ var _constants = require("../../constants");
11
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
+ const OnboardingHeader = ({
13
+ title,
14
+ subtitle,
15
+ showBackButton = false,
16
+ onBack,
17
+ onClose
18
+ }) => {
19
+ return /*#__PURE__*/_react.default.createElement(_reactNative.View, {
20
+ style: styles.header
21
+ }, showBackButton && /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
22
+ style: styles.backButton,
23
+ onPress: onBack
24
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
25
+ name: "arrow-back",
26
+ size: 24,
27
+ color: "#000"
28
+ })), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
29
+ style: styles.titleContainer
30
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
31
+ style: styles.title
32
+ }, title), subtitle && /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
33
+ style: styles.subtitle
34
+ }, subtitle)), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
35
+ style: styles.closeButton,
36
+ onPress: onClose
37
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
38
+ name: "close",
39
+ size: 24,
40
+ color: "#000"
41
+ })));
42
+ };
43
+ exports.OnboardingHeader = OnboardingHeader;
44
+ const styles = _reactNative.StyleSheet.create({
45
+ header: {
46
+ flexDirection: 'row',
47
+ alignItems: 'center',
48
+ padding: 16,
49
+ backgroundColor: _constants.COLORS.headerBg,
50
+ borderTopLeftRadius: 16,
51
+ borderTopRightRadius: 16
52
+ },
53
+ backButton: {
54
+ padding: 8,
55
+ marginRight: 8
56
+ },
57
+ titleContainer: {
58
+ flex: 1
59
+ },
60
+ title: {
61
+ fontSize: 18,
62
+ fontWeight: '600',
63
+ color: '#000'
64
+ },
65
+ subtitle: {
66
+ fontSize: 14,
67
+ color: '#666',
68
+ marginTop: 4
69
+ },
70
+ closeButton: {
71
+ padding: 8
72
+ }
73
+ });
74
+ //# sourceMappingURL=OnboardingHeader.js.map
@@ -1,10 +1,283 @@
1
- 'use strict';
2
- // Onairos SDK - Asset Registry (auto-generated)
3
- var __ONAIROS_REQ_REGISTRY__ = [
4
- require("react"),
5
- require("react-native"),
6
- require("react-native-vector-icons/MaterialIcons"),
7
- require("../../constants")
8
- ];
9
- function __ONAIROS_REQ_FUNC__(i) { return __ONAIROS_REQ_REGISTRY__[i]; }
10
- Object['defineProperty'](exports,'__esModule',{'value':!![]}),exports[_0xed0c(0x0)]=void 0x0;var _react=_interopRequireWildcard(__ONAIROS_REQ_FUNC__(0x0)),_reactNative=__ONAIROS_REQ_FUNC__(0x1),_MaterialIcons=_interopRequireDefault(__ONAIROS_REQ_FUNC__(0x2)),_constants=__ONAIROS_REQ_FUNC__(0x3);function _interopRequireDefault(_0xca8ade){return _0xca8ade&&_0xca8ade[_0xed0c(0x1)]?_0xca8ade:{'default':_0xca8ade};}function _interopRequireWildcard(_0x17ca76,_0x164c99){const _0x1c48cd={'QDuCP':function(_0x51f770,_0xda5ef6){return _0x51f770(_0xda5ef6);},'krBid':function(_0x4047ef,_0x45437d){return _0x4047ef!==_0x45437d;},'NNZRz':_0xed0c(0x2),'CFFTP':function(_0x461a30,_0x27617a){return _0x461a30===_0x27617a;},'SiWZT':function(_0x1e7c9e,_0x232140){return _0x1e7c9e!=_0x232140;},'JMvkK':_0xed0c(0x3),'UUdIb':'function','oaVks':'NrYUh','WSswp':_0xed0c(0x4),'EBIzd':function(_0x4d776b,_0xff7cd0){return _0x4d776b!==_0xff7cd0;},'HFnfn':_0xed0c(0x5),'eCVMJ':function(_0x2827cf,_0x2b7499,_0x2ac803,_0x3f65e2){return _0x2827cf(_0x2b7499,_0x2ac803,_0x3f65e2);},'AuSxm':function(_0x10db72,_0x5b0d70){return _0x10db72==_0x5b0d70;}};if(_0x1c48cd['AuSxm'](_0xed0c(0x6),typeof WeakMap))var _0x2eec39=new WeakMap(),_0x11646f=new WeakMap();return(_interopRequireWildcard=function(_0x1cb917,_0x103267){const _0x283de3={'lRNRb':function(_0x52e6f3,_0x32b341){return _0x52e6f3(_0x32b341);}};if(_0x1c48cd[_0xed0c(0x7)](_0x1c48cd[_0xed0c(0x8)],_0xed0c(0x2)))_0x1c48cd['QDuCP'](_0x18db89,'confirm');else{if(!_0x103267&&_0x1cb917&&_0x1cb917[_0xed0c(0x1)])return _0x1cb917;var _0x559eac,_0x4f21f9,_0xeb370e={'__proto__':null,'default':_0x1cb917};if(_0x1c48cd[_0xed0c(0x9)](null,_0x1cb917)||_0x1c48cd[_0xed0c(0xa)](_0x1c48cd[_0xed0c(0xb)],typeof _0x1cb917)&&_0x1c48cd[_0xed0c(0xa)](_0x1c48cd[_0xed0c(0xc)],typeof _0x1cb917))return _0xeb370e;if(_0x559eac=_0x103267?_0x11646f:_0x2eec39){if(_0x1c48cd['CFFTP'](_0x1c48cd[_0xed0c(0xd)],_0x1c48cd[_0xed0c(0xe)]))_0x2e05f7[_0xed0c(0xf)][_0xed0c(0x10)](),_0x283de3[_0xed0c(0x11)](_0x40349e,_0x38231e);else{if(_0x559eac['has'](_0x1cb917))return _0x559eac[_0xed0c(0x12)](_0x1cb917);_0x559eac['set'](_0x1cb917,_0xeb370e);}}for(const _0x5fbd68 in _0x1cb917)_0x1c48cd[_0xed0c(0x13)](_0x1c48cd['HFnfn'],_0x5fbd68)&&{}[_0xed0c(0x14)][_0xed0c(0x15)](_0x1cb917,_0x5fbd68)&&((_0x4f21f9=(_0x559eac=Object[_0xed0c(0x16)])&&Object[_0xed0c(0x17)](_0x1cb917,_0x5fbd68))&&(_0x4f21f9[_0xed0c(0x12)]||_0x4f21f9[_0xed0c(0x18)])?_0x1c48cd['eCVMJ'](_0x559eac,_0xeb370e,_0x5fbd68,_0x4f21f9):_0xeb370e[_0x5fbd68]=_0x1cb917[_0x5fbd68]);return _0xeb370e;}})(_0x17ca76,_0x164c99);}function _0x53e2(){const _0x1280c4=['PinInput','__esModule','yEvuE','object','hSoFX','default','function','krBid','NNZRz','CFFTP','SiWZT','JMvkK','UUdIb','oaVks','WSswp','Keyboard','dismiss','lRNRb','get','EBIzd','hasOwnProperty','call','defineProperty','getOwnPropertyDescriptor','set','create','laMID','PINs\x20do\x20not\x20match','PecBe','HNxio','PIN\x20must\x20include\x20at\x20least\x20one\x20number','confirm','eAsmD','UuWgo','GrPoQ','CuGhT','ios','padding','Create\x20a\x20PIN','Confirm\x20your\x20PIN','This\x20PIN\x20will\x20protect\x20your\x20Onairos\x20account','Enter\x20PIN','#999','visibility-off','check-circle','#4caf50','At\x20least\x20','\x20characters','Include\x20at\x20least\x20one\x20number','Next','arrow-forward','useState','useEffect','MgueM','CBEkN','LmnMQ','push','PIN\x20must\x20be\x20at\x20least\x20','useCallback','QqxAd','rhUfe','VLxoP','length','LEjQK','DdruO','test','PIN\x20must\x20include\x20at\x20least\x20one\x20special\x20character','Daeny','JSsJa','saZJA','FXdIw','dgYfr','BGdMZ','KhIbf','rNXaa','UOdoF','bZsXo','ontgz','WfCIQ','jYCpO','OPZio','mbsHY','CBtsz','PIYPH','dljgz','DlCTk','KeyboardAvoidingView','opCJV','Platform','View','createElement','Text','title','xdzqQ','subtitle','lwnBd','Please\x20re-enter\x20your\x20PIN\x20to\x20confirm','TextInput','input','IuyGv','none','gqVOm','Confirm\x20PIN','vKgMH','visibilityToggle','seEij','visibility','errorContainer','error-outline','#f44336','errorText','requirementsContainer','requirementsTitle','BPJST','requirement','ZVwhV','tJUcI','sbzjN','requirementText','tlmBS','lUuzf','CXmix','UDdeI','GAPCB','qcCZk','TouchableOpacity','button','backButton','MiudE','COLORS','primary','buttonText','backButtonText','Back','nextButton','llQbm','OnUpP','PRFgE','disabledButton','lqfKN','xzskp','nextButtonText','aGTXb','Submit','PvaLu','#fff','bold','#000','#666','row','#ddd','center','#f5f5f5','600'];_0x53e2=function(){return _0x1280c4;};return _0x53e2();}const PinInput=({onSubmit:_0x2135b3,minLength:minLength=0x6,requireSpecialChar:requireSpecialChar=!![],requireNumber:requireNumber=!![]})=>{const _0x28cad={'MgueM':function(_0x2feb71,_0x27b82b){return _0x2feb71===_0x27b82b;},'saZJA':_0xed0c(0x19),'CBEkN':_0xed0c(0x1a),'LmnMQ':function(_0x1ef532,_0x44b62a){return _0x1ef532(_0x44b62a);},'qcCZk':function(_0x28b596,_0x25852c){return _0x28b596===_0x25852c;},'DdruO':_0xed0c(0x1b),'QqxAd':function(_0x525fe7,_0xb5e42d){return _0x525fe7===_0xb5e42d;},'rhUfe':'oGHwD','VLxoP':_0xed0c(0x1c),'KjUlQ':function(_0x290a65,_0x2f9822){return _0x290a65<_0x2f9822;},'LEjQK':_0xed0c(0x1d),'gMDSI':_0xed0c(0x1e),'Daeny':function(_0x4fb759,_0x1871db){return _0x4fb759===_0x1871db;},'JSsJa':_0xed0c(0x1f),'FXdIw':function(_0x47debe,_0x2cf89d){return _0x47debe(_0x2cf89d);},'dgYfr':function(_0x31d5a6,_0x33bdde){return _0x31d5a6===_0x33bdde;},'BGdMZ':_0xed0c(0x20),'KhIbf':function(_0xe43acb,_0x104ff5){return _0xe43acb(_0x104ff5);},'ontgz':function(_0xcfc11a,_0x199ac5){return _0xcfc11a(_0x199ac5);},'WfCIQ':function(_0x27ed45,_0x16d5c4){return _0x27ed45(_0x16d5c4);},'jYCpO':function(_0x1fcbc5,_0x34311c){return _0x1fcbc5===_0x34311c;},'OPZio':_0xed0c(0x21),'mbsHY':function(_0x2668fd,_0x28b25c){return _0x2668fd(_0x28b25c);},'Jqnlp':function(_0x2633c4,_0x5e1e39){return _0x2633c4(_0x5e1e39);},'PIYPH':function(_0x6d811c,_0x249653){return _0x6d811c!==_0x249653;},'dljgz':_0xed0c(0x22),'DlCTk':_0xed0c(0x23),'opCJV':function(_0x3cddb0,_0x1fad85){return _0x3cddb0===_0x1fad85;},'FLISI':_0xed0c(0x24),'Idzah':_0xed0c(0x25),'weSAh':'height','CGcBX':_0xed0c(0x26),'xdzqQ':_0xed0c(0x27),'lwnBd':_0xed0c(0x28),'cDjyk':function(_0x4b43e3,_0x24388a){return _0x4b43e3===_0x24388a;},'IuyGv':_0xed0c(0x5),'gqVOm':_0xed0c(0x29),'vKgMH':_0xed0c(0x2a),'HVeQS':'done','seEij':_0xed0c(0x2b),'BPJST':'PIN\x20Requirements:','xFanB':function(_0x295294,_0x370c9e){return _0x295294>=_0x370c9e;},'ZVwhV':_0xed0c(0x2c),'tJUcI':'radio-button-unchecked','sbzjN':function(_0x443816,_0x526bfc){return _0x443816>=_0x526bfc;},'tlmBS':function(_0x307787,_0x3e754f){return _0x307787>=_0x3e754f;},'lUuzf':_0xed0c(0x2d),'PtJSj':_0xed0c(0x2e),'CXmix':_0xed0c(0x2f),'UDdeI':_0xed0c(0x30),'GAPCB':'Include\x20at\x20least\x20one\x20special\x20character','MiudE':'arrow-back','llQbm':function(_0x1e9194,_0x5e53b4){return _0x1e9194===_0x5e53b4;},'OnUpP':function(_0x14948d,_0x1faab8){return _0x14948d>_0x1faab8;},'PRFgE':function(_0x1110d0,_0x47dd4c){return _0x1110d0===_0x47dd4c;},'lqfKN':function(_0x495447,_0x3a8daa){return _0x495447===_0x3a8daa;},'xzskp':function(_0x5e0feb,_0x41ddcc){return _0x5e0feb===_0x41ddcc;},'wEYms':function(_0x6b06d9,_0x120206){return _0x6b06d9===_0x120206;},'aGTXb':_0xed0c(0x31),'PvaLu':_0xed0c(0x32)},[_0xdb744e,_0x50b038]=(0x0,_react['useState'])(''),[_0x5e1ffd,_0x1386ab]=(0x0,_react[_0xed0c(0x33)])(''),[_0x48a3b2,_0x212549]=(0x0,_react['useState'])(![]),[_0x52f5c3,_0x168b3f]=(0x0,_react[_0xed0c(0x33)])([]),[_0x51a438,_0x38e38d]=(0x0,_react[_0xed0c(0x33)])(_0x28cad['saZJA']);(0x0,_react[_0xed0c(0x34)])(()=>{_0x28cad[_0xed0c(0x35)](_0x51a438,_0x28cad['saZJA'])&&(_0x28cad[_0xed0c(0x35)](_0x28cad['CBEkN'],_0x28cad[_0xed0c(0x36)])?_0x28cad[_0xed0c(0x37)](_0x19f3ef,_0xdb744e):_0x3efc6[_0xed0c(0x38)](_0xed0c(0x39)+_0xd4017f+'\x20characters'));},[_0xdb744e,_0x51a438]);const _0x19f3ef=(0x0,_react[_0xed0c(0x3a)])(_0x500168=>{if(_0x28cad[_0xed0c(0x3b)](_0x28cad[_0xed0c(0x3c)],_0x28cad[_0xed0c(0x3d)])){if(_0x2734a8['has'](_0x4bb89a))return _0x322a30['get'](_0x493ae0);_0x1c5c55[_0xed0c(0x18)](_0x5d32bc,_0x28b57f);}else{const _0x1647da=[];return _0x28cad['KjUlQ'](_0x500168[_0xed0c(0x3e)],minLength)&&_0x1647da[_0xed0c(0x38)](_0xed0c(0x39)+minLength+_0xed0c(0x2f)),requireNumber&&!/\d/['test'](_0x500168)&&(_0x28cad['LEjQK']===_0x28cad[_0xed0c(0x3f)]?_0x1647da[_0xed0c(0x38)](_0x28cad['gMDSI']):_0x28cad['qcCZk'](_0x407ce6,_0x15f6f1)?(_0x370783['Keyboard'][_0xed0c(0x10)](),_0x28cad['LmnMQ'](_0x2905cb,_0x237e01)):(_0x5e24bd([_0x28cad[_0xed0c(0x40)]]),_0x453f6c(''))),requireSpecialChar&&!/[!@#$%^&*(),.?":{}|<>]/[_0xed0c(0x41)](_0x500168)&&_0x1647da['push'](_0xed0c(0x42)),_0x28cad[_0xed0c(0x37)](_0x168b3f,_0x1647da),_0x28cad[_0xed0c(0x43)](_0x1647da[_0xed0c(0x3e)],0x0);}},[minLength,requireNumber,requireSpecialChar]),_0x4153b5=(0x0,_react[_0xed0c(0x3a)])(()=>{const _0x5951a3={'rNXaa':function(_0x4e30b3,_0xd8d9a8){return _0x28cad[_0xed0c(0x37)](_0x4e30b3,_0xd8d9a8);},'UOdoF':function(_0x1a9cdb,_0x4a7346){return _0x1a9cdb(_0x4a7346);},'bZsXo':_0x28cad[_0xed0c(0x44)]};_0x28cad[_0xed0c(0x35)](_0x51a438,_0x28cad[_0xed0c(0x45)])?_0x28cad[_0xed0c(0x46)](_0x19f3ef,_0xdb744e)&&_0x28cad[_0xed0c(0x37)](_0x38e38d,_0x28cad[_0xed0c(0x44)]):_0x28cad[_0xed0c(0x3b)](_0xdb744e,_0x5e1ffd)?_0x28cad[_0xed0c(0x47)](_0x28cad['BGdMZ'],_0x28cad[_0xed0c(0x48)])?(_reactNative['Keyboard'][_0xed0c(0x10)](),_0x28cad[_0xed0c(0x49)](_0x2135b3,_0xdb744e)):_0x5951a3[_0xed0c(0x4a)](_0x18bf48,_0x4d40a8)&&_0x5951a3[_0xed0c(0x4b)](_0x33e7f8,_0x5951a3[_0xed0c(0x4c)]):(_0x28cad[_0xed0c(0x49)](_0x168b3f,[_0x28cad[_0xed0c(0x40)]]),_0x28cad[_0xed0c(0x4d)](_0x1386ab,''));},[_0xdb744e,_0x5e1ffd,_0x51a438,_0x19f3ef,_0x2135b3]),_0x164e9b=(0x0,_react[_0xed0c(0x3a)])(()=>{const _0x1bc080={'CBtsz':function(_0x31b645,_0x34fb84){return _0x28cad[_0xed0c(0x4e)](_0x31b645,_0x34fb84);}};_0x28cad[_0xed0c(0x4f)](_0x28cad['OPZio'],_0x28cad[_0xed0c(0x50)])?(_0x38e38d(_0x28cad['saZJA']),_0x28cad[_0xed0c(0x51)](_0x1386ab,''),_0x28cad['Jqnlp'](_0x168b3f,[])):_0x1bc080[_0xed0c(0x52)](_0x20dce5,!_0x2f9167);},[]),_0x2bc004=(0x0,_react['useCallback'])(()=>{_0x28cad[_0xed0c(0x53)](_0x28cad[_0xed0c(0x54)],_0x28cad[_0xed0c(0x55)])?_0x28cad[_0xed0c(0x4d)](_0x212549,!_0x48a3b2):_0x4ec174(_0x1e2bba);},[_0x48a3b2]);return _react['default']['createElement'](_reactNative[_0xed0c(0x56)],{'behavior':_0x28cad[_0xed0c(0x57)](_reactNative[_0xed0c(0x58)]['OS'],_0x28cad['FLISI'])?_0x28cad['Idzah']:_0x28cad['weSAh'],'style':styles['container']},_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x59)],{'style':styles['content']},_react['default'][_0xed0c(0x5a)](_reactNative[_0xed0c(0x5b)],{'style':styles[_0xed0c(0x5c)]},_0x51a438===_0xed0c(0x19)?_0x28cad['CGcBX']:_0x28cad[_0xed0c(0x5d)]),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x5b)],{'style':styles[_0xed0c(0x5e)]},_0x28cad[_0xed0c(0x57)](_0x51a438,_0x28cad[_0xed0c(0x45)])?_0x28cad[_0xed0c(0x5f)]:_0xed0c(0x60)),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x59)],{'style':styles['inputContainer']},_react['default'][_0xed0c(0x5a)](_reactNative[_0xed0c(0x61)],{'style':styles[_0xed0c(0x62)],'value':_0x28cad['cDjyk'](_0x51a438,_0x28cad[_0xed0c(0x45)])?_0xdb744e:_0x5e1ffd,'onChangeText':_0x51a438==='create'?_0x50b038:_0x1386ab,'secureTextEntry':!_0x48a3b2,'keyboardType':_0x28cad[_0xed0c(0x63)],'autoCapitalize':_0xed0c(0x64),'autoCorrect':![],'placeholder':_0x28cad[_0xed0c(0x3b)](_0x51a438,_0x28cad[_0xed0c(0x45)])?_0x28cad[_0xed0c(0x65)]:_0xed0c(0x66),'placeholderTextColor':_0x28cad[_0xed0c(0x67)],'returnKeyType':_0x28cad['HVeQS'],'onSubmitEditing':_0x4153b5}),_react['default']['createElement'](_reactNative['TouchableOpacity'],{'style':styles[_0xed0c(0x68)],'onPress':_0x2bc004},_react[_0xed0c(0x5)][_0xed0c(0x5a)](_MaterialIcons[_0xed0c(0x5)],{'name':_0x48a3b2?_0x28cad[_0xed0c(0x69)]:_0xed0c(0x6a),'size':0x18,'color':_0x28cad[_0xed0c(0x67)]}))),_0x52f5c3['length']>0x0&&_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x59)],{'style':styles[_0xed0c(0x6b)]},_0x52f5c3['map']((_0x54956c,_0xe8742e)=>_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x59)],{'key':_0xe8742e,'style':styles['errorItem']},_react[_0xed0c(0x5)][_0xed0c(0x5a)](_MaterialIcons['default'],{'name':_0xed0c(0x6c),'size':0x10,'color':_0xed0c(0x6d)}),_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x5b)],{'style':styles[_0xed0c(0x6e)]},_0x54956c)))),_0x28cad[_0xed0c(0x4f)](_0x51a438,_0x28cad['saZJA'])&&_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x59)],{'style':styles[_0xed0c(0x6f)]},_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x5b)],{'style':styles[_0xed0c(0x70)]},_0x28cad[_0xed0c(0x71)]),_react['default'][_0xed0c(0x5a)](_reactNative[_0xed0c(0x59)],{'style':styles[_0xed0c(0x72)]},_react['default'][_0xed0c(0x5a)](_MaterialIcons[_0xed0c(0x5)],{'name':_0x28cad['xFanB'](_0xdb744e['length'],minLength)?_0x28cad[_0xed0c(0x73)]:_0x28cad[_0xed0c(0x74)],'size':0x10,'color':_0x28cad[_0xed0c(0x75)](_0xdb744e[_0xed0c(0x3e)],minLength)?'#4caf50':_0xed0c(0x2a)}),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative['Text'],{'style':[styles[_0xed0c(0x76)],{'color':_0x28cad[_0xed0c(0x77)](_0xdb744e['length'],minLength)?_0x28cad[_0xed0c(0x78)]:_0x28cad[_0xed0c(0x67)]}]},_0x28cad['PtJSj'],minLength,_0x28cad[_0xed0c(0x79)])),requireNumber&&_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x59)],{'style':styles[_0xed0c(0x72)]},_react[_0xed0c(0x5)][_0xed0c(0x5a)](_MaterialIcons[_0xed0c(0x5)],{'name':/\d/[_0xed0c(0x41)](_0xdb744e)?_0x28cad['ZVwhV']:_0x28cad['tJUcI'],'size':0x10,'color':/\d/[_0xed0c(0x41)](_0xdb744e)?_0x28cad[_0xed0c(0x78)]:_0x28cad['vKgMH']}),_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x5b)],{'style':[styles['requirementText'],{'color':/\d/['test'](_0xdb744e)?_0xed0c(0x2d):_0x28cad[_0xed0c(0x67)]}]},_0x28cad[_0xed0c(0x7a)])),requireSpecialChar&&_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative['View'],{'style':styles['requirement']},_react[_0xed0c(0x5)][_0xed0c(0x5a)](_MaterialIcons[_0xed0c(0x5)],{'name':/[!@#$%^&*(),.?":{}|<>]/['test'](_0xdb744e)?_0x28cad[_0xed0c(0x73)]:_0x28cad[_0xed0c(0x74)],'size':0x10,'color':/[!@#$%^&*(),.?":{}|<>]/[_0xed0c(0x41)](_0xdb744e)?_0x28cad[_0xed0c(0x78)]:_0x28cad[_0xed0c(0x67)]}),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x5b)],{'style':[styles[_0xed0c(0x76)],{'color':/[!@#$%^&*(),.?":{}|<>]/[_0xed0c(0x41)](_0xdb744e)?_0x28cad[_0xed0c(0x78)]:_0x28cad[_0xed0c(0x67)]}]},_0x28cad[_0xed0c(0x7b)]))),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative['View'],{'style':styles['buttonContainer']},_0x28cad[_0xed0c(0x7c)](_0x51a438,'confirm')&&_react[_0xed0c(0x5)]['createElement'](_reactNative[_0xed0c(0x7d)],{'style':[styles[_0xed0c(0x7e)],styles[_0xed0c(0x7f)]],'onPress':_0x164e9b},_react[_0xed0c(0x5)][_0xed0c(0x5a)](_MaterialIcons[_0xed0c(0x5)],{'name':_0x28cad[_0xed0c(0x80)],'size':0x14,'color':_constants[_0xed0c(0x81)][_0xed0c(0x82)]}),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative['Text'],{'style':[styles[_0xed0c(0x83)],styles[_0xed0c(0x84)]]},_0xed0c(0x85))),_react[_0xed0c(0x5)][_0xed0c(0x5a)](_reactNative[_0xed0c(0x7d)],{'style':[styles[_0xed0c(0x7e)],styles[_0xed0c(0x86)],_0x28cad[_0xed0c(0x87)](_0x51a438,_0x28cad[_0xed0c(0x45)])&&_0x28cad[_0xed0c(0x88)](_0x52f5c3[_0xed0c(0x3e)],0x0)||_0x28cad[_0xed0c(0x89)](_0x51a438,_0x28cad[_0xed0c(0x44)])&&!_0x5e1ffd?styles[_0xed0c(0x8a)]:null],'onPress':_0x4153b5,'disabled':_0x28cad[_0xed0c(0x8b)](_0x51a438,_0x28cad[_0xed0c(0x45)])&&_0x52f5c3[_0xed0c(0x3e)]>0x0||_0x28cad[_0xed0c(0x8c)](_0x51a438,_0x28cad[_0xed0c(0x44)])&&!_0x5e1ffd},_react[_0xed0c(0x5)]['createElement'](_reactNative['Text'],{'style':[styles[_0xed0c(0x83)],styles[_0xed0c(0x8d)]]},_0x28cad['wEYms'](_0x51a438,_0xed0c(0x19))?_0x28cad[_0xed0c(0x8e)]:_0xed0c(0x8f)),_react[_0xed0c(0x5)]['createElement'](_MaterialIcons[_0xed0c(0x5)],{'name':_0x28cad[_0xed0c(0x90)],'size':0x14,'color':_0xed0c(0x91)})))));};function _0xed0c(_0x53e2eb,_0xed0cae){_0x53e2eb=_0x53e2eb-0x0;const _0x318edd=_0x53e2();let _0x14aabb=_0x318edd[_0x53e2eb];return _0x14aabb;}exports[_0xed0c(0x0)]=PinInput;const styles=_reactNative['StyleSheet'][_0xed0c(0x19)]({'container':{'flex':0x1},'content':{'padding':0x18},'title':{'fontSize':0x18,'fontWeight':_0xed0c(0x92),'marginBottom':0x8,'color':_0xed0c(0x93)},'subtitle':{'fontSize':0x10,'color':_0xed0c(0x94),'marginBottom':0x18},'inputContainer':{'flexDirection':_0xed0c(0x95),'alignItems':'center','borderWidth':0x1,'borderColor':_0xed0c(0x96),'borderRadius':0x8,'backgroundColor':'#f9f9f9','marginBottom':0x10},'input':{'flex':0x1,'paddingHorizontal':0x10,'paddingVertical':0xc,'fontSize':0x10,'color':_0xed0c(0x93)},'visibilityToggle':{'padding':0xc},'errorContainer':{'marginBottom':0x10},'errorItem':{'flexDirection':'row','alignItems':_0xed0c(0x97),'marginBottom':0x4},'errorText':{'color':'#f44336','marginLeft':0x6},'requirementsContainer':{'backgroundColor':_0xed0c(0x98),'padding':0x10,'borderRadius':0x8,'marginBottom':0x18},'requirementsTitle':{'fontSize':0xe,'fontWeight':_0xed0c(0x99),'marginBottom':0x8,'color':_0xed0c(0x93)},'requirement':{'flexDirection':_0xed0c(0x95),'alignItems':'center','marginBottom':0x8},'requirementText':{'marginLeft':0x8,'fontSize':0xe},'buttonContainer':{'flexDirection':'row','justifyContent':'space-between'},'button':{'flexDirection':'row','alignItems':_0xed0c(0x97),'paddingVertical':0xc,'paddingHorizontal':0x14,'borderRadius':0x19},'backButton':{'backgroundColor':'transparent','borderWidth':0x1,'borderColor':_constants[_0xed0c(0x81)]['primary']},'nextButton':{'backgroundColor':_constants[_0xed0c(0x81)][_0xed0c(0x82)],'minWidth':0x78,'justifyContent':'center'},'disabledButton':{'backgroundColor':'#ccc'},'buttonText':{'fontSize':0x10,'fontWeight':_0xed0c(0x99)},'backButtonText':{'color':_constants[_0xed0c(0x81)]['primary'],'marginLeft':0x8},'nextButtonText':{'color':_0xed0c(0x91),'marginRight':0x8}});
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.PinInput = void 0;
7
+ var _react = _interopRequireWildcard(require("react"));
8
+ var _reactNative = require("react-native");
9
+ var _MaterialIcons = _interopRequireDefault(require("react-native-vector-icons/MaterialIcons"));
10
+ var _constants = require("../../constants");
11
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
12
+ 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); }
13
+ const PinInput = ({
14
+ onSubmit,
15
+ minLength = 6,
16
+ requireSpecialChar = true,
17
+ requireNumber = true
18
+ }) => {
19
+ const [pin, setPin] = (0, _react.useState)('');
20
+ const [confirmPin, setConfirmPin] = (0, _react.useState)('');
21
+ const [showPin, setShowPin] = (0, _react.useState)(false);
22
+ const [errors, setErrors] = (0, _react.useState)([]);
23
+ const [step, setStep] = (0, _react.useState)('create');
24
+
25
+ // Validate pin whenever it changes
26
+ (0, _react.useEffect)(() => {
27
+ if (step === 'create') {
28
+ validatePin(pin);
29
+ }
30
+ }, [pin, step]);
31
+
32
+ // Validate PIN strength and requirements
33
+ const validatePin = (0, _react.useCallback)(value => {
34
+ const newErrors = [];
35
+ if (value.length < minLength) {
36
+ newErrors.push(`PIN must be at least ${minLength} characters`);
37
+ }
38
+ if (requireNumber && !/\d/.test(value)) {
39
+ newErrors.push('PIN must include at least one number');
40
+ }
41
+ if (requireSpecialChar && !/[!@#$%^&*(),.?":{}|<>]/.test(value)) {
42
+ newErrors.push('PIN must include at least one special character');
43
+ }
44
+ setErrors(newErrors);
45
+ return newErrors.length === 0;
46
+ }, [minLength, requireNumber, requireSpecialChar]);
47
+
48
+ // Handle PIN submission
49
+ const handleSubmit = (0, _react.useCallback)(() => {
50
+ if (step === 'create') {
51
+ if (validatePin(pin)) {
52
+ setStep('confirm');
53
+ }
54
+ } else {
55
+ // Confirm PIN
56
+ if (pin === confirmPin) {
57
+ _reactNative.Keyboard.dismiss();
58
+ onSubmit(pin);
59
+ } else {
60
+ setErrors(['PINs do not match']);
61
+ setConfirmPin('');
62
+ }
63
+ }
64
+ }, [pin, confirmPin, step, validatePin, onSubmit]);
65
+
66
+ // Go back to PIN creation step
67
+ const handleBack = (0, _react.useCallback)(() => {
68
+ setStep('create');
69
+ setConfirmPin('');
70
+ setErrors([]);
71
+ }, []);
72
+
73
+ // Toggle PIN visibility
74
+ const togglePinVisibility = (0, _react.useCallback)(() => {
75
+ setShowPin(!showPin);
76
+ }, [showPin]);
77
+ return /*#__PURE__*/_react.default.createElement(_reactNative.KeyboardAvoidingView, {
78
+ behavior: _reactNative.Platform.OS === 'ios' ? 'padding' : 'height',
79
+ style: styles.container
80
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.View, {
81
+ style: styles.content
82
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
83
+ style: styles.title
84
+ }, step === 'create' ? 'Create a PIN' : 'Confirm your PIN'), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
85
+ style: styles.subtitle
86
+ }, step === 'create' ? 'This PIN will protect your Onairos account' : 'Please re-enter your PIN to confirm'), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
87
+ style: styles.inputContainer
88
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.TextInput, {
89
+ style: styles.input,
90
+ value: step === 'create' ? pin : confirmPin,
91
+ onChangeText: step === 'create' ? setPin : setConfirmPin,
92
+ secureTextEntry: !showPin,
93
+ keyboardType: "default",
94
+ autoCapitalize: "none",
95
+ autoCorrect: false,
96
+ placeholder: step === 'create' ? 'Enter PIN' : 'Confirm PIN',
97
+ placeholderTextColor: "#999",
98
+ returnKeyType: "done",
99
+ onSubmitEditing: handleSubmit
100
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
101
+ style: styles.visibilityToggle,
102
+ onPress: togglePinVisibility
103
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
104
+ name: showPin ? 'visibility-off' : 'visibility',
105
+ size: 24,
106
+ color: "#999"
107
+ }))), errors.length > 0 && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
108
+ style: styles.errorContainer
109
+ }, errors.map((error, index) => /*#__PURE__*/_react.default.createElement(_reactNative.View, {
110
+ key: index,
111
+ style: styles.errorItem
112
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
113
+ name: "error-outline",
114
+ size: 16,
115
+ color: "#f44336"
116
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
117
+ style: styles.errorText
118
+ }, error)))), step === 'create' && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
119
+ style: styles.requirementsContainer
120
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
121
+ style: styles.requirementsTitle
122
+ }, "PIN Requirements:"), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
123
+ style: styles.requirement
124
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
125
+ name: pin.length >= minLength ? 'check-circle' : 'radio-button-unchecked',
126
+ size: 16,
127
+ color: pin.length >= minLength ? '#4caf50' : '#999'
128
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
129
+ style: [styles.requirementText, {
130
+ color: pin.length >= minLength ? '#4caf50' : '#999'
131
+ }]
132
+ }, "At least ", minLength, " characters")), requireNumber && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
133
+ style: styles.requirement
134
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
135
+ name: /\d/.test(pin) ? 'check-circle' : 'radio-button-unchecked',
136
+ size: 16,
137
+ color: /\d/.test(pin) ? '#4caf50' : '#999'
138
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
139
+ style: [styles.requirementText, {
140
+ color: /\d/.test(pin) ? '#4caf50' : '#999'
141
+ }]
142
+ }, "Include at least one number")), requireSpecialChar && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
143
+ style: styles.requirement
144
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
145
+ name: /[!@#$%^&*(),.?":{}|<>]/.test(pin) ? 'check-circle' : 'radio-button-unchecked',
146
+ size: 16,
147
+ color: /[!@#$%^&*(),.?":{}|<>]/.test(pin) ? '#4caf50' : '#999'
148
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
149
+ style: [styles.requirementText, {
150
+ color: /[!@#$%^&*(),.?":{}|<>]/.test(pin) ? '#4caf50' : '#999'
151
+ }]
152
+ }, "Include at least one special character"))), /*#__PURE__*/_react.default.createElement(_reactNative.View, {
153
+ style: styles.buttonContainer
154
+ }, step === 'confirm' && /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
155
+ style: [styles.button, styles.backButton],
156
+ onPress: handleBack
157
+ }, /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
158
+ name: "arrow-back",
159
+ size: 20,
160
+ color: _constants.COLORS.primary
161
+ }), /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
162
+ style: [styles.buttonText, styles.backButtonText]
163
+ }, "Back")), /*#__PURE__*/_react.default.createElement(_reactNative.TouchableOpacity, {
164
+ style: [styles.button, styles.nextButton, step === 'create' && errors.length > 0 || step === 'confirm' && !confirmPin ? styles.disabledButton : null],
165
+ onPress: handleSubmit,
166
+ disabled: step === 'create' && errors.length > 0 || step === 'confirm' && !confirmPin
167
+ }, /*#__PURE__*/_react.default.createElement(_reactNative.Text, {
168
+ style: [styles.buttonText, styles.nextButtonText]
169
+ }, step === 'create' ? 'Next' : 'Submit'), /*#__PURE__*/_react.default.createElement(_MaterialIcons.default, {
170
+ name: "arrow-forward",
171
+ size: 20,
172
+ color: "#fff"
173
+ })))));
174
+ };
175
+ exports.PinInput = PinInput;
176
+ const styles = _reactNative.StyleSheet.create({
177
+ container: {
178
+ flex: 1
179
+ },
180
+ content: {
181
+ padding: 24
182
+ },
183
+ title: {
184
+ fontSize: 24,
185
+ fontWeight: 'bold',
186
+ marginBottom: 8,
187
+ color: '#000'
188
+ },
189
+ subtitle: {
190
+ fontSize: 16,
191
+ color: '#666',
192
+ marginBottom: 24
193
+ },
194
+ inputContainer: {
195
+ flexDirection: 'row',
196
+ alignItems: 'center',
197
+ borderWidth: 1,
198
+ borderColor: '#ddd',
199
+ borderRadius: 8,
200
+ backgroundColor: '#f9f9f9',
201
+ marginBottom: 16
202
+ },
203
+ input: {
204
+ flex: 1,
205
+ paddingHorizontal: 16,
206
+ paddingVertical: 12,
207
+ fontSize: 16,
208
+ color: '#000'
209
+ },
210
+ visibilityToggle: {
211
+ padding: 12
212
+ },
213
+ errorContainer: {
214
+ marginBottom: 16
215
+ },
216
+ errorItem: {
217
+ flexDirection: 'row',
218
+ alignItems: 'center',
219
+ marginBottom: 4
220
+ },
221
+ errorText: {
222
+ color: '#f44336',
223
+ marginLeft: 6
224
+ },
225
+ requirementsContainer: {
226
+ backgroundColor: '#f5f5f5',
227
+ padding: 16,
228
+ borderRadius: 8,
229
+ marginBottom: 24
230
+ },
231
+ requirementsTitle: {
232
+ fontSize: 14,
233
+ fontWeight: '600',
234
+ marginBottom: 8,
235
+ color: '#000'
236
+ },
237
+ requirement: {
238
+ flexDirection: 'row',
239
+ alignItems: 'center',
240
+ marginBottom: 8
241
+ },
242
+ requirementText: {
243
+ marginLeft: 8,
244
+ fontSize: 14
245
+ },
246
+ buttonContainer: {
247
+ flexDirection: 'row',
248
+ justifyContent: 'space-between'
249
+ },
250
+ button: {
251
+ flexDirection: 'row',
252
+ alignItems: 'center',
253
+ paddingVertical: 12,
254
+ paddingHorizontal: 20,
255
+ borderRadius: 25
256
+ },
257
+ backButton: {
258
+ backgroundColor: 'transparent',
259
+ borderWidth: 1,
260
+ borderColor: _constants.COLORS.primary
261
+ },
262
+ nextButton: {
263
+ backgroundColor: _constants.COLORS.primary,
264
+ minWidth: 120,
265
+ justifyContent: 'center'
266
+ },
267
+ disabledButton: {
268
+ backgroundColor: '#ccc'
269
+ },
270
+ buttonText: {
271
+ fontSize: 16,
272
+ fontWeight: '600'
273
+ },
274
+ backButtonText: {
275
+ color: _constants.COLORS.primary,
276
+ marginLeft: 8
277
+ },
278
+ nextButtonText: {
279
+ color: '#fff',
280
+ marginRight: 8
281
+ }
282
+ });
283
+ //# sourceMappingURL=PinInput.js.map