@buoy-gg/network 7.0.41 → 7.0.43

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 (272) hide show
  1. package/README.md +11 -85
  2. package/lib/commonjs/index.js +1 -332
  3. package/lib/commonjs/index.web.js +1 -420
  4. package/lib/commonjs/network/components/DataViewer.web.js +1 -879
  5. package/lib/commonjs/network/components/NetworkCopyScreen.web.js +1 -48
  6. package/lib/commonjs/network/components/NetworkCopySettingsView.js +27 -755
  7. package/lib/commonjs/network/components/NetworkCopySettingsView.web.js +14 -1242
  8. package/lib/commonjs/network/components/NetworkDetailScreen.web.js +1 -101
  9. package/lib/commonjs/network/components/NetworkDetailStepper.js +1 -108
  10. package/lib/commonjs/network/components/NetworkDetailStepper.web.js +1 -298
  11. package/lib/commonjs/network/components/NetworkEventDetailView.js +15 -1130
  12. package/lib/commonjs/network/components/NetworkEventDetailView.web.js +15 -1484
  13. package/lib/commonjs/network/components/NetworkEventItemCompact.js +2 -401
  14. package/lib/commonjs/network/components/NetworkEventItemCompact.web.js +2 -820
  15. package/lib/commonjs/network/components/NetworkFilterScreen.web.js +1 -55
  16. package/lib/commonjs/network/components/NetworkFilterViewV3.js +1 -442
  17. package/lib/commonjs/network/components/NetworkFilterViewV3.web.js +1 -1310
  18. package/lib/commonjs/network/components/NetworkHeaderLive.js +1 -375
  19. package/lib/commonjs/network/components/NetworkHeaderLive.web.js +1 -623
  20. package/lib/commonjs/network/components/NetworkHeaderMenu.js +1 -190
  21. package/lib/commonjs/network/components/NetworkListScreen.js +1 -403
  22. package/lib/commonjs/network/components/NetworkListScreen.web.js +1 -624
  23. package/lib/commonjs/network/components/NetworkModal.js +1 -786
  24. package/lib/commonjs/network/components/NetworkNumberPrompt.js +1 -178
  25. package/lib/commonjs/network/components/NetworkNumberPrompt.web.js +1 -232
  26. package/lib/commonjs/network/components/NetworkOverrideEditor.js +1 -814
  27. package/lib/commonjs/network/components/NetworkOverrideEditor.web.js +1 -942
  28. package/lib/commonjs/network/components/NetworkOverrideHeaderButton.js +1 -107
  29. package/lib/commonjs/network/components/NetworkOverrideHeaderButton.web.js +1 -133
  30. package/lib/commonjs/network/components/NetworkOverridesButton.js +1 -90
  31. package/lib/commonjs/network/components/NetworkOverridesButton.web.js +1 -143
  32. package/lib/commonjs/network/components/NetworkOverridesScreen.js +1 -543
  33. package/lib/commonjs/network/components/NetworkOverridesScreen.web.js +1 -830
  34. package/lib/commonjs/network/components/NetworkSavedScreen.js +1 -226
  35. package/lib/commonjs/network/components/NetworkSavedScreen.web.js +1 -463
  36. package/lib/commonjs/network/components/NetworkUpgradeBanner.js +1 -76
  37. package/lib/commonjs/network/components/response-editor/Explorer.js +1 -973
  38. package/lib/commonjs/network/components/response-editor/Explorer.web.js +1 -1136
  39. package/lib/commonjs/network/components/response-editor/deleteNestedDataByPath.js +1 -56
  40. package/lib/commonjs/network/components/response-editor/editorContext.js +1 -33
  41. package/lib/commonjs/network/components/response-editor/updateNestedDataByPath.js +1 -61
  42. package/lib/commonjs/network/conditions/NetworkConditionsControl.js +1 -235
  43. package/lib/commonjs/network/conditions/NetworkConditionsControl.test.js +1 -136
  44. package/lib/commonjs/network/conditions/NetworkConditionsIcon.js +1 -33
  45. package/lib/commonjs/network/conditions/NetworkFloatingTool.js +1 -310
  46. package/lib/commonjs/network/conditions/NetworkFloatingTool.test.js +1 -219
  47. package/lib/commonjs/network/conditions/store.js +1 -75
  48. package/lib/commonjs/network/conditions/wait.js +1 -43
  49. package/lib/commonjs/network/conditions/xhr.js +1 -135
  50. package/lib/commonjs/network/hooks/useLiveNetworkEvent.js +1 -62
  51. package/lib/commonjs/network/hooks/useNetworkBadgeCounts.js +1 -83
  52. package/lib/commonjs/network/hooks/useNetworkEventList.js +1 -108
  53. package/lib/commonjs/network/hooks/useNetworkEvents.js +1 -318
  54. package/lib/commonjs/network/hooks/useNetworkHasMatches.js +1 -56
  55. package/lib/commonjs/network/hooks/useNetworkSaved.js +1 -38
  56. package/lib/commonjs/network/hooks/useNetworkSelection.js +1 -53
  57. package/lib/commonjs/network/hooks/useOverrideRules.js +1 -36
  58. package/lib/commonjs/network/hooks/useTickEveryMinute.js +1 -21
  59. package/lib/commonjs/network/overrides/applyToFetch.js +1 -80
  60. package/lib/commonjs/network/overrides/applyToXhr.js +2 -510
  61. package/lib/commonjs/network/overrides/engine.js +1 -93
  62. package/lib/commonjs/network/overrides/matchRule.js +1 -87
  63. package/lib/commonjs/network/overrides/overriddenRows.js +1 -37
  64. package/lib/commonjs/network/overrides/overrideRulesStore.js +1 -550
  65. package/lib/commonjs/network/overrides/presets.js +1 -70
  66. package/lib/commonjs/network/overrides/resolveOverride.js +1 -158
  67. package/lib/commonjs/network/overrides/types.js +1 -90
  68. package/lib/commonjs/network/sync/networkBodyResolver.js +1 -39
  69. package/lib/commonjs/network/sync/networkSyncAdapter.js +1 -882
  70. package/lib/commonjs/network/sync/overrideHonesty.release.test.js +1 -36
  71. package/lib/commonjs/network/types/index.js +1 -5
  72. package/lib/commonjs/network/utils/extractOperationName.js +1 -80
  73. package/lib/commonjs/network/utils/filterNetworkEvents.js +1 -96
  74. package/lib/commonjs/network/utils/formatGraphQLVariables.js +1 -219
  75. package/lib/commonjs/network/utils/formatting.js +1 -30
  76. package/lib/commonjs/network/utils/generateCurl.js +2 -71
  77. package/lib/commonjs/network/utils/generateNetworkCopyText.js +37 -166
  78. package/lib/commonjs/network/utils/httpCompletion.js +1 -37
  79. package/lib/commonjs/network/utils/networkEventStore.js +1 -411
  80. package/lib/commonjs/network/utils/networkListener.js +4 -1352
  81. package/lib/commonjs/network/utils/networkSavedStore.js +3 -577
  82. package/lib/commonjs/network/utils/networkSelectionStore.js +1 -193
  83. package/lib/commonjs/network/utils/realNow.js +1 -0
  84. package/lib/commonjs/network/utils/requestId.js +1 -16
  85. package/lib/commonjs/network/utils/resolveRequestUrl.js +1 -15
  86. package/lib/commonjs/network/utils/selectSavedEvents.js +1 -39
  87. package/lib/commonjs/network/utils/startNetworkCapture.js +1 -24
  88. package/lib/commonjs/network/utils/withPinnedFirst.js +1 -32
  89. package/lib/commonjs/preset.js +1 -93
  90. package/lib/module/index.js +1 -104
  91. package/lib/module/index.web.js +1 -82
  92. package/lib/module/network/components/DataViewer.web.js +1 -875
  93. package/lib/module/network/components/NetworkCopyScreen.web.js +1 -44
  94. package/lib/module/network/components/NetworkCopySettingsView.js +27 -750
  95. package/lib/module/network/components/NetworkCopySettingsView.web.js +14 -1237
  96. package/lib/module/network/components/NetworkDetailScreen.web.js +1 -97
  97. package/lib/module/network/components/NetworkDetailStepper.js +1 -104
  98. package/lib/module/network/components/NetworkDetailStepper.web.js +1 -296
  99. package/lib/module/network/components/NetworkEventDetailView.js +15 -1129
  100. package/lib/module/network/components/NetworkEventDetailView.web.js +15 -1482
  101. package/lib/module/network/components/NetworkEventItemCompact.js +2 -398
  102. package/lib/module/network/components/NetworkEventItemCompact.web.js +2 -818
  103. package/lib/module/network/components/NetworkFilterScreen.web.js +1 -51
  104. package/lib/module/network/components/NetworkFilterViewV3.js +1 -438
  105. package/lib/module/network/components/NetworkFilterViewV3.web.js +1 -1306
  106. package/lib/module/network/components/NetworkHeaderLive.js +1 -366
  107. package/lib/module/network/components/NetworkHeaderLive.web.js +1 -617
  108. package/lib/module/network/components/NetworkHeaderMenu.js +1 -184
  109. package/lib/module/network/components/NetworkListScreen.js +1 -399
  110. package/lib/module/network/components/NetworkListScreen.web.js +1 -622
  111. package/lib/module/network/components/NetworkModal.js +1 -781
  112. package/lib/module/network/components/NetworkNumberPrompt.js +1 -174
  113. package/lib/module/network/components/NetworkNumberPrompt.web.js +1 -230
  114. package/lib/module/network/components/NetworkOverrideEditor.js +1 -811
  115. package/lib/module/network/components/NetworkOverrideEditor.web.js +1 -939
  116. package/lib/module/network/components/NetworkOverrideHeaderButton.js +1 -104
  117. package/lib/module/network/components/NetworkOverrideHeaderButton.web.js +1 -131
  118. package/lib/module/network/components/NetworkOverridesButton.js +1 -87
  119. package/lib/module/network/components/NetworkOverridesButton.web.js +1 -141
  120. package/lib/module/network/components/NetworkOverridesScreen.js +1 -539
  121. package/lib/module/network/components/NetworkOverridesScreen.web.js +1 -826
  122. package/lib/module/network/components/NetworkSavedScreen.js +1 -222
  123. package/lib/module/network/components/NetworkSavedScreen.web.js +1 -461
  124. package/lib/module/network/components/NetworkUpgradeBanner.js +1 -72
  125. package/lib/module/network/components/response-editor/Explorer.js +1 -972
  126. package/lib/module/network/components/response-editor/Explorer.web.js +1 -1133
  127. package/lib/module/network/components/response-editor/deleteNestedDataByPath.js +1 -51
  128. package/lib/module/network/components/response-editor/editorContext.js +1 -29
  129. package/lib/module/network/components/response-editor/updateNestedDataByPath.js +1 -56
  130. package/lib/module/network/conditions/NetworkConditionsControl.js +1 -231
  131. package/lib/module/network/conditions/NetworkConditionsControl.test.js +1 -135
  132. package/lib/module/network/conditions/NetworkConditionsIcon.js +1 -29
  133. package/lib/module/network/conditions/NetworkFloatingTool.js +1 -304
  134. package/lib/module/network/conditions/NetworkFloatingTool.test.js +1 -218
  135. package/lib/module/network/conditions/store.js +1 -65
  136. package/lib/module/network/conditions/wait.js +1 -38
  137. package/lib/module/network/conditions/xhr.js +1 -131
  138. package/lib/module/network/hooks/useLiveNetworkEvent.js +1 -58
  139. package/lib/module/network/hooks/useNetworkBadgeCounts.js +1 -79
  140. package/lib/module/network/hooks/useNetworkEventList.js +1 -104
  141. package/lib/module/network/hooks/useNetworkEvents.js +1 -314
  142. package/lib/module/network/hooks/useNetworkHasMatches.js +1 -52
  143. package/lib/module/network/hooks/useNetworkSaved.js +1 -34
  144. package/lib/module/network/hooks/useNetworkSelection.js +1 -46
  145. package/lib/module/network/hooks/useOverrideRules.js +1 -32
  146. package/lib/module/network/hooks/useTickEveryMinute.js +1 -11
  147. package/lib/module/network/overrides/applyToFetch.js +1 -72
  148. package/lib/module/network/overrides/applyToXhr.js +2 -502
  149. package/lib/module/network/overrides/engine.js +1 -85
  150. package/lib/module/network/overrides/matchRule.js +1 -81
  151. package/lib/module/network/overrides/overriddenRows.js +1 -33
  152. package/lib/module/network/overrides/overrideRulesStore.js +1 -547
  153. package/lib/module/network/overrides/presets.js +1 -65
  154. package/lib/module/network/overrides/resolveOverride.js +1 -152
  155. package/lib/module/network/overrides/types.js +1 -86
  156. package/lib/module/network/sync/networkBodyResolver.js +1 -34
  157. package/lib/module/network/sync/networkSyncAdapter.js +1 -880
  158. package/lib/module/network/sync/overrideHonesty.release.test.js +1 -35
  159. package/lib/module/network/types/index.js +1 -3
  160. package/lib/module/network/utils/extractOperationName.js +1 -76
  161. package/lib/module/network/utils/filterNetworkEvents.js +1 -92
  162. package/lib/module/network/utils/formatGraphQLVariables.js +1 -213
  163. package/lib/module/network/utils/formatting.js +1 -9
  164. package/lib/module/network/utils/generateCurl.js +2 -67
  165. package/lib/module/network/utils/generateNetworkCopyText.js +37 -162
  166. package/lib/module/network/utils/httpCompletion.js +1 -32
  167. package/lib/module/network/utils/networkEventStore.js +1 -409
  168. package/lib/module/network/utils/networkListener.js +4 -1341
  169. package/lib/module/network/utils/networkSavedStore.js +3 -572
  170. package/lib/module/network/utils/networkSelectionStore.js +1 -188
  171. package/lib/module/network/utils/realNow.js +1 -0
  172. package/lib/module/network/utils/requestId.js +1 -12
  173. package/lib/module/network/utils/resolveRequestUrl.js +1 -11
  174. package/lib/module/network/utils/selectSavedEvents.js +1 -35
  175. package/lib/module/network/utils/startNetworkCapture.js +1 -21
  176. package/lib/module/network/utils/withPinnedFirst.js +1 -28
  177. package/lib/module/preset.js +1 -91
  178. package/lib/typescript/network/overrides/engine.d.ts +1 -1
  179. package/lib/typescript/network/overrides/matchRule.d.ts +1 -1
  180. package/lib/typescript/network/overrides/resolveOverride.d.ts +2 -2
  181. package/lib/typescript/network/overrides/types.d.ts +9 -0
  182. package/lib/typescript/network/utils/networkListener.d.ts +11 -0
  183. package/lib/typescript/network/utils/realNow.d.ts +18 -0
  184. package/lib/web/index.mjs +73 -74
  185. package/package.json +3 -6
  186. package/lib/typescript/index.d.ts.map +0 -1
  187. package/lib/typescript/index.web.d.ts.map +0 -1
  188. package/lib/typescript/network/components/DataViewer.web.d.ts.map +0 -1
  189. package/lib/typescript/network/components/NetworkCopyScreen.web.d.ts.map +0 -1
  190. package/lib/typescript/network/components/NetworkCopySettingsView.d.ts.map +0 -1
  191. package/lib/typescript/network/components/NetworkCopySettingsView.web.d.ts.map +0 -1
  192. package/lib/typescript/network/components/NetworkDetailScreen.web.d.ts.map +0 -1
  193. package/lib/typescript/network/components/NetworkDetailStepper.d.ts.map +0 -1
  194. package/lib/typescript/network/components/NetworkDetailStepper.web.d.ts.map +0 -1
  195. package/lib/typescript/network/components/NetworkEventDetailView.d.ts.map +0 -1
  196. package/lib/typescript/network/components/NetworkEventDetailView.web.d.ts.map +0 -1
  197. package/lib/typescript/network/components/NetworkEventItemCompact.d.ts.map +0 -1
  198. package/lib/typescript/network/components/NetworkEventItemCompact.web.d.ts.map +0 -1
  199. package/lib/typescript/network/components/NetworkFilterScreen.web.d.ts.map +0 -1
  200. package/lib/typescript/network/components/NetworkFilterViewV3.d.ts.map +0 -1
  201. package/lib/typescript/network/components/NetworkFilterViewV3.web.d.ts.map +0 -1
  202. package/lib/typescript/network/components/NetworkHeaderLive.d.ts.map +0 -1
  203. package/lib/typescript/network/components/NetworkHeaderLive.web.d.ts.map +0 -1
  204. package/lib/typescript/network/components/NetworkHeaderMenu.d.ts.map +0 -1
  205. package/lib/typescript/network/components/NetworkListScreen.d.ts.map +0 -1
  206. package/lib/typescript/network/components/NetworkListScreen.web.d.ts.map +0 -1
  207. package/lib/typescript/network/components/NetworkModal.d.ts.map +0 -1
  208. package/lib/typescript/network/components/NetworkNumberPrompt.d.ts.map +0 -1
  209. package/lib/typescript/network/components/NetworkNumberPrompt.web.d.ts.map +0 -1
  210. package/lib/typescript/network/components/NetworkOverrideEditor.d.ts.map +0 -1
  211. package/lib/typescript/network/components/NetworkOverrideEditor.web.d.ts.map +0 -1
  212. package/lib/typescript/network/components/NetworkOverrideHeaderButton.d.ts.map +0 -1
  213. package/lib/typescript/network/components/NetworkOverrideHeaderButton.web.d.ts.map +0 -1
  214. package/lib/typescript/network/components/NetworkOverridesButton.d.ts.map +0 -1
  215. package/lib/typescript/network/components/NetworkOverridesButton.web.d.ts.map +0 -1
  216. package/lib/typescript/network/components/NetworkOverridesScreen.d.ts.map +0 -1
  217. package/lib/typescript/network/components/NetworkOverridesScreen.web.d.ts.map +0 -1
  218. package/lib/typescript/network/components/NetworkSavedScreen.d.ts.map +0 -1
  219. package/lib/typescript/network/components/NetworkSavedScreen.web.d.ts.map +0 -1
  220. package/lib/typescript/network/components/NetworkUpgradeBanner.d.ts.map +0 -1
  221. package/lib/typescript/network/components/response-editor/Explorer.d.ts.map +0 -1
  222. package/lib/typescript/network/components/response-editor/Explorer.web.d.ts.map +0 -1
  223. package/lib/typescript/network/components/response-editor/deleteNestedDataByPath.d.ts.map +0 -1
  224. package/lib/typescript/network/components/response-editor/editorContext.d.ts.map +0 -1
  225. package/lib/typescript/network/components/response-editor/updateNestedDataByPath.d.ts.map +0 -1
  226. package/lib/typescript/network/conditions/NetworkConditionsControl.d.ts.map +0 -1
  227. package/lib/typescript/network/conditions/NetworkConditionsControl.test.d.ts.map +0 -1
  228. package/lib/typescript/network/conditions/NetworkConditionsIcon.d.ts.map +0 -1
  229. package/lib/typescript/network/conditions/NetworkFloatingTool.d.ts.map +0 -1
  230. package/lib/typescript/network/conditions/NetworkFloatingTool.test.d.ts.map +0 -1
  231. package/lib/typescript/network/conditions/store.d.ts.map +0 -1
  232. package/lib/typescript/network/conditions/wait.d.ts.map +0 -1
  233. package/lib/typescript/network/conditions/xhr.d.ts.map +0 -1
  234. package/lib/typescript/network/hooks/useLiveNetworkEvent.d.ts.map +0 -1
  235. package/lib/typescript/network/hooks/useNetworkBadgeCounts.d.ts.map +0 -1
  236. package/lib/typescript/network/hooks/useNetworkEventList.d.ts.map +0 -1
  237. package/lib/typescript/network/hooks/useNetworkEvents.d.ts.map +0 -1
  238. package/lib/typescript/network/hooks/useNetworkHasMatches.d.ts.map +0 -1
  239. package/lib/typescript/network/hooks/useNetworkSaved.d.ts.map +0 -1
  240. package/lib/typescript/network/hooks/useNetworkSelection.d.ts.map +0 -1
  241. package/lib/typescript/network/hooks/useOverrideRules.d.ts.map +0 -1
  242. package/lib/typescript/network/hooks/useTickEveryMinute.d.ts.map +0 -1
  243. package/lib/typescript/network/overrides/applyToFetch.d.ts.map +0 -1
  244. package/lib/typescript/network/overrides/applyToXhr.d.ts.map +0 -1
  245. package/lib/typescript/network/overrides/engine.d.ts.map +0 -1
  246. package/lib/typescript/network/overrides/matchRule.d.ts.map +0 -1
  247. package/lib/typescript/network/overrides/overriddenRows.d.ts.map +0 -1
  248. package/lib/typescript/network/overrides/overrideRulesStore.d.ts.map +0 -1
  249. package/lib/typescript/network/overrides/presets.d.ts.map +0 -1
  250. package/lib/typescript/network/overrides/resolveOverride.d.ts.map +0 -1
  251. package/lib/typescript/network/overrides/types.d.ts.map +0 -1
  252. package/lib/typescript/network/sync/networkBodyResolver.d.ts.map +0 -1
  253. package/lib/typescript/network/sync/networkSyncAdapter.d.ts.map +0 -1
  254. package/lib/typescript/network/sync/overrideHonesty.release.test.d.ts.map +0 -1
  255. package/lib/typescript/network/types/index.d.ts.map +0 -1
  256. package/lib/typescript/network/utils/extractOperationName.d.ts.map +0 -1
  257. package/lib/typescript/network/utils/filterNetworkEvents.d.ts.map +0 -1
  258. package/lib/typescript/network/utils/formatGraphQLVariables.d.ts.map +0 -1
  259. package/lib/typescript/network/utils/formatting.d.ts.map +0 -1
  260. package/lib/typescript/network/utils/generateCurl.d.ts.map +0 -1
  261. package/lib/typescript/network/utils/generateNetworkCopyText.d.ts.map +0 -1
  262. package/lib/typescript/network/utils/httpCompletion.d.ts.map +0 -1
  263. package/lib/typescript/network/utils/networkEventStore.d.ts.map +0 -1
  264. package/lib/typescript/network/utils/networkListener.d.ts.map +0 -1
  265. package/lib/typescript/network/utils/networkSavedStore.d.ts.map +0 -1
  266. package/lib/typescript/network/utils/networkSelectionStore.d.ts.map +0 -1
  267. package/lib/typescript/network/utils/requestId.d.ts.map +0 -1
  268. package/lib/typescript/network/utils/resolveRequestUrl.d.ts.map +0 -1
  269. package/lib/typescript/network/utils/selectSavedEvents.d.ts.map +0 -1
  270. package/lib/typescript/network/utils/startNetworkCapture.d.ts.map +0 -1
  271. package/lib/typescript/network/utils/withPinnedFirst.d.ts.map +0 -1
  272. package/lib/typescript/preset.d.ts.map +0 -1
@@ -1,1150 +1,35 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.NetworkEventDetailView = void 0;
7
- var _react = require("react");
8
- var _reactNative = require("react-native");
9
- var _sharedUi = require("@buoy-gg/shared-ui");
10
- var _formatting = require("../utils/formatting");
11
- var _dataViewer = require("@buoy-gg/shared-ui/dataViewer");
12
- var _formatGraphQLVariables = require("../utils/formatGraphQLVariables");
13
- var _networkBodyResolver = require("../sync/networkBodyResolver");
14
- var _jsxRuntime = require("react/jsx-runtime");
15
- /**
16
- * Colour for the icons that merely LABEL a section (Sent/Received, the JSON
17
- * body glyphs). The Lock/Unlock pair keeps its colour because
18
- * secure-vs-insecure is a genuine signal, as does the status pill.
19
- */const NEUTRAL_ICON = _sharedUi.night.color.accent;
20
-
21
- /** Hoisted so the defaults don't mint a new Set/function per render. */
22
- const EMPTY_PATTERNS = new Set();
23
- const noop = () => {};
24
- /**
25
- * The measurable slice of a request's lifetime, as proportional bars.
26
- *
27
- * Renders NOTHING when the interceptor couldn't measure it — an older device
28
- * talking to a newer dashboard, or a request that died before headers. A phase
29
- * row reading `0ms` would claim we measured zero, which is a different and
30
- * false statement from "we didn't measure this".
31
- *
32
- * Only two phases, on purpose. Queueing / DNS / TLS / request-send all happen
33
- * below the JS layer with nothing to read them from — see NetworkTimings. The
34
- * design this came from shows five, but derives the other three by multiplying
35
- * the total by fixed fractions, i.e. they are invented. Two real ones are worth
36
- * more than five where three are decoration.
37
- */
38
- const TimingPhases = ({
39
- timings,
40
- total
41
- }) => {
42
- // Guard the divisor: a sub-millisecond request would otherwise divide by 0.
43
- const span = Math.max(1, total);
44
- const phases = [{
45
- // Deliberately NOT called "server time". Measured from JS, this includes
46
- // queueing, DNS, TLS and sending the request — everything before the
47
- // headers land. The subtitle says so rather than implying Chrome-grade
48
- // precision we don't have.
49
- label: "Waiting (TTFB)",
50
- hint: "incl. queue, DNS, TLS",
51
- value: timings.ttfb,
52
- color: _sharedUi.macOSColors.semantic.warning
53
- }, {
54
- label: "Content download",
55
- hint: undefined,
56
- value: timings.download,
57
- color: _sharedUi.macOSColors.semantic.success
58
- }];
59
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
60
- style: styles.phaseList,
61
- children: phases.map(phase => /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
62
- style: styles.phaseRow,
63
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
64
- style: styles.phaseLabelGroup,
65
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
66
- style: styles.phaseLabel,
67
- children: phase.label
68
- }), phase.hint ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
69
- style: styles.phaseHint,
70
- children: phase.hint
71
- }) : null]
72
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
73
- style: styles.phaseTrack,
74
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
75
- style: [styles.phaseBar, {
76
- backgroundColor: phase.color,
77
- // A floor so a 1ms phase is still a visible tick, and a
78
- // ceiling because `total` and the phases are measured at
79
- // different points — ttfb can exceed event.duration, which
80
- // would push the bar past its track and over the label.
81
- width: `${Math.min(100, Math.max(1, phase.value / span * 100))}%`
82
- }]
83
- })
84
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
85
- style: styles.phaseValue,
86
- children: (0, _formatting.formatDuration)(phase.value)
87
- })]
88
- }, phase.label))
89
- });
90
- };
91
-
92
- /**
93
- * Stand-in for a body tree while the prev/next cursor is still moving.
94
- *
95
- * Deliberately a fixed-height nothing: it must cost ~0 to render (that is the
96
- * entire point) and it must not resize the scroll view as the real tree swaps
97
- * in, or fast stepping would make the page jump under the reader.
98
- */
99
- const BodyDeferred = () => /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
100
- style: styles.bodyDeferred
101
- });
102
-
103
- // Component for collapsible sections matching Sentry style
104
- const CollapsibleSection = ({
105
- title,
106
- icon,
107
- children,
108
- defaultOpen = false,
109
- count
110
- }) => {
111
- const [isOpen, setIsOpen] = (0, _react.useState)(defaultOpen);
112
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
113
- style: styles.collapsibleSection,
114
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
115
- style: styles.collapsibleHeader,
116
- onPress: () => setIsOpen(!isOpen),
117
- testID: `buoy-network-section-${title.toLowerCase().replace(/\s+/g, "-")}`,
118
- accessibilityRole: "button",
119
- accessibilityLabel: title,
120
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
121
- style: styles.collapsibleTitle,
122
- children: [icon, /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
123
- style: styles.collapsibleTitleText,
124
- children: title
125
- }), count !== undefined ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
126
- style: styles.collapsibleCount,
127
- children: count
128
- }) : null]
129
- }), isOpen ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronUp, {
130
- size: 16,
131
- color: _sharedUi.night.color.textSecondary
132
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronDown, {
133
- size: 16,
134
- color: _sharedUi.night.color.textSecondary
135
- })]
136
- }), isOpen ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
137
- style: styles.collapsibleContent,
138
- children: children
139
- }) : null]
140
- });
141
- };
142
-
143
- // URL breakdown component matching Sentry style
144
- const UrlBreakdown = ({
145
- url,
146
- requestData,
147
- operationName,
148
- graphqlVariables,
149
- requestClient,
150
- isPro = false,
151
- onUpgradePress
152
- }) => {
153
- const parseUrl = urlString => {
154
- try {
155
- const urlObj = new URL(urlString);
156
- const protocol = String(urlObj.protocol || "");
157
- const host = String(urlObj.host || "");
158
- const isSecure = protocol === "https:";
159
- let pathname = String(urlObj.pathname || "");
160
-
161
- // If this is a GraphQL request with operation name, format with arrow notation
162
- // Matches React Query pattern: "GetPokemon › Sandshrew"
163
- if (requestClient === "graphql" && operationName) {
164
- const graphqlDisplay = (0, _formatGraphQLVariables.formatGraphQLDisplay)(operationName, graphqlVariables);
165
- pathname = `${pathname} (${graphqlDisplay})`;
166
- } else if (operationName) {
167
- // For non-GraphQL requests with operation names (e.g., gRPC)
168
- pathname = `${pathname} (${operationName})`;
169
- }
170
-
171
- // Parse query parameters
172
- const params = {};
173
- const searchParams = urlObj.searchParams;
174
- if (searchParams && typeof searchParams.forEach === "function") {
175
- searchParams.forEach((value, key) => {
176
- params[key] = value;
177
- });
178
- }
179
- return {
180
- protocol: protocol.replace(":", ""),
181
- host,
182
- pathname,
183
- params: Object.keys(params).length > 0 ? params : null,
184
- isSecure
185
- };
186
- } catch {
187
- return {
188
- protocol: "",
189
- host: url,
190
- pathname: "",
191
- params: null,
192
- isSecure: false
193
- };
194
- }
195
- };
196
-
197
- /**
198
- * MUST be memoized. `parseUrl` builds a fresh `params` object every call, and
199
- * that object is handed to `DataViewer` as its `data` prop — whose flattening
200
- * effect keys on `data` by IDENTITY. Computed inline, every render of this
201
- * component produced a new object, so the effect re-fired and re-entered
202
- * "Processing data…" forever. The detail view re-renders constantly on the
203
- * dashboard (it tracks the live event as the device pushes snapshots ~4×/sec),
204
- * so this pinned the query-parameter viewer in a permanent processing loop.
205
- *
206
- * `url` is a string, so this is stable by value.
207
- */
208
- const urlParts = (0, _react.useMemo)(() => parseUrl(url),
209
- // parseUrl closes over the graphql/operation props, which are what change
210
- // the derived pathname.
211
- // eslint-disable-next-line react-hooks/exhaustive-deps
212
- [url, requestClient, operationName, graphqlVariables]);
213
- const [showParams, setShowParams] = (0, _react.useState)(false);
214
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
215
- style: styles.urlBreakdown,
216
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
217
- style: styles.urlRow,
218
- children: [urlParts.isSecure ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Lock, {
219
- size: 12,
220
- color: _sharedUi.macOSColors.semantic.success
221
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Unlock, {
222
- size: 12,
223
- color: _sharedUi.macOSColors.semantic.warning
224
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
225
- style: styles.urlDomain,
226
- children: urlParts.host
227
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
228
- style: styles.urlProtocol,
229
- children: ["(", urlParts.protocol.toUpperCase(), ")"]
230
- }), isPro ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.InlineCopyButton, {
231
- value: url,
232
- buttonStyle: styles.copyButton
233
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
234
- style: styles.copyButton,
235
- onPress: onUpgradePress,
236
- activeOpacity: 0.7,
237
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Copy, {
238
- size: 14,
239
- color: _sharedUi.night.color.textSecondary
240
- })
241
- })]
242
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
243
- style: styles.urlPathRow,
244
- children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
245
- style: styles.urlPath,
246
- numberOfLines: 2,
247
- children: [urlParts.pathname, urlParts.params ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
248
- style: styles.urlQueryString,
249
- children: ["?", new URLSearchParams(urlParts.params).toString()]
250
- }) : null]
251
- })
252
- }), urlParts.params ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
253
- style: styles.queryParamsCollapsible,
254
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
255
- style: styles.queryParamsToggle,
256
- onPress: () => setShowParams(!showParams),
257
- activeOpacity: 0.7,
258
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
259
- style: styles.queryParamsToggleText,
260
- children: "Query Parameters"
261
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
262
- style: styles.collapsibleCount,
263
- children: Object.keys(urlParts.params).length
264
- }), showParams ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronUp, {
265
- size: 14,
266
- color: _sharedUi.night.color.textSecondary
267
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.ChevronDown, {
268
- size: 14,
269
- color: _sharedUi.night.color.textSecondary
270
- })]
271
- }), showParams ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.DataViewer, {
272
- title: "",
273
- data: urlParts.params,
274
- showTypeFilter: true,
275
- rawMode: true,
276
- initialExpanded: true
277
- }) : null]
278
- }) : null]
279
- });
280
- };
281
-
282
- /**
283
- * Detailed inspector rendering request/response metadata for a single network event. Designed to
284
- * mimic Sentry’s layout with collapsible sections, diff views, and quick copy affordances.
285
- *
286
- * MEMOIZED with profiling evidence, not by reflex. Two render paths hit this
287
- * subtree with unchanged props:
288
- *
289
- * 1. `useLiveNetworkEvent` re-subscribes when the selected ID changes, and
290
- * `subscribeToEvents` replays immediately — so every step through the
291
- * prev/next footer committed the SAME event object twice, rendering this
292
- * whole tree (expanded DataViewer included) a second time for nothing.
293
- * 2. Any modal-root state change (header search, mode toggle) re-renders the
294
- * shell, and the detail body has nothing to do with it.
295
- *
296
- * Both props besides `event` are stable by construction — `values` is memoized
297
- * in `useIgnoredPatterns` and `toggle` is module-scope there — so the bail-out
298
- * actually fires.
299
- *
300
- * Measured baseline (js-top, example-dev-build, 5 steps over 109–324KB
301
- * pokeapi responses): 307ms of React work across 5 steps ≈ 61ms of JS per
302
- * step. Case 1 alone is half of that, since it re-ran the whole body render.
303
- */
304
- const NetworkEventDetailView = exports.NetworkEventDetailView = /*#__PURE__*/(0, _react.memo)(function NetworkEventDetailView({
305
- event,
306
- ignoredPatterns = EMPTY_PATTERNS,
307
- onTogglePattern = noop,
308
- showBodies = true
309
- }) {
310
- const status = event.status ? (0, _formatting.formatHttpStatus)(event.status) : null;
311
- const isPending = !event.status && !event.error;
312
-
313
- // Check Pro status for copy features
314
- const {
315
- isPro
316
- } = (0, _sharedUi.useFeatureGate)();
317
- const [showUpgradeModal, setShowUpgradeModal] = (0, _react.useState)(false);
318
-
319
- // Auto-close upgrade modal when user becomes Pro
320
- (0, _react.useEffect)(() => {
321
- if (showUpgradeModal && isPro) {
322
- setShowUpgradeModal(false);
323
- }
324
- }, [showUpgradeModal, isPro]);
325
-
326
- // Large bodies are omitted from synced snapshots (see networkSyncAdapter) and
327
- // fetched on demand through the resolver. On the device there is no resolver
328
- // and bodies are always inline, so this is a no-op there.
329
- const resolveBody = (0, _networkBodyResolver.useNetworkBodyResolver)();
330
- // The explicit flag is authoritative (adapter v5+). The size>0 fallback keeps
331
- // detail-on-demand working against a device on an older adapter, which marked
332
- // a withheld body only by leaving `data` undefined with a non-zero size.
333
- const requestBodyOmitted = event.requestData === undefined && (event.requestBodyOmitted === true || (event.requestSize ?? 0) > 0);
334
- const responseBodyOmitted = event.responseData === undefined && (event.responseBodyOmitted === true || (event.responseSize ?? 0) > 0);
335
- const headersOmitted = event.headersOmitted === true;
336
- const [resolvedBody, setResolvedBody] = (0, _react.useState)(null);
337
- const [isLoadingBody, setIsLoadingBody] = (0, _react.useState)(false);
338
- (0, _react.useEffect)(() => {
339
- setResolvedBody(null);
340
- if (!resolveBody || !requestBodyOmitted && !responseBodyOmitted && !headersOmitted) {
341
- setIsLoadingBody(false);
342
- return;
343
- }
344
- let cancelled = false;
345
- setIsLoadingBody(true);
346
- resolveBody(event.id).then(body => {
347
- if (!cancelled) setResolvedBody(body);
348
- }).catch(() => {}).finally(() => {
349
- if (!cancelled) setIsLoadingBody(false);
350
- });
351
- return () => {
352
- cancelled = true;
353
- };
354
- }, [event.id, resolveBody, requestBodyOmitted, responseBodyOmitted, headersOmitted]);
355
-
356
- // Effective bodies: inline data when present, otherwise the lazily resolved
357
- // body. `null`/`undefined` both collapse to undefined ("no body").
358
- const requestData = event.requestData ?? resolvedBody?.requestData ?? undefined;
359
- const responseData = event.responseData ?? resolvedBody?.responseData ?? undefined;
360
- const requestHeaders = (headersOmitted ? resolvedBody?.requestHeaders : undefined) ?? event.requestHeaders;
361
- const responseHeaders = (headersOmitted ? resolvedBody?.responseHeaders : undefined) ?? event.responseHeaders;
362
-
363
- // Generate full request details for copying
364
- const getFullRequestDetails = () => {
365
- const requestDetails = {
366
- method: event.method,
367
- url: event.url,
368
- status: event.status,
369
- statusText: event.statusText,
370
- timestamp: new Date(event.timestamp).toISOString(),
371
- duration: event.duration ? `${event.duration}ms` : "N/A",
372
- requestHeaders,
373
- requestData,
374
- responseHeaders,
375
- responseData,
376
- requestSize: event.requestSize ? (0, _formatting.formatBytes)(event.requestSize) : "N/A",
377
- responseSize: event.responseSize ? (0, _formatting.formatBytes)(event.responseSize) : "N/A",
378
- error: event.error,
379
- client: event.requestClient
380
- };
381
- return `# Network Request Details
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.NetworkEventDetailView=void 0;var _react=require("react");var _reactNative=require("react-native");var _sharedUi=require("@buoy-gg/shared-ui");var _formatting=require("../utils/formatting");var _dataViewer=require("@buoy-gg/shared-ui/dataViewer");var _formatGraphQLVariables=require("../utils/formatGraphQLVariables");var _networkBodyResolver=require("../sync/networkBodyResolver");var _jsxRuntime=require("react/jsx-runtime");const NEUTRAL_ICON=_sharedUi.night.color.accent;const EMPTY_PATTERNS=new Set;const noop=()=>{};const TimingPhases=({timings:i,total:e})=>{const l=Math.max(1,e);const a=[{label:"Waiting (TTFB)",hint:"incl. queue, DNS, TLS",value:i.ttfb,color:_sharedUi.macOSColors.semantic.warning},{label:"Content download",hint:void 0,value:i.download,color:_sharedUi.macOSColors.semantic.success}];return(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.phaseList,children:a.map(o=>(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.phaseRow,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.phaseLabelGroup,children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.phaseLabel,children:o.label}),o.hint?(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.phaseHint,children:o.hint}):null]}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.phaseTrack,children:(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.phaseBar,{backgroundColor:o.color,width:`${Math.min(100,Math.max(1,o.value/l*100))}%`}]})}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.phaseValue,children:(0,_formatting.formatDuration)(o.value)})]},o.label))})};const BodyDeferred=()=>(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.bodyDeferred});const CollapsibleSection=({title:i,icon:e,children:l,defaultOpen:a=false,count:o})=>{const[n,w]=(0,_react.useState)(a);return(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.collapsibleSection,children:[(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{style:styles.collapsibleHeader,onPress:()=>w(!n),testID:`buoy-network-section-${i.toLowerCase().replace(/\s+/g,"-")}`,accessibilityRole:"button",accessibilityLabel:i,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.collapsibleTitle,children:[e,(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.collapsibleTitleText,children:i}),o!==void 0?(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.collapsibleCount,children:o}):null]}),n?(0,_jsxRuntime.jsx)(_sharedUi.ChevronUp,{size:16,color:_sharedUi.night.color.textSecondary}):(0,_jsxRuntime.jsx)(_sharedUi.ChevronDown,{size:16,color:_sharedUi.night.color.textSecondary})]}),n?(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.collapsibleContent,children:l}):null]})};const UrlBreakdown=({url:i,requestData:e,operationName:l,graphqlVariables:a,requestClient:o,isPro:n=false,onUpgradePress:w})=>{const s=j=>{try{const d=new URL(j);const x=String(d.protocol||"");const y=String(d.host||"");const z=x==="https:";let u=String(d.pathname||"");if(o==="graphql"&&l){const f=(0,_formatGraphQLVariables.formatGraphQLDisplay)(l,a);u=`${u} (${f})`}else if(l){u=`${u} (${l})`}const p={};const g=d.searchParams;if(g&&typeof g.forEach==="function"){g.forEach((f,m)=>{p[m]=f})}return{protocol:x.replace(":",""),host:y,pathname:u,params:Object.keys(p).length>0?p:null,isSecure:z}}catch{return{protocol:"",host:i,pathname:"",params:null,isSecure:false}}};const r=(0,_react.useMemo)(()=>s(i),[i,o,l,a]);const[c,b]=(0,_react.useState)(false);return(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.urlBreakdown,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.urlRow,children:[r.isSecure?(0,_jsxRuntime.jsx)(_sharedUi.Lock,{size:12,color:_sharedUi.macOSColors.semantic.success}):(0,_jsxRuntime.jsx)(_sharedUi.Unlock,{size:12,color:_sharedUi.macOSColors.semantic.warning}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.urlDomain,children:r.host}),(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:styles.urlProtocol,children:["(",r.protocol.toUpperCase(),")"]}),n?(0,_jsxRuntime.jsx)(_sharedUi.InlineCopyButton,{value:i,buttonStyle:styles.copyButton}):(0,_jsxRuntime.jsx)(_reactNative.TouchableOpacity,{style:styles.copyButton,onPress:w,activeOpacity:.7,children:(0,_jsxRuntime.jsx)(_sharedUi.Copy,{size:14,color:_sharedUi.night.color.textSecondary})})]}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.urlPathRow,children:(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:styles.urlPath,numberOfLines:2,children:[r.pathname,r.params?(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:styles.urlQueryString,children:["?",new URLSearchParams(r.params).toString()]}):null]})}),r.params?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.queryParamsCollapsible,children:[(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{style:styles.queryParamsToggle,onPress:()=>b(!c),activeOpacity:.7,children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.queryParamsToggleText,children:"Query Parameters"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.collapsibleCount,children:Object.keys(r.params).length}),c?(0,_jsxRuntime.jsx)(_sharedUi.ChevronUp,{size:14,color:_sharedUi.night.color.textSecondary}):(0,_jsxRuntime.jsx)(_sharedUi.ChevronDown,{size:14,color:_sharedUi.night.color.textSecondary})]}),c?(0,_jsxRuntime.jsx)(_dataViewer.DataViewer,{title:"",data:r.params,showTypeFilter:true,rawMode:true,initialExpanded:true}):null]}):null]})};const NetworkEventDetailView=exports.NetworkEventDetailView=(0,_react.memo)(function i({event:e,ignoredPatterns:l=EMPTY_PATTERNS,onTogglePattern:a=noop,showBodies:o=true}){const n=e.status?(0,_formatting.formatHttpStatus)(e.status):null;const w=!e.status&&!e.error;const{isPro:s}=(0,_sharedUi.useFeatureGate)();const[r,c]=(0,_react.useState)(false);(0,_react.useEffect)(()=>{if(r&&s){c(false)}},[r,s]);const b=(0,_networkBodyResolver.useNetworkBodyResolver)();const j=e.requestData===void 0&&(e.requestBodyOmitted===true||(e.requestSize??0)>0);const d=e.responseData===void 0&&(e.responseBodyOmitted===true||(e.responseSize??0)>0);const x=e.headersOmitted===true;const[y,z]=(0,_react.useState)(null);const[u,p]=(0,_react.useState)(false);(0,_react.useEffect)(()=>{z(null);if(!b||!j&&!d&&!x){p(false);return}let t=false;p(true);b(e.id).then(h=>{if(!t)z(h)}).catch(()=>{}).finally(()=>{if(!t)p(false)});return()=>{t=true}},[e.id,b,j,d,x]);const g=e.requestData??y?.requestData??void 0;const f=e.responseData??y?.responseData??void 0;const m=(x?y?.requestHeaders:void 0)??e.requestHeaders;const C=(x?y?.responseHeaders:void 0)??e.responseHeaders;const D=()=>{const t={method:e.method,url:e.url,status:e.status,statusText:e.statusText,timestamp:new Date(e.timestamp).toISOString(),duration:e.duration?`${e.duration}ms`:"N/A",requestHeaders:m,requestData:g,responseHeaders:C,responseData:f,requestSize:e.requestSize?(0,_formatting.formatBytes)(e.requestSize):"N/A",responseSize:e.responseSize?(0,_formatting.formatBytes)(e.responseSize):"N/A",error:e.error,client:e.requestClient};return`# Network Request Details
382
2
 
383
3
  ## Request
384
- - **Method:** ${requestDetails.method}
385
- - **URL:** ${requestDetails.url}
386
- - **Client:** ${requestDetails.client || "N/A"}
387
- - **Timestamp:** ${requestDetails.timestamp}
4
+ - **Method:** ${t.method}
5
+ - **URL:** ${t.url}
6
+ - **Client:** ${t.client||"N/A"}
7
+ - **Timestamp:** ${t.timestamp}
388
8
 
389
9
  ## Response
390
- - **Status:** ${requestDetails.status || "Pending"}${requestDetails.statusText ? ` (${requestDetails.statusText})` : ""}
391
- - **Duration:** ${requestDetails.duration}
392
- - **Request Size:** ${requestDetails.requestSize}
393
- - **Response Size:** ${requestDetails.responseSize}
394
- ${requestDetails.error ? `- **Error:** ${requestDetails.error}` : ""}
10
+ - **Status:** ${t.status||"Pending"}${t.statusText?` (${t.statusText})`:""}
11
+ - **Duration:** ${t.duration}
12
+ - **Request Size:** ${t.requestSize}
13
+ - **Response Size:** ${t.responseSize}
14
+ ${t.error?`- **Error:** ${t.error}`:""}
395
15
 
396
16
  ## Request Headers
397
17
  \`\`\`json
398
- ${JSON.stringify(requestDetails.requestHeaders, null, 2)}
18
+ ${JSON.stringify(t.requestHeaders,null,2)}
399
19
  \`\`\`
400
20
 
401
21
  ## Request Data
402
22
  \`\`\`json
403
- ${JSON.stringify(requestDetails.requestData, null, 2)}
23
+ ${JSON.stringify(t.requestData,null,2)}
404
24
  \`\`\`
405
25
 
406
26
  ## Response Headers
407
27
  \`\`\`json
408
- ${JSON.stringify(requestDetails.responseHeaders, null, 2)}
28
+ ${JSON.stringify(t.responseHeaders,null,2)}
409
29
  \`\`\`
410
30
 
411
31
  ## Response Data
412
32
  \`\`\`json
413
- ${JSON.stringify(requestDetails.responseData, null, 2)}
33
+ ${JSON.stringify(t.responseData,null,2)}
414
34
  \`\`\`
415
- `;
416
- };
417
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
418
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.ScrollView, {
419
- testID: "buoy-network-detail-scroll",
420
- style: styles.container,
421
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
422
- style: styles.requestDetailsSection,
423
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
424
- style: styles.httpHeader,
425
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
426
- style: styles.httpMethodBadge,
427
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
428
- style: styles.httpMethod,
429
- children: event.method
430
- })
431
- }), event.status ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
432
- style: [styles.httpStatusBadge, {
433
- backgroundColor: `${status?.color}20`
434
- }],
435
- children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
436
- style: [styles.httpStatusText, {
437
- color: status?.color
438
- }],
439
- children: [status?.text, " ", status?.meaning]
440
- })
441
- }) : isPending ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
442
- style: styles.pendingBadge,
443
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Clock, {
444
- size: 10,
445
- color: _sharedUi.night.color.warning
446
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
447
- style: styles.pendingBadgeText,
448
- children: "Pending"
449
- })]
450
- }) : null, event.condition && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
451
- style: {
452
- color: "#FFCC66"
453
- },
454
- children: ["Conditions: ", event.condition.profile, " (+", event.condition.delayMs, " ms)"]
455
- }), event.duration ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
456
- style: styles.httpDuration,
457
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Clock, {
458
- size: 10,
459
- color: _sharedUi.night.color.textTertiary
460
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
461
- style: styles.httpDurationText,
462
- children: (0, _formatting.formatDuration)(event.duration)
463
- })]
464
- }) : null, event.override ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
465
- style: styles.overrideBadge,
466
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.FlaskConical, {
467
- size: 10,
468
- color: _sharedUi.night.color.warning
469
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
470
- style: styles.overrideBadgeText,
471
- children: event.override.ruleName || "Overridden"
472
- })]
473
- }) : null, isPro ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.InlineCopyButton
474
- // LAZY, not `getFullRequestDetails()`. CopyButton resolves a
475
- // function value at press time; calling it here instead
476
- // pretty-printed the headers AND both bodies on every render —
477
- // four JSON.stringify passes over the full payload just to have
478
- // a string nobody asked for yet. Same shape NetworkSavedScreen
479
- // already uses for its copy button.
480
- , {
481
- value: getFullRequestDetails,
482
- buttonStyle: styles.copyFullButton
483
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
484
- style: styles.copyFullButton,
485
- onPress: () => setShowUpgradeModal(true),
486
- activeOpacity: 0.7,
487
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Copy, {
488
- size: 14,
489
- color: _sharedUi.night.color.textSecondary
490
- })
491
- })]
492
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(UrlBreakdown, {
493
- url: event.url,
494
- requestData: requestData,
495
- operationName: event.operationName,
496
- graphqlVariables: event.graphqlVariables,
497
- requestClient: event.requestClient,
498
- isPro: isPro,
499
- onUpgradePress: () => setShowUpgradeModal(true)
500
- }), event.error ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
501
- style: styles.errorBox,
502
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.AlertCircle, {
503
- size: 12,
504
- color: _sharedUi.night.color.danger
505
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
506
- style: styles.errorText,
507
- children: event.error
508
- })]
509
- }) : null]
510
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
511
- style: styles.timingSection,
512
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
513
- style: styles.timingRow,
514
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Clock, {
515
- size: 12,
516
- color: _sharedUi.night.color.textSecondary
517
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
518
- style: styles.timingLabel,
519
- children: "Started:"
520
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
521
- style: styles.timingValue,
522
- children: (0, _sharedUi.formatRelativeTime)(event.timestamp)
523
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
524
- style: styles.timingExact,
525
- children: ["(", new Date(event.timestamp).toLocaleTimeString(), ")"]
526
- }), event.requestSize || event.responseSize ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
527
- style: styles.sizeRow,
528
- children: [event.requestSize !== undefined ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
529
- style: styles.sizeItem,
530
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Upload, {
531
- size: 10,
532
- color: _sharedUi.night.color.info
533
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
534
- style: styles.sizeLabel,
535
- children: "Sent:"
536
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
537
- style: styles.sizeValue,
538
- children: (0, _formatting.formatBytes)(event.requestSize)
539
- })]
540
- }) : null, event.responseSize !== undefined ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
541
- style: styles.sizeItem,
542
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Download, {
543
- size: 10,
544
- color: NEUTRAL_ICON
545
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
546
- style: styles.sizeLabel,
547
- children: "Received:"
548
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
549
- style: styles.sizeValue,
550
- children: (0, _formatting.formatBytes)(event.responseSize)
551
- })]
552
- }) : null]
553
- }) : null]
554
- }), event.timings ? /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
555
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
556
- style: styles.phaseDivider
557
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(TimingPhases, {
558
- timings: event.timings,
559
- total: event.duration ?? event.timings.ttfb + event.timings.download
560
- })]
561
- }) : null]
562
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
563
- title: "Request Headers",
564
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Upload, {
565
- size: 14,
566
- color: _sharedUi.night.color.info
567
- }),
568
- defaultOpen: false,
569
- count: Object.keys(requestHeaders).length,
570
- children: Object.keys(requestHeaders).length > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
571
- style: styles.dataViewerContainer,
572
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.DataViewer, {
573
- title: "",
574
- data: requestHeaders,
575
- showTypeFilter: true,
576
- rawMode: true,
577
- initialExpanded: true,
578
- disableCopy: !isPro
579
- })
580
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
581
- style: styles.emptyText,
582
- children: "No request headers"
583
- })
584
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
585
- title: "Response Headers",
586
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Download, {
587
- size: 14,
588
- color: NEUTRAL_ICON
589
- }),
590
- defaultOpen: false,
591
- count: Object.keys(responseHeaders).length,
592
- children: Object.keys(responseHeaders).length > 0 ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
593
- style: styles.dataViewerContainer,
594
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.DataViewer, {
595
- title: "",
596
- data: responseHeaders,
597
- showTypeFilter: true,
598
- rawMode: true,
599
- initialExpanded: true,
600
- disableCopy: !isPro
601
- })
602
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
603
- style: styles.emptyText,
604
- children: "No response headers yet"
605
- })
606
- }), requestData !== undefined ? /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
607
- title: "Request Body",
608
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.FileJson, {
609
- size: 14,
610
- color: _sharedUi.night.color.accent
611
- }),
612
- defaultOpen: false,
613
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
614
- style: styles.dataViewerContainer,
615
- children: showBodies ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.DataViewer, {
616
- title: "",
617
- data: requestData,
618
- showTypeFilter: true,
619
- rawMode: true,
620
- initialExpanded: true,
621
- disableCopy: !isPro
622
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(BodyDeferred, {})
623
- })
624
- }) : requestBodyOmitted ? /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
625
- title: "Request Body",
626
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.FileJson, {
627
- size: 14,
628
- color: _sharedUi.night.color.accent
629
- }),
630
- defaultOpen: true,
631
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
632
- style: styles.emptyText,
633
- children: isLoadingBody ? `Loading request body (${(0, _formatting.formatBytes)(event.requestSize ?? 0)})…` : "Request body unavailable"
634
- })
635
- }) : null, responseData !== undefined ? /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
636
- title: "Response Body",
637
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.FileJson, {
638
- size: 14,
639
- color: NEUTRAL_ICON
640
- })
641
- // The body is what you opened the row FOR — the design has it
642
- // expanded on arrival, everything else closed.
643
- ,
644
- defaultOpen: true,
645
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
646
- style: styles.dataViewerContainer,
647
- children: showBodies ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_dataViewer.DataViewer, {
648
- title: "",
649
- data: responseData,
650
- showTypeFilter: true,
651
- rawMode: true,
652
- initialExpanded: true,
653
- disableCopy: !isPro
654
- }) : /*#__PURE__*/(0, _jsxRuntime.jsx)(BodyDeferred, {})
655
- })
656
- }) : responseBodyOmitted ? /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
657
- title: "Response Body",
658
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.FileJson, {
659
- size: 14,
660
- color: NEUTRAL_ICON
661
- }),
662
- defaultOpen: true,
663
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
664
- style: styles.emptyText,
665
- children: isLoadingBody ? `Loading response body (${(0, _formatting.formatBytes)(event.responseSize ?? 0)})…` : "Response body unavailable"
666
- })
667
- }) : null, /*#__PURE__*/(0, _jsxRuntime.jsx)(CollapsibleSection, {
668
- title: "Filter Options",
669
- icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Filter, {
670
- size: 14,
671
- color: _sharedUi.night.color.warning
672
- }),
673
- defaultOpen: false,
674
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
675
- style: styles.filterOptionsContainer,
676
- children: (() => {
677
- let domain = "";
678
- let urlPath = "";
679
- try {
680
- const url = new URL(event.url);
681
- domain = url.hostname;
682
- urlPath = url.pathname;
683
- } catch {
684
- urlPath = event.url;
685
- }
686
- const isDomainIgnored = ignoredPatterns.has(domain);
687
- const isUrlIgnored = ignoredPatterns.has(urlPath);
688
- return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
689
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
690
- style: [styles.filterOption, isDomainIgnored && styles.filterOptionActive],
691
- onPress: () => domain && onTogglePattern(domain),
692
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
693
- style: styles.filterOptionLeft,
694
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Globe, {
695
- size: 16,
696
- color: isDomainIgnored ? _sharedUi.night.color.warning : _sharedUi.night.color.textTertiary
697
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
698
- style: styles.filterOptionContent,
699
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
700
- style: styles.filterOptionLabel,
701
- children: "Ignore Domain"
702
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
703
- style: styles.filterOptionValue,
704
- children: domain || "N/A"
705
- })]
706
- })]
707
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
708
- style: [styles.filterToggle, isDomainIgnored && styles.filterToggleActive],
709
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
710
- style: [styles.filterToggleText, isDomainIgnored && styles.filterToggleTextActive],
711
- children: isDomainIgnored ? "IGNORED" : "IGNORE"
712
- })
713
- })]
714
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
715
- style: [styles.filterOption, isUrlIgnored && styles.filterOptionActive],
716
- onPress: () => urlPath && onTogglePattern(urlPath),
717
- children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
718
- style: styles.filterOptionLeft,
719
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.Link, {
720
- size: 16,
721
- color: isUrlIgnored ? _sharedUi.night.color.warning : _sharedUi.night.color.textTertiary
722
- }), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
723
- style: styles.filterOptionContent,
724
- children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
725
- style: styles.filterOptionLabel,
726
- children: "Ignore URL Pattern"
727
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
728
- style: styles.filterOptionValue,
729
- numberOfLines: 1,
730
- children: urlPath || "N/A"
731
- })]
732
- })]
733
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
734
- style: [styles.filterToggle, isUrlIgnored && styles.filterToggleActive],
735
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
736
- style: [styles.filterToggleText, isUrlIgnored && styles.filterToggleTextActive],
737
- children: isUrlIgnored ? "IGNORED" : "IGNORE"
738
- })
739
- })]
740
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
741
- style: styles.filterInfoBox,
742
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
743
- style: styles.filterInfoText,
744
- children: "Ignored requests will be hidden from the network list. You can manage filters in the Filters tab."
745
- })
746
- })]
747
- });
748
- })()
749
- })
750
- })]
751
- }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_sharedUi.UpgradeModal, {
752
- visible: showUpgradeModal,
753
- onClose: () => setShowUpgradeModal(false),
754
- featureName: "Copy Request Details",
755
- description: "Copy network request details to share or debug issues.",
756
- benefits: ["Copy full request details including headers and body", "Export to JSON, Markdown, or plain text", "Share request data with teammates", "Feed data to AI assistants for debugging"]
757
- })]
758
- });
759
- });
760
- const styles = _reactNative.StyleSheet.create({
761
- container: {
762
- flex: 1,
763
- // Transparent so the night sheet's star field shows through.
764
- backgroundColor: "transparent"
765
- },
766
- // Request details section - always visible
767
- requestDetailsSection: {
768
- marginHorizontal: 12,
769
- marginTop: 12,
770
- backgroundColor: _sharedUi.night.color.surface,
771
- borderRadius: 8,
772
- borderWidth: 1,
773
- borderColor: _sharedUi.night.color.border,
774
- padding: 12
775
- },
776
- httpHeader: {
777
- flexDirection: "row",
778
- alignItems: "center",
779
- gap: 8,
780
- marginBottom: 12,
781
- flexWrap: "nowrap"
782
- },
783
- httpMethodBadge: {
784
- backgroundColor: _sharedUi.night.color.infoSoft,
785
- paddingHorizontal: 8,
786
- paddingVertical: 4,
787
- borderRadius: 4
788
- },
789
- httpMethod: {
790
- color: _sharedUi.night.color.info,
791
- fontSize: 11,
792
- fontWeight: "700",
793
- letterSpacing: 0.5
794
- },
795
- httpStatusBadge: {
796
- paddingHorizontal: 8,
797
- paddingVertical: 4,
798
- borderRadius: 4
799
- },
800
- httpStatusText: {
801
- fontSize: 11,
802
- fontWeight: "600"
803
- },
804
- pendingBadge: {
805
- flexDirection: "row",
806
- alignItems: "center",
807
- gap: 4,
808
- backgroundColor: _sharedUi.night.color.warningSoft,
809
- paddingHorizontal: 8,
810
- paddingVertical: 4,
811
- borderRadius: 4
812
- },
813
- pendingBadgeText: {
814
- color: _sharedUi.night.color.warning,
815
- fontSize: 11,
816
- fontWeight: "600"
817
- },
818
- httpDuration: {
819
- flexDirection: "row",
820
- alignItems: "center",
821
- gap: 4
822
- },
823
- httpDurationText: {
824
- color: _sharedUi.night.color.textSecondary,
825
- fontSize: 11
826
- },
827
- overrideBadge: {
828
- flexDirection: "row",
829
- alignItems: "center",
830
- gap: 4,
831
- paddingHorizontal: 6,
832
- paddingVertical: 3,
833
- borderRadius: 4,
834
- backgroundColor: _sharedUi.night.color.warningSoft
835
- },
836
- overrideBadgeText: {
837
- color: _sharedUi.night.color.warning,
838
- fontSize: 10,
839
- fontWeight: "700"
840
- },
841
- copyFullButton: {
842
- marginLeft: "auto",
843
- flexShrink: 0,
844
- padding: 4
845
- },
846
- // URL breakdown styles
847
- urlBreakdown: {
848
- // Inset code box — darker than the card, the night track color.
849
- backgroundColor: _sharedUi.night.color.bg,
850
- borderRadius: 4,
851
- padding: 8
852
- },
853
- urlRow: {
854
- flexDirection: "row",
855
- alignItems: "center",
856
- gap: 6,
857
- marginBottom: 4
858
- },
859
- urlDomain: {
860
- color: _sharedUi.night.color.text,
861
- fontSize: 12,
862
- fontWeight: "600",
863
- flex: 1
864
- },
865
- urlProtocol: {
866
- color: _sharedUi.night.color.textTertiary,
867
- fontSize: 10
868
- },
869
- copyButton: {
870
- padding: 4
871
- },
872
- urlPathRow: {
873
- paddingLeft: 18
874
- },
875
- urlPath: {
876
- color: _sharedUi.night.color.textSecondary,
877
- fontSize: 11,
878
- fontFamily: _sharedUi.monoFont
879
- },
880
- urlQueryString: {
881
- color: _sharedUi.night.color.info,
882
- fontSize: 11,
883
- fontFamily: _sharedUi.monoFont
884
- },
885
- // Query Parameters - Collapsible section
886
- queryParamsCollapsible: {
887
- marginTop: 8
888
- },
889
- queryParamsToggle: {
890
- flexDirection: "row",
891
- alignItems: "center",
892
- justifyContent: "space-between",
893
- paddingHorizontal: 12,
894
- paddingVertical: 10,
895
- backgroundColor: _sharedUi.night.color.surfaceElevated,
896
- borderRadius: 8,
897
- borderWidth: 1,
898
- borderColor: _sharedUi.night.color.border,
899
- marginBottom: 8
900
- },
901
- queryParamsToggleText: {
902
- flexGrow: 0,
903
- color: _sharedUi.night.color.text,
904
- fontSize: 12,
905
- fontWeight: "600",
906
- letterSpacing: 0.3
907
- },
908
- // Timing section - always visible
909
- timingSection: {
910
- marginHorizontal: 12,
911
- marginTop: 8,
912
- backgroundColor: _sharedUi.night.color.surface,
913
- borderRadius: 8,
914
- borderWidth: 1,
915
- borderColor: _sharedUi.night.color.border,
916
- padding: 12
917
- },
918
- timingRow: {
919
- flexDirection: "row",
920
- alignItems: "center",
921
- gap: 6,
922
- // Wraps rather than squashing when the card is narrow (a phone, or a
923
- // half-width panel) — the sizes drop to their own line there.
924
- flexWrap: "wrap"
925
- },
926
- timingLabel: {
927
- color: _sharedUi.night.color.textSecondary,
928
- fontSize: 11
929
- },
930
- timingValue: {
931
- color: _sharedUi.night.color.text,
932
- fontSize: 11,
933
- fontWeight: "600"
934
- },
935
- timingExact: {
936
- color: _sharedUi.night.color.textTertiary,
937
- fontSize: 10,
938
- marginLeft: 4
939
- },
940
- sizeRow: {
941
- flexDirection: "row",
942
- alignItems: "center",
943
- gap: 16,
944
- // Pushed to the far end of the Started row. No top border/padding — it is
945
- // no longer a separate strip.
946
- marginLeft: "auto"
947
- },
948
- sizeItem: {
949
- flexDirection: "row",
950
- alignItems: "center",
951
- gap: 4
952
- },
953
- sizeLabel: {
954
- color: _sharedUi.night.color.textTertiary,
955
- fontSize: 10
956
- },
957
- sizeValue: {
958
- color: _sharedUi.night.color.info,
959
- fontSize: 10,
960
- fontFamily: _sharedUi.monoFont,
961
- fontWeight: "600"
962
- },
963
- /* ---- Timing phases ---- */
964
- phaseDivider: {
965
- height: 1,
966
- backgroundColor: _sharedUi.night.color.border,
967
- marginTop: 12,
968
- marginBottom: 12
969
- },
970
- phaseList: {
971
- gap: 8
972
- },
973
- phaseRow: {
974
- flexDirection: "row",
975
- alignItems: "center",
976
- gap: 14
977
- },
978
- phaseLabelGroup: {
979
- width: 150
980
- },
981
- phaseLabel: {
982
- fontSize: 12,
983
- color: _sharedUi.night.color.textSecondary
984
- },
985
- phaseHint: {
986
- fontSize: 10,
987
- color: _sharedUi.night.color.textTertiary
988
- },
989
- phaseTrack: {
990
- flex: 1,
991
- height: 7,
992
- borderRadius: 4,
993
- backgroundColor: _sharedUi.night.color.surfaceElevated,
994
- justifyContent: "center",
995
- overflow: "hidden"
996
- },
997
- phaseBar: {
998
- height: 7,
999
- borderRadius: 4
1000
- },
1001
- phaseValue: {
1002
- width: 72,
1003
- textAlign: "right",
1004
- fontSize: 12,
1005
- fontFamily: _sharedUi.monoFont,
1006
- color: _sharedUi.night.color.text
1007
- },
1008
- // Collapsible section styles
1009
- collapsibleSection: {
1010
- marginHorizontal: 12,
1011
- marginTop: 8,
1012
- backgroundColor: _sharedUi.night.color.surface,
1013
- borderRadius: 8,
1014
- borderWidth: 1,
1015
- borderColor: _sharedUi.night.color.border,
1016
- overflow: "hidden"
1017
- },
1018
- collapsibleHeader: {
1019
- flexDirection: "row",
1020
- alignItems: "center",
1021
- justifyContent: "space-between",
1022
- padding: 12,
1023
- // `background.hover` is the SELECTION grey — heavy enough here that every
1024
- // section header read as a toolbar. The design uses a near-white strip.
1025
- backgroundColor: _sharedUi.night.color.surfaceElevated
1026
- },
1027
- collapsibleTitle: {
1028
- flexDirection: "row",
1029
- alignItems: "center",
1030
- gap: 8
1031
- },
1032
- collapsibleTitleText: {
1033
- color: _sharedUi.night.color.text,
1034
- fontSize: 13,
1035
- fontWeight: "600"
1036
- },
1037
- /** The "how much is in here" number beside a section title. */
1038
- collapsibleCount: {
1039
- color: _sharedUi.night.color.textTertiary,
1040
- fontSize: 11.5,
1041
- fontFamily: _sharedUi.monoFont
1042
- },
1043
- collapsibleContent: {
1044
- padding: 12
1045
- },
1046
- // Data viewer container
1047
- dataViewerContainer: {
1048
- marginTop: -12,
1049
- marginHorizontal: -12,
1050
- marginBottom: -12
1051
- },
1052
- /** Placeholder for a not-yet-mounted body tree. See BodyDeferred. */
1053
- bodyDeferred: {
1054
- height: 120
1055
- },
1056
- // Error box
1057
- errorBox: {
1058
- flexDirection: "row",
1059
- alignItems: "center",
1060
- gap: 6,
1061
- backgroundColor: _sharedUi.night.color.dangerSoft,
1062
- padding: 8,
1063
- borderRadius: 4,
1064
- marginTop: 8
1065
- },
1066
- errorText: {
1067
- color: _sharedUi.night.color.danger,
1068
- fontSize: 11,
1069
- flex: 1
1070
- },
1071
- // Empty state
1072
- emptyText: {
1073
- color: _sharedUi.night.color.textTertiary,
1074
- fontSize: 12,
1075
- fontStyle: "italic",
1076
- textAlign: "center"
1077
- },
1078
- // Filter options styles
1079
- filterOptionsContainer: {
1080
- gap: 12
1081
- },
1082
- filterOption: {
1083
- flexDirection: "row",
1084
- alignItems: "center",
1085
- justifyContent: "space-between",
1086
- backgroundColor: _sharedUi.night.color.surfaceElevated,
1087
- borderRadius: 8,
1088
- padding: 12,
1089
- borderWidth: 1,
1090
- borderColor: _sharedUi.night.color.border
1091
- },
1092
- filterOptionActive: {
1093
- backgroundColor: _sharedUi.night.color.warningSoft,
1094
- borderColor: _sharedUi.night.color.warning + "33"
1095
- },
1096
- filterOptionLeft: {
1097
- flexDirection: "row",
1098
- alignItems: "center",
1099
- gap: 12,
1100
- flex: 1
1101
- },
1102
- filterOptionContent: {
1103
- flex: 1
1104
- },
1105
- filterOptionLabel: {
1106
- color: _sharedUi.night.color.textSecondary,
1107
- fontSize: 11,
1108
- marginBottom: 2,
1109
- textTransform: "uppercase",
1110
- letterSpacing: 0.5
1111
- },
1112
- filterOptionValue: {
1113
- color: _sharedUi.night.color.text,
1114
- fontSize: 13,
1115
- fontFamily: _sharedUi.monoFont
1116
- },
1117
- filterToggle: {
1118
- paddingHorizontal: 10,
1119
- paddingVertical: 6,
1120
- borderRadius: 4,
1121
- backgroundColor: _sharedUi.night.color.bg,
1122
- borderWidth: 1,
1123
- borderColor: _sharedUi.night.color.border
1124
- },
1125
- filterToggleActive: {
1126
- backgroundColor: _sharedUi.night.color.warningSoft,
1127
- borderColor: _sharedUi.night.color.warning + "4D"
1128
- },
1129
- filterToggleText: {
1130
- fontSize: 10,
1131
- fontWeight: "600",
1132
- color: _sharedUi.night.color.textTertiary,
1133
- letterSpacing: 0.5
1134
- },
1135
- filterToggleTextActive: {
1136
- color: _sharedUi.night.color.warning
1137
- },
1138
- filterInfoBox: {
1139
- backgroundColor: _sharedUi.night.color.infoSoft,
1140
- borderRadius: 6,
1141
- padding: 10,
1142
- borderWidth: 1,
1143
- borderColor: _sharedUi.night.color.info + "33"
1144
- },
1145
- filterInfoText: {
1146
- color: _sharedUi.night.color.textSecondary,
1147
- fontSize: 11,
1148
- lineHeight: 16
1149
- }
1150
- });
35
+ `};return(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsxs)(_reactNative.ScrollView,{testID:"buoy-network-detail-scroll",style:styles.container,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.requestDetailsSection,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.httpHeader,children:[(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.httpMethodBadge,children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.httpMethod,children:e.method})}),e.status?(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.httpStatusBadge,{backgroundColor:`${n?.color}20`}],children:(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:[styles.httpStatusText,{color:n?.color}],children:[n?.text," ",n?.meaning]})}):w?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.pendingBadge,children:[(0,_jsxRuntime.jsx)(_sharedUi.Clock,{size:10,color:_sharedUi.night.color.warning}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.pendingBadgeText,children:"Pending"})]}):null,e.condition&&(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:{color:"#FFCC66"},children:["Conditions: ",e.condition.profile," (+",e.condition.delayMs," ms)"]}),e.duration?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.httpDuration,children:[(0,_jsxRuntime.jsx)(_sharedUi.Clock,{size:10,color:_sharedUi.night.color.textTertiary}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.httpDurationText,children:(0,_formatting.formatDuration)(e.duration)})]}):null,e.override?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.overrideBadge,children:[(0,_jsxRuntime.jsx)(_sharedUi.FlaskConical,{size:10,color:_sharedUi.night.color.warning}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.overrideBadgeText,children:e.override.ruleName||"Overridden"})]}):null,s?(0,_jsxRuntime.jsx)(_sharedUi.InlineCopyButton,{value:D,buttonStyle:styles.copyFullButton}):(0,_jsxRuntime.jsx)(_reactNative.TouchableOpacity,{style:styles.copyFullButton,onPress:()=>c(true),activeOpacity:.7,children:(0,_jsxRuntime.jsx)(_sharedUi.Copy,{size:14,color:_sharedUi.night.color.textSecondary})})]}),(0,_jsxRuntime.jsx)(UrlBreakdown,{url:e.url,requestData:g,operationName:e.operationName,graphqlVariables:e.graphqlVariables,requestClient:e.requestClient,isPro:s,onUpgradePress:()=>c(true)}),e.error?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.errorBox,children:[(0,_jsxRuntime.jsx)(_sharedUi.AlertCircle,{size:12,color:_sharedUi.night.color.danger}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.errorText,children:e.error})]}):null]}),(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.timingSection,children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.timingRow,children:[(0,_jsxRuntime.jsx)(_sharedUi.Clock,{size:12,color:_sharedUi.night.color.textSecondary}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.timingLabel,children:"Started:"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.timingValue,children:(0,_sharedUi.formatRelativeTime)(e.timestamp)}),(0,_jsxRuntime.jsxs)(_reactNative.Text,{style:styles.timingExact,children:["(",new Date(e.timestamp).toLocaleTimeString(),")"]}),e.requestSize||e.responseSize?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.sizeRow,children:[e.requestSize!==void 0?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.sizeItem,children:[(0,_jsxRuntime.jsx)(_sharedUi.Upload,{size:10,color:_sharedUi.night.color.info}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.sizeLabel,children:"Sent:"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.sizeValue,children:(0,_formatting.formatBytes)(e.requestSize)})]}):null,e.responseSize!==void 0?(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.sizeItem,children:[(0,_jsxRuntime.jsx)(_sharedUi.Download,{size:10,color:NEUTRAL_ICON}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.sizeLabel,children:"Received:"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.sizeValue,children:(0,_formatting.formatBytes)(e.responseSize)})]}):null]}):null]}),e.timings?(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.phaseDivider}),(0,_jsxRuntime.jsx)(TimingPhases,{timings:e.timings,total:e.duration??e.timings.ttfb+e.timings.download})]}):null]}),(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Request Headers",icon:(0,_jsxRuntime.jsx)(_sharedUi.Upload,{size:14,color:_sharedUi.night.color.info}),defaultOpen:false,count:Object.keys(m).length,children:Object.keys(m).length>0?(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.dataViewerContainer,children:(0,_jsxRuntime.jsx)(_dataViewer.DataViewer,{title:"",data:m,showTypeFilter:true,rawMode:true,initialExpanded:true,disableCopy:!s})}):(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptyText,children:"No request headers"})}),(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Response Headers",icon:(0,_jsxRuntime.jsx)(_sharedUi.Download,{size:14,color:NEUTRAL_ICON}),defaultOpen:false,count:Object.keys(C).length,children:Object.keys(C).length>0?(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.dataViewerContainer,children:(0,_jsxRuntime.jsx)(_dataViewer.DataViewer,{title:"",data:C,showTypeFilter:true,rawMode:true,initialExpanded:true,disableCopy:!s})}):(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptyText,children:"No response headers yet"})}),g!==void 0?(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Request Body",icon:(0,_jsxRuntime.jsx)(_sharedUi.FileJson,{size:14,color:_sharedUi.night.color.accent}),defaultOpen:false,children:(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.dataViewerContainer,children:o?(0,_jsxRuntime.jsx)(_dataViewer.DataViewer,{title:"",data:g,showTypeFilter:true,rawMode:true,initialExpanded:true,disableCopy:!s}):(0,_jsxRuntime.jsx)(BodyDeferred,{})})}):j?(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Request Body",icon:(0,_jsxRuntime.jsx)(_sharedUi.FileJson,{size:14,color:_sharedUi.night.color.accent}),defaultOpen:true,children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptyText,children:u?`Loading request body (${(0,_formatting.formatBytes)(e.requestSize??0)})\u2026`:"Request body unavailable"})}):null,f!==void 0?(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Response Body",icon:(0,_jsxRuntime.jsx)(_sharedUi.FileJson,{size:14,color:NEUTRAL_ICON}),defaultOpen:true,children:(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.dataViewerContainer,children:o?(0,_jsxRuntime.jsx)(_dataViewer.DataViewer,{title:"",data:f,showTypeFilter:true,rawMode:true,initialExpanded:true,disableCopy:!s}):(0,_jsxRuntime.jsx)(BodyDeferred,{})})}):d?(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Response Body",icon:(0,_jsxRuntime.jsx)(_sharedUi.FileJson,{size:14,color:NEUTRAL_ICON}),defaultOpen:true,children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.emptyText,children:u?`Loading response body (${(0,_formatting.formatBytes)(e.responseSize??0)})\u2026`:"Response body unavailable"})}):null,(0,_jsxRuntime.jsx)(CollapsibleSection,{title:"Filter Options",icon:(0,_jsxRuntime.jsx)(_sharedUi.Filter,{size:14,color:_sharedUi.night.color.warning}),defaultOpen:false,children:(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.filterOptionsContainer,children:(()=>{let t="";let h="";try{const V=new URL(e.url);t=V.hostname;h=V.pathname}catch{h=e.url}const T=l.has(t);const S=l.has(h);return(0,_jsxRuntime.jsxs)(_jsxRuntime.Fragment,{children:[(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{style:[styles.filterOption,T&&styles.filterOptionActive],onPress:()=>t&&a(t),children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.filterOptionLeft,children:[(0,_jsxRuntime.jsx)(_sharedUi.Globe,{size:16,color:T?_sharedUi.night.color.warning:_sharedUi.night.color.textTertiary}),(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.filterOptionContent,children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.filterOptionLabel,children:"Ignore Domain"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.filterOptionValue,children:t||"N/A"})]})]}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.filterToggle,T&&styles.filterToggleActive],children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[styles.filterToggleText,T&&styles.filterToggleTextActive],children:T?"IGNORED":"IGNORE"})})]}),(0,_jsxRuntime.jsxs)(_reactNative.TouchableOpacity,{style:[styles.filterOption,S&&styles.filterOptionActive],onPress:()=>h&&a(h),children:[(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.filterOptionLeft,children:[(0,_jsxRuntime.jsx)(_sharedUi.Link,{size:16,color:S?_sharedUi.night.color.warning:_sharedUi.night.color.textTertiary}),(0,_jsxRuntime.jsxs)(_reactNative.View,{style:styles.filterOptionContent,children:[(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.filterOptionLabel,children:"Ignore URL Pattern"}),(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.filterOptionValue,numberOfLines:1,children:h||"N/A"})]})]}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:[styles.filterToggle,S&&styles.filterToggleActive],children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:[styles.filterToggleText,S&&styles.filterToggleTextActive],children:S?"IGNORED":"IGNORE"})})]}),(0,_jsxRuntime.jsx)(_reactNative.View,{style:styles.filterInfoBox,children:(0,_jsxRuntime.jsx)(_reactNative.Text,{style:styles.filterInfoText,children:"Ignored requests will be hidden from the network list. You can manage filters in the Filters tab."})})]})})()})})]}),(0,_jsxRuntime.jsx)(_sharedUi.UpgradeModal,{visible:r,onClose:()=>c(false),featureName:"Copy Request Details",description:"Copy network request details to share or debug issues.",benefits:["Copy full request details including headers and body","Export to JSON, Markdown, or plain text","Share request data with teammates","Feed data to AI assistants for debugging"]})]})});const styles=_reactNative.StyleSheet.create({container:{flex:1,backgroundColor:"transparent"},requestDetailsSection:{marginHorizontal:12,marginTop:12,backgroundColor:_sharedUi.night.color.surface,borderRadius:8,borderWidth:1,borderColor:_sharedUi.night.color.border,padding:12},httpHeader:{flexDirection:"row",alignItems:"center",gap:8,marginBottom:12,flexWrap:"nowrap"},httpMethodBadge:{backgroundColor:_sharedUi.night.color.infoSoft,paddingHorizontal:8,paddingVertical:4,borderRadius:4},httpMethod:{color:_sharedUi.night.color.info,fontSize:11,fontWeight:"700",letterSpacing:.5},httpStatusBadge:{paddingHorizontal:8,paddingVertical:4,borderRadius:4},httpStatusText:{fontSize:11,fontWeight:"600"},pendingBadge:{flexDirection:"row",alignItems:"center",gap:4,backgroundColor:_sharedUi.night.color.warningSoft,paddingHorizontal:8,paddingVertical:4,borderRadius:4},pendingBadgeText:{color:_sharedUi.night.color.warning,fontSize:11,fontWeight:"600"},httpDuration:{flexDirection:"row",alignItems:"center",gap:4},httpDurationText:{color:_sharedUi.night.color.textSecondary,fontSize:11},overrideBadge:{flexDirection:"row",alignItems:"center",gap:4,paddingHorizontal:6,paddingVertical:3,borderRadius:4,backgroundColor:_sharedUi.night.color.warningSoft},overrideBadgeText:{color:_sharedUi.night.color.warning,fontSize:10,fontWeight:"700"},copyFullButton:{marginLeft:"auto",flexShrink:0,padding:4},urlBreakdown:{backgroundColor:_sharedUi.night.color.bg,borderRadius:4,padding:8},urlRow:{flexDirection:"row",alignItems:"center",gap:6,marginBottom:4},urlDomain:{color:_sharedUi.night.color.text,fontSize:12,fontWeight:"600",flex:1},urlProtocol:{color:_sharedUi.night.color.textTertiary,fontSize:10},copyButton:{padding:4},urlPathRow:{paddingLeft:18},urlPath:{color:_sharedUi.night.color.textSecondary,fontSize:11,fontFamily:_sharedUi.monoFont},urlQueryString:{color:_sharedUi.night.color.info,fontSize:11,fontFamily:_sharedUi.monoFont},queryParamsCollapsible:{marginTop:8},queryParamsToggle:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",paddingHorizontal:12,paddingVertical:10,backgroundColor:_sharedUi.night.color.surfaceElevated,borderRadius:8,borderWidth:1,borderColor:_sharedUi.night.color.border,marginBottom:8},queryParamsToggleText:{flexGrow:0,color:_sharedUi.night.color.text,fontSize:12,fontWeight:"600",letterSpacing:.3},timingSection:{marginHorizontal:12,marginTop:8,backgroundColor:_sharedUi.night.color.surface,borderRadius:8,borderWidth:1,borderColor:_sharedUi.night.color.border,padding:12},timingRow:{flexDirection:"row",alignItems:"center",gap:6,flexWrap:"wrap"},timingLabel:{color:_sharedUi.night.color.textSecondary,fontSize:11},timingValue:{color:_sharedUi.night.color.text,fontSize:11,fontWeight:"600"},timingExact:{color:_sharedUi.night.color.textTertiary,fontSize:10,marginLeft:4},sizeRow:{flexDirection:"row",alignItems:"center",gap:16,marginLeft:"auto"},sizeItem:{flexDirection:"row",alignItems:"center",gap:4},sizeLabel:{color:_sharedUi.night.color.textTertiary,fontSize:10},sizeValue:{color:_sharedUi.night.color.info,fontSize:10,fontFamily:_sharedUi.monoFont,fontWeight:"600"},phaseDivider:{height:1,backgroundColor:_sharedUi.night.color.border,marginTop:12,marginBottom:12},phaseList:{gap:8},phaseRow:{flexDirection:"row",alignItems:"center",gap:14},phaseLabelGroup:{width:150},phaseLabel:{fontSize:12,color:_sharedUi.night.color.textSecondary},phaseHint:{fontSize:10,color:_sharedUi.night.color.textTertiary},phaseTrack:{flex:1,height:7,borderRadius:4,backgroundColor:_sharedUi.night.color.surfaceElevated,justifyContent:"center",overflow:"hidden"},phaseBar:{height:7,borderRadius:4},phaseValue:{width:72,textAlign:"right",fontSize:12,fontFamily:_sharedUi.monoFont,color:_sharedUi.night.color.text},collapsibleSection:{marginHorizontal:12,marginTop:8,backgroundColor:_sharedUi.night.color.surface,borderRadius:8,borderWidth:1,borderColor:_sharedUi.night.color.border,overflow:"hidden"},collapsibleHeader:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",padding:12,backgroundColor:_sharedUi.night.color.surfaceElevated},collapsibleTitle:{flexDirection:"row",alignItems:"center",gap:8},collapsibleTitleText:{color:_sharedUi.night.color.text,fontSize:13,fontWeight:"600"},collapsibleCount:{color:_sharedUi.night.color.textTertiary,fontSize:11.5,fontFamily:_sharedUi.monoFont},collapsibleContent:{padding:12},dataViewerContainer:{marginTop:-12,marginHorizontal:-12,marginBottom:-12},bodyDeferred:{height:120},errorBox:{flexDirection:"row",alignItems:"center",gap:6,backgroundColor:_sharedUi.night.color.dangerSoft,padding:8,borderRadius:4,marginTop:8},errorText:{color:_sharedUi.night.color.danger,fontSize:11,flex:1},emptyText:{color:_sharedUi.night.color.textTertiary,fontSize:12,fontStyle:"italic",textAlign:"center"},filterOptionsContainer:{gap:12},filterOption:{flexDirection:"row",alignItems:"center",justifyContent:"space-between",backgroundColor:_sharedUi.night.color.surfaceElevated,borderRadius:8,padding:12,borderWidth:1,borderColor:_sharedUi.night.color.border},filterOptionActive:{backgroundColor:_sharedUi.night.color.warningSoft,borderColor:_sharedUi.night.color.warning+"33"},filterOptionLeft:{flexDirection:"row",alignItems:"center",gap:12,flex:1},filterOptionContent:{flex:1},filterOptionLabel:{color:_sharedUi.night.color.textSecondary,fontSize:11,marginBottom:2,textTransform:"uppercase",letterSpacing:.5},filterOptionValue:{color:_sharedUi.night.color.text,fontSize:13,fontFamily:_sharedUi.monoFont},filterToggle:{paddingHorizontal:10,paddingVertical:6,borderRadius:4,backgroundColor:_sharedUi.night.color.bg,borderWidth:1,borderColor:_sharedUi.night.color.border},filterToggleActive:{backgroundColor:_sharedUi.night.color.warningSoft,borderColor:_sharedUi.night.color.warning+"4D"},filterToggleText:{fontSize:10,fontWeight:"600",color:_sharedUi.night.color.textTertiary,letterSpacing:.5},filterToggleTextActive:{color:_sharedUi.night.color.warning},filterInfoBox:{backgroundColor:_sharedUi.night.color.infoSoft,borderRadius:6,padding:10,borderWidth:1,borderColor:_sharedUi.night.color.info+"33"},filterInfoText:{color:_sharedUi.night.color.textSecondary,fontSize:11,lineHeight:16}});