@utk09/ui-observability 0.12.0 → 1.1.0

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 (523) hide show
  1. package/CHANGELOG.md +280 -10
  2. package/README.md +70 -839
  3. package/dist/{batch-BjQUwjA6.js → batch-D3NHhF9L.js} +4 -4
  4. package/dist/{batch-BjQUwjA6.js.map → batch-D3NHhF9L.js.map} +1 -1
  5. package/dist/{batch-D5LlU4Q9.cjs → batch-DnYRJqhU.cjs} +2 -2
  6. package/dist/{batch-D5LlU4Q9.cjs.map → batch-DnYRJqhU.cjs.map} +1 -1
  7. package/dist/bus/bus.d.cts +355 -0
  8. package/dist/bus/bus.d.ts +86 -12
  9. package/dist/bus/links.d.cts +132 -0
  10. package/dist/bus/links.d.ts +18 -3
  11. package/dist/bus/validation.d.cts +16 -0
  12. package/dist/bus/validation.d.ts +10 -1
  13. package/dist/bus-B__467mL.cjs +2 -0
  14. package/dist/bus-B__467mL.cjs.map +1 -0
  15. package/dist/bus-dw7T92sO.js +788 -0
  16. package/dist/bus-dw7T92sO.js.map +1 -0
  17. package/dist/capture/console.d.cts +37 -0
  18. package/dist/capture/console.d.ts +1 -1
  19. package/dist/capture/errors.d.cts +32 -0
  20. package/dist/capture/errors.d.ts +1 -1
  21. package/dist/capture/interactions.d.cts +80 -0
  22. package/dist/capture/interactions.d.ts +36 -4
  23. package/dist/capture/lifecycle.d.cts +20 -0
  24. package/dist/capture/lifecycle.d.ts +1 -1
  25. package/dist/capture/long-frames.d.cts +31 -0
  26. package/dist/capture/long-frames.d.ts +1 -1
  27. package/dist/capture/network.d.cts +57 -0
  28. package/dist/capture/network.d.ts +1 -1
  29. package/dist/capture/observed-windows.d.cts +51 -0
  30. package/dist/capture/observed-windows.d.ts +51 -0
  31. package/dist/capture/profiler-frames.d.cts +44 -0
  32. package/dist/capture/profiler-frames.d.ts +1 -1
  33. package/dist/capture/replay-buffer.d.cts +45 -0
  34. package/dist/capture/replay-buffer.d.ts +9 -10
  35. package/dist/capture/replay-upload.d.cts +79 -0
  36. package/dist/capture/replay-upload.d.ts +7 -2
  37. package/dist/capture/replay.d.cts +114 -0
  38. package/dist/capture/replay.d.ts +1 -1
  39. package/dist/capture/reports.d.cts +17 -0
  40. package/dist/capture/reports.d.ts +1 -1
  41. package/dist/capture/resource-timing.d.cts +14 -0
  42. package/dist/capture/resource-timing.d.ts +1 -1
  43. package/dist/capture/server-timing.d.cts +19 -0
  44. package/dist/capture/storm.d.cts +13 -0
  45. package/dist/capture/storm.d.ts +5 -5
  46. package/dist/capture/types.d.cts +128 -0
  47. package/dist/capture/types.d.ts +10 -9
  48. package/dist/capture/unclean-exit.d.cts +31 -0
  49. package/dist/capture/unclean-exit.d.ts +1 -1
  50. package/dist/capture/user-timing.d.cts +22 -0
  51. package/dist/capture/user-timing.d.ts +2 -2
  52. package/dist/capture/web-socket.d.cts +40 -0
  53. package/dist/capture/web-socket.d.ts +3 -3
  54. package/dist/capture/web-vitals.d.cts +40 -0
  55. package/dist/capture/web-vitals.d.ts +1 -1
  56. package/dist/{compression-lD9abCcO.cjs → compression-C0hUHKR-.cjs} +2 -2
  57. package/dist/{compression-lD9abCcO.cjs.map → compression-C0hUHKR-.cjs.map} +1 -1
  58. package/dist/{compression-AJJCMBOa.js → compression-SHPAvS4U.js} +2 -2
  59. package/dist/{compression-AJJCMBOa.js.map → compression-SHPAvS4U.js.map} +1 -1
  60. package/dist/config-CSNcS7OZ.js +558 -0
  61. package/dist/config-CSNcS7OZ.js.map +1 -0
  62. package/dist/config-CybPP5VM.cjs +2 -0
  63. package/dist/config-CybPP5VM.cjs.map +1 -0
  64. package/dist/console-BsM-fSCQ.js +81 -0
  65. package/dist/console-BsM-fSCQ.js.map +1 -0
  66. package/dist/console-Dkxs6IVQ.cjs +2 -0
  67. package/dist/console-Dkxs6IVQ.cjs.map +1 -0
  68. package/dist/constants-BwJDXzj6.js +357 -0
  69. package/dist/constants-BwJDXzj6.js.map +1 -0
  70. package/dist/constants-CtF52hIV.cjs +2 -0
  71. package/dist/constants-CtF52hIV.cjs.map +1 -0
  72. package/dist/constants.d.cts +763 -0
  73. package/dist/constants.d.ts +100 -20
  74. package/dist/core/breadcrumbs.d.cts +54 -0
  75. package/dist/core/breadcrumbs.d.ts +5 -0
  76. package/dist/core/config.d.cts +45 -0
  77. package/dist/core/config.d.ts +30 -2
  78. package/dist/core/context.d.cts +24 -0
  79. package/dist/core/context.d.ts +3 -8
  80. package/dist/core/debug-buffer.d.cts +34 -0
  81. package/dist/core/debug-buffer.d.ts +3 -3
  82. package/dist/core/debug-bundle.d.cts +12 -0
  83. package/dist/core/debug-bundle.d.ts +3 -3
  84. package/dist/core/deferred.d.cts +7 -0
  85. package/dist/core/deferred.d.ts +2 -2
  86. package/dist/core/diagnostics.d.cts +86 -0
  87. package/dist/core/diagnostics.d.ts +1 -1
  88. package/dist/core/drops.d.cts +39 -0
  89. package/dist/core/drops.d.ts +16 -6
  90. package/dist/core/hold-buffer.d.cts +36 -0
  91. package/dist/core/hold-buffer.d.ts +16 -7
  92. package/dist/core/journey.d.cts +148 -0
  93. package/dist/core/journey.d.ts +7 -7
  94. package/dist/core/logger.d.cts +141 -0
  95. package/dist/core/logger.d.ts +23 -30
  96. package/dist/core/measure.d.cts +30 -0
  97. package/dist/core/measure.d.ts +14 -3
  98. package/dist/core/meter.d.cts +78 -0
  99. package/dist/core/meter.d.ts +14 -8
  100. package/dist/core/pipeline.d.cts +227 -0
  101. package/dist/core/pipeline.d.ts +73 -10
  102. package/dist/core/profile-buckets.d.cts +31 -0
  103. package/dist/core/profiler.d.cts +218 -0
  104. package/dist/core/profiler.d.ts +2 -2
  105. package/dist/core/record.d.cts +190 -0
  106. package/dist/core/record.d.ts +44 -12
  107. package/dist/core/remote-rules.d.cts +17 -0
  108. package/dist/core/remote-rules.d.ts +3 -3
  109. package/dist/core/remote-sampling.d.cts +74 -0
  110. package/dist/core/remote-sampling.d.ts +3 -3
  111. package/dist/core/rotation.d.cts +99 -0
  112. package/dist/core/rotation.d.ts +99 -0
  113. package/dist/core/runtime.d.cts +774 -0
  114. package/dist/core/runtime.d.ts +254 -70
  115. package/dist/core/sampling.d.cts +86 -0
  116. package/dist/core/sampling.d.ts +5 -5
  117. package/dist/core/sender.d.cts +161 -0
  118. package/dist/core/sender.d.ts +59 -15
  119. package/dist/core/spans.d.cts +39 -0
  120. package/dist/core/spans.d.ts +1 -1
  121. package/dist/debug-bundle-B2v6Cym-.cjs +2 -0
  122. package/dist/debug-bundle-B2v6Cym-.cjs.map +1 -0
  123. package/dist/debug-bundle-Cs_YWzTa.js +35 -0
  124. package/dist/debug-bundle-Cs_YWzTa.js.map +1 -0
  125. package/dist/defineProperty-X1c4tIPD.cjs +1 -0
  126. package/dist/defineProperty-s2S8BXUc.js +35 -0
  127. package/dist/doctor.cjs +1 -1
  128. package/dist/doctor.cjs.map +1 -1
  129. package/dist/doctor.d.cts +36 -0
  130. package/dist/doctor.d.ts +5 -2
  131. package/dist/doctor.js +119 -87
  132. package/dist/doctor.js.map +1 -1
  133. package/dist/errors-DP2RUm4V.cjs +3 -0
  134. package/dist/errors-DP2RUm4V.cjs.map +1 -0
  135. package/dist/errors-Q3Ng1ciC.js +86 -0
  136. package/dist/errors-Q3Ng1ciC.js.map +1 -0
  137. package/dist/factory-DV17sm2p.js +404 -0
  138. package/dist/factory-DV17sm2p.js.map +1 -0
  139. package/dist/factory-K8O6gpux.cjs +2 -0
  140. package/dist/factory-K8O6gpux.cjs.map +1 -0
  141. package/dist/guards-BlYGRK4l.js +10 -0
  142. package/dist/guards-BlYGRK4l.js.map +1 -0
  143. package/dist/guards-EjG3ahFp.cjs +2 -0
  144. package/dist/guards-EjG3ahFp.cjs.map +1 -0
  145. package/dist/{identity-BrQp_5J5.js → identity-BgtHyY4u.js} +33 -26
  146. package/dist/identity-BgtHyY4u.js.map +1 -0
  147. package/dist/identity-CvuyqZk7.cjs +2 -0
  148. package/dist/identity-CvuyqZk7.cjs.map +1 -0
  149. package/dist/index.cjs +1 -1
  150. package/dist/index.cjs.map +1 -1
  151. package/dist/index.d.cts +301 -0
  152. package/dist/index.d.ts +90 -98
  153. package/dist/index.js +1253 -1555
  154. package/dist/index.js.map +1 -1
  155. package/dist/indexeddb-storage-D4KVcqdD.cjs +2 -0
  156. package/dist/indexeddb-storage-D4KVcqdD.cjs.map +1 -0
  157. package/dist/{indexeddb-storage-DLXQzAGh.js → indexeddb-storage-e-13ZLWm.js} +61 -57
  158. package/dist/indexeddb-storage-e-13ZLWm.js.map +1 -0
  159. package/dist/interactions-Byxf1C82.js +207 -0
  160. package/dist/interactions-Byxf1C82.js.map +1 -0
  161. package/dist/interactions-OK85T-Dk.cjs +2 -0
  162. package/dist/interactions-OK85T-Dk.cjs.map +1 -0
  163. package/dist/{journey-35yCMNFo.js → journey-C93FTYcs.js} +46 -49
  164. package/dist/journey-C93FTYcs.js.map +1 -0
  165. package/dist/journey-nMbob3OB.cjs +2 -0
  166. package/dist/journey-nMbob3OB.cjs.map +1 -0
  167. package/dist/{library-console-BFWEuQsl.cjs → library-console-DJUQzcgM.cjs} +2 -2
  168. package/dist/{library-console-BFWEuQsl.cjs.map → library-console-DJUQzcgM.cjs.map} +1 -1
  169. package/dist/{library-console-Dl_Ly6DQ.js → library-console-DklSmucS.js} +2 -2
  170. package/dist/{library-console-Dl_Ly6DQ.js.map → library-console-DklSmucS.js.map} +1 -1
  171. package/dist/{library-request-nI6pvI6I.js → library-request-UGEwOHpf.js} +2 -2
  172. package/dist/{library-request-nI6pvI6I.js.map → library-request-UGEwOHpf.js.map} +1 -1
  173. package/dist/{library-request-Da-CHKzT.cjs → library-request-kY9iTpIF.cjs} +2 -2
  174. package/dist/{library-request-Da-CHKzT.cjs.map → library-request-kY9iTpIF.cjs.map} +1 -1
  175. package/dist/{lifecycle-CZ6RRXc6.js → lifecycle-B2PlIuQu.js} +21 -29
  176. package/dist/lifecycle-B2PlIuQu.js.map +1 -0
  177. package/dist/lifecycle-DaMdH_X7.cjs +2 -0
  178. package/dist/lifecycle-DaMdH_X7.cjs.map +1 -0
  179. package/dist/log-record-Bmx6etMh.cjs +2 -0
  180. package/dist/log-record-Bmx6etMh.cjs.map +1 -0
  181. package/dist/{log-record-DIA6McNr.js → log-record-DSt2P-Sr.js} +8 -7
  182. package/dist/log-record-DSt2P-Sr.js.map +1 -0
  183. package/dist/{long-frames-430_85Da.js → long-frames-Bamjs1WV.js} +18 -22
  184. package/dist/long-frames-Bamjs1WV.js.map +1 -0
  185. package/dist/long-frames-lhtONgGt.cjs +2 -0
  186. package/dist/long-frames-lhtONgGt.cjs.map +1 -0
  187. package/dist/models/batch.d.cts +57 -0
  188. package/dist/models/batch.d.ts +2 -2
  189. package/dist/models/bus.d.cts +163 -0
  190. package/dist/models/bus.d.ts +28 -3
  191. package/dist/models/config.d.cts +1555 -0
  192. package/dist/models/config.d.ts +377 -261
  193. package/dist/models/drop.d.cts +54 -0
  194. package/dist/models/drop.d.ts +16 -3
  195. package/dist/models/health.d.cts +148 -0
  196. package/dist/models/health.d.ts +108 -12
  197. package/dist/models/log-record.d.cts +61 -0
  198. package/dist/models/metric.d.cts +139 -0
  199. package/dist/models/metric.d.ts +13 -2
  200. package/dist/models/plugin.d.cts +47 -0
  201. package/dist/models/plugin.d.ts +3 -3
  202. package/dist/models/replay.d.cts +60 -0
  203. package/dist/models/serializer.d.cts +25 -0
  204. package/dist/models/serializer.d.ts +4 -2
  205. package/dist/models/storage.d.cts +95 -0
  206. package/dist/models/storage.d.ts +7 -5
  207. package/dist/network-BCn8Gn47.cjs +2 -0
  208. package/dist/network-BCn8Gn47.cjs.map +1 -0
  209. package/dist/{network-C7SkLf4v.js → network-Cg1L2w2r.js} +57 -57
  210. package/dist/network-Cg1L2w2r.js.map +1 -0
  211. package/dist/observed-windows-B3gJkdql.cjs +2 -0
  212. package/dist/observed-windows-B3gJkdql.cjs.map +1 -0
  213. package/dist/observed-windows-BrwaJNlj.js +64 -0
  214. package/dist/observed-windows-BrwaJNlj.js.map +1 -0
  215. package/dist/{otlp-2MCrC3kd.cjs → otlp-CrAWkQdO.cjs} +2 -2
  216. package/dist/{otlp-2MCrC3kd.cjs.map → otlp-CrAWkQdO.cjs.map} +1 -1
  217. package/dist/{otlp-COq033e3.js → otlp-D6dRZyB8.js} +9 -9
  218. package/dist/{otlp-COq033e3.js.map → otlp-D6dRZyB8.js.map} +1 -1
  219. package/dist/{platform-CVewe4wQ.js → platform-8DLhjddo.js} +9 -9
  220. package/dist/{platform-CVewe4wQ.js.map → platform-8DLhjddo.js.map} +1 -1
  221. package/dist/{platform-12uR7kBQ.cjs → platform-BqRc-7RO.cjs} +2 -2
  222. package/dist/{platform-12uR7kBQ.cjs.map → platform-BqRc-7RO.cjs.map} +1 -1
  223. package/dist/{profiler-BVWIOgnq.js → profiler-BaXSqCfz.js} +78 -96
  224. package/dist/profiler-BaXSqCfz.js.map +1 -0
  225. package/dist/profiler-BvWW2kNM.cjs +2 -0
  226. package/dist/profiler-BvWW2kNM.cjs.map +1 -0
  227. package/dist/{profiler-frames-CLXlT_xL.js → profiler-frames-C4ySHN0X.js} +21 -29
  228. package/dist/profiler-frames-C4ySHN0X.js.map +1 -0
  229. package/dist/profiler-frames-DeaBiB-5.cjs +2 -0
  230. package/dist/profiler-frames-DeaBiB-5.cjs.map +1 -0
  231. package/dist/remote-rules-D7L6D_D2.cjs +2 -0
  232. package/dist/remote-rules-D7L6D_D2.cjs.map +1 -0
  233. package/dist/remote-rules-Dq9xe7Qn.js +95 -0
  234. package/dist/remote-rules-Dq9xe7Qn.js.map +1 -0
  235. package/dist/replay-B0M8kWz_.js +310 -0
  236. package/dist/replay-B0M8kWz_.js.map +1 -0
  237. package/dist/replay-QOFBpAXh.cjs +2 -0
  238. package/dist/replay-QOFBpAXh.cjs.map +1 -0
  239. package/dist/{reports-BuXekPOS.js → reports--8APRLa-.js} +25 -30
  240. package/dist/reports--8APRLa-.js.map +1 -0
  241. package/dist/reports-ojuMKGO7.cjs +2 -0
  242. package/dist/reports-ojuMKGO7.cjs.map +1 -0
  243. package/dist/{resource-timing-CXGHwFRD.js → resource-timing-BzR05rE-.js} +20 -23
  244. package/dist/resource-timing-BzR05rE-.js.map +1 -0
  245. package/dist/resource-timing-pAG3ZhB5.cjs +2 -0
  246. package/dist/resource-timing-pAG3ZhB5.cjs.map +1 -0
  247. package/dist/response-body-BWvwKQ2p.js +331 -0
  248. package/dist/response-body-BWvwKQ2p.js.map +1 -0
  249. package/dist/response-body-CKEJ5itk.cjs +3 -0
  250. package/dist/response-body-CKEJ5itk.cjs.map +1 -0
  251. package/dist/rotation-BylN1B9e.js +93 -0
  252. package/dist/rotation-BylN1B9e.js.map +1 -0
  253. package/dist/rotation-E2eKClIs.cjs +2 -0
  254. package/dist/rotation-E2eKClIs.cjs.map +1 -0
  255. package/dist/sampling-B46LW0cy.cjs +2 -0
  256. package/dist/sampling-B46LW0cy.cjs.map +1 -0
  257. package/dist/sampling-zXA6r-Nw.js +63 -0
  258. package/dist/sampling-zXA6r-Nw.js.map +1 -0
  259. package/dist/{sanitize-CNmsD9r3.js → sanitize-DjnR6RXR.js} +2 -2
  260. package/dist/sanitize-DjnR6RXR.js.map +1 -0
  261. package/dist/{sanitize-ChLn97Ch.cjs → sanitize-Qj6LuZqp.cjs} +2 -2
  262. package/dist/sanitize-Qj6LuZqp.cjs.map +1 -0
  263. package/dist/sender-Bdp-TAS4.js +979 -0
  264. package/dist/sender-Bdp-TAS4.js.map +1 -0
  265. package/dist/sender-DR7ZycZY.cjs +2 -0
  266. package/dist/sender-DR7ZycZY.cjs.map +1 -0
  267. package/dist/storage/context-storage.d.cts +90 -0
  268. package/dist/storage/context-storage.d.ts +5 -5
  269. package/dist/storage/emergency-queue.d.cts +27 -0
  270. package/dist/storage/emergency-queue.d.ts +4 -4
  271. package/dist/storage/eviction.d.cts +40 -0
  272. package/dist/storage/eviction.d.ts +1 -1
  273. package/dist/storage/factory.d.cts +21 -0
  274. package/dist/storage/factory.d.ts +3 -3
  275. package/dist/storage/gap.d.cts +20 -0
  276. package/dist/storage/gap.d.ts +3 -3
  277. package/dist/storage/idb-driver.d.cts +93 -0
  278. package/dist/storage/idb-driver.d.ts +1 -1
  279. package/dist/storage/indexeddb-storage.d.cts +97 -0
  280. package/dist/storage/indexeddb-storage.d.ts +12 -4
  281. package/dist/storage/keys.d.cts +17 -0
  282. package/dist/storage/keys.d.ts +2 -2
  283. package/dist/storage/local-storage.d.cts +139 -0
  284. package/dist/storage/local-storage.d.ts +11 -4
  285. package/dist/storage/memory-storage.d.cts +73 -0
  286. package/dist/storage/memory-storage.d.ts +4 -3
  287. package/dist/storage/persistence.d.cts +8 -0
  288. package/dist/storage/persistence.d.ts +2 -2
  289. package/dist/storage/stored-context.d.cts +34 -0
  290. package/dist/storage/stored-context.d.ts +34 -0
  291. package/dist/stored-context-BOu54M8Y.cjs +2 -0
  292. package/dist/stored-context-BOu54M8Y.cjs.map +1 -0
  293. package/dist/stored-context-CSttrAsw.js +51 -0
  294. package/dist/stored-context-CSttrAsw.js.map +1 -0
  295. package/dist/storm-BHgI12iS.cjs +2 -0
  296. package/dist/storm-BHgI12iS.cjs.map +1 -0
  297. package/dist/storm-DKlpv0FL.js +9 -0
  298. package/dist/storm-DKlpv0FL.js.map +1 -0
  299. package/dist/transport/compression.d.cts +7 -0
  300. package/dist/transport/custom-transport.d.cts +22 -0
  301. package/dist/transport/custom-transport.d.ts +6 -5
  302. package/dist/transport/errors.d.cts +31 -0
  303. package/dist/transport/exit-flush.d.cts +135 -0
  304. package/dist/transport/exit-flush.d.ts +30 -13
  305. package/dist/transport/headers.d.cts +8 -0
  306. package/dist/transport/headers.d.ts +2 -2
  307. package/dist/transport/http-transport.d.cts +116 -0
  308. package/dist/transport/http-transport.d.ts +20 -8
  309. package/dist/transport/memory-transport.d.cts +30 -0
  310. package/dist/transport/memory-transport.d.ts +2 -2
  311. package/dist/transport/response-body.d.cts +49 -0
  312. package/dist/transport/response-body.d.ts +49 -0
  313. package/dist/transport/retry-engine.d.cts +129 -0
  314. package/dist/transport/retry-engine.d.ts +27 -9
  315. package/dist/transport/serializers/ecs.d.cts +3 -0
  316. package/dist/transport/serializers/ecs.d.ts +1 -1
  317. package/dist/transport/serializers/otlp-metrics.d.cts +3 -0
  318. package/dist/transport/serializers/otlp-metrics.d.ts +1 -1
  319. package/dist/transport/serializers/otlp-traces.d.cts +3 -0
  320. package/dist/transport/serializers/otlp-traces.d.ts +1 -1
  321. package/dist/transport/serializers/otlp.d.cts +47 -0
  322. package/dist/transport/serializers/otlp.d.ts +2 -2
  323. package/dist/transport/serializers/select.d.cts +38 -0
  324. package/dist/transport/serializers/select.d.ts +5 -5
  325. package/dist/transport/status-transport.d.cts +129 -0
  326. package/dist/transport/status-transport.d.ts +25 -8
  327. package/dist/transport/worker-client.d.cts +23 -0
  328. package/dist/transport/worker-client.d.ts +12 -3
  329. package/dist/transport/worker-entry.d.cts +5 -0
  330. package/dist/transport/worker-entry.d.ts +1 -1
  331. package/dist/transport/worker-protocol.d.cts +38 -0
  332. package/dist/transport/worker-protocol.d.ts +4 -2
  333. package/dist/transport/worker-server.d.cts +3 -0
  334. package/dist/transport/worker-server.d.ts +1 -1
  335. package/dist/transport/worker-transport.d.cts +10 -0
  336. package/dist/transport/worker-transport.d.ts +5 -4
  337. package/dist/types-BAerHgCq.js.map +1 -1
  338. package/dist/types-C7WNpnG1.cjs.map +1 -1
  339. package/dist/unclean-exit-BYPYYkQ5.cjs +2 -0
  340. package/dist/unclean-exit-BYPYYkQ5.cjs.map +1 -0
  341. package/dist/{unclean-exit-Cob_jyTv.js → unclean-exit-BcOB8A2e.js} +23 -30
  342. package/dist/unclean-exit-BcOB8A2e.js.map +1 -0
  343. package/dist/{user-timing-DgHubxCI.js → user-timing-4KIJ74Vi.js} +15 -17
  344. package/dist/user-timing-4KIJ74Vi.js.map +1 -0
  345. package/dist/user-timing-BsU2wQKE.cjs +2 -0
  346. package/dist/user-timing-BsU2wQKE.cjs.map +1 -0
  347. package/dist/utils/console.d.cts +36 -0
  348. package/dist/utils/console.d.ts +4 -4
  349. package/dist/utils/deadline.d.cts +14 -0
  350. package/dist/utils/error-like.d.cts +25 -0
  351. package/dist/utils/fixed-window.d.cts +25 -0
  352. package/dist/utils/global-scope.d.cts +20 -0
  353. package/dist/utils/guards.d.cts +14 -0
  354. package/dist/utils/guards.d.ts +8 -0
  355. package/dist/utils/identity.d.cts +114 -0
  356. package/dist/utils/identity.d.ts +8 -4
  357. package/dist/utils/library-console.d.cts +11 -0
  358. package/dist/utils/library-request.d.cts +24 -0
  359. package/dist/utils/lock.d.cts +24 -0
  360. package/dist/utils/lock.d.ts +1 -1
  361. package/dist/utils/openfin.d.cts +48 -0
  362. package/dist/utils/patch.d.cts +9 -0
  363. package/dist/utils/platform.d.cts +62 -0
  364. package/dist/utils/platform.d.ts +2 -2
  365. package/dist/utils/sanitize.d.cts +52 -0
  366. package/dist/utils/sanitize.d.ts +1 -1
  367. package/dist/utils/sequence.d.cts +10 -0
  368. package/dist/utils/tracing.d.cts +158 -0
  369. package/dist/utils/tracing.d.ts +11 -4
  370. package/dist/utils/unref.d.cts +9 -0
  371. package/dist/web-socket-Cs1ZbmmN.cjs +2 -0
  372. package/dist/{web-socket-DthJuSAg.js.map → web-socket-Cs1ZbmmN.cjs.map} +1 -1
  373. package/dist/{web-socket-DthJuSAg.js → web-socket-Zg0hj1LB.js} +23 -28
  374. package/dist/web-socket-Zg0hj1LB.js.map +1 -0
  375. package/dist/{web-vitals-CsGCWnUr.js → web-vitals-4pWACwaR.js} +15 -21
  376. package/dist/web-vitals-4pWACwaR.js.map +1 -0
  377. package/dist/web-vitals-__X7t4pj.cjs +2 -0
  378. package/dist/web-vitals-__X7t4pj.cjs.map +1 -0
  379. package/dist/{worker-protocol-B0_8rWy5.js → worker-protocol-CYpAbrVl.js} +14 -11
  380. package/dist/worker-protocol-CYpAbrVl.js.map +1 -0
  381. package/dist/worker-protocol-DFYXIFus.cjs +2 -0
  382. package/dist/worker-protocol-DFYXIFus.cjs.map +1 -0
  383. package/dist/worker-server--yGTadTA.cjs +2 -0
  384. package/dist/worker-server--yGTadTA.cjs.map +1 -0
  385. package/dist/worker-server-BokySIII.js +94 -0
  386. package/dist/worker-server-BokySIII.js.map +1 -0
  387. package/dist/worker-transport-BdEvh_-a.cjs +2 -0
  388. package/dist/worker-transport-BdEvh_-a.cjs.map +1 -0
  389. package/dist/worker-transport-JK-Fby9J.js +194 -0
  390. package/dist/worker-transport-JK-Fby9J.js.map +1 -0
  391. package/llms.txt +400 -0
  392. package/package.json +65 -49
  393. package/dist/bus-D_7pd7RN.cjs +0 -2
  394. package/dist/bus-D_7pd7RN.cjs.map +0 -1
  395. package/dist/bus-ecxUNTja.js +0 -660
  396. package/dist/bus-ecxUNTja.js.map +0 -1
  397. package/dist/console-CLz_PvFn.cjs +0 -2
  398. package/dist/console-CLz_PvFn.cjs.map +0 -1
  399. package/dist/console-cwgHKXvM.js +0 -82
  400. package/dist/console-cwgHKXvM.js.map +0 -1
  401. package/dist/constants-Bwl_YtQi.js +0 -349
  402. package/dist/constants-Bwl_YtQi.js.map +0 -1
  403. package/dist/constants-DakMxVB2.cjs +0 -2
  404. package/dist/constants-DakMxVB2.cjs.map +0 -1
  405. package/dist/context-storage-BjzeBSxH.cjs +0 -2
  406. package/dist/context-storage-BjzeBSxH.cjs.map +0 -1
  407. package/dist/context-storage-BzkoHzkQ.js +0 -51
  408. package/dist/context-storage-BzkoHzkQ.js.map +0 -1
  409. package/dist/debug-bundle-BOdYmCeV.js +0 -32
  410. package/dist/debug-bundle-BOdYmCeV.js.map +0 -1
  411. package/dist/debug-bundle-Ex4L_LSP.cjs +0 -2
  412. package/dist/debug-bundle-Ex4L_LSP.cjs.map +0 -1
  413. package/dist/emergency-queue-B9WZxanZ.js +0 -67
  414. package/dist/emergency-queue-B9WZxanZ.js.map +0 -1
  415. package/dist/emergency-queue-HBpL5r3V.cjs +0 -2
  416. package/dist/emergency-queue-HBpL5r3V.cjs.map +0 -1
  417. package/dist/errors-D6bwgJtO.js +0 -92
  418. package/dist/errors-D6bwgJtO.js.map +0 -1
  419. package/dist/errors-DCOCRdSi.cjs +0 -3
  420. package/dist/errors-DCOCRdSi.cjs.map +0 -1
  421. package/dist/factory-DLFDjdLv.cjs +0 -2
  422. package/dist/factory-DLFDjdLv.cjs.map +0 -1
  423. package/dist/factory-e9Qo3K0z.js +0 -276
  424. package/dist/factory-e9Qo3K0z.js.map +0 -1
  425. package/dist/guards-Cidk71ME.js +0 -7
  426. package/dist/guards-Cidk71ME.js.map +0 -1
  427. package/dist/guards-nJ70syPt.cjs +0 -2
  428. package/dist/guards-nJ70syPt.cjs.map +0 -1
  429. package/dist/identity-BlvlgjrU.cjs +0 -2
  430. package/dist/identity-BlvlgjrU.cjs.map +0 -1
  431. package/dist/identity-BrQp_5J5.js.map +0 -1
  432. package/dist/indexeddb-storage-CtLvZH1r.cjs +0 -2
  433. package/dist/indexeddb-storage-CtLvZH1r.cjs.map +0 -1
  434. package/dist/indexeddb-storage-DLXQzAGh.js.map +0 -1
  435. package/dist/interactions-B6z2I4tU.js +0 -119
  436. package/dist/interactions-B6z2I4tU.js.map +0 -1
  437. package/dist/interactions-P6pz08Jn.cjs +0 -2
  438. package/dist/interactions-P6pz08Jn.cjs.map +0 -1
  439. package/dist/journey-35yCMNFo.js.map +0 -1
  440. package/dist/journey-DAGh5h9k.cjs +0 -2
  441. package/dist/journey-DAGh5h9k.cjs.map +0 -1
  442. package/dist/keys-BHhw_0Wh.cjs +0 -2
  443. package/dist/keys-BHhw_0Wh.cjs.map +0 -1
  444. package/dist/keys-BU9j5YqW.js +0 -16
  445. package/dist/keys-BU9j5YqW.js.map +0 -1
  446. package/dist/lifecycle-BGGOcN4N.cjs +0 -2
  447. package/dist/lifecycle-BGGOcN4N.cjs.map +0 -1
  448. package/dist/lifecycle-CZ6RRXc6.js.map +0 -1
  449. package/dist/log-record-D7bA1RPb.cjs +0 -2
  450. package/dist/log-record-D7bA1RPb.cjs.map +0 -1
  451. package/dist/log-record-DIA6McNr.js.map +0 -1
  452. package/dist/long-frames-430_85Da.js.map +0 -1
  453. package/dist/long-frames-Dd8tsi2U.cjs +0 -2
  454. package/dist/long-frames-Dd8tsi2U.cjs.map +0 -1
  455. package/dist/models/stats.d.ts +0 -11
  456. package/dist/network-C7SkLf4v.js.map +0 -1
  457. package/dist/network-pEX3PAJv.cjs +0 -2
  458. package/dist/network-pEX3PAJv.cjs.map +0 -1
  459. package/dist/profiler-BVWIOgnq.js.map +0 -1
  460. package/dist/profiler-eVCknCzS.cjs +0 -2
  461. package/dist/profiler-eVCknCzS.cjs.map +0 -1
  462. package/dist/profiler-frames-CLXlT_xL.js.map +0 -1
  463. package/dist/profiler-frames-Dg2OebB2.cjs +0 -2
  464. package/dist/profiler-frames-Dg2OebB2.cjs.map +0 -1
  465. package/dist/remote-rules-BJGDJGwA.js +0 -98
  466. package/dist/remote-rules-BJGDJGwA.js.map +0 -1
  467. package/dist/remote-rules-CJD3ToVk.cjs +0 -2
  468. package/dist/remote-rules-CJD3ToVk.cjs.map +0 -1
  469. package/dist/replay-0zAJv9T3.js +0 -338
  470. package/dist/replay-0zAJv9T3.js.map +0 -1
  471. package/dist/replay-DomJpXqW.cjs +0 -2
  472. package/dist/replay-DomJpXqW.cjs.map +0 -1
  473. package/dist/reports-BsbqmP8h.cjs +0 -2
  474. package/dist/reports-BsbqmP8h.cjs.map +0 -1
  475. package/dist/reports-BuXekPOS.js.map +0 -1
  476. package/dist/resource-timing-CXGHwFRD.js.map +0 -1
  477. package/dist/resource-timing-DkycFGDa.cjs +0 -2
  478. package/dist/resource-timing-DkycFGDa.cjs.map +0 -1
  479. package/dist/sampling-Dd0wllyq.cjs +0 -2
  480. package/dist/sampling-Dd0wllyq.cjs.map +0 -1
  481. package/dist/sampling-UUDbi3K0.js +0 -60
  482. package/dist/sampling-UUDbi3K0.js.map +0 -1
  483. package/dist/sanitize-CNmsD9r3.js.map +0 -1
  484. package/dist/sanitize-ChLn97Ch.cjs.map +0 -1
  485. package/dist/select-CTk-K5mG.cjs +0 -3
  486. package/dist/select-CTk-K5mG.cjs.map +0 -1
  487. package/dist/select-DPv_j6wq.js +0 -270
  488. package/dist/select-DPv_j6wq.js.map +0 -1
  489. package/dist/sender-15zEsZpr.js +0 -857
  490. package/dist/sender-15zEsZpr.js.map +0 -1
  491. package/dist/sender-Bfpv9tad.cjs +0 -2
  492. package/dist/sender-Bfpv9tad.cjs.map +0 -1
  493. package/dist/storage-BA9RqRO-.cjs +0 -2
  494. package/dist/storage-BA9RqRO-.cjs.map +0 -1
  495. package/dist/storage-DZwed89z.js +0 -16
  496. package/dist/storage-DZwed89z.js.map +0 -1
  497. package/dist/storm-BTSNTIWI.js +0 -9
  498. package/dist/storm-BTSNTIWI.js.map +0 -1
  499. package/dist/storm-D0_qZOEg.cjs +0 -2
  500. package/dist/storm-D0_qZOEg.cjs.map +0 -1
  501. package/dist/unclean-exit-ClGzrc2A.cjs +0 -2
  502. package/dist/unclean-exit-ClGzrc2A.cjs.map +0 -1
  503. package/dist/unclean-exit-Cob_jyTv.js.map +0 -1
  504. package/dist/user-timing-CdYqx3PF.cjs +0 -2
  505. package/dist/user-timing-CdYqx3PF.cjs.map +0 -1
  506. package/dist/user-timing-DgHubxCI.js.map +0 -1
  507. package/dist/utils/timer.d.ts +0 -19
  508. package/dist/web-socket-BTuvYoJI.cjs +0 -2
  509. package/dist/web-socket-BTuvYoJI.cjs.map +0 -1
  510. package/dist/web-vitals-Ch5BpDmo.cjs +0 -2
  511. package/dist/web-vitals-Ch5BpDmo.cjs.map +0 -1
  512. package/dist/web-vitals-CsGCWnUr.js.map +0 -1
  513. package/dist/worker-protocol-B0_8rWy5.js.map +0 -1
  514. package/dist/worker-protocol-BjzFORfq.cjs +0 -2
  515. package/dist/worker-protocol-BjzFORfq.cjs.map +0 -1
  516. package/dist/worker-server-4en-Lt-3.cjs +0 -2
  517. package/dist/worker-server-4en-Lt-3.cjs.map +0 -1
  518. package/dist/worker-server-Cne9MX9I.js +0 -83
  519. package/dist/worker-server-Cne9MX9I.js.map +0 -1
  520. package/dist/worker-transport-B-GF4Aqn.cjs +0 -2
  521. package/dist/worker-transport-B-GF4Aqn.cjs.map +0 -1
  522. package/dist/worker-transport-C3SjJAEC.js +0 -200
  523. package/dist/worker-transport-C3SjJAEC.js.map +0 -1
@@ -0,0 +1,128 @@
1
+ import type { BreadcrumbBuffer } from "../core/breadcrumbs.cjs";
2
+ import type { Diagnostics } from "../core/diagnostics.cjs";
3
+ import type { SpanData } from "../core/spans.cjs";
4
+ import type { ResolvedConfig } from "../models/config.cjs";
5
+ import type { LogRecord, MetricType } from "../models/log-record.cjs";
6
+ import type { InstrumentDef, MetricAttributes } from "../models/metric.cjs";
7
+ import type { TraceEngine } from "../utils/tracing.cjs";
8
+ /**
9
+ * The logging interface the auto-capture modules use. Referring to the runtime class here
10
+ * would create an import cycle, because the runtime installs the capture modules.
11
+ */
12
+ export interface CaptureLogger {
13
+ /**
14
+ * Logs an error event, with the error or reason behind it.
15
+ * @param message Error description.
16
+ * @param error The caught error or reason.
17
+ * @param payload Optional attributes.
18
+ */
19
+ error(message: string, error?: unknown, payload?: Record<string, unknown>): void;
20
+ /**
21
+ * Logs a warning event.
22
+ * @param message Warning description.
23
+ * @param payload Optional attributes.
24
+ */
25
+ warn(message: string, payload?: Record<string, unknown>): void;
26
+ /**
27
+ * Logs a single lifecycle or user event.
28
+ * @param name Event identifier.
29
+ * @param payload Optional attributes.
30
+ */
31
+ logEvent(name: string, payload?: Record<string, unknown>): void;
32
+ /**
33
+ * Logs a numeric metric measurement.
34
+ * @param name Metric name.
35
+ * @param value The measurement.
36
+ * @param unit Unit of measurement.
37
+ * @param type Metric type.
38
+ * @param attrs Optional metric attributes. With metricsEndpoint they're point attributes.
39
+ * @param recordOnly Optional attributes for the record only, never on the OTLP point.
40
+ */
41
+ logMetric(name: string, value: number, unit?: string, type?: MetricType, attrs?: Record<string, unknown>, recordOnly?: Record<string, unknown>): void;
42
+ /**
43
+ * Logs a debug message.
44
+ * @param message Debug message.
45
+ * @param payload Optional attributes.
46
+ */
47
+ debug(message: string, payload?: Record<string, unknown>): void;
48
+ }
49
+ /**
50
+ * Capture work that runs once per document, not once per install. A reconfigure
51
+ * builds new capture instances, so instance state can't hold these flags.
52
+ * web-vitals has no unsubscribe, and a second subscription would report every
53
+ * metric twice.
54
+ */
55
+ export interface CaptureOnce {
56
+ /** True once the web-vitals reporters are subscribed. */
57
+ webVitals: boolean;
58
+ /** True once navigation timing has been reported. */
59
+ navigationTiming: boolean;
60
+ /** True after the first long frame install. Only that install reads buffered frames. */
61
+ longFrames: boolean;
62
+ /** True once we've read the previous page's alive marker. */
63
+ uncleanExit: boolean;
64
+ /** True after the first user timing install. Only that install reads buffered entries. */
65
+ userTiming: boolean;
66
+ /** True after the first resource timing install. Later installs skip buffered entries. */
67
+ resourceTiming?: boolean;
68
+ /** Page state and when it started. A reinstall keeps them, so it logs no false transition. */
69
+ lifecycle?: {
70
+ state: string;
71
+ enteredAt: number;
72
+ };
73
+ /** Set once the frame phases capture has reported a browser without long animation frames. */
74
+ framePhases?: boolean;
75
+ /** Set once the profiler's frame pacing has reported a context without frame callbacks. */
76
+ framePacing?: boolean;
77
+ /** Set once session replay has reported why it can't record in this document. */
78
+ replay?: boolean;
79
+ }
80
+ /** Runtime dependencies shared by all auto-capture instances. */
81
+ export interface CaptureContext {
82
+ /** False while the runtime is stopping or changing its security context. */
83
+ isActive?: () => boolean;
84
+ /** Active runtime configuration. */
85
+ config: ResolvedConfig;
86
+ /** Diagnostics reporter for capture faults. */
87
+ diagnostics: Diagnostics;
88
+ /** Logger for the telemetry the captures record. */
89
+ logger: CaptureLogger;
90
+ /** Breadcrumb buffer. */
91
+ breadcrumbs: BreadcrumbBuffer;
92
+ /** Active trace context provider. */
93
+ tracing: TraceEngine;
94
+ /** Guards for capture work that a reinstall must not repeat. */
95
+ once: CaptureOnce;
96
+ /** Adds a value to one of the runtime's counters or histograms. */
97
+ recordMetric: (def: InstrumentDef, value: number, attributes?: MetricAttributes) => void;
98
+ /** Records a span. The runtime drops it when spans are off. */
99
+ recordSpan: (span: SpanData) => void;
100
+ /** Returns the current session id. */
101
+ sessionId: () => string;
102
+ /** Sets or clears the hook that receives every ERROR and FATAL record from the runtime. */
103
+ onError?: (hook: ((record: LogRecord) => void) | undefined) => void;
104
+ /** Sets an ambient attribute on every later record. Undefined removes it. */
105
+ setContext?: (key: string, value: string | undefined) => void;
106
+ /** True after startReplay(), false after stopReplay(), undefined if neither was called. */
107
+ replayConsent?: () => boolean | undefined;
108
+ }
109
+ /** Lifecycle interface for the browser instrumentation modules. */
110
+ export interface Capture {
111
+ /** Module identifier used in diagnostics. */
112
+ readonly name: string;
113
+ /**
114
+ * Attaches the instrumentation listeners and patches the target APIs. Patching an
115
+ * already patched function adds a second wrapper and doubles every record, so a
116
+ * second call must do nothing.
117
+ */
118
+ install(): void;
119
+ /** Restores the native APIs and removes the listeners. */
120
+ uninstall(): void;
121
+ }
122
+ /**
123
+ * Checks whether a URL matches any of the substring or regular expression patterns.
124
+ * @param url URL to test. A value that isn't a string matches nothing.
125
+ * @param patterns Substrings and regular expressions to test against.
126
+ * @returns True if any pattern matches the URL.
127
+ */
128
+ export declare function matchesAny(url: unknown, patterns: (string | RegExp)[]): boolean;
@@ -1,10 +1,10 @@
1
- import type { BreadcrumbBuffer } from "../core/breadcrumbs";
2
- import type { Diagnostics } from "../core/diagnostics";
3
- import type { SpanData } from "../core/spans";
4
- import type { ResolvedConfig } from "../models/config";
5
- import type { LogRecord, MetricType } from "../models/log-record";
6
- import type { InstrumentDef, MetricAttributes } from "../models/metric";
7
- import type { TraceEngine } from "../utils/tracing";
1
+ import type { BreadcrumbBuffer } from "../core/breadcrumbs.js";
2
+ import type { Diagnostics } from "../core/diagnostics.js";
3
+ import type { SpanData } from "../core/spans.js";
4
+ import type { ResolvedConfig } from "../models/config.js";
5
+ import type { LogRecord, MetricType } from "../models/log-record.js";
6
+ import type { InstrumentDef, MetricAttributes } from "../models/metric.js";
7
+ import type { TraceEngine } from "../utils/tracing.js";
8
8
  /**
9
9
  * The logging interface the auto-capture modules use. Referring to the runtime class here
10
10
  * would create an import cycle, because the runtime installs the capture modules.
@@ -35,9 +35,10 @@ export interface CaptureLogger {
35
35
  * @param value The measurement.
36
36
  * @param unit Unit of measurement.
37
37
  * @param type Metric type.
38
- * @param attrs Optional metric attributes.
38
+ * @param attrs Optional metric attributes. With metricsEndpoint they're point attributes.
39
+ * @param recordOnly Optional attributes for the record only, never on the OTLP point.
39
40
  */
40
- logMetric(name: string, value: number, unit?: string, type?: MetricType, attrs?: Record<string, unknown>): void;
41
+ logMetric(name: string, value: number, unit?: string, type?: MetricType, attrs?: Record<string, unknown>, recordOnly?: Record<string, unknown>): void;
41
42
  /**
42
43
  * Logs a debug message.
43
44
  * @param message Debug message.
@@ -0,0 +1,31 @@
1
+ import type { Capture, CaptureContext } from "./types.cjs";
2
+ /** Reports the previous page's unclean exit, and maintains this page's marker. */
3
+ export declare class UncleanExitCapture implements Capture {
4
+ private readonly ctx;
5
+ /** Capture module identifier. */
6
+ readonly name = "uncleanExit";
7
+ /** Prevents duplicate listener registration. */
8
+ private installed;
9
+ /** Timer that updates the marker. */
10
+ private timer;
11
+ /** True after pagehide. Needed because the browser fires visibilitychange after pagehide. */
12
+ private closing;
13
+ /**
14
+ * @param ctx Capture context with the config, diagnostics, logger and session id.
15
+ */
16
+ constructor(ctx: CaptureContext);
17
+ /** Reports the previous page's marker once, then starts maintaining this page's own. */
18
+ install(): void;
19
+ /** Removes the listeners, the timer and the marker, since the capture stopped without a crash. */
20
+ uninstall(): void;
21
+ /** Logs WARN `ui.unclean_exit` if this tab's previous page left its marker behind. */
22
+ private reportPrevious;
23
+ /** Writes this page's marker with the current time and visibility. */
24
+ private readonly mark;
25
+ /** Removes this page's marker. */
26
+ private clear;
27
+ /** A clean close removes the marker. The page may still live on in the back-forward cache. */
28
+ private readonly onPageHide;
29
+ /** A page that comes back from the back-forward cache is alive again. */
30
+ private readonly onPageShow;
31
+ }
@@ -1,4 +1,4 @@
1
- import type { Capture, CaptureContext } from "./types";
1
+ import type { Capture, CaptureContext } from "./types.js";
2
2
  /** Reports the previous page's unclean exit, and maintains this page's marker. */
3
3
  export declare class UncleanExitCapture implements Capture {
4
4
  private readonly ctx;
@@ -0,0 +1,22 @@
1
+ import { type Capture, type CaptureContext } from "./types.cjs";
2
+ /** Observes the app's marks and measures. */
3
+ export declare class UserTimingCapture implements Capture {
4
+ private readonly ctx;
5
+ /** Capture module identifier. */
6
+ readonly name = "userTiming";
7
+ /** Observer for the mark and measure entries. */
8
+ private observer;
9
+ /**
10
+ * @param ctx Capture context with the config, the meter and the breadcrumbs.
11
+ */
12
+ constructor(ctx: CaptureContext);
13
+ /** Observes marks and measures. Only the first install in a document reads buffered entries. */
14
+ install(): void;
15
+ /** Disconnects the observer. */
16
+ uninstall(): void;
17
+ /**
18
+ * Records the entries whose name `userTiming.include` selects.
19
+ * @param entries Mark and measure entries.
20
+ */
21
+ private record;
22
+ }
@@ -1,4 +1,4 @@
1
- import { type Capture, type CaptureContext } from "./types";
1
+ import { type Capture, type CaptureContext } from "./types.js";
2
2
  /** Observes the app's marks and measures. */
3
3
  export declare class UserTimingCapture implements Capture {
4
4
  private readonly ctx;
@@ -15,7 +15,7 @@ export declare class UserTimingCapture implements Capture {
15
15
  /** Disconnects the observer. */
16
16
  uninstall(): void;
17
17
  /**
18
- * Records the entries whose name `userTimingInclude` selects.
18
+ * Records the entries whose name `userTiming.include` selects.
19
19
  * @param entries Mark and measure entries.
20
20
  */
21
21
  private record;
@@ -0,0 +1,40 @@
1
+ import type { Diagnostics } from "../core/diagnostics.cjs";
2
+ import type { ResolvedConfig } from "../models/config.cjs";
3
+ import type { CapturePlugin, PluginContext } from "../models/plugin.cjs";
4
+ /** Records the lifecycle and message counts of every WebSocket the app opens. */
5
+ export declare class WebSocketCapture implements CapturePlugin {
6
+ private readonly diagnostics;
7
+ private readonly config;
8
+ /** Capture module identifier. */
9
+ readonly name = "websocket";
10
+ /** Restores the WebSocket constructor. Undefined while the capture isn't installed. */
11
+ private restore;
12
+ /** State of the active install. */
13
+ private state;
14
+ /** Rate limit for the lifecycle records, so a reconnect loop can't flood the pipeline. */
15
+ private readonly window;
16
+ /**
17
+ * @param diagnostics Diagnostics reporter.
18
+ * @param config Active configuration. The capture reads `capture.ignoreUrls`.
19
+ */
20
+ constructor(diagnostics: Diagnostics, config: ResolvedConfig);
21
+ /**
22
+ * Replaces the WebSocket constructor with a subclass that tracks every socket.
23
+ * @param ctx The plugin's tools.
24
+ */
25
+ install(ctx: PluginContext): void;
26
+ /** Restores the WebSocket constructor and stops every tracked socket from recording. */
27
+ uninstall(): void;
28
+ /**
29
+ * Adds the listeners that record one socket's lifecycle and received messages.
30
+ * @param socket The app's new socket.
31
+ * @param state State of the install that created the socket.
32
+ */
33
+ private track;
34
+ /**
35
+ * Checks whether a lifecycle record can go out.
36
+ * @param state State of the install that created the socket.
37
+ * @returns False after uninstall, or when the window has no allowance left.
38
+ */
39
+ private allow;
40
+ }
@@ -1,6 +1,6 @@
1
- import type { Diagnostics } from "../core/diagnostics";
2
- import type { ResolvedConfig } from "../models/config";
3
- import type { CapturePlugin, PluginContext } from "../models/plugin";
1
+ import type { Diagnostics } from "../core/diagnostics.js";
2
+ import type { ResolvedConfig } from "../models/config.js";
3
+ import type { CapturePlugin, PluginContext } from "../models/plugin.js";
4
4
  /** Records the lifecycle and message counts of every WebSocket the app opens. */
5
5
  export declare class WebSocketCapture implements CapturePlugin {
6
6
  private readonly diagnostics;
@@ -0,0 +1,40 @@
1
+ import type { Capture, CaptureContext } from "./types.cjs";
2
+ /** Captures browser navigation timing and Core Web Vitals. */
3
+ export declare class WebVitalsCapture implements Capture {
4
+ private readonly ctx;
5
+ /** Capture module identifier. */
6
+ readonly name = "web-vitals";
7
+ /** Prevents duplicate listener registration. */
8
+ private installed;
9
+ /** Navigation metrics already logged, so the early and the late read never repeat one. */
10
+ private readonly logged;
11
+ /**
12
+ * @param ctx Capture context: configuration, diagnostics and logger.
13
+ */
14
+ constructor(ctx: CaptureContext);
15
+ /** Reports navigation timing and starts loading web-vitals. */
16
+ install(): void;
17
+ /**
18
+ * Marks the module as uninstalled. The web-vitals reporters stay subscribed
19
+ * because the package has no unsubscribe, and `ctx.once` prevents a second set.
20
+ */
21
+ uninstall(): void;
22
+ /**
23
+ * Loads the web-vitals module and registers the metric reporters.
24
+ * @param loader The loader the consumer supplies.
25
+ */
26
+ private loadWebVitals;
27
+ /** Logs the navigation timing metrics, once per document and only after the load event. */
28
+ private reportNavigationTiming;
29
+ /**
30
+ * Runs one step of the navigation timing read. The browser calls the late steps directly,
31
+ * so anything they throw would be an uncaught error on the page.
32
+ * @param step The step to run.
33
+ */
34
+ private guardNavigation;
35
+ /**
36
+ * Logs every navigation metric that is ready and hasn't been logged yet.
37
+ * @param nav The document's navigation entry.
38
+ */
39
+ private logNavigation;
40
+ }
@@ -1,4 +1,4 @@
1
- import type { Capture, CaptureContext } from "./types";
1
+ import type { Capture, CaptureContext } from "./types.js";
2
2
  /** Captures browser navigation timing and Core Web Vitals. */
3
3
  export declare class WebVitalsCapture implements Capture {
4
4
  private readonly ctx;
@@ -1,2 +1,2 @@
1
- const e=require("./constants-DakMxVB2.cjs");async function t(t){let n=globalThis.CompressionStream;if(n===void 0)return null;let r=new Blob([t]).stream().pipeThrough(new n(e.tt)),i=await new Response(r).arrayBuffer();return new Uint8Array(i)}Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return t}});
2
- //# sourceMappingURL=compression-lD9abCcO.cjs.map
1
+ const e=require("./constants-CtF52hIV.cjs");async function t(t){let n=globalThis.CompressionStream;if(n===void 0)return null;let r=new Blob([t]).stream().pipeThrough(new n(e.nt)),i=await new Response(r).arrayBuffer();return new Uint8Array(i)}Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return t}});
2
+ //# sourceMappingURL=compression-C0hUHKR-.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"compression-lD9abCcO.cjs","names":["ENCODING_GZIP","require_constants","gzip","CS","stream","text","buffer"],"sources":["../src/transport/compression.ts"],"sourcesContent":["// src/transport/compression.ts\n//\n// Compresses payloads with the native CompressionStream API. Returns null when the API is\n// absent, never the raw text, because the server answers a non-gzip body that carries a\n// \"Content-Encoding: gzip\" header with a 400 status.\n\nimport { ENCODING_GZIP } from \"../constants\";\n\n/**\n * Compresses a string to gzip bytes with CompressionStream. The result is a\n * Uint8Array on a non-shared ArrayBuffer, which fetch accepts as BodyInit.\n * @param text Raw serialized payload to compress.\n * @returns Promise that resolves to the gzip bytes, or null when there is no CompressionStream.\n */\nexport async function gzip(text: string): Promise<Uint8Array<ArrayBuffer> | null> {\n const CS = (globalThis as { CompressionStream?: typeof CompressionStream }).CompressionStream;\n if (CS === undefined) {\n return null;\n }\n\n const stream = new Blob([text]).stream().pipeThrough(new CS(ENCODING_GZIP));\n const buffer = await new Response(stream).arrayBuffer();\n\n return new Uint8Array(buffer);\n}\n"],"mappings":"A,4CAcA,eAAsBE,EAAK,EAAuD,CAChF,IAAMC,EAAM,WAAgE,kBAC5E,GAAIA,IAAO,IAAA,GACT,OAAO,KAGT,IAAMC,EAAS,IAAI,KAAK,CAACC,CAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,YAAY,IAAIF,EAAGH,EAAAA,EAAa,CAAC,EACpEM,EAAS,MAAM,IAAI,SAASF,CAAM,CAAC,CAAC,YAAY,EAEtD,OAAO,IAAI,WAAWE,CAAM,CAC9B,C"}
1
+ {"version":3,"file":"compression-C0hUHKR-.cjs","names":["ENCODING_GZIP","require_constants","gzip","CS","stream","text","buffer"],"sources":["../src/transport/compression.ts"],"sourcesContent":["// src/transport/compression.ts\n//\n// Compresses payloads with the native CompressionStream API. Returns null when the API is\n// absent, never the raw text, because the server answers a non-gzip body that carries a\n// \"Content-Encoding: gzip\" header with a 400 status.\n\nimport { ENCODING_GZIP } from \"../constants\";\n\n/**\n * Compresses a string to gzip bytes with CompressionStream. The result is a\n * Uint8Array on a non-shared ArrayBuffer, which fetch accepts as BodyInit.\n * @param text Raw serialized payload to compress.\n * @returns Promise that resolves to the gzip bytes, or null when there is no CompressionStream.\n */\nexport async function gzip(text: string): Promise<Uint8Array<ArrayBuffer> | null> {\n const CS = (globalThis as { CompressionStream?: typeof CompressionStream }).CompressionStream;\n if (CS === undefined) {\n return null;\n }\n\n const stream = new Blob([text]).stream().pipeThrough(new CS(ENCODING_GZIP));\n const buffer = await new Response(stream).arrayBuffer();\n\n return new Uint8Array(buffer);\n}\n"],"mappings":"A,4CAcA,eAAsBE,EAAK,EAAuD,CAChF,IAAMC,EAAM,WAAgE,kBAC5E,GAAIA,IAAO,IAAA,GACT,OAAO,KAGT,IAAMC,EAAS,IAAI,KAAK,CAACC,CAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,YAAY,IAAIF,EAAGH,EAAAA,EAAa,CAAC,EACpEM,EAAS,MAAM,IAAI,SAASF,CAAM,CAAC,CAAC,YAAY,EAEtD,OAAO,IAAI,WAAWE,CAAM,CAC9B,C"}
@@ -1,4 +1,4 @@
1
- import { tt as e } from "./constants-Bwl_YtQi.js";
1
+ import { nt as e } from "./constants-BwJDXzj6.js";
2
2
  // src/transport/compression.ts
3
3
  async function t(t) {
4
4
  let n = globalThis.CompressionStream;
@@ -8,4 +8,4 @@ async function t(t) {
8
8
  }
9
9
  export { t };
10
10
 
11
- //# sourceMappingURL=compression-AJJCMBOa.js.map
11
+ //# sourceMappingURL=compression-SHPAvS4U.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"compression-AJJCMBOa.js","names":["ENCODING_GZIP","gzip","CS","stream","text","buffer"],"sources":["../src/transport/compression.ts"],"sourcesContent":["// src/transport/compression.ts\n//\n// Compresses payloads with the native CompressionStream API. Returns null when the API is\n// absent, never the raw text, because the server answers a non-gzip body that carries a\n// \"Content-Encoding: gzip\" header with a 400 status.\n\nimport { ENCODING_GZIP } from \"../constants\";\n\n/**\n * Compresses a string to gzip bytes with CompressionStream. The result is a\n * Uint8Array on a non-shared ArrayBuffer, which fetch accepts as BodyInit.\n * @param text Raw serialized payload to compress.\n * @returns Promise that resolves to the gzip bytes, or null when there is no CompressionStream.\n */\nexport async function gzip(text: string): Promise<Uint8Array<ArrayBuffer> | null> {\n const CS = (globalThis as { CompressionStream?: typeof CompressionStream }).CompressionStream;\n if (CS === undefined) {\n return null;\n }\n\n const stream = new Blob([text]).stream().pipeThrough(new CS(ENCODING_GZIP));\n const buffer = await new Response(stream).arrayBuffer();\n\n return new Uint8Array(buffer);\n}\n"],"mappings":";;AAcA,eAAsBC,EAAK,GAAuD;CAChF,IAAMC,IAAM,WAAgE;CAC5E,IAAIA,MAAO,KAAA,GACT,OAAO;CAGT,IAAMC,IAAS,IAAI,KAAK,CAACC,CAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,YAAY,IAAIF,EAAGF,CAAa,CAAC,GACpEK,IAAS,MAAM,IAAI,SAASF,CAAM,CAAC,CAAC,YAAY;CAEtD,OAAO,IAAI,WAAWE,CAAM;AAC9B"}
1
+ {"version":3,"file":"compression-SHPAvS4U.js","names":["ENCODING_GZIP","gzip","CS","stream","text","buffer"],"sources":["../src/transport/compression.ts"],"sourcesContent":["// src/transport/compression.ts\n//\n// Compresses payloads with the native CompressionStream API. Returns null when the API is\n// absent, never the raw text, because the server answers a non-gzip body that carries a\n// \"Content-Encoding: gzip\" header with a 400 status.\n\nimport { ENCODING_GZIP } from \"../constants\";\n\n/**\n * Compresses a string to gzip bytes with CompressionStream. The result is a\n * Uint8Array on a non-shared ArrayBuffer, which fetch accepts as BodyInit.\n * @param text Raw serialized payload to compress.\n * @returns Promise that resolves to the gzip bytes, or null when there is no CompressionStream.\n */\nexport async function gzip(text: string): Promise<Uint8Array<ArrayBuffer> | null> {\n const CS = (globalThis as { CompressionStream?: typeof CompressionStream }).CompressionStream;\n if (CS === undefined) {\n return null;\n }\n\n const stream = new Blob([text]).stream().pipeThrough(new CS(ENCODING_GZIP));\n const buffer = await new Response(stream).arrayBuffer();\n\n return new Uint8Array(buffer);\n}\n"],"mappings":";;AAcA,eAAsBC,EAAK,GAAuD;CAChF,IAAMC,IAAM,WAAgE;CAC5E,IAAIA,MAAO,KAAA,GACT,OAAO;CAGT,IAAMC,IAAS,IAAI,KAAK,CAACC,CAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,YAAY,IAAIF,EAAGF,CAAa,CAAC,GACpEK,IAAS,MAAM,IAAI,SAASF,CAAM,CAAC,CAAC,YAAY;CAEtD,OAAO,IAAI,WAAWE,CAAM;AAC9B"}