@onairos/react-native 3.6.7 โ†’ 3.6.9

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 (257) hide show
  1. package/README.md +423 -423
  2. package/lib/commonjs/api/index.js +1 -1
  3. package/lib/commonjs/assets/images/Checkbox.svg +3 -3
  4. package/lib/commonjs/assets/images/EnochE.svg +19 -19
  5. package/lib/commonjs/assets/images/Personalityprofile.svg +3 -3
  6. package/lib/commonjs/assets/images/Personalitytraits.svg +3 -3
  7. package/lib/commonjs/assets/images/Userpreferences.svg +3 -3
  8. package/lib/commonjs/assets/images/arrow.svg +20 -20
  9. package/lib/commonjs/assets/images/basicproficon.svg +43 -43
  10. package/lib/commonjs/assets/images/basicprofile.svg +3 -3
  11. package/lib/commonjs/assets/images/checkmark.svg +4 -4
  12. package/lib/commonjs/assets/images/contentanalysis.svg +3 -3
  13. package/lib/commonjs/assets/images/contenticon.svg +23 -23
  14. package/lib/commonjs/assets/images/personalityicon.svg +18 -18
  15. package/lib/commonjs/assets/images/x-close.svg +3 -3
  16. package/lib/commonjs/components/BodyText.js +1 -1
  17. package/lib/commonjs/components/BrandMark.js +1 -1
  18. package/lib/commonjs/components/CodeInput.js +1 -1
  19. package/lib/commonjs/components/EmailInput.js +1 -1
  20. package/lib/commonjs/components/GoogleButton.js +1 -1
  21. package/lib/commonjs/components/HeadingGroup.js +1 -1
  22. package/lib/commonjs/components/LLMDataInputModal.js +1 -1
  23. package/lib/commonjs/components/ModalHeader.js +1 -1
  24. package/lib/commonjs/components/ModalSheet.js +1 -1
  25. package/lib/commonjs/components/Onairos.js +1 -1
  26. package/lib/commonjs/components/OnairosButton.js +1 -1
  27. package/lib/commonjs/components/OnairosSignInButton.js +1 -1
  28. package/lib/commonjs/components/Overlay.js +1 -1
  29. package/lib/commonjs/components/PersonaImage.js +1 -1
  30. package/lib/commonjs/components/PersonaLoadingScreen.js +1 -1
  31. package/lib/commonjs/components/PersonalizationConsentScreen.js +1 -1
  32. package/lib/commonjs/components/PinCreationScreen.js +1 -1
  33. package/lib/commonjs/components/PinInput.js +1 -1
  34. package/lib/commonjs/components/PlatformConnectorsStep.js +1 -1
  35. package/lib/commonjs/components/PlatformList.js +1 -1
  36. package/lib/commonjs/components/PlatformToggle.js +1 -1
  37. package/lib/commonjs/components/PrimaryButton.js +1 -1
  38. package/lib/commonjs/components/SignInMatchAnimation.js +1 -1
  39. package/lib/commonjs/components/SignInStep.js +1 -1
  40. package/lib/commonjs/components/UniversalOnboarding.js +1 -1
  41. package/lib/commonjs/components/VerificationStep.js +1 -1
  42. package/lib/commonjs/components/WelcomeScreen.js +1 -1
  43. package/lib/commonjs/components/icons/Basicproficon.js +1 -1
  44. package/lib/commonjs/components/icons/Basicprofile.js +1 -1
  45. package/lib/commonjs/components/icons/Checkbox.js +1 -1
  46. package/lib/commonjs/components/icons/Checkmark.js +1 -1
  47. package/lib/commonjs/components/icons/Contentanalysis.js +1 -1
  48. package/lib/commonjs/components/icons/Contenticon.js +1 -1
  49. package/lib/commonjs/components/icons/EnochE.js +1 -1
  50. package/lib/commonjs/components/icons/Personalityicon.js +1 -1
  51. package/lib/commonjs/components/icons/Personalityprofile.js +1 -1
  52. package/lib/commonjs/components/icons/Personalitytraits.js +1 -1
  53. package/lib/commonjs/components/icons/Userpreferences.js +1 -1
  54. package/lib/commonjs/components/icons/index.js +1 -1
  55. package/lib/commonjs/components/onboarding/OAuthWebView.js +1 -1
  56. package/lib/commonjs/components/onboarding/OnboardingHeader.js +1 -1
  57. package/lib/commonjs/components/onboarding/PinInput.js +1 -1
  58. package/lib/commonjs/components/onboarding/PlatformConnector.js +1 -1
  59. package/lib/commonjs/config/PLATFORM_APIS.md +559 -0
  60. package/lib/commonjs/config/api.js +1 -1
  61. package/lib/commonjs/config/telegramConfig.js +8 -0
  62. package/lib/commonjs/config/webchangelog/md +607 -0
  63. package/lib/commonjs/constants/index.js +1 -1
  64. package/lib/commonjs/context/AuthContext.js +1 -1
  65. package/lib/commonjs/hooks/useConnectedAccounts.js +1 -1
  66. package/lib/commonjs/hooks/useConnections.js +1 -1
  67. package/lib/commonjs/hooks/useCredentials.js +1 -1
  68. package/lib/commonjs/hooks/useUserConnections.js +1 -1
  69. package/lib/commonjs/index.js +1 -1
  70. package/lib/commonjs/services/SDK_API_KEY_VALIDATION.md +421 -421
  71. package/lib/commonjs/services/apiClient.js +1 -1
  72. package/lib/commonjs/services/apiKeyService.js +99 -99
  73. package/lib/commonjs/services/authService.js +72 -72
  74. package/lib/commonjs/services/biometricPinService.js +1 -1
  75. package/lib/commonjs/services/chatGPTConversationExtractor.js +1 -1
  76. package/lib/commonjs/services/chatGPTConversationService.js +1 -1
  77. package/lib/commonjs/services/claudeConversationExtractor.js +1 -1
  78. package/lib/commonjs/services/claudeConversationService.js +1 -1
  79. package/lib/commonjs/services/connectedAccountsService.js +1 -1
  80. package/lib/commonjs/services/googleAuthService.js +1 -1
  81. package/lib/commonjs/services/hingeDataExtractor.js +1 -1
  82. package/lib/commonjs/services/hingeDataService.js +1 -1
  83. package/lib/commonjs/services/imageCompressionService.js +1 -1
  84. package/lib/commonjs/services/instagramDataExtractor.js +1 -1
  85. package/lib/commonjs/services/instagramDataService.js +1 -1
  86. package/lib/commonjs/services/jwtStorageService.js +1 -1
  87. package/lib/commonjs/services/linkedinDOMExtractor.js +1 -1
  88. package/lib/commonjs/services/linkedinProfileService.js +1 -1
  89. package/lib/commonjs/services/linkedinScrapingService.js +1 -1
  90. package/lib/commonjs/services/llmDataStorage.js +1 -1
  91. package/lib/commonjs/services/mobileTrainingService.js +1 -1
  92. package/lib/commonjs/services/oauthService.js +20 -20
  93. package/lib/commonjs/services/pinEncryptionService.js +1 -1
  94. package/lib/commonjs/services/pinStorageUtils.js +1 -1
  95. package/lib/commonjs/services/platformAuthService.js +1 -1
  96. package/lib/commonjs/services/sephoraDataExtractor.js +1 -1
  97. package/lib/commonjs/services/sephoraDataService.js +1 -1
  98. package/lib/commonjs/services/storageService.js +1 -1
  99. package/lib/commonjs/services/telegramDataExtractor.js +1 -1
  100. package/lib/commonjs/services/telegramDataService.js +1 -1
  101. package/lib/commonjs/services/trainingApiHelpers.js +1 -1
  102. package/lib/commonjs/services/userConnectionsService.js +1 -1
  103. package/lib/commonjs/services/youtubeMigrationService.js +1 -1
  104. package/lib/commonjs/theme/index.js +1 -1
  105. package/lib/commonjs/types/index.js +1 -1
  106. package/lib/commonjs/types.js +1 -1
  107. package/lib/commonjs/utils/Portal.js +1 -1
  108. package/lib/commonjs/utils/api.js +1 -1
  109. package/lib/commonjs/utils/assetRegistry.js +1 -1
  110. package/lib/commonjs/utils/auth.js +1 -1
  111. package/lib/commonjs/utils/connectorTests.js +1 -1
  112. package/lib/commonjs/utils/crypto.js +1 -1
  113. package/lib/commonjs/utils/debugHelper.js +1 -1
  114. package/lib/commonjs/utils/encryption.js +1 -1
  115. package/lib/commonjs/utils/eventUtils.js +1 -1
  116. package/lib/commonjs/utils/haptics.js +1 -1
  117. package/lib/commonjs/utils/imagePreloader.js +1 -1
  118. package/lib/commonjs/utils/networkDiagnostics.js +1 -1
  119. package/lib/commonjs/utils/onairosApi.js +1 -1
  120. package/lib/commonjs/utils/programmaticFlow.js +1 -1
  121. package/lib/commonjs/utils/retryHelper.js +1 -1
  122. package/lib/commonjs/utils/secureStorage.js +1 -1
  123. package/lib/commonjs/utils/webviewScripts/chatgpt.js +1 -1
  124. package/lib/commonjs/utils/webviewScripts/claude.js +1 -1
  125. package/lib/commonjs/utils/webviewScripts/hinge.js +1 -1
  126. package/lib/commonjs/utils/webviewScripts/index.js +1 -1
  127. package/lib/commonjs/utils/webviewScripts/instagram.js +1 -1
  128. package/lib/commonjs/utils/webviewScripts/linkedin.js +1 -1
  129. package/lib/commonjs/utils/webviewScripts/sephora.js +1 -1
  130. package/lib/commonjs/utils/webviewScripts/telegram.js +1 -1
  131. package/lib/module/api/index.js +1 -1
  132. package/lib/module/assets/images/Checkbox.svg +3 -3
  133. package/lib/module/assets/images/EnochE.svg +19 -19
  134. package/lib/module/assets/images/Personalityprofile.svg +3 -3
  135. package/lib/module/assets/images/Personalitytraits.svg +3 -3
  136. package/lib/module/assets/images/Userpreferences.svg +3 -3
  137. package/lib/module/assets/images/arrow.svg +20 -20
  138. package/lib/module/assets/images/basicproficon.svg +43 -43
  139. package/lib/module/assets/images/basicprofile.svg +3 -3
  140. package/lib/module/assets/images/checkmark.svg +4 -4
  141. package/lib/module/assets/images/contentanalysis.svg +3 -3
  142. package/lib/module/assets/images/contenticon.svg +23 -23
  143. package/lib/module/assets/images/personalityicon.svg +18 -18
  144. package/lib/module/assets/images/x-close.svg +3 -3
  145. package/lib/module/components/BodyText.js +1 -1
  146. package/lib/module/components/BrandMark.js +1 -1
  147. package/lib/module/components/CodeInput.js +1 -1
  148. package/lib/module/components/EmailInput.js +1 -1
  149. package/lib/module/components/GoogleButton.js +1 -1
  150. package/lib/module/components/HeadingGroup.js +1 -1
  151. package/lib/module/components/LLMDataInputModal.js +1 -1
  152. package/lib/module/components/ModalHeader.js +1 -1
  153. package/lib/module/components/ModalSheet.js +1 -1
  154. package/lib/module/components/Onairos.js +1 -1
  155. package/lib/module/components/OnairosButton.js +1 -1
  156. package/lib/module/components/OnairosSignInButton.js +1 -1
  157. package/lib/module/components/Overlay.js +1 -1
  158. package/lib/module/components/PersonaImage.js +1 -1
  159. package/lib/module/components/PersonaLoadingScreen.js +1 -1
  160. package/lib/module/components/PersonalizationConsentScreen.js +1 -1
  161. package/lib/module/components/PinCreationScreen.js +1 -1
  162. package/lib/module/components/PinInput.js +1 -1
  163. package/lib/module/components/PlatformConnectorsStep.js +1 -1
  164. package/lib/module/components/PlatformList.js +1 -1
  165. package/lib/module/components/PlatformToggle.js +1 -1
  166. package/lib/module/components/PrimaryButton.js +1 -1
  167. package/lib/module/components/SignInMatchAnimation.js +1 -1
  168. package/lib/module/components/SignInStep.js +1 -1
  169. package/lib/module/components/UniversalOnboarding.js +1 -1
  170. package/lib/module/components/VerificationStep.js +1 -1
  171. package/lib/module/components/WelcomeScreen.js +1 -1
  172. package/lib/module/components/icons/Basicproficon.js +1 -1
  173. package/lib/module/components/icons/Basicprofile.js +1 -1
  174. package/lib/module/components/icons/Checkbox.js +1 -1
  175. package/lib/module/components/icons/Checkmark.js +1 -1
  176. package/lib/module/components/icons/Contentanalysis.js +1 -1
  177. package/lib/module/components/icons/Contenticon.js +1 -1
  178. package/lib/module/components/icons/EnochE.js +1 -1
  179. package/lib/module/components/icons/Personalityicon.js +1 -1
  180. package/lib/module/components/icons/Personalityprofile.js +1 -1
  181. package/lib/module/components/icons/Personalitytraits.js +1 -1
  182. package/lib/module/components/icons/Userpreferences.js +1 -1
  183. package/lib/module/components/onboarding/OAuthWebView.js +1 -1
  184. package/lib/module/components/onboarding/OnboardingHeader.js +1 -1
  185. package/lib/module/components/onboarding/PinInput.js +1 -1
  186. package/lib/module/components/onboarding/PlatformConnector.js +1 -1
  187. package/lib/module/config/PLATFORM_APIS.md +559 -0
  188. package/lib/module/config/api.js +1 -1
  189. package/lib/module/config/telegramConfig.js +8 -0
  190. package/lib/module/config/webchangelog/md +607 -0
  191. package/lib/module/constants/index.js +1 -1
  192. package/lib/module/context/AuthContext.js +1 -1
  193. package/lib/module/hooks/useConnectedAccounts.js +1 -1
  194. package/lib/module/hooks/useConnections.js +1 -1
  195. package/lib/module/hooks/useCredentials.js +1 -1
  196. package/lib/module/hooks/useUserConnections.js +1 -1
  197. package/lib/module/index.js +1 -1
  198. package/lib/module/services/SDK_API_KEY_VALIDATION.md +421 -421
  199. package/lib/module/services/apiClient.js +1 -1
  200. package/lib/module/services/apiKeyService.js +99 -99
  201. package/lib/module/services/authService.js +72 -72
  202. package/lib/module/services/biometricPinService.js +1 -1
  203. package/lib/module/services/chatGPTConversationExtractor.js +1 -1
  204. package/lib/module/services/chatGPTConversationService.js +1 -1
  205. package/lib/module/services/claudeConversationExtractor.js +1 -1
  206. package/lib/module/services/claudeConversationService.js +1 -1
  207. package/lib/module/services/connectedAccountsService.js +1 -1
  208. package/lib/module/services/googleAuthService.js +1 -1
  209. package/lib/module/services/hingeDataExtractor.js +1 -1
  210. package/lib/module/services/hingeDataService.js +1 -1
  211. package/lib/module/services/imageCompressionService.js +1 -1
  212. package/lib/module/services/instagramDataExtractor.js +1 -1
  213. package/lib/module/services/instagramDataService.js +1 -1
  214. package/lib/module/services/jwtStorageService.js +1 -1
  215. package/lib/module/services/linkedinDOMExtractor.js +1 -1
  216. package/lib/module/services/linkedinProfileService.js +1 -1
  217. package/lib/module/services/linkedinScrapingService.js +1 -1
  218. package/lib/module/services/llmDataStorage.js +1 -1
  219. package/lib/module/services/mobileTrainingService.js +1 -1
  220. package/lib/module/services/oauthService.js +20 -20
  221. package/lib/module/services/pinEncryptionService.js +1 -1
  222. package/lib/module/services/pinStorageUtils.js +1 -1
  223. package/lib/module/services/platformAuthService.js +1 -1
  224. package/lib/module/services/sephoraDataExtractor.js +1 -1
  225. package/lib/module/services/sephoraDataService.js +1 -1
  226. package/lib/module/services/storageService.js +1 -1
  227. package/lib/module/services/telegramDataExtractor.js +1 -1
  228. package/lib/module/services/telegramDataService.js +1 -1
  229. package/lib/module/services/trainingApiHelpers.js +1 -1
  230. package/lib/module/services/userConnectionsService.js +1 -1
  231. package/lib/module/services/youtubeMigrationService.js +1 -1
  232. package/lib/module/theme/index.js +1 -1
  233. package/lib/module/types.js +1 -1
  234. package/lib/module/utils/Portal.js +1 -1
  235. package/lib/module/utils/api.js +1 -1
  236. package/lib/module/utils/assetRegistry.js +1 -1
  237. package/lib/module/utils/auth.js +1 -1
  238. package/lib/module/utils/connectorTests.js +1 -1
  239. package/lib/module/utils/crypto.js +1 -1
  240. package/lib/module/utils/debugHelper.js +1 -1
  241. package/lib/module/utils/encryption.js +1 -1
  242. package/lib/module/utils/eventUtils.js +1 -1
  243. package/lib/module/utils/haptics.js +1 -1
  244. package/lib/module/utils/networkDiagnostics.js +1 -1
  245. package/lib/module/utils/onairosApi.js +1 -1
  246. package/lib/module/utils/programmaticFlow.js +1 -1
  247. package/lib/module/utils/retryHelper.js +1 -1
  248. package/lib/module/utils/secureStorage.js +1 -1
  249. package/lib/module/utils/webviewScripts/chatgpt.js +1 -1
  250. package/lib/module/utils/webviewScripts/claude.js +1 -1
  251. package/lib/module/utils/webviewScripts/hinge.js +1 -1
  252. package/lib/module/utils/webviewScripts/index.js +1 -1
  253. package/lib/module/utils/webviewScripts/instagram.js +1 -1
  254. package/lib/module/utils/webviewScripts/linkedin.js +1 -1
  255. package/lib/module/utils/webviewScripts/sephora.js +1 -1
  256. package/lib/module/utils/webviewScripts/telegram.js +1 -1
  257. package/package.json +172 -172
@@ -0,0 +1,607 @@
1
+ # Changelog
2
+
3
+ All notable changes to the Onairos SDK will be documented in this file.
4
+
5
+ ## [5.8.22] - 2026-02-22
6
+
7
+ ### ๐Ÿ› Bug Fix - Cached Login / Session Persistence
8
+
9
+ #### Problem Fixed
10
+ - **Cached login was not working** - users were being asked to sign in again even with a valid session
11
+ - Session data flags (`onboardingComplete`, `pinCreated`) were not being persisted after flow completion
12
+
13
+ #### Root Cause
14
+ When onboarding or PIN setup completed, if the session was already valid (not expired), only `extendSession()` was called instead of `createSession()`. The `extendSession()` function only bumps the session expiry but does NOT update the stored user data with the new flags.
15
+
16
+ This caused:
17
+ 1. User completes onboarding โ†’ `onboardingComplete: true` set in memory but not persisted to session
18
+ 2. User completes PIN โ†’ `pinCreated: true` set in memory but not persisted to session
19
+ 3. User returns later โ†’ `checkValidSession()` reads old flags (both false) โ†’ session considered incomplete โ†’ login required
20
+
21
+ #### Solution
22
+ Always call `createSession()` with updated user data when flags change, not just `extendSession()`.
23
+
24
+ ---
25
+
26
+ ### โœจ Enhancement - Data Request UI Improvements
27
+
28
+ #### Changes
29
+ - **Raw Memories option visibility**: Now properly handles apps that don't request raw/LLM data
30
+ - If app doesn't request raw data: option shows greyed out with "Not used by this app" hover text
31
+ - If user has no LLM connections: option shows greyed out with "Connect an LLM app first" hover text
32
+ - **Added descriptions under data types** (matching Connections page style):
33
+ - Basic Profile: "Your basic profile information"
34
+ - Preferences: "Your preferences towards {appName}"
35
+ - Interests: "Overview of your personality"
36
+ - Raw Memories: "Secure raw app data from your LLM connections" (or disabled reason if unavailable)
37
+
38
+ ---
39
+
40
+ ## [5.8.19] - 2026-02-22
41
+
42
+ ### ๐Ÿ› Critical Fix - Next.js 16 Turbopack Compatibility
43
+
44
+ #### Problem Fixed
45
+ - **Turbopack parsing errors when importing onairos in Next.js 16+ App Router:**
46
+ - `SyntaxError: Function statements require a function name`
47
+ - `ChunkLoadError: Failed to load chunk server/chunks/ssr/...onairos_esm...`
48
+ - `Turbopack panic: x Expected ident` / `x Expected ';', '}' or <eof>`
49
+ - ESM bundle was incompatible with Turbopack's stricter SWC-based JavaScript parser
50
+ - Obfuscated code patterns (IIFEs, hexadecimal identifiers, RC4 decoders) broke parsing
51
+
52
+ #### Root Cause
53
+ Turbopack uses SWC (Rust-based parser) which is stricter than Webpack's Acorn parser.
54
+ `javascript-obfuscator` produces valid JavaScript that SWC cannot parse in certain edge cases:
55
+
56
+ | Pattern | Example | SWC Error |
57
+ |---------|---------|-----------|
58
+ | IIFE with hex identifiers | `function(_0x1a2b){...}` | "Function statements require function name" |
59
+ | RC4 decoder wrappers | `(function(){...})()` | Malformed IIFE detection |
60
+ | Control flow flattening | `switch(_0x...){case...}` | "Expected ident" errors |
61
+ | Dead code injection | Anonymous unreachable functions | Parser panics |
62
+
63
+ #### Solution Implemented
64
+ **Full obfuscation preserved with post-build normalization:**
65
+
66
+ 1. ESM builds use **full-strength obfuscation** (RC4, control flow flattening, etc.)
67
+ 2. After webpack completes, `scripts/normalize-esm-for-turbopack.cjs` runs the output through Babel
68
+ 3. Babel's parser/generator normalizes the AST into standard-form JavaScript
69
+ 4. The result is fully obfuscated code that Turbopack can parse
70
+
71
+ **Build flow:**
72
+ ```
73
+ Webpack โ†’ Obfuscate (full) โ†’ Babel normalize โ†’ Turbopack-compatible output
74
+ ```
75
+
76
+ **No security trade-off** - ESM builds retain the same protection level as before:
77
+ - RC4 string encryption
78
+ - Control flow flattening
79
+ - Dead code injection
80
+ - Hexadecimal identifiers
81
+ - String splitting
82
+ - Object key transformation
83
+
84
+ #### Migration
85
+ Simply update to 5.8.19:
86
+ ```bash
87
+ npm install onairos@5.8.19
88
+ # or
89
+ yarn add onairos@5.8.19
90
+ ```
91
+
92
+ No code changes required - the fix is entirely in the distributed bundle.
93
+
94
+ ---
95
+
96
+ ## [4.3.6] - 2024-12-24
97
+
98
+ ### ๐Ÿ› Critical Fix - Google Sign-In Token Type (ID Token vs Access Token)
99
+
100
+ #### Problem Fixed
101
+ - **Backend error: "Wrong number of segments in token"**
102
+ - SDK was sending **access token** (`ya29.xxx...`) instead of **ID token** (JWT `eyJhbGciOiJ...`)
103
+ - Backend expects ID token (JWT with 3 segments) for authentication verification
104
+ - Access tokens cannot be decoded/verified as JWTs
105
+
106
+ #### Solution Implemented
107
+ - **Switched from `useGoogleLogin` hook to `GoogleLogin` component**
108
+ - `useGoogleLogin` returns access token (for API calls) โŒ
109
+ - `GoogleLogin` returns ID token (for authentication) โœ…
110
+ - Backend now receives proper JWT ID token for verification
111
+
112
+ #### Technical Details
113
+
114
+ **Token Format Comparison:**
115
+ | Token Type | Format | Segments | Use Case |
116
+ |------------|--------|----------|----------|
117
+ | ID Token (JWT) โœ… | `eyJhbGciOiJ...` | 3 (header.payload.signature) | Authentication |
118
+ | Access Token โŒ | `ya29.xxx...` | Variable | API calls |
119
+
120
+ **Before (BROKEN):**
121
+ ```javascript
122
+ // Using useGoogleLogin - returns access token
123
+ const googleLogin = useGoogleLogin({
124
+ onSuccess: (tokenResponse) => {
125
+ const accessToken = tokenResponse.access_token; // ya29.xxx
126
+ // Send to backend โ†’ JWT decode fails!
127
+ }
128
+ });
129
+ ```
130
+
131
+ **After (FIXED):**
132
+ ```javascript
133
+ // Using GoogleLogin component - returns ID token
134
+ <GoogleLogin
135
+ onSuccess={(credentialResponse) => {
136
+ const idToken = credentialResponse.credential; // eyJhbGciOiJ... (JWT)
137
+ // Send to backend โ†’ JWT decode succeeds! โœ…
138
+ }}
139
+ />
140
+ ```
141
+
142
+ #### Files Changed
143
+ - `src/components/EmailAuth.js`:
144
+ - Changed import: `useGoogleLogin` โ†’ `GoogleLogin`
145
+ - Removed custom `GoogleButton` component (no longer needed)
146
+ - Implemented `handleGoogleSuccess()` to handle ID token
147
+ - Decode JWT to extract email before sending to backend
148
+ - Updated comments to clarify ID token vs access token
149
+ - Replaced custom button with official `<GoogleLogin>` component
150
+
151
+ #### Impact
152
+ - โœ… Backend receives proper JWT ID token (3 segments)
153
+ - โœ… JWT verification succeeds in backend
154
+ - โœ… Google Sign-In authentication works correctly
155
+ - โœ… Account creation succeeds
156
+ - โœ… Platform connections work for new Google users
157
+
158
+ #### Backend Integration
159
+ - Endpoint: `POST /google/google`
160
+ - Receives: `{ credential: "eyJhbGciOiJ..." }` (ID token, not access token)
161
+ - Backend can now decode and verify JWT successfully
162
+
163
+ ---
164
+
165
+ ## [4.3.5] - 2024-12-24
166
+
167
+ ### ๐Ÿ› Critical Fix - Google Sign-In Account Creation
168
+
169
+ #### Problem Fixed
170
+ - **New Google users were NOT getting accounts created in the backend**
171
+ - After Google Sign-In, frontend only checked if account exists but never created it
172
+ - This caused platform connection failures: "Account doesn't exist" error when connecting YouTube
173
+ - Backend diagnostics showed: `/getAccountInfo/email` called but NO account creation endpoint called
174
+
175
+ #### Solution Implemented
176
+ - **Added `/google/google` endpoint call** after Google Sign-In to create/login account
177
+ - Frontend now properly authenticates with backend and receives JWT token
178
+ - Backend creates account if it doesn't exist, or logs in existing user
179
+ - Platform connections now succeed for new Google users
180
+
181
+ #### Technical Details
182
+
183
+ **Before (BROKEN):**
184
+ ```javascript
185
+ // Google Sign-In โ†’ Get email
186
+ // Call /getAccountInfo/email โ†’ "No Account Found"
187
+ // โŒ No backend call to create account
188
+ // Proceed to YouTube connection โ†’ FAILS
189
+ ```
190
+
191
+ **After (FIXED):**
192
+ ```javascript
193
+ // Google Sign-In โ†’ Get email + access token
194
+ // Call /google/google with credential โ†’ Account created + JWT token returned
195
+ // โœ… Account exists in backend
196
+ // Proceed to YouTube connection โ†’ SUCCESS
197
+ ```
198
+
199
+ #### Files Changed
200
+ - `src/components/EmailAuth.js`:
201
+ - Updated `handleOAuthSuccess()` to call `/google/google` endpoint
202
+ - Pass Google access token as `credential` to backend
203
+ - Receive and store JWT token from backend response
204
+ - Updated `googleLogin` hook to pass access token to handler
205
+
206
+ #### Impact
207
+ - โœ… NEW Google users now get accounts created properly
208
+ - โœ… Platform connections (YouTube, etc.) succeed for new users
209
+ - โœ… JWT tokens properly issued and stored
210
+ - โœ… Existing Google users continue to work (login flow)
211
+
212
+ #### Backend Integration
213
+ - Uses existing `/google/google` endpoint
214
+ - Sends: `{ credential: googleAccessToken }`
215
+ - Receives: `{ body: { token, username, isNewUser } }`
216
+
217
+ For full technical analysis, see `GOOGLE_SIGNIN_ACCOUNT_CREATION_BUG.md`
218
+
219
+ ---
220
+
221
+ ## [4.2.3] - 2025-12-14
222
+
223
+ ### ๐Ÿ› Critical Fix - Email Authentication Routing (Corrects 4.2.2)
224
+
225
+ #### Problem Fixed
226
+ - **Version 4.2.2 introduced a bug**: NEW users via email authentication were incorrectly routed to dataRequest instead of onboarding
227
+ - **Root cause**: Added `/getAccountInfo/email` check AFTER email verification, but backend creates account during verification
228
+ - **Result**: Account check always found account exists (even for new users), causing wrong routing
229
+
230
+ #### Solution Implemented
231
+ - **Trust backend's `isNewUser` field** - Backend knows if account was just created during verification
232
+ - **Removed unnecessary API call** - No longer call `/getAccountInfo/email` after email verification
233
+ - **Consistent with backend design** - Both `/email/verify/confirm` and `/auth/google` are authoritative about user status
234
+
235
+ #### Technical Details
236
+
237
+ **Before (4.2.2 - BROKEN):**
238
+ ```javascript
239
+ // Email verification creates account and returns isNewUser: true
240
+ // Then we called /getAccountInfo/email
241
+ // Found account exists (just created!) โ†’ treated as existing user โŒ
242
+ ```
243
+
244
+ **After (4.2.3 - FIXED):**
245
+ ```javascript
246
+ // Email verification returns isNewUser: true
247
+ // Trust this field directly โ†’ route to onboarding โœ…
248
+ ```
249
+
250
+ #### Files Changed
251
+ - `src/components/EmailAuth.js`:
252
+ - Email verification: Trust `data.isNewUser` from verification response
253
+ - Google sign-in: Trust `authData.body.isNewUser` from `/auth/google` response
254
+ - Removed post-verification `/getAccountInfo/email` call that caused the bug
255
+
256
+ #### Impact
257
+ - โœ… NEW email users now correctly route to onboarding (FIXED)
258
+ - โœ… EXISTING email users still correctly route to dataRequest (unchanged)
259
+ - โœ… NEW Google users still correctly route to onboarding (unchanged)
260
+ - โœ… EXISTING Google users still correctly route to dataRequest (unchanged)
261
+
262
+ For detailed technical analysis, see `FIX_4.2.3_CORRECT_IMPLEMENTATION.md` and `AUTHENTICATION_FLOW_ANALYSIS.md`
263
+
264
+ ---
265
+
266
+ ## [4.2.2] - 2025-12-14 (SUPERSEDED BY 4.2.3)
267
+
268
+ ### ๐Ÿ› Fixed - Email Authentication Routing for Existing Users
269
+
270
+ #### Problem Resolved
271
+ - **Critical Bug**: Existing users authenticating via email verification were incorrectly routed to onboarding instead of dataRequest page
272
+ - **Root Cause**: Frontend was checking non-existent `data.existingUser` field instead of `data.isNewUser` returned by backend
273
+ - **Impact**: Existing users had to go through onboarding again instead of proceeding directly to data request
274
+
275
+ #### Solution Implemented
276
+ - Added explicit account status check via `/getAccountInfo/email` endpoint (matching Google sign-in behavior)
277
+ - Email verification flow now fetches complete account data after code verification
278
+ - Both Google OAuth and email authentication flows now return identical account data structures
279
+ - Uses `accountStatus.exists` field for consistent user routing logic
280
+
281
+ #### Technical Details
282
+ **Before Fix:**
283
+ ```javascript
284
+ // Backend returns: { isNewUser: false }
285
+ // Frontend checked: data.existingUser (undefined)
286
+ // Result: existingUser = false (WRONG!)
287
+ // Route: onboarding (WRONG for existing users!)
288
+ ```
289
+
290
+ **After Fix:**
291
+ ```javascript
292
+ // Explicit account check via /getAccountInfo/email
293
+ // Gets: { accountStatus: { exists: true } }
294
+ // Result: existingUser = true (CORRECT!)
295
+ // Route: dataRequest (CORRECT for existing users!)
296
+ ```
297
+
298
+ #### Files Changed
299
+ - `src/components/EmailAuth.js` - Added explicit account status check in `handleCodeSubmit()`
300
+ - Improved logging for account status verification
301
+ - Enhanced error handling and fallback logic
302
+
303
+ #### Benefits
304
+ - โœ… Existing users now correctly route to dataRequest page via email auth
305
+ - โœ… Consistent behavior between Google and email authentication
306
+ - โœ… Full account data available for both authentication flows
307
+ - โœ… Better user experience for returning users
308
+ - โœ… No breaking changes to existing functionality
309
+
310
+ For detailed technical analysis, see `EMAIL_AUTH_CONSISTENCY_FIX.md`
311
+
312
+ ---
313
+
314
+ ## [4.0.16] - 2025-12-01
315
+
316
+ ### ๐ŸŽ‰ Major Fix: Full Tailwind CSS v3 & v4 Compatibility
317
+
318
+ #### Fixed
319
+ - โœ… **RESOLVED**: Peer dependency conflict error with Tailwind CSS v3
320
+ - โœ… Package now works with **Tailwind v3.0+ and v4.0+** without any workarounds
321
+ - โœ… Brandon's issue with `tailwindcss@3.4.18` now resolved
322
+ - โœ… No need for `--force` or `--legacy-peer-deps` flags
323
+
324
+ #### Added
325
+ - `INSTALLATION_GUIDE.md` - Comprehensive installation guide for both Tailwind versions
326
+ - Automatic version compatibility detection
327
+ - Clear upgrade path documentation for developers who want to move to v4
328
+
329
+ #### Changed
330
+ - Peer dependency: `"tailwindcss": ">=3.0.0"` (supports all v3 and v4 versions)
331
+ - Version bumped to 4.0.16
332
+
333
+ #### Developer Instructions
334
+ **No configuration changes needed!** Just run:
335
+ ```bash
336
+ npm install onairos@latest
337
+ ```
338
+
339
+ Works automatically with:
340
+ - Tailwind CSS v3.4.x (Brandon's version with the error)
341
+ - Tailwind CSS v4.1.x
342
+ - All versions >=3.0.0
343
+
344
+ ---
345
+
346
+ ## [4.0.1] - 2025-11-14
347
+
348
+ ### ๐ŸŽฏ TypeScript Enhancement: onComplete Callback
349
+
350
+ #### Enhanced Type Definitions
351
+ - **NEW**: Added comprehensive `OnairosCompleteData` interface with full type documentation
352
+ - **IMPROVED**: Specified `token: string` and `apiUrl: string` as core response properties
353
+ - **NEW**: Documented all optional fields with detailed comments
354
+ - **NEW**: Added enhanced formatting fields (`userDataSummary`, `prettyPrint`)
355
+
356
+ #### Bug Fixes
357
+ - **FIXED**: Test mode now includes mock `token` field for consistent data structure
358
+ - **FIXED**: Test mode returns identical structure to production mode
359
+
360
+ #### Developer Experience
361
+ - **NEW**: Added comprehensive logging for `onComplete` data structure validation
362
+ - **NEW**: Visual indicators (โœ…/โŒ) for presence of key fields in console
363
+ - **NEW**: Detailed logging shows token preview, apiUrl, and all returned keys
364
+ - **NEW**: Created `ONCOMPLETE_USAGE_EXAMPLE.md` with complete usage documentation
365
+
366
+ #### Documentation
367
+ - **NEW**: TypeScript interface examples with proper typing
368
+ - **NEW**: JavaScript usage examples with authentication patterns
369
+ - **NEW**: Complete field documentation with descriptions
370
+ - **NEW**: Test mode vs Production mode comparison
371
+ - **NEW**: Examples of authenticated API requests using token and apiUrl
372
+
373
+ #### Code Quality
374
+ - **IMPROVED**: Better console debugging output at all stages of data flow
375
+ - **IMPROVED**: DataRequest component logs token and apiUrl presence before callback
376
+ - **IMPROVED**: OnairosButton logs complete data structure before passing to parent
377
+
378
+ ### Changes Summary
379
+ ```typescript
380
+ // Now properly typed in TypeScript
381
+ interface OnairosCompleteData {
382
+ token: string; // โœ… JWT token for authenticated API calls
383
+ apiUrl: string; // โœ… Backend API endpoint URL
384
+ // ... plus 20+ optional fields with full documentation
385
+ }
386
+
387
+ // Usage
388
+ const handleComplete = (data: OnairosCompleteData) => {
389
+ const { token, apiUrl } = data; // TypeScript knows these are strings!
390
+ };
391
+ ```
392
+
393
+ ## [3.4.0] - 2024-10-09
394
+
395
+ ### ๐Ÿš€ Major Features
396
+
397
+ #### Standardized API Key Validation System
398
+ - **NEW**: Implemented comprehensive `initializeApiKey()` function following standardized documentation
399
+ - **NEW**: Added `validateApiKey()` utility with backend validation
400
+ - **NEW**: Created `/auth/validate-key` endpoint for standardized API key validation
401
+ - **NEW**: Added retry logic with exponential backoff for network resilience
402
+ - **NEW**: Comprehensive error handling with specific error codes and suggestions
403
+
404
+ #### Enhanced SDK Architecture
405
+ - **NEW**: Modular API key validation utilities (`apiKeyValidation.js`)
406
+ - **NEW**: Centralized SDK initialization system (`sdkInitialization.js`)
407
+ - **NEW**: Global SDK state management with proper lifecycle
408
+ - **NEW**: Authenticated request helper with automatic API key injection
409
+
410
+ #### ChatGPT Integration
411
+ - **NEW**: Added ChatGPT as first connector with special behavior
412
+ - **NEW**: ChatGPT connector opens `chatgpt.com` in new tab (no OAuth)
413
+ - **NEW**: Added OpenAI icon support with fallback to emoji
414
+ - **NEW**: Updated platform configurations across all components
415
+
416
+ #### Gmail OAuth Fix
417
+ - **NEW**: Created Gmail OAuth backend route (`gmail-enhanced.js`)
418
+ - **NEW**: Added Gmail configuration to OAuth config
419
+ - **NEW**: Fixed "Not Found" error for Gmail authorization
420
+ - **NEW**: Comprehensive Gmail OAuth flow with token exchange
421
+
422
+ ### ๐Ÿ”ง Technical Improvements
423
+
424
+ #### API Key Validation
425
+ - **Format Validation**: Supports `ona_`, `dev_`, `pk_` prefixes (32+ characters)
426
+ - **Admin Key Support**: Special handling for admin keys with full permissions
427
+ - **Environment Detection**: Automatic production/development environment detection
428
+ - **Rate Limiting**: Built-in rate limit handling and reporting
429
+ - **Timeout Handling**: Configurable timeouts with abort controller
430
+
431
+ #### Error Handling
432
+ - **Standardized Error Codes**: `MISSING_API_KEY`, `INVALID_API_KEY_FORMAT`, etc.
433
+ - **Detailed Error Messages**: User-friendly error descriptions
434
+ - **Actionable Suggestions**: Specific suggestions for each error type
435
+ - **Retry Logic**: Automatic retry with exponential backoff for server errors
436
+
437
+ #### SDK Configuration
438
+ ```typescript
439
+ interface InitConfig {
440
+ apiKey: string; // Required: Developer API key
441
+ environment?: 'production' | 'development'; // Default: auto-detected
442
+ enableLogging?: boolean; // Default: false
443
+ timeout?: number; // Default: 30000ms
444
+ retryAttempts?: number; // Default: 3
445
+ platform?: string; // Default: 'web'
446
+ sdkVersion?: string; // Default: '3.4.0'
447
+ }
448
+ ```
449
+
450
+ ### ๐Ÿ“ก API Endpoints
451
+
452
+ #### New Validation Endpoints
453
+ - **POST** `/auth/validate-key` - Primary validation endpoint
454
+ - **GET** `/auth/validate-key?key=API_KEY` - Simple validation
455
+ - **GET** `/auth/health` - Health check endpoint
456
+
457
+ #### Enhanced OAuth Endpoints
458
+ - **POST** `/gmail/authorize` - Gmail OAuth authorization
459
+ - **GET** `/gmail/callback` - Gmail OAuth callback
460
+ - **POST** `/gmail/native-auth` - Gmail native authentication
461
+
462
+ ### ๐ŸŽจ UI/UX Improvements
463
+
464
+ #### Platform Connectors
465
+ - **ChatGPT First**: ChatGPT appears as first connector option
466
+ - **Visual Icons**: OpenAI icon for ChatGPT with emoji fallback
467
+ - **Consistent Design**: Unified design across all connector components
468
+ - **Special Behaviors**: Platform-specific behaviors (ChatGPT opens new tab)
469
+
470
+ #### Error Feedback
471
+ - **User-Friendly Messages**: Clear error descriptions for users
472
+ - **Developer Guidance**: Detailed suggestions for developers
473
+ - **Visual Feedback**: Proper loading states and error indicators
474
+
475
+ ### ๐Ÿ”’ Security Enhancements
476
+
477
+ #### API Key Security
478
+ - **Format Validation**: Strict format validation before network requests
479
+ - **Secure Storage**: Proper API key handling in global state
480
+ - **Token Management**: Automatic token refresh and management
481
+ - **Permission Checking**: Granular permission validation
482
+
483
+ #### Network Security
484
+ - **HTTPS Only**: All API calls use HTTPS endpoints
485
+ - **Request Signing**: Proper authorization headers
486
+ - **Timeout Protection**: Request timeout protection
487
+ - **Retry Limits**: Bounded retry attempts to prevent abuse
488
+
489
+ ### ๐Ÿ“š Documentation
490
+
491
+ #### New Documentation Files
492
+ - `SDK_API_KEY_VALIDATION.md` - Comprehensive API key validation guide
493
+ - `GMAIL_CHATGPT_IMPLEMENTATION.md` - Gmail OAuth and ChatGPT implementation
494
+ - `CHATGPT_ICON_UPDATE.md` - ChatGPT icon implementation details
495
+ - `CHANGELOG.md` - This changelog
496
+
497
+ #### Code Documentation
498
+ - **JSDoc Comments**: Comprehensive function documentation
499
+ - **TypeScript Interfaces**: Proper type definitions
500
+ - **Usage Examples**: Clear usage examples in documentation
501
+ - **Error Handling**: Documented error codes and handling
502
+
503
+ ### ๐Ÿงช Testing & Quality
504
+
505
+ #### Validation Testing
506
+ - **Format Validation**: Comprehensive API key format testing
507
+ - **Network Testing**: Retry logic and timeout testing
508
+ - **Error Scenarios**: All error code paths tested
509
+ - **Integration Testing**: End-to-end validation flow testing
510
+
511
+ #### Code Quality
512
+ - **ESLint Clean**: No linting errors
513
+ - **Modular Design**: Clean separation of concerns
514
+ - **Error Boundaries**: Proper error handling throughout
515
+ - **Performance**: Optimized network requests and state management
516
+
517
+ ### ๐Ÿ”„ Migration Guide
518
+
519
+ #### From v3.3.0 to v3.4.0
520
+
521
+ **Before (v3.3.0)**:
522
+ ```javascript
523
+ import { OnairosButton } from 'onairos';
524
+
525
+ // Components worked without explicit initialization
526
+ <OnairosButton requestData={{...}} />
527
+ ```
528
+
529
+ **After (v3.4.0)**:
530
+ ```javascript
531
+ import { initializeApiKey, OnairosButton } from 'onairos';
532
+
533
+ // 1. Initialize SDK first
534
+ await initializeApiKey({
535
+ apiKey: 'ona_your_api_key_here',
536
+ environment: 'production',
537
+ enableLogging: true
538
+ });
539
+
540
+ // 2. Use components (they automatically use initialized API key)
541
+ <OnairosButton requestData={{...}} />
542
+ ```
543
+
544
+ #### Breaking Changes
545
+ - **API Key Required**: `initializeApiKey()` must be called before using SDK components
546
+ - **Environment Detection**: Automatic environment detection (can be overridden)
547
+ - **Error Handling**: New error codes and error structure
548
+
549
+ #### Backward Compatibility
550
+ - **Component APIs**: All existing component APIs remain unchanged
551
+ - **Response Formats**: All response formats remain compatible
552
+ - **OAuth Flows**: Existing OAuth flows continue to work
553
+
554
+ ### ๐Ÿ› Bug Fixes
555
+
556
+ #### Gmail OAuth
557
+ - **Fixed**: "Not Found" error when connecting Gmail
558
+ - **Fixed**: Missing Gmail OAuth backend route
559
+ - **Fixed**: Gmail OAuth callback handling
560
+ - **Fixed**: Gmail token exchange and user data storage
561
+
562
+ #### Platform Connectors
563
+ - **Fixed**: Platform icon loading and fallback behavior
564
+ - **Fixed**: Connector state management across components
565
+ - **Fixed**: Platform configuration consistency
566
+ - **Fixed**: Special behavior handling for different platforms
567
+
568
+ #### SDK Initialization
569
+ - **Fixed**: Race conditions in SDK initialization
570
+ - **Fixed**: Global state management and cleanup
571
+ - **Fixed**: Error propagation and handling
572
+ - **Fixed**: Network request timeout and retry logic
573
+
574
+ ### ๐Ÿ“ฆ Dependencies
575
+
576
+ #### Updated Dependencies
577
+ - Maintained compatibility with existing React versions
578
+ - No breaking dependency changes
579
+ - Added proper error handling utilities
580
+ - Enhanced network request capabilities
581
+
582
+ ### ๐Ÿš€ Deployment
583
+
584
+ #### NPM Package
585
+ - **Version**: 3.4.0
586
+ - **Size**: Optimized bundle size
587
+ - **Compatibility**: React 18+, Node.js 16+
588
+ - **Platforms**: Web, React Native, Node.js
589
+
590
+ #### Distribution Files
591
+ - `dist/onairos.bundle.js` - Browser bundle
592
+ - `dist/onairos.esm.js` - ES modules
593
+ - `dist/onairos.native.js` - React Native
594
+ - `dist/onairos.laravel.js` - Laravel integration
595
+
596
+ ---
597
+
598
+ ## [3.3.0] - Previous Release
599
+
600
+ ### Features
601
+ - Basic OAuth connectors
602
+ - Component-based data collection
603
+ - Response formatting utilities
604
+
605
+ ---
606
+
607
+ *For more details, see the [GitHub repository](https://github.com/zd819/onairos-npm) and [documentation](https://docs.onairos.uk).*
@@ -1 +1 @@
1
- import{API_CONFIG}from'../config/api';export const COLORS={'primary':_0x1fd2(0x0),'headerBg':_0x1fd2(0x1),'text':{'primary':'#000000','secondary':_0x1fd2(0x2)},'border':_0x1fd2(0x3),'success':_0x1fd2(0x4),'error':_0x1fd2(0x5),'instagram':_0x1fd2(0x6),'pinterest':_0x1fd2(0x7),'reddit':_0x1fd2(0x8),'youtube':_0x1fd2(0x9),'chatgpt':_0x1fd2(0xa),'llm':_0x1fd2(0xa),'white':_0x1fd2(0xb),'black':_0x1fd2(0xc),'gray':'#666666','lightGray':'#E5E5E5'};export const PLATFORMS={'instagram':{'name':_0x1fd2(0xd),'icon':_0x1fd2(0xe),'color':COLORS['instagram'],'description':'Connect\x20your\x20Instagram\x20account\x20to\x20train\x20your\x20AI\x20model'},'pinterest':{'name':_0x1fd2(0xf),'icon':_0x1fd2(0x10),'color':COLORS[_0x1fd2(0x10)],'description':_0x1fd2(0x11)},'reddit':{'name':_0x1fd2(0x12),'icon':_0x1fd2(0x13),'color':COLORS[_0x1fd2(0x13)],'description':_0x1fd2(0x14)},'youtube':{'name':_0x1fd2(0x15),'icon':_0x1fd2(0x16),'color':COLORS[_0x1fd2(0x16)],'description':_0x1fd2(0x17)},'chatgpt':{'name':_0x1fd2(0x18),'icon':'chat','color':COLORS[_0x1fd2(0x19)],'description':_0x1fd2(0x1a)},'llm':{'name':'LLM\x20Data','icon':_0x1fd2(0x1b),'color':COLORS[_0x1fd2(0x1c)],'description':_0x1fd2(0x1d)}};function _0x48d5(){const _0x18de65=['#1BA9D4','#F8F9FA','#666666','#E5E5E5','#34C759','#FF3B30','#E1306C','#E60023','#FF4500','#FF0000','#10A37F','#FFFFFF','#000000','Instagram','instagram','Pinterest','pinterest','Use\x20your\x20Pinterest\x20boards\x20for\x20AI\x20training','Reddit','reddit','Connect\x20Reddit\x20to\x20enhance\x20your\x20AI\x20model','YouTube','youtube','Use\x20YouTube\x20data\x20to\x20improve\x20AI\x20recommendations','ChatGPT','chatgpt','Connect\x20your\x20ChatGPT\x20conversations\x20for\x20AI\x20insights','psychology','llm','Connect\x20your\x20AI\x20conversation\x20data','BASE_URL','/instagram/auth','/chatgpt/auth','/instagram/callback','/pinterest/callback','/reddit/callback','/youtube/callback','/chatgpt/callback','/llmdata/request','onairos_credentials','onairos_connections','onairosanime','onairosanime://auth/'];_0x48d5=function(){return _0x18de65;};return _0x48d5();}export const API_ENDPOINTS={'base':API_CONFIG[_0x1fd2(0x1e)],'oauth':{'instagram':_0x1fd2(0x1f),'pinterest':'/pinterest/auth','reddit':'/reddit/auth','youtube':'/youtube/auth','chatgpt':_0x1fd2(0x20),'llm':'/chatgpt/auth'},'callback':{'instagram':_0x1fd2(0x21),'pinterest':_0x1fd2(0x22),'reddit':_0x1fd2(0x23),'youtube':_0x1fd2(0x24),'chatgpt':_0x1fd2(0x25),'llm':'/chatgpt/callback'},'llm':{'dataIngest':'/llmdata','dataRequest':_0x1fd2(0x26)}};export const STORAGE_KEYS={'credentials':_0x1fd2(0x27),'connections':_0x1fd2(0x28)};function _0x1fd2(_0x48d5e4,_0x1fd223){_0x48d5e4=_0x48d5e4-0x0;const _0x473b44=_0x48d5();let _0x2391ff=_0x473b44[_0x48d5e4];return _0x2391ff;}export const PIN_REQUIREMENTS={'minLength':0x8,'requireUppercase':!![],'requireLowercase':!![],'requireNumber':!![],'requireSpecialChar':!![]};export const DEEP_LINK_CONFIG={'scheme':_0x1fd2(0x29),'host':'authenticate','redirectUri':_0x1fd2(0x2a)};
1
+ function _0x55ab(){const _0x5a3fa6=['#1BA9D4','#F8F9FA','#000000','#666666','#E5E5E5','#34C759','#FF3B30','#E1306C','#E60023','#FF0000','#10A37F','#FFFFFF','Instagram','instagram','Pinterest','pinterest','Reddit','reddit','Connect\x20Reddit\x20to\x20enhance\x20your\x20AI\x20model','YouTube','youtube','Use\x20YouTube\x20data\x20to\x20improve\x20AI\x20recommendations','chat','chatgpt','Connect\x20your\x20ChatGPT\x20conversations\x20for\x20AI\x20insights','LLM\x20Data','psychology','llm','Connect\x20your\x20AI\x20conversation\x20data','BASE_URL','/instagram/auth','/pinterest/auth','/reddit/auth','/youtube/auth','/chatgpt/auth','/instagram/callback','/pinterest/callback','/reddit/callback','/chatgpt/callback','/llmdata','/llmdata/request','onairos_credentials','authenticate','onairosanime://auth/'];_0x55ab=function(){return _0x5a3fa6;};return _0x55ab();}function _0x56c5(_0x55ab3f,_0x56c58e){_0x55ab3f=_0x55ab3f-0x0;const _0x4945cf=_0x55ab();let _0x1f2e4e=_0x4945cf[_0x55ab3f];return _0x1f2e4e;}import{API_CONFIG}from'../config/api';export const COLORS={'primary':_0x56c5(0x0),'headerBg':_0x56c5(0x1),'text':{'primary':_0x56c5(0x2),'secondary':_0x56c5(0x3)},'border':_0x56c5(0x4),'success':_0x56c5(0x5),'error':_0x56c5(0x6),'instagram':_0x56c5(0x7),'pinterest':_0x56c5(0x8),'reddit':'#FF4500','youtube':_0x56c5(0x9),'chatgpt':_0x56c5(0xa),'llm':_0x56c5(0xa),'white':_0x56c5(0xb),'black':'#000000','gray':_0x56c5(0x3),'lightGray':_0x56c5(0x4)};export const PLATFORMS={'instagram':{'name':_0x56c5(0xc),'icon':'instagram','color':COLORS[_0x56c5(0xd)],'description':'Connect\x20your\x20Instagram\x20account\x20to\x20train\x20your\x20AI\x20model'},'pinterest':{'name':_0x56c5(0xe),'icon':_0x56c5(0xf),'color':COLORS[_0x56c5(0xf)],'description':'Use\x20your\x20Pinterest\x20boards\x20for\x20AI\x20training'},'reddit':{'name':_0x56c5(0x10),'icon':_0x56c5(0x11),'color':COLORS['reddit'],'description':_0x56c5(0x12)},'youtube':{'name':_0x56c5(0x13),'icon':_0x56c5(0x14),'color':COLORS['youtube'],'description':_0x56c5(0x15)},'chatgpt':{'name':'ChatGPT','icon':_0x56c5(0x16),'color':COLORS[_0x56c5(0x17)],'description':_0x56c5(0x18)},'llm':{'name':_0x56c5(0x19),'icon':_0x56c5(0x1a),'color':COLORS[_0x56c5(0x1b)],'description':_0x56c5(0x1c)}};export const API_ENDPOINTS={'base':API_CONFIG[_0x56c5(0x1d)],'oauth':{'instagram':_0x56c5(0x1e),'pinterest':_0x56c5(0x1f),'reddit':_0x56c5(0x20),'youtube':_0x56c5(0x21),'chatgpt':_0x56c5(0x22),'llm':_0x56c5(0x22)},'callback':{'instagram':_0x56c5(0x23),'pinterest':_0x56c5(0x24),'reddit':_0x56c5(0x25),'youtube':'/youtube/callback','chatgpt':'/chatgpt/callback','llm':_0x56c5(0x26)},'llm':{'dataIngest':_0x56c5(0x27),'dataRequest':_0x56c5(0x28)}};export const STORAGE_KEYS={'credentials':_0x56c5(0x29),'connections':'onairos_connections'};export const PIN_REQUIREMENTS={'minLength':0x8,'requireUppercase':!![],'requireLowercase':!![],'requireNumber':!![],'requireSpecialChar':!![]};export const DEEP_LINK_CONFIG={'scheme':'onairosanime','host':_0x56c5(0x2a),'redirectUri':_0x56c5(0x2b)};