@oxyhq/services 5.7.5 → 5.8.1

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 (239) hide show
  1. package/README.md +76 -76
  2. package/lib/commonjs/core/index.js +177 -102
  3. package/lib/commonjs/core/index.js.map +1 -1
  4. package/lib/commonjs/index.js +88 -29
  5. package/lib/commonjs/index.js.map +1 -1
  6. package/lib/commonjs/node/createAuth.js +585 -7
  7. package/lib/commonjs/node/createAuth.js.map +1 -1
  8. package/lib/commonjs/node/index.js +38 -1
  9. package/lib/commonjs/node/index.js.map +1 -1
  10. package/lib/commonjs/ui/components/Avatar.js +15 -6
  11. package/lib/commonjs/ui/components/Avatar.js.map +1 -1
  12. package/lib/commonjs/ui/components/GroupedItem.js +58 -13
  13. package/lib/commonjs/ui/components/GroupedItem.js.map +1 -1
  14. package/lib/commonjs/ui/components/GroupedSection.js +7 -1
  15. package/lib/commonjs/ui/components/GroupedSection.js.map +1 -1
  16. package/lib/commonjs/ui/components/Header.js +322 -0
  17. package/lib/commonjs/ui/components/Header.js.map +1 -0
  18. package/lib/commonjs/ui/components/OxyProvider.js +23 -7
  19. package/lib/commonjs/ui/components/OxyProvider.js.map +1 -1
  20. package/lib/commonjs/ui/components/index.js +7 -0
  21. package/lib/commonjs/ui/components/index.js.map +1 -1
  22. package/lib/commonjs/ui/components/internal/GroupedPillButtons.js +1 -1
  23. package/lib/commonjs/ui/components/internal/GroupedPillButtons.js.map +1 -1
  24. package/lib/commonjs/ui/components/internal/TextField.js +606 -546
  25. package/lib/commonjs/ui/components/internal/TextField.js.map +1 -1
  26. package/lib/commonjs/ui/components/internal/TextField.md +436 -0
  27. package/lib/commonjs/ui/context/OxyContext.js +122 -78
  28. package/lib/commonjs/ui/context/OxyContext.js.map +1 -1
  29. package/lib/commonjs/ui/hooks/useSessionSocket.js +5 -2
  30. package/lib/commonjs/ui/hooks/useSessionSocket.js.map +1 -1
  31. package/lib/commonjs/ui/navigation/OxyRouter.js +1 -1
  32. package/lib/commonjs/ui/navigation/OxyRouter.js.map +1 -1
  33. package/lib/commonjs/ui/screens/AccountCenterScreen.js +6 -6
  34. package/lib/commonjs/ui/screens/AccountCenterScreen.js.map +1 -1
  35. package/lib/commonjs/ui/screens/AccountManagementDemo.js +3 -3
  36. package/lib/commonjs/ui/screens/AccountManagementDemo.js.map +1 -1
  37. package/lib/commonjs/ui/screens/AccountOverviewScreen.js +241 -598
  38. package/lib/commonjs/ui/screens/AccountOverviewScreen.js.map +1 -1
  39. package/lib/commonjs/ui/screens/AccountSettingsScreen.js +1151 -406
  40. package/lib/commonjs/ui/screens/AccountSettingsScreen.js.map +1 -1
  41. package/lib/commonjs/ui/screens/AccountSwitcherScreen.js +135 -237
  42. package/lib/commonjs/ui/screens/AccountSwitcherScreen.js.map +1 -1
  43. package/lib/commonjs/ui/screens/AppInfoScreen.js +246 -463
  44. package/lib/commonjs/ui/screens/AppInfoScreen.js.map +1 -1
  45. package/lib/commonjs/ui/screens/FeedbackScreen.js +3 -3
  46. package/lib/commonjs/ui/screens/FeedbackScreen.js.map +1 -1
  47. package/lib/commonjs/ui/screens/PaymentGatewayScreen.js +808 -650
  48. package/lib/commonjs/ui/screens/PaymentGatewayScreen.js.map +1 -1
  49. package/lib/commonjs/ui/screens/RecoverAccountScreen.js +51 -72
  50. package/lib/commonjs/ui/screens/RecoverAccountScreen.js.map +1 -1
  51. package/lib/commonjs/ui/screens/SessionManagementScreen.js +11 -29
  52. package/lib/commonjs/ui/screens/SessionManagementScreen.js.map +1 -1
  53. package/lib/commonjs/ui/screens/SignInScreen.js +30 -303
  54. package/lib/commonjs/ui/screens/SignInScreen.js.map +1 -1
  55. package/lib/commonjs/ui/screens/SignUpScreen.js +4 -4
  56. package/lib/commonjs/ui/screens/SignUpScreen.js.map +1 -1
  57. package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js +19 -31
  58. package/lib/commonjs/ui/screens/internal/SignInPasswordStep.js.map +1 -1
  59. package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js +7 -10
  60. package/lib/commonjs/ui/screens/internal/SignInUsernameStep.js.map +1 -1
  61. package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js +11 -5
  62. package/lib/commonjs/ui/screens/internal/SignUpIdentityStep.js.map +1 -1
  63. package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js +11 -4
  64. package/lib/commonjs/ui/screens/internal/SignUpSecurityStep.js.map +1 -1
  65. package/lib/commonjs/ui/stores/authStore.js +12 -0
  66. package/lib/commonjs/ui/stores/authStore.js.map +1 -1
  67. package/lib/commonjs/ui/styles/authStyles.js +337 -0
  68. package/lib/commonjs/ui/styles/authStyles.js.map +1 -0
  69. package/lib/commonjs/ui/styles/index.js +11 -0
  70. package/lib/commonjs/ui/styles/index.js.map +1 -1
  71. package/lib/module/core/index.js +177 -41
  72. package/lib/module/core/index.js.map +1 -1
  73. package/lib/module/index.js +26 -4
  74. package/lib/module/index.js.map +1 -1
  75. package/lib/module/node/createAuth.js +584 -7
  76. package/lib/module/node/createAuth.js.map +1 -1
  77. package/lib/module/node/index.js +7 -1
  78. package/lib/module/node/index.js.map +1 -1
  79. package/lib/module/ui/components/Avatar.js +15 -6
  80. package/lib/module/ui/components/Avatar.js.map +1 -1
  81. package/lib/module/ui/components/GroupedItem.js +59 -14
  82. package/lib/module/ui/components/GroupedItem.js.map +1 -1
  83. package/lib/module/ui/components/GroupedSection.js +7 -1
  84. package/lib/module/ui/components/GroupedSection.js.map +1 -1
  85. package/lib/module/ui/components/Header.js +317 -0
  86. package/lib/module/ui/components/Header.js.map +1 -0
  87. package/lib/module/ui/components/OxyProvider.js +25 -9
  88. package/lib/module/ui/components/OxyProvider.js.map +1 -1
  89. package/lib/module/ui/components/index.js +1 -0
  90. package/lib/module/ui/components/index.js.map +1 -1
  91. package/lib/module/ui/components/internal/GroupedPillButtons.js +1 -1
  92. package/lib/module/ui/components/internal/GroupedPillButtons.js.map +1 -1
  93. package/lib/module/ui/components/internal/TextField.js +607 -547
  94. package/lib/module/ui/components/internal/TextField.js.map +1 -1
  95. package/lib/module/ui/components/internal/TextField.md +436 -0
  96. package/lib/module/ui/context/OxyContext.js +121 -77
  97. package/lib/module/ui/context/OxyContext.js.map +1 -1
  98. package/lib/module/ui/hooks/useSessionSocket.js +5 -2
  99. package/lib/module/ui/hooks/useSessionSocket.js.map +1 -1
  100. package/lib/module/ui/navigation/OxyRouter.js +1 -1
  101. package/lib/module/ui/navigation/OxyRouter.js.map +1 -1
  102. package/lib/module/ui/screens/AccountCenterScreen.js +6 -6
  103. package/lib/module/ui/screens/AccountCenterScreen.js.map +1 -1
  104. package/lib/module/ui/screens/AccountManagementDemo.js +3 -3
  105. package/lib/module/ui/screens/AccountManagementDemo.js.map +1 -1
  106. package/lib/module/ui/screens/AccountOverviewScreen.js +242 -597
  107. package/lib/module/ui/screens/AccountOverviewScreen.js.map +1 -1
  108. package/lib/module/ui/screens/AccountSettingsScreen.js +1152 -407
  109. package/lib/module/ui/screens/AccountSettingsScreen.js.map +1 -1
  110. package/lib/module/ui/screens/AccountSwitcherScreen.js +135 -237
  111. package/lib/module/ui/screens/AccountSwitcherScreen.js.map +1 -1
  112. package/lib/module/ui/screens/AppInfoScreen.js +248 -465
  113. package/lib/module/ui/screens/AppInfoScreen.js.map +1 -1
  114. package/lib/module/ui/screens/FeedbackScreen.js +3 -3
  115. package/lib/module/ui/screens/FeedbackScreen.js.map +1 -1
  116. package/lib/module/ui/screens/PaymentGatewayScreen.js +809 -651
  117. package/lib/module/ui/screens/PaymentGatewayScreen.js.map +1 -1
  118. package/lib/module/ui/screens/RecoverAccountScreen.js +53 -74
  119. package/lib/module/ui/screens/RecoverAccountScreen.js.map +1 -1
  120. package/lib/module/ui/screens/SessionManagementScreen.js +11 -29
  121. package/lib/module/ui/screens/SessionManagementScreen.js.map +1 -1
  122. package/lib/module/ui/screens/SignInScreen.js +32 -305
  123. package/lib/module/ui/screens/SignInScreen.js.map +1 -1
  124. package/lib/module/ui/screens/SignUpScreen.js +5 -5
  125. package/lib/module/ui/screens/SignUpScreen.js.map +1 -1
  126. package/lib/module/ui/screens/internal/SignInPasswordStep.js +19 -31
  127. package/lib/module/ui/screens/internal/SignInPasswordStep.js.map +1 -1
  128. package/lib/module/ui/screens/internal/SignInUsernameStep.js +7 -10
  129. package/lib/module/ui/screens/internal/SignInUsernameStep.js.map +1 -1
  130. package/lib/module/ui/screens/internal/SignUpIdentityStep.js +11 -5
  131. package/lib/module/ui/screens/internal/SignUpIdentityStep.js.map +1 -1
  132. package/lib/module/ui/screens/internal/SignUpSecurityStep.js +11 -4
  133. package/lib/module/ui/screens/internal/SignUpSecurityStep.js.map +1 -1
  134. package/lib/module/ui/stores/authStore.js +12 -0
  135. package/lib/module/ui/stores/authStore.js.map +1 -1
  136. package/lib/module/ui/styles/authStyles.js +332 -0
  137. package/lib/module/ui/styles/authStyles.js.map +1 -0
  138. package/lib/module/ui/styles/index.js +1 -0
  139. package/lib/module/ui/styles/index.js.map +1 -1
  140. package/lib/typescript/core/index.d.ts +68 -24
  141. package/lib/typescript/core/index.d.ts.map +1 -1
  142. package/lib/typescript/index.d.ts +13 -3
  143. package/lib/typescript/index.d.ts.map +1 -1
  144. package/lib/typescript/node/createAuth.d.ts +112 -0
  145. package/lib/typescript/node/createAuth.d.ts.map +1 -1
  146. package/lib/typescript/node/index.d.ts +2 -0
  147. package/lib/typescript/node/index.d.ts.map +1 -1
  148. package/lib/typescript/ui/components/Avatar.d.ts.map +1 -1
  149. package/lib/typescript/ui/components/GroupedItem.d.ts +6 -0
  150. package/lib/typescript/ui/components/GroupedItem.d.ts.map +1 -1
  151. package/lib/typescript/ui/components/GroupedSection.d.ts +6 -0
  152. package/lib/typescript/ui/components/GroupedSection.d.ts.map +1 -1
  153. package/lib/typescript/ui/components/Header.d.ts +22 -0
  154. package/lib/typescript/ui/components/Header.d.ts.map +1 -0
  155. package/lib/typescript/ui/components/OxyProvider.d.ts.map +1 -1
  156. package/lib/typescript/ui/components/index.d.ts +1 -0
  157. package/lib/typescript/ui/components/index.d.ts.map +1 -1
  158. package/lib/typescript/ui/components/internal/TextField.d.ts +31 -16
  159. package/lib/typescript/ui/components/internal/TextField.d.ts.map +1 -1
  160. package/lib/typescript/ui/context/OxyContext.d.ts +5 -2
  161. package/lib/typescript/ui/context/OxyContext.d.ts.map +1 -1
  162. package/lib/typescript/ui/hooks/useSessionSocket.d.ts.map +1 -1
  163. package/lib/typescript/ui/navigation/types.d.ts +9 -2
  164. package/lib/typescript/ui/navigation/types.d.ts.map +1 -1
  165. package/lib/typescript/ui/screens/AccountOverviewScreen.d.ts.map +1 -1
  166. package/lib/typescript/ui/screens/AccountSettingsScreen.d.ts.map +1 -1
  167. package/lib/typescript/ui/screens/AccountSwitcherScreen.d.ts.map +1 -1
  168. package/lib/typescript/ui/screens/AppInfoScreen.d.ts.map +1 -1
  169. package/lib/typescript/ui/screens/PaymentGatewayScreen.d.ts.map +1 -1
  170. package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts +5 -1
  171. package/lib/typescript/ui/screens/RecoverAccountScreen.d.ts.map +1 -1
  172. package/lib/typescript/ui/screens/SessionManagementScreen.d.ts.map +1 -1
  173. package/lib/typescript/ui/screens/SignInScreen.d.ts.map +1 -1
  174. package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts +1 -1
  175. package/lib/typescript/ui/screens/internal/SignInPasswordStep.d.ts.map +1 -1
  176. package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts +0 -1
  177. package/lib/typescript/ui/screens/internal/SignInUsernameStep.d.ts.map +1 -1
  178. package/lib/typescript/ui/screens/internal/SignUpIdentityStep.d.ts.map +1 -1
  179. package/lib/typescript/ui/screens/internal/SignUpSecurityStep.d.ts.map +1 -1
  180. package/lib/typescript/ui/stores/authStore.d.ts.map +1 -1
  181. package/lib/typescript/ui/styles/authStyles.d.ts +326 -0
  182. package/lib/typescript/ui/styles/authStyles.d.ts.map +1 -0
  183. package/lib/typescript/ui/styles/index.d.ts +1 -0
  184. package/lib/typescript/ui/styles/index.d.ts.map +1 -1
  185. package/package.json +1 -4
  186. package/src/core/index.ts +195 -41
  187. package/src/index.ts +72 -4
  188. package/src/node/createAuth.ts +623 -7
  189. package/src/node/index.ts +19 -1
  190. package/src/ui/components/Avatar.tsx +11 -5
  191. package/src/ui/components/GroupedItem.tsx +57 -9
  192. package/src/ui/components/GroupedSection.tsx +12 -0
  193. package/src/ui/components/Header.tsx +364 -0
  194. package/src/ui/components/OxyProvider.tsx +31 -15
  195. package/src/ui/components/index.ts +1 -0
  196. package/src/ui/components/internal/GroupedPillButtons.tsx +1 -1
  197. package/src/ui/components/internal/TextField.md +436 -0
  198. package/src/ui/components/internal/TextField.tsx +720 -620
  199. package/src/ui/context/OxyContext.tsx +150 -63
  200. package/src/ui/hooks/useSessionSocket.ts +5 -2
  201. package/src/ui/navigation/OxyRouter.tsx +1 -1
  202. package/src/ui/navigation/types.ts +10 -2
  203. package/src/ui/screens/AccountCenterScreen.tsx +5 -5
  204. package/src/ui/screens/AccountManagementDemo.tsx +9 -9
  205. package/src/ui/screens/AccountOverviewScreen.tsx +265 -414
  206. package/src/ui/screens/AccountSettingsScreen.tsx +1165 -403
  207. package/src/ui/screens/AccountSwitcherScreen.tsx +158 -202
  208. package/src/ui/screens/AppInfoScreen.tsx +270 -497
  209. package/src/ui/screens/FeedbackScreen.tsx +3 -3
  210. package/src/ui/screens/PaymentGatewayScreen.tsx +668 -365
  211. package/src/ui/screens/ProfileScreen.tsx +5 -5
  212. package/src/ui/screens/RecoverAccountScreen.tsx +46 -74
  213. package/src/ui/screens/SessionManagementScreen.tsx +14 -22
  214. package/src/ui/screens/SignInScreen.tsx +27 -294
  215. package/src/ui/screens/SignUpScreen.tsx +5 -5
  216. package/src/ui/screens/internal/SignInPasswordStep.tsx +11 -22
  217. package/src/ui/screens/internal/SignInUsernameStep.tsx +3 -10
  218. package/src/ui/screens/internal/SignUpIdentityStep.tsx +2 -5
  219. package/src/ui/screens/internal/SignUpSecurityStep.tsx +3 -4
  220. package/src/ui/stores/authStore.ts +12 -0
  221. package/src/ui/styles/authStyles.ts +352 -0
  222. package/src/ui/styles/index.ts +1 -0
  223. package/lib/commonjs/core/auth-manager.js +0 -440
  224. package/lib/commonjs/core/auth-manager.js.map +0 -1
  225. package/lib/commonjs/core/use-auth.js +0 -244
  226. package/lib/commonjs/core/use-auth.js.map +0 -1
  227. package/lib/module/core/auth-manager.js +0 -432
  228. package/lib/module/core/auth-manager.js.map +0 -1
  229. package/lib/module/core/use-auth.js +0 -235
  230. package/lib/module/core/use-auth.js.map +0 -1
  231. package/lib/typescript/core/auth-manager.d.ts +0 -136
  232. package/lib/typescript/core/auth-manager.d.ts.map +0 -1
  233. package/lib/typescript/core/use-auth.d.ts +0 -79
  234. package/lib/typescript/core/use-auth.d.ts.map +0 -1
  235. package/src/__tests__/middleware.test.ts +0 -105
  236. package/src/__tests__/setup.ts +0 -10
  237. package/src/__tests__/zero-config-auth.test.ts +0 -607
  238. package/src/core/auth-manager.ts +0 -500
  239. package/src/core/use-auth.tsx +0 -245
@@ -10,10 +10,9 @@ var _OxyContext = require("../context/OxyContext");
10
10
  var _fonts = require("../styles/fonts");
11
11
  var _version = require("../../constants/version");
12
12
  var _sonner = require("../../lib/sonner");
13
- var _confirmAction = require("../utils/confirmAction");
14
- var _OxyIcon = _interopRequireDefault(require("../components/icon/OxyIcon"));
15
13
  var _vectorIcons = require("@expo/vector-icons");
16
14
  var _OxyServices = _interopRequireDefault(require("../../assets/icons/OxyServices"));
15
+ var _components = require("../components");
17
16
  var _jsxRuntime = require("react/jsx-runtime");
18
17
  function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
19
18
  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); }
@@ -85,196 +84,46 @@ const AppInfoScreen = ({
85
84
  }
86
85
  };
87
86
  const runSystemCheck = async () => {
88
- if (!oxyServices) {
89
- _sonner.toast.error('OxyServices not initialized');
90
- return;
91
- }
92
87
  setIsRunningSystemCheck(true);
93
- const checks = [];
94
-
95
- // Get the API base URL from the services instance
96
- const apiBaseUrl = oxyServices?.getBaseURL() || 'https://api.oxy.so'; // Default for now, could be made configurable
97
-
98
88
  try {
99
- // Check 1: API Server Health
100
- checks.push('🔍 Checking API server connection...');
101
- _sonner.toast.info('Running system checks...', {
102
- duration: 2000
103
- });
104
- try {
105
- const data = await oxyServices.healthCheck();
106
- checks.push('✅ API server is responding');
107
- checks.push(`📊 Server stats: ${data.users || 0} users`);
108
- checks.push(`🌐 API URL: ${apiBaseUrl}`);
109
- setConnectionStatus('connected');
110
- } catch (error) {
111
- checks.push('❌ API server connection failed');
112
- checks.push(` Error: ${error instanceof Error ? error.message : 'Unknown error'}`);
113
- checks.push(` URL: ${apiBaseUrl}`);
114
- setConnectionStatus('disconnected');
115
- }
89
+ // Simulate system check
90
+ await new Promise(resolve => setTimeout(resolve, 2000));
116
91
 
117
- // Check 2: Authentication Status
118
- checks.push('🔍 Checking authentication...');
119
- checks.push(`🔐 Authentication Status: ${isAuthenticated ? '✅ Authenticated' : '❌ Not authenticated'}`);
120
- if (isAuthenticated) {
121
- // Check 3: Token Validation
92
+ // Check API connection
93
+ if (oxyServices) {
122
94
  try {
123
- const isValid = await oxyServices.validate();
124
- if (isValid) {
125
- checks.push('✅ Authentication token is valid');
126
- } else {
127
- checks.push('❌ Authentication token is invalid');
128
- }
95
+ await oxyServices.healthCheck();
96
+ setConnectionStatus('connected');
129
97
  } catch (error) {
130
- checks.push('❌ Token validation failed');
131
- checks.push(` Error: ${error instanceof Error ? error.message : 'Unknown error'}`);
98
+ setConnectionStatus('disconnected');
132
99
  }
133
100
  }
134
-
135
- // Check 4: Session Validation (if user has active sessions)
136
- if (user && sessions && sessions.length > 0) {
137
- checks.push('🔍 Checking active sessions...');
138
- try {
139
- // Just check if we can fetch sessions
140
- const userSessions = await oxyServices.getUserSessions();
141
- checks.push(`✅ Session validation successful (${userSessions.length} sessions)`);
142
- } catch (error) {
143
- checks.push('❌ Session validation failed');
144
- checks.push(` Error: ${error instanceof Error ? error.message : 'Unknown error'}`);
145
- }
146
- }
147
-
148
- // Check 5: Platform Information
149
- checks.push('🔍 Checking platform information...');
150
- checks.push(`✅ Platform: ${_reactNative.Platform.OS} ${_reactNative.Platform.Version || 'Unknown'}`);
151
- checks.push(`✅ Screen: ${systemInfo?.screenDimensions.width || 0}x${systemInfo?.screenDimensions.height || 0}`);
152
- checks.push(`✅ Environment: ${__DEV__ ? 'Development' : 'Production'}`);
153
-
154
- // Check 6: Package Information
155
- checks.push('🔍 Checking package information...');
156
- checks.push(`✅ Package: ${_version.packageInfo.name}@${_version.packageInfo.version}`);
157
-
158
- // Check 7: Memory and Performance (basic)
159
- checks.push('🔍 Checking performance metrics...');
160
- const memoryUsage = performance.memory;
161
- if (memoryUsage) {
162
- const usedMB = Math.round(memoryUsage.usedJSHeapSize / 1024 / 1024);
163
- const totalMB = Math.round(memoryUsage.totalJSHeapSize / 1024 / 1024);
164
- checks.push(`✅ Memory usage: ${usedMB}MB / ${totalMB}MB`);
165
- } else {
166
- checks.push('✅ Performance metrics not available on this platform');
167
- }
168
-
169
- // Final summary
170
- const errorCount = checks.filter(check => check.includes('❌')).length;
171
- const warningCount = checks.filter(check => check.includes('⚠️')).length;
172
- checks.push('');
173
- checks.push('📋 SYSTEM CHECK SUMMARY:');
174
- if (errorCount === 0 && warningCount === 0) {
175
- checks.push('✅ All systems operational');
176
- _sonner.toast.success('System check completed - All systems operational!');
177
- } else if (errorCount === 0) {
178
- checks.push(`⚠️ ${warningCount} warning(s) found`);
179
- _sonner.toast.warning(`System check completed with ${warningCount} warning(s)`);
180
- } else {
181
- checks.push(`❌ ${errorCount} error(s) and ${warningCount} warning(s) found`);
182
- _sonner.toast.error(`System check failed with ${errorCount} error(s)`);
183
- }
184
-
185
- // Show results in an alert and copy to clipboard
186
- const report = checks.join('\n');
187
- (0, _confirmAction.confirmAction)(`Check completed. Results copied to clipboard.\n\nSummary: ${errorCount} errors, ${warningCount} warnings.\n\nCopy full report to clipboard?`, () => copyToClipboard(report, 'System check report'));
101
+ _sonner.toast.success('System check completed successfully');
188
102
  } catch (error) {
189
- _sonner.toast.error('System check failed to run');
190
- console.error('System check error:', error);
103
+ _sonner.toast.error('System check failed');
191
104
  } finally {
192
105
  setIsRunningSystemCheck(false);
193
106
  }
194
107
  };
195
108
  const generateFullReport = () => {
196
109
  const report = {
197
- packageInfo: {
198
- name: _version.packageInfo.name,
199
- version: _version.packageInfo.version,
200
- description: _version.packageInfo.description
201
- },
202
- systemInfo,
203
- userInfo: {
204
- isAuthenticated: !!user,
205
- userId: user?.id || 'Not authenticated',
206
- username: user?.username || 'N/A',
207
- totalUsers: sessions?.length || 0
208
- },
209
- apiConfiguration: {
210
- apiUrl: oxyServices?.getBaseURL() || 'Not configured'
211
- },
212
- buildInfo: {
213
- timestamp: new Date().toISOString(),
214
- environment: __DEV__ ? 'Development' : 'Production'
215
- }
110
+ package: _version.packageInfo,
111
+ system: systemInfo,
112
+ user: user ? {
113
+ id: user.id,
114
+ username: user.username,
115
+ email: user.email,
116
+ isPremium: user.isPremium
117
+ } : null,
118
+ sessions: sessions?.length || 0,
119
+ connection: connectionStatus,
120
+ timestamp: new Date().toISOString()
216
121
  };
217
122
  return JSON.stringify(report, null, 2);
218
123
  };
219
124
  const handleCopyFullReport = () => {
220
125
  const report = generateFullReport();
221
- copyToClipboard(report, 'Full application report');
222
- };
223
- const InfoRow = ({
224
- label,
225
- value,
226
- copyable = false,
227
- icon = 'information-circle',
228
- iconComponent,
229
- color = '#8E8E93',
230
- isFirst = false,
231
- isLast = false,
232
- onPress,
233
- showChevron = false
234
- }) => {
235
- const handlePress = () => {
236
- if (onPress) {
237
- onPress();
238
- } else if (copyable) {
239
- copyToClipboard(value, label);
240
- }
241
- };
242
- const isInteractive = copyable || !!onPress;
243
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
244
- style: [styles.settingItem, isFirst && styles.firstSettingItem, isLast && styles.lastSettingItem],
245
- onPress: isInteractive ? handlePress : undefined,
246
- disabled: !isInteractive,
247
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
248
- style: styles.settingInfo,
249
- children: [iconComponent ? (/*#__PURE__*/_react.default.cloneElement(iconComponent, {
250
- style: styles.settingIcon
251
- })) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
252
- name: icon,
253
- size: 20,
254
- color: color,
255
- style: styles.settingIcon
256
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
257
- style: styles.settingDetails,
258
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
259
- style: styles.settingLabel,
260
- children: label
261
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
262
- style: [styles.settingValue, (copyable || onPress) && {
263
- color: primaryColor
264
- }],
265
- children: value
266
- })]
267
- })]
268
- }), copyable && /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
269
- name: "copy",
270
- size: 16,
271
- color: "#ccc"
272
- }), showChevron && /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
273
- name: "chevron-forward",
274
- size: 16,
275
- color: "#ccc"
276
- })]
277
- });
126
+ copyToClipboard(report, 'Full system report');
278
127
  };
279
128
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
280
129
  style: [styles.container, {
@@ -299,105 +148,119 @@ const AppInfoScreen = ({
299
148
  }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.ScrollView, {
300
149
  style: styles.content,
301
150
  showsVerticalScrollIndicator: false,
302
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
303
- style: styles.section,
304
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
305
- style: styles.sectionTitle,
306
- children: "Package Information"
307
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
308
- label: "Name",
309
- value: _version.packageInfo.name,
310
- copyable: true,
311
- iconComponent: /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyServices.default, {
312
- width: 20,
313
- height: 20
314
- }),
315
- color: "#007AFF",
316
- isFirst: true
317
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
318
- label: "Version",
319
- value: _version.packageInfo.version,
320
- copyable: true,
321
- icon: "pricetag",
322
- color: "#5856D6"
323
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
324
- label: "Description",
325
- value: _version.packageInfo.description || 'No description',
326
- icon: "document-text",
327
- color: "#34C759"
328
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
329
- label: "Main Entry",
330
- value: _version.packageInfo.main || 'N/A',
331
- icon: "code",
332
- color: "#FF9500"
333
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
334
- label: "Module Entry",
335
- value: _version.packageInfo.module || 'N/A',
336
- icon: "library",
337
- color: "#FF3B30"
338
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
339
- label: "Types Entry",
340
- value: _version.packageInfo.types || 'N/A',
341
- icon: "construct",
342
- color: "#32D74B",
343
- isLast: true
344
- })]
345
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
346
- style: styles.section,
347
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
348
- style: styles.sectionTitle,
349
- children: "System Information"
350
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
351
- label: "Platform",
352
- value: _reactNative.Platform.OS,
353
- icon: "phone-portrait",
354
- color: "#007AFF",
355
- isFirst: true
356
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
357
- label: "Platform Version",
358
- value: systemInfo?.version || 'Loading...',
359
- icon: "hardware-chip",
360
- color: "#5856D6"
361
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
362
- label: "Screen Width",
363
- value: `${systemInfo?.screenDimensions.width || 0}px`,
364
- icon: "resize",
365
- color: "#FF9500"
366
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
367
- label: "Screen Height",
368
- value: `${systemInfo?.screenDimensions.height || 0}px`,
369
- icon: "resize",
370
- color: "#FF3B30"
371
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
372
- label: "Environment",
373
- value: __DEV__ ? 'Development' : 'Production',
374
- icon: "settings",
375
- color: "#34C759",
376
- isLast: true
377
- })]
378
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
379
- style: styles.section,
380
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
381
- style: styles.sectionTitle,
382
- children: "User Information"
383
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
384
- label: "Authentication Status",
385
- value: isAuthenticated ? 'Authenticated' : 'Not Authenticated',
386
- icon: "shield-checkmark",
387
- color: isAuthenticated ? '#34C759' : '#FF3B30',
388
- isFirst: true
389
- }), user && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
390
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
391
- label: "User ID",
392
- value: user.id,
393
- copyable: true,
394
- icon: "person",
395
- color: "#007AFF"
396
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
397
- label: "Username",
398
- value: user.username || 'N/A',
399
- icon: "at",
400
- color: "#5856D6",
151
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
152
+ title: "Package Information",
153
+ theme: theme,
154
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
155
+ items: [{
156
+ id: 'name',
157
+ icon: 'information-circle',
158
+ iconColor: '#007AFF',
159
+ title: 'Name',
160
+ subtitle: _version.packageInfo.name,
161
+ onPress: () => copyToClipboard(_version.packageInfo.name, 'Package name'),
162
+ customContent: /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyServices.default, {
163
+ width: 20,
164
+ height: 20,
165
+ style: styles.settingIcon
166
+ })
167
+ }, {
168
+ id: 'version',
169
+ icon: 'pricetag',
170
+ iconColor: '#5856D6',
171
+ title: 'Version',
172
+ subtitle: _version.packageInfo.version,
173
+ onPress: () => copyToClipboard(_version.packageInfo.version, 'Version')
174
+ }, {
175
+ id: 'description',
176
+ icon: 'document-text',
177
+ iconColor: '#34C759',
178
+ title: 'Description',
179
+ subtitle: _version.packageInfo.description || 'No description'
180
+ }, {
181
+ id: 'main-entry',
182
+ icon: 'code',
183
+ iconColor: '#FF9500',
184
+ title: 'Main Entry',
185
+ subtitle: _version.packageInfo.main || 'N/A',
186
+ onPress: () => copyToClipboard(_version.packageInfo.main || 'N/A', 'Main entry')
187
+ }, {
188
+ id: 'module-entry',
189
+ icon: 'library',
190
+ iconColor: '#FF3B30',
191
+ title: 'Module Entry',
192
+ subtitle: _version.packageInfo.module || 'N/A',
193
+ onPress: () => copyToClipboard(_version.packageInfo.module || 'N/A', 'Module entry')
194
+ }, {
195
+ id: 'types-entry',
196
+ icon: 'construct',
197
+ iconColor: '#32D74B',
198
+ title: 'Types Entry',
199
+ subtitle: _version.packageInfo.types || 'N/A',
200
+ onPress: () => copyToClipboard(_version.packageInfo.types || 'N/A', 'Types entry')
201
+ }],
202
+ theme: theme
203
+ })
204
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
205
+ title: "System Information",
206
+ theme: theme,
207
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
208
+ items: [{
209
+ id: 'platform',
210
+ icon: 'phone-portrait',
211
+ iconColor: '#007AFF',
212
+ title: 'Platform',
213
+ subtitle: _reactNative.Platform.OS
214
+ }, {
215
+ id: 'platform-version',
216
+ icon: 'hardware-chip',
217
+ iconColor: '#5856D6',
218
+ title: 'Platform Version',
219
+ subtitle: systemInfo?.version || 'Loading...'
220
+ }, {
221
+ id: 'screen-width',
222
+ icon: 'resize',
223
+ iconColor: '#FF9500',
224
+ title: 'Screen Width',
225
+ subtitle: `${systemInfo?.screenDimensions.width || 0}px`
226
+ }, {
227
+ id: 'screen-height',
228
+ icon: 'resize',
229
+ iconColor: '#FF3B30',
230
+ title: 'Screen Height',
231
+ subtitle: `${systemInfo?.screenDimensions.height || 0}px`
232
+ }, {
233
+ id: 'environment',
234
+ icon: 'settings',
235
+ iconColor: '#34C759',
236
+ title: 'Environment',
237
+ subtitle: __DEV__ ? 'Development' : 'Production'
238
+ }],
239
+ theme: theme
240
+ })
241
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
242
+ title: "User Information",
243
+ theme: theme,
244
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
245
+ items: [{
246
+ id: 'auth-status',
247
+ icon: 'shield-checkmark',
248
+ iconColor: isAuthenticated ? '#34C759' : '#FF3B30',
249
+ title: 'Authentication Status',
250
+ subtitle: isAuthenticated ? 'Authenticated' : 'Not Authenticated'
251
+ }, ...(user ? [{
252
+ id: 'user-id',
253
+ icon: 'person',
254
+ iconColor: '#007AFF',
255
+ title: 'User ID',
256
+ subtitle: user.id,
257
+ onPress: () => copyToClipboard(user.id, 'User ID')
258
+ }, {
259
+ id: 'username',
260
+ icon: 'at',
261
+ iconColor: '#5856D6',
262
+ title: 'Username',
263
+ subtitle: user.username || 'N/A',
401
264
  onPress: () => {
402
265
  if (user?.username && navigate) {
403
266
  navigate('Profile', {
@@ -406,143 +269,119 @@ const AppInfoScreen = ({
406
269
  } else {
407
270
  _sonner.toast.info('No username available or navigation not supported');
408
271
  }
409
- },
410
- showChevron: true
411
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
412
- label: "Email",
413
- value: user.email || 'N/A',
414
- icon: "mail",
415
- color: "#FF9500"
416
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
417
- label: "Premium Status",
418
- value: user.isPremium ? 'Premium' : 'Standard',
419
- icon: "star",
420
- color: user.isPremium ? '#FFD700' : '#8E8E93'
421
- })]
422
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
423
- label: "Total Active Sessions",
424
- value: sessions?.length?.toString() || '0',
425
- icon: "people",
426
- color: "#32D74B",
427
- isLast: true
428
- })]
429
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
430
- style: styles.section,
431
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
432
- style: styles.sectionTitle,
433
- children: "API Configuration"
434
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
435
- label: "API Base URL",
436
- value: oxyServices?.getBaseURL() || 'Not configured',
437
- copyable: true,
438
- icon: "server",
439
- color: "#007AFF",
440
- isFirst: true
441
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
442
- label: "Connection Status",
443
- value: connectionStatus === 'checking' ? 'Checking...' : connectionStatus === 'connected' ? 'Connected' : connectionStatus === 'disconnected' ? 'Disconnected' : 'Unknown',
444
- icon: connectionStatus === 'checking' ? 'sync' : connectionStatus === 'connected' ? 'wifi' : 'wifi-off',
445
- color: connectionStatus === 'checking' ? '#FF9500' : connectionStatus === 'connected' ? '#34C759' : '#FF3B30',
446
- onPress: async () => {
447
- setConnectionStatus('checking');
448
- if (!oxyServices) {
449
- setConnectionStatus('disconnected');
450
- _sonner.toast.error('OxyServices not initialized');
451
- return;
452
272
  }
453
- try {
454
- await oxyServices.healthCheck();
455
- setConnectionStatus('connected');
456
- _sonner.toast.success('API connection successful');
457
- } catch (error) {
458
- setConnectionStatus('disconnected');
459
- _sonner.toast.error('Failed to connect to API server');
273
+ }, {
274
+ id: 'email',
275
+ icon: 'mail',
276
+ iconColor: '#FF9500',
277
+ title: 'Email',
278
+ subtitle: user.email || 'N/A'
279
+ }, {
280
+ id: 'premium-status',
281
+ icon: 'star',
282
+ iconColor: user.isPremium ? '#FFD700' : '#8E8E93',
283
+ title: 'Premium Status',
284
+ subtitle: user.isPremium ? 'Premium' : 'Standard'
285
+ }] : []), {
286
+ id: 'active-sessions',
287
+ icon: 'people',
288
+ iconColor: '#32D74B',
289
+ title: 'Total Active Sessions',
290
+ subtitle: sessions?.length?.toString() || '0'
291
+ }],
292
+ theme: theme
293
+ })
294
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
295
+ title: "API Configuration",
296
+ theme: theme,
297
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
298
+ items: [{
299
+ id: 'api-base-url',
300
+ icon: 'server',
301
+ iconColor: '#007AFF',
302
+ title: 'API Base URL',
303
+ subtitle: oxyServices?.getBaseURL() || 'Not configured',
304
+ onPress: () => copyToClipboard(oxyServices?.getBaseURL() || 'Not configured', 'API Base URL')
305
+ }, {
306
+ id: 'connection-status',
307
+ icon: connectionStatus === 'checking' ? 'sync' : connectionStatus === 'connected' ? 'wifi' : 'wifi-off',
308
+ iconColor: connectionStatus === 'checking' ? '#FF9500' : connectionStatus === 'connected' ? '#34C759' : '#FF3B30',
309
+ title: 'Connection Status',
310
+ subtitle: connectionStatus === 'checking' ? 'Checking...' : connectionStatus === 'connected' ? 'Connected' : connectionStatus === 'disconnected' ? 'Disconnected' : 'Unknown',
311
+ onPress: async () => {
312
+ setConnectionStatus('checking');
313
+ if (!oxyServices) {
314
+ setConnectionStatus('disconnected');
315
+ _sonner.toast.error('OxyServices not initialized');
316
+ return;
317
+ }
318
+ try {
319
+ await oxyServices.healthCheck();
320
+ setConnectionStatus('connected');
321
+ _sonner.toast.success('API connection successful');
322
+ } catch (error) {
323
+ setConnectionStatus('disconnected');
324
+ _sonner.toast.error('Failed to connect to API server');
325
+ }
460
326
  }
461
- },
462
- showChevron: true,
463
- isLast: true
464
- })]
465
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
466
- style: styles.section,
467
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
468
- style: styles.sectionTitle,
469
- children: "Build Information"
470
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
471
- label: "Build Timestamp",
472
- value: systemInfo?.timestamp || 'Loading...',
473
- copyable: true,
474
- icon: "time",
475
- color: "#007AFF",
476
- isFirst: true
477
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
478
- label: "React Native",
479
- value: "Expo/React Native",
480
- icon: "logo-react",
481
- color: "#61DAFB"
482
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(InfoRow, {
483
- label: "JavaScript Engine",
484
- value: "Hermes",
485
- icon: "flash",
486
- color: "#FF3B30",
487
- isLast: true
488
- })]
489
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
490
- style: styles.section,
491
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
492
- style: styles.sectionTitle,
493
- children: "Quick Actions"
494
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
495
- style: [styles.settingItem, styles.firstSettingItem],
496
- onPress: handleCopyFullReport,
497
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
498
- style: styles.settingInfo,
499
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
500
- name: "copy",
501
- size: 20,
502
- color: "#007AFF",
503
- style: styles.settingIcon
504
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
505
- style: styles.settingDetails,
506
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
507
- style: styles.settingLabel,
508
- children: "Copy Full Report"
509
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
510
- style: styles.settingDescription,
511
- children: "Copy complete application information to clipboard"
512
- })]
513
- })]
514
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
515
- name: "chevron-forward",
516
- size: 16,
517
- color: "#ccc"
518
- })]
519
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
520
- style: [styles.settingItem, styles.lastSettingItem, isRunningSystemCheck && styles.disabledSettingItem],
521
- onPress: runSystemCheck,
522
- disabled: isRunningSystemCheck,
523
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
524
- style: styles.settingInfo,
525
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
526
- name: isRunningSystemCheck ? "sync" : "checkmark-circle",
527
- size: 20,
528
- color: isRunningSystemCheck ? "#FF9500" : "#34C759",
529
- style: [styles.settingIcon, isRunningSystemCheck && styles.spinningIcon]
530
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
531
- style: styles.settingDetails,
532
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
533
- style: styles.settingLabel,
534
- children: isRunningSystemCheck ? 'Running System Check...' : 'Run System Check'
535
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
536
- style: styles.settingDescription,
537
- children: isRunningSystemCheck ? 'Checking API, authentication, and platform status...' : 'Verify application health and status'
538
- })]
539
- })]
540
- }), !isRunningSystemCheck && /*#__PURE__*/(0, _jsxRuntime.jsx)(_OxyIcon.default, {
541
- name: "chevron-forward",
542
- size: 16,
543
- color: "#ccc"
544
- })]
545
- })]
327
+ }],
328
+ theme: theme
329
+ })
330
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
331
+ title: "Build Information",
332
+ theme: theme,
333
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
334
+ items: [{
335
+ id: 'build-timestamp',
336
+ icon: 'time',
337
+ iconColor: '#007AFF',
338
+ title: 'Build Timestamp',
339
+ subtitle: systemInfo?.timestamp || 'Loading...',
340
+ onPress: () => copyToClipboard(systemInfo?.timestamp || 'Loading...', 'Build timestamp')
341
+ }, {
342
+ id: 'react-native',
343
+ icon: 'logo-react',
344
+ iconColor: '#61DAFB',
345
+ title: 'React Native',
346
+ subtitle: 'Expo/React Native'
347
+ }, {
348
+ id: 'js-engine',
349
+ icon: 'flash',
350
+ iconColor: '#FF3B30',
351
+ title: 'JavaScript Engine',
352
+ subtitle: 'Hermes'
353
+ }],
354
+ theme: theme
355
+ })
356
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.Section, {
357
+ title: "Quick Actions",
358
+ theme: theme,
359
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_components.GroupedSection, {
360
+ items: [{
361
+ id: 'copy-full-report',
362
+ icon: 'copy',
363
+ iconColor: '#007AFF',
364
+ title: 'Copy Full Report',
365
+ subtitle: 'Copy complete application information to clipboard',
366
+ onPress: handleCopyFullReport
367
+ }, {
368
+ id: 'run-system-check',
369
+ icon: isRunningSystemCheck ? 'sync' : 'checkmark-circle',
370
+ iconColor: isRunningSystemCheck ? '#FF9500' : '#34C759',
371
+ title: isRunningSystemCheck ? 'Running System Check...' : 'Run System Check',
372
+ subtitle: isRunningSystemCheck ? 'Checking API, authentication, and platform status...' : 'Verify application health and status',
373
+ onPress: runSystemCheck,
374
+ disabled: isRunningSystemCheck,
375
+ customContent: isRunningSystemCheck ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ActivityIndicator, {
376
+ color: "#FF9500",
377
+ size: "small",
378
+ style: {
379
+ marginRight: 16
380
+ }
381
+ }) : null
382
+ }],
383
+ theme: theme
384
+ })
546
385
  })]
547
386
  })]
548
387
  });
@@ -575,64 +414,8 @@ const styles = _reactNative.StyleSheet.create({
575
414
  flex: 1,
576
415
  padding: 16
577
416
  },
578
- section: {
579
- marginBottom: 24
580
- },
581
- sectionTitle: {
582
- fontSize: 16,
583
- fontWeight: '600',
584
- color: '#333',
585
- marginBottom: 12,
586
- fontFamily: _fonts.fontFamilies.phuduSemiBold
587
- },
588
- settingItem: {
589
- backgroundColor: '#fff',
590
- padding: 16,
591
- flexDirection: 'row',
592
- alignItems: 'center',
593
- justifyContent: 'space-between',
594
- marginBottom: 2
595
- },
596
- firstSettingItem: {
597
- borderTopLeftRadius: 24,
598
- borderTopRightRadius: 24
599
- },
600
- lastSettingItem: {
601
- borderBottomLeftRadius: 24,
602
- borderBottomRightRadius: 24,
603
- marginBottom: 8
604
- },
605
- settingInfo: {
606
- flexDirection: 'row',
607
- alignItems: 'center',
608
- flex: 1
609
- },
610
417
  settingIcon: {
611
418
  marginRight: 12
612
- },
613
- settingDetails: {
614
- flex: 1
615
- },
616
- settingLabel: {
617
- fontSize: 16,
618
- fontWeight: '500',
619
- color: '#333',
620
- marginBottom: 2
621
- },
622
- settingValue: {
623
- fontSize: 14,
624
- color: '#666'
625
- },
626
- settingDescription: {
627
- fontSize: 14,
628
- color: '#999'
629
- },
630
- disabledSettingItem: {
631
- opacity: 0.6
632
- },
633
- spinningIcon: {
634
- // Note: Animation would need to be implemented with Animated API
635
- // For now, just showing the sync icon to indicate loading
636
419
  }
637
420
  });
638
421
  var _default = exports.default = AppInfoScreen;