react-native-inapp-inspector 2.3.19 → 2.3.21

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 (353) hide show
  1. package/README.md +14 -14
  2. package/android/src/main/java/com/inappinspector/NetworkInspectorModule.kt +67 -0
  3. package/dist/commonjs/analytics.js +1 -24
  4. package/dist/commonjs/bundle.js +1 -16
  5. package/dist/commonjs/capture.js +1 -35
  6. package/dist/commonjs/components/AnalyticsDetail.js +92 -623
  7. package/dist/commonjs/components/AnalyticsEventCard.js +54 -350
  8. package/dist/commonjs/components/AnalyticsGraph.js +70 -370
  9. package/dist/commonjs/components/AnimatedEntrance.js +1 -11
  10. package/dist/commonjs/components/AppHeaderLogo.js +7 -134
  11. package/dist/commonjs/components/BrandCircleIcon.js +73 -118
  12. package/dist/commonjs/components/BrandSquareIcon.js +63 -108
  13. package/dist/commonjs/components/CodeSnippet.js +48 -623
  14. package/dist/commonjs/components/ConsoleLogCard.js +63 -537
  15. package/dist/commonjs/components/CopyButton.js +3 -89
  16. package/dist/commonjs/components/DiffViewer.js +19 -83
  17. package/dist/commonjs/components/DomainHeader.js +27 -127
  18. package/dist/commonjs/components/EmptyState.js +10 -87
  19. package/dist/commonjs/components/EndOfListFooter.js +7 -81
  20. package/dist/commonjs/components/ErrorBoundary.js +72 -566
  21. package/dist/commonjs/components/HeadersSection.js +31 -110
  22. package/dist/commonjs/components/HighlightText.js +17 -58
  23. package/dist/commonjs/components/Inspector/AboutModal.d.ts +6 -0
  24. package/dist/commonjs/components/Inspector/AboutModal.js +243 -0
  25. package/dist/commonjs/components/Inspector/AnalyticsFilterModal.js +98 -797
  26. package/dist/commonjs/components/Inspector/AnalyticsTab.js +284 -930
  27. package/dist/commonjs/components/Inspector/BundleTab.js +551 -2918
  28. package/dist/commonjs/components/Inspector/ConsoleTab.js +79 -492
  29. package/dist/commonjs/components/Inspector/CrashDetail.js +123 -672
  30. package/dist/commonjs/components/Inspector/CrashFilterModal.js +66 -498
  31. package/dist/commonjs/components/Inspector/CrashTab.js +98 -670
  32. package/dist/commonjs/components/Inspector/DebuggingTab.js +74 -875
  33. package/dist/commonjs/components/Inspector/DeviceInfoTab.js +143 -907
  34. package/dist/commonjs/components/Inspector/FabLauncher.js +42 -466
  35. package/dist/commonjs/components/Inspector/FeatureUnderDevNotice.js +6 -99
  36. package/dist/commonjs/components/Inspector/InspectorContext.js +1 -21
  37. package/dist/commonjs/components/Inspector/InspectorHeader.js +191 -1110
  38. package/dist/commonjs/components/Inspector/LogDetail.js +168 -994
  39. package/dist/commonjs/components/Inspector/MainScreen.js +52 -335
  40. package/dist/commonjs/components/Inspector/MediaGalleryTab.js +97 -644
  41. package/dist/commonjs/components/Inspector/MediaPreviewModal.js +90 -605
  42. package/dist/commonjs/components/Inspector/NavigationTracker.js +1 -12
  43. package/dist/commonjs/components/Inspector/NetworkDetail.js +89 -411
  44. package/dist/commonjs/components/Inspector/NetworkFilterModal.js +60 -576
  45. package/dist/commonjs/components/Inspector/NetworkTab.js +84 -514
  46. package/dist/commonjs/components/Inspector/NpmStarPrompt.js +18 -434
  47. package/dist/commonjs/components/Inspector/NpmUpdateToast.js +25 -298
  48. package/dist/commonjs/components/Inspector/PerformanceTab.js +182 -1397
  49. package/dist/commonjs/components/Inspector/ReduxDetail.js +188 -1089
  50. package/dist/commonjs/components/Inspector/ReduxTab.js +85 -701
  51. package/dist/commonjs/components/Inspector/SettingsPanel.js +427 -3807
  52. package/dist/commonjs/components/Inspector/SkeletonPlaceholder.js +11 -180
  53. package/dist/commonjs/components/Inspector/StorageTab.js +93 -826
  54. package/dist/commonjs/components/Inspector/TabBar.js +36 -334
  55. package/dist/commonjs/components/Inspector/UpdateAvailableModal.js +37 -412
  56. package/dist/commonjs/components/JsonViewer.js +168 -381
  57. package/dist/commonjs/components/LogCard.js +57 -567
  58. package/dist/commonjs/components/LogSyntaxHighlighter.js +11 -130
  59. package/dist/commonjs/components/MetaAccordion.js +69 -238
  60. package/dist/commonjs/components/MiniBarChart.js +3 -56
  61. package/dist/commonjs/components/MiniLineChart.js +3 -58
  62. package/dist/commonjs/components/NetworkIcons.d.ts +13 -0
  63. package/dist/commonjs/components/NetworkIcons.js +521 -1022
  64. package/dist/commonjs/components/QRCodeView.js +5 -79
  65. package/dist/commonjs/components/SectionHeader.js +15 -37
  66. package/dist/commonjs/components/SegmentedTabs.js +7 -62
  67. package/dist/commonjs/components/SkeletonPlaceholder.js +11 -180
  68. package/dist/commonjs/components/Slider.js +15 -243
  69. package/dist/commonjs/components/SourcePageCard.js +30 -89
  70. package/dist/commonjs/components/Toast.js +5 -147
  71. package/dist/commonjs/components/TouchableScale.js +3 -24
  72. package/dist/commonjs/components/TreeNode.js +55 -130
  73. package/dist/commonjs/console.js +1 -16
  74. package/dist/commonjs/constants/index.js +1 -32
  75. package/dist/commonjs/constants/telemetryConfig.js +1 -6
  76. package/dist/commonjs/constants/version.d.ts +1 -1
  77. package/dist/commonjs/constants/version.js +1 -4
  78. package/dist/commonjs/crash.js +1 -23
  79. package/dist/commonjs/customHooks/analyticsLogger.js +1 -250
  80. package/dist/commonjs/customHooks/bundleAnalyzer.js +1 -957
  81. package/dist/commonjs/customHooks/consoleLogger.js +6 -445
  82. package/dist/commonjs/customHooks/crashHandler.js +7 -656
  83. package/dist/commonjs/customHooks/logFilters.js +1 -23
  84. package/dist/commonjs/customHooks/networkLogger.js +2 -536
  85. package/dist/commonjs/customHooks/performanceTracker.js +63 -750
  86. package/dist/commonjs/customHooks/reduxLogger.js +2 -313
  87. package/dist/commonjs/customHooks/storageInspector.js +1 -435
  88. package/dist/commonjs/customHooks/useAccordion.js +1 -18
  89. package/dist/commonjs/decorators/index.js +1 -100
  90. package/dist/commonjs/helpers/gaAnalyticsRegistry.js +1 -148
  91. package/dist/commonjs/helpers/index.d.ts +1 -0
  92. package/dist/commonjs/helpers/index.js +8 -921
  93. package/dist/commonjs/helpers/memoryManager.js +1 -99
  94. package/dist/commonjs/helpers/qrGenerator.js +1 -367
  95. package/dist/commonjs/helpers/remoteConfig.js +1 -165
  96. package/dist/commonjs/helpers/searchQueryParser.js +1 -62
  97. package/dist/commonjs/helpers/settingsStore.js +1 -144
  98. package/dist/commonjs/helpers/telemetry.js +1 -501
  99. package/dist/commonjs/helpers/toast.js +1 -20
  100. package/dist/commonjs/i18n/index.js +1 -90
  101. package/dist/commonjs/i18n/locales/en.json +1 -1140
  102. package/dist/commonjs/index.js +5 -2168
  103. package/dist/commonjs/metro.js +6 -468
  104. package/dist/commonjs/native/NativeInspector.d.ts +1 -0
  105. package/dist/commonjs/native/NativeInspector.js +1 -415
  106. package/dist/commonjs/native/NativeNetworkInspector.js +1 -4
  107. package/dist/commonjs/network.js +1 -13
  108. package/dist/commonjs/performance.js +1 -29
  109. package/dist/commonjs/redux.js +1 -20
  110. package/dist/commonjs/storage.js +1 -14
  111. package/dist/commonjs/styles/AppColors.js +1 -423
  112. package/dist/commonjs/styles/AppFonts.js +1 -17
  113. package/dist/commonjs/styles/common.js +1 -190
  114. package/dist/commonjs/styles/index.d.ts +6 -0
  115. package/dist/commonjs/styles/index.js +1 -1589
  116. package/dist/commonjs/types/enums.d.ts +0 -1
  117. package/dist/commonjs/types/enums.js +1 -152
  118. package/dist/commonjs/types/index.js +1 -18
  119. package/dist/commonjs/types/interfaces.d.ts +2 -2
  120. package/dist/commonjs/types/interfaces.js +1 -2
  121. package/dist/esm/analytics.js +1 -2
  122. package/dist/esm/bundle.js +1 -2
  123. package/dist/esm/capture.js +1 -32
  124. package/dist/esm/components/AnalyticsDetail.js +171 -664
  125. package/dist/esm/components/AnalyticsEventCard.js +77 -335
  126. package/dist/esm/components/AnalyticsGraph.js +95 -357
  127. package/dist/esm/components/AnimatedEntrance.js +1 -6
  128. package/dist/esm/components/AppHeaderLogo.js +7 -94
  129. package/dist/esm/components/BrandCircleIcon.js +114 -119
  130. package/dist/esm/components/BrandSquareIcon.js +73 -78
  131. package/dist/esm/components/CodeSnippet.js +58 -595
  132. package/dist/esm/components/ConsoleLogCard.js +91 -526
  133. package/dist/esm/components/CopyButton.js +3 -51
  134. package/dist/esm/components/DiffViewer.js +22 -48
  135. package/dist/esm/components/DomainHeader.js +43 -138
  136. package/dist/esm/components/EmptyState.js +17 -56
  137. package/dist/esm/components/EndOfListFooter.js +15 -83
  138. package/dist/esm/components/ErrorBoundary.js +125 -582
  139. package/dist/esm/components/HeadersSection.js +52 -93
  140. package/dist/esm/components/HighlightText.js +17 -53
  141. package/dist/esm/components/Inspector/AboutModal.d.ts +6 -0
  142. package/dist/esm/components/Inspector/AboutModal.js +243 -0
  143. package/dist/esm/components/Inspector/AnalyticsFilterModal.js +225 -886
  144. package/dist/esm/components/Inspector/AnalyticsTab.js +296 -904
  145. package/dist/esm/components/Inspector/BundleTab.js +1175 -3502
  146. package/dist/esm/components/Inspector/ConsoleTab.js +113 -488
  147. package/dist/esm/components/Inspector/CrashDetail.js +236 -747
  148. package/dist/esm/components/Inspector/CrashFilterModal.js +149 -541
  149. package/dist/esm/components/Inspector/CrashTab.js +177 -711
  150. package/dist/esm/components/Inspector/DebuggingTab.js +164 -925
  151. package/dist/esm/components/Inspector/DeviceInfoTab.js +199 -924
  152. package/dist/esm/components/Inspector/FabLauncher.js +68 -454
  153. package/dist/esm/components/Inspector/FeatureUnderDevNotice.js +14 -70
  154. package/dist/esm/components/Inspector/InspectorContext.js +1 -12
  155. package/dist/esm/components/Inspector/InspectorHeader.js +282 -1163
  156. package/dist/esm/components/Inspector/LogDetail.js +235 -1023
  157. package/dist/esm/components/Inspector/MainScreen.js +78 -323
  158. package/dist/esm/components/Inspector/MediaGalleryTab.js +143 -650
  159. package/dist/esm/components/Inspector/MediaPreviewModal.js +138 -613
  160. package/dist/esm/components/Inspector/NavigationTracker.js +1 -10
  161. package/dist/esm/components/Inspector/NetworkDetail.js +138 -455
  162. package/dist/esm/components/Inspector/NetworkFilterModal.js +122 -597
  163. package/dist/esm/components/Inspector/NetworkTab.js +125 -517
  164. package/dist/esm/components/Inspector/NpmStarPrompt.js +58 -434
  165. package/dist/esm/components/Inspector/NpmUpdateToast.js +45 -281
  166. package/dist/esm/components/Inspector/PerformanceTab.js +393 -1570
  167. package/dist/esm/components/Inspector/ReduxDetail.js +307 -1170
  168. package/dist/esm/components/Inspector/ReduxTab.js +144 -722
  169. package/dist/esm/components/Inspector/SettingsPanel.js +643 -3985
  170. package/dist/esm/components/Inspector/SkeletonPlaceholder.js +30 -163
  171. package/dist/esm/components/Inspector/StorageTab.js +172 -866
  172. package/dist/esm/components/Inspector/TabBar.js +45 -305
  173. package/dist/esm/components/Inspector/UpdateAvailableModal.js +80 -418
  174. package/dist/esm/components/JsonViewer.js +179 -354
  175. package/dist/esm/components/LogCard.js +93 -565
  176. package/dist/esm/components/LogSyntaxHighlighter.js +11 -123
  177. package/dist/esm/components/MetaAccordion.js +136 -267
  178. package/dist/esm/components/MiniBarChart.js +3 -18
  179. package/dist/esm/components/MiniLineChart.js +3 -20
  180. package/dist/esm/components/NetworkIcons.d.ts +13 -0
  181. package/dist/esm/components/NetworkIcons.js +523 -838
  182. package/dist/esm/components/QRCodeView.js +8 -45
  183. package/dist/esm/components/SectionHeader.js +22 -39
  184. package/dist/esm/components/SegmentedTabs.js +8 -58
  185. package/dist/esm/components/SkeletonPlaceholder.js +30 -163
  186. package/dist/esm/components/Slider.js +24 -213
  187. package/dist/esm/components/SourcePageCard.js +65 -86
  188. package/dist/esm/components/Toast.js +10 -117
  189. package/dist/esm/components/TouchableScale.js +3 -19
  190. package/dist/esm/components/TreeNode.js +58 -95
  191. package/dist/esm/console.js +1 -2
  192. package/dist/esm/constants/index.js +1 -28
  193. package/dist/esm/constants/telemetryConfig.js +1 -3
  194. package/dist/esm/constants/version.d.ts +1 -1
  195. package/dist/esm/constants/version.js +1 -1
  196. package/dist/esm/crash.js +1 -2
  197. package/dist/esm/customHooks/analyticsLogger.js +1 -230
  198. package/dist/esm/customHooks/bundleAnalyzer.js +1 -944
  199. package/dist/esm/customHooks/consoleLogger.js +6 -432
  200. package/dist/esm/customHooks/crashHandler.js +7 -630
  201. package/dist/esm/customHooks/logFilters.js +1 -20
  202. package/dist/esm/customHooks/networkLogger.js +2 -519
  203. package/dist/esm/customHooks/performanceTracker.js +63 -723
  204. package/dist/esm/customHooks/reduxLogger.js +2 -293
  205. package/dist/esm/customHooks/storageInspector.js +1 -418
  206. package/dist/esm/customHooks/useAccordion.js +1 -16
  207. package/dist/esm/decorators/index.js +1 -95
  208. package/dist/esm/helpers/gaAnalyticsRegistry.js +1 -143
  209. package/dist/esm/helpers/index.d.ts +1 -0
  210. package/dist/esm/helpers/index.js +8 -861
  211. package/dist/esm/helpers/memoryManager.js +1 -91
  212. package/dist/esm/helpers/qrGenerator.js +1 -364
  213. package/dist/esm/helpers/remoteConfig.js +1 -160
  214. package/dist/esm/helpers/searchQueryParser.js +1 -59
  215. package/dist/esm/helpers/settingsStore.js +1 -134
  216. package/dist/esm/helpers/telemetry.js +1 -489
  217. package/dist/esm/helpers/toast.js +1 -15
  218. package/dist/esm/i18n/index.js +1 -78
  219. package/dist/esm/i18n/locales/en.json +1 -1140
  220. package/dist/esm/index.js +7 -1982
  221. package/dist/esm/metro.js +6 -459
  222. package/dist/esm/native/NativeInspector.d.ts +1 -0
  223. package/dist/esm/native/NativeInspector.js +1 -382
  224. package/dist/esm/native/NativeNetworkInspector.js +1 -2
  225. package/dist/esm/network.js +1 -1
  226. package/dist/esm/performance.js +1 -2
  227. package/dist/esm/redux.js +1 -1
  228. package/dist/esm/storage.js +1 -1
  229. package/dist/esm/styles/AppColors.js +1 -417
  230. package/dist/esm/styles/AppFonts.js +1 -13
  231. package/dist/esm/styles/common.js +1 -186
  232. package/dist/esm/styles/index.d.ts +6 -0
  233. package/dist/esm/styles/index.js +1 -1551
  234. package/dist/esm/types/enums.d.ts +0 -1
  235. package/dist/esm/types/enums.js +1 -149
  236. package/dist/esm/types/index.js +1 -2
  237. package/dist/esm/types/interfaces.d.ts +2 -2
  238. package/dist/esm/types/interfaces.js +1 -1
  239. package/ios/NetworkInspectorModule.mm +60 -12
  240. package/package.json +5 -3
  241. package/src/native/NativeInspector.ts +18 -0
  242. package/dist/commonjs/components/Inspector/FeedbackModal.d.ts +0 -7
  243. package/dist/commonjs/components/Inspector/FeedbackModal.js +0 -552
  244. package/dist/esm/components/Inspector/FeedbackModal.d.ts +0 -7
  245. package/dist/esm/components/Inspector/FeedbackModal.js +0 -515
  246. package/src/analytics.ts +0 -35
  247. package/src/bundle.ts +0 -25
  248. package/src/capture.ts +0 -109
  249. package/src/components/AnalyticsDetail.tsx +0 -870
  250. package/src/components/AnalyticsEventCard.tsx +0 -444
  251. package/src/components/AnalyticsGraph.tsx +0 -583
  252. package/src/components/AnimatedEntrance.tsx +0 -20
  253. package/src/components/AppHeaderLogo.tsx +0 -143
  254. package/src/components/BrandCircleIcon.tsx +0 -144
  255. package/src/components/BrandSquareIcon.tsx +0 -184
  256. package/src/components/CodeSnippet.tsx +0 -725
  257. package/src/components/ConsoleLogCard.tsx +0 -679
  258. package/src/components/CopyButton.tsx +0 -87
  259. package/src/components/DiffViewer.tsx +0 -82
  260. package/src/components/DomainHeader.tsx +0 -224
  261. package/src/components/EmptyState.tsx +0 -97
  262. package/src/components/EndOfListFooter.tsx +0 -100
  263. package/src/components/ErrorBoundary.tsx +0 -688
  264. package/src/components/HeadersSection.tsx +0 -172
  265. package/src/components/HighlightText.tsx +0 -100
  266. package/src/components/Inspector/AnalyticsFilterModal.tsx +0 -1250
  267. package/src/components/Inspector/AnalyticsTab.tsx +0 -1362
  268. package/src/components/Inspector/BundleTab.tsx +0 -4768
  269. package/src/components/Inspector/ConsoleTab.tsx +0 -726
  270. package/src/components/Inspector/CrashDetail.tsx +0 -997
  271. package/src/components/Inspector/CrashFilterModal.tsx +0 -721
  272. package/src/components/Inspector/CrashTab.tsx +0 -933
  273. package/src/components/Inspector/DebuggingTab.tsx +0 -1103
  274. package/src/components/Inspector/DeviceInfoTab.tsx +0 -1397
  275. package/src/components/Inspector/FabLauncher.tsx +0 -590
  276. package/src/components/Inspector/FeatureUnderDevNotice.tsx +0 -94
  277. package/src/components/Inspector/FeedbackModal.tsx +0 -626
  278. package/src/components/Inspector/InspectorContext.tsx +0 -28
  279. package/src/components/Inspector/InspectorHeader.tsx +0 -1583
  280. package/src/components/Inspector/LogDetail.tsx +0 -1431
  281. package/src/components/Inspector/MainScreen.tsx +0 -460
  282. package/src/components/Inspector/MediaGalleryTab.tsx +0 -829
  283. package/src/components/Inspector/MediaPreviewModal.tsx +0 -783
  284. package/src/components/Inspector/NavigationTracker.tsx +0 -13
  285. package/src/components/Inspector/NetworkDetail.tsx +0 -778
  286. package/src/components/Inspector/NetworkFilterModal.tsx +0 -730
  287. package/src/components/Inspector/NetworkTab.tsx +0 -820
  288. package/src/components/Inspector/NpmStarPrompt.tsx +0 -532
  289. package/src/components/Inspector/NpmUpdateToast.tsx +0 -387
  290. package/src/components/Inspector/PerformanceTab.tsx +0 -1967
  291. package/src/components/Inspector/ReduxDetail.tsx +0 -1651
  292. package/src/components/Inspector/ReduxTab.tsx +0 -987
  293. package/src/components/Inspector/SettingsPanel.tsx +0 -5136
  294. package/src/components/Inspector/SkeletonPlaceholder.tsx +0 -206
  295. package/src/components/Inspector/StorageTab.tsx +0 -1159
  296. package/src/components/Inspector/TabBar.tsx +0 -431
  297. package/src/components/Inspector/UpdateAvailableModal.tsx +0 -555
  298. package/src/components/JsonViewer.tsx +0 -549
  299. package/src/components/LogCard.tsx +0 -694
  300. package/src/components/LogSyntaxHighlighter.tsx +0 -178
  301. package/src/components/MetaAccordion.tsx +0 -355
  302. package/src/components/MiniBarChart.tsx +0 -42
  303. package/src/components/MiniLineChart.tsx +0 -33
  304. package/src/components/NetworkIcons.tsx +0 -2655
  305. package/src/components/QRCodeView.tsx +0 -75
  306. package/src/components/SectionHeader.tsx +0 -101
  307. package/src/components/SegmentedTabs.tsx +0 -84
  308. package/src/components/SkeletonPlaceholder.tsx +0 -206
  309. package/src/components/Slider.tsx +0 -300
  310. package/src/components/SourcePageCard.tsx +0 -150
  311. package/src/components/Toast.tsx +0 -131
  312. package/src/components/TouchableScale.tsx +0 -61
  313. package/src/components/TreeNode.tsx +0 -171
  314. package/src/console.ts +0 -24
  315. package/src/constants/index.ts +0 -41
  316. package/src/constants/telemetryConfig.ts +0 -4
  317. package/src/constants/version.ts +0 -3
  318. package/src/crash.ts +0 -32
  319. package/src/customHooks/analyticsLogger.ts +0 -336
  320. package/src/customHooks/bundleAnalyzer.ts +0 -1256
  321. package/src/customHooks/consoleLogger.ts +0 -530
  322. package/src/customHooks/crashHandler.ts +0 -944
  323. package/src/customHooks/logFilters.ts +0 -32
  324. package/src/customHooks/networkLogger.ts +0 -624
  325. package/src/customHooks/performanceTracker.ts +0 -1014
  326. package/src/customHooks/reduxLogger.ts +0 -406
  327. package/src/customHooks/storageInspector.ts +0 -513
  328. package/src/customHooks/useAccordion.tsx +0 -27
  329. package/src/decorators/index.ts +0 -184
  330. package/src/helpers/gaAnalyticsRegistry.ts +0 -204
  331. package/src/helpers/index.ts +0 -1092
  332. package/src/helpers/memoryManager.ts +0 -138
  333. package/src/helpers/qrGenerator.ts +0 -430
  334. package/src/helpers/remoteConfig.ts +0 -212
  335. package/src/helpers/searchQueryParser.ts +0 -84
  336. package/src/helpers/settingsStore.ts +0 -171
  337. package/src/helpers/telemetry.ts +0 -568
  338. package/src/helpers/toast.ts +0 -17
  339. package/src/i18n/index.ts +0 -104
  340. package/src/i18n/locales/en.json +0 -1141
  341. package/src/index.tsx +0 -2650
  342. package/src/metro.ts +0 -598
  343. package/src/network.ts +0 -22
  344. package/src/performance.ts +0 -38
  345. package/src/redux.ts +0 -23
  346. package/src/storage.ts +0 -18
  347. package/src/styles/AppColors.ts +0 -455
  348. package/src/styles/AppFonts.ts +0 -26
  349. package/src/styles/common.ts +0 -209
  350. package/src/styles/index.ts +0 -1606
  351. package/src/types/enums.ts +0 -210
  352. package/src/types/index.ts +0 -34
  353. package/src/types/interfaces.ts +0 -535
@@ -1,899 +1,205 @@
1
- import React, { useState, useEffect, useMemo, useCallback, useRef } from 'react';
2
- import { View, Text, ScrollView, FlatList, TextInput, Modal, Alert, StyleSheet, ActivityIndicator, Platform, } from 'react-native';
3
- import TouchableScale from '../TouchableScale';
4
- import { AppColors } from '../../styles/AppColors';
5
- import { AppFonts } from '../../styles/AppFonts';
6
- import { useTranslation } from '../../i18n';
7
- import { DatabaseIcon, SearchIcon, ClearIcon, PlusIcon, PencilIcon, TrashIcon, CopyIcon, CheckIcon, LayersIcon, ResetIcon, ChevronIcon, WarningTriangleIcon, } from '../NetworkIcons';
8
- import { fetchStorageEntries, setStorageEntry, removeStorageEntry, clearStorageDriver, isAsyncStorageConnected, isMMKVConnected, getRegisteredMMKVInstanceIds, subscribeToStorageChanges, } from '../../customHooks/storageInspector';
9
- import { copyToClipboard } from '../../helpers';
10
- import { showToast } from '../../helpers/toast';
11
- const getTypeBadge = (type) => {
12
- switch (type) {
13
- case 'json':
14
- return { label: 'JSON', color: AppColors.purple, bg: `${AppColors.purple}16` };
15
- case 'number':
16
- return { label: 'NUM', color: AppColors.warningIconGold, bg: `${AppColors.warningIconGold}16` };
17
- case 'boolean':
18
- return { label: 'BOOL', color: AppColors.emerald500, bg: `${AppColors.emerald500}16` };
19
- case 'null':
20
- return { label: 'NULL', color: AppColors.grayTextWeak, bg: `${AppColors.grayTextWeak}16` };
21
- default:
22
- return { label: 'STR', color: AppColors.blue500, bg: `${AppColors.blue500}16` };
23
- }
24
- };
25
- const StorageEntryCard = React.memo(function StorageEntryCard({ entry, isExpanded, onToggleExpand, onCopy, onEdit, onDelete, badge, }) {
26
- const formattedBytes = useMemo(() => {
27
- return entry.byteSize < 1024
28
- ? `${entry.byteSize} B`
29
- : `${(entry.byteSize / 1024).toFixed(1)} KB`;
30
- }, [entry.byteSize]);
31
- const displayValue = useMemo(() => {
32
- if (!isExpanded) {
33
- if (entry.value.length > 250) {
34
- return entry.value.slice(0, 250) + '...';
35
- }
36
- return entry.value;
37
- }
38
- if (entry.type === 'json') {
39
- try {
40
- const parsed = entry.parsedValue ?? JSON.parse(entry.value);
41
- return JSON.stringify(parsed, null, 2);
42
- }
43
- catch {
44
- return entry.value;
45
- }
46
- }
47
- return entry.value;
48
- }, [isExpanded, entry.value, entry.type, entry.parsedValue]);
49
- return (<View style={styles.entryCard}>
1
+ import ae,{useState as k,useEffect as Re,useMemo as K,useCallback as X,useRef as We}from"react";import{View as T,Text as S,ScrollView as Ke,FlatList as De,TextInput as Z,Modal as Le,Alert as ne,StyleSheet as Ee,ActivityIndicator as Oe,Platform as le}from"react-native";import B from"../TouchableScale";import{AppColors as e}from"../../styles/AppColors";import{AppFonts as x}from"../../styles/AppFonts";import{useTranslation as Ne}from"../../i18n";import{DatabaseIcon as Te,SearchIcon as He,ClearIcon as Se,PlusIcon as Je,PencilIcon as Ge,TrashIcon as Ce,CopyIcon as Ue,CheckIcon as Ye,LayersIcon as _e,ResetIcon as Qe,ChevronIcon as Xe,WarningTriangleIcon as Ze}from"../NetworkIcons";import{fetchStorageEntries as et,setStorageEntry as tt,removeStorageEntry as rt,clearStorageDriver as ot,isAsyncStorageConnected as at,isMMKVConnected as nt,getRegisteredMMKVInstanceIds as lt,subscribeToStorageChanges as it}from"../../customHooks/storageInspector";import{copyToClipboard as st}from"../../helpers";import{showToast as A}from"../../helpers/toast";const dt=J=>{switch(J){case"json":return{label:"JSON",color:e.purple,bg:`${e.purple}16`};case"number":return{label:"NUM",color:e.warningIconGold,bg:`${e.warningIconGold}16`};case"boolean":return{label:"BOOL",color:e.emerald500,bg:`${e.emerald500}16`};case"null":return{label:"NULL",color:e.grayTextWeak,bg:`${e.grayTextWeak}16`};default:return{label:"STR",color:e.blue500,bg:`${e.blue500}16`}}},Tt=ae.memo(function({entry:C,isExpanded:o,onToggleExpand:E,onCopy:z,onEdit:G,onDelete:v,badge:P}){const U=K(()=>C.byteSize<1024?`${C.byteSize} B`:`${(C.byteSize/1024).toFixed(1)} KB`,[C.byteSize]),O=K(()=>{if(!o)return C.value.length>250?C.value.slice(0,250)+"...":C.value;if(C.type==="json")try{const V=C.parsedValue??JSON.parse(C.value);return JSON.stringify(V,null,2)}catch{return C.value}return C.value},[o,C.value,C.type,C.parsedValue]);return<T style={t.entryCard}>
50
2
 
51
- <View style={styles.entryHeader}>
52
- <View style={{ flex: 1, marginRight: 8 }}>
53
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 6, flexWrap: 'wrap' }}>
54
- <Text style={styles.entryKey} numberOfLines={1} selectable>
55
- {entry.key}
56
- </Text>
57
- <View style={[
58
- styles.typeBadge,
59
- { backgroundColor: badge.bg, borderColor: `${badge.color}33` },
60
- ]}>
61
- <Text style={[styles.typeBadgeText, { color: badge.color }]}>
62
- {badge.label}
63
- </Text>
64
- </View>
65
- <Text style={styles.sizeText}>{formattedBytes}</Text>
66
- </View>
67
- </View>
3
+ <T style={t.entryHeader}>
4
+ <T style={{flex:1,marginRight:8}}>
5
+ <T style={{flexDirection:"row",alignItems:"center",gap:6,flexWrap:"wrap"}}>
6
+ <S style={t.entryKey}numberOfLines={1}selectable>
7
+ {C.key}
8
+ </S>
9
+ <T style={[t.typeBadge,{backgroundColor:P.bg,borderColor:`${P.color}33`}]}>
10
+ <S style={[t.typeBadgeText,{color:P.color}]}>
11
+ {P.label}
12
+ </S>
13
+ </T>
14
+ <S style={t.sizeText}>{U}</S>
15
+ </T>
16
+ </T>
68
17
 
69
18
 
70
- <View style={styles.entryActions}>
71
- <TouchableScale hitSlop={6} onPress={() => onCopy(entry)} style={styles.entryActionBtn}>
72
- <CopyIcon size={12} color={AppColors.grayText}/>
73
- </TouchableScale>
19
+ <T style={t.entryActions}>
20
+ <B hitSlop={6}onPress={()=>z(C)}style={t.entryActionBtn}>
21
+ <Ue size={12}color={e.grayText}/>
22
+ </B>
74
23
 
75
- <TouchableScale hitSlop={6} onPress={() => onEdit(entry)} style={styles.entryActionBtn}>
76
- <PencilIcon size={12} color={AppColors.purple}/>
77
- </TouchableScale>
24
+ <B hitSlop={6}onPress={()=>G(C)}style={t.entryActionBtn}>
25
+ <Ge size={12}color={e.purple}/>
26
+ </B>
78
27
 
79
- <TouchableScale hitSlop={6} onPress={() => onDelete(entry.key)} style={[styles.entryActionBtn, { backgroundColor: `${AppColors.errorColor}12` }]}>
80
- <TrashIcon size={12} color={AppColors.errorColor}/>
81
- </TouchableScale>
82
- </View>
83
- </View>
28
+ <B hitSlop={6}onPress={()=>v(C.key)}style={[t.entryActionBtn,{backgroundColor:`${e.errorColor}12`}]}>
29
+ <Ce size={12}color={e.errorColor}/>
30
+ </B>
31
+ </T>
32
+ </T>
84
33
 
85
34
 
86
- <TouchableScale onPress={() => onToggleExpand(entry.key)} style={styles.valuePreviewBox}>
87
- <Text style={styles.valuePreviewText} numberOfLines={isExpanded ? undefined : 3} selectable={isExpanded}>
88
- {displayValue}
89
- </Text>
90
- {entry.value.length > 80 && (<View style={{ flexDirection: 'row', alignItems: 'center', gap: 4, marginTop: 4 }}>
91
- <Text style={styles.expandHint}>
92
- {isExpanded ? 'Collapse' : 'Expand'}
93
- </Text>
94
- <ChevronIcon direction={isExpanded ? 'up' : 'down'} size={10} color={AppColors.purple}/>
95
- </View>)}
96
- </TouchableScale>
97
- </View>);
98
- });
99
- export const StorageTab = React.memo(() => {
100
- const { t } = useTranslation();
101
- const listRef = useRef(null);
102
- const [activeDriver, setActiveDriver] = useState('asyncStorage');
103
- const [activeMMKVId, setActiveMMKVId] = useState('default');
104
- const [entries, setEntries] = useState([]);
105
- const [isLoading, setIsLoading] = useState(true);
106
- const [search, setSearch] = useState('');
107
- const [expandedKeys, setExpandedKeys] = useState({});
108
- const [modalVisible, setModalVisible] = useState(false);
109
- const [modalMode, setModalMode] = useState('create');
110
- const [editKeyName, setEditKeyName] = useState('');
111
- const [editValue, setEditValue] = useState('');
112
- const [editType, setEditType] = useState('string');
113
- const [jsonError, setJsonError] = useState(null);
114
- const mmkvInstanceIds = useMemo(() => getRegisteredMMKVInstanceIds(), []);
115
- const loadEntries = useCallback(async () => {
116
- setIsLoading(true);
117
- try {
118
- const data = await fetchStorageEntries(activeDriver, activeDriver === 'mmkv' ? activeMMKVId : undefined);
119
- setEntries(data);
120
- }
121
- catch {
122
- setEntries([]);
123
- }
124
- finally {
125
- setIsLoading(false);
126
- }
127
- }, [activeDriver, activeMMKVId]);
128
- useEffect(() => {
129
- loadEntries();
130
- const unsubscribe = subscribeToStorageChanges(loadEntries);
131
- return unsubscribe;
132
- }, [loadEntries]);
133
- const toggleExpand = (key) => {
134
- setExpandedKeys(prev => ({ ...prev, [key]: !prev[key] }));
135
- };
136
- const handleOpenCreate = () => {
137
- setModalMode('create');
138
- setEditKeyName('');
139
- setEditValue('');
140
- setEditType('string');
141
- setJsonError(null);
142
- setModalVisible(true);
143
- };
144
- const handleOpenEdit = (entry) => {
145
- setModalMode('edit');
146
- setEditKeyName(entry.key);
147
- setEditValue(entry.value);
148
- setEditType(entry.type === 'json' ? 'json' : entry.type === 'number' ? 'number' : entry.type === 'boolean' ? 'boolean' : 'string');
149
- setJsonError(null);
150
- setModalVisible(true);
151
- };
152
- const handleDeleteKey = (key) => {
153
- Alert.alert('Delete Storage Key', `Are you sure you want to permanently delete "${key}" from ${activeDriver === 'asyncStorage' ? 'AsyncStorage' : 'MMKV'}?`, [
154
- { text: 'Cancel', style: 'cancel' },
155
- {
156
- text: 'Delete',
157
- style: 'destructive',
158
- onPress: async () => {
159
- const ok = await removeStorageEntry(activeDriver, key, activeDriver === 'mmkv' ? activeMMKVId : undefined);
160
- if (ok) {
161
- showToast(`Deleted "${key}"`);
162
- loadEntries();
163
- }
164
- else {
165
- showToast(`Failed to delete "${key}"`);
166
- }
167
- },
168
- },
169
- ]);
170
- };
171
- const handleClearAll = () => {
172
- Alert.alert('Wipe All Storage Keys', `Are you sure you want to clear all ${entries.length} keys in ${activeDriver === 'asyncStorage' ? 'AsyncStorage' : 'MMKV'}? This cannot be undone.`, [
173
- { text: 'Cancel', style: 'cancel' },
174
- {
175
- text: 'Wipe All',
176
- style: 'destructive',
177
- onPress: async () => {
178
- const ok = await clearStorageDriver(activeDriver, activeDriver === 'mmkv' ? activeMMKVId : undefined);
179
- if (ok) {
180
- showToast('All storage keys wiped');
181
- loadEntries();
182
- }
183
- },
184
- },
185
- ]);
186
- };
187
- const handleSaveModal = async () => {
188
- if (!editKeyName.trim()) {
189
- showToast('Key name cannot be empty');
190
- return;
191
- }
192
- let finalVal = editValue;
193
- if (editType === 'json') {
194
- try {
195
- const parsed = JSON.parse(editValue);
196
- finalVal = JSON.stringify(parsed);
197
- }
198
- catch (err) {
199
- setJsonError('Invalid JSON: ' + err.message);
200
- return;
201
- }
202
- }
203
- else if (editType === 'number') {
204
- if (isNaN(Number(editValue))) {
205
- setJsonError('Value must be a valid number');
206
- return;
207
- }
208
- }
209
- const success = await setStorageEntry(activeDriver, editKeyName.trim(), finalVal, activeDriver === 'mmkv' ? activeMMKVId : undefined);
210
- if (success) {
211
- showToast(modalMode === 'create' ? `Added "${editKeyName.trim()}"` : `Updated "${editKeyName.trim()}"`);
212
- setModalVisible(false);
213
- loadEntries();
214
- }
215
- else {
216
- showToast('Error saving storage key');
217
- }
218
- };
219
- const handleBeautifyJson = () => {
220
- try {
221
- const parsed = JSON.parse(editValue);
222
- setEditValue(JSON.stringify(parsed, null, 2));
223
- setJsonError(null);
224
- setEditType('json');
225
- showToast('Formatted JSON');
226
- }
227
- catch {
228
- setJsonError('Cannot format: invalid JSON syntax');
229
- }
230
- };
231
- const filteredEntries = useMemo(() => {
232
- if (!search.trim())
233
- return entries;
234
- const tokens = search.toLowerCase().trim().split(/\s+/).filter(Boolean);
235
- return entries.filter(e => {
236
- const corpus = `${e.key} ${e.value}`.toLowerCase();
237
- return tokens.every(tok => corpus.includes(tok));
238
- });
239
- }, [entries, search]);
240
- const totalBytes = useMemo(() => {
241
- return entries.reduce((sum, e) => sum + e.byteSize, 0);
242
- }, [entries]);
243
- const formattedTotalSize = useMemo(() => {
244
- if (totalBytes < 1024)
245
- return `${totalBytes} B`;
246
- if (totalBytes < 1024 * 1024)
247
- return `${(totalBytes / 1024).toFixed(1)} KB`;
248
- return `${(totalBytes / (1024 * 1024)).toFixed(2)} MB`;
249
- }, [totalBytes]);
250
- const handleCopyEntry = useCallback((entry) => {
251
- copyToClipboard(entry.value, entry.key);
252
- showToast(`Copied value of "${entry.key}"`);
253
- }, []);
254
- const renderItem = useCallback(({ item }) => (<StorageEntryCard entry={item} isExpanded={Boolean(expandedKeys[item.key])} onToggleExpand={toggleExpand} onCopy={handleCopyEntry} onEdit={handleOpenEdit} onDelete={handleDeleteKey} badge={getTypeBadge(item.type)}/>), [expandedKeys, handleCopyEntry]);
255
- const isConnected = activeDriver === 'asyncStorage'
256
- ? isAsyncStorageConnected()
257
- : isMMKVConnected();
258
- return (<View style={styles.container}>
35
+ <B onPress={()=>E(C.key)}style={t.valuePreviewBox}>
36
+ <S style={t.valuePreviewText}numberOfLines={o?void 0:3}selectable={o}>
37
+ {O}
38
+ </S>
39
+ {C.value.length>80&&<T style={{flexDirection:"row",alignItems:"center",gap:4,marginTop:4}}>
40
+ <S style={t.expandHint}>
41
+ {o?"Collapse":"Expand"}
42
+ </S>
43
+ <Xe direction={o?"up":"down"}size={10}color={e.purple}/>
44
+ </T>}
45
+ </B>
46
+ </T>});export const StorageTab=ae.memo(()=>{const{t:J}=Ne(),C=We(null),[o,E]=k("asyncStorage"),[z,G]=k("default"),[v,P]=k([]),[U,O]=k(!0),[V,Y]=k(""),[ee,Be]=k({}),[ve,F]=k(!1),[N,te]=k("create"),[R,_]=k(""),[D,H]=k(""),[$,j]=k("string"),[q,I]=k(null),re=K(()=>lt(),[]),M=X(async()=>{O(!0);try{const r=await et(o,o==="mmkv"?z:void 0);P(r)}catch{P([])}finally{O(!1)}},[o,z]);Re(()=>(M(),it(M)),[M]);const we=r=>{Be(w=>({...w,[r]:!w[r]}))},ke=()=>{te("create"),_(""),H(""),j("string"),I(null),F(!0)},Ve=r=>{te("edit"),_(r.key),H(r.value),j(r.type==="json"?"json":r.type==="number"?"number":r.type==="boolean"?"boolean":"string"),I(null),F(!0)},ze=r=>{ne.alert("Delete Storage Key",`Are you sure you want to permanently delete "${r}" from ${o==="asyncStorage"?"AsyncStorage":"MMKV"}?`,[{text:"Cancel",style:"cancel"},{text:"Delete",style:"destructive",onPress:async()=>{await rt(o,r,o==="mmkv"?z:void 0)?(A(`Deleted "${r}"`),M()):A(`Failed to delete "${r}"`)}}])},Ie=()=>{ne.alert("Wipe All Storage Keys",`Are you sure you want to clear all ${v.length} keys in ${o==="asyncStorage"?"AsyncStorage":"MMKV"}? This cannot be undone.`,[{text:"Cancel",style:"cancel"},{text:"Wipe All",style:"destructive",onPress:async()=>{await ot(o,o==="mmkv"?z:void 0)&&(A("All storage keys wiped"),M())}}])},Ae=async()=>{if(!R.trim()){A("Key name cannot be empty");return}let r=D;if($==="json")try{const L=JSON.parse(D);r=JSON.stringify(L)}catch(L){I("Invalid JSON: "+L.message);return}else if($==="number"&&isNaN(Number(D))){I("Value must be a valid number");return}await tt(o,R.trim(),r,o==="mmkv"?z:void 0)?(A(N==="create"?`Added "${R.trim()}"`:`Updated "${R.trim()}"`),F(!1),M()):A("Error saving storage key")},Pe=()=>{try{const r=JSON.parse(D);H(JSON.stringify(r,null,2)),I(null),j("json"),A("Formatted JSON")}catch{I("Cannot format: invalid JSON syntax")}},Q=K(()=>{if(!V.trim())return v;const r=V.toLowerCase().trim().split(/\s+/).filter(Boolean);return v.filter(w=>{const L=`${w.key} ${w.value}`.toLowerCase();return r.every(Fe=>L.includes(Fe))})},[v,V]),W=K(()=>v.reduce((r,w)=>r+w.byteSize,0),[v]),$e=K(()=>W<1024?`${W} B`:W<1024*1024?`${(W/1024).toFixed(1)} KB`:`${(W/(1024*1024)).toFixed(2)} MB`,[W]),oe=X(r=>{st(r.value,r.key),A(`Copied value of "${r.key}"`)},[]),Me=X(({item:r})=><Tt entry={r}isExpanded={!!ee[r.key]}onToggleExpand={we}onCopy={oe}onEdit={Ve}onDelete={ze}badge={dt(r.type)}/>,[ee,oe]),xt=o==="asyncStorage"?at():nt();return<T style={t.container}>
259
47
 
260
- <View style={styles.driverTabsWrapper}>
261
- <ScrollView horizontal showsHorizontalScrollIndicator={false} contentContainerStyle={styles.driverTabsContainer}>
262
- <TouchableScale onPress={() => setActiveDriver('asyncStorage')} style={[
263
- styles.driverTabPill,
264
- activeDriver === 'asyncStorage' && styles.driverTabPillActive,
265
- ]}>
266
- <DatabaseIcon size={13} color={activeDriver === 'asyncStorage'
267
- ? AppColors.white
268
- : AppColors.grayText}/>
269
- <Text style={[
270
- styles.driverTabText,
271
- activeDriver === 'asyncStorage' && styles.driverTabTextActive,
272
- ]}>
48
+ <T style={t.driverTabsWrapper}>
49
+ <Ke horizontal showsHorizontalScrollIndicator={!1}contentContainerStyle={t.driverTabsContainer}>
50
+ <B onPress={()=>E("asyncStorage")}style={[t.driverTabPill,o==="asyncStorage"&&t.driverTabPillActive]}>
51
+ <Te size={13}color={o==="asyncStorage"?e.white:e.grayText}/>
52
+ <S style={[t.driverTabText,o==="asyncStorage"&&t.driverTabTextActive]}>
273
53
  AsyncStorage
274
- </Text>
275
- {activeDriver === 'asyncStorage' && entries.length > 0 && (<View style={styles.driverCountBadge}>
276
- <Text style={styles.driverCountText}>{entries.length}</Text>
277
- </View>)}
278
- </TouchableScale>
279
-
280
- <TouchableScale onPress={() => setActiveDriver('mmkv')} style={[
281
- styles.driverTabPill,
282
- activeDriver === 'mmkv' && styles.driverTabPillActive,
283
- ]}>
284
- <LayersIcon size={13} color={activeDriver === 'mmkv'
285
- ? AppColors.white
286
- : AppColors.grayText}/>
287
- <Text style={[
288
- styles.driverTabText,
289
- activeDriver === 'mmkv' && styles.driverTabTextActive,
290
- ]}>
54
+ </S>
55
+ {o==="asyncStorage"&&v.length>0&&<T style={t.driverCountBadge}>
56
+ <S style={t.driverCountText}>{v.length}</S>
57
+ </T>}
58
+ </B>
59
+
60
+ <B onPress={()=>E("mmkv")}style={[t.driverTabPill,o==="mmkv"&&t.driverTabPillActive]}>
61
+ <_e size={13}color={o==="mmkv"?e.white:e.grayText}/>
62
+ <S style={[t.driverTabText,o==="mmkv"&&t.driverTabTextActive]}>
291
63
  MMKV
292
- </Text>
293
- {activeDriver === 'mmkv' && entries.length > 0 && (<View style={styles.driverCountBadge}>
294
- <Text style={styles.driverCountText}>{entries.length}</Text>
295
- </View>)}
296
- </TouchableScale>
64
+ </S>
65
+ {o==="mmkv"&&v.length>0&&<T style={t.driverCountBadge}>
66
+ <S style={t.driverCountText}>{v.length}</S>
67
+ </T>}
68
+ </B>
297
69
 
298
70
 
299
- {activeDriver === 'mmkv' && mmkvInstanceIds.length > 1 && (<View style={{ flexDirection: 'row', alignItems: 'center', gap: 4, marginLeft: 6 }}>
300
- {mmkvInstanceIds.map(id => (<TouchableScale key={id} onPress={() => setActiveMMKVId(id)} style={[
301
- styles.instancePill,
302
- activeMMKVId === id && styles.instancePillActive,
303
- ]}>
304
- <Text style={[
305
- styles.instancePillText,
306
- activeMMKVId === id && styles.instancePillTextActive,
307
- ]}>
308
- {id}
309
- </Text>
310
- </TouchableScale>))}
311
- </View>)}
312
- </ScrollView>
313
- </View>
71
+ {o==="mmkv"&&re.length>1&&<T style={{flexDirection:"row",alignItems:"center",gap:4,marginLeft:6}}>
72
+ {re.map(r=><B key={r}onPress={()=>G(r)}style={[t.instancePill,z===r&&t.instancePillActive]}>
73
+ <S style={[t.instancePillText,z===r&&t.instancePillTextActive]}>
74
+ {r}
75
+ </S>
76
+ </B>)}
77
+ </T>}
78
+ </Ke>
79
+ </T>
314
80
 
315
81
 
316
- <View style={styles.actionBar}>
317
- <View style={styles.searchBar}>
318
- <SearchIcon size={14} color={AppColors.grayTextWeak}/>
319
- <TextInput value={search} onChangeText={setSearch} placeholder={`Search ${entries.length} keys & values...`} placeholderTextColor={AppColors.grayTextWeak} style={styles.searchInput} clearButtonMode="while-editing"/>
320
- {search.length > 0 && (<View style={{ flexDirection: 'row', alignItems: 'center', gap: 4 }}>
321
- <View style={{
322
- backgroundColor: `${AppColors.purple}20`,
323
- borderRadius: 10,
324
- paddingHorizontal: 6,
325
- paddingVertical: 1.5,
326
- }}>
327
- <Text style={{
328
- color: AppColors.purple,
329
- fontSize: 9.5,
330
- fontFamily: AppFonts.interBold,
331
- }}>
332
- {filteredEntries.length}
333
- </Text>
334
- </View>
335
- <TouchableScale onPress={() => setSearch('')} hitSlop={8}>
336
- <ClearIcon size={13} color={AppColors.grayTextWeak}/>
337
- </TouchableScale>
338
- </View>)}
339
- </View>
82
+ <T style={t.actionBar}>
83
+ <T style={t.searchBar}>
84
+ <He size={14}color={e.grayTextWeak}/>
85
+ <Z value={V}onChangeText={Y}placeholder={`Search ${v.length} keys & values...`}placeholderTextColor={e.grayTextWeak}style={t.searchInput}clearButtonMode="while-editing"/>
86
+ {V.length>0&&<T style={{flexDirection:"row",alignItems:"center",gap:4}}>
87
+ <T style={{backgroundColor:`${e.purple}20`,borderRadius:10,paddingHorizontal:6,paddingVertical:1.5}}>
88
+ <S style={{color:e.purple,fontSize:9.5,fontFamily:x.interBold}}>
89
+ {Q.length}
90
+ </S>
91
+ </T>
92
+ <B onPress={()=>Y("")}hitSlop={8}>
93
+ <Se size={13}color={e.grayTextWeak}/>
94
+ </B>
95
+ </T>}
96
+ </T>
340
97
 
341
98
 
342
- <TouchableScale onPress={handleOpenCreate} style={styles.addKeyBtn} hitSlop={6}>
343
- <PlusIcon size={13} color={AppColors.white}/>
344
- <Text style={styles.addKeyBtnText}>Add</Text>
345
- </TouchableScale>
99
+ <B onPress={ke}style={t.addKeyBtn}hitSlop={6}>
100
+ <Je size={13}color={e.white}/>
101
+ <S style={t.addKeyBtnText}>Add</S>
102
+ </B>
346
103
 
347
- <TouchableScale onPress={loadEntries} style={styles.actionIconBtn} hitSlop={6}>
348
- <ResetIcon size={13} color={AppColors.grayText}/>
349
- </TouchableScale>
104
+ <B onPress={M}style={t.actionIconBtn}hitSlop={6}>
105
+ <Qe size={13}color={e.grayText}/>
106
+ </B>
350
107
 
351
- {entries.length > 0 && (<TouchableScale onPress={handleClearAll} style={[styles.actionIconBtn, { borderColor: `${AppColors.errorColor}33`, backgroundColor: `${AppColors.errorColor}12` }]} hitSlop={6}>
352
- <TrashIcon size={13} color={AppColors.errorColor}/>
353
- </TouchableScale>)}
354
- </View>
108
+ {v.length>0&&<B onPress={Ie}style={[t.actionIconBtn,{borderColor:`${e.errorColor}33`,backgroundColor:`${e.errorColor}12`}]}hitSlop={6}>
109
+ <Ce size={13}color={e.errorColor}/>
110
+ </B>}
111
+ </T>
355
112
 
356
113
 
357
- <View style={styles.statsStrip}>
358
- <Text style={styles.statsText}>
359
- {filteredEntries.length} of {entries.length} Keys • {formattedTotalSize}
360
- </Text>
361
- <Text style={styles.statsSubtext}>
362
- {activeDriver === 'asyncStorage' ? 'SQLite Key-Value' : `MMKV (${activeMMKVId})`}
363
- </Text>
364
- </View>
114
+ <T style={t.statsStrip}>
115
+ <S style={t.statsText}>
116
+ {Q.length} of {v.length} Keys • {$e}
117
+ </S>
118
+ <S style={t.statsSubtext}>
119
+ {o==="asyncStorage"?"SQLite Key-Value":`MMKV (${z})`}
120
+ </S>
121
+ </T>
365
122
 
366
123
 
367
- {isLoading ? (<View style={styles.loadingContainer}>
368
- <ActivityIndicator size="small" color={AppColors.purple}/>
369
- <Text style={styles.loadingText}>Loading storage entries...</Text>
370
- </View>) : (<>
371
- <FlatList ref={listRef} data={filteredEntries} keyExtractor={item => item.key} renderItem={renderItem} initialNumToRender={10} maxToRenderPerBatch={10} windowSize={5} removeClippedSubviews={Platform.OS === 'android'} style={styles.scrollArea} contentContainerStyle={styles.scrollContent} showsVerticalScrollIndicator={false} ListEmptyComponent={<View style={styles.emptyContainer}>
372
- <View style={styles.emptyIconWrap}>
373
- <DatabaseIcon size={28} color={AppColors.grayTextWeak}/>
374
- </View>
375
- <Text style={styles.emptyTitle}>
376
- {search.trim().length > 0
377
- ? 'No matching keys found'
378
- : `No ${activeDriver === 'asyncStorage' ? 'AsyncStorage' : 'MMKV'} Keys`}
379
- </Text>
380
- <Text style={styles.emptySubtitle}>
381
- {search.trim().length > 0
382
- ? `No keys or values match "${search}"`
383
- : `Storage is auto-detected. Tap "+ Add" above to create your first ${activeDriver === 'asyncStorage' ? 'AsyncStorage' : 'MMKV'} key!`}
384
- </Text>
385
- {search.trim().length > 0 && (<TouchableScale onPress={() => setSearch('')} style={{
386
- marginTop: 12,
387
- paddingHorizontal: 14,
388
- paddingVertical: 6,
389
- borderRadius: 8,
390
- backgroundColor: AppColors.grayBackground,
391
- borderWidth: 1,
392
- borderColor: AppColors.grayBorderSecondary,
393
- }}>
394
- <Text style={{ color: AppColors.brandPurple, fontSize: 12, fontFamily: AppFonts.interBold }}>
124
+ {U?<T style={t.loadingContainer}>
125
+ <Oe size="small"color={e.purple}/>
126
+ <S style={t.loadingText}>Loading storage entries...</S>
127
+ </T>:<>
128
+ <De ref={C}data={Q}keyExtractor={r=>r.key}renderItem={Me}initialNumToRender={10}maxToRenderPerBatch={10}windowSize={5}removeClippedSubviews={le.OS==="android"}style={t.scrollArea}contentContainerStyle={t.scrollContent}showsVerticalScrollIndicator={!1}ListEmptyComponent={<T style={t.emptyContainer}>
129
+ <T style={t.emptyIconWrap}>
130
+ <Te size={28}color={e.grayTextWeak}/>
131
+ </T>
132
+ <S style={t.emptyTitle}>
133
+ {V.trim().length>0?"No matching keys found":`No ${o==="asyncStorage"?"AsyncStorage":"MMKV"} Keys`}
134
+ </S>
135
+ <S style={t.emptySubtitle}>
136
+ {V.trim().length>0?`No keys or values match "${V}"`:`Storage is auto-detected. Tap "+ Add" above to create your first ${o==="asyncStorage"?"AsyncStorage":"MMKV"} key!`}
137
+ </S>
138
+ {V.trim().length>0&&<B onPress={()=>Y("")}style={{marginTop:12,paddingHorizontal:14,paddingVertical:6,borderRadius:8,backgroundColor:e.grayBackground,borderWidth:1,borderColor:e.grayBorderSecondary}}>
139
+ <S style={{color:e.brandPurple,fontSize:12,fontFamily:x.interBold}}>
395
140
  Clear Search
396
- </Text>
397
- </TouchableScale>)}
398
- </View>} ListFooterComponent={<View style={{ height: 60 }}/>}/>
399
- </>)}
141
+ </S>
142
+ </B>}
143
+ </T>}ListFooterComponent={<T style={{height:60}}/>}/>
144
+ </>}
400
145
 
401
146
 
402
- <Modal visible={modalVisible} transparent animationType="fade" onRequestClose={() => setModalVisible(false)}>
403
- <View style={styles.modalOverlay}>
404
- <View style={styles.modalCard}>
405
- <View style={styles.modalHeader}>
406
- <Text style={styles.modalTitle}>
407
- {modalMode === 'create' ? 'Add Storage Key' : `Edit: ${editKeyName}`}
408
- </Text>
409
- <TouchableScale onPress={() => setModalVisible(false)} hitSlop={8}>
410
- <ClearIcon size={16} color={AppColors.grayText}/>
411
- </TouchableScale>
412
- </View>
147
+ <Le visible={ve}transparent animationType="fade"onRequestClose={()=>F(!1)}>
148
+ <T style={t.modalOverlay}>
149
+ <T style={t.modalCard}>
150
+ <T style={t.modalHeader}>
151
+ <S style={t.modalTitle}>
152
+ {N==="create"?"Add Storage Key":`Edit: ${R}`}
153
+ </S>
154
+ <B onPress={()=>F(!1)}hitSlop={8}>
155
+ <Se size={16}color={e.grayText}/>
156
+ </B>
157
+ </T>
413
158
 
414
159
 
415
- <View style={styles.inputGroup}>
416
- <Text style={styles.inputLabel}>KEY NAME</Text>
417
- <TextInput value={editKeyName} onChangeText={setEditKeyName} placeholder="e.g. user_session, auth_token" placeholderTextColor={AppColors.grayTextWeak} editable={modalMode === 'create'} style={[
418
- styles.textInput,
419
- modalMode === 'edit' && styles.textInputDisabled,
420
- ]} autoCapitalize="none"/>
421
- </View>
160
+ <T style={t.inputGroup}>
161
+ <S style={t.inputLabel}>KEY NAME</S>
162
+ <Z value={R}onChangeText={_}placeholder="e.g. user_session, auth_token"placeholderTextColor={e.grayTextWeak}editable={N==="create"}style={[t.textInput,N==="edit"&&t.textInputDisabled]}autoCapitalize="none"/>
163
+ </T>
422
164
 
423
165
 
424
- <View style={styles.inputGroup}>
425
- <View style={{ flexDirection: 'row', alignItems: 'center', justifyContent: 'space-between', marginBottom: 4 }}>
426
- <Text style={styles.inputLabel}>VALUE TYPE</Text>
427
- {editType === 'json' && (<TouchableScale onPress={handleBeautifyJson} hitSlop={6}>
428
- <Text style={styles.formatJsonBtn}>Beautify JSON</Text>
429
- </TouchableScale>)}
430
- </View>
431
- <View style={styles.typeSelectorStrip}>
432
- {['string', 'json', 'number', 'boolean'].map(t => {
433
- const isSel = editType === t;
434
- return (<TouchableScale key={t} onPress={() => {
435
- setEditType(t);
436
- setJsonError(null);
437
- }} style={[
438
- styles.typePill,
439
- isSel && styles.typePillActive,
440
- ]}>
441
- <Text style={[
442
- styles.typePillText,
443
- isSel && styles.typePillTextActive,
444
- ]}>
445
- {t.toUpperCase()}
446
- </Text>
447
- </TouchableScale>);
448
- })}
449
- </View>
450
- </View>
166
+ <T style={t.inputGroup}>
167
+ <T style={{flexDirection:"row",alignItems:"center",justifyContent:"space-between",marginBottom:4}}>
168
+ <S style={t.inputLabel}>VALUE TYPE</S>
169
+ {$==="json"&&<B onPress={Pe}hitSlop={6}>
170
+ <S style={t.formatJsonBtn}>Beautify JSON</S>
171
+ </B>}
172
+ </T>
173
+ <T style={t.typeSelectorStrip}>
174
+ {["string","json","number","boolean"].map(r=>{const w=$===r;return<B key={r}onPress={()=>{j(r),I(null)}}style={[t.typePill,w&&t.typePillActive]}>
175
+ <S style={[t.typePillText,w&&t.typePillTextActive]}>
176
+ {r.toUpperCase()}
177
+ </S>
178
+ </B>})}
179
+ </T>
180
+ </T>
451
181
 
452
182
 
453
- <View style={styles.inputGroup}>
454
- <Text style={styles.inputLabel}>VALUE CONTENT</Text>
455
- <TextInput value={editValue} onChangeText={v => {
456
- setEditValue(v);
457
- if (jsonError)
458
- setJsonError(null);
459
- }} placeholder={editType === 'json'
460
- ? '{"userId": 123, "isLoggedIn": true}'
461
- : editType === 'number'
462
- ? '42'
463
- : editType === 'boolean'
464
- ? 'true'
465
- : 'String value...'} placeholderTextColor={AppColors.grayTextWeak} style={[styles.textInput, styles.textAreaInput]} multiline textAlignVertical="top" autoCapitalize="none"/>
466
- {jsonError && (<View style={{ flexDirection: 'row', alignItems: 'center', gap: 5, marginTop: 4 }}>
467
- <WarningTriangleIcon size={12} color={AppColors.errorColor}/>
468
- <Text style={styles.errorText}>{jsonError}</Text>
469
- </View>)}
470
- </View>
183
+ <T style={t.inputGroup}>
184
+ <S style={t.inputLabel}>VALUE CONTENT</S>
185
+ <Z value={D}onChangeText={r=>{H(r),q&&I(null)}}placeholder={$==="json"?'{"userId": 123, "isLoggedIn": true}':$==="number"?"42":$==="boolean"?"true":"String value..."}placeholderTextColor={e.grayTextWeak}style={[t.textInput,t.textAreaInput]}multiline textAlignVertical="top"autoCapitalize="none"/>
186
+ {q&&<T style={{flexDirection:"row",alignItems:"center",gap:5,marginTop:4}}>
187
+ <Ze size={12}color={e.errorColor}/>
188
+ <S style={t.errorText}>{q}</S>
189
+ </T>}
190
+ </T>
471
191
 
472
192
 
473
- <View style={styles.modalActions}>
474
- <TouchableScale onPress={() => setModalVisible(false)} style={styles.cancelBtn}>
475
- <Text style={styles.cancelBtnText}>Cancel</Text>
476
- </TouchableScale>
477
- <TouchableScale onPress={handleSaveModal} style={styles.saveBtn}>
478
- <CheckIcon size={14} color={AppColors.white}/>
479
- <Text style={styles.saveBtnText}>Save Key</Text>
480
- </TouchableScale>
481
- </View>
482
- </View>
483
- </View>
484
- </Modal>
485
- </View>);
486
- });
487
- const styles = StyleSheet.create({
488
- container: {
489
- flex: 1,
490
- backgroundColor: AppColors.grayBackground,
491
- },
492
- driverTabsWrapper: {
493
- backgroundColor: AppColors.primaryLight,
494
- borderBottomWidth: 1,
495
- borderBottomColor: AppColors.dividerColor,
496
- paddingVertical: 8,
497
- },
498
- driverTabsContainer: {
499
- paddingHorizontal: 12,
500
- flexDirection: 'row',
501
- alignItems: 'center',
502
- gap: 6,
503
- },
504
- driverTabPill: {
505
- flexDirection: 'row',
506
- alignItems: 'center',
507
- gap: 6,
508
- paddingHorizontal: 11,
509
- paddingVertical: 6,
510
- borderRadius: 8,
511
- backgroundColor: AppColors.grayBackground,
512
- borderWidth: 1,
513
- borderColor: AppColors.grayBorderSecondary,
514
- },
515
- driverTabPillActive: {
516
- backgroundColor: AppColors.purple,
517
- borderColor: AppColors.purple,
518
- },
519
- driverTabText: {
520
- fontFamily: AppFonts.interBold,
521
- fontSize: 11.5,
522
- color: AppColors.grayText,
523
- },
524
- driverTabTextActive: {
525
- color: AppColors.white,
526
- },
527
- driverCountBadge: {
528
- backgroundColor: 'rgba(255, 255, 255, 0.25)',
529
- paddingHorizontal: 5,
530
- paddingVertical: 1,
531
- borderRadius: 6,
532
- },
533
- driverCountText: {
534
- fontFamily: AppFonts.interBold,
535
- fontSize: 9,
536
- color: AppColors.white,
537
- },
538
- instancePill: {
539
- paddingHorizontal: 7,
540
- paddingVertical: 3,
541
- borderRadius: 6,
542
- backgroundColor: `${AppColors.purple}14`,
543
- borderWidth: 1,
544
- borderColor: `${AppColors.purple}30`,
545
- },
546
- instancePillActive: {
547
- backgroundColor: AppColors.purple,
548
- borderColor: AppColors.purple,
549
- },
550
- instancePillText: {
551
- fontFamily: AppFonts.interBold,
552
- fontSize: 10,
553
- color: AppColors.purple,
554
- },
555
- instancePillTextActive: {
556
- color: AppColors.white,
557
- },
558
- actionBar: {
559
- flexDirection: 'row',
560
- alignItems: 'center',
561
- paddingHorizontal: 12,
562
- paddingVertical: 8,
563
- backgroundColor: AppColors.primaryLight,
564
- borderBottomWidth: 1,
565
- borderBottomColor: AppColors.dividerColor,
566
- gap: 6,
567
- },
568
- searchBar: {
569
- flex: 1,
570
- flexDirection: 'row',
571
- alignItems: 'center',
572
- backgroundColor: AppColors.grayBackground,
573
- borderRadius: 8,
574
- paddingHorizontal: 9,
575
- paddingVertical: Platform.OS === 'ios' ? 6 : 2,
576
- borderWidth: 1,
577
- borderColor: AppColors.grayBorderSecondary,
578
- gap: 6,
579
- },
580
- searchInput: {
581
- flex: 1,
582
- fontFamily: AppFonts.interMedium,
583
- fontSize: 12,
584
- color: AppColors.primaryBlack,
585
- padding: 0,
586
- },
587
- addKeyBtn: {
588
- flexDirection: 'row',
589
- alignItems: 'center',
590
- gap: 4,
591
- paddingHorizontal: 10,
592
- paddingVertical: 6,
593
- borderRadius: 8,
594
- backgroundColor: AppColors.purple,
595
- },
596
- addKeyBtnText: {
597
- fontFamily: AppFonts.interBold,
598
- fontSize: 11,
599
- color: AppColors.white,
600
- },
601
- actionIconBtn: {
602
- width: 30,
603
- height: 30,
604
- borderRadius: 8,
605
- alignItems: 'center',
606
- justifyContent: 'center',
607
- backgroundColor: AppColors.grayBackground,
608
- borderWidth: 1,
609
- borderColor: AppColors.grayBorderSecondary,
610
- },
611
- statsStrip: {
612
- flexDirection: 'row',
613
- alignItems: 'center',
614
- justifyContent: 'space-between',
615
- paddingHorizontal: 12,
616
- paddingVertical: 5,
617
- backgroundColor: `${AppColors.grayBorderSecondary}40`,
618
- },
619
- statsText: {
620
- fontFamily: AppFonts.interMedium,
621
- fontSize: 10,
622
- color: AppColors.grayText,
623
- },
624
- statsSubtext: {
625
- fontFamily: AppFonts.interBold,
626
- fontSize: 9.5,
627
- color: AppColors.grayTextWeak,
628
- },
629
- scrollArea: {
630
- flex: 1,
631
- },
632
- scrollContent: {
633
- padding: 12,
634
- gap: 10,
635
- paddingBottom: 100,
636
- },
637
- entryCard: {
638
- backgroundColor: AppColors.primaryLight,
639
- borderRadius: 10,
640
- borderWidth: 1,
641
- borderColor: AppColors.grayBorderSecondary,
642
- padding: 10,
643
- gap: 8,
644
- shadowColor: AppColors.black,
645
- shadowOpacity: 0.02,
646
- shadowRadius: 3,
647
- shadowOffset: { width: 0, height: 1 },
648
- elevation: 1,
649
- },
650
- entryHeader: {
651
- flexDirection: 'row',
652
- alignItems: 'center',
653
- justifyContent: 'space-between',
654
- },
655
- entryKey: {
656
- fontFamily: AppFonts.interBold,
657
- fontSize: 12.5,
658
- color: AppColors.primaryBlack,
659
- },
660
- typeBadge: {
661
- paddingHorizontal: 5,
662
- paddingVertical: 1,
663
- borderRadius: 4,
664
- borderWidth: 1,
665
- },
666
- typeBadgeText: {
667
- fontFamily: AppFonts.interBold,
668
- fontSize: 8.5,
669
- },
670
- sizeText: {
671
- fontFamily: AppFonts.interRegular,
672
- fontSize: 10,
673
- color: AppColors.grayTextWeak,
674
- },
675
- entryActions: {
676
- flexDirection: 'row',
677
- alignItems: 'center',
678
- gap: 5,
679
- },
680
- entryActionBtn: {
681
- padding: 5,
682
- borderRadius: 5,
683
- backgroundColor: AppColors.grayBackground,
684
- },
685
- valuePreviewBox: {
686
- backgroundColor: AppColors.grayBackground,
687
- borderRadius: 6,
688
- padding: 8,
689
- borderWidth: 1,
690
- borderColor: `${AppColors.grayBorderSecondary}80`,
691
- },
692
- valuePreviewText: {
693
- fontFamily: AppFonts.interRegular,
694
- fontSize: 11,
695
- color: AppColors.primaryBlack,
696
- lineHeight: 16,
697
- },
698
- expandHint: {
699
- fontFamily: AppFonts.interBold,
700
- fontSize: 9.5,
701
- color: AppColors.purple,
702
- marginTop: 4,
703
- },
704
- loadingContainer: {
705
- flex: 1,
706
- alignItems: 'center',
707
- justifyContent: 'center',
708
- gap: 8,
709
- },
710
- loadingText: {
711
- fontFamily: AppFonts.interMedium,
712
- fontSize: 12,
713
- color: AppColors.grayText,
714
- },
715
- emptyContainer: {
716
- padding: 24,
717
- alignItems: 'center',
718
- justifyContent: 'center',
719
- },
720
- emptyIconWrap: {
721
- width: 56,
722
- height: 56,
723
- borderRadius: 28,
724
- backgroundColor: `${AppColors.grayBorderSecondary}40`,
725
- alignItems: 'center',
726
- justifyContent: 'center',
727
- marginBottom: 12,
728
- },
729
- emptyTitle: {
730
- fontFamily: AppFonts.interBold,
731
- fontSize: 14,
732
- color: AppColors.primaryBlack,
733
- marginBottom: 4,
734
- },
735
- emptySubtitle: {
736
- fontFamily: AppFonts.interRegular,
737
- fontSize: 11.5,
738
- color: AppColors.grayText,
739
- textAlign: 'center',
740
- maxWidth: 280,
741
- },
742
- connectGuideCard: {
743
- marginTop: 20,
744
- width: '100%',
745
- backgroundColor: AppColors.primaryLight,
746
- borderRadius: 10,
747
- borderWidth: 1,
748
- borderColor: AppColors.grayBorderSecondary,
749
- padding: 12,
750
- gap: 6,
751
- },
752
- connectGuideTitle: {
753
- fontFamily: AppFonts.interBold,
754
- fontSize: 11,
755
- color: AppColors.purple,
756
- },
757
- connectGuideCode: {
758
- fontFamily: AppFonts.interRegular,
759
- fontSize: 10,
760
- color: AppColors.grayText,
761
- lineHeight: 15,
762
- },
763
- modalOverlay: {
764
- flex: 1,
765
- backgroundColor: 'rgba(0, 0, 0, 0.5)',
766
- justifyContent: 'center',
767
- alignItems: 'center',
768
- padding: 16,
769
- },
770
- modalCard: {
771
- width: '100%',
772
- maxWidth: 400,
773
- backgroundColor: AppColors.primaryLight,
774
- borderRadius: 14,
775
- padding: 16,
776
- gap: 12,
777
- shadowColor: AppColors.black,
778
- shadowOpacity: 0.2,
779
- shadowRadius: 10,
780
- shadowOffset: { width: 0, height: 4 },
781
- elevation: 5,
782
- },
783
- modalHeader: {
784
- flexDirection: 'row',
785
- alignItems: 'center',
786
- justifyContent: 'space-between',
787
- borderBottomWidth: 1,
788
- borderBottomColor: AppColors.dividerColor,
789
- paddingBottom: 10,
790
- },
791
- modalTitle: {
792
- fontFamily: AppFonts.interBold,
793
- fontSize: 14,
794
- color: AppColors.primaryBlack,
795
- },
796
- inputGroup: {
797
- gap: 4,
798
- },
799
- inputLabel: {
800
- fontFamily: AppFonts.interBold,
801
- fontSize: 9.5,
802
- color: AppColors.grayTextWeak,
803
- letterSpacing: 0.5,
804
- },
805
- textInput: {
806
- backgroundColor: AppColors.grayBackground,
807
- borderRadius: 8,
808
- paddingHorizontal: 10,
809
- paddingVertical: 8,
810
- fontFamily: AppFonts.interMedium,
811
- fontSize: 12,
812
- color: AppColors.primaryBlack,
813
- borderWidth: 1,
814
- borderColor: AppColors.grayBorderSecondary,
815
- },
816
- textInputDisabled: {
817
- backgroundColor: `${AppColors.grayBorderSecondary}40`,
818
- color: AppColors.grayText,
819
- },
820
- textAreaInput: {
821
- minHeight: 90,
822
- maxHeight: 160,
823
- fontFamily: AppFonts.interRegular,
824
- fontSize: 11,
825
- },
826
- typeSelectorStrip: {
827
- flexDirection: 'row',
828
- alignItems: 'center',
829
- gap: 6,
830
- },
831
- typePill: {
832
- flex: 1,
833
- alignItems: 'center',
834
- paddingVertical: 6,
835
- borderRadius: 6,
836
- backgroundColor: AppColors.grayBackground,
837
- borderWidth: 1,
838
- borderColor: AppColors.grayBorderSecondary,
839
- },
840
- typePillActive: {
841
- backgroundColor: AppColors.purple,
842
- borderColor: AppColors.purple,
843
- },
844
- typePillText: {
845
- fontFamily: AppFonts.interBold,
846
- fontSize: 10,
847
- color: AppColors.grayText,
848
- },
849
- typePillTextActive: {
850
- color: AppColors.white,
851
- },
852
- formatJsonBtn: {
853
- fontFamily: AppFonts.interBold,
854
- fontSize: 10,
855
- color: AppColors.purple,
856
- },
857
- errorText: {
858
- fontFamily: AppFonts.interMedium,
859
- fontSize: 10,
860
- color: AppColors.errorColor,
861
- marginTop: 2,
862
- },
863
- modalActions: {
864
- flexDirection: 'row',
865
- alignItems: 'center',
866
- gap: 10,
867
- marginTop: 4,
868
- },
869
- cancelBtn: {
870
- flex: 1,
871
- alignItems: 'center',
872
- paddingVertical: 10,
873
- borderRadius: 8,
874
- backgroundColor: AppColors.grayBackground,
875
- borderWidth: 1,
876
- borderColor: AppColors.grayBorderSecondary,
877
- },
878
- cancelBtnText: {
879
- fontFamily: AppFonts.interBold,
880
- fontSize: 12,
881
- color: AppColors.grayText,
882
- },
883
- saveBtn: {
884
- flex: 1.5,
885
- flexDirection: 'row',
886
- alignItems: 'center',
887
- justifyContent: 'center',
888
- gap: 5,
889
- paddingVertical: 10,
890
- borderRadius: 8,
891
- backgroundColor: AppColors.purple,
892
- },
893
- saveBtnText: {
894
- fontFamily: AppFonts.interBold,
895
- fontSize: 12,
896
- color: AppColors.white,
897
- },
898
- });
899
- export default StorageTab;
193
+ <T style={t.modalActions}>
194
+ <B onPress={()=>F(!1)}style={t.cancelBtn}>
195
+ <S style={t.cancelBtnText}>Cancel</S>
196
+ </B>
197
+ <B onPress={Ae}style={t.saveBtn}>
198
+ <Ye size={14}color={e.white}/>
199
+ <S style={t.saveBtnText}>Save Key</S>
200
+ </B>
201
+ </T>
202
+ </T>
203
+ </T>
204
+ </Le>
205
+ </T>});const t=Ee.create({container:{flex:1,backgroundColor:e.grayBackground},driverTabsWrapper:{backgroundColor:e.primaryLight,borderBottomWidth:1,borderBottomColor:e.dividerColor,paddingVertical:8},driverTabsContainer:{paddingHorizontal:12,flexDirection:"row",alignItems:"center",gap:6},driverTabPill:{flexDirection:"row",alignItems:"center",gap:6,paddingHorizontal:11,paddingVertical:6,borderRadius:8,backgroundColor:e.grayBackground,borderWidth:1,borderColor:e.grayBorderSecondary},driverTabPillActive:{backgroundColor:e.purple,borderColor:e.purple},driverTabText:{fontFamily:x.interBold,fontSize:11.5,color:e.grayText},driverTabTextActive:{color:e.white},driverCountBadge:{backgroundColor:"rgba(255, 255, 255, 0.25)",paddingHorizontal:5,paddingVertical:1,borderRadius:6},driverCountText:{fontFamily:x.interBold,fontSize:9,color:e.white},instancePill:{paddingHorizontal:7,paddingVertical:3,borderRadius:6,backgroundColor:`${e.purple}14`,borderWidth:1,borderColor:`${e.purple}30`},instancePillActive:{backgroundColor:e.purple,borderColor:e.purple},instancePillText:{fontFamily:x.interBold,fontSize:10,color:e.purple},instancePillTextActive:{color:e.white},actionBar:{flexDirection:"row",alignItems:"center",paddingHorizontal:12,paddingVertical:8,backgroundColor:e.primaryLight,borderBottomWidth:1,borderBottomColor:e.dividerColor,gap:6},searchBar:{flex:1,flexDirection:"row",alignItems:"center",backgroundColor:e.grayBackground,borderRadius:8,paddingHorizontal:9,paddingVertical:le.OS==="ios"?6:2,borderWidth:1,borderColor:e.grayBorderSecondary,gap:6},searchInput:{flex:1,fontFamily:x.interMedium,fontSize:12,color:e.primaryBlack,padding:0},addKeyBtn:{flexDirection:"row",alignItems:"center",gap:4,paddingHorizontal:10,paddingVertical:6,borderRadius:8,backgroundColor:e.purple},addKeyBtnText:{fontFamily:x.interBold,fontSize:11,color:e.white},actionIconBtn:{width:30,height:30,borderRadius:8,alignItems:"center",justifyContent:"center",backgroundColor:e.grayBackground,borderWidth:1,borderColor:e.grayBorderSecondary},statsStrip:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",paddingHorizontal:12,paddingVertical:5,backgroundColor:`${e.grayBorderSecondary}40`},statsText:{fontFamily:x.interMedium,fontSize:10,color:e.grayText},statsSubtext:{fontFamily:x.interBold,fontSize:9.5,color:e.grayTextWeak},scrollArea:{flex:1},scrollContent:{padding:12,gap:10,paddingBottom:100},entryCard:{backgroundColor:e.primaryLight,borderRadius:10,borderWidth:1,borderColor:e.grayBorderSecondary,padding:10,gap:8,shadowColor:e.black,shadowOpacity:.02,shadowRadius:3,shadowOffset:{width:0,height:1},elevation:1},entryHeader:{flexDirection:"row",alignItems:"center",justifyContent:"space-between"},entryKey:{fontFamily:x.interBold,fontSize:12.5,color:e.primaryBlack},typeBadge:{paddingHorizontal:5,paddingVertical:1,borderRadius:4,borderWidth:1},typeBadgeText:{fontFamily:x.interBold,fontSize:8.5},sizeText:{fontFamily:x.interRegular,fontSize:10,color:e.grayTextWeak},entryActions:{flexDirection:"row",alignItems:"center",gap:5},entryActionBtn:{padding:5,borderRadius:5,backgroundColor:e.grayBackground},valuePreviewBox:{backgroundColor:e.grayBackground,borderRadius:6,padding:8,borderWidth:1,borderColor:`${e.grayBorderSecondary}80`},valuePreviewText:{fontFamily:x.interRegular,fontSize:11,color:e.primaryBlack,lineHeight:16},expandHint:{fontFamily:x.interBold,fontSize:9.5,color:e.purple,marginTop:4},loadingContainer:{flex:1,alignItems:"center",justifyContent:"center",gap:8},loadingText:{fontFamily:x.interMedium,fontSize:12,color:e.grayText},emptyContainer:{padding:24,alignItems:"center",justifyContent:"center"},emptyIconWrap:{width:56,height:56,borderRadius:28,backgroundColor:`${e.grayBorderSecondary}40`,alignItems:"center",justifyContent:"center",marginBottom:12},emptyTitle:{fontFamily:x.interBold,fontSize:14,color:e.primaryBlack,marginBottom:4},emptySubtitle:{fontFamily:x.interRegular,fontSize:11.5,color:e.grayText,textAlign:"center",maxWidth:280},connectGuideCard:{marginTop:20,width:"100%",backgroundColor:e.primaryLight,borderRadius:10,borderWidth:1,borderColor:e.grayBorderSecondary,padding:12,gap:6},connectGuideTitle:{fontFamily:x.interBold,fontSize:11,color:e.purple},connectGuideCode:{fontFamily:x.interRegular,fontSize:10,color:e.grayText,lineHeight:15},modalOverlay:{flex:1,backgroundColor:"rgba(0, 0, 0, 0.5)",justifyContent:"center",alignItems:"center",padding:16},modalCard:{width:"100%",maxWidth:400,backgroundColor:e.primaryLight,borderRadius:14,padding:16,gap:12,shadowColor:e.black,shadowOpacity:.2,shadowRadius:10,shadowOffset:{width:0,height:4},elevation:5},modalHeader:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",borderBottomWidth:1,borderBottomColor:e.dividerColor,paddingBottom:10},modalTitle:{fontFamily:x.interBold,fontSize:14,color:e.primaryBlack},inputGroup:{gap:4},inputLabel:{fontFamily:x.interBold,fontSize:9.5,color:e.grayTextWeak,letterSpacing:.5},textInput:{backgroundColor:e.grayBackground,borderRadius:8,paddingHorizontal:10,paddingVertical:8,fontFamily:x.interMedium,fontSize:12,color:e.primaryBlack,borderWidth:1,borderColor:e.grayBorderSecondary},textInputDisabled:{backgroundColor:`${e.grayBorderSecondary}40`,color:e.grayText},textAreaInput:{minHeight:90,maxHeight:160,fontFamily:x.interRegular,fontSize:11},typeSelectorStrip:{flexDirection:"row",alignItems:"center",gap:6},typePill:{flex:1,alignItems:"center",paddingVertical:6,borderRadius:6,backgroundColor:e.grayBackground,borderWidth:1,borderColor:e.grayBorderSecondary},typePillActive:{backgroundColor:e.purple,borderColor:e.purple},typePillText:{fontFamily:x.interBold,fontSize:10,color:e.grayText},typePillTextActive:{color:e.white},formatJsonBtn:{fontFamily:x.interBold,fontSize:10,color:e.purple},errorText:{fontFamily:x.interMedium,fontSize:10,color:e.errorColor,marginTop:2},modalActions:{flexDirection:"row",alignItems:"center",gap:10,marginTop:4},cancelBtn:{flex:1,alignItems:"center",paddingVertical:10,borderRadius:8,backgroundColor:e.grayBackground,borderWidth:1,borderColor:e.grayBorderSecondary},cancelBtnText:{fontFamily:x.interBold,fontSize:12,color:e.grayText},saveBtn:{flex:1.5,flexDirection:"row",alignItems:"center",justifyContent:"center",gap:5,paddingVertical:10,borderRadius:8,backgroundColor:e.purple},saveBtnText:{fontFamily:x.interBold,fontSize:12,color:e.white}});export default StorageTab;