react-native-inapp-inspector 1.1.18 → 1.1.19

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 (291) hide show
  1. package/dist/commonjs/constants/version.d.ts +1 -1
  2. package/dist/commonjs/constants/version.js +1 -1
  3. package/dist/esm/constants/version.d.ts +1 -1
  4. package/dist/esm/constants/version.js +1 -1
  5. package/package.json +2 -4
  6. package/assets/banner_dark.svg +0 -186
  7. package/assets/banner_light.svg +0 -186
  8. package/assets/icon_circle.svg +0 -148
  9. package/assets/icon_square.svg +0 -148
  10. package/assets/social_preview.png +0 -0
  11. package/assets/walkthrough.gif +0 -0
  12. package/dist/commonjs/assets/svgAssets.d.ts +0 -3
  13. package/dist/commonjs/assets/svgAssets.js +0 -17
  14. package/dist/commonjs/components/AnalyticsTabView.d.ts +0 -15
  15. package/dist/commonjs/components/AnalyticsTabView.js +0 -157
  16. package/dist/commonjs/components/ApiDetailView.d.ts +0 -22
  17. package/dist/commonjs/components/ApiDetailView.js +0 -304
  18. package/dist/commonjs/components/ApisTabView.d.ts +0 -33
  19. package/dist/commonjs/components/ApisTabView.js +0 -235
  20. package/dist/commonjs/components/ConsoleLogDetailView.d.ts +0 -9
  21. package/dist/commonjs/components/ConsoleLogDetailView.js +0 -278
  22. package/dist/commonjs/components/ConsoleLogsTabView.d.ts +0 -24
  23. package/dist/commonjs/components/ConsoleLogsTabView.js +0 -354
  24. package/dist/commonjs/components/FloatingBubble.d.ts +0 -14
  25. package/dist/commonjs/components/FloatingBubble.js +0 -75
  26. package/dist/commonjs/components/Inspector/InsightsDashboard.d.ts +0 -3
  27. package/dist/commonjs/components/Inspector/InsightsDashboard.js +0 -619
  28. package/dist/commonjs/components/Inspector/WebViewTab.d.ts +0 -3
  29. package/dist/commonjs/components/Inspector/WebViewTab.js +0 -757
  30. package/dist/commonjs/components/InspectorHeader.d.ts +0 -19
  31. package/dist/commonjs/components/InspectorHeader.js +0 -329
  32. package/dist/commonjs/components/InspectorTabBar.d.ts +0 -16
  33. package/dist/commonjs/components/InspectorTabBar.js +0 -90
  34. package/dist/commonjs/components/NavigationTracker.d.ts +0 -7
  35. package/dist/commonjs/components/NavigationTracker.js +0 -76
  36. package/dist/commonjs/components/ReduxTabView.d.ts +0 -9
  37. package/dist/commonjs/components/ReduxTabView.js +0 -56
  38. package/dist/commonjs/components/ReduxTreeView.d.ts +0 -16
  39. package/dist/commonjs/components/ReduxTreeView.js +0 -1257
  40. package/dist/commonjs/components/SettingsView.d.ts +0 -13
  41. package/dist/commonjs/components/SettingsView.js +0 -328
  42. package/dist/commonjs/customHooks/webViewLogger.d.ts +0 -24
  43. package/dist/commonjs/customHooks/webViewLogger.js +0 -452
  44. package/dist/commonjs/enums/index.d.ts +0 -39
  45. package/dist/commonjs/enums/index.js +0 -50
  46. package/dist/commonjs/i18n/en.json +0 -144
  47. package/dist/esm/assets/svgAssets.d.ts +0 -3
  48. package/dist/esm/assets/svgAssets.js +0 -14
  49. package/dist/esm/components/AnalyticsTabView.d.ts +0 -15
  50. package/dist/esm/components/AnalyticsTabView.js +0 -151
  51. package/dist/esm/components/ApiDetailView.d.ts +0 -22
  52. package/dist/esm/components/ApiDetailView.js +0 -264
  53. package/dist/esm/components/ApisTabView.d.ts +0 -33
  54. package/dist/esm/components/ApisTabView.js +0 -196
  55. package/dist/esm/components/ConsoleLogDetailView.d.ts +0 -9
  56. package/dist/esm/components/ConsoleLogDetailView.js +0 -271
  57. package/dist/esm/components/ConsoleLogsTabView.d.ts +0 -24
  58. package/dist/esm/components/ConsoleLogsTabView.js +0 -348
  59. package/dist/esm/components/FloatingBubble.d.ts +0 -14
  60. package/dist/esm/components/FloatingBubble.js +0 -68
  61. package/dist/esm/components/Inspector/InsightsDashboard.d.ts +0 -3
  62. package/dist/esm/components/Inspector/InsightsDashboard.js +0 -614
  63. package/dist/esm/components/Inspector/WebViewTab.d.ts +0 -3
  64. package/dist/esm/components/Inspector/WebViewTab.js +0 -752
  65. package/dist/esm/components/InspectorHeader.d.ts +0 -19
  66. package/dist/esm/components/InspectorHeader.js +0 -323
  67. package/dist/esm/components/InspectorTabBar.d.ts +0 -16
  68. package/dist/esm/components/InspectorTabBar.js +0 -84
  69. package/dist/esm/components/NavigationTracker.d.ts +0 -7
  70. package/dist/esm/components/NavigationTracker.js +0 -39
  71. package/dist/esm/components/ReduxTabView.d.ts +0 -9
  72. package/dist/esm/components/ReduxTabView.js +0 -50
  73. package/dist/esm/components/ReduxTreeView.d.ts +0 -16
  74. package/dist/esm/components/ReduxTreeView.js +0 -1218
  75. package/dist/esm/components/SettingsView.d.ts +0 -13
  76. package/dist/esm/components/SettingsView.js +0 -321
  77. package/dist/esm/customHooks/webViewLogger.d.ts +0 -24
  78. package/dist/esm/customHooks/webViewLogger.js +0 -405
  79. package/dist/esm/enums/index.d.ts +0 -39
  80. package/dist/esm/enums/index.js +0 -47
  81. package/dist/esm/i18n/en.json +0 -144
  82. package/example/.bundle/config +0 -2
  83. package/example/.eslintrc.js +0 -4
  84. package/example/.prettierrc.js +0 -5
  85. package/example/.watchmanconfig +0 -1
  86. package/example/App.tsx +0 -879
  87. package/example/Gemfile +0 -17
  88. package/example/README.md +0 -53
  89. package/example/__tests__/App.test.tsx +0 -13
  90. package/example/android/app/build.gradle +0 -147
  91. package/example/android/app/debug.keystore +0 -0
  92. package/example/android/app/proguard-rules.pro +0 -10
  93. package/example/android/app/src/main/AndroidManifest.xml +0 -27
  94. package/example/android/app/src/main/java/com/example/MainActivity.kt +0 -22
  95. package/example/android/app/src/main/java/com/example/MainApplication.kt +0 -52
  96. package/example/android/app/src/main/res/drawable/rn_edit_text_material.xml +0 -37
  97. package/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
  98. package/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
  99. package/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
  100. package/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
  101. package/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
  102. package/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
  103. package/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
  104. package/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
  105. package/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
  106. package/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
  107. package/example/android/app/src/main/res/values/strings.xml +0 -3
  108. package/example/android/app/src/main/res/values/styles.xml +0 -9
  109. package/example/android/build.gradle +0 -48
  110. package/example/android/gradle/wrapper/gradle-wrapper.jar +0 -0
  111. package/example/android/gradle/wrapper/gradle-wrapper.properties +0 -7
  112. package/example/android/gradle.properties +0 -45
  113. package/example/android/gradlew +0 -248
  114. package/example/android/gradlew.bat +0 -98
  115. package/example/android/settings.gradle +0 -25
  116. package/example/app.json +0 -4
  117. package/example/assets/app_icon.png +0 -0
  118. package/example/babel.config.js +0 -3
  119. package/example/guidance/Video-WalkThrough.mp4 +0 -0
  120. package/example/index.js +0 -9
  121. package/example/ios/.xcode.env +0 -11
  122. package/example/ios/Podfile +0 -34
  123. package/example/ios/Podfile.lock +0 -2303
  124. package/example/ios/example/AppDelegate.swift +0 -48
  125. package/example/ios/example/Images.xcassets/AppIcon.appiconset/Contents.json +0 -62
  126. package/example/ios/example/Images.xcassets/AppIcon.appiconset/app_icon_1024.png +0 -0
  127. package/example/ios/example/Images.xcassets/Contents.json +0 -6
  128. package/example/ios/example/Info.plist +0 -60
  129. package/example/ios/example/LaunchScreen.storyboard +0 -47
  130. package/example/ios/example/PrivacyInfo.xcprivacy +0 -37
  131. package/example/ios/example.xcodeproj/project.pbxproj +0 -498
  132. package/example/ios/example.xcodeproj/xcshareddata/xcschemes/example.xcscheme +0 -88
  133. package/example/ios/example.xcworkspace/contents.xcworkspacedata +0 -10
  134. package/example/jest.config.js +0 -3
  135. package/example/metro.config.js +0 -45
  136. package/example/package-lock.json +0 -13508
  137. package/example/package.json +0 -54
  138. package/example/polyfill.js +0 -13
  139. package/example/tsconfig.json +0 -8
  140. package/fonts/Inter/Inter.ttc +0 -0
  141. package/fonts/Inter/InterVariable-Italic.ttf +0 -0
  142. package/fonts/Inter/InterVariable.ttf +0 -0
  143. package/fonts/Inter/LICENSE.txt +0 -92
  144. package/fonts/Inter/extras/otf/Inter-Black.otf +0 -0
  145. package/fonts/Inter/extras/otf/Inter-BlackItalic.otf +0 -0
  146. package/fonts/Inter/extras/otf/Inter-Bold.otf +0 -0
  147. package/fonts/Inter/extras/otf/Inter-BoldItalic.otf +0 -0
  148. package/fonts/Inter/extras/otf/Inter-ExtraBold.otf +0 -0
  149. package/fonts/Inter/extras/otf/Inter-ExtraBoldItalic.otf +0 -0
  150. package/fonts/Inter/extras/otf/Inter-ExtraLight.otf +0 -0
  151. package/fonts/Inter/extras/otf/Inter-ExtraLightItalic.otf +0 -0
  152. package/fonts/Inter/extras/otf/Inter-Italic.otf +0 -0
  153. package/fonts/Inter/extras/otf/Inter-Light.otf +0 -0
  154. package/fonts/Inter/extras/otf/Inter-LightItalic.otf +0 -0
  155. package/fonts/Inter/extras/otf/Inter-Medium.otf +0 -0
  156. package/fonts/Inter/extras/otf/Inter-MediumItalic.otf +0 -0
  157. package/fonts/Inter/extras/otf/Inter-Regular.otf +0 -0
  158. package/fonts/Inter/extras/otf/Inter-SemiBold.otf +0 -0
  159. package/fonts/Inter/extras/otf/Inter-SemiBoldItalic.otf +0 -0
  160. package/fonts/Inter/extras/otf/Inter-Thin.otf +0 -0
  161. package/fonts/Inter/extras/otf/Inter-ThinItalic.otf +0 -0
  162. package/fonts/Inter/extras/otf/InterDisplay-Black.otf +0 -0
  163. package/fonts/Inter/extras/otf/InterDisplay-BlackItalic.otf +0 -0
  164. package/fonts/Inter/extras/otf/InterDisplay-Bold.otf +0 -0
  165. package/fonts/Inter/extras/otf/InterDisplay-BoldItalic.otf +0 -0
  166. package/fonts/Inter/extras/otf/InterDisplay-ExtraBold.otf +0 -0
  167. package/fonts/Inter/extras/otf/InterDisplay-ExtraBoldItalic.otf +0 -0
  168. package/fonts/Inter/extras/otf/InterDisplay-ExtraLight.otf +0 -0
  169. package/fonts/Inter/extras/otf/InterDisplay-ExtraLightItalic.otf +0 -0
  170. package/fonts/Inter/extras/otf/InterDisplay-Italic.otf +0 -0
  171. package/fonts/Inter/extras/otf/InterDisplay-Light.otf +0 -0
  172. package/fonts/Inter/extras/otf/InterDisplay-LightItalic.otf +0 -0
  173. package/fonts/Inter/extras/otf/InterDisplay-Medium.otf +0 -0
  174. package/fonts/Inter/extras/otf/InterDisplay-MediumItalic.otf +0 -0
  175. package/fonts/Inter/extras/otf/InterDisplay-Regular.otf +0 -0
  176. package/fonts/Inter/extras/otf/InterDisplay-SemiBold.otf +0 -0
  177. package/fonts/Inter/extras/otf/InterDisplay-SemiBoldItalic.otf +0 -0
  178. package/fonts/Inter/extras/otf/InterDisplay-Thin.otf +0 -0
  179. package/fonts/Inter/extras/otf/InterDisplay-ThinItalic.otf +0 -0
  180. package/fonts/Inter/extras/ttf/Inter-Black.ttf +0 -0
  181. package/fonts/Inter/extras/ttf/Inter-BlackItalic.ttf +0 -0
  182. package/fonts/Inter/extras/ttf/Inter-Bold.ttf +0 -0
  183. package/fonts/Inter/extras/ttf/Inter-BoldItalic.ttf +0 -0
  184. package/fonts/Inter/extras/ttf/Inter-ExtraBold.ttf +0 -0
  185. package/fonts/Inter/extras/ttf/Inter-ExtraBoldItalic.ttf +0 -0
  186. package/fonts/Inter/extras/ttf/Inter-ExtraLight.ttf +0 -0
  187. package/fonts/Inter/extras/ttf/Inter-ExtraLightItalic.ttf +0 -0
  188. package/fonts/Inter/extras/ttf/Inter-Italic.ttf +0 -0
  189. package/fonts/Inter/extras/ttf/Inter-Light.ttf +0 -0
  190. package/fonts/Inter/extras/ttf/Inter-LightItalic.ttf +0 -0
  191. package/fonts/Inter/extras/ttf/Inter-Medium.ttf +0 -0
  192. package/fonts/Inter/extras/ttf/Inter-MediumItalic.ttf +0 -0
  193. package/fonts/Inter/extras/ttf/Inter-Regular.ttf +0 -0
  194. package/fonts/Inter/extras/ttf/Inter-SemiBold.ttf +0 -0
  195. package/fonts/Inter/extras/ttf/Inter-SemiBoldItalic.ttf +0 -0
  196. package/fonts/Inter/extras/ttf/Inter-Thin.ttf +0 -0
  197. package/fonts/Inter/extras/ttf/Inter-ThinItalic.ttf +0 -0
  198. package/fonts/Inter/extras/ttf/InterDisplay-Black.ttf +0 -0
  199. package/fonts/Inter/extras/ttf/InterDisplay-BlackItalic.ttf +0 -0
  200. package/fonts/Inter/extras/ttf/InterDisplay-Bold.ttf +0 -0
  201. package/fonts/Inter/extras/ttf/InterDisplay-BoldItalic.ttf +0 -0
  202. package/fonts/Inter/extras/ttf/InterDisplay-ExtraBold.ttf +0 -0
  203. package/fonts/Inter/extras/ttf/InterDisplay-ExtraBoldItalic.ttf +0 -0
  204. package/fonts/Inter/extras/ttf/InterDisplay-ExtraLight.ttf +0 -0
  205. package/fonts/Inter/extras/ttf/InterDisplay-ExtraLightItalic.ttf +0 -0
  206. package/fonts/Inter/extras/ttf/InterDisplay-Italic.ttf +0 -0
  207. package/fonts/Inter/extras/ttf/InterDisplay-Light.ttf +0 -0
  208. package/fonts/Inter/extras/ttf/InterDisplay-LightItalic.ttf +0 -0
  209. package/fonts/Inter/extras/ttf/InterDisplay-Medium.ttf +0 -0
  210. package/fonts/Inter/extras/ttf/InterDisplay-MediumItalic.ttf +0 -0
  211. package/fonts/Inter/extras/ttf/InterDisplay-Regular.ttf +0 -0
  212. package/fonts/Inter/extras/ttf/InterDisplay-SemiBold.ttf +0 -0
  213. package/fonts/Inter/extras/ttf/InterDisplay-SemiBoldItalic.ttf +0 -0
  214. package/fonts/Inter/extras/ttf/InterDisplay-Thin.ttf +0 -0
  215. package/fonts/Inter/extras/ttf/InterDisplay-ThinItalic.ttf +0 -0
  216. package/fonts/Inter/extras/woff-hinted/Inter-Black.woff2 +0 -0
  217. package/fonts/Inter/extras/woff-hinted/Inter-BlackItalic.woff2 +0 -0
  218. package/fonts/Inter/extras/woff-hinted/Inter-Bold.woff2 +0 -0
  219. package/fonts/Inter/extras/woff-hinted/Inter-BoldItalic.woff2 +0 -0
  220. package/fonts/Inter/extras/woff-hinted/Inter-ExtraBold.woff2 +0 -0
  221. package/fonts/Inter/extras/woff-hinted/Inter-ExtraBoldItalic.woff2 +0 -0
  222. package/fonts/Inter/extras/woff-hinted/Inter-ExtraLight.woff2 +0 -0
  223. package/fonts/Inter/extras/woff-hinted/Inter-ExtraLightItalic.woff2 +0 -0
  224. package/fonts/Inter/extras/woff-hinted/Inter-Italic.woff2 +0 -0
  225. package/fonts/Inter/extras/woff-hinted/Inter-Light.woff2 +0 -0
  226. package/fonts/Inter/extras/woff-hinted/Inter-LightItalic.woff2 +0 -0
  227. package/fonts/Inter/extras/woff-hinted/Inter-Medium.woff2 +0 -0
  228. package/fonts/Inter/extras/woff-hinted/Inter-MediumItalic.woff2 +0 -0
  229. package/fonts/Inter/extras/woff-hinted/Inter-Regular.woff2 +0 -0
  230. package/fonts/Inter/extras/woff-hinted/Inter-SemiBold.woff2 +0 -0
  231. package/fonts/Inter/extras/woff-hinted/Inter-SemiBoldItalic.woff2 +0 -0
  232. package/fonts/Inter/extras/woff-hinted/Inter-Thin.woff2 +0 -0
  233. package/fonts/Inter/extras/woff-hinted/Inter-ThinItalic.woff2 +0 -0
  234. package/fonts/Inter/extras/woff-hinted/InterDisplay-Black.woff2 +0 -0
  235. package/fonts/Inter/extras/woff-hinted/InterDisplay-BlackItalic.woff2 +0 -0
  236. package/fonts/Inter/extras/woff-hinted/InterDisplay-Bold.woff2 +0 -0
  237. package/fonts/Inter/extras/woff-hinted/InterDisplay-BoldItalic.woff2 +0 -0
  238. package/fonts/Inter/extras/woff-hinted/InterDisplay-ExtraBold.woff2 +0 -0
  239. package/fonts/Inter/extras/woff-hinted/InterDisplay-ExtraBoldItalic.woff2 +0 -0
  240. package/fonts/Inter/extras/woff-hinted/InterDisplay-ExtraLight.woff2 +0 -0
  241. package/fonts/Inter/extras/woff-hinted/InterDisplay-ExtraLightItalic.woff2 +0 -0
  242. package/fonts/Inter/extras/woff-hinted/InterDisplay-Italic.woff2 +0 -0
  243. package/fonts/Inter/extras/woff-hinted/InterDisplay-Light.woff2 +0 -0
  244. package/fonts/Inter/extras/woff-hinted/InterDisplay-LightItalic.woff2 +0 -0
  245. package/fonts/Inter/extras/woff-hinted/InterDisplay-Medium.woff2 +0 -0
  246. package/fonts/Inter/extras/woff-hinted/InterDisplay-MediumItalic.woff2 +0 -0
  247. package/fonts/Inter/extras/woff-hinted/InterDisplay-Regular.woff2 +0 -0
  248. package/fonts/Inter/extras/woff-hinted/InterDisplay-SemiBold.woff2 +0 -0
  249. package/fonts/Inter/extras/woff-hinted/InterDisplay-SemiBoldItalic.woff2 +0 -0
  250. package/fonts/Inter/extras/woff-hinted/InterDisplay-Thin.woff2 +0 -0
  251. package/fonts/Inter/extras/woff-hinted/InterDisplay-ThinItalic.woff2 +0 -0
  252. package/fonts/Inter/help.txt +0 -165
  253. package/fonts/Inter/web/Inter-Black.woff2 +0 -0
  254. package/fonts/Inter/web/Inter-BlackItalic.woff2 +0 -0
  255. package/fonts/Inter/web/Inter-Bold.woff2 +0 -0
  256. package/fonts/Inter/web/Inter-BoldItalic.woff2 +0 -0
  257. package/fonts/Inter/web/Inter-ExtraBold.woff2 +0 -0
  258. package/fonts/Inter/web/Inter-ExtraBoldItalic.woff2 +0 -0
  259. package/fonts/Inter/web/Inter-ExtraLight.woff2 +0 -0
  260. package/fonts/Inter/web/Inter-ExtraLightItalic.woff2 +0 -0
  261. package/fonts/Inter/web/Inter-Italic.woff2 +0 -0
  262. package/fonts/Inter/web/Inter-Light.woff2 +0 -0
  263. package/fonts/Inter/web/Inter-LightItalic.woff2 +0 -0
  264. package/fonts/Inter/web/Inter-Medium.woff2 +0 -0
  265. package/fonts/Inter/web/Inter-MediumItalic.woff2 +0 -0
  266. package/fonts/Inter/web/Inter-Regular.woff2 +0 -0
  267. package/fonts/Inter/web/Inter-SemiBold.woff2 +0 -0
  268. package/fonts/Inter/web/Inter-SemiBoldItalic.woff2 +0 -0
  269. package/fonts/Inter/web/Inter-Thin.woff2 +0 -0
  270. package/fonts/Inter/web/Inter-ThinItalic.woff2 +0 -0
  271. package/fonts/Inter/web/InterDisplay-Black.woff2 +0 -0
  272. package/fonts/Inter/web/InterDisplay-BlackItalic.woff2 +0 -0
  273. package/fonts/Inter/web/InterDisplay-Bold.woff2 +0 -0
  274. package/fonts/Inter/web/InterDisplay-BoldItalic.woff2 +0 -0
  275. package/fonts/Inter/web/InterDisplay-ExtraBold.woff2 +0 -0
  276. package/fonts/Inter/web/InterDisplay-ExtraBoldItalic.woff2 +0 -0
  277. package/fonts/Inter/web/InterDisplay-ExtraLight.woff2 +0 -0
  278. package/fonts/Inter/web/InterDisplay-ExtraLightItalic.woff2 +0 -0
  279. package/fonts/Inter/web/InterDisplay-Italic.woff2 +0 -0
  280. package/fonts/Inter/web/InterDisplay-Light.woff2 +0 -0
  281. package/fonts/Inter/web/InterDisplay-LightItalic.woff2 +0 -0
  282. package/fonts/Inter/web/InterDisplay-Medium.woff2 +0 -0
  283. package/fonts/Inter/web/InterDisplay-MediumItalic.woff2 +0 -0
  284. package/fonts/Inter/web/InterDisplay-Regular.woff2 +0 -0
  285. package/fonts/Inter/web/InterDisplay-SemiBold.woff2 +0 -0
  286. package/fonts/Inter/web/InterDisplay-SemiBoldItalic.woff2 +0 -0
  287. package/fonts/Inter/web/InterDisplay-Thin.woff2 +0 -0
  288. package/fonts/Inter/web/InterDisplay-ThinItalic.woff2 +0 -0
  289. package/fonts/Inter/web/InterVariable-Italic.woff2 +0 -0
  290. package/fonts/Inter/web/InterVariable.woff2 +0 -0
  291. package/fonts/Inter/web/inter.css +0 -148
@@ -1,614 +0,0 @@
1
- import React from 'react';
2
- import { ScrollView, Text, TouchableOpacity, View } from 'react-native';
3
- import { animateNextLayout, useInspector } from './InspectorContext';
4
- import TouchableScale from '../TouchableScale';
5
- import styles from '../../styles';
6
- import { AppColors } from '../../styles/AppColors';
7
- import { AppFonts } from '../../styles/AppFonts';
8
- import { getSize } from '../../helpers';
9
- import { SignalIcon, TerminalIcon, AnalyticsIcon, GlobeIcon, } from '../NetworkIcons';
10
- const InsightsDashboard = () => {
11
- const { logs, visibleConsoleLogs, analyticsEvents, webViewNavHistory, tabVisibility, slowRequestThreshold, insightsActiveSubTab, setInsightsActiveSubTab, switchActiveTab, reduxState, } = useInspector();
12
- const apiTotal = logs.length;
13
- const apiErrors = logs.filter(l => (l.status != null && l.status >= 400) ||
14
- l.status === 0 ||
15
- l.status == null).length;
16
- const apiSuccess = apiTotal - apiErrors;
17
- const apiSuccessRate = apiTotal > 0 ? Math.round((apiSuccess / apiTotal) * 100) : 100;
18
- const durations = logs
19
- .filter(l => l.duration != null)
20
- .map(l => l.duration);
21
- const avgTime = durations.length > 0
22
- ? Math.round(durations.reduce((a, b) => a + b, 0) / durations.length)
23
- : null;
24
- const logTotal = visibleConsoleLogs.length;
25
- const logErrors = visibleConsoleLogs.filter(l => l.type === 'error').length;
26
- const logWarns = visibleConsoleLogs.filter(l => l.type === 'warn').length;
27
- const logInfos = visibleConsoleLogs.filter(l => l.type === 'info').length;
28
- const analyticsTotal = analyticsEvents.length;
29
- const uniqueEvents = new Set(analyticsEvents.map(e => e.name)).size;
30
- const screenViews = analyticsEvents.filter(e => e.name === 'screen_view' ||
31
- e.name === 'page_view' ||
32
- e.name === 'firebase_screen_class').length;
33
- const webviewTotal = webViewNavHistory.length;
34
- // --- Richer insights metrics ---
35
- const slowestTime = durations.length > 0 ? Math.max(...durations) : null;
36
- const fastestTime = durations.length > 0 ? Math.min(...durations) : null;
37
- const slowCount = durations.filter(d => d >= slowRequestThreshold).length;
38
- const status2xx = logs.filter(l => l.status != null && l.status >= 200 && l.status < 300).length;
39
- const status3xx = logs.filter(l => l.status != null && l.status >= 300 && l.status < 400).length;
40
- const status4xx = logs.filter(l => l.status != null && l.status >= 400 && l.status < 500).length;
41
- const status5xx = logs.filter(l => l.status != null && l.status >= 500).length;
42
- const totalSignals = apiTotal + logTotal + analyticsTotal + webviewTotal;
43
- const totalIssues = apiErrors + logErrors;
44
- const activeModules = [
45
- tabVisibility?.apis,
46
- tabVisibility?.logs,
47
- tabVisibility?.analytics,
48
- tabVisibility?.webview,
49
- tabVisibility?.redux,
50
- ].filter(Boolean).length;
51
- // Composite health score: success rate penalised by error volume and slow requests.
52
- const healthScore = totalSignals === 0
53
- ? 100
54
- : Math.max(0, Math.min(100, Math.round(apiSuccessRate -
55
- (logErrors > 0 ? Math.min(15, logErrors * 3) : 0) -
56
- (slowCount > 0 ? Math.min(10, slowCount * 2) : 0))));
57
- const healthColor = healthScore >= 90
58
- ? AppColors.greenColor
59
- : healthScore >= 70
60
- ? AppColors.warningIconGold
61
- : AppColors.errorColor;
62
- const healthLabel = healthScore >= 90
63
- ? 'Healthy'
64
- : healthScore >= 70
65
- ? 'Needs attention'
66
- : 'Degraded';
67
- return (<View style={styles.dashboardContainer}>
68
- {/* Overview hero card */}
69
- <View style={{
70
- backgroundColor: AppColors.primaryLight,
71
- borderRadius: 14,
72
- borderWidth: 1,
73
- borderColor: AppColors.grayBorderSecondary,
74
- padding: 16,
75
- marginBottom: 12,
76
- }}>
77
- <View style={{
78
- flexDirection: 'row',
79
- alignItems: 'center',
80
- gap: 14,
81
- }}>
82
- {/* Health ring stand-in */}
83
- <View style={{
84
- width: 64,
85
- height: 64,
86
- borderRadius: 32,
87
- borderWidth: 4,
88
- borderColor: healthColor,
89
- alignItems: 'center',
90
- justifyContent: 'center',
91
- backgroundColor: AppColors.purpleShade50,
92
- }}>
93
- <Text style={{
94
- fontFamily: AppFonts.interBold,
95
- fontSize: 18,
96
- color: healthColor,
97
- }}>
98
- {healthScore}
99
- </Text>
100
- <Text style={{
101
- fontFamily: AppFonts.interMedium,
102
- fontSize: 7.5,
103
- color: AppColors.grayTextWeak,
104
- letterSpacing: 0.4,
105
- }}>
106
- HEALTH
107
- </Text>
108
- </View>
109
- <View style={{ flex: 1 }}>
110
- <Text style={{
111
- fontFamily: AppFonts.interBold,
112
- fontSize: 15,
113
- color: AppColors.primaryBlack,
114
- }}>
115
- Session Overview
116
- </Text>
117
- <View style={{
118
- flexDirection: 'row',
119
- alignItems: 'center',
120
- gap: 6,
121
- marginTop: 3,
122
- }}>
123
- <View style={{
124
- width: 7,
125
- height: 7,
126
- borderRadius: 3.5,
127
- backgroundColor: healthColor,
128
- }}/>
129
- <Text style={{
130
- fontFamily: AppFonts.interMedium,
131
- fontSize: 11.5,
132
- color: healthColor,
133
- }}>
134
- {healthLabel}
135
- </Text>
136
- <Text style={{
137
- fontFamily: AppFonts.interRegular,
138
- fontSize: 11.5,
139
- color: AppColors.grayTextWeak,
140
- }}>
141
- • {activeModules} modules active
142
- </Text>
143
- </View>
144
- </View>
145
- </View>
146
-
147
- {/* Quick totals strip */}
148
- <View style={{
149
- flexDirection: 'row',
150
- marginTop: 14,
151
- borderTopWidth: 1,
152
- borderTopColor: AppColors.dividerColor,
153
- paddingTop: 12,
154
- }}>
155
- <View style={{ flex: 1, alignItems: 'center' }}>
156
- <Text style={{
157
- fontFamily: AppFonts.interBold,
158
- fontSize: 16,
159
- color: AppColors.primaryBlack,
160
- }}>
161
- {totalSignals}
162
- </Text>
163
- <Text style={{
164
- fontFamily: AppFonts.interRegular,
165
- fontSize: 10,
166
- color: AppColors.grayTextWeak,
167
- marginTop: 1,
168
- }}>
169
- Signals
170
- </Text>
171
- </View>
172
- <View style={{ width: 1, backgroundColor: AppColors.dividerColor }}/>
173
- <View style={{ flex: 1, alignItems: 'center' }}>
174
- <Text style={{
175
- fontFamily: AppFonts.interBold,
176
- fontSize: 16,
177
- color: totalIssues > 0
178
- ? AppColors.errorColor
179
- : AppColors.primaryBlack,
180
- }}>
181
- {totalIssues}
182
- </Text>
183
- <Text style={{
184
- fontFamily: AppFonts.interRegular,
185
- fontSize: 10,
186
- color: AppColors.grayTextWeak,
187
- marginTop: 1,
188
- }}>
189
- Issues
190
- </Text>
191
- </View>
192
- <View style={{ width: 1, backgroundColor: AppColors.dividerColor }}/>
193
- <View style={{ flex: 1, alignItems: 'center' }}>
194
- <Text style={{
195
- fontFamily: AppFonts.interBold,
196
- fontSize: 16,
197
- color: slowCount > 0
198
- ? AppColors.warningIconGold
199
- : AppColors.primaryBlack,
200
- }}>
201
- {slowCount}
202
- </Text>
203
- <Text style={{
204
- fontFamily: AppFonts.interRegular,
205
- fontSize: 10,
206
- color: AppColors.grayTextWeak,
207
- marginTop: 1,
208
- }}>
209
- Slow ({slowRequestThreshold}ms+)
210
- </Text>
211
- </View>
212
- </View>
213
- </View>
214
-
215
- {/* ── Insights Sub-Tab Selector ── */}
216
- {(() => {
217
- const insightTabs = [
218
- {
219
- key: 'apis',
220
- label: 'APIs',
221
- icon: (c, s) => <SignalIcon color={c} size={s}/>,
222
- color: AppColors.purple,
223
- count: apiTotal,
224
- visible: !!tabVisibility?.apis,
225
- },
226
- {
227
- key: 'logs',
228
- label: 'Logs',
229
- icon: (c, s) => <TerminalIcon color={c} size={s}/>,
230
- color: '#0D9488',
231
- count: logTotal,
232
- visible: !!tabVisibility?.logs,
233
- },
234
- {
235
- key: 'analytics',
236
- label: 'Analytics',
237
- icon: (c, s) => <AnalyticsIcon color={c} size={s}/>,
238
- color: '#EA580C',
239
- count: analyticsTotal,
240
- visible: !!tabVisibility?.analytics,
241
- },
242
- {
243
- key: 'webview',
244
- label: 'WebView',
245
- icon: (c, s) => <GlobeIcon color={c} size={s}/>,
246
- color: '#2563EB',
247
- count: webviewTotal,
248
- visible: !!tabVisibility?.webview,
249
- },
250
- {
251
- key: 'redux',
252
- label: 'Redux',
253
- icon: (c, s) => <TerminalIcon color={c} size={s}/>,
254
- color: AppColors.purple,
255
- count: reduxState ? Object.keys(reduxState).length : 0,
256
- visible: !!tabVisibility?.redux,
257
- },
258
- ];
259
- const visibleTabs = insightTabs.filter(t => t.visible);
260
- if (visibleTabs.length === 0)
261
- return null;
262
- return (<>
263
- <ScrollView horizontal showsHorizontalScrollIndicator={false} contentContainerStyle={{
264
- paddingHorizontal: 2,
265
- paddingVertical: 2,
266
- gap: 8,
267
- }} style={{
268
- marginBottom: 12,
269
- flexGrow: 0,
270
- }}>
271
- {visibleTabs.map(tab => {
272
- const isActive = insightsActiveSubTab === tab.key;
273
- return (<TouchableOpacity key={tab.key} onPress={() => {
274
- animateNextLayout();
275
- setInsightsActiveSubTab(tab.key);
276
- }} activeOpacity={0.7} style={{
277
- flexDirection: 'row',
278
- alignItems: 'center',
279
- gap: 6,
280
- paddingHorizontal: 14,
281
- paddingVertical: 8,
282
- borderRadius: 20,
283
- backgroundColor: isActive
284
- ? tab.color
285
- : AppColors.primaryLight,
286
- borderWidth: 1,
287
- borderColor: isActive
288
- ? tab.color
289
- : AppColors.grayBorderSecondary,
290
- }}>
291
- {tab.icon(isActive ? '#FFFFFF' : tab.color, 14)}
292
- <Text style={{
293
- fontFamily: AppFonts.interBold,
294
- fontSize: 11.5,
295
- color: isActive ? '#FFFFFF' : AppColors.grayTextStrong,
296
- }}>
297
- {tab.label}
298
- </Text>
299
- <View style={{
300
- minWidth: 20,
301
- height: 18,
302
- borderRadius: 9,
303
- paddingHorizontal: 5,
304
- alignItems: 'center',
305
- justifyContent: 'center',
306
- backgroundColor: isActive
307
- ? 'rgba(255,255,255,0.25)'
308
- : AppColors.grayBackground,
309
- }}>
310
- <Text style={{
311
- fontFamily: AppFonts.interBold,
312
- fontSize: 9.5,
313
- color: isActive ? '#FFFFFF' : AppColors.grayTextWeak,
314
- }}>
315
- {tab.count}
316
- </Text>
317
- </View>
318
- </TouchableOpacity>);
319
- })}
320
- </ScrollView>
321
-
322
- {/* ── Active Module Card ── */}
323
- {insightsActiveSubTab === 'apis' && tabVisibility?.apis && (<TouchableScale style={styles.dashboardModuleCard} onPress={() => switchActiveTab('apis')}>
324
- <View style={styles.dashboardModuleHeader}>
325
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
326
- <SignalIcon color={AppColors.purple} size={18}/>
327
- <Text style={styles.dashboardModuleTitle}>APIs & Network</Text>
328
- </View>
329
- <Text style={styles.dashboardModuleGoText}>View Details →</Text>
330
- </View>
331
- <View style={styles.dashboardModuleGrid}>
332
- <View style={styles.dashboardGridItem}>
333
- <Text style={styles.dashboardGridVal}>{apiTotal}</Text>
334
- <Text style={styles.dashboardGridLbl}>Requests</Text>
335
- </View>
336
- <View style={styles.dashboardGridItem}>
337
- <Text style={[
338
- styles.dashboardGridVal,
339
- apiSuccessRate < 90 && { color: AppColors.warningIconGold },
340
- ]}>
341
- {apiSuccessRate}%
342
- </Text>
343
- <Text style={styles.dashboardGridLbl}>Success Rate</Text>
344
- </View>
345
- <View style={styles.dashboardGridItem}>
346
- <Text style={[
347
- styles.dashboardGridVal,
348
- apiErrors > 0 && { color: AppColors.errorColor },
349
- ]}>
350
- {apiErrors}
351
- </Text>
352
- <Text style={styles.dashboardGridLbl}>Errors</Text>
353
- </View>
354
- <View style={styles.dashboardGridItem}>
355
- <Text style={styles.dashboardGridVal}>
356
- {avgTime != null ? `${avgTime}ms` : '—'}
357
- </Text>
358
- <Text style={styles.dashboardGridLbl}>Avg Latency</Text>
359
- </View>
360
- </View>
361
-
362
- {/* Status-class breakdown + latency range */}
363
- <View style={{
364
- marginTop: 10,
365
- paddingTop: 10,
366
- borderTopWidth: 1,
367
- borderTopColor: AppColors.dividerColor,
368
- flexDirection: 'row',
369
- alignItems: 'center',
370
- flexWrap: 'wrap',
371
- gap: 6,
372
- }}>
373
- {[
374
- { label: '2xx', value: status2xx, color: AppColors.greenColor },
375
- { label: '3xx', value: status3xx, color: AppColors.skyBlue },
376
- {
377
- label: '4xx',
378
- value: status4xx,
379
- color: AppColors.warningIconGold,
380
- },
381
- { label: '5xx', value: status5xx, color: AppColors.errorColor },
382
- ].map(s => (<View key={s.label} style={{
383
- flexDirection: 'row',
384
- alignItems: 'center',
385
- gap: 4,
386
- backgroundColor: AppColors.grayBackground,
387
- borderRadius: 6,
388
- borderWidth: 1,
389
- borderColor: AppColors.dividerColor,
390
- paddingHorizontal: 7,
391
- paddingVertical: 3,
392
- }}>
393
- <View style={{
394
- width: 6,
395
- height: 6,
396
- borderRadius: 3,
397
- backgroundColor: s.color,
398
- }}/>
399
- <Text style={{
400
- fontFamily: AppFonts.interBold,
401
- fontSize: 10,
402
- color: AppColors.grayTextStrong,
403
- }}>
404
- {s.label} {s.value}
405
- </Text>
406
- </View>))}
407
- {slowestTime != null && (<View style={{
408
- marginLeft: 'auto',
409
- flexDirection: 'row',
410
- alignItems: 'center',
411
- gap: 4,
412
- }}>
413
- <Text style={{
414
- fontFamily: AppFonts.interRegular,
415
- fontSize: 10,
416
- color: AppColors.grayTextWeak,
417
- }}>
418
- Range
419
- </Text>
420
- <Text style={{
421
- fontFamily: AppFonts.interBold,
422
- fontSize: 10,
423
- color: AppColors.grayTextStrong,
424
- }}>
425
- {fastestTime}–{slowestTime}ms
426
- </Text>
427
- </View>)}
428
- </View>
429
- </TouchableScale>)}
430
-
431
- {insightsActiveSubTab === 'logs' && tabVisibility?.logs && (<TouchableScale style={styles.dashboardModuleCard} onPress={() => switchActiveTab('logs')}>
432
- <View style={styles.dashboardModuleHeader}>
433
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
434
- <TerminalIcon color="#0D9488" size={18}/>
435
- <Text style={styles.dashboardModuleTitle}>Console Logs</Text>
436
- </View>
437
- <Text style={styles.dashboardModuleGoText}>View Details →</Text>
438
- </View>
439
- <View style={styles.dashboardModuleGrid}>
440
- <View style={styles.dashboardGridItem}>
441
- <Text style={styles.dashboardGridVal}>{logTotal}</Text>
442
- <Text style={styles.dashboardGridLbl}>Total Logs</Text>
443
- </View>
444
- <View style={styles.dashboardGridItem}>
445
- <Text style={[styles.dashboardGridVal, { color: '#0D9488' }]}>
446
- {logInfos}
447
- </Text>
448
- <Text style={styles.dashboardGridLbl}>Info</Text>
449
- </View>
450
- <View style={styles.dashboardGridItem}>
451
- <Text style={[
452
- styles.dashboardGridVal,
453
- logWarns > 0 && { color: AppColors.warningIconGold },
454
- ]}>
455
- {logWarns}
456
- </Text>
457
- <Text style={styles.dashboardGridLbl}>Warnings</Text>
458
- </View>
459
- <View style={styles.dashboardGridItem}>
460
- <Text style={[
461
- styles.dashboardGridVal,
462
- logErrors > 0 && { color: AppColors.errorColor },
463
- ]}>
464
- {logErrors}
465
- </Text>
466
- <Text style={styles.dashboardGridLbl}>Errors</Text>
467
- </View>
468
- </View>
469
- </TouchableScale>)}
470
-
471
- {insightsActiveSubTab === 'analytics' && tabVisibility?.analytics && (<TouchableScale style={styles.dashboardModuleCard} onPress={() => switchActiveTab('analytics')}>
472
- <View style={styles.dashboardModuleHeader}>
473
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
474
- <AnalyticsIcon color="#EA580C" size={18}/>
475
- <Text style={styles.dashboardModuleTitle}>
476
- Analytics Events
477
- </Text>
478
- </View>
479
- <Text style={styles.dashboardModuleGoText}>View Details →</Text>
480
- </View>
481
- <View style={styles.dashboardModuleGrid}>
482
- <View style={styles.dashboardGridItem}>
483
- <Text style={styles.dashboardGridVal}>{analyticsTotal}</Text>
484
- <Text style={styles.dashboardGridLbl}>Total Events</Text>
485
- </View>
486
- <View style={styles.dashboardGridItem}>
487
- <Text style={[styles.dashboardGridVal, { color: '#EA580C' }]}>
488
- {uniqueEvents}
489
- </Text>
490
- <Text style={styles.dashboardGridLbl}>Unique Names</Text>
491
- </View>
492
- <View style={styles.dashboardGridItem}>
493
- <Text style={styles.dashboardGridVal}>{screenViews}</Text>
494
- <Text style={styles.dashboardGridLbl}>Screen Views</Text>
495
- </View>
496
- <View style={styles.dashboardGridItem}>
497
- <Text style={styles.dashboardGridVal}>
498
- {analyticsTotal > 0
499
- ? Math.round(analyticsTotal / Math.max(1, logs.length / 5))
500
- : 0}
501
- </Text>
502
- <Text style={styles.dashboardGridLbl}>Events Ratio</Text>
503
- </View>
504
- </View>
505
- </TouchableScale>)}
506
-
507
- {insightsActiveSubTab === 'webview' && tabVisibility?.webview && (<TouchableScale style={styles.dashboardModuleCard} onPress={() => switchActiveTab('webview')}>
508
- <View style={styles.dashboardModuleHeader}>
509
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
510
- <GlobeIcon color="#2563EB" size={18}/>
511
- <Text style={styles.dashboardModuleTitle}>
512
- WebView Captures
513
- </Text>
514
- </View>
515
- <Text style={styles.dashboardModuleGoText}>View Details →</Text>
516
- </View>
517
- <View style={styles.dashboardModuleGrid}>
518
- <View style={styles.dashboardGridItem}>
519
- <Text style={styles.dashboardGridVal}>{webviewTotal}</Text>
520
- <Text style={styles.dashboardGridLbl}>History Size</Text>
521
- </View>
522
- <View style={styles.dashboardGridItem}>
523
- <Text style={[styles.dashboardGridVal, { color: '#16A34A' }]}>
524
- Active
525
- </Text>
526
- <Text style={styles.dashboardGridLbl}>Status</Text>
527
- </View>
528
- <View style={styles.dashboardGridItem}>
529
- <Text numberOfLines={1} style={styles.dashboardGridVal}>
530
- {webviewTotal > 0
531
- ? `${webViewNavHistory[0]?.title?.substring(0, 10) ?? ''}...`
532
- : '—'}
533
- </Text>
534
- <Text style={styles.dashboardGridLbl}>Last URL</Text>
535
- </View>
536
- </View>
537
- </TouchableScale>)}
538
-
539
- {insightsActiveSubTab === 'redux' && tabVisibility?.redux && (<TouchableScale style={styles.dashboardModuleCard} onPress={() => switchActiveTab('redux')}>
540
- <View style={styles.dashboardModuleHeader}>
541
- <View style={{ flexDirection: 'row', alignItems: 'center', gap: 8 }}>
542
- <TerminalIcon color={AppColors.purple} size={18}/>
543
- <Text style={styles.dashboardModuleTitle}>
544
- Redux Store State
545
- </Text>
546
- </View>
547
- <Text style={styles.dashboardModuleGoText}>View Details →</Text>
548
- </View>
549
- {reduxState ? (<View style={{ paddingHorizontal: 12, paddingBottom: 12, gap: 6 }}>
550
- <View style={{
551
- flexDirection: 'row',
552
- justifyContent: 'space-between',
553
- marginBottom: 4,
554
- }}>
555
- <Text style={{
556
- fontFamily: AppFonts.interBold,
557
- fontSize: 10,
558
- color: AppColors.grayTextWeak,
559
- letterSpacing: 0.5,
560
- }}>
561
- REDUCER NAME
562
- </Text>
563
- <Text style={{
564
- fontFamily: AppFonts.interBold,
565
- fontSize: 10,
566
- color: AppColors.grayTextWeak,
567
- letterSpacing: 0.5,
568
- }}>
569
- SIZE / FIELDS
570
- </Text>
571
- </View>
572
- {Object.keys(reduxState).map(key => {
573
- const val = reduxState[key];
574
- const fieldsCount = typeof val === 'object' && val !== null
575
- ? Object.keys(val).length
576
- : 0;
577
- const sizeStr = getSize(val);
578
- return (<View key={key} style={{
579
- flexDirection: 'row',
580
- justifyContent: 'space-between',
581
- alignItems: 'center',
582
- paddingVertical: 2,
583
- }}>
584
- <Text style={{
585
- fontFamily: AppFonts.interMedium,
586
- fontSize: 12,
587
- color: AppColors.grayTextStrong,
588
- }}>
589
- {key}
590
- </Text>
591
- <Text style={{
592
- fontFamily: AppFonts.interRegular,
593
- fontSize: 11,
594
- color: AppColors.grayTextWeak,
595
- }}>
596
- {sizeStr} ({fieldsCount} fields)
597
- </Text>
598
- </View>);
599
- })}
600
- </View>) : (<View style={{ padding: 12, alignItems: 'center' }}>
601
- <Text style={{
602
- fontFamily: AppFonts.interRegular,
603
- fontSize: 12,
604
- color: AppColors.grayTextWeak,
605
- }}>
606
- No connected Redux store.
607
- </Text>
608
- </View>)}
609
- </TouchableScale>)}
610
- </>);
611
- })()}
612
- </View>);
613
- };
614
- export default InsightsDashboard;
@@ -1,3 +0,0 @@
1
- import React from 'react';
2
- declare const WebViewTab: () => React.JSX.Element;
3
- export default WebViewTab;