@graphrefly/graphrefly 0.43.0 → 0.45.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 (422) hide show
  1. package/README.md +21 -17
  2. package/dist/compat/index.cjs +20 -10
  3. package/dist/compat/index.cjs.map +1 -0
  4. package/dist/compat/index.d.cts +1 -22
  5. package/dist/compat/index.d.ts +1 -22
  6. package/dist/compat/index.js +3 -1
  7. package/dist/compat/index.js.map +1 -0
  8. package/dist/compat/jotai/index.cjs +21 -1
  9. package/dist/compat/jotai/index.cjs.map +1 -0
  10. package/dist/compat/jotai/index.d.cts +1 -2
  11. package/dist/compat/jotai/index.d.ts +1 -2
  12. package/dist/compat/jotai/index.js +3 -1
  13. package/dist/compat/jotai/index.js.map +1 -0
  14. package/dist/compat/nanostores/index.cjs +21 -1
  15. package/dist/compat/nanostores/index.cjs.map +1 -0
  16. package/dist/compat/nanostores/index.d.cts +1 -2
  17. package/dist/compat/nanostores/index.d.ts +1 -2
  18. package/dist/compat/nanostores/index.js +3 -1
  19. package/dist/compat/nanostores/index.js.map +1 -0
  20. package/dist/compat/nestjs/index.cjs +20 -10
  21. package/dist/compat/nestjs/index.cjs.map +1 -0
  22. package/dist/compat/nestjs/index.d.cts +1 -13
  23. package/dist/compat/nestjs/index.d.ts +1 -13
  24. package/dist/compat/nestjs/index.js +3 -1
  25. package/dist/compat/nestjs/index.js.map +1 -0
  26. package/dist/compat/react/index.cjs +21 -1
  27. package/dist/compat/react/index.cjs.map +1 -0
  28. package/dist/compat/react/index.d.cts +1 -2
  29. package/dist/compat/react/index.d.ts +1 -2
  30. package/dist/compat/react/index.js +3 -1
  31. package/dist/compat/react/index.js.map +1 -0
  32. package/dist/compat/solid/index.cjs +21 -1
  33. package/dist/compat/solid/index.cjs.map +1 -0
  34. package/dist/compat/solid/index.d.cts +1 -2
  35. package/dist/compat/solid/index.d.ts +1 -2
  36. package/dist/compat/solid/index.js +3 -1
  37. package/dist/compat/solid/index.js.map +1 -0
  38. package/dist/compat/svelte/index.cjs +21 -1
  39. package/dist/compat/svelte/index.cjs.map +1 -0
  40. package/dist/compat/svelte/index.d.cts +1 -2
  41. package/dist/compat/svelte/index.d.ts +1 -2
  42. package/dist/compat/svelte/index.js +3 -1
  43. package/dist/compat/svelte/index.js.map +1 -0
  44. package/dist/compat/vue/index.cjs +21 -1
  45. package/dist/compat/vue/index.cjs.map +1 -0
  46. package/dist/compat/vue/index.d.cts +1 -3
  47. package/dist/compat/vue/index.d.ts +1 -3
  48. package/dist/compat/vue/index.js +3 -1
  49. package/dist/compat/vue/index.js.map +1 -0
  50. package/dist/compat/zustand/index.cjs +21 -3
  51. package/dist/compat/zustand/index.cjs.map +1 -0
  52. package/dist/compat/zustand/index.d.cts +1 -6
  53. package/dist/compat/zustand/index.d.ts +1 -6
  54. package/dist/compat/zustand/index.js +3 -1
  55. package/dist/compat/zustand/index.js.map +1 -0
  56. package/dist/core/index.cjs +21 -1
  57. package/dist/core/index.cjs.map +1 -0
  58. package/dist/core/index.d.cts +1 -4
  59. package/dist/core/index.d.ts +1 -4
  60. package/dist/core/index.js +3 -1
  61. package/dist/core/index.js.map +1 -0
  62. package/dist/extra/browser.cjs +21 -1
  63. package/dist/extra/browser.cjs.map +1 -0
  64. package/dist/extra/browser.d.cts +1 -4
  65. package/dist/extra/browser.d.ts +1 -4
  66. package/dist/extra/browser.js +3 -1
  67. package/dist/extra/browser.js.map +1 -0
  68. package/dist/extra/index.cjs +20 -19
  69. package/dist/extra/index.cjs.map +1 -0
  70. package/dist/extra/index.d.cts +1 -17
  71. package/dist/extra/index.d.ts +1 -17
  72. package/dist/extra/index.js +3 -1
  73. package/dist/extra/index.js.map +1 -0
  74. package/dist/extra/node.cjs +21 -2
  75. package/dist/extra/node.cjs.map +1 -0
  76. package/dist/extra/node.d.cts +1 -187
  77. package/dist/extra/node.d.ts +1 -187
  78. package/dist/extra/node.js +3 -2
  79. package/dist/extra/node.js.map +1 -0
  80. package/dist/extra/operators.cjs +21 -1
  81. package/dist/extra/operators.cjs.map +1 -0
  82. package/dist/extra/operators.d.cts +1 -950
  83. package/dist/extra/operators.d.ts +1 -950
  84. package/dist/extra/operators.js +3 -1
  85. package/dist/extra/operators.js.map +1 -0
  86. package/dist/extra/reactive.cjs +21 -1
  87. package/dist/extra/reactive.cjs.map +1 -0
  88. package/dist/extra/reactive.d.cts +1 -353
  89. package/dist/extra/reactive.d.ts +1 -353
  90. package/dist/extra/reactive.js +3 -1
  91. package/dist/extra/reactive.js.map +1 -0
  92. package/dist/extra/render/index.cjs +21 -5
  93. package/dist/extra/render/index.cjs.map +1 -0
  94. package/dist/extra/render/index.d.cts +1 -183
  95. package/dist/extra/render/index.d.ts +1 -183
  96. package/dist/extra/render/index.js +3 -1
  97. package/dist/extra/render/index.js.map +1 -0
  98. package/dist/extra/sources.cjs +21 -3
  99. package/dist/extra/sources.cjs.map +1 -0
  100. package/dist/extra/sources.d.cts +1 -584
  101. package/dist/extra/sources.d.ts +1 -584
  102. package/dist/extra/sources.js +3 -1
  103. package/dist/extra/sources.js.map +1 -0
  104. package/dist/extra/storage-browser.cjs +21 -1
  105. package/dist/extra/storage-browser.cjs.map +1 -0
  106. package/dist/extra/storage-browser.d.cts +1 -37
  107. package/dist/extra/storage-browser.d.ts +1 -37
  108. package/dist/extra/storage-browser.js +3 -1
  109. package/dist/extra/storage-browser.js.map +1 -0
  110. package/dist/extra/storage-core.cjs +21 -1
  111. package/dist/extra/storage-core.cjs.map +1 -0
  112. package/dist/extra/storage-core.d.cts +1 -28
  113. package/dist/extra/storage-core.d.ts +1 -28
  114. package/dist/extra/storage-core.js +3 -1
  115. package/dist/extra/storage-core.js.map +1 -0
  116. package/dist/extra/storage-node.cjs +20 -0
  117. package/dist/extra/storage-node.cjs.map +1 -0
  118. package/dist/extra/storage-node.d.cts +1 -2
  119. package/dist/extra/storage-node.d.ts +1 -2
  120. package/dist/extra/storage-node.js +3 -0
  121. package/dist/extra/storage-node.js.map +1 -0
  122. package/dist/extra/storage-tiers-browser.cjs +21 -1
  123. package/dist/extra/storage-tiers-browser.cjs.map +1 -0
  124. package/dist/extra/storage-tiers-browser.d.cts +1 -120
  125. package/dist/extra/storage-tiers-browser.d.ts +1 -120
  126. package/dist/extra/storage-tiers-browser.js +3 -1
  127. package/dist/extra/storage-tiers-browser.js.map +1 -0
  128. package/dist/extra/storage-tiers-node.cjs +21 -1
  129. package/dist/extra/storage-tiers-node.cjs.map +1 -0
  130. package/dist/extra/storage-tiers-node.d.cts +1 -210
  131. package/dist/extra/storage-tiers-node.d.ts +1 -210
  132. package/dist/extra/storage-tiers-node.js +3 -1
  133. package/dist/extra/storage-tiers-node.js.map +1 -0
  134. package/dist/extra/storage-tiers.cjs +21 -1
  135. package/dist/extra/storage-tiers.cjs.map +1 -0
  136. package/dist/extra/storage-tiers.d.cts +1 -412
  137. package/dist/extra/storage-tiers.d.ts +1 -412
  138. package/dist/extra/storage-tiers.js +3 -1
  139. package/dist/extra/storage-tiers.js.map +1 -0
  140. package/dist/extra/storage-wal.cjs +21 -0
  141. package/dist/extra/storage-wal.cjs.map +1 -0
  142. package/dist/extra/storage-wal.d.cts +1 -0
  143. package/dist/extra/storage-wal.d.ts +1 -0
  144. package/dist/extra/storage-wal.js +3 -0
  145. package/dist/extra/storage-wal.js.map +1 -0
  146. package/dist/graph/index.cjs +21 -7
  147. package/dist/graph/index.cjs.map +1 -0
  148. package/dist/graph/index.d.cts +1 -7
  149. package/dist/graph/index.d.ts +1 -7
  150. package/dist/graph/index.js +3 -1
  151. package/dist/graph/index.js.map +1 -0
  152. package/dist/index.cjs +20 -227
  153. package/dist/index.cjs.map +1 -0
  154. package/dist/index.d.cts +45 -96
  155. package/dist/index.d.ts +45 -96
  156. package/dist/index.js +3 -1
  157. package/dist/index.js.map +1 -0
  158. package/dist/patterns/ai/browser.cjs +20 -7
  159. package/dist/patterns/ai/browser.cjs.map +1 -0
  160. package/dist/patterns/ai/browser.d.cts +1 -127
  161. package/dist/patterns/ai/browser.d.ts +1 -127
  162. package/dist/patterns/ai/browser.js +3 -3
  163. package/dist/patterns/ai/browser.js.map +1 -0
  164. package/dist/patterns/ai/index.cjs +20 -73
  165. package/dist/patterns/ai/index.cjs.map +1 -0
  166. package/dist/patterns/ai/index.d.cts +1 -21
  167. package/dist/patterns/ai/index.d.ts +1 -21
  168. package/dist/patterns/ai/index.js +3 -1
  169. package/dist/patterns/ai/index.js.map +1 -0
  170. package/dist/patterns/ai/node.cjs +21 -1
  171. package/dist/patterns/ai/node.cjs.map +1 -0
  172. package/dist/patterns/ai/node.d.cts +1 -59
  173. package/dist/patterns/ai/node.d.ts +1 -59
  174. package/dist/patterns/ai/node.js +3 -1
  175. package/dist/patterns/ai/node.js.map +1 -0
  176. package/dist/patterns/cqrs/index.cjs +21 -3
  177. package/dist/patterns/cqrs/index.cjs.map +1 -0
  178. package/dist/patterns/cqrs/index.d.cts +1 -8
  179. package/dist/patterns/cqrs/index.d.ts +1 -8
  180. package/dist/patterns/cqrs/index.js +3 -1
  181. package/dist/patterns/cqrs/index.js.map +1 -0
  182. package/dist/patterns/demo-shell/index.cjs +21 -5
  183. package/dist/patterns/demo-shell/index.cjs.map +1 -0
  184. package/dist/patterns/demo-shell/index.d.cts +1 -7
  185. package/dist/patterns/demo-shell/index.d.ts +1 -7
  186. package/dist/patterns/demo-shell/index.js +3 -1
  187. package/dist/patterns/demo-shell/index.js.map +1 -0
  188. package/dist/patterns/domain-templates/index.cjs +21 -3
  189. package/dist/patterns/domain-templates/index.cjs.map +1 -0
  190. package/dist/patterns/domain-templates/index.d.cts +1 -6
  191. package/dist/patterns/domain-templates/index.d.ts +1 -6
  192. package/dist/patterns/domain-templates/index.js +3 -1
  193. package/dist/patterns/domain-templates/index.js.map +1 -0
  194. package/dist/patterns/graphspec/index.cjs +21 -86
  195. package/dist/patterns/graphspec/index.cjs.map +1 -0
  196. package/dist/patterns/graphspec/index.d.cts +1 -8
  197. package/dist/patterns/graphspec/index.d.ts +1 -8
  198. package/dist/patterns/graphspec/index.js +3 -1
  199. package/dist/patterns/graphspec/index.js.map +1 -0
  200. package/dist/patterns/harness/index.cjs +21 -48
  201. package/dist/patterns/harness/index.cjs.map +1 -0
  202. package/dist/patterns/harness/index.d.cts +1 -14
  203. package/dist/patterns/harness/index.d.ts +1 -14
  204. package/dist/patterns/harness/index.js +3 -1
  205. package/dist/patterns/harness/index.js.map +1 -0
  206. package/dist/patterns/inspect/index.cjs +21 -3
  207. package/dist/patterns/inspect/index.cjs.map +1 -0
  208. package/dist/patterns/inspect/index.d.cts +1 -9
  209. package/dist/patterns/inspect/index.d.ts +1 -9
  210. package/dist/patterns/inspect/index.js +3 -1
  211. package/dist/patterns/inspect/index.js.map +1 -0
  212. package/dist/patterns/job-queue/index.cjs +21 -3
  213. package/dist/patterns/job-queue/index.cjs.map +1 -0
  214. package/dist/patterns/job-queue/index.d.cts +1 -9
  215. package/dist/patterns/job-queue/index.d.ts +1 -9
  216. package/dist/patterns/job-queue/index.js +3 -1
  217. package/dist/patterns/job-queue/index.js.map +1 -0
  218. package/dist/patterns/memory/index.cjs +21 -3
  219. package/dist/patterns/memory/index.cjs.map +1 -0
  220. package/dist/patterns/memory/index.d.cts +1 -8
  221. package/dist/patterns/memory/index.d.ts +1 -8
  222. package/dist/patterns/memory/index.js +3 -1
  223. package/dist/patterns/memory/index.js.map +1 -0
  224. package/dist/patterns/messaging/index.cjs +21 -3
  225. package/dist/patterns/messaging/index.cjs.map +1 -0
  226. package/dist/patterns/messaging/index.d.cts +1 -7
  227. package/dist/patterns/messaging/index.d.ts +1 -7
  228. package/dist/patterns/messaging/index.js +3 -1
  229. package/dist/patterns/messaging/index.js.map +1 -0
  230. package/dist/patterns/orchestration/index.cjs +21 -3
  231. package/dist/patterns/orchestration/index.cjs.map +1 -0
  232. package/dist/patterns/orchestration/index.d.cts +1 -9
  233. package/dist/patterns/orchestration/index.d.ts +1 -9
  234. package/dist/patterns/orchestration/index.js +3 -1
  235. package/dist/patterns/orchestration/index.js.map +1 -0
  236. package/dist/patterns/process/index.cjs +21 -1
  237. package/dist/patterns/process/index.cjs.map +1 -0
  238. package/dist/patterns/process/index.d.cts +1 -10
  239. package/dist/patterns/process/index.d.ts +1 -10
  240. package/dist/patterns/process/index.js +3 -1
  241. package/dist/patterns/process/index.js.map +1 -0
  242. package/dist/patterns/reactive-layout/index.cjs +21 -4
  243. package/dist/patterns/reactive-layout/index.cjs.map +1 -0
  244. package/dist/patterns/reactive-layout/index.d.cts +1 -7
  245. package/dist/patterns/reactive-layout/index.d.ts +1 -7
  246. package/dist/patterns/reactive-layout/index.js +3 -1
  247. package/dist/patterns/reactive-layout/index.js.map +1 -0
  248. package/dist/patterns/reduction/index.cjs +21 -3
  249. package/dist/patterns/reduction/index.cjs.map +1 -0
  250. package/dist/patterns/reduction/index.d.cts +1 -6
  251. package/dist/patterns/reduction/index.d.ts +1 -6
  252. package/dist/patterns/reduction/index.js +3 -1
  253. package/dist/patterns/reduction/index.js.map +1 -0
  254. package/dist/patterns/surface/index.cjs +21 -13
  255. package/dist/patterns/surface/index.cjs.map +1 -0
  256. package/dist/patterns/surface/index.d.cts +1 -9
  257. package/dist/patterns/surface/index.d.ts +1 -9
  258. package/dist/patterns/surface/index.js +3 -1
  259. package/dist/patterns/surface/index.js.map +1 -0
  260. package/dist/patterns/topology-view/index.cjs +21 -0
  261. package/dist/patterns/topology-view/index.cjs.map +1 -0
  262. package/dist/patterns/topology-view/index.d.cts +1 -0
  263. package/dist/patterns/topology-view/index.d.ts +1 -0
  264. package/dist/patterns/topology-view/index.js +3 -0
  265. package/dist/patterns/topology-view/index.js.map +1 -0
  266. package/dist/testing/index.cjs +21 -0
  267. package/dist/testing/index.cjs.map +1 -0
  268. package/dist/testing/index.d.cts +1 -0
  269. package/dist/testing/index.d.ts +1 -0
  270. package/dist/testing/index.js +3 -0
  271. package/dist/testing/index.js.map +1 -0
  272. package/package.json +608 -584
  273. package/dist/backoff-HPZMEZNF.js +0 -1
  274. package/dist/cascading-CH-_VwG9.d.cts +0 -199
  275. package/dist/cascading-OgKQZjsa.d.ts +0 -199
  276. package/dist/chunk-35JTVPOX.js +0 -1
  277. package/dist/chunk-3G5U5QNE.js +0 -5
  278. package/dist/chunk-3XDYJRYU.js +0 -1
  279. package/dist/chunk-4I45FVQS.js +0 -1
  280. package/dist/chunk-4VVTGLXJ.js +0 -1
  281. package/dist/chunk-4YAN45KM.js +0 -1
  282. package/dist/chunk-5QDBSZBV.js +0 -1
  283. package/dist/chunk-626TESAC.js +0 -3
  284. package/dist/chunk-6HOSXQKF.js +0 -1
  285. package/dist/chunk-6QZNQS5B.js +0 -1
  286. package/dist/chunk-C72GO4IZ.js +0 -1
  287. package/dist/chunk-CE72X3WO.js +0 -1
  288. package/dist/chunk-CK2E7BTU.js +0 -1
  289. package/dist/chunk-CLD3F4R5.js +0 -1
  290. package/dist/chunk-CUNIRONA.js +0 -1
  291. package/dist/chunk-D27JNOLZ.js +0 -1
  292. package/dist/chunk-D5RFJOZ2.js +0 -1
  293. package/dist/chunk-EBW4V6JN.js +0 -1
  294. package/dist/chunk-ESMPEKEV.js +0 -1
  295. package/dist/chunk-F3IGTWCQ.js +0 -1
  296. package/dist/chunk-F672GV32.js +0 -1
  297. package/dist/chunk-FDQGFWLF.js +0 -1
  298. package/dist/chunk-FG4TKHMC.js +0 -1
  299. package/dist/chunk-GPW2V3RE.js +0 -1
  300. package/dist/chunk-I7IGYPSL.js +0 -1
  301. package/dist/chunk-INQD2KRQ.js +0 -1
  302. package/dist/chunk-JNWRYDJN.js +0 -1
  303. package/dist/chunk-JQFH2DV6.js +0 -1
  304. package/dist/chunk-K2Q24F5T.js +0 -1
  305. package/dist/chunk-KGKJCHEK.js +0 -1
  306. package/dist/chunk-KRH66M4O.js +0 -1
  307. package/dist/chunk-KVV66NN2.js +0 -1
  308. package/dist/chunk-L6NSJVJZ.js +0 -1
  309. package/dist/chunk-LYCLF26R.js +0 -1
  310. package/dist/chunk-NNKJUORL.js +0 -1
  311. package/dist/chunk-NON4NLIC.js +0 -45
  312. package/dist/chunk-O2BLLH7M.js +0 -18
  313. package/dist/chunk-OCKEEPRJ.js +0 -2
  314. package/dist/chunk-OFZG3TB3.js +0 -9
  315. package/dist/chunk-OYJKFY7V.js +0 -1
  316. package/dist/chunk-P6C4WHZO.js +0 -5
  317. package/dist/chunk-PT7W5FCD.js +0 -5
  318. package/dist/chunk-Q4U3A3L5.js +0 -1
  319. package/dist/chunk-QE4IGY7I.js +0 -61
  320. package/dist/chunk-QYADASLV.js +0 -1
  321. package/dist/chunk-QYVXF7GW.js +0 -1
  322. package/dist/chunk-S3EEIPO7.js +0 -1
  323. package/dist/chunk-SUWT3ZON.js +0 -1
  324. package/dist/chunk-TPKQW72B.js +0 -1
  325. package/dist/chunk-TSOYJ743.js +0 -1
  326. package/dist/chunk-TZQPPQEQ.js +0 -1
  327. package/dist/chunk-V5A7M7RJ.js +0 -1
  328. package/dist/chunk-VIMF6LGM.js +0 -1
  329. package/dist/chunk-VJLMUKOI.js +0 -1
  330. package/dist/chunk-VN6RDSK2.js +0 -1
  331. package/dist/chunk-VNC3TMVY.js +0 -1
  332. package/dist/chunk-VOPGGIL7.js +0 -1
  333. package/dist/chunk-VQ4A6T2A.js +0 -1
  334. package/dist/chunk-XG62INFA.js +0 -1
  335. package/dist/chunk-Y4NI3X7O.js +0 -84
  336. package/dist/content-addressed-storage-4-ST1tYk.d.cts +0 -124
  337. package/dist/content-addressed-storage-DuYMjV7o.d.ts +0 -124
  338. package/dist/decay-2ZukgQ4o.d.cts +0 -112
  339. package/dist/decay-CdEBmDIs.d.ts +0 -112
  340. package/dist/fallback-CqYVLL6X.d.ts +0 -250
  341. package/dist/fallback-Ctlj2tMY.d.cts +0 -250
  342. package/dist/graph-7VguS7a4.d.ts +0 -1668
  343. package/dist/graph-C4SHb3Ly.d.cts +0 -1668
  344. package/dist/index-0rKFCVFp.d.cts +0 -557
  345. package/dist/index-B-i4_g3k.d.ts +0 -651
  346. package/dist/index-B5iz82A3.d.cts +0 -2655
  347. package/dist/index-BAOD98JD.d.cts +0 -754
  348. package/dist/index-BG0BN3PB.d.ts +0 -44
  349. package/dist/index-BJX94aud.d.cts +0 -34
  350. package/dist/index-BP8a88zx.d.ts +0 -385
  351. package/dist/index-BTQtTb_H.d.cts +0 -301
  352. package/dist/index-BVpm6noz.d.cts +0 -36
  353. package/dist/index-Bc41FuHp.d.cts +0 -291
  354. package/dist/index-BdGtBX-X.d.cts +0 -515
  355. package/dist/index-Bf7eqeSF.d.ts +0 -113
  356. package/dist/index-BiX1Nkgx.d.cts +0 -1844
  357. package/dist/index-BoLv_OfD.d.cts +0 -651
  358. package/dist/index-BojK2fwH.d.cts +0 -299
  359. package/dist/index-BsT7F2et.d.ts +0 -291
  360. package/dist/index-BwLvVVsy.d.cts +0 -189
  361. package/dist/index-C59mYFKp.d.ts +0 -121
  362. package/dist/index-C7O6r5fV.d.ts +0 -37
  363. package/dist/index-C9kSENB4.d.cts +0 -127
  364. package/dist/index-C9pjcz3l.d.cts +0 -209
  365. package/dist/index-CAC_rNzm.d.ts +0 -189
  366. package/dist/index-CCq87F7t.d.ts +0 -127
  367. package/dist/index-CDXc9zKM.d.cts +0 -26
  368. package/dist/index-CJK1JkYy.d.ts +0 -36
  369. package/dist/index-CLon-IWF.d.cts +0 -374
  370. package/dist/index-COD1kVoS.d.cts +0 -468
  371. package/dist/index-CPT7C_f1.d.ts +0 -374
  372. package/dist/index-CQG3D1cp.d.ts +0 -468
  373. package/dist/index-CZQXo5tH.d.ts +0 -209
  374. package/dist/index-CZjOhcBy.d.cts +0 -113
  375. package/dist/index-ChOyVLKm.d.cts +0 -86
  376. package/dist/index-CvrqGfNS.d.ts +0 -34
  377. package/dist/index-D-AEQVLo.d.ts +0 -2655
  378. package/dist/index-D4Y1cMG0.d.ts +0 -26
  379. package/dist/index-DBHK8O6H.d.ts +0 -301
  380. package/dist/index-DBevwHj_.d.ts +0 -515
  381. package/dist/index-DIOoAZUX.d.ts +0 -45
  382. package/dist/index-DSZ3ZCHF.d.ts +0 -3402
  383. package/dist/index-Dgs8zcj7.d.ts +0 -102
  384. package/dist/index-Dh_HJ82K.d.ts +0 -299
  385. package/dist/index-Dhc7a7Xo.d.cts +0 -102
  386. package/dist/index-Dmqp7KjD.d.ts +0 -86
  387. package/dist/index-Dn-wI9g4.d.ts +0 -231
  388. package/dist/index-Du7u1lSf.d.cts +0 -385
  389. package/dist/index-DwigL4lY.d.ts +0 -1844
  390. package/dist/index-DyR7eU5S.d.cts +0 -779
  391. package/dist/index-JZUPJIJy.d.ts +0 -779
  392. package/dist/index-K0_0eR8g.d.ts +0 -557
  393. package/dist/index-O16yXPK4.d.cts +0 -3402
  394. package/dist/index-O7fucFrU.d.cts +0 -121
  395. package/dist/index-RV_yDjOX.d.cts +0 -198
  396. package/dist/index-cm1GNcWE.d.ts +0 -754
  397. package/dist/index-f5IivDUX.d.cts +0 -37
  398. package/dist/index-hHcaFlJX.d.cts +0 -45
  399. package/dist/index-tJoTcnHh.d.cts +0 -231
  400. package/dist/index-wAzD9yVj.d.ts +0 -198
  401. package/dist/index-z96luz5O.d.cts +0 -44
  402. package/dist/meta-BgVAsg9j.d.ts +0 -102
  403. package/dist/meta-vE8bxW1E.d.cts +0 -102
  404. package/dist/node-ClS5yC-B.d.cts +0 -1347
  405. package/dist/node-ClS5yC-B.d.ts +0 -1347
  406. package/dist/observable-BsBzUrcI.d.ts +0 -36
  407. package/dist/observable-DLGPPtb8.d.cts +0 -36
  408. package/dist/pipeline-graph-DPqKDk59.d.cts +0 -137
  409. package/dist/pipeline-graph-loP57TBA.d.ts +0 -137
  410. package/dist/reactive-layout-Dsvob4zD.d.cts +0 -183
  411. package/dist/reactive-layout-v7KPvxoc.d.ts +0 -183
  412. package/dist/reactive-log-B00laMSQ.d.cts +0 -223
  413. package/dist/reactive-log-BezYsbA_.d.ts +0 -223
  414. package/dist/reactive-map-48mnZ-nu.d.cts +0 -296
  415. package/dist/reactive-map-BVVPdvmi.d.ts +0 -296
  416. package/dist/resilience-YIWPK4YC.js +0 -1
  417. package/dist/sugar-DLwvMr3F.d.ts +0 -223
  418. package/dist/sugar-DyVGtczU.d.cts +0 -223
  419. package/dist/topology-tree-BNGvuG82.d.ts +0 -25
  420. package/dist/topology-tree-BSdfSwMi.d.cts +0 -25
  421. package/dist/types-B1jDWVsM.d.cts +0 -442
  422. package/dist/types-DkzUUs0H.d.ts +0 -442
@@ -1,183 +1 @@
1
- import { b as GraphDescribeOutput } from '../../graph-7VguS7a4.js';
2
- import '../../node-ClS5yC-B.js';
3
- import '../../meta-BgVAsg9j.js';
4
- import '../storage-core.js';
5
- import '../storage-tiers.js';
6
-
7
- /**
8
- * Internal helpers shared across renderers in `extra/render/`.
9
- *
10
- * These are pure functions over `GraphDescribeOutput` — no Graph instance
11
- * dependency. Extracted from `src/graph/graph.ts` (the consolidated
12
- * ex-dumpGraph / ex-toMermaid / ex-toD2 renderers) per Tier 2.1 A2.
13
- */
14
-
15
- /** Direction options for diagram exports. */
16
- type DiagramDirection = "TD" | "LR" | "BT" | "RL";
17
-
18
- /**
19
- * Sugiyama-style layered DAG layout on an integer grid.
20
- *
21
- * Pipeline:
22
- * 1. Longest-path layer assignment (sources at layer 0).
23
- * 2. Virtual-node splitting — every edge spanning more than one layer
24
- * becomes a chain of synthetic nodes on intermediate layers. Downstream
25
- * passes treat real and virtual nodes identically; crossing
26
- * minimization therefore works on wide + deep DAGs, not only
27
- * adjacent-layer cases.
28
- * 3. Crossing minimization — barycenter heuristic with alternating up /
29
- * down sweeps plus an adjacent-transposition polish pass.
30
- * 4. Coordinate assignment — greedy median-aligned packing with collision
31
- * resolution. Straightens vertical runs of virtual nodes so long edges
32
- * become straight lines where topology allows.
33
- * 5. Orthogonal edge routing — per-gutter x-track assignment; horizontal
34
- * segments sit at endpoint centerlines, vertical segments pack into the
35
- * gutter column range without overlap. Remaining crossings are
36
- * topologically unavoidable and will render as `┼` at draw time.
37
- *
38
- * Output coordinates are cell-grid integers (LR direction). TD rendering
39
- * swaps axes at draw time — the layout is direction-agnostic by
40
- * construction.
41
- *
42
- * Used only by [to-ascii.ts](./to-ascii.ts); not part of the public
43
- * `extra/render/index.ts` surface (underscore-prefixed).
44
- */
45
- type LayoutDirection = "LR" | "TD";
46
-
47
- /**
48
- * `toAscii(g, opts?)` — stdout-native DAG flowchart renderer for a
49
- * {@link GraphDescribeOutput}.
50
- *
51
- * Zero external dependencies, graph-size independent via proper Sugiyama
52
- * (layer assignment → virtual-node splitting → barycenter crossing
53
- * minimization → median-aligned coordinate assignment → per-gutter
54
- * track-assigned orthogonal routing). See
55
- * [_layout-sugiyama.ts](./_layout-sugiyama.ts) for the layout pipeline and
56
- * [_ascii-grid.ts](./_ascii-grid.ts) for the character blitter.
57
- *
58
- * Pure function over the describe snapshot; no Graph instance dependency.
59
- *
60
- * @category extra
61
- */
62
-
63
- type ToAsciiOptions = {
64
- /**
65
- * ASCII layout direction. ASCII grid semantics are meaningful only for
66
- * `"LR"` (default) and `"TD"`.
67
- */
68
- direction?: LayoutDirection;
69
- /** Per-box label cell cap; longer labels are truncated with `…`. Default `24`. */
70
- maxLabelWidth?: number;
71
- /** Glyph set: `"unicode"` (default, box-drawing) or `"ascii"` (`-|+<>v`). */
72
- asciiCharset?: "unicode" | "ascii";
73
- /** Optional logger hook; fires with the rendered text before return. */
74
- logger?: (text: string) => void;
75
- };
76
- declare function toAscii(g: GraphDescribeOutput, opts?: ToAsciiOptions): string;
77
-
78
- /**
79
- * `toD2(g, opts?)` — render a {@link GraphDescribeOutput} as D2 diagram text.
80
- *
81
- * Pure function over the describe snapshot; no Graph instance dependency.
82
- *
83
- * @category extra
84
- */
85
-
86
- type ToD2Options = {
87
- /** Diagram direction; default `"LR"`. */
88
- direction?: DiagramDirection;
89
- };
90
- declare function toD2(g: GraphDescribeOutput, opts?: ToD2Options): string;
91
-
92
- /**
93
- * `toJson(g, opts?)` — render a {@link GraphDescribeOutput} as deterministic
94
- * JSON text with sorted keys.
95
- *
96
- * Pure function over the describe snapshot; no Graph instance dependency.
97
- *
98
- * @category extra
99
- */
100
-
101
- type ToJsonOptions = {
102
- /** Include the Edges section (default `true`). */
103
- includeEdges?: boolean;
104
- /** Include the Subgraphs section (default `true`). */
105
- includeSubgraphs?: boolean;
106
- /** JSON indent (default `2`). */
107
- indent?: number;
108
- /** Optional logger hook; fires with the rendered text before return. */
109
- logger?: (text: string) => void;
110
- };
111
- declare function toJson(g: GraphDescribeOutput, opts?: ToJsonOptions): string;
112
-
113
- /**
114
- * `toMermaid(g, opts?)` — render a {@link GraphDescribeOutput} as Mermaid
115
- * flowchart text.
116
- *
117
- * Pure function over the describe snapshot; no Graph instance dependency.
118
- * Compose with `derived` for live formatted output:
119
- *
120
- * ```ts
121
- * import { toMermaid } from "@graphrefly/graphrefly/extra/render";
122
- * import { derived } from "@graphrefly/graphrefly";
123
- *
124
- * const live = derived([graph.describe({ reactive: true }).node], ([g]) => toMermaid(g));
125
- * ```
126
- *
127
- * @category extra
128
- */
129
-
130
- type ToMermaidOptions = {
131
- /** Diagram direction; default `"LR"`. */
132
- direction?: DiagramDirection;
133
- };
134
- declare function toMermaid(g: GraphDescribeOutput, opts?: ToMermaidOptions): string;
135
-
136
- /**
137
- * `toMermaidUrl(g, opts?)` — encode a {@link GraphDescribeOutput} as a
138
- * `https://mermaid.live/edit#base64:…` deep link.
139
- *
140
- * Round-trip with the mermaid.live editor's `/edit#base64:` share format —
141
- * payload is `base64url(JSON({code, mermaid: {theme}, ...}))`. No network
142
- * calls; the payload is encoded into the URL fragment.
143
- *
144
- * @category extra
145
- */
146
-
147
- type MermaidLiveTheme = "default" | "dark" | "forest" | "neutral" | "base";
148
- type ToMermaidUrlOptions = ToMermaidOptions & {
149
- theme?: MermaidLiveTheme;
150
- autoSync?: boolean;
151
- };
152
- /**
153
- * Encode an arbitrary mermaid source string to a `mermaid.live` deep link.
154
- * Exported separately so callers that already rendered mermaid text can
155
- * upgrade to a live-editor URL without re-rendering.
156
- */
157
- declare function mermaidLiveUrl(mermaidSrc: string, opts?: {
158
- theme?: MermaidLiveTheme;
159
- autoSync?: boolean;
160
- }): string;
161
- declare function toMermaidUrl(g: GraphDescribeOutput, opts?: ToMermaidUrlOptions): string;
162
-
163
- /**
164
- * `toPretty(g, opts?)` — render a {@link GraphDescribeOutput} as
165
- * human-readable plaintext (Node list with values, plus optional Edges and
166
- * Subgraphs sections).
167
- *
168
- * Pure function over the describe snapshot; no Graph instance dependency.
169
- *
170
- * @category extra
171
- */
172
-
173
- type ToPrettyOptions = {
174
- /** Include the Edges section (default `true`). */
175
- includeEdges?: boolean;
176
- /** Include the Subgraphs section (default `true`). */
177
- includeSubgraphs?: boolean;
178
- /** Optional logger hook; fires with the rendered text before return. */
179
- logger?: (text: string) => void;
180
- };
181
- declare function toPretty(g: GraphDescribeOutput, opts?: ToPrettyOptions): string;
182
-
183
- export { type DiagramDirection, type LayoutDirection, type MermaidLiveTheme, type ToAsciiOptions, type ToD2Options, type ToJsonOptions, type ToMermaidOptions, type ToMermaidUrlOptions, type ToPrettyOptions, mermaidLiveUrl, toAscii, toD2, toJson, toMermaid, toMermaidUrl, toPretty };
1
+ export * from '@graphrefly/pure-ts/extra/render';
@@ -1 +1,3 @@
1
- import{a,b,c,d,e,f,g}from"../../chunk-3G5U5QNE.js";import"../../chunk-C72GO4IZ.js";import"../../chunk-QYADASLV.js";export{e as mermaidLiveUrl,a as toAscii,b as toD2,c as toJson,d as toMermaid,f as toMermaidUrl,g as toPretty};
1
+ // src/extra/render/index.ts
2
+ export * from "@graphrefly/pure-ts/extra/render";
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/extra/render/index.ts"],"sourcesContent":["// Phase 13.9.A shim — re-export from pure-TS sibling until\n// @graphrefly/native (napi binding) and per-milestone swap-overs land.\nexport * from \"@graphrefly/pure-ts/extra/render\";\n"],"mappings":";AAEA,cAAc;","names":[]}
@@ -1,3 +1,21 @@
1
- "use strict";var gt=Object.defineProperty;var gr=Object.getOwnPropertyDescriptor;var br=Object.getOwnPropertyNames;var yr=Object.prototype.hasOwnProperty;var G=(n,e)=>()=>(n&&(e=n(n=0)),e);var bt=(n,e)=>{for(var t in e)gt(n,t,{get:e[t],enumerable:!0})},vr=(n,e,t,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of br(e))!yr.call(n,o)&&o!==t&&gt(n,o,{get:()=>e[o],enumerable:!(r=gr(e,o))||r.enumerable});return n};var wr=n=>vr(gt({},"__esModule",{value:!0}),n);function X(){return Math.trunc(performance.now()*1e6)}function ve(){return Date.now()*1e6}var we=G(()=>{"use strict"});var oe,x,M,D,te,q,ne,B,E,N,Te,yt,Tr,vt,_r,Nr,wt,rn,on,sn,Tt,ie=G(()=>{"use strict";oe=Symbol.for("graphrefly/START"),x=Symbol.for("graphrefly/DATA"),M=Symbol.for("graphrefly/DIRTY"),D=Symbol.for("graphrefly/RESOLVED"),te=Symbol.for("graphrefly/INVALIDATE"),q=Symbol.for("graphrefly/PAUSE"),ne=Symbol.for("graphrefly/RESUME"),B=Symbol.for("graphrefly/TEARDOWN"),E=Symbol.for("graphrefly/COMPLETE"),N=Symbol.for("graphrefly/ERROR"),Te=Object.freeze([M]),yt=Object.freeze([D]),Tr=Object.freeze([te]),vt=Object.freeze([oe]),_r=Object.freeze([E]),Nr=Object.freeze([B]),wt=Object.freeze([Te]),rn=Object.freeze([yt]),on=Object.freeze([Tr]),sn=Object.freeze([_r]),Tt=Object.freeze([Nr])});function un(n,e){let t=new TextEncoder().encode(n.name);if(t.length===0||t.length>255)throw new Error(`encodeEnvelope: codec name "${n.name}" encodes to ${t.length} bytes (must be 1\u2013255)`);let r=n.version;if(!Number.isInteger(r)||r<0||r>65535)throw new Error(`encodeEnvelope: codec.version ${r} out of u16 range (expected integer 0\u201365535)`);let o=2+t.length+2+e.length;if(o>4294967295)throw new Error(`encodeEnvelope: total envelope size ${o} exceeds 2^32-1 bytes (payload ${e.length} bytes)`);let s=new Uint8Array(o),i=0;return s[i++]=_t,s[i++]=t.length,s.set(t,i),i+=t.length,s[i++]=r>>>8&255,s[i++]=r&255,s.set(e,i),s}function dn(n,e){if(n.length<an)throw new Error(`decodeEnvelope: bytes too short (${n.length} < ${an})`);let t=0,r=n[t++];if(r!==_t)throw new Error(`decodeEnvelope: unsupported envelope version ${r} (expected ${_t})`);let o=n[t++];if(o===0)throw new Error("decodeEnvelope: name_len must be >= 1");if(t+o+2>n.length)throw new Error(`decodeEnvelope: envelope truncated (need ${t+o+2} bytes, have ${n.length})`);let s=new TextDecoder().decode(n.subarray(t,t+o));t+=o;let i=(n[t]<<8|n[t+1])>>>0;t+=2;let a=n.subarray(t),u=e.lookupCodec(s);if(u==null)throw new Error(`decodeEnvelope: codec "${s}" not registered (envelope codec_v=${i})`);return{codec:u,codecVersion:i,payload:a}}function cn(n){n.registerCodec(Or)}var Or,_t,an,Nt=G(()=>{"use strict";Or={name:"json",version:1,contentType:"application/json",encode(n){let e=JSON.stringify(n);return new TextEncoder().encode(e)},decode(n,e){let t=new TextDecoder().decode(n);return JSON.parse(t)}},_t=1,an=4});function ze(n){if(n==null)return _e;let{type:e,id:t,...r}=n;return{type:e??"system",id:t??"",...r}}var _e,Ot=G(()=>{"use strict";_e={type:"system",id:""}});function Ue(){return Ne>0||De}function ln(){return Ne>0}function ke(n){Ne>0?Me.push(n):n()}function Ge(n){Ne+=1;let e=!1;try{n()}catch(t){throw e=!0,t}finally{if(Ne-=1,Ne===0)if(e){if(!De){let t=Me.splice(0);for(let r of t)try{r()}catch{}ce.length=0,le.length=0,Oe.length=0}}else kr()}}function kr(){let n=!De;n&&(De=!0);let e=[],t=0;try{for(;ce.length>0||le.length>0||Oe.length>0||n&&Me.length>0;){if(n&&Me.length>0){let s=Me.splice(0);for(let i of s)try{i()}catch(a){e.push(a)}continue}if(t+=1,t>1e3)throw ce.length=0,le.length=0,Oe.length=0,new Error("batch drain exceeded 1000 iterations \u2014 likely a reactive cycle");let o=(ce.length>0?ce:le.length>0?le:Oe).splice(0);for(let s of o)try{s()}catch(i){e.push(i)}}}finally{n&&(De=!1)}if(e.length===1)throw e[0];if(e.length>1)throw new AggregateError(e,"batch drain: multiple callbacks threw")}function We(n,e,t){if(e.length===0)return;if(e.length===1){let d=t(e[0][0]);if(d<3||!Ue()){n(e);return}(d>=5?Oe:d===4?le:ce).push(()=>n(e));return}let r=e.length,o=r,s=r,i=r,a=0;for(;a<r&&t(e[a][0])<3;)a++;for(o=a;a<r&&t(e[a][0])===3;)a++;for(s=a;a<r&&t(e[a][0])===4;)a++;i=a;let u=Ue();if(o>0){let d=e.slice(0,o);n(d)}if(s>o){let d=e.slice(o,s);u?ce.push(()=>n(d)):n(d)}if(i>s){let d=e.slice(s,i);u?le.push(()=>n(d)):n(d)}if(r>i){let d=e.slice(i,r);u?Oe.push(()=>n(d)):n(d)}}var Ne,De,ce,le,Oe,Me,He=G(()=>{"use strict";Ne=0,De=!1,ce=[],le=[],Oe=[],Me=[]});function fn(n){n.registerMessageType(oe,{tier:0,wireCrossing:!1}),n.registerMessageType(M,{tier:1,wireCrossing:!1}),n.registerMessageType(te,{tier:1,wireCrossing:!1,metaPassthrough:!1}),n.registerMessageType(q,{tier:2,wireCrossing:!1}),n.registerMessageType(ne,{tier:2,wireCrossing:!1}),n.registerMessageType(x,{tier:3,wireCrossing:!0}),n.registerMessageType(D,{tier:3,wireCrossing:!0}),n.registerMessageType(E,{tier:4,wireCrossing:!0,metaPassthrough:!1}),n.registerMessageType(N,{tier:4,wireCrossing:!0,metaPassthrough:!1}),n.registerMessageType(B,{tier:5,wireCrossing:!0,metaPassthrough:!1})}var Ke,pn=G(()=>{"use strict";ie();Ke=class{_messageTypes=new Map;_codecs=new Map;_onMessage;_onSubscribe;_defaultVersioning;_defaultHashFn;_inspectorEnabled=!(typeof process<"u"&&process.env?.NODE_ENV==="production");_globalInspector;_rigorRecorder;_frozen=!1;tierOf;constructor(e){this._onMessage=e.onMessage,this._onSubscribe=e.onSubscribe,this._defaultVersioning=e.defaultVersioning,this._defaultHashFn=e.defaultHashFn,this.tierOf=t=>{let r=this._messageTypes.get(t);return r!=null?r.tier:1}}get onMessage(){return this._frozen=!0,this._onMessage}get onSubscribe(){return this._frozen=!0,this._onSubscribe}set onMessage(e){this._assertUnfrozen(),this._onMessage=e}set onSubscribe(e){this._assertUnfrozen(),this._onSubscribe=e}get defaultVersioning(){return this._defaultVersioning}set defaultVersioning(e){this._assertUnfrozen(),this._defaultVersioning=e}get defaultHashFn(){return this._defaultHashFn}set defaultHashFn(e){this._assertUnfrozen(),this._defaultHashFn=e}get inspectorEnabled(){return this._inspectorEnabled}set inspectorEnabled(e){this._inspectorEnabled=e}get globalInspector(){return this._globalInspector}set globalInspector(e){this._globalInspector=e}get rigorRecorder(){return this._rigorRecorder}set rigorRecorder(e){this._rigorRecorder=e}registerMessageType(e,t){return this._assertUnfrozen(),this._messageTypes.set(e,{tier:t.tier,wireCrossing:t.wireCrossing??t.tier>=3,metaPassthrough:t.metaPassthrough??!0}),this}messageTier(e){let t=this._messageTypes.get(e);return t!=null?t.tier:1}isWireCrossing(e){let t=this._messageTypes.get(e);return t!=null?t.wireCrossing:!0}isLocalOnly(e){return!this.isWireCrossing(e)}isMetaPassthrough(e){let t=this._messageTypes.get(e);return t!=null?t.metaPassthrough:!0}isKnownMessageType(e){return this._messageTypes.has(e)}registerCodec(e){return this._assertUnfrozen(),this._codecs.set(e.name,e),this}lookupCodec(e){return this._codecs.get(e)}_isFrozen(){return this._frozen}_assertUnfrozen(){if(this._frozen)throw new Error("GraphReFlyConfig is frozen: a node has already captured this config. Register custom types and set hooks before creating any node.")}}});function kt(n){let e=xr.filter(t=>n({type:t,id:""},"write"));return e.length===0?"restricted":e.includes("human")&&e.includes("llm")&&e.every(t=>t==="human"||t==="llm"||t==="system")?"both":e.length===1?e[0]:e.join("+")}var Q,xr,qe=G(()=>{"use strict";Q=class extends Error{actor;action;nodeName;constructor(e,t){super(t??`GuardDenied: action "${String(e.action)}" denied for actor type "${String(e.actor.type)}"`),this.name="GuardDenied",this.actor=e.actor,this.action=e.action,this.nodeName=e.nodeName}get node(){return this.nodeName}},xr=["human","llm","wallet","system"]});function xt(n){if(n===void 0)return null;if(typeof n=="number"){if(!Number.isFinite(n))throw new TypeError(`Cannot hash non-finite number: ${n}`);if(Number.isInteger(n)&&!Number.isSafeInteger(n))throw new TypeError(`Cannot hash integer outside safe range (|n| > 2^53-1): ${n}. Cross-language cid parity is not guaranteed for unsafe integers.`);return n}if(typeof n=="string"||typeof n=="boolean"||n===null)return n;if(Array.isArray(n))return n.map(xt);if(typeof n=="object"&&n!==null){let e={};for(let t of Object.keys(n).sort())e[t]=xt(n[t]);return e}return null}function Sr(n){let e=Rr.encode(n),t=e.length,r=t*8,o=t+9+63&-64,s=new Uint8Array(o);s.set(e),s[t]=128;let i=new DataView(s.buffer);i.setUint32(o-4,r>>>0,!1),i.setUint32(o-8,Math.floor(r/4294967296)>>>0,!1);let a=1779033703,u=3144134277,d=1013904242,c=2773480762,l=1359893119,h=2600822924,p=528734635,f=1541459225,g=new Uint32Array(64),m=(b,y)=>b>>>y|b<<32-y;for(let b=0;b<o;b+=64){for(let k=0;k<16;k++)g[k]=i.getUint32(b+k*4,!1);for(let k=16;k<64;k++){let U=g[k-15],V=g[k-2],I=m(U,7)^m(U,18)^U>>>3,ye=m(V,17)^m(V,19)^V>>>10;g[k]=g[k-16]+I+g[k-7]+ye>>>0}let y=a,v=u,w=d,_=c,R=l,S=h,C=p,A=f;for(let k=0;k<64;k++){let U=m(R,6)^m(R,11)^m(R,25),V=R&S^~R&C,I=A+U+V+Er[k]+g[k]>>>0,ye=m(y,2)^m(y,13)^m(y,22),lt=y&v^y&w^v&w,Ve=ye+lt>>>0;A=C,C=S,S=R,R=_+I>>>0,_=w,w=v,v=y,y=I+Ve>>>0}a=a+y>>>0,u=u+v>>>0,d=d+w>>>0,c=c+_>>>0,l=l+R>>>0,h=h+S>>>0,p=p+C>>>0,f=f+A>>>0}let T=b=>b.toString(16).padStart(8,"0");return T(a)+T(u)+T(d)+T(c)+T(l)+T(h)+T(p)+T(f)}function Et(n){let e=xt(n??null),t=JSON.stringify(e);return Sr(t).slice(0,16)}function Cr(){let n=globalThis.crypto;if(n?.randomUUID)return n.randomUUID();let e=()=>Math.floor(Math.random()*4294967296).toString(16).padStart(8,"0"),t=e()+e()+e()+e();return`${t.slice(0,8)}-${t.slice(8,12)}-4${t.slice(13,16)}-${(parseInt(t.slice(16,17),16)&3|8).toString(16)}${t.slice(17,20)}-${t.slice(20,32)}`}function Rt(n,e,t){let r=t?.id??Cr();if(n===0)return{id:r,version:0};let s=(t?.hash??Et)(e);return{id:r,version:0,cid:s,prev:null}}function hn(n,e,t){n.version+=1,"cid"in n&&(n.prev=n.cid,n.cid=t(e))}var Er,Rr,mn=G(()=>{"use strict";Er=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),Rr=new TextEncoder});function yn(n){return{node:n,unsub:null,prevData:void 0,dirty:!1,involvedThisWave:!1,dataBatch:[],terminal:void 0}}function St(n){n.prevData=void 0,n.dirty=!1,n.involvedThisWave=!1,n.dataBatch.length=0,n.terminal=void 0}function Ye(n){return n.length===0?n:typeof n[0]=="symbol"?[n]:n}function W(n,e,t){let r=vn(n)?n:[],o=typeof n=="function"?n:typeof e=="function"?e:void 0,s={};return vn(n)?s=(Ct(e)?e:t)??{}:Ct(n)?s=n:s=(Ct(e)?e:t)??{},new j(r,o,s)}var gn,bn,Ar,Dr,xe,j,vn,Ct,se=G(()=>{"use strict";Nt();Ot();He();we();pn();qe();ie();mn();gn=()=>{},bn=100;Ar=(n,e,t,r)=>{t.direction==="down-in"&&n._onDepMessage(t.depIndex,e)},Dr=(n,e,t,r)=>{let o=n;if(o._status==="completed"||o._status==="errored")return;let s=o._cached,i=s===void 0?[vt]:[vt,[x,s]];o._status==="dirty"&&i.push(Te),We(e,i,o._config.tierOf)},xe=new Ke({onMessage:Ar,onSubscribe:Dr});fn(xe);cn(xe);j=class n{_optsName;_describeKind;meta;_hasMeta;_config;_deps;_sinks=null;_sinkCount=0;_cached;_status;_cleanup;_store={};_waveHasNewData=!1;_hasNewTerminal=!1;_hasCalledFnOnce=!1;_paused=!1;_pendingWave=!1;_isExecutingFn=!1;_pendingRerun=!1;_rerunDepth=0;_dirtyDepCount=0;_batchPendingMessages=null;_pauseLocks=null;_pauseBuffer=null;_fn;_equals;_resubscribable;_resetOnTeardown;_autoComplete;_autoError;_pausable;_partial;_guard;_extraGuards;_hashFn;_versioning;_versioningLevel;_lastMutation;_inspectorHooks;_actions;constructor(e,t,r){this._config=r.config??xe,this._config.onMessage,this._optsName=r.name,this._describeKind=r.describeKind,this._equals=r.equals??Object.is,this._resubscribable=r.resubscribable??!1,this._resetOnTeardown=r.resetOnTeardown??!1,this._autoComplete=r.completeWhenDepsComplete??!0,this._autoError=r.errorWhenDepsError??!0,this._pausable=r.pausable??!0,this._guard=r.guard,this._fn=t,this._partial=r.partial??!1,this._cached=r.initial!==void 0?r.initial:void 0,this._status=e.length===0&&t==null&&this._cached!==void 0?"settled":"sentinel",this._hashFn=r.versioningHash??this._config.defaultHashFn??Et;let o=r.versioning??this._config.defaultVersioning;this._versioningLevel=o,this._versioning=o!=null?Rt(o,this._cached===void 0?void 0:this._cached,{id:r.versioningId,hash:this._hashFn}):void 0,this._deps=e.map(yn);let s={};for(let[a,u]of Object.entries(r.meta??{})){let d={initial:u,name:`${r.name??"node"}:meta:${a}`,describeKind:"state",config:this._config};r.guard!=null&&(d.guard=r.guard),s[a]=new n([],void 0,d)}Object.freeze(s),this.meta=s,this._hasMeta=Object.keys(s).length>0;let i=this;this._actions={emit(a){i._emit([[x,a]])},down(a){i._emit(Ye(a))},up(a){i._emitUp(Ye(a))}},this.down=this.down.bind(this),this.up=this.up.bind(this)}get _isTerminal(){return this._status==="completed"||this._status==="errored"}get name(){return this._optsName}get status(){return this._status}get cache(){return this._cached===void 0?void 0:this._cached}get lastMutation(){return this._lastMutation}get v(){return this._versioning}hasGuard(){return this._guard!=null}_applyVersioning(e,t){if(this._isExecutingFn)throw new Error(`Node "${this.name}": _applyVersioning cannot run mid-fn \u2014 call it outside of \`_execFn\` (typically at graph setup time before the first subscribe).`);let r=this._versioningLevel;if(r!=null&&e<=r)return;let o=t?.hash??this._hashFn;o!==this._hashFn&&(this._hashFn=o);let s=this._cached===void 0?void 0:this._cached,i=this._versioning,a=i?.id??t?.id,u=i?.version??0,d=Rt(e,s,{id:a,hash:o});d.version=u,this._versioning=d,this._versioningLevel=e}_setInspectorHook(e){return e==null?()=>{}:(this._inspectorHooks==null&&(this._inspectorHooks=new Set),this._inspectorHooks.add(e),()=>{this._inspectorHooks?.delete(e),this._inspectorHooks?.size===0&&(this._inspectorHooks=void 0)})}_pushGuard(e){return this._extraGuards==null&&(this._extraGuards=new Set),this._extraGuards.add(e),()=>{this._extraGuards?.delete(e),this._extraGuards?.size===0&&(this._extraGuards=void 0)}}allowsObserve(e){if(this._guard==null&&this._extraGuards==null)return!0;let t=ze(e);if(this._guard!=null&&!this._guard(t,"observe"))return!1;if(this._extraGuards!=null){for(let r of this._extraGuards)if(!r(t,"observe"))return!1}return!0}_checkGuard(e){if(e?.internal)return;let t=this._guard!=null||this._extraGuards!=null,r=e?.actor!=null;if(!t&&!r)return;let o=ze(e?.actor),s=e?.delivery==="signal"?"signal":"write";if(this._guard!=null&&!this._guard(o,s))throw new Q({actor:o,action:s,nodeName:this.name});if(this._extraGuards!=null){for(let i of this._extraGuards)if(!i(o,s))throw new Q({actor:o,action:s,nodeName:this.name})}this._lastMutation={actor:o,timestamp_ns:ve()}}down(e,t){let r=Ye(e);r.length!==0&&(this._checkGuard(t),this._emit(r))}emit(e,t){this._checkGuard(t),this._emit([[x,e]])}up(e,t){if(this._deps.length===0)return;let r=Ye(e);if(r.length===0)return;this._checkGuard(t);let o=t??{internal:!0};this._validateUpTiers(r);for(let s of this._deps)s.node.up?.(r,o)}_emitUp(e){if(this._deps.length!==0&&e.length!==0){this._validateUpTiers(e);for(let t of this._deps)t.node.up?.(e,{internal:!0})}}_validateUpTiers(e){let t=this._config.tierOf;for(let r of e){let o=t(r[0]);if(o===3||o===4)throw new Error(`Node "${this.name}": tier-${o} messages cannot flow up \u2014 DATA/RESOLVED/COMPLETE/ERROR are downstream-only. Use \`down(...)\` for value delivery; \`up(...)\` is for control signals (DIRTY, INVALIDATE, PAUSE, RESUME, TEARDOWN).`)}}subscribe(e,t){if(t!=null&&this._guard!=null){let u=ze(t);if(!this._guard(u,"observe"))throw new Q({actor:u,action:"observe",nodeName:this.name})}let o=this._isTerminal&&this._resubscribable;if(o){this._cached=void 0,this._status="sentinel",this._store={},this._hasCalledFnOnce=!1,this._waveHasNewData=!1,this._hasNewTerminal=!1,this._paused=!1,this._pendingWave=!1,this._pendingRerun=!1,this._isExecutingFn=!1,this._rerunDepth=0,this._dirtyDepCount=0,this._pauseLocks=null,this._pauseBuffer=null;for(let u of this._deps)St(u);if(this._partial===!1){for(let u of this._deps)if(u.prevData!==void 0||u.dataBatch.length!==0||u.terminal!==void 0||u.dirty)throw new Error(`resubscribable-reset invariant: DepRecord not fully reset for node ${this._optsName??"(anonymous)"}`)}}this._sinkCount+=1;let s;try{s=this._config.onSubscribe(this,e,{sinkCount:this._sinkCount,afterTerminalReset:o},this._actions)}catch(u){throw this._sinkCount-=1,u}this._sinks==null?this._sinks=e:typeof this._sinks=="function"?this._sinks=new Set([this._sinks,e]):this._sinks.add(e);let i=this._isTerminal;if(this._sinkCount===1&&!i)try{this._activate()}catch(u){if(this._sinkCount-=1,this._removeSink(e),this._sinkCount===0&&(this._status="sentinel"),typeof s=="function")try{s()}catch{}throw u}this._status==="sentinel"&&this._cached===void 0&&(this._status="pending");let a=!1;return()=>{a||(a=!0,this._sinkCount-=1,this._removeSink(e),typeof s=="function"&&s(),this._sinks==null&&this._deactivate())}}_removeSink(e){if(this._sinks===e)this._sinks=null;else if(this._sinks!=null&&typeof this._sinks!="function")if(this._sinks.delete(e),this._sinks.size===1){let[t]=this._sinks;this._sinks=t}else this._sinks.size===0&&(this._sinks=null)}_activate(){if(this._deps.length===0){this._fn&&this._execFn();return}this._dirtyDepCount=0;let e=this._deps.length,t=0;try{for(let r=0;r<e;r++){let o=r,s=this._deps[r];s.unsub=gn,s.unsub=s.node.subscribe(i=>{if(s.unsub===null)return;let a=this._config.tierOf,u=!1;for(let d of i)a(d[0])>=3&&(u=!0),this._config.onMessage(this,d,{direction:"down-in",depIndex:o},this._actions);u&&this._maybeRunFnOnSettlement()}),t++}}catch(r){this._deps[t].unsub=null;for(let o=0;o<t;o++){let s=this._deps[o];if(s.unsub!=null){let i=s.unsub;s.unsub=null;try{i()}catch{}St(s)}}throw this._dirtyDepCount=0,r}}_addDep(e){for(let o=0;o<this._deps.length;o++)if(this._deps[o].node===e)return o;let t=this._deps.length,r=yn(e);if(this._deps.push(r),this._sinks==null)return t;r.dirty=!0,this._dirtyDepCount++,this._status!=="dirty"&&this._emit(wt),r.unsub=gn;try{r.unsub=e.subscribe(o=>{if(r.unsub===null)return;let s=this._config.tierOf,i=!1;for(let a of o)s(a[0])>=3&&(i=!0),this._config.onMessage(this,a,{direction:"down-in",depIndex:t},this._actions);i&&this._maybeRunFnOnSettlement()})}catch(o){throw r.unsub=null,this._deps.pop(),this._dirtyDepCount--,o}return t}_deactivate(e=!1){let t=this._cleanup;if(this._cleanup=void 0,typeof t=="function")try{t()}catch(r){this._emit([[N,this._wrapFnError("cleanup threw",r)]])}else if(t!=null&&typeof t=="object"){let r=t.deactivate;if(typeof r=="function")try{r()}catch(o){this._emit([[N,this._wrapFnError("cleanup.deactivate threw",o)]])}}for(let r of this._deps){if(r.unsub!=null){let o=r.unsub;r.unsub=null;try{o()}catch{}}St(r)}this._waveHasNewData=!1,this._hasNewTerminal=!1,this._hasCalledFnOnce=!1,this._paused=!1,this._pendingWave=!1,this._pendingRerun=!1,this._rerunDepth=0,this._store={},this._dirtyDepCount=0,this._pauseLocks=null,this._pauseBuffer=null,this._fn!=null&&(this._cached=void 0),e||(this._fn!=null||this._deps.length>0)&&(!this._isTerminal||this._resubscribable)&&(this._status="sentinel")}_onDepMessage(e,t){let r=this._deps[e],o=t[0];if(this._inspectorHooks!=null){let s={kind:"dep_message",depIndex:e,message:t};for(let i of this._inspectorHooks)i(s)}if(o!==oe){if(o===M){this._depDirtied(r);return}if(o===te){if(this._depInvalidated(r),this._cached===void 0)return;this._emit(on);return}if(o===q||o===ne){this._emit([t]);return}if(o===B){this._emit(Tt);return}if(o===x)this._depSettledAsData(r,t[1]);else if(o===D)this._depSettledAsResolved(r);else if(o===E)this._depSettledAsTerminal(r,!0);else if(o===N)this._depSettledAsTerminal(r,t[1]);else{this._emit([t]);return}if(!this._fn){(o===x||o===D)&&this._emit([t]),(o===E||o===N)&&this._maybeAutoTerminalAfterWave();return}}}_depDirtied(e){e.dirty||(e.dirty=!0,e.involvedThisWave=!0,this._dirtyDepCount++,this._status!=="dirty"&&this._emit(wt))}_depSettledAsData(e,t){e.dirty&&(e.dirty=!1,this._dirtyDepCount--),e.involvedThisWave=!0,e.dataBatch.push(t),this._waveHasNewData=!0}_depSettledAsResolved(e){e.dirty&&(e.dirty=!1,this._dirtyDepCount--)}_depSettledAsTerminal(e,t){e.dirty&&(e.dirty=!1,this._dirtyDepCount--),e.terminal=t,e.involvedThisWave=!0,this._hasNewTerminal=!0}_depInvalidated(e){e.prevData=void 0,e.terminal=void 0,e.dataBatch.length=0,e.dirty?e.involvedThisWave=!1:(e.dirty=!0,e.involvedThisWave=!0,this._dirtyDepCount++)}_maybeRunFnOnSettlement(){if(!(this._isTerminal&&!this._resubscribable)&&!(this._dirtyDepCount>0)){if(!this._partial&&!this._hasCalledFnOnce)for(let e=0;e<this._deps.length;e++){let t=this._deps[e];if(t.dataBatch.length===0&&t.prevData===void 0&&t.terminal===void 0){this._maybeAutoTerminalAfterWave();return}}if(this._paused){this._pendingWave=!0;return}if(!this._waveHasNewData&&!this._hasNewTerminal&&this._hasCalledFnOnce){this._clearWaveFlags(),this._emit(rn),this._maybeAutoTerminalAfterWave();return}this._fn&&this._execFn(),this._maybeAutoTerminalAfterWave()}}_maybeAutoTerminalAfterWave(){if(this._deps.length===0||this._isTerminal)return;let e=this._deps.find(t=>t.terminal!==void 0&&t.terminal!==!0);if(e!=null){this._autoError&&this._emit([[N,e.terminal]]);return}this._autoComplete&&this._deps.every(t=>t.terminal!==void 0)&&this._emit(sn)}_execFn(){if(!this._fn||this._isTerminal&&!this._resubscribable)return;if(this._isExecutingFn){this._pendingRerun=!0;return}let e=this._cleanup;if(typeof e=="function"){this._cleanup=void 0;try{e()}catch(i){this._emit([[N,this._wrapFnError("cleanup threw",i)]]);return}}else if(e!=null&&typeof e=="object"){let i=e.beforeRun;if(typeof i=="function"){e.beforeRun=void 0;try{i()}catch(a){this._emit([[N,this._wrapFnError("cleanup.beforeRun threw",a)]]);return}}}let t=this._deps.map(i=>i.involvedThisWave?i.dataBatch.length>0?[...i.dataBatch]:[]:void 0),r=this._deps.map(i=>i.prevData);for(let i=0;i<this._deps.length;i++){let a=t[i];a!=null&&a.length>0&&(this._deps[i].prevData=a[a.length-1])}let o=this._deps.map(i=>i.terminal),s={prevData:r,terminalDeps:o,store:this._store};if(this._hasCalledFnOnce=!0,this._clearWaveFlags(),this._inspectorHooks!=null){let i={kind:"run",batchData:t,prevData:r};for(let a of this._inspectorHooks)a(i)}this._isExecutingFn=!0;try{let i=this._fn(t,this._actions,s);if(typeof i=="function")this._cleanup=i;else if(i!=null&&typeof i=="object"){let a=i;(typeof a.beforeRun=="function"||typeof a.deactivate=="function"||typeof a.invalidate=="function")&&(this._cleanup=i)}}catch(i){this._emit([[N,this._wrapFnError("fn threw",i)]])}finally{this._isExecutingFn=!1,this._pendingRerun?(this._pendingRerun=!1,this._rerunDepth+=1,this._rerunDepth>bn?(this._rerunDepth=0,this._emit([[N,new Error(`Node "${this.name}": _pendingRerun depth exceeded ${bn} \u2014 likely a reactive cycle`)]])):this._maybeRunFnOnSettlement()):this._rerunDepth=0,this._clearWaveFlags()}}_clearWaveFlags(){this._waveHasNewData=!1,this._hasNewTerminal=!1;for(let e of this._deps)e.involvedThisWave=!1,e.dataBatch.length=0}_wrapFnError(e,t){let r=t instanceof Error?t.message:String(t);return new Error(`Node "${this.name}": ${e}: ${r}`,{cause:t})}_frameBatch(e){let t=this._config.tierOf;if(e.length===1)return t(e[0][0])===3&&this._status!=="dirty"?[Te,e[0]]:e;let r=!0,o=!1,s=!1,i=-1;for(let u of e){let d=t(u[0]);d<i&&(r=!1),d===3&&(o=!0),u[0]===M&&(s=!0),i=d}let a=e;if(!r){let u=e.map((d,c)=>({m:d,i:c,tier:t(d[0])}));u.sort((d,c)=>d.tier-c.tier||d.i-c.i),a=u.map(d=>d.m)}if(o&&!s&&this._status!=="dirty"){let u=0;for(;u<a.length&&t(a[u][0])===0;)u++;return u===0?[Te,...a]:[...a.slice(0,u),Te,...a.slice(u)]}return a}_emit(e){if(e.length===0)return;for(let a=0;a<e.length;a++){let u=e[a];if(u[0]===N&&u[1]===void 0)throw new TypeError('[ERROR, payload] requires a non-undefined payload (spec \xA71.2). Pass an Error object or domain tag instead \u2014 e.g. node.down([[ERROR, new Error("reason")]])')}let t=e;if(this._isTerminal&&!this._resubscribable){let a=e.filter(u=>u[0]===B||u[0]===te);if(a.length===0)return;t=a}t=this._frameBatch(t);let o=null;for(let a=0;a<t.length;a++){let u=t[a],d=u[0];if(d!==q&&d!==ne){o?.push(u);continue}if(u.length<2)throw new Error(`Node "${this.name}": [[${d===q?"PAUSE":"RESUME"}]] must carry a lockId payload \u2014 bare PAUSE/RESUME is a protocol violation (C0 rule). Use \`[[PAUSE, lockId]]\` / \`[[RESUME, lockId]]\`.`);let c=!0;if(this._pausable!==!1){let l=u[1];if(d===q)this._pauseLocks==null&&(this._pauseLocks=new Set),this._pauseLocks.add(l),this._paused=!0,this._pausable==="resumeAll"&&this._pauseBuffer==null&&(this._pauseBuffer=[]);else if(this._pauseLocks==null||!this._pauseLocks.has(l))c=!1;else if(this._pauseLocks.delete(l),this._pauseLocks.size===0){if(this._paused=!1,this._pauseBuffer!=null&&this._pauseBuffer.length>0){let h=this._pauseBuffer;this._pauseBuffer=[],this._emit(h)}this._pendingWave&&(this._pendingWave=!1,this._maybeRunFnOnSettlement())}}c?o?.push(u):o==null&&(o=t.slice(0,a))}if(o!=null){if(o.length===0)return;t=o}if(this._hasMeta&&t.some(a=>a[0]===B))for(let a of Object.keys(this.meta))try{this.meta[a]._emit(Tt)}catch{}let{finalMessages:s,equalsError:i}=this._updateState(t);if(s.length>0&&this._config.inspectorEnabled){let a=this._config.globalInspector;if(a!=null)try{a({kind:"emit",node:this,messages:s})}catch{}}if(s.length>0)if(this._paused&&this._pausable==="resumeAll"&&this._pauseBuffer!=null){let a=this._config.tierOf,u=[];for(let d of s)a(d[0])===3?this._pauseBuffer.push(d):u.push(d);u.length>0&&this._dispatchOrAccumulate(u)}else this._dispatchOrAccumulate(s);i!=null&&this._emit([[N,i]])}_updateState(e){let t=this._config.tierOf,r,o,s=-1,i=0;for(let c of e)t(c[0])===3&&i++;let a=i<=1,u=-1;if(this._versioning!=null&&i>1){for(let c=e.length-1;c>=0;c--)if(e[c][0]===x){u=c;break}}for(let c=0;c<e.length;c++){let l=e[c],h=l[0];if(h===x){if(l.length>=2){let p=!1;if(a&&this._cached!==void 0)try{p=this._equals(this._cached,l[1])}catch(f){o=this._wrapFnError("equals threw",f),s=c;break}if(p){r==null&&(r=e.slice(0,c)),r.push(yt),this._status="resolved";continue}this._cached=l[1],this._versioning!=null&&(u<0||c===u)&&hn(this._versioning,l[1],this._hashFn)}this._status="settled",r?.push(l)}else if(r?.push(l),h===M)this._status="dirty";else if(h===D)this._status="resolved";else if(h===E){this._status="completed";{let p=this._config.rigorRecorder;if(p!=null)try{p.onTerminalTransition(this,"completed",this._autoComplete,this._autoError,this._deps.length>0)}catch{}}}else if(h===N){this._status="errored";{let p=this._config.rigorRecorder;if(p!=null)try{p.onTerminalTransition(this,"errored",this._autoComplete,this._autoError,this._deps.length>0)}catch{}}}else if(h===te){if(this._cached!==void 0){let f=this._config.rigorRecorder;if(f!=null)try{f.onNonVacuousInvalidate(this,this._cached)}catch{}}this._cached=void 0,this._status="dirty";let p=this._cleanup;if(typeof p=="function"){this._cleanup=void 0;try{p()}catch{}}else if(p!=null&&typeof p=="object"){let f=p.invalidate;if(typeof f=="function")try{f()}catch{}}}else h===B&&(this._resetOnTeardown&&(this._cached=void 0),this._deactivate(!0),this._status="sentinel")}let d=s>=0?r??e.slice(0,s):r??e;return o!=null?{finalMessages:d,equalsError:o}:{finalMessages:d}}_deliverToSinks=e=>{if(this._sinks==null)return;if(typeof this._sinks=="function"){this._sinks(e);return}let t=[...this._sinks];for(let r of t)r(e)};_dispatchOrAccumulate(e){if(ln()){this._batchPendingMessages===null&&(this._batchPendingMessages=[],ke(()=>this._flushBatchPending()));for(let t of e)this._batchPendingMessages.push(t);return}We(this._deliverToSinks,e,this._config.tierOf)}_flushBatchPending(){let e=this._batchPendingMessages;if(e===null||(this._batchPendingMessages=null,e.length===0))return;let t=this._frameBatch(e);We(this._deliverToSinks,t,this._config.tierOf)}},vn=n=>Array.isArray(n),Ct=n=>typeof n=="object"&&n!=null&&!Array.isArray(n)});function fe(n,e){return W([],{...e,initial:n})}function F(n,e){return W((r,o,s)=>n(o,s)??void 0,{describeKind:"producer",...e})}function At(n,e,t){return W(n,(o,s,i)=>{let a=o.map((u,d)=>u!=null&&u.length>0?u.at(-1):i.prevData[d]);s.emit(e(a,i))},{describeKind:"derived",...t})}var Je=G(()=>{"use strict";se()});function Pe(n,e,t){let r=new Set;for(let o of n.split(",")){let[s,i]=o.split("/"),a=i?Number.parseInt(i,10):1;if(Number.isNaN(a)||a<1)throw new Error(`Invalid cron step: ${o}`);let u,d;if(s==="*")u=e,d=t;else if(s.includes("-")){let[c,l]=s.split("-");u=Number.parseInt(c,10),d=Number.parseInt(l,10)}else u=Number.parseInt(s,10),d=u;if(Number.isNaN(u)||Number.isNaN(d))throw new Error(`Invalid cron field: ${n}`);if(u<e||d>t)throw new Error(`Cron field out of range: ${n} (${e}-${t})`);if(u>d)throw new Error(`Invalid cron range: ${u}-${d} in ${n}`);for(let c=u;c<=d;c+=a)r.add(c)}return r}function wn(n){let e=n.trim().split(/\s+/);if(e.length!==5)throw new Error(`Invalid cron: expected 5 fields, got ${e.length}`);return{minutes:Pe(e[0],0,59),hours:Pe(e[1],0,23),daysOfMonth:Pe(e[2],1,31),months:Pe(e[3],1,12),daysOfWeek:Pe(e[4],0,6)}}function Tn(n,e){return n.minutes.has(e.getMinutes())&&n.hours.has(e.getHours())&&n.daysOfMonth.has(e.getDate())&&n.months.has(e.getMonth()+1)&&n.daysOfWeek.has(e.getDay())}var _n=G(()=>{"use strict"});function H(n,e,t){return{[n]:!0,[`${n}_type`]:e,...t??{}}}var Dt=G(()=>{"use strict"});function Ie(n,e,t){if(e.length===0)throw new RangeError("budgetGate requires at least one constraint");let r=e.map(p=>p.node),o=[n,...r],s=new Mt,i=!1,a=!1,u=Symbol("budget-gate"),d=new Array(e.length);function c(){return e.every((p,f)=>p.check(d[f]))}function l(p){for(;s.size>0&&c();){let f=s.shift();p.emit(f)}s.size===0&&a&&(a=!1,p.down([[D]]))}return W([],(p,f)=>{for(let m=0;m<e.length;m++)d[m]=e[m].node.cache;let g=[];for(let m=0;m<o.length;m++){let T=o[m];g.push(T.subscribe(b=>{for(let y of b)h(y,m,f)}))}return()=>{for(let m of g)m()}},{...t,describeKind:"derived",meta:H("resilience","budget_gate",t?.meta)});function h(p,f,g){let m=p[0];if(f===0){if(m===x)return c()&&s.size===0?g.emit(p[1]):(s.push(p[1]),i||(i=!0,g.up([[q,u]]))),!0;if(m===M)return g.down([[M]]),!0;if(m===D)return s.size===0?g.down([[D]]):a=!0,!0;if(m===E||m===N){for(;s.size>0;)g.emit(s.shift());return a=!1,i&&(i=!1,g.up([[ne,u]])),g.down([p]),!0}return!1}if(m===x&&(d[f-1]=p[1]),m===x||m===D){let T=c();return T&&s.size>0?(l(g),s.size===0&&i&&(i=!1,g.up([[ne,u]]))):!T&&!i&&s.size>0&&(i=!0,g.up([[q,u]])),!0}return m===M?!0:m===N?(g.down([p]),!0):m===E}}var Mt,Nn=G(()=>{"use strict";ie();se();Dt();Mt=class{buf=[];head=0;get size(){return this.buf.length-this.head}push(e){this.buf.push(e)}shift(){if(this.head>=this.buf.length)return;let e=this.buf[this.head];return this.buf[this.head]=void 0,this.head++,this.head>32&&this.head*2>this.buf.length&&(this.buf=this.buf.slice(this.head),this.head=0),e}clear(){this.buf=[],this.head=0}}});function Pt(n,e){if(e!=null&&e.length>0)return new Set(e);switch(n){case"standard":return new Set(["type","status","value","deps","meta","v"]);case"full":return null;case"spec":return new Set(["type","deps","meta","value"]);default:return new Set(["type","deps"])}}function Mr(n){return n._describeKind!=null?n._describeKind:n._deps.length>0?"derived":n._fn!=null?"producer":"state"}function On(n){let e=new WeakSet,t={};for(let[r,o]of kn(n))t[r]=Gt(o,e);return t}function Gt(n,e){if(n==null)return n;let t=typeof n;if(t==="boolean"||t==="number"||t==="string")return n;if(t==="function")return"<function>";if(Array.isArray(n))return e.has(n)?"<cycle>":(e.add(n),n.map(r=>Gt(r,e)));if(t==="object"){let r=n;if(e.has(r))return"<cycle>";e.add(r);try{if(typeof r.subscribe=="function"&&"cache"in r)return"<Node>"}catch{return"<unserializable>"}let o={};for(let[s,i]of kn(r))o[s]=Gt(i,e);return o}return"<unserializable>"}function kn(n){let e=[],t;try{t=Object.keys(n)}catch{return e}for(let r of t)try{e.push([r,n[r]])}catch{e.push([r,"<unserializable>"])}return e}function re(n,e){let t={factory:n};return e!==void 0&&(t.factoryArgs=e),t}function Gr(n){let e={};for(let[t,r]of Object.entries(n.meta))try{e[t]=r.cache}catch{}return e}function It(n,e,t){let r=e==null,o=!r&&e!=null?[...e].filter(c=>c.startsWith("meta.")).map(c=>c.slice(5)):null,s=r||e.has("meta")||o!=null&&o.length>0,i="state",a=[];n instanceof j&&(i=Mr(n),a=n._deps.map(c=>c.node.name??""));let u={type:i,deps:a};(r||e.has("status"))&&(u.status=n.status);let d=n instanceof j?n._guard:void 0;if(s){let c={...Gr(n)};if(d!=null&&c.access===void 0&&(c.access=kt(d)),o!=null&&o.length>0&&!e.has("meta")){let l={};for(let h of o)h in c&&(l[h]=c[h]);u.meta=l}else u.meta=c}if(n.name!=null&&(u.name=n.name),(r||e.has("value"))&&(!t||i==="state")){n.status==="sentinel"&&(u.sentinel=!0);try{u.value=n.cache}catch{}}if((r||e.has("v"))&&n.v!=null){let c={id:n.v.id,version:n.v.version};"cid"in n.v&&(c.cid=n.v.cid,c.prev=n.v.prev),u.v=c}return(r||e.has("guard"))&&d!=null&&(u.guard=kt(d)),(r||e.has("lastMutation"))&&n.lastMutation!=null&&(u.lastMutation=n.lastMutation),u}var $e=G(()=>{"use strict";qe();se()});function xn(n){let e=new WeakSet,t=new WeakSet,r=[n],o=0;for(;r.length>0;){let s=r.pop();o+=Ir(s,e,t,r)}return o}function Ir(n,e,t,r){if(n==null)return 0;switch(typeof n){case"number":return z.number;case"boolean":return z.boolean;case"string":return z.string+n.length*2;case"bigint":return z.bigint+$r(n);case"symbol":return z.symbol;case"function":return e.has(n)?0:(e.add(n),z.function);case"undefined":return 0}let s=n;if(e.has(s))return 0;e.add(s);let i=s[Pr];if(typeof i=="function")try{let d=i.call(s);if(typeof d=="number"&&Number.isFinite(d))return d}catch{}if(s instanceof Date)return z.date;if(s instanceof RegExp)return z.regexp+s.source.length*2;if(s instanceof Error){let d=s.message?s.message.length*2:0,c=s.stack?s.stack.length*2:0;return z.error+d+c}if(typeof URL<"u"&&s instanceof URL)return z.url+s.href.length*2;if(typeof Promise<"u"&&s instanceof Promise)return z.promise;if(s instanceof WeakMap)return z.weakmap;if(s instanceof WeakSet)return z.weakset;if(s instanceof Map){let d=z.map;for(let[c,l]of s)d+=z.mapEntry,r.push(c),r.push(l);return d}if(s instanceof Set){let d=z.set;for(let c of s)d+=z.setEntry,r.push(c);return d}if(Array.isArray(s)){let d=z.array+s.length*8;for(let c of s)r.push(c);return d}if(s instanceof ArrayBuffer)return t.has(s)?0:(t.add(s),s.byteLength);if(ArrayBuffer.isView(s)){let d=s;return t.has(d.buffer)?48:(t.add(d.buffer),d.buffer.byteLength+48)}let a=z.object,u=Object.keys(s);for(let d of u){a+=z.string+d.length*2;try{r.push(s[d])}catch{}}return a}function $r(n){let e=n<0n?-n:n;if(e===0n)return 0;let t=e.toString(2).length;return Math.ceil(t/32)*8}var z,Pr,En=G(()=>{"use strict";z={object:56,array:64,string:40,number:8,boolean:4,null:0,undefined:0,symbol:40,bigint:16,function:120,map:72,set:72,mapEntry:40,setEntry:24,date:24,regexp:48,error:64,url:80,promise:48,weakmap:40,weakset:40},Pr=Symbol.for("sizeof")});function Rn(n,e,t,r={}){let o=e in n.nodes,s=t in n.nodes;if(!o)return Ze(e,t,"no-such-from");if(!s)return Ze(e,t,"no-such-to");let i=r.maxDepth;if(i!=null&&(!Number.isInteger(i)||i<0))throw new Error("explainPath: maxDepth must be an integer >= 0");if(e===t){if(r.findCycle===!0){let d=Lr(n,e,r);if(d!=null)return d}let u=Xe(e,n.nodes[e],0,r);return Qe(e,t,[u])}if(i===0)return Ze(e,t,"no-path");let a=Sn(n,e,t,i);return a.found?Qe(e,t,Cn(n,a.pathOrder,r)):Ze(e,t,a.truncated?"max-depth-exceeded":"no-path")}function Sn(n,e,t,r){let o=new Map,s=[{path:t,depth:0}],i=new Set([t]),a=0,u=!1;for(;a<s.length;){let l=s[a++];if(l.path===e)break;if(r!=null&&l.depth>=r){let g=n.nodes[l.path];g?.deps&&g.deps.length>0&&(u=!0);continue}let h=n.nodes[l.path];if(h==null)continue;let p=h.deps??[],f=new Map;for(let g=0;g<p.length;g++){let m=p[g];if(!m)continue;let T=f.get(m);T==null&&(T=[],f.set(m,T)),T.push(g)}for(let[g,m]of f)i.has(g)||(i.add(g),o.set(g,{from:l.path,depIndices:m}),s.push({path:g,depth:l.depth+1}))}if(!o.has(e))return{found:!1,pathOrder:[],truncated:u};let d=[{path:e}],c=e;for(;c!==t;){let l=o.get(c);if(l==null)return{found:!1,pathOrder:[],truncated:!1};d[d.length-1].depIndices=l.depIndices,d.push({path:l.from}),c=l.from}return{found:!0,pathOrder:d,truncated:!1}}function Lr(n,e,t){let r=n.nodes[e];if(r==null)return null;let o=r.deps??[],s=[];for(let a=0;a<o.length;a++)o[a]===e&&s.push(a);if(s.length>0){let a=Xe(e,r,0,t);a.dep_index=s[0];let u=Xe(e,r,1,t);return Qe(e,e,[a,u])}let i=null;for(let a=0;a<o.length;a++){let u=o[a];if(!u||u===e)continue;let d=Sn(n,u,e,t.maxDepth);d.found&&(i==null||d.pathOrder.length<i.pathOrder.length)&&(i=d,i={found:!0,pathOrder:[{path:e,depIndices:[a]},...d.pathOrder],truncated:!1})}return i==null?null:Qe(e,e,Cn(n,i.pathOrder,t))}function Cn(n,e,t){return e.map((r,o)=>{let s=n.nodes[r.path],i=Xe(r.path,s,o,t);return r.depIndices!=null&&r.depIndices.length>0&&(i.dep_index=r.depIndices[0],r.depIndices.length>1&&(i.dep_indices=[...r.depIndices])),i})}function Xe(n,e,t,r){let o={path:n,type:e.type,hop:t};e.status!==void 0&&(o.status=e.status),"value"in e&&(o.value=e.value),e.v!=null&&(o.v=e.v);let s=r.annotations?.get(n)??e.annotation;s!=null&&(o.annotation=s);let i=r.lastMutations?.get(n)??e.lastMutation;return i!=null&&(o.lastMutation=i),o}function Qe(n,e,t){return An(n,e,!0,"ok",t)}function Ze(n,e,t){return An(n,e,!1,t,[])}function An(n,e,t,r,o){let s=Fr(n,e,t,r,o);return{from:n,to:e,found:t,reason:r,steps:o,text:s,toJSON(){return{from:n,to:e,found:t,reason:r,steps:o}}}}function Fr(n,e,t,r,o){if(!t)switch(r){case"no-such-from":return`explainPath: no node named "${n}"`;case"no-such-to":return`explainPath: no node named "${e}"`;case"max-depth-exceeded":return`explainPath: no path from "${n}" to "${e}" within maxDepth`;default:return`explainPath: no path from "${n}" to "${e}"`}let s=[`Causal path: ${n} \u2192 ${e} (${o.length} step(s))`];for(let i of o){let u=` ${i.hop===0?"\xB7":"\u2193"} ${i.path} (${i.type}${i.status?`/${i.status}`:""})`;if(s.push(u),"value"in i&&s.push(` value: ${Br(i.value)}`),i.annotation!=null&&s.push(` annotation: ${i.annotation}`),i.lastMutation!=null){let d=i.lastMutation.actor;s.push(` actor: ${d.type}${d.id?`:${d.id}`:""}`)}}return s.join(`
2
- `)}function Br(n){if(n===void 0)return"<sentinel>";if(n===null)return"null";if(typeof n=="string")return JSON.stringify(n);if(typeof n=="number"||typeof n=="boolean"||typeof n=="bigint")return String(n);try{let e=JSON.stringify(n);return e.length>80?`${e.slice(0,77)}...`:e}catch{return String(n)}}var Dn=G(()=>{"use strict"});function $t(n,e){if(Object.is(n,e))return!0;if(n==null||e==null||typeof n!="object"||typeof e!="object")return!1;if(Array.isArray(n)){if(!Array.isArray(e)||n.length!==e.length)return!1;for(let s=0;s<n.length;s++)if(!$t(n[s],e[s]))return!1;return!0}if(Array.isArray(e))return!1;let t=Object.keys(n),r=Object.keys(e);if(t.length!==r.length)return!1;let o=new Set(r);for(let s of t)if(!o.has(s)||!$t(n[s],e[s]))return!1;return!0}function Mn(n,e){return`${n}\0${e}`}function Lt(n,e){let t=[],r=new Set(n.subgraphs),o=new Set(e.subgraphs),s=[];for(let m of o)r.has(m)||s.push(m);s.sort();for(let m of s)t.push({type:"subgraph-mounted",path:m});let i=new Set(Object.keys(n.nodes)),a=new Set(Object.keys(e.nodes)),u=[];for(let m of a)i.has(m)||u.push(m);u.sort();for(let m of u)t.push({type:"node-added",path:m,node:{...e.nodes[m]}});let d=[];for(let m of a){if(!i.has(m))continue;let T=n.nodes[m]?.meta,b=e.nodes[m]?.meta;T==null&&b==null||$t(T??{},b??{})||d.push(m)}d.sort();for(let m of d)t.push({type:"node-meta-changed",path:m,prevMeta:n.nodes[m]?.meta??{},nextMeta:e.nodes[m]?.meta??{}});let c=new Map;for(let m of n.edges)c.set(Mn(m.from,m.to),m);let l=new Map;for(let m of e.edges)l.set(Mn(m.from,m.to),m);let h=[];for(let[m,T]of l)c.has(m)||h.push(T);h.sort((m,T)=>m.from<T.from?-1:m.from>T.from?1:m.to<T.to?-1:m.to>T.to?1:0);for(let m of h)t.push({type:"edge-added",from:m.from,to:m.to});let p=[];for(let[m,T]of c)l.has(m)||p.push(T);p.sort((m,T)=>m.from<T.from?-1:m.from>T.from?1:m.to<T.to?-1:m.to>T.to?1:0);for(let m of p)t.push({type:"edge-removed",from:m.from,to:m.to});let f=[];for(let m of i)a.has(m)||f.push(m);f.sort();for(let m of f)t.push({type:"node-removed",path:m});let g=[];for(let m of r)o.has(m)||g.push(m);g.sort();for(let m of g)t.push({type:"subgraph-unmounted",path:m});return{events:t,flushedAt_ns:X()}}var Gn=G(()=>{"use strict";we()});var ae,Ft=G(()=>{"use strict";ae=class{_timer;_gen=0;start(e,t){this.cancel(),this._gen+=1;let r=this._gen;this._timer=setTimeout(()=>{this._timer=void 0,r===this._gen&&t()},e)}cancel(){this._timer!==void 0&&(clearTimeout(this._timer),this._timer=void 0)}get pending(){return this._timer!==void 0}}});var pe,Bt=G(()=>{"use strict";pe=class{constructor(e){this.capacity=e;if(!Number.isInteger(e)||e<=0)throw new Error(`RingBuffer capacity must be a positive integer (got ${e})`);this.buf=new Array(e)}buf;head=0;_size=0;get size(){return this._size}get maxSize(){return this.capacity}push(e){let t=(this.head+this._size)%this.capacity;this.buf[t]=e,this._size<this.capacity?this._size++:this.head=(this.head+1)%this.capacity}shift(){if(this._size===0)return;let e=this.buf[this.head];return this.buf[this.head]=void 0,this.head=(this.head+1)%this.capacity,this._size--,e}at(e){if(this._size===0)return;let t=e<0?this._size+e:e;if(!(t<0||t>=this._size))return this.buf[(this.head+t)%this.capacity]}toArray(){let e=new Array(this._size);for(let t=0;t<this._size;t++)e[t]=this.buf[(this.head+t)%this.capacity];return e}clear(){for(let e=0;e<this._size;e++)this.buf[(this.head+e)%this.capacity]=void 0;this.head=0,this._size=0}}});function Pn(n,e){let t=e?.topN??10,r=n.describe({detail:"standard"}),o=[],s=n._collectObserveTargets;typeof s=="function"&&s.call(n,"",o);let i=new Map;for(let[h,p]of o)i.set(h,p);let a=[];for(let[h,p]of Object.entries(r.nodes)){let f=i.get(h),g=f instanceof j?f:null,m=g?xn(g.cache):0,T=g?g._sinkCount:0,b=p.deps?.length??0,y=p.type==="effect"&&T===0,v=T===0?p.type==="effect"?"orphan-effect":p.type==="derived"?"idle-derived":p.type==="producer"?"idle-producer":null:null;a.push({path:h,type:p.type,status:p.status??"unknown",valueSizeBytes:m,subscriberCount:T,depCount:b,isOrphanEffect:y,orphanKind:v})}let u=a.reduce((h,p)=>h+p.valueSizeBytes,0),d=(h,p)=>[...a].sort(p??((f,g)=>g[h]-f[h])).slice(0,t),c=a.filter(h=>h.orphanKind!=null),l=a.filter(h=>h.isOrphanEffect);return{nodeCount:a.length,edgeCount:r.edges.length,subgraphCount:r.subgraphs.length,nodes:a,totalValueSizeBytes:u,hotspots:{byValueSize:d("valueSizeBytes"),bySubscriberCount:d("subscriberCount"),byDepCount:d("depCount")},orphans:c,orphanEffects:l}}var In=G(()=>{"use strict";se();En()});function $n(n,e){let t=Math.max(16,n.size*4),r=0;for(;n.size>0;){if(r++>=t){console.error(`[Graph "${e}".destroy] disposer drain exceeded cap (${t}); ${n.size} disposer(s) discarded`),n.clear();return}let o=n.values().next();if(o.done)return;let s=o.value;n.delete(s);try{s()}catch(i){console.error(`[Graph "${e}".destroy] disposer threw:`,i)}}}function jn(n){return n!=null&&typeof n=="object"&&"cache"in n&&typeof n.subscribe=="function"&&typeof n.down=="function"}function Vr(n){if(n!=null)return jn(n)?n.cache:n}function me(n){return n!=null&&typeof n=="object"&&"cache"in n&&typeof n.subscribe=="function"&&typeof n.down=="function"}function ue(n){return me(n)?n.cache??"":n}function Ln(n){return me(n)?n.cache??0:n}function Fn(n){return me(n)?n.cache??!1:n}function jr(n){let e=[];for(let t of Object.keys(n).sort()){let r=n[t].v;r!=null&&e.push(`${t} ${r.id} ${r.version}`)}return e.join(`
3
- `)}function Bn(n){if(n.version!==he)throw new Error(`unsupported snapshot version ${String(n.version)} (expected ${he})`);for(let e of["name","nodes","edges","subgraphs"])if(!(e in n))throw new Error(`snapshot missing required key "${e}"`);if(typeof n.name!="string")throw new TypeError("snapshot 'name' must be a string");if(typeof n.nodes!="object"||n.nodes===null||Array.isArray(n.nodes))throw new TypeError("snapshot 'nodes' must be an object");if(!Array.isArray(n.edges))throw new TypeError("snapshot 'edges' must be an array");if(!Array.isArray(n.subgraphs))throw new TypeError("snapshot 'subgraphs' must be an array")}function zr(n,e){let t=new WeakMap,r=(o,s)=>{if(Object.is(o,s))return!0;if(o==null||s==null||typeof o!="object"||typeof s!="object")return!1;let i=t.get(o);if(i==null&&(i=new WeakSet,t.set(o,i)),i.has(s))return!0;i.add(s);let a=o.constructor,u=s.constructor;if(a!==u)return!1;if(o instanceof Date)return o.getTime()===s.getTime();if(o instanceof RegExp)return o.source===s.source&&o.flags===s.flags;if(Array.isArray(o)){let h=s;if(o.length!==h.length)return!1;for(let p=0;p<o.length;p++)if(!r(o[p],h[p]))return!1;return!0}if(o instanceof Map){let h=s;if(o.size!==h.size)return!1;for(let[p,f]of o)if(!h.has(p)||!r(f,h.get(p)))return!1;return!0}if(o instanceof Set){let h=s;if(o.size!==h.size)return!1;for(let p of o){let f=!1;for(let g of h)if(r(p,g)){f=!0;break}if(!f)return!1}return!0}if(ArrayBuffer.isView(o)){let h=o,p=s;if(h.length!==p.length)return!1;for(let f=0;f<h.length;f++)if(h[f]!==p[f])return!1;return!0}let d=Object.keys(o),c=Object.keys(s);if(d.length!==c.length)return!1;let l=new Set(c);for(let h of d)if(!l.has(h)||!r(o[h],s[h]))return!1;return!0};return r(n,e)}function Ur(n){return n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function et(n){let e="^";for(let t=0;t<n.length;t+=1){let r=n[t];if(r==="*"){e+=".*";continue}if(r==="?"){e+=".";continue}if(r==="["){let o=n.indexOf("]",t+1);if(o<=t+1){e+="\\[";continue}let s=n.slice(t+1,o);s.startsWith("!")&&(s=`^${s.slice(1)}`),s=s.replace(/\\/g,"\\\\"),e+=`[${s}]`,t=o;continue}e+=Ur(r)}return e+="$",new RegExp(e)}function Vt(n){if(typeof n=="string")return JSON.stringify(n);if(typeof n=="number"||typeof n=="boolean"||n==null)return String(n);try{return JSON.stringify(n)}catch{return"[unserializable]"}}function Kr(n){return n==="none"?Hr:n==="ansi"||n==null?Wr:{data:n.data??"",dirty:n.dirty??"",resolved:n.resolved??"",invalidate:n.invalidate??"",pause:n.pause??"",resume:n.resume??"",complete:n.complete??"",error:n.error??"",teardown:n.teardown??"",derived:n.derived??"",path:n.path??"",reset:n.reset??""}}function Vn(n){if(n==null)return{};let e=n.detail;return e==="full"?{...n,structured:n.structured??!0,timeline:n.timeline??!0,causal:n.causal??!0,derived:n.derived??!0}:e==="minimal"?{...n,structured:n.structured??!0}:n.format==="stage-log"?{...n,structured:n.structured??!0,timeline:n.timeline??!0}:n}function qr(n,e,t){for(let r=0;r<n.length;r++){let o=n.charCodeAt(r);if(o<32||o===127)throw new Error(`Graph "${e}": ${t} "${n}" must not contain control character (U+${o.toString(16).padStart(4,"0").toUpperCase()} at index ${r})`)}}function jt(n,e,t){if(n==="")throw new Error(`Graph "${e}": ${t} name must be non-empty`);if(n.includes(L))throw new Error(`Graph "${e}": ${t} "${n}" must not contain '${L}' (path separator)`);if(n===ee)throw new Error(`Graph "${e}": ${t} name "${ee}" is reserved for meta companion paths`);qr(n,e,t)}function Yr(n,e){if(n==="")throw new Error(`Graph "${e}": resolve path must be non-empty`);let t=n.split(L);for(let r of t)if(r==="")throw new Error(`Graph "${e}": resolve path has empty segment`);return t}function Jr(n,e){let t=!1;for(let o of n)if(!e.isMetaPassthrough(o[0])){t=!0;break}return t?n.filter(o=>e.isMetaPassthrough(o[0])):n}function zn(n){for(let e of n._mounts.values())zn(e);for(let e of n._nodes.values())try{e.down([[B]],{internal:!0})}catch{}}function Un(n,e){let t=Ee.diff(n,e),r={};for(let o of t.nodesAdded){let s=e.nodes[o];s!=null&&(r[o]=s)}return{...t,nodesAddedFull:r}}function zt(n,e,t,r={}){let o={paths:[],depths:new Map,truncated:!1};if(!e)return r.withDetail?o:[];if(!r.both&&t!=="upstream"&&t!=="downstream")throw new Error('reachable: direction must be "upstream" or "downstream"');let s=r.maxDepth;if(s!=null&&(!Number.isInteger(s)||s<0))throw new Error("reachable: maxDepth must be an integer >= 0");if(s===0)return r.withDetail?o:[];let i=new Map,a=new Map,u=new Map,d=new Map,c=new Set;for(let[y,v]of Object.entries(n.nodes)){if(!y)continue;c.add(y);let w=v.deps??[];i.set(y,w);for(let _ of w)_&&(c.add(_),a.has(_)||a.set(_,new Set),a.get(_).add(y))}for(let y of n.edges){if(y==null||typeof y!="object")continue;let v=typeof y.from=="string"?y.from:"",w=typeof y.to=="string"?y.to:"";!v||!w||(c.add(v),c.add(w),d.has(v)||d.set(v,new Set),d.get(v).add(w),u.has(w)||u.set(w,new Set),u.get(w).add(v))}if(!c.has(e))return r.withDetail?o:[];let l=r.both===!0,h=y=>{if(l){let R=i.get(y)??[],S=u.get(y),C=a.get(y),A=d.get(y),k=[...R];return S&&k.push(...S),C&&k.push(...C),A&&k.push(...A),k}if(t==="upstream"){let R=i.get(y)??[],S=u.get(y);return S?[...R,...S]:R}let v=a.get(y),w=d.get(y),_=v?[...v]:[];return w&&_.push(...w),_},p=new Set([e]),f=new Map,g=[{path:e,depth:0}],m=0,T=!1;for(;m<g.length;){let y=g[m++];if(s!=null&&y.depth>=s){h(y.path).length>0&&(T=!0);continue}for(let v of h(y.path))!v||p.has(v)||(p.add(v),f.set(v,y.depth+1),g.push({path:v,depth:y.depth+1}))}let b=[...f.keys()].sort((y,v)=>y<v?-1:y>v?1:0);return r.withDetail?{paths:b,depths:f,truncated:T}:b}function Zr(n,e){if(n.length!==e.length)return!1;for(let t=0;t<n.length;t++){let r=n[t],o=e[t];if(r.path!==o.path||r.type!==o.type||r.status!==o.status||r.hop!==o.hop||r.dep_index!==o.dep_index||r.annotation!==o.annotation||r.value!==o.value||r.lastMutation!==o.lastMutation)return!1;let s=r.v,i=o.v;if(s!==i&&(s==null||i==null||s.id!==i.id||s.version!==i.version))return!1}return!0}var L,ee,he,Wr,Hr,Ee,Wn=G(()=>{"use strict";Ot();He();we();qe();ie();$e();se();Je();Gn();tt();Ft();Bt();Nt();Dn();In();L="::",ee="__meta__",he=1;Wr={data:"\x1B[32m",dirty:"\x1B[33m",resolved:"\x1B[36m",invalidate:"\x1B[93m",pause:"\x1B[90m",resume:"\x1B[96m",complete:"\x1B[34m",error:"\x1B[31m",teardown:"\x1B[91m",derived:"\x1B[35m",path:"\x1B[90m",reset:"\x1B[0m"},Hr={data:"",dirty:"",resolved:"",invalidate:"",pause:"",resume:"",complete:"",error:"",teardown:"",derived:"",path:"",reset:""};Ee=class n{name;opts;config;_nodes=new Map;_nodeToName=new WeakMap;_mounts=new Map;_parent=void 0;_storageDisposers=new Set;_disposers=new Set;_destroyed=!1;_topology;_topologyEmitters=new Set;_factory;_factoryArgs;constructor(e,t){if(e==="")throw new Error("Graph name must be non-empty");if(e.includes(L))throw new Error(`Graph name must not contain '${L}' (got "${e}")`);if(e===ee)throw new Error(`Graph name "${ee}" is reserved for meta companion paths`);this.name=e,this.opts=Object.freeze({...t??{}}),this.config=t?.config??xe,this._traceRing=new pe(t?.traceCapacity??1e3),t?.versioning!=null&&this.setVersioning(t.versioning),typeof t?.factory=="string"&&(this._factory=t.factory,t.factoryArgs!==void 0&&(this._factoryArgs=t.factoryArgs))}tagFactory(e,t){return this._factory=e,this._factoryArgs=t,this}ancestors(e=!0){let t=[],r=e?this:this._parent;for(;r!=null;)t.push(r),r=r._parent;return t}get topology(){return this._topology==null&&(this._topology=F(e=>{let t=r=>{e.emit(r)};return this._topologyEmitters.add(t),()=>{this._topologyEmitters.delete(t)}},{name:`${this.name}_topology`})),this._topology}_emitTopology(e){if(!(this._topology==null||this._topologyEmitters.size===0))for(let t of this._topologyEmitters)t(e)}nameOf(e){return this._nodeToName.get(e)}add(e,t){let r=e.name,o=t?.name??r;if(o==null||o==="")throw new Error(`Graph "${this.name}": graph.add requires a non-empty name \u2014 pass via opts.name or set it on the node (e.g. state(0, { name: "x" }))`);let s=o,i=t?.annotation;if(jt(s,this.name,"add"),this._mounts.has(s))throw new Error(`Graph "${this.name}": name "${s}" is already a mount point`);if(this._nodes.has(s))throw new Error(`Graph "${this.name}": node "${s}" already exists`);let a=this._nodeToName.get(e);if(a!==void 0)throw new Error(`Graph "${this.name}": node instance already registered as "${a}"`);return this._nodes.set(s,e),this._nodeToName.set(e,s),this._emitTopology({kind:"added",name:s,nodeKind:"node"}),i!=null&&(this._annotations.set(s,i),this.config.inspectorEnabled&&this._traceRing.push({path:s,annotation:i,timestamp_ns:X()})),e}setVersioning(e){if(e!=null)for(let t of this._nodes.values())t instanceof j&&t._applyVersioning(e)}remove(e){jt(e,this.name,"remove");let t=this._mounts.get(e);if(t){let s={kind:"mount",nodes:[],mounts:[]},i=[];t._collectObserveTargets("",i);for(let[a,u]of i)a.includes(`${L}${ee}${L}`)||s.nodes.push(a);return s.nodes.sort(),s.mounts.push(e),s.mounts.push(...t._collectSubgraphs(`${e}${L}`)),this._mounts.delete(e),t._parent=void 0,zn(t),this._emitTopology({kind:"removed",name:e,nodeKind:"mount",audit:s}),s}let r=this._nodes.get(e);if(!r)throw new Error(`Graph "${this.name}": unknown node or mount "${e}"`);this._nodes.delete(e),this._nodeToName.delete(r),r.down([[B]],{internal:!0});let o={kind:"node",nodes:[e],mounts:[]};return this._emitTopology({kind:"removed",name:e,nodeKind:"node",audit:o}),o}removeAll(e){let t=typeof e=="function"?e:(()=>{let s=et(e);return i=>s.test(i)})(),r={kind:"mount",nodes:[],mounts:[]},o=[...this._nodes.keys(),...this._mounts.keys()].filter(s=>t(s));for(let s of o){let i=this.remove(s);r.nodes.push(...i.nodes),r.mounts.push(...i.mounts)}return r.nodes.sort(),r.mounts.sort(),r}[Symbol.iterator](){let e=[...this._nodes.keys()].sort(),t=this._nodes,r=0;return{[Symbol.iterator](){return this},next(){if(r>=e.length)return{value:void 0,done:!0};let o=e[r++];return{value:[o,t.get(o)],done:!1}}}}node(e){if(e==="")throw new Error(`Graph "${this.name}": node name must be non-empty`);if(e.includes(L))return this.resolve(e);let t=this._nodes.get(e);if(!t)throw new Error(`Graph "${this.name}": unknown node "${e}"`);return t}get(e){return this.node(e).cache}set(e,t,r){let o=r?.internal===!0;this.node(e).down([[x,t]],{actor:r?.actor,internal:o,delivery:"write"})}setAll(e,t){let r=Symbol.iterator in e?e:Object.entries(e);Ge(()=>{for(let[o,s]of r)this.set(o,s,t)})}invalidate(e,t){let r=t?.internal===!0;this.node(e).down([[te]],{actor:t?.actor,internal:r,delivery:"write"})}error(e,t,r){let o=r?.internal===!0;this.node(e).down([[N,t]],{actor:r?.actor,internal:o,delivery:"write"})}complete(e,t){let r=t?.internal===!0;this.node(e).down([[E]],{actor:t?.actor,internal:r,delivery:"write"})}edges(e){let t=e?.recursive===!0,r=new Map;if(!t){for(let[u,d]of this._nodes)r.set(d,u);let a=[];for(let[u,d]of this._nodes)if(d instanceof j)for(let c of d._deps){let l=r.get(c.node);l!=null&&a.push([l,u])}return a.sort((u,d)=>u[0]<d[0]?-1:u[0]>d[0]?1:u[1]<d[1]?-1:u[1]>d[1]?1:0),a}let o=[];this._collectObserveTargets("",o);let s=new Map;for(let[a,u]of o)s.set(u,a);let i=[];for(let[a,u]of o)if(u instanceof j)for(let d of u._deps){let c=s.get(d.node);c!=null&&i.push([c,a])}return i.sort((a,u)=>a[0]<u[0]?-1:a[0]>u[0]?1:a[1]<u[1]?-1:a[1]>u[1]?1:0),i}mount(e,t){if(t===void 0){let o=new n(e);return this.mount(e,o)}if(typeof t=="function"){let o=new n(e);return t(o),this.mount(e,o)}let r=t;if(jt(e,this.name,"mount"),this._nodes.has(e))throw new Error(`Graph "${this.name}": cannot mount at "${e}" \u2014 node with that name exists`);if(this._mounts.has(e))throw new Error(`Graph "${this.name}": mount "${e}" already exists`);if(r===this)throw new Error(`Graph "${this.name}": cannot mount a graph into itself`);if(r._parent!=null)throw new Error(`Graph "${this.name}": this child graph is already mounted on "${r._parent.name}"`);for(let o=this;o!=null;o=o._parent)if(o===r)throw new Error(`Graph "${this.name}": mount("${e}", \u2026) would create a mount cycle`);return this._mounts.set(e,r),r._parent=this,this._emitTopology({kind:"added",name:e,nodeKind:"mount"}),r}resolve(e){let t=Yr(e,this.name);return this._resolveFromSegments(t)}tryResolve(e){try{return this.resolve(e)}catch{return}}_resolveFromSegments(e){let t=e;if(t[0]===this.name&&(t=t.slice(1),t.length===0))throw new Error(`Graph "${this.name}": resolve path ends at graph name only`);let r=t[0],o=t.slice(1);if(o.length===0){let a=this._nodes.get(r);if(a)return a;throw this._mounts.has(r)?new Error(`Graph "${this.name}": path ends at subgraph "${r}" \u2014 not a node (GRAPHREFLY-SPEC \xA73.5)`):new Error(`Graph "${this.name}": unknown name "${r}"`)}let s=this._nodes.get(r);if(s&&o.length>0&&o[0]===ee)return this._resolveMetaChainFromNode(s,o,t.join(L));let i=this._mounts.get(r);if(!i)throw this._nodes.has(r)?new Error(`Graph "${this.name}": "${r}" is a node; trailing path "${o.join(L)}" is invalid`):new Error(`Graph "${this.name}": unknown mount or node "${r}"`);return i.resolve(o.join(L))}_resolveMetaChainFromNode(e,t,r){let o=e,s=0,i=[...t];for(;s<i.length;){if(i[s]!==ee)throw new Error(`Graph "${this.name}": expected ${ee} segment in meta path "${r}"`);if(s+1>=i.length)throw new Error(`Graph "${this.name}": meta path requires a key after ${ee} in "${r}"`);let a=i[s+1],u=o.meta[a];if(!u)throw new Error(`Graph "${this.name}": unknown meta "${a}" in path "${r}"`);o=u,s+=2}return o}signal(e,t){if(t?.internal!==!0){for(let o of e)if(this.config.messageTier(o[0])===3)throw new Error(`Graph "${this.name}": Graph.signal() rejects tier-3 messages (DATA / RESOLVED). Broadcast is for control-plane tiers (START / DIRTY / INVALIDATE / PAUSE / RESUME / COMPLETE / ERROR / TEARDOWN). For per-node value writes, use Graph.set or graph.node(name).down(...).`)}let r=[];if(this._signalDeliver(e,t??{},new Set,r),r.length>0)throw r[0]}_signalDeliver(e,t,r,o){for(let u of this._mounts.values())u._signalDeliver(e,t,r,o);let i=t.internal===!0?{internal:!0}:{actor:t.actor,delivery:"signal"},a=Jr(e,this.config);for(let u of[...this._nodes.keys()].sort()){let d=this._nodes.get(u);if(!r.has(d)){r.add(d);try{d.down(e,i)}catch(c){if(c instanceof Q)throw c;o.push(c)}a.length!==0&&this._signalMetaSubtree(d,a,r,i,o)}}}_signalMetaSubtree(e,t,r,o,s){for(let i of Object.keys(e.meta).sort()){let a=e.meta[i];if(!r.has(a)){r.add(a);try{a.down(t,o)}catch(u){if(u instanceof Q)throw u;s.push(u)}this._signalMetaSubtree(a,t,r,o,s)}}}describe(e){if(e?.reactive==="diff")return this._describeReactiveDiff(e);if(e?.reactive===!0)return this._describeReactive(e);let t=Vr(e?.actor),r=e?.filter;if(e?.detail!=null&&e?.fields!=null)throw new TypeError("Graph.describe(): pass either `detail` or `fields`, not both. `detail: 'spec'` is the canonical spec projection; use `fields` only when you need a custom subset.");let o=Pt(e?.detail,e?.fields),s=e?.detail==="spec",i=o,a=[];this._collectObserveTargets("",a);let u=new Map;for(let[v,w]of a)u.set(w,v);let d=[];{let v=a.map(([,R])=>R),w=new Set(u.values()),_=0;for(;v.length>0;){let R=v.shift();if(R instanceof j)for(let S of R._deps){let C=S.node;if(u.has(C))continue;let A=C.name??"",k=A;if(!k||w.has(k))if(A){let U=2;for(;w.has(`${A}#${U}`);)U++;k=`${A}#${U}`}else for(k=`__internal__/${_++}`;w.has(k);)k=`__internal__/${_++}`;u.set(C,k),w.add(k),d.push([k,C]),v.push(C)}}}let c=[...a,...d],l={};for(let[v,w]of c){if(t!=null&&!w.allowsObserve(t))continue;let _=It(w,i,s),R=w instanceof j?w._deps.map(k=>u.get(k.node)??k.node.name??""):[],{name:S,...C}=_,A={...C,deps:R};if(!s){let k=this._annotations.get(v);k!=null&&(A.annotation=k)}if(r!=null)if(typeof r=="function"){let k=r;if(!(k.length>=2?k(v,A):k(A)))continue}else{let k=!0;for(let[U,V]of Object.entries(r)){let I=U==="deps_includes"?"depsIncludes":U==="meta_has"?"metaHas":U;if(I==="depsIncludes"){if(!A.deps.includes(String(V))){k=!1;break}continue}if(I==="metaHas"){if(!Object.hasOwn(A.meta??{},String(V))){k=!1;break}continue}if(A[I]!==V){k=!1;break}}if(!k)continue}l[v]=A}let h=new Set(Object.keys(l)),p=[];for(let[v,w]of c)if(w instanceof j)for(let _ of w._deps){let R=u.get(_.node);R!=null&&p.push([R,v])}p.sort((v,w)=>v[0]<w[0]?-1:v[0]>w[0]?1:v[1]<w[1]?-1:v[1]>w[1]?1:0);let f=p.map(([v,w])=>({from:v,to:w}));(t!=null||r!=null)&&(f=f.filter(v=>h.has(v.from)&&h.has(v.to)));let g=this._collectSubgraphs(""),m=t!=null||r!=null?g.filter(v=>{let w=`${v}${L}`;return[...h].some(_=>_===v||_.startsWith(w))}):g,T=this,b=e;return{name:this.name,nodes:l,edges:f,subgraphs:m,...this._factory!==void 0?{factory:this._factory}:{},...this._factoryArgs!==void 0?{factoryArgs:this._factoryArgs}:{},expand(v){let w={...b};return Array.isArray(v)?(w.fields=v,w.detail=void 0):(w.detail=v,w.fields=void 0),T.describe(w)}}}_collectSubgraphs(e){let t=[];for(let r of[...this._mounts.keys()].sort()){let o=e===""?r:`${e}${r}`;t.push(o),t.push(...this._mounts.get(r)._collectSubgraphs(`${o}${L}`))}return t}resourceProfile(e){return Pn(this,e)}reachable(e,t,r={}){return r.withDetail===!0?zt(this.describe(),e,t,{...r,withDetail:!0}):zt(this.describe(),e,t,r)}explain(e,t,r){return r?.reactive===!0?this._explainReactive(e,t,r):this._explainStatic(ue(e),ue(t),{...r?.maxDepth!==void 0?{maxDepth:Ln(r.maxDepth)}:{},...r?.findCycle!==void 0?{findCycle:Fn(r.findCycle)}:{}})}_explainStatic(e,t,r){let o=this.describe({detail:"full"}),s=new Map(this._annotations),i=new Map;for(let[a,u]of Object.entries(o.nodes))u.lastMutation!=null&&i.set(a,u.lastMutation);return Rn(o,e,t,{...r?.maxDepth!=null?{maxDepth:r.maxDepth}:{},...r?.findCycle===!0?{findCycle:!0}:{},annotations:s,lastMutations:i})}_describeReactive(e){let t={...e,reactive:!1},r=e.reactiveName??"describe",o=0,s=fe(o,{name:`${r}_version`}),i=this.observe({timeline:!0,structured:!0}),a=!1,u=!1,d=()=>{a||u||(a=!0,ke(()=>{a=!1,!u&&(o+=1,s.emit(o))}))},c=i.onEvent(b=>{let y=b.type;y!=="data"&&y!=="error"&&y!=="complete"&&y!=="teardown"||d()}),l=[],h=new WeakSet,p=b=>{if(h.has(b)||u)return;h.add(b);let y=b.topology.subscribe(v=>{for(let w of v){if(w[0]!==x)continue;let _=w[1];if(d(),_.kind==="added"&&_.nodeKind==="mount"){let R=b._mounts.get(_.name);R!=null&&p(R)}}});l.push(y);for(let v of b._mounts.keys()){let w=b._mounts.get(v);w!=null&&p(w)}};p(this);let f,g=e.actor;jn(g)&&(f=g.subscribe(b=>{let y=!1,v=!1;for(let w of b){let _=w[0];_===x?y=!0:(_===E||_===N||_===B)&&(v=!0)}y&&d(),v&&(f?.(),f=void 0,d())}));let m;try{m=At([s],()=>this.describe(t),{name:r,describeKind:"derived",meta:{domain:"audit",kind:"describe"},equals:(b,y)=>b===y})}catch(b){c(),f?.();for(let y of l)y();throw i.dispose(),b}let T=Le(m);return{node:m,dispose(){u=!0,c(),f?.();for(let b of l)b();l.length=0,i.dispose(),T()}}}_describeReactiveDiff(e){let t={...e,reactive:!1},r=e.reactiveName??"describe-diff",o={name:this.name,nodes:{},edges:[],subgraphs:[]},s=this.describe(t),i=Lt(o,s),a=fe(i,{name:r,meta:{domain:"audit",kind:"describe-diff"},equals:(h,p)=>h===p}),u=this._describeReactive({...e,reactiveName:void 0}),d=!1,c=u.node.subscribe(h=>{if(!d)for(let p of h){if(p[0]!==x)continue;let f=p[1],g=Lt(s,f);s=f,g.events.length!==0&&a.emit(g)}}),l=Le(a);return{node:a,dispose(){d=!0,c(),u.dispose(),a.down([[B,"describe-diff disposed"]]),l()}}}_explainReactive(e,t,r){let o=0,s=fe(o,{name:"explain_version"}),i=this.observe({timeline:!0,structured:!0}),a=!1,u=!1,d=()=>{a||u||(a=!0,ke(()=>{a=!1,!u&&(o+=1,s.emit(o))}))},c=i.onEvent(b=>{let y=b.type;y!=="data"&&y!=="error"&&y!=="complete"&&y!=="teardown"||d()}),l=[];e!=null&&me(e)&&l.push(e),t!=null&&me(t)&&l.push(t),r?.maxDepth!=null&&me(r.maxDepth)&&l.push(r.maxDepth),r?.findCycle!=null&&me(r.findCycle)&&l.push(r.findCycle);let h=()=>{for(let b of l)if(b.cache===void 0)return!1;return!0},p=()=>{let b=ue(e),y=ue(t);return{from:b,to:y,found:!1,reason:"pending",steps:[],text:"(awaiting reactive args)",toJSON:()=>({from:b,to:y,found:!1,reason:"pending",steps:[]})}},f;try{f=At([s],()=>{if(!h())return p();let b=ue(e),y=ue(t),v={...r?.maxDepth!==void 0?{maxDepth:Ln(r.maxDepth)}:{},...r?.findCycle!==void 0?{findCycle:Fn(r.findCycle)}:{}};return this._explainStatic(b,y,v)},{name:r?.name??"explain",describeKind:"derived",meta:{domain:"audit",kind:"explain_path",from:ue(e),to:ue(t)},equals:(b,y)=>b.found===y.found&&b.reason===y.reason&&b.steps.length===y.steps.length&&Zr(b.steps,y.steps)})}catch(b){throw c(),i.dispose(),b}let g=Le(f),m=[],T=b=>{let y;return y=b.subscribe(v=>{let w=!1,_=!1;for(let R of v){let S=R[0];S===x?w=!0:(S===E||S===N||S===B)&&(_=!0)}(w||_)&&d(),_&&y&&(y(),y=void 0)}),()=>{y&&(y(),y=void 0)}};for(let b of l)m.push(T(b));return{node:f,dispose(){u=!0,c();for(let b of m)b?.();m.length=0,i.dispose(),g()}}}_pathsMatching(e){let t=et(e),r=[];return this._collectObserveTargets("",r),r.map(([o])=>o).filter(o=>t.test(o))}_collectObserveTargets(e,t){for(let r of[...this._mounts.keys()].sort()){let o=e===""?r:`${e}${L}${r}`;this._mounts.get(r)._collectObserveTargets(o,t)}for(let r of[...this._nodes.keys()].sort()){let o=this._nodes.get(r),s=e===""?r:`${e}${L}${r}`;t.push([s,o]),this._appendMetaObserveTargets(s,o,t)}}_appendMetaObserveTargets(e,t,r){for(let o of Object.keys(t.meta).sort()){let s=t.meta[o],i=`${e}${L}${ee}${L}${o}`;r.push([i,s]),this._appendMetaObserveTargets(i,s,r)}}observe(e,t){let r=typeof e=="string",s=Vn(r?t:e);if(s.reactive===!0)return this._observeReactive(r?e:void 0,s);let i=s.structured===!0||s.timeline===!0||s.causal===!0||s.derived===!0||s.detail==="minimal"||s.detail==="full"||s.format!=null,a=s.actor;if(r){let c=e,l=this.resolve(c);if(a!=null&&!l.allowsObserve(a))throw new Q({actor:a,action:"observe",nodeName:c});return i?this._buildStructuredObserver([[c,l]],s,"one"):{subscribe(h){return l.subscribe(h)},up(h){try{l.up?.(h)}catch(p){if(p instanceof Q)return;throw p}}}}let u=[];this._collectObserveTargets("",u),u.sort((c,l)=>c[0]<l[0]?-1:c[0]>l[0]?1:0);let d=a==null?u:u.filter(([,c])=>c.allowsObserve(a));return i?this._buildStructuredObserver(d,s,"all"):{subscribe:c=>{let l=d.map(([h,p])=>p.subscribe(f=>{c(h,f)}));return()=>{for(let h of l)h()}},up:(c,l)=>{try{this.resolve(c).up?.(l)}catch(h){if(h instanceof Q)return;throw h}}}}_observeReactive(e,t){let r=t.tiers,o=r!=null?new Set(r):null,s=t.reactiveName??"observe";return F(i=>{let a=[],u=!1,d=!1,c=()=>{if(a.length===0||d)return;let g={events:a.slice(),flushedAt_ns:X()};a.length=0,i.emit(g)},l={...t,reactive:!1,structured:!0,timeline:!0},h=e!=null?this.observe(e,l):this.observe(l),p=g=>{d||(a.push(g),!u&&(u=!0,ke(()=>{u=!1,c()})))};for(let g of h.events)p(g);let f=h.onEvent(p);return()=>{d=!0,f(),h.dispose()}},{name:s,meta:{domain:"audit",kind:"observe-reactive"}})}_buildStructuredObserver(e,t,r){let o=r==="one"?e[0]?.[0]:void 0,s=i=>{if(r==="one"&&o!=null){let c=this.resolve(o);return this._buildStructuredObserver([[o,c]],i,"one")}let a=[];this._collectObserveTargets("",a),a.sort((c,l)=>c[0]<l[0]?-1:c[0]>l[0]?1:0);let u=i.actor,d=u==null?a:a.filter(([,c])=>c.allowsObserve(u));return this._buildStructuredObserver(d,i,"all")};return this._createObserveResult(e,t,s)}_createObserveResult(e,t,r){let o=t.timeline===!0,s=t.causal===!0,i=t.derived===!0,a=t.detail==="minimal",u=this.config.inspectorEnabled,d=(s||i)&&u,c=t.maxEvents,l=c!=null&&c>0?new pe(c):null,h=[],p=new Set,f=t.tiers!=null?new Set(t.tiers):null,g={},m=new Set,T=0,b=0,y=0,v=0,w=0,_=0,R=!1,S=!1,C=0,A=new Map,k=new Map,U=new Map,V=O=>{if(!(f!=null&&!f.has(O.type))){l?l.push(O):h.push(O);for(let $ of p)$(O)}},I=O=>f==null||f.has(O),ye=()=>o?{timestamp_ns:X(),in_batch:Ue(),batch_id:C}:{},lt=(O,$)=>{if(!(!d||!(O instanceof j)))return O._setInspectorHook(J=>{if(J.kind==="dep_message")A.set(O,J.depIndex);else if(J.kind==="run"){let Ae=J.batchData.map((P,K)=>P!=null&&P.length>0?P.at(-1):J.prevData[K]);k.set(O,Ae);let Z=J.batchData.map(P=>P!=null?[...P]:void 0);U.set(O,Z),i&&V({type:"derived",path:$,dep_values:Ae,dep_batches:Z,...ye()})}})},Ve=O=>{let $=A.get(O),J=k.get(O);if(!s||J==null)return{};let Z=($!=null&&$>=0&&O instanceof j?O._deps[$]:void 0)?.node,P=Z?.v,K=U.get(O);return{trigger_dep_index:$,trigger_dep_name:Z?.name,...P!=null?{trigger_version:{id:P.id,version:P.version}}:{},dep_values:[...J],...K!=null?{dep_batches:K}:{}}},en=[],tn=[];for(let[O,$]of e){let J=lt($,O);J&&en.push(J),tn.push($.subscribe(Ae=>{C++;for(let Z of Ae){let P=Z[0],K=ye();if(P===x){g[O]=Z[1];let mt=$ instanceof j?$.lastMutation?.actor??_e:_e;V({type:"data",path:O,data:Z[1],actor:mt,...K,...Ve($)})}else if(a)P===M?I("dirty")&&T++:P===D?I("resolved")&&b++:P===te?I("invalidate")&&y++:P===q?I("pause")&&v++:P===ne?I("resume")&&w++:P===B?I("teardown")&&_++:P===E&&!m.has(O)?I("complete")&&(R=!0):P===N&&I("error")&&(S=!0,m.add(O));else if(P===M)I("dirty")&&T++,V({type:"dirty",path:O,...K});else if(P===D)I("resolved")&&b++,V({type:"resolved",path:O,...K,...Ve($)});else if(P===te)I("invalidate")&&y++,V({type:"invalidate",path:O,...K});else if(P===q)I("pause")&&v++,V({type:"pause",path:O,lockId:Z[1],...K});else if(P===ne)I("resume")&&w++,V({type:"resume",path:O,lockId:Z[1],...K});else if(P===E)I("complete")&&!m.has(O)&&(R=!0),V({type:"complete",path:O,...K});else if(P===N){I("error")&&(S=!0,m.add(O));let mt=$ instanceof j?$.lastMutation?.actor??_e:_e;V({type:"error",path:O,data:Z[1],actor:mt,...K})}else P===B&&(I("teardown")&&_++,V({type:"teardown",path:O,...K}))}}))}let ft=!1,pt=()=>{if(!ft){ft=!0;for(let O of tn)O();for(let O of en)O();for(let O of je)O({value:void 0,done:!0});je.length=0}},ht=[],je=[];p.add(O=>{let $=je.shift();$?$({value:O,done:!1}):ht.push(O)});let nn={get values(){return g},get dirtyCount(){return T},get resolvedCount(){return b},get invalidateCount(){return y},get pauseCount(){return v},get resumeCount(){return w},get teardownCount(){return _},get events(){return l?l.toArray():[...h]},get anyCompletedCleanly(){return R},get anyErrored(){return S},get completedWithoutErrors(){return R&&!S},onEvent(O){return p.add(O),()=>p.delete(O)},dispose:pt,expand(O){pt();let $={...t};return typeof O=="string"?$.detail=O:Object.assign($,O),r(Vn($))},[Symbol.asyncIterator](){return{next(){return ht.length>0?Promise.resolve({value:ht.shift(),done:!1}):ft?Promise.resolve({value:void 0,done:!0}):new Promise(O=>je.push(O))},return(){return pt(),Promise.resolve({value:void 0,done:!0})}}}};return t.format!=null&&this._attachFormatLogger(nn,t),nn}_attachFormatLogger(e,t){let r=t.format;if(r==null)return;let o=t.logger??(f=>console.log(f)),s=t.includeTypes?new Set(t.includeTypes):null,i=t.excludeTypes?new Set(t.excludeTypes):null,a=s==null&&i==null?()=>!0:f=>(s==null||s.has(f))&&(i==null||!i.has(f)),u=Kr(t.theme),d=r==="stage-log"?X():0,c=f=>f==null?"":t.stageLabels?.[f]??f,l=(f,g)=>f.length>g?`${f.slice(0,g-1)}\u2026`:f,h=f=>f.type==="data"||f.type==="error"?l(Vt(f.data),120):"",p=f=>{if(r==="stage-log"){let R=(X()-d)/1e9,S=c(f.path).padEnd(9);if(f.type==="data"){let C=h(f);return`[${R.toFixed(3)}s] ${S} \u2190${C?` ${C}`:""}`}if(f.type==="error"){let C=h(f);return`[${R.toFixed(3)}s] ${S} \u2717${C?` ${C}`:""}`}return f.type==="complete"?`[${R.toFixed(3)}s] ${S} \u25A0 complete`:`[${R.toFixed(3)}s] ${S} ${f.type}`}if(r==="json")try{return JSON.stringify(f)}catch{return JSON.stringify({type:f.type,path:f.path,data:"[unserializable]"})}let g=u[f.type]??"",m=f.path?`${u.path}${f.path}${u.reset} `:"",T=f.type==="data"||f.type==="error",b=f.type==="pause"||f.type==="resume",y=T?` ${Vt(f.data)}`:b?` ${Vt(f.lockId)}`:"",v=f.type==="data"||f.type==="resolved"||f.type==="derived"?f:void 0,w=v?.trigger_dep_name!=null?` <- ${v.trigger_dep_name}`:v?.trigger_dep_index!=null?` <- #${v.trigger_dep_index}`:"",_=f.in_batch?" [batch]":"";return`${m}${g}${f.type.toUpperCase()}${u.reset}${y}${w}${_}`};e.onEvent(f=>{a(f.type)&&o(p(f),f)})}addDisposer(e){return this._disposers.add(e),()=>{this._disposers.delete(e)}}destroy(){$n(this._disposers,this.name),this.signal([[B]],{internal:!0}),$n(this._storageDisposers,this.name);for(let e of[...this._mounts.values()])e._parent=void 0,e._destroyClearOnly();this._mounts.clear(),this._nodes.clear(),this._parent=void 0,this._destroyed=!0}get destroyed(){return this._destroyed}_destroyClearOnly(){for(let e of[...this._mounts.values()])e._parent=void 0,e._destroyClearOnly();this._mounts.clear(),this._nodes.clear(),this._parent=void 0,this._destroyed=!0}snapshot(e){let{expand:t,...r}=this.describe({detail:"full"}),o={};for(let a of Object.keys(r.nodes).sort()){let{lastMutation:u,guard:d,...c}=r.nodes[a];o[a]=c}let s=[...r.subgraphs].sort(),i={...r,version:1,nodes:o,subgraphs:s};if(e?.format==null)return i;if(e.format==="json-string")return JSON.stringify(i);if(e.format==="bytes"){if(e.codec==null)throw new Error("snapshot({format: 'bytes'}) requires a `codec` name");let a=this.config.lookupCodec(e.codec);if(a==null)throw new Error(`snapshot: codec "${e.codec}" is not registered on this graph's config. Call config.registerCodec(...) before creating nodes.`);return un(a,a.encode(i))}throw new Error(`snapshot: unknown format "${String(e.format)}"`)}static decode(e,t){let r=t?.config??xe,{codec:o,codecVersion:s,payload:i}=dn(e,r);return o.decode(i,s)}restore(e,t){if(Bn(e),e.name!==this.name)throw new Error(`Graph "${this.name}": restore snapshot name "${e.name}" does not match this graph`);let r=t?.only==null?null:(Array.isArray(t.only)?t.only:[t.only]).map(s=>et(s)),o=t?.includeProducers===!0;for(let s of Object.keys(e.nodes).sort()){if(r!==null&&!r.some(a=>a.test(s)))continue;let i=e.nodes[s];if(i!==void 0){if(!("value"in i)||i.value===void 0){"value"in i&&i.value===void 0&&t?.onError?.(s,new Error(`restore: slice.value is undefined for "${s}" (undefined is the global SENTINEL; not valid DATA)`));continue}if(!(i.type==="derived"||i.type==="effect")&&!(i.type==="producer"&&!o)){if(i.v!=null){let u=this.tryResolve(s)?.v;if(u!=null&&u.id===i.v.id&&u.version===i.v.version)continue}try{this.set(s,i.value)}catch(a){t?.onError?.(s,a)}}}}}static fromSnapshot(e,t){Bn(e);let r=typeof t=="function"?t:t?.build,o=typeof t=="function"?void 0:t?.factories,s=new n(e.name);if(r)return r(s),s.restore(e),s;for(let p of[...e.subgraphs].sort((f,g)=>{let m=f.split(L).length,T=g.split(L).length;return m!==T?m-T:f<g?-1:f>g?1:0})){let f=p.split(L),g=s;for(let m of f)g._mounts.has(m)||g.mount(m,new n(m)),g=g._mounts.get(m)}let i=o?Object.entries(o).map(([p,f])=>({re:et(p),factory:f})):[],a=p=>{for(let f of i)if(f.re.test(p))return f.factory},u=p=>{let f=p.split(L),g=f.pop();if(g==null||g.length===0)throw new Error(`invalid snapshot path "${p}"`);let m=s;for(let T of f){let b=m._mounts.get(T);if(!b)throw new Error(`unknown mount "${T}" in path "${p}"`);m=b}return[m,g]},d=Object.entries(e.nodes).filter(([p])=>!p.includes(`${L}${ee}${L}`)).sort((p,f)=>p[0]<f[0]?-1:p[0]>f[0]?1:0),c=new Map(d),l=new Map,h=!0;for(;c.size>0&&h;){h=!1;for(let[p,f]of[...c.entries()]){let g=f?.deps??[];if(!g.every(w=>l.has(w)))continue;let[m,T]=u(p),b={...f?.meta??{}},y=a(p),v;if(f?.type==="state")v=fe(f.value,{meta:b});else{if(y==null)continue;v=y(T,{path:p,type:f.type,value:f.value,meta:b,deps:g,resolvedDeps:g.map(w=>l.get(w))})}m.add(v,{name:T}),l.set(p,v),c.delete(p),h=!0}}if(c.size>0){let p=[...c.keys()].sort().join(", ");throw new Error(`Graph.fromSnapshot could not reconstruct nodes without build callback: ${p}. Pass matching factories via fromSnapshot(data, { factories: { pattern: factoryFn } }).`)}return s.restore(e),s}toJSON(){return this.snapshot()}attachSnapshotStorage(e,t={}){let r=e.map(d=>({tier:d,debounceMs:Math.max(0,d.debounceMs??0),compactEvery:Math.max(1,d.compactEvery??10),timer:void 0,seq:0,lastSnapshot:void 0,lastFingerprint:"",disposed:!1,savePending:void 0}));t.autoRestore===!0&&this._cascadeRestore(e,t.onError);let o=(d,c)=>{if(d.disposed)return;let l=jr(c.nodes);if(d.lastSnapshot!=null&&l!==""&&l===d.lastFingerprint)return;let h=d.seq+1,p=ve(),m=d.lastSnapshot==null||h%d.compactEvery===0?{name:this.name,mode:"full",snapshot:c,seq:h,timestamp_ns:p,format_version:he}:{name:this.name,mode:"diff",diff:Un(d.lastSnapshot,c),seq:h,timestamp_ns:p,format_version:he};if(d.tier.filter&&!d.tier.filter(m))return;let T;try{T=d.tier.save(m)}catch(b){t.onError?.(b,d.tier);return}if(T&&typeof T.then=="function"){let v=(d.savePending??Promise.resolve()).then(()=>T,()=>T).then(()=>{d.disposed||(d.seq=h,d.lastSnapshot=c,d.lastFingerprint=l)},w=>{t.onError?.(w,d.tier)});d.savePending=v.finally(()=>{d.savePending===v&&(d.savePending=void 0)})}else d.seq=h,d.lastSnapshot=c,d.lastFingerprint=l},s=(d,c)=>{try{o(d,c)}catch(l){t.onError?.(l,d.tier)}},i=(d,c)=>{if(!c.some(f=>{let g=this.config.messageTier(f[0]);return g>=3&&g<5}))return;if(t.filter){let f=this.tryResolve(d);if(f==null)return;let g=It(f,Pt("standard"));if(!t.filter(d,g))return}let h,p=()=>(h==null&&(h=this.snapshot()),h);for(let f of r)f.disposed||(f.debounceMs===0?s(f,p()):(f.timer==null&&(f.timer=new ae),f.timer.start(f.debounceMs,()=>{f.disposed||s(f,this.snapshot())})))},a;if(t.paths!=null){let c=(typeof t.paths=="string"?this._pathsMatching(t.paths):t.paths).map(l=>{let h=this.tryResolve(l);return h==null?()=>{}:h.subscribe(p=>i(l,p))});a=()=>{for(let l of c)l()}}else a=this.observe().subscribe((d,c)=>i(d,c));let u=()=>{a();for(let d of r)d.disposed=!0,d.timer?.cancel();this._storageDisposers.delete(u)};return this._storageDisposers.add(u),{dispose:u}}async _cascadeRestore(e,t){for(let r of e){let o;try{o=await r.load?.()}catch(i){t?.(i,r);continue}if(o==null||typeof o!="object"||Array.isArray(o))continue;let s=o;try{if(s.mode==="full"&&s.snapshot!=null)return this.restore(s.snapshot),!0;if(s.version===he&&s.nodes!=null)return this.restore(s),!0}catch(i){t?.(i,r)}}return!1}static async fromStorage(e,t,r){for(let o of t){let s;try{s=await o.load?.()}catch(u){r?.onError?.(u,o);continue}if(s==null||typeof s!="object"||Array.isArray(s))continue;let i=s,a=i.mode==="full"&&i.snapshot!=null?i.snapshot:i.version===he&&i.nodes!=null?i:void 0;if(a!=null)try{return n.fromSnapshot(a,r)}catch(u){r?.onError?.(u,o)}}throw new Error(`Graph.fromStorage: no tier held a restorable record for "${e}" across ${t.length} tier(s)`)}_annotations=new Map;_traceRing;trace(e,t,r){if(e!=null&&t!=null){if(this.tryResolve(e)==null)return;if(this._annotations.set(e,t),this.config.inspectorEnabled){let o={path:e,annotation:t,timestamp_ns:X(),...r?.actor!=null?{actor:r.actor}:{}};this._traceRing.push(o)}return}return e!=null?this.config.inspectorEnabled?this._annotations.get(e):void 0:this.config.inspectorEnabled?this._traceRing.toArray():[]}annotation(e){return this._annotations.get(e)}clearTrace(){this._annotations.clear(),this._traceRing.clear()}pruneTrace(e){let t=this._traceRing.toArray().filter(o=>!e(o)),r=this._traceRing.size-t.length;this._traceRing.clear();for(let o of t)this._traceRing.push(o);return r}static diff(e,t){let r=new Set(Object.keys(e.nodes)),o=new Set(Object.keys(t.nodes)),s=[...o].filter(b=>!r.has(b)).sort(),i=[...r].filter(b=>!o.has(b)).sort(),a=[],u=[];for(let b of r){if(!o.has(b))continue;let y=e.nodes[b],v=t.nodes[b],w=y.v,_=v.v;w!=null&&_!=null&&w.id===_.id&&w.version!==_.version&&u.push({path:b,id:w.id,from:w.version,to:_.version});let R=w!=null&&_!=null&&w.id===_.id&&w.version===_.version;for(let S of["type","status","sentinel"]){let C=y[S],A=v[S];C!==A&&a.push({path:b,field:S,from:C,to:A})}if(!R)for(let S of["value","meta"]){let C=y[S],A=v[S];zr(C,A)||a.push({path:b,field:S,from:C,to:A})}}let d=b=>`${b.from} ${b.to}`,c=new Set(e.edges.map(d)),l=new Set(t.edges.map(d)),h=t.edges.filter(b=>!c.has(d(b))),p=e.edges.filter(b=>!l.has(d(b))),f=new Set(e.subgraphs),g=new Set(t.subgraphs),m=[...g].filter(b=>!f.has(b)).sort(),T=[...f].filter(b=>!g.has(b)).sort();return{nodesAdded:s,nodesRemoved:i,nodesChanged:a,versionChanges:u,edgesAdded:h,edgesRemoved:p,subgraphsAdded:m,subgraphsRemoved:T}}}});var Hn=G(()=>{"use strict";Wn()});var Xn={};bt(Xn,{NS_PER_MS:()=>de,NS_PER_SEC:()=>Re,constant:()=>Kn,decorrelatedJitter:()=>Zn,exponential:()=>Yn,fibonacci:()=>Jn,linear:()=>qn,resolveBackoffPreset:()=>Ut,withMaxAttempts:()=>eo});function ge(n){return n<0?0:n}function Xr(n,e){return e==="none"?n:e==="full"?Math.random()*n:n/2+Math.random()*(n/2)}function Qr(n,e){return n+Math.random()*(e-n)}function Kn(n){let e=ge(n);return()=>e}function qn(n,e){let t=ge(n),r=e===void 0?t:ge(e);return o=>t+r*Math.max(0,o)}function Yn(n){let e=ge(n?.baseNs??1e8),t=n?.factor!==void 0&&n.factor<1?1:n?.factor??2,r=ge(n?.maxDelayNs??30*1e9),o=n?.jitter??"none";return s=>{let i;if(e===0)i=0;else if(t===1)i=e;else{let a=r/e,u=1;for(let d=0;d<Math.max(0,s);d++){if(u>=a){u=a;break}u*=t}i=e*u,i>r&&(i=r)}return Xr(i,o)}}function Jn(n=100*1e6,e=30*1e9){let t=ge(n),r=ge(e);function o(s){if(s<=0)return 1;let i=1,a=2;for(let u=1;u<s;u++){let d=i+a;i=a,a=d}return a}return s=>{let i=o(s)*t;return i<=r?i:r}}function Zn(n=100*1e6,e=30*1e9){return(t,r,o)=>{let i=Math.min(e,(o??n)*3);return Qr(n,i)}}function eo(n,e){return(t,r,o)=>t>=e?null:n(t,r,o)}function Ut(n){if(n==="constant")return Kn(1*1e9);if(n==="linear")return qn(1*1e9);if(n==="exponential")return Yn();if(n==="fibonacci")return Jn();if(n==="decorrelatedJitter")return Zn();throw new Error(`Unknown backoff preset: "${String(n)}". Use one of: constant, linear, exponential, fibonacci, decorrelatedJitter`)}var de,Re,Wt=G(()=>{"use strict";de=1e6,Re=1e9});function to(n){return{describeKind:"derived",...n}}function no(n,e,t){let r,o=!1,s=()=>{o||(o=!0,t())};return r=n.subscribe(i=>{let a=!1,u=!1;for(let d of i)d[0]!==oe&&(d[0]===x?e.emit(d[1]):d[0]===E?a=!0:d[0]===N?(u=!0,e.down([d])):(d[0]===M||d[0]===D)&&e.down([d]));u?(r?.(),r=void 0,s()):a&&s()}),()=>{r?.(),r=void 0}}function Se(n,e,t){let r,o=!1;function s(){r?.(),r=void 0}return W([n],(i,a,u)=>{if(u.terminalDeps[0]!=null&&u.terminalDeps[0]!==!0){s();return}if(u.terminalDeps[0]===!0){o=!0,r||a.down([[E]]);return}let d=i[0];if(!(d==null||d.length===0))return s(),r=no(Ce(e(d[d.length-1])),a,()=>{s(),o&&a.down([[E]])}),{deactivate:()=>{s(),o=!1}}},{...to(t),completeWhenDepsComplete:!1,meta:{...re("switchMap"),...t?.meta??{}}})}var Qn=G(()=>{"use strict";ie();$e();se();tt()});var er=G(()=>{"use strict";Qn()});function Fe(n){return typeof n=="object"&&n!==null&&"subscribe"in n&&"down"in n}function tr(n){if(n<=0)throw new RangeError("timeoutMs must be > 0");if(n>9e6)throw new RangeError("timeoutMs must be <= 9_000_000 (\u22482.5h) to stay within safe ns arithmetic")}function nr(n,e={}){let t=new Be(n,e);return t.tagFactory("resilientPipeline",On(e)),t}var Be,rr=G(()=>{"use strict";$e();Hn();Dt();er();qt();Be=class extends Ee{output;status;lastError;breakerState;droppedCount;rateLimitState;constructor(e,t={}){super(t.name??"resilient_pipeline",t.graph);let r=e,o,s,i;if(t.rateLimit!=null)if(Fe(t.rateLimit)){let u=r,d=t.rateLimit;r=Se(d,c=>{let l={...c,maxBuffer:c.maxBuffer??1/0,meta:H("resilient","rate-limit")};return st(u,l).node}),this.add(r,{name:"rateLimited"})}else{let u={...t.rateLimit,maxBuffer:t.rateLimit.maxBuffer??1/0,meta:H("resilient","rate-limit")},d=st(r,u);r=d.node,o=d.droppedCount,s=d.rateLimitState,this.add(r,{name:"rateLimited"}),this.add(o,{name:"droppedCount"}),this.add(s,{name:"rateLimitState"})}if(t.budget!=null)if(Fe(t.budget)){let u=r,d=t.budget;r=Se(d,c=>c.length>0?Ie(u,c,{meta:H("resilient","budget")}):u),this.add(r,{name:"budgetGated"})}else t.budget.length>0&&(r=Ie(r,t.budget,{meta:H("resilient","budget")}),this.add(r,{name:"budgetGated"}));if(t.breaker!=null)if(Fe(t.breaker)){let u=r,d=t.breaker,c=t.breakerOnOpen??"skip";r=Se(d,l=>{let h=rt(l);return ot(h,{onOpen:c,meta:H("resilient","breaker")})(u).node}),this.add(r,{name:"breakerWrapped"})}else{let u=rt(t.breaker),d=t.breakerOnOpen??"skip",c=ot(u,{onOpen:d,meta:H("resilient","breaker")})(r);r=c.node,i=c.breakerState,this.add(r,{name:"breakerWrapped"}),this.add(i,{name:"breakerState"})}if(t.timeoutMs!=null)if(Fe(t.timeoutMs)){let u=r,d=t.timeoutMs;r=Se(d,c=>(tr(c),it(u,c*1e6,{meta:H("resilient","timeout")}))),this.add(r,{name:"timeoutWrapped"})}else tr(t.timeoutMs),r=it(r,t.timeoutMs*1e6,{meta:H("resilient","timeout")}),this.add(r,{name:"timeoutWrapped"});if(t.retry!=null)if(Fe(t.retry)){let u=r,d=t.retry;r=Se(d,c=>nt(u,{...c,meta:H("resilient","retry")})),this.add(r,{name:"retryWrapped"})}else r=nt(r,{...t.retry,meta:H("resilient","retry")}),this.add(r,{name:"retryWrapped"});t.fallback!==void 0&&(r=Kt(r,t.fallback,{meta:H("resilient","fallback")}),this.add(r,{name:"fallbackWrapped"}));let a=Ht(r,{initialStatus:t.initialStatus??"pending",meta:H("resilient","status")});this.output=a.node,this.status=a.status,this.lastError=a.error,this.breakerState=i,this.droppedCount=o,this.rateLimitState=s,this.add(this.output,{name:"output"}),this.add(this.status,{name:"status"}),this.add(this.lastError,{name:"lastError"})}}});function be(n){return{describeKind:"derived",...n}}function ro(n){return n<0?0:n}function Yt(n){return n[1]}function oo(n){if(typeof n!="number"||!Number.isFinite(n))throw new TypeError("backoff strategy must return a finite number");return n<0?0:n}function or(n){let e=n?.count,t=n?.backoff;if(t!==void 0&&e===void 0)throw new RangeError("retry({ backoff }) requires explicit count to prevent unbounded retries; pass { count: <n>, backoff: ... }");let r=e!==void 0?e:0;if(r<0)throw new RangeError("retry count must be >= 0");let o=t===void 0?null:typeof t=="string"?Ut(t):t;return{maxRetries:r,strategy:o}}function sr(n){let e={};return n?.count!==void 0&&(e.count=n.count),typeof n?.backoff=="string"&&(e.backoff=n.backoff),Object.keys(e).length>0?e:void 0}function ir(n,e,t){let r=0,o=!1,s=null,i,a=new ae;function u(){i?.(),i=void 0}function d(l){if(o)return;if(r>=n.maxRetries){u(),t.down([[N,l]]);return}let h=n.strategy===null?0:n.strategy(r,l,s);if(h==null){u(),t.down([[N,l]]);return}let p;try{p=oo(h)}catch{u(),t.down([[N,l]]);return}s=p,r+=1,u();let f=p>0?p/1e6:1;a.start(f,()=>{o||c()})}function c(){a.cancel(),u();let l;try{l=e()}catch(h){d(h);return}i=l.subscribe(h=>{if(!o)for(let p of h){let f=p[0];if(f===M)t.down([[M]]);else if(f===x)r=0,s=null,t.emit(p[1]);else if(f===D)t.down([[D]]);else if(f===E)u(),t.down([[E]]);else if(f===N){d(Yt(p));return}else t.down([p])}})}return c(),()=>{o=!0,a.cancel(),u()}}function nt(n,e){return typeof n=="function"?io(n,e):so(n,e)}function so(n,e){let t=or(e);return F(r=>ir(t,()=>n,r),{...be(),initial:n.cache,meta:{...e?.meta??{},...re("retry",sr(e))}})}function io(n,e){let t=or(e);return F(r=>ir(t,n,r),{...be(),initial:e?.initial,meta:{...e?.meta??{},...re("retry",sr(e))}})}function rt(n){let e=Math.max(1,n?.failureThreshold??5),t=ro(n?.cooldownNs??30*1e9),r=n?.cooldown??null,o=Math.max(1,n?.halfOpenMax??1),s=n?.now??X,i="closed",a=0,u=0,d=0,c=t,l=0;function h(){if(!r)return t;let g=r(u);return g!==null?g:t}function p(){i="open",c=h(),d=s(),l=0}return{canExecute(){return i==="closed"?!0:i==="open"?s()-d>=c?(i="half-open",l=1,!0):!1:l<o?(l++,!0):!1},recordSuccess(){i==="half-open"?(i="closed",a=0,u=0):i==="closed"&&(a=0)},recordFailure(g){if(i==="half-open"){u++,p();return}i==="closed"&&(a++,a>=e&&p())},get state(){return i},get failureCount(){return a},reset(){i="closed",a=0,u=0,l=0}}}function ot(n,e){let t=e?.onOpen??"skip",r=e?.meta;return o=>{let s=W([],(i,a)=>{function u(){s.meta.breakerState.down([[x,n.state]])}let d=o.subscribe(c=>{for(let l of c){let h=l[0];h===M?a.down([[M]]):h===x?n.canExecute()?(u(),a.emit(l[1])):(u(),t==="error"?a.down([[N,new ut]]):a.down([[D]])):h===D?a.down([[D]]):h===E?(n.recordSuccess(),u(),a.down([[E]])):h===N?(n.recordFailure(Yt(l)),u(),a.down([l])):a.down([l])}});return u(),d},{...be(),meta:{...r??{},breakerState:n.state,...re("withBreaker",{onOpen:t})},completeWhenDepsComplete:!1,initial:o.cache});return{node:s,breakerState:s.meta.breakerState}}}function ar(n,e,t){if(n<=0)throw new RangeError("capacity must be > 0");if(e<0)throw new RangeError("refillPerSecond must be >= 0");let r=t?.clock??X,o=n,s=r();function i(a){if(e>0){let u=a-s;o=Math.min(n,o+u/1e9*e)}s=a}return{available(){return i(r()),o},tryConsume(a=1){if(a<=0)return!0;let u=r();return i(u),o>=a?(o-=a,!0):!1},putBack(a=1){a<=0||(i(r()),o=Math.min(n,o+a))}}}function ao(n,e){return n.droppedCount===e.droppedCount&&n.pendingCount===e.pendingCount&&n.paused===e.paused}function st(n,e){let{maxEvents:t,windowNs:r}=e;if(t<=0)throw new RangeError("maxEvents must be > 0");if(r<=0)throw new RangeError("windowNs must be > 0");let o=e.maxBuffer;if(o===void 0)throw new RangeError("rateLimiter requires explicit maxBuffer (use Infinity to opt in to unbounded)");let s=o===1/0;if(!s&&(!Number.isInteger(o)||o<1))throw new RangeError("maxBuffer must be a positive integer (or Infinity for unbounded)");let i=e.onOverflow??"drop-newest",a=t*1e9/r,u=F(d=>{let c=ar(t,a),l=s?co():uo(o),h=new ae,p=!1,f=0,g=1e9/a,m=u.meta.droppedCount,T=u.meta.rateLimitState,b=at;function y(){m.emit(f);let S={droppedCount:f,pendingCount:l.size,paused:l.size>0};ao(b,S)||(b=S,T.emit(S))}b=at,m.emit(0),T.emit(at);function v(){for(;l.size>0;)if(c.tryConsume(1))d.emit(l.shift()),y();else{h.start(Math.max(1,g/1e6),v);return}}function w(){f+=1,y()}function _(){for(p=!0,h.cancel();l.size>0;)l.shift();f=0}let R=n.subscribe(S=>{for(let C of S){if(p)return;let A=C[0];if(A===M)d.down([[M]]);else if(A===x){if(!s&&l.size>=o)if(i==="drop-newest")w();else if(i==="drop-oldest")l.shift(),l.push(C[1]),w();else{w(),_(),d.down([[N,new dt(o)]]);return}else l.push(C[1]),y();v()}else if(A===D)d.down([[D]]);else if(A===E)_(),d.down([[E]]);else if(A===N)_(),d.down([C]);else if(A===B){_(),d.down([C]);return}else d.down([C])}});return()=>{p=!0,h.cancel(),R()}},{...be(),initial:n.cache,meta:{...e.meta??{},droppedCount:0,rateLimitState:at,...re("rateLimiter",e)}});return{node:u,droppedCount:u.meta.droppedCount,rateLimitState:u.meta.rateLimitState}}function uo(n){let e=new pe(n);return{push:t=>e.push(t),shift:()=>e.shift(),get size(){return e.size}}}function co(){let n=[];return{push:e=>{n.push(e)},shift:()=>n.shift(),get size(){return n.length}}}function Ht(n,e){let t=e?.initialStatus??"pending",r=e?.meta,o=W([],(s,i)=>{let a=t;return o.meta.status.down([[x,t]]),o.meta.error.down([[x,null]]),n.subscribe(d=>{for(let c of d){let l=c[0];if(l===M)i.down([[M]]);else if(l===x)a==="errored"?Ge(()=>{o.meta.error.down([[x,null]]),o.meta.status.down([[x,"running"]])}):o.meta.status.down([[x,"running"]]),a="running",i.emit(c[1]);else if(l===D)i.down([[D]]);else if(l===E)o.meta.status.down([[x,"completed"]]),a="completed",i.down([[E]]);else if(l===N){let h=Yt(c);Ge(()=>{o.meta.error.down([[x,h]]),o.meta.status.down([[x,"errored"]])}),a="errored",i.down([c])}else i.down([c])}})},{...be(),meta:{...r??{},status:t,error:null,...re("withStatus",{initialStatus:t})},completeWhenDepsComplete:!1,resubscribable:!0,initial:n.cache});return{node:o,status:o.meta.status,error:o.meta.error}}function lo(n){return n!=null&&typeof n=="object"&&"cache"in n&&typeof n.subscribe=="function"}function fo(n){return n!=null&&typeof n.then=="function"}function po(n){return n!=null&&typeof n=="object"&&typeof n[Symbol.asyncIterator]=="function"}function Kt(n,e,t){let r=t?.meta;return F(o=>{let s,i;function a(){i?.(),i=void 0,lo(e)||fo(e)||po(e)?s=Ce(e).subscribe(d=>{o.down(d);for(let c of d){let l=c[0];if(l===E||l===N||l===B){s=void 0;return}}}):(o.emit(e),o.down([[E]]))}return i=n.subscribe(u=>{for(let d of u){let c=d[0];if(c===M)o.down([[M]]);else if(c===x)o.emit(d[1]);else if(c===D)o.down([[D]]);else if(c===E)o.down([[E]]);else if(c===N){a();return}else if(c===B){s?.(),o.down([d]);return}else o.down([d])}}),()=>{i?.(),s?.()}},{...be(),initial:n.cache,meta:{...r??{},...re("fallback")}})}function it(n,e,t){if(e<=0)throw new RangeError("timeoutNs must be > 0");let r=t?.meta;return F(o=>{let s=!1,i=new ae;function a(){let d=e/1e6;i.start(d,()=>{s||(s=!0,u(),o.down([[N,new ct(e)]]))})}let u=n.subscribe(d=>{for(let c of d){if(s)return;let l=c[0];if(l===M)o.down([[M]]);else if(l===x)a(),o.emit(c[1]);else if(l===D)o.down([[D]]);else if(l===E){i.cancel(),s=!0,o.down([[E]]);return}else if(l===N){i.cancel(),s=!0,o.down([c]);return}else if(l===B){i.cancel(),s=!0,o.down([c]);return}else o.down([c])}});return a(),()=>{s=!0,i.cancel(),u()}},{...be(),initial:n.cache,meta:{...r??{},...re("timeout",{timeoutNs:e})}})}var ut,dt,at,ct,qt=G(()=>{"use strict";Nn();rr();He();we();ie();$e();se();Je();Wt();tt();Ft();Bt();ut=class extends Error{name="CircuitOpenError";constructor(){super("Circuit breaker is open")}};dt=class extends Error{name="RateLimiterOverflowError";constructor(e){super(`rateLimiter buffer overflow (maxBuffer=${e})`)}};at=Object.freeze({droppedCount:0,pendingCount:0,paused:!1});ct=class extends Error{name="TimeoutError";constructor(e){super(`Timed out after ${e/1e6}ms`)}}});var ur={};bt(ur,{CircuitOpenError:()=>ut,RateLimiterOverflowError:()=>dt,ResilientPipelineGraph:()=>Be,TimeoutError:()=>ct,budgetGate:()=>Ie,circuitBreaker:()=>rt,fallback:()=>Kt,rateLimiter:()=>st,resilientPipeline:()=>nr,retry:()=>nt,timeout:()=>it,tokenBucket:()=>ar,withBreaker:()=>ot,withStatus:()=>Ht});var dr=G(()=>{"use strict";qt()});function Y(n){return{describeKind:"producer",...n}}function lr(n){return/[\\^$+?.()|[\]{}]/.test(n)?`\\${n}`:n}function ho(n){let e="^";for(let t=0;t<n.length;t+=1){let r=n[t];if(r==="*"){n[t+1]==="*"?(e+=".*",t+=1):e+="[^/]*";continue}e+=lr(r)}return e+="$",new RegExp(e)}function mo(n,e){for(let t of e)if(t.test(n))return!0;return!1}function go(n,e){let t=W([n],(o,s)=>{let i=o[0];if(i==null||i.length===0){s.down([[D]]);return}for(let a of i)s.emit(a)},{describeKind:"derived",initial:n.cache}),r=t.subscribe.bind(t);return t.subscribe=(o,s)=>(e(o),r(o,s)),t}function bo(n,e){let{signal:t,period:r,...o}=e??{};return F(s=>{let i=!1,a=0,u,d,c=()=>{i=!0,u!==void 0&&clearTimeout(u),d!==void 0&&clearInterval(d),t?.removeEventListener("abort",h)},l=()=>{i||(r!=null?(s.emit(a++),d=setInterval(()=>{i||s.emit(a++)},r)):(i=!0,t?.removeEventListener("abort",h),s.emit(a++),s.down([[E]])))},h=()=>{i||(c(),s.down([[N,t.reason]]))};if(t?.aborted){h();return}return u=setTimeout(l,n),t?.addEventListener("abort",h,{once:!0}),c},Y(o))}function yo(n){let{signal:e,...t}=n??{};return F(r=>{let o=!1,s,i,a=!1,u=!1,d=typeof requestAnimationFrame=="function"?requestAnimationFrame:void 0,c=typeof cancelAnimationFrame=="function"?cancelAnimationFrame:void 0,l=typeof document<"u"?document:void 0,h=()=>{s!==void 0&&c&&c(s),i!==void 0&&clearTimeout(i),s=void 0,i=void 0},p=()=>{o=!0,h(),a&&(e?.removeEventListener("abort",f),a=!1),u&&l&&(l.removeEventListener("visibilitychange",T),u=!1)},f=()=>{o||(p(),r.down([[N,e.reason]]))},g=b=>{o||(r.emit(b),m())},m=()=>{o||(d&&(!l||l.visibilityState!=="hidden")?s=d(g):i=setTimeout(()=>g(performance.now()),16))},T=()=>{o||(h(),m())};return e?.aborted?(f(),p):(e?.addEventListener("abort",f,{once:!0}),a=e!==void 0,l&&d&&(l.addEventListener("visibilitychange",T),u=!0),m(),p)},Y(t))}function vo(n,e){let t=wn(n),{tickMs:r,output:o,...s}=e??{},i=r??6e4,a=o==="date";return F(u=>{let d=-1,c=()=>{let h=new Date,p=h.getFullYear()*1e8+(h.getMonth()+1)*1e6+h.getDate()*1e4+h.getHours()*100+h.getMinutes();p!==d&&Tn(t,h)&&(d=p,u.emit(a?h:ve()))};c();let l=setInterval(c,i);return()=>clearInterval(l)},{...Y(s),name:s.name??`cron:${n}`})}function wo(n,e,t){let{capture:r,passive:o,once:s,...i}=t??{};return F(a=>{let u=c=>{a.emit(c)},d={capture:r,passive:o,once:s};return n.addEventListener(e,u,d),()=>n.removeEventListener(e,u,d)},Y(i))}function Xt(n,e){return F(t=>{let r=!1;try{for(let o of n){if(r)return;t.emit(o)}r||t.down([[E]])}catch(o){r||t.down([[N,o]])}return()=>{r=!0}},Y(e))}function To(n){return n!=null&&typeof n.then=="function"}function fr(n,e){let{signal:t,...r}=e??{};return F(o=>{let s=!1,i=()=>{s||(s=!0,o.down([[N,t.reason]]))};if(t?.aborted){i();return}return t?.addEventListener("abort",i,{once:!0}),Promise.resolve(n).then(a=>{s||(s=!0,t?.removeEventListener("abort",i),o.emit(a),o.down([[E]]))},a=>{s||(s=!0,t?.removeEventListener("abort",i),o.down([[N,a]]))}),()=>{s=!0,t?.removeEventListener("abort",i)}},Y(r))}function pr(n,e){let{signal:t,...r}=e??{};return F(o=>{let s=new AbortController,i=()=>s.abort(t?.reason);t?.aborted?s.abort(t.reason):t?.addEventListener("abort",i,{once:!0});let a=t??s.signal,u=!1,d=n[Symbol.asyncIterator](),c=()=>{u||a.aborted||Promise.resolve(d.next()).then(l=>{if(!(u||a.aborted)){if(l.done){o.down([[E]]);return}o.emit(l.value),c()}},l=>{!u&&!a.aborted&&o.down([[N,l]])})};return c(),()=>{u=!0,t?.removeEventListener("abort",i),s.abort(),Promise.resolve(d.return?.()).catch(()=>{})}},Y(r))}function _o(n){return n!=null&&typeof n=="object"&&"cache"in n&&typeof n.subscribe=="function"}function Ce(n,e){if(_o(n))return n;if(To(n))return fr(n,e);if(n!=null){let t=n;if(typeof t[Symbol.asyncIterator]=="function")return pr(n,e);if(typeof t[Symbol.iterator]=="function")return Xt(n,e)}return hr(n)}function hr(...n){return Xt(n,void 0)}function No(n){return F(e=>{e.down([[E]])},Y(n))}function Oo(n){return F(()=>{},Y(n))}function ko(n,e){return F(t=>{t.down([[N,n]])},Y(e))}function xo(n,e){let{signal:t,...r}=e??{},o=Y(r),s=o.resubscribable===void 0?{...o,resubscribable:!0}:o;return F(i=>{let a,u=!1;try{let d=n();a=Ce(d,e).subscribe(l=>{if(!u)for(let h of l){let p=h[0];if(p!==oe)if(p===x)i.emit(h[1]);else if(p===E){u=!0,i.down([[E]]);break}else if(p===N){u=!0,i.down([[N,h[1]]]);break}else i.down([h])}})}catch(d){let c=d===void 0?new Error("defer: thunk threw undefined"):d;i.down([[N,c]])}return()=>{u=!0,a?.()}},s)}function Eo(n,e,t){return W([n],(o,s)=>{let i=o[0];if(i!=null&&i.length>0)for(let a of i)e(a)},{describeKind:"effect",...t}).subscribe(()=>{})}function Ro(n,e){return W([n],(t,r,o)=>{o.store.buf||(o.store.buf=[]);let s=o.store.buf,i=t[0];if(i!=null&&i.length>0)for(let a of i)s.push(a);if(o.terminalDeps[0]===!0){r.emit([...s]),r.down([[E]]);return}(i==null||i.length===0)&&r.down([[D]])},{describeKind:"derived",completeWhenDepsComplete:!1,...e})}function So(n,e){return F(t=>n.subscribe(r=>{t.down(r)}),{...Y(e),initial:n.cache})}function Qt(n,e,t){if(e<1)throw new RangeError("replay expects bufferSize >= 1");let r=[],o=F(s=>n.subscribe(i=>{for(let a of i)a[0]===x&&(r.push(a[1]),r.length>e&&r.shift());s.down(i)}),{...Y(t),initial:n.cache});return go(o,s=>{for(let i of r)s([[x,i]])})}function Co(n,e){return Qt(n,1,e)}function Ao(n){return new Promise((e,t)=>{let r=!1,o=!1,s;s=n.subscribe(i=>{for(let a of i){if(r)return;if(a[0]===x){r=!0,e(a[1]),s?(s(),s=void 0):o=!0;return}if(a[0]===N){r=!0,t(a[1]),s?(s(),s=void 0):o=!0;return}if(a[0]===E){r=!0,t(new Error("completed without DATA")),s?(s(),s=void 0):o=!0;return}}}),o&&(s?.(),s=void 0)})}function Zt(n,e,t){return new Promise((r,o)=>{let s=!1,i=!1,a,u=t?.skipCurrent===!0;a=n.subscribe(d=>{for(let c of d){if(s)return;if(!(u&&c[0]===x)){if(c[0]===x){let l=c[1];if(e(l)){s=!0,r(l),a?(a(),a=void 0):i=!0;return}}if(c[0]===N){s=!0,o(c[1]),a?(a(),a=void 0):i=!0;return}if(c[0]===E){s=!0,o(new Error("completed without matching value")),a?(a(),a=void 0):i=!0;return}}}}),u=!1,i&&(a?.(),a=void 0)})}async function Do(n,e){let t=e?.predicate??(s=>s!=null),r=e?.skipCurrent;if(e?.timeoutMs==null||e.timeoutMs<=0)return await Zt(n,t,{skipCurrent:r});if(Jt===void 0){let[s,i]=await Promise.all([Promise.resolve().then(()=>(dr(),ur)),Promise.resolve().then(()=>(Wt(),Xn))]);Jt=s.timeout,cr=i.NS_PER_MS}let o=Jt(n,e.timeoutMs*cr);return await Zt(o,t,{skipCurrent:r})}function Mo(n,e){let t=new AbortController,r=e?.reason??new Error("cancelled via nodeSignal"),o,s=!1,i=()=>{o?(o(),o=void 0):s=!0};return o=n.subscribe(a=>{if(!t.signal.aborted)for(let u of a){if(u[0]===x&&u[1]===!0){t.abort(r),i();return}if(u[0]===N){t.abort(u[1]),i();return}if(u[0]===E){i();return}}}),s&&(o?.(),o=void 0),{signal:t.signal,dispose:()=>{o&&(o(),o=void 0)}}}function Le(n){return n.subscribe(()=>{})}function Po(n){let e=fe(0);return{node:e,increment(){let t=e.cache??0;return t>=n?!1:(e.down([[M],[x,t+1]]),!0)},get(){return e.cache??0},atCap(){return(e.cache??0)>=n}}}var Jt,cr,Go,mr=G(()=>{"use strict";we();ie();se();Je();_n();Go=Qt});var Io={};bt(Io,{awaitSettled:()=>Do,cached:()=>Co,defer:()=>xo,empty:()=>No,escapeRegexChar:()=>lr,firstValueFrom:()=>Ao,firstWhere:()=>Zt,forEach:()=>Eo,fromAny:()=>Ce,fromAsyncIter:()=>pr,fromCron:()=>vo,fromEvent:()=>wo,fromIter:()=>Xt,fromPromise:()=>fr,fromRaf:()=>yo,fromTimer:()=>bo,globToRegExp:()=>ho,keepalive:()=>Le,matchesAnyPattern:()=>mo,never:()=>Oo,nodeSignal:()=>Mo,of:()=>hr,reactiveCounter:()=>Po,replay:()=>Qt,share:()=>So,shareReplay:()=>Go,throwError:()=>ko,toArray:()=>Ro});module.exports=wr(Io);var tt=G(()=>{mr()});tt();0&&(module.exports={awaitSettled,cached,defer,empty,escapeRegexChar,firstValueFrom,firstWhere,forEach,fromAny,fromAsyncIter,fromCron,fromEvent,fromIter,fromPromise,fromRaf,fromTimer,globToRegExp,keepalive,matchesAnyPattern,never,nodeSignal,of,reactiveCounter,replay,share,shareReplay,throwError,toArray});
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __copyProps = (to, from, except, desc) => {
7
+ if (from && typeof from === "object" || typeof from === "function") {
8
+ for (let key of __getOwnPropNames(from))
9
+ if (!__hasOwnProp.call(to, key) && key !== except)
10
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
+ }
12
+ return to;
13
+ };
14
+ var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
16
+
17
+ // src/extra/sources.ts
18
+ var sources_exports = {};
19
+ module.exports = __toCommonJS(sources_exports);
20
+ __reExport(sources_exports, require("@graphrefly/pure-ts/extra/sources"), module.exports);
21
+ //# sourceMappingURL=sources.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/extra/sources.ts"],"sourcesContent":["// Phase 13.9.A shim — re-export from pure-TS sibling until\n// @graphrefly/native (napi binding) and per-milestone swap-overs land.\nexport * from \"@graphrefly/pure-ts/extra/sources\";\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AAAA;AAEA,4BAAc,8CAFd;","names":[]}