langgraph-ui-components 0.0.10 → 0.0.11-testing

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 (393) hide show
  1. package/dist/index.es.js +3 -2
  2. package/dist/index.es10.js +25 -6
  3. package/dist/index.es10.js.map +1 -1
  4. package/dist/index.es100.js +131 -64
  5. package/dist/index.es100.js.map +1 -1
  6. package/dist/index.es101.js +65 -32
  7. package/dist/index.es101.js.map +1 -1
  8. package/dist/index.es102.js +34 -34
  9. package/dist/index.es102.js.map +1 -1
  10. package/dist/index.es103.js +35 -164
  11. package/dist/index.es103.js.map +1 -1
  12. package/dist/index.es104.js +156 -193
  13. package/dist/index.es104.js.map +1 -1
  14. package/dist/index.es105.js +202 -13
  15. package/dist/index.es105.js.map +1 -1
  16. package/dist/index.es106.js +13 -29
  17. package/dist/index.es106.js.map +1 -1
  18. package/dist/index.es107.js +25 -29
  19. package/dist/index.es107.js.map +1 -1
  20. package/dist/index.es108.js +24 -3147
  21. package/dist/index.es108.js.map +1 -1
  22. package/dist/index.es109.js +3151 -31
  23. package/dist/index.es109.js.map +1 -1
  24. package/dist/index.es110.js +21 -5
  25. package/dist/index.es110.js.map +1 -1
  26. package/dist/index.es111.js +64 -69
  27. package/dist/index.es111.js.map +1 -1
  28. package/dist/index.es112.js +3 -37
  29. package/dist/index.es112.js.map +1 -1
  30. package/dist/index.es113.js +16 -5
  31. package/dist/index.es113.js.map +1 -1
  32. package/dist/index.es114.js +7 -2
  33. package/dist/index.es114.js.map +1 -1
  34. package/dist/index.es115.js +2 -13
  35. package/dist/index.es115.js.map +1 -1
  36. package/dist/index.es116.js +9 -499
  37. package/dist/index.es116.js.map +1 -1
  38. package/dist/index.es117.js +501 -5
  39. package/dist/index.es117.js.map +1 -1
  40. package/dist/index.es118.js +7 -2
  41. package/dist/index.es118.js.map +1 -1
  42. package/dist/index.es119.js +2 -148
  43. package/dist/index.es119.js.map +1 -1
  44. package/dist/index.es120.js +118 -878
  45. package/dist/index.es120.js.map +1 -1
  46. package/dist/index.es121.js +877 -251
  47. package/dist/index.es121.js.map +1 -1
  48. package/dist/index.es122.js +281 -3
  49. package/dist/index.es122.js.map +1 -1
  50. package/dist/index.es123.js +3 -445
  51. package/dist/index.es123.js.map +1 -1
  52. package/dist/index.es124.js +437 -39
  53. package/dist/index.es124.js.map +1 -1
  54. package/dist/index.es125.js +46 -22
  55. package/dist/index.es125.js.map +1 -1
  56. package/dist/index.es126.js +21 -78
  57. package/dist/index.es126.js.map +1 -1
  58. package/dist/index.es127.js +76 -126
  59. package/dist/index.es127.js.map +1 -1
  60. package/dist/index.es128.js +125 -45
  61. package/dist/index.es128.js.map +1 -1
  62. package/dist/index.es129.js +48 -9
  63. package/dist/index.es129.js.map +1 -1
  64. package/dist/index.es130.js +10 -45
  65. package/dist/index.es130.js.map +1 -1
  66. package/dist/index.es131.js +43 -97
  67. package/dist/index.es131.js.map +1 -1
  68. package/dist/index.es132.js +94 -48
  69. package/dist/index.es132.js.map +1 -1
  70. package/dist/index.es133.js +51 -14
  71. package/dist/index.es133.js.map +1 -1
  72. package/dist/index.es134.js +1 -1
  73. package/dist/index.es135.js +1 -1
  74. package/dist/index.es138.js +1 -1
  75. package/dist/index.es139.js +1 -1
  76. package/dist/index.es140.js +1 -1
  77. package/dist/index.es141.js +1 -1
  78. package/dist/index.es142.js +1 -1
  79. package/dist/index.es143.js +1 -1
  80. package/dist/index.es144.js +1 -1
  81. package/dist/index.es145.js +1 -1
  82. package/dist/index.es146.js +1 -1
  83. package/dist/index.es147.js +1 -1
  84. package/dist/index.es148.js +1 -1
  85. package/dist/index.es149.js +1 -1
  86. package/dist/index.es150.js +1 -1
  87. package/dist/index.es151.js +1 -1
  88. package/dist/index.es152.js +1 -1
  89. package/dist/index.es153.js +1 -1
  90. package/dist/index.es154.js +1 -1
  91. package/dist/index.es155.js +1 -1
  92. package/dist/index.es156.js +1 -1
  93. package/dist/index.es157.js +1 -1
  94. package/dist/index.es158.js +1 -1
  95. package/dist/index.es159.js +1 -1
  96. package/dist/index.es16.js +3 -3
  97. package/dist/index.es16.js.map +1 -1
  98. package/dist/index.es160.js +1 -1
  99. package/dist/index.es161.js +1 -1
  100. package/dist/index.es162.js +1 -1
  101. package/dist/index.es163.js +1 -1
  102. package/dist/index.es164.js +1 -1
  103. package/dist/index.es165.js +1 -1
  104. package/dist/index.es166.js +1 -1
  105. package/dist/index.es167.js +1 -1
  106. package/dist/index.es168.js +1 -1
  107. package/dist/index.es169.js +1 -1
  108. package/dist/index.es170.js +1 -1
  109. package/dist/index.es171.js +1 -1
  110. package/dist/index.es172.js +1 -1
  111. package/dist/index.es173.js +1 -1
  112. package/dist/index.es174.js +1 -1
  113. package/dist/index.es175.js +1 -1
  114. package/dist/index.es176.js +1 -1
  115. package/dist/index.es177.js +1 -1
  116. package/dist/index.es178.js +1 -1
  117. package/dist/index.es179.js +1 -1
  118. package/dist/index.es18.js +15 -15
  119. package/dist/index.es180.js +1 -1
  120. package/dist/index.es181.js +1 -1
  121. package/dist/index.es182.js +1 -1
  122. package/dist/index.es183.js +162 -13
  123. package/dist/index.es183.js.map +1 -1
  124. package/dist/index.es184.js +2 -89
  125. package/dist/index.es184.js.map +1 -1
  126. package/dist/index.es185.js +15 -2
  127. package/dist/index.es185.js.map +1 -1
  128. package/dist/index.es186.js +89 -2
  129. package/dist/index.es186.js.map +1 -1
  130. package/dist/index.es187.js +2 -2
  131. package/dist/index.es188.js +56 -2
  132. package/dist/index.es188.js.map +1 -1
  133. package/dist/index.es189.js +100 -2
  134. package/dist/index.es189.js.map +1 -1
  135. package/dist/index.es190.js +191 -2
  136. package/dist/index.es190.js.map +1 -1
  137. package/dist/index.es191.js +110 -2
  138. package/dist/index.es191.js.map +1 -1
  139. package/dist/index.es192.js +35 -2
  140. package/dist/index.es192.js.map +1 -1
  141. package/dist/index.es193.js +10 -2
  142. package/dist/index.es193.js.map +1 -1
  143. package/dist/index.es194.js +11 -2
  144. package/dist/index.es194.js.map +1 -1
  145. package/dist/index.es195.js +12 -2
  146. package/dist/index.es195.js.map +1 -1
  147. package/dist/index.es196.js +91 -2
  148. package/dist/index.es196.js.map +1 -1
  149. package/dist/index.es197.js +275 -2
  150. package/dist/index.es197.js.map +1 -1
  151. package/dist/index.es198.js +2 -2
  152. package/dist/index.es199.js +164 -2
  153. package/dist/index.es199.js.map +1 -1
  154. package/dist/index.es200.js +51 -2
  155. package/dist/index.es200.js.map +1 -1
  156. package/dist/index.es201.js +40 -2
  157. package/dist/index.es201.js.map +1 -1
  158. package/dist/index.es202.js +35 -2
  159. package/dist/index.es202.js.map +1 -1
  160. package/dist/index.es203.js +40 -2
  161. package/dist/index.es203.js.map +1 -1
  162. package/dist/index.es204.js +24 -2
  163. package/dist/index.es204.js.map +1 -1
  164. package/dist/index.es205.js +591 -2
  165. package/dist/index.es205.js.map +1 -1
  166. package/dist/index.es206.js +125 -2
  167. package/dist/index.es206.js.map +1 -1
  168. package/dist/index.es207.js +2 -2
  169. package/dist/index.es208.js +2 -2
  170. package/dist/index.es209.js +2 -2
  171. package/dist/index.es210.js +2 -2
  172. package/dist/index.es211.js +2 -2
  173. package/dist/index.es212.js +2 -2
  174. package/dist/index.es213.js +2 -2
  175. package/dist/index.es214.js +2 -2
  176. package/dist/index.es215.js +2 -2
  177. package/dist/index.es216.js +2 -2
  178. package/dist/index.es217.js +2 -2
  179. package/dist/index.es218.js +2 -2
  180. package/dist/index.es219.js +2 -2
  181. package/dist/index.es220.js +2 -2
  182. package/dist/index.es221.js +2 -2
  183. package/dist/index.es222.js +2 -2
  184. package/dist/index.es223.js +2 -2
  185. package/dist/index.es224.js +2 -2
  186. package/dist/index.es225.js +2 -2
  187. package/dist/index.es226.js +2 -2
  188. package/dist/index.es227.js +2 -2
  189. package/dist/index.es228.js +2 -2
  190. package/dist/index.es229.js +2 -2
  191. package/dist/index.es230.js +2 -2
  192. package/dist/index.es231.js +2 -56
  193. package/dist/index.es231.js.map +1 -1
  194. package/dist/index.es232.js +2 -100
  195. package/dist/index.es232.js.map +1 -1
  196. package/dist/index.es233.js +2 -191
  197. package/dist/index.es233.js.map +1 -1
  198. package/dist/index.es234.js +2 -110
  199. package/dist/index.es234.js.map +1 -1
  200. package/dist/index.es235.js +2 -35
  201. package/dist/index.es235.js.map +1 -1
  202. package/dist/index.es236.js +2 -10
  203. package/dist/index.es236.js.map +1 -1
  204. package/dist/index.es237.js +2 -11
  205. package/dist/index.es237.js.map +1 -1
  206. package/dist/index.es238.js +2 -12
  207. package/dist/index.es238.js.map +1 -1
  208. package/dist/index.es239.js +2 -91
  209. package/dist/index.es239.js.map +1 -1
  210. package/dist/index.es24.js +1 -1
  211. package/dist/index.es240.js +2 -275
  212. package/dist/index.es240.js.map +1 -1
  213. package/dist/index.es241.js +2 -2
  214. package/dist/index.es242.js +2 -164
  215. package/dist/index.es242.js.map +1 -1
  216. package/dist/index.es243.js +2 -51
  217. package/dist/index.es243.js.map +1 -1
  218. package/dist/index.es244.js +2 -40
  219. package/dist/index.es244.js.map +1 -1
  220. package/dist/index.es245.js +2 -35
  221. package/dist/index.es245.js.map +1 -1
  222. package/dist/index.es246.js +2 -40
  223. package/dist/index.es246.js.map +1 -1
  224. package/dist/index.es247.js +2 -24
  225. package/dist/index.es247.js.map +1 -1
  226. package/dist/index.es248.js +2 -591
  227. package/dist/index.es248.js.map +1 -1
  228. package/dist/index.es249.js +2 -125
  229. package/dist/index.es249.js.map +1 -1
  230. package/dist/index.es25.js +3 -1
  231. package/dist/index.es25.js.map +1 -1
  232. package/dist/index.es250.js +2 -164
  233. package/dist/index.es250.js.map +1 -1
  234. package/dist/index.es251.js +2 -2
  235. package/dist/index.es252.js +2 -2
  236. package/dist/index.es253.js +1 -1
  237. package/dist/index.es258.js +1 -1
  238. package/dist/index.es260.js +2 -2
  239. package/dist/index.es262.js +2 -2
  240. package/dist/index.es265.js +1 -1
  241. package/dist/index.es267.js +1 -1
  242. package/dist/index.es277.js +2 -147
  243. package/dist/index.es277.js.map +1 -1
  244. package/dist/index.es278.js +126 -167
  245. package/dist/index.es278.js.map +1 -1
  246. package/dist/index.es279.js +188 -2
  247. package/dist/index.es279.js.map +1 -1
  248. package/dist/index.es280.js +1 -1
  249. package/dist/index.es283.js +1 -1
  250. package/dist/index.es288.js +1 -1
  251. package/dist/index.es29.js +1 -1
  252. package/dist/index.es3.js +24 -9
  253. package/dist/index.es3.js.map +1 -1
  254. package/dist/index.es300.js +1 -1
  255. package/dist/index.es302.js +1 -1
  256. package/dist/index.es31.js +7 -7
  257. package/dist/index.es314.js +1 -1
  258. package/dist/index.es32.js +1 -1
  259. package/dist/index.es334.js +2 -2
  260. package/dist/index.es35.js +4 -4
  261. package/dist/index.es36.js +1185 -111
  262. package/dist/index.es36.js.map +1 -1
  263. package/dist/index.es37.js +7 -71
  264. package/dist/index.es37.js.map +1 -1
  265. package/dist/index.es38.js +9 -18
  266. package/dist/index.es38.js.map +1 -1
  267. package/dist/index.es39.js +136 -250
  268. package/dist/index.es39.js.map +1 -1
  269. package/dist/index.es4.js +2 -1
  270. package/dist/index.es4.js.map +1 -1
  271. package/dist/index.es40.js +116 -41
  272. package/dist/index.es40.js.map +1 -1
  273. package/dist/index.es41.js +64 -208
  274. package/dist/index.es41.js.map +1 -1
  275. package/dist/index.es42.js +17 -66
  276. package/dist/index.es42.js.map +1 -1
  277. package/dist/index.es43.js +236 -117
  278. package/dist/index.es43.js.map +1 -1
  279. package/dist/index.es44.js +38 -19
  280. package/dist/index.es44.js.map +1 -1
  281. package/dist/index.es45.js +202 -217
  282. package/dist/index.es45.js.map +1 -1
  283. package/dist/index.es46.js +65 -7
  284. package/dist/index.es46.js.map +1 -1
  285. package/dist/index.es47.js +131 -1181
  286. package/dist/index.es47.js.map +1 -1
  287. package/dist/index.es48.js +25 -8
  288. package/dist/index.es48.js.map +1 -1
  289. package/dist/index.es49.js +218 -135
  290. package/dist/index.es49.js.map +1 -1
  291. package/dist/index.es5.js.map +1 -1
  292. package/dist/index.es50.js +5 -208
  293. package/dist/index.es50.js.map +1 -1
  294. package/dist/index.es51.js +208 -5
  295. package/dist/index.es51.js.map +1 -1
  296. package/dist/index.es52.js +90 -7
  297. package/dist/index.es52.js.map +1 -1
  298. package/dist/index.es53.js +6 -92
  299. package/dist/index.es53.js.map +1 -1
  300. package/dist/index.es54.js +14 -3
  301. package/dist/index.es54.js.map +1 -1
  302. package/dist/index.es55.js +8 -36
  303. package/dist/index.es55.js.map +1 -1
  304. package/dist/index.es56.js +83 -61
  305. package/dist/index.es56.js.map +1 -1
  306. package/dist/index.es57.js +3 -37
  307. package/dist/index.es57.js.map +1 -1
  308. package/dist/index.es58.js +34 -304
  309. package/dist/index.es58.js.map +1 -1
  310. package/dist/index.es59.js +72 -9
  311. package/dist/index.es59.js.map +1 -1
  312. package/dist/index.es60.js +32 -85
  313. package/dist/index.es60.js.map +1 -1
  314. package/dist/index.es61.js +304 -6
  315. package/dist/index.es61.js.map +1 -1
  316. package/dist/index.es62.js +9 -15
  317. package/dist/index.es62.js.map +1 -1
  318. package/dist/index.es63.js +3 -3
  319. package/dist/index.es64.js +5 -142
  320. package/dist/index.es64.js.map +1 -1
  321. package/dist/index.es65.js +148 -285
  322. package/dist/index.es65.js.map +1 -1
  323. package/dist/index.es66.js +668 -62
  324. package/dist/index.es66.js.map +1 -1
  325. package/dist/index.es67.js +131 -201
  326. package/dist/index.es67.js.map +1 -1
  327. package/dist/index.es68.js +295 -29
  328. package/dist/index.es68.js.map +1 -1
  329. package/dist/index.es69.js +65 -8
  330. package/dist/index.es69.js.map +1 -1
  331. package/dist/index.es7.js +2 -1
  332. package/dist/index.es7.js.map +1 -1
  333. package/dist/index.es70.js +210 -9
  334. package/dist/index.es70.js.map +1 -1
  335. package/dist/index.es71.js +28 -181
  336. package/dist/index.es71.js.map +1 -1
  337. package/dist/index.es72.js +8 -23
  338. package/dist/index.es72.js.map +1 -1
  339. package/dist/index.es73.js +9 -1397
  340. package/dist/index.es73.js.map +1 -1
  341. package/dist/index.es74.js +187 -9
  342. package/dist/index.es74.js.map +1 -1
  343. package/dist/index.es75.js +24 -8
  344. package/dist/index.es75.js.map +1 -1
  345. package/dist/index.es76.js +1399 -5
  346. package/dist/index.es76.js.map +1 -1
  347. package/dist/index.es77.js +9 -163
  348. package/dist/index.es77.js.map +1 -1
  349. package/dist/index.es78.js +8 -672
  350. package/dist/index.es78.js.map +1 -1
  351. package/dist/index.es79.js +36 -20
  352. package/dist/index.es79.js.map +1 -1
  353. package/dist/index.es80.js +5 -68
  354. package/dist/index.es80.js.map +1 -1
  355. package/dist/index.es81.js +73 -3
  356. package/dist/index.es81.js.map +1 -1
  357. package/dist/index.es82.js +36 -11
  358. package/dist/index.es82.js.map +1 -1
  359. package/dist/index.es83.js +10 -38
  360. package/dist/index.es83.js.map +1 -1
  361. package/dist/index.es84.js +34 -28
  362. package/dist/index.es84.js.map +1 -1
  363. package/dist/index.es85.js +28 -226
  364. package/dist/index.es85.js.map +1 -1
  365. package/dist/index.es86.js +228 -26
  366. package/dist/index.es86.js.map +1 -1
  367. package/dist/index.es87.js +26 -71
  368. package/dist/index.es87.js.map +1 -1
  369. package/dist/index.es88.js +41 -42
  370. package/dist/index.es88.js.map +1 -1
  371. package/dist/index.es89.js +71 -47
  372. package/dist/index.es89.js.map +1 -1
  373. package/dist/index.es90.js +37 -15
  374. package/dist/index.es90.js.map +1 -1
  375. package/dist/index.es91.js +6 -19
  376. package/dist/index.es91.js.map +1 -1
  377. package/dist/index.es92.js +40 -54
  378. package/dist/index.es92.js.map +1 -1
  379. package/dist/index.es93.js +56 -12
  380. package/dist/index.es93.js.map +1 -1
  381. package/dist/index.es94.js +13 -137
  382. package/dist/index.es94.js.map +1 -1
  383. package/dist/index.es95.js +135 -19
  384. package/dist/index.es95.js.map +1 -1
  385. package/dist/index.es96.js +18 -179
  386. package/dist/index.es96.js.map +1 -1
  387. package/dist/index.es97.js +163 -222
  388. package/dist/index.es97.js.map +1 -1
  389. package/dist/index.es98.js +187 -301
  390. package/dist/index.es98.js.map +1 -1
  391. package/dist/index.es99.js +348 -130
  392. package/dist/index.es99.js.map +1 -1
  393. package/package.json +1 -1
@@ -1,102 +1,48 @@
1
- import { toBase64Url } from "./index.es102.js";
2
- function _escapeNodeLabel(nodeLabel) {
3
- return nodeLabel.replace(/[^a-zA-Z-_0-9]/g, "_");
4
- }
5
- const MARKDOWN_SPECIAL_CHARS = [
6
- "*",
7
- "_",
8
- "`"
9
- ];
10
- function _generateMermaidGraphStyles(nodeColors) {
11
- let styles = "";
12
- for (const [className, color] of Object.entries(nodeColors)) styles += ` classDef ${className} ${color};
13
- `;
14
- return styles;
15
- }
16
- function drawMermaid(nodes, edges, config) {
17
- const { firstNode, lastNode, nodeColors, withStyles = true, curveStyle = "linear", wrapLabelNWords = 9 } = config ?? {};
18
- let mermaidGraph = withStyles ? `%%{init: {'flowchart': {'curve': '${curveStyle}'}}}%%
19
- graph TD;
20
- ` : "graph TD;\n";
21
- if (withStyles) {
22
- const defaultClassLabel = "default";
23
- const formatDict = { [defaultClassLabel]: "{0}({1})" };
24
- if (firstNode !== void 0) formatDict[firstNode] = "{0}([{1}]):::first";
25
- if (lastNode !== void 0) formatDict[lastNode] = "{0}([{1}]):::last";
26
- for (const [key, node] of Object.entries(nodes)) {
27
- const nodeName = node.name.split(":").pop() ?? "";
28
- const label = MARKDOWN_SPECIAL_CHARS.some((char) => nodeName.startsWith(char) && nodeName.endsWith(char)) ? `<p>${nodeName}</p>` : nodeName;
29
- let finalLabel = label;
30
- if (Object.keys(node.metadata ?? {}).length) finalLabel += `<hr/><small><em>${Object.entries(node.metadata ?? {}).map(([k, v]) => `${k} = ${v}`).join("\n")}</em></small>`;
31
- const nodeLabel = (formatDict[key] ?? formatDict[defaultClassLabel]).replace("{0}", _escapeNodeLabel(key)).replace("{1}", finalLabel);
32
- mermaidGraph += ` ${nodeLabel}
33
- `;
34
- }
1
+ import { config, $ZodAsyncError } from "./index.es264.js";
2
+ import { $ZodRealError, $ZodError } from "./index.es265.js";
3
+ import { finalizeIssue, captureStackTrace } from "./index.es127.js";
4
+ const _parseAsync = (_Err) => async (schema, value, _ctx, params) => {
5
+ const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };
6
+ let result = schema._zod.run({ value, issues: [] }, ctx);
7
+ if (result instanceof Promise)
8
+ result = await result;
9
+ if (result.issues.length) {
10
+ const e = new (params?.Err ?? _Err)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())));
11
+ captureStackTrace(e, params?.callee);
12
+ throw e;
35
13
  }
36
- const edgeGroups = {};
37
- for (const edge of edges) {
38
- const srcParts = edge.source.split(":");
39
- const tgtParts = edge.target.split(":");
40
- const commonPrefix = srcParts.filter((src, i) => src === tgtParts[i]).join(":");
41
- if (!edgeGroups[commonPrefix]) edgeGroups[commonPrefix] = [];
42
- edgeGroups[commonPrefix].push(edge);
43
- }
44
- const seenSubgraphs = /* @__PURE__ */ new Set();
45
- function sortPrefixesByDepth(prefixes) {
46
- return [...prefixes].sort((a, b) => {
47
- return a.split(":").length - b.split(":").length;
48
- });
49
- }
50
- function addSubgraph(edges$1, prefix) {
51
- const selfLoop = edges$1.length === 1 && edges$1[0].source === edges$1[0].target;
52
- if (prefix && !selfLoop) {
53
- const subgraph = prefix.split(":").pop();
54
- if (seenSubgraphs.has(prefix)) throw new Error(`Found duplicate subgraph '${subgraph}' at '${prefix} -- this likely means that you're reusing a subgraph node with the same name. Please adjust your graph to have subgraph nodes with unique names.`);
55
- seenSubgraphs.add(prefix);
56
- mermaidGraph += ` subgraph ${subgraph}
57
- `;
58
- }
59
- const nestedPrefixes = sortPrefixesByDepth(Object.keys(edgeGroups).filter((nestedPrefix) => nestedPrefix.startsWith(`${prefix}:`) && nestedPrefix !== prefix && nestedPrefix.split(":").length === prefix.split(":").length + 1));
60
- for (const nestedPrefix of nestedPrefixes) addSubgraph(edgeGroups[nestedPrefix], nestedPrefix);
61
- for (const edge of edges$1) {
62
- const { source, target, data, conditional } = edge;
63
- let edgeLabel = "";
64
- if (data !== void 0) {
65
- let edgeData = data;
66
- const words = edgeData.split(" ");
67
- if (words.length > wrapLabelNWords) edgeData = Array.from({ length: Math.ceil(words.length / wrapLabelNWords) }, (_, i) => words.slice(i * wrapLabelNWords, (i + 1) * wrapLabelNWords).join(" ")).join("&nbsp;<br>&nbsp;");
68
- edgeLabel = conditional ? ` -. &nbsp;${edgeData}&nbsp; .-> ` : ` -- &nbsp;${edgeData}&nbsp; --> `;
69
- } else edgeLabel = conditional ? " -.-> " : " --> ";
70
- mermaidGraph += ` ${_escapeNodeLabel(source)}${edgeLabel}${_escapeNodeLabel(target)};
71
- `;
72
- }
73
- if (prefix && !selfLoop) mermaidGraph += " end\n";
74
- }
75
- addSubgraph(edgeGroups[""] ?? [], "");
76
- for (const prefix in edgeGroups) if (!prefix.includes(":") && prefix !== "") addSubgraph(edgeGroups[prefix], prefix);
77
- if (withStyles) mermaidGraph += _generateMermaidGraphStyles(nodeColors ?? {});
78
- return mermaidGraph;
79
- }
80
- async function drawMermaidImage(mermaidSyntax, config) {
81
- let backgroundColor = config?.backgroundColor ?? "white";
82
- const imageType = config?.imageType ?? "png";
83
- const mermaidSyntaxEncoded = toBase64Url(mermaidSyntax);
84
- if (backgroundColor !== void 0) {
85
- const hexColorPattern = /^#(?:[0-9a-fA-F]{3}){1,2}$/;
86
- if (!hexColorPattern.test(backgroundColor)) backgroundColor = `!${backgroundColor}`;
14
+ return result.value;
15
+ };
16
+ const parseAsync = /* @__PURE__ */ _parseAsync($ZodRealError);
17
+ const _safeParse = (_Err) => (schema, value, _ctx) => {
18
+ const ctx = _ctx ? { ..._ctx, async: false } : { async: false };
19
+ const result = schema._zod.run({ value, issues: [] }, ctx);
20
+ if (result instanceof Promise) {
21
+ throw new $ZodAsyncError();
87
22
  }
88
- const imageUrl = `https://mermaid.ink/img/${mermaidSyntaxEncoded}?bgColor=${backgroundColor}&type=${imageType}`;
89
- const res = await fetch(imageUrl);
90
- if (!res.ok) throw new Error([
91
- `Failed to render the graph using the Mermaid.INK API.`,
92
- `Status code: ${res.status}`,
93
- `Status text: ${res.statusText}`
94
- ].join("\n"));
95
- const content = await res.blob();
96
- return content;
97
- }
23
+ return result.issues.length ? {
24
+ success: false,
25
+ error: new (_Err ?? $ZodError)(result.issues.map((iss) => finalizeIssue(iss, ctx, config())))
26
+ } : { success: true, data: result.value };
27
+ };
28
+ const safeParse = /* @__PURE__ */ _safeParse($ZodRealError);
29
+ const _safeParseAsync = (_Err) => async (schema, value, _ctx) => {
30
+ const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };
31
+ let result = schema._zod.run({ value, issues: [] }, ctx);
32
+ if (result instanceof Promise)
33
+ result = await result;
34
+ return result.issues.length ? {
35
+ success: false,
36
+ error: new _Err(result.issues.map((iss) => finalizeIssue(iss, ctx, config())))
37
+ } : { success: true, data: result.value };
38
+ };
39
+ const safeParseAsync = /* @__PURE__ */ _safeParseAsync($ZodRealError);
98
40
  export {
99
- drawMermaid,
100
- drawMermaidImage
41
+ _parseAsync,
42
+ _safeParse,
43
+ _safeParseAsync,
44
+ parseAsync,
45
+ safeParse,
46
+ safeParseAsync
101
47
  };
102
48
  //# sourceMappingURL=index.es131.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.es131.js","sources":["../node_modules/.pnpm/@langchain+core@1.1.13_openai@6.16.0_zod@4.3.5_/node_modules/@langchain/core/dist/runnables/graph_mermaid.js"],"sourcesContent":["import { toBase64Url } from \"./utils.js\";\n\n//#region src/runnables/graph_mermaid.ts\nfunction _escapeNodeLabel(nodeLabel) {\n\treturn nodeLabel.replace(/[^a-zA-Z-_0-9]/g, \"_\");\n}\nconst MARKDOWN_SPECIAL_CHARS = [\n\t\"*\",\n\t\"_\",\n\t\"`\"\n];\nfunction _generateMermaidGraphStyles(nodeColors) {\n\tlet styles = \"\";\n\tfor (const [className, color] of Object.entries(nodeColors)) styles += `\\tclassDef ${className} ${color};\\n`;\n\treturn styles;\n}\n/**\n* Draws a Mermaid graph using the provided graph data\n*/\nfunction drawMermaid(nodes, edges, config) {\n\tconst { firstNode, lastNode, nodeColors, withStyles = true, curveStyle = \"linear\", wrapLabelNWords = 9 } = config ?? {};\n\tlet mermaidGraph = withStyles ? `%%{init: {'flowchart': {'curve': '${curveStyle}'}}}%%\\ngraph TD;\\n` : \"graph TD;\\n\";\n\tif (withStyles) {\n\t\tconst defaultClassLabel = \"default\";\n\t\tconst formatDict = { [defaultClassLabel]: \"{0}({1})\" };\n\t\tif (firstNode !== void 0) formatDict[firstNode] = \"{0}([{1}]):::first\";\n\t\tif (lastNode !== void 0) formatDict[lastNode] = \"{0}([{1}]):::last\";\n\t\tfor (const [key, node] of Object.entries(nodes)) {\n\t\t\tconst nodeName = node.name.split(\":\").pop() ?? \"\";\n\t\t\tconst label = MARKDOWN_SPECIAL_CHARS.some((char) => nodeName.startsWith(char) && nodeName.endsWith(char)) ? `<p>${nodeName}</p>` : nodeName;\n\t\t\tlet finalLabel = label;\n\t\t\tif (Object.keys(node.metadata ?? {}).length) finalLabel += `<hr/><small><em>${Object.entries(node.metadata ?? {}).map(([k, v]) => `${k} = ${v}`).join(\"\\n\")}</em></small>`;\n\t\t\tconst nodeLabel = (formatDict[key] ?? formatDict[defaultClassLabel]).replace(\"{0}\", _escapeNodeLabel(key)).replace(\"{1}\", finalLabel);\n\t\t\tmermaidGraph += `\\t${nodeLabel}\\n`;\n\t\t}\n\t}\n\tconst edgeGroups = {};\n\tfor (const edge of edges) {\n\t\tconst srcParts = edge.source.split(\":\");\n\t\tconst tgtParts = edge.target.split(\":\");\n\t\tconst commonPrefix = srcParts.filter((src, i) => src === tgtParts[i]).join(\":\");\n\t\tif (!edgeGroups[commonPrefix]) edgeGroups[commonPrefix] = [];\n\t\tedgeGroups[commonPrefix].push(edge);\n\t}\n\tconst seenSubgraphs = /* @__PURE__ */ new Set();\n\tfunction sortPrefixesByDepth(prefixes) {\n\t\treturn [...prefixes].sort((a, b) => {\n\t\t\treturn a.split(\":\").length - b.split(\":\").length;\n\t\t});\n\t}\n\tfunction addSubgraph(edges$1, prefix) {\n\t\tconst selfLoop = edges$1.length === 1 && edges$1[0].source === edges$1[0].target;\n\t\tif (prefix && !selfLoop) {\n\t\t\tconst subgraph = prefix.split(\":\").pop();\n\t\t\tif (seenSubgraphs.has(prefix)) throw new Error(`Found duplicate subgraph '${subgraph}' at '${prefix} -- this likely means that you're reusing a subgraph node with the same name. Please adjust your graph to have subgraph nodes with unique names.`);\n\t\t\tseenSubgraphs.add(prefix);\n\t\t\tmermaidGraph += `\\tsubgraph ${subgraph}\\n`;\n\t\t}\n\t\tconst nestedPrefixes = sortPrefixesByDepth(Object.keys(edgeGroups).filter((nestedPrefix) => nestedPrefix.startsWith(`${prefix}:`) && nestedPrefix !== prefix && nestedPrefix.split(\":\").length === prefix.split(\":\").length + 1));\n\t\tfor (const nestedPrefix of nestedPrefixes) addSubgraph(edgeGroups[nestedPrefix], nestedPrefix);\n\t\tfor (const edge of edges$1) {\n\t\t\tconst { source, target, data, conditional } = edge;\n\t\t\tlet edgeLabel = \"\";\n\t\t\tif (data !== void 0) {\n\t\t\t\tlet edgeData = data;\n\t\t\t\tconst words = edgeData.split(\" \");\n\t\t\t\tif (words.length > wrapLabelNWords) edgeData = Array.from({ length: Math.ceil(words.length / wrapLabelNWords) }, (_, i) => words.slice(i * wrapLabelNWords, (i + 1) * wrapLabelNWords).join(\" \")).join(\"&nbsp;<br>&nbsp;\");\n\t\t\t\tedgeLabel = conditional ? ` -. &nbsp;${edgeData}&nbsp; .-> ` : ` -- &nbsp;${edgeData}&nbsp; --> `;\n\t\t\t} else edgeLabel = conditional ? \" -.-> \" : \" --> \";\n\t\t\tmermaidGraph += `\\t${_escapeNodeLabel(source)}${edgeLabel}${_escapeNodeLabel(target)};\\n`;\n\t\t}\n\t\tif (prefix && !selfLoop) mermaidGraph += \"\tend\\n\";\n\t}\n\taddSubgraph(edgeGroups[\"\"] ?? [], \"\");\n\tfor (const prefix in edgeGroups) if (!prefix.includes(\":\") && prefix !== \"\") addSubgraph(edgeGroups[prefix], prefix);\n\tif (withStyles) mermaidGraph += _generateMermaidGraphStyles(nodeColors ?? {});\n\treturn mermaidGraph;\n}\n/**\n* Renders Mermaid graph using the Mermaid.INK API.\n*\n* @example\n* ```javascript\n* const image = await drawMermaidImage(mermaidSyntax, {\n* backgroundColor: \"white\",\n* imageType: \"png\",\n* });\n* fs.writeFileSync(\"image.png\", image);\n* ```\n*\n* @param mermaidSyntax - The Mermaid syntax to render.\n* @param config - The configuration for the image.\n* @returns The image as a Blob.\n*/\nasync function drawMermaidImage(mermaidSyntax, config) {\n\tlet backgroundColor = config?.backgroundColor ?? \"white\";\n\tconst imageType = config?.imageType ?? \"png\";\n\tconst mermaidSyntaxEncoded = toBase64Url(mermaidSyntax);\n\tif (backgroundColor !== void 0) {\n\t\tconst hexColorPattern = /^#(?:[0-9a-fA-F]{3}){1,2}$/;\n\t\tif (!hexColorPattern.test(backgroundColor)) backgroundColor = `!${backgroundColor}`;\n\t}\n\tconst imageUrl = `https://mermaid.ink/img/${mermaidSyntaxEncoded}?bgColor=${backgroundColor}&type=${imageType}`;\n\tconst res = await fetch(imageUrl);\n\tif (!res.ok) throw new Error([\n\t\t`Failed to render the graph using the Mermaid.INK API.`,\n\t\t`Status code: ${res.status}`,\n\t\t`Status text: ${res.statusText}`\n\t].join(\"\\n\"));\n\tconst content = await res.blob();\n\treturn content;\n}\n\n//#endregion\nexport { drawMermaid, drawMermaidImage };\n//# sourceMappingURL=graph_mermaid.js.map"],"names":[],"mappings":";AAGA,SAAS,iBAAiB,WAAW;AACpC,SAAO,UAAU,QAAQ,mBAAmB,GAAG;AAChD;AACA,MAAM,yBAAyB;AAAA,EAC9B;AAAA,EACA;AAAA,EACA;AACD;AACA,SAAS,4BAA4B,YAAY;AAChD,MAAI,SAAS;AACb,aAAW,CAAC,WAAW,KAAK,KAAK,OAAO,QAAQ,UAAU,EAAG,WAAU,aAAc,SAAS,IAAI,KAAK;AAAA;AACvG,SAAO;AACR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ent":["import * as core from \"./core.js\";\nimport * as errors from \"./errors.js\";\nimport * as util from \"./util.js\";\nexport const _parse = (_Err) => (schema, value, _ctx, _params) => {\n const ctx = _ctx ? Object.assign(_ctx, { async: false }) : { async: false };\n const result = schema._zod.run({ value, issues: [] }, ctx);\n if (result instanceof Promise) {\n throw new core.$ZodAsyncError();\n }\n if (result.issues.length) {\n const e = new (_params?.Err ?? _Err)(result.issues.map((iss) => util.finalizeIssue(iss, ctx, core.config())));\n util.captureStackTrace(e, _params?.callee);\n throw e;\n }\n return result.value;\n};\nexport const parse = /* @__PURE__*/ _parse(errors.$ZodRealError);\nexport const _parseAsync = (_Err) => async (schema, value, _ctx, params) => {\n const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };\n let result = schema._zod.run({ value, issues: [] }, ctx);\n if (result instanceof Promise)\n result = await result;\n if (result.issues.length) {\n const e = new (params?.Err ?? _Err)(result.issues.map((iss) => util.finalizeIssue(iss, ctx, core.config())));\n util.captureStackTrace(e, params?.callee);\n throw e;\n }\n return result.value;\n};\nexport const parseAsync = /* @__PURE__*/ _parseAsync(errors.$ZodRealError);\nexport const _safeParse = (_Err) => (schema, value, _ctx) => {\n const ctx = _ctx ? { ..._ctx, async: false } : { async: false };\n const result = schema._zod.run({ value, issues: [] }, ctx);\n if (result instanceof Promise) {\n throw new core.$ZodAsyncError();\n }\n return result.issues.length\n ? {\n success: false,\n error: new (_Err ?? errors.$ZodError)(result.issues.map((iss) => util.finalizeIssue(iss, ctx, core.config()))),\n }\n : { success: true, data: result.value };\n};\nexport const safeParse = /* @__PURE__*/ _safeParse(errors.$ZodRealError);\nexport const _safeParseAsync = (_Err) => async (schema, value, _ctx) => {\n const ctx = _ctx ? Object.assign(_ctx, { async: true }) : { async: true };\n let result = schema._zod.run({ value, issues: [] }, ctx);\n if (result instanceof Promise)\n result = await result;\n return result.issues.length\n ? {\n success: false,\n error: new _Err(result.issues.map((iss) => util.finalizeIssue(iss, ctx, core.config()))),\n }\n : { success: true, data: result.value };\n};\nexport const safeParseAsync = /* @__PURE__*/ _safeParseAsync(errors.$ZodRealError);\nexport const _encode = (_Err) => (schema, value, _ctx) => {\n const ctx = _ctx ? Object.assign(_ctx, { direction: \"backward\" }) : { direction: \"backward\" };\n return _parse(_Err)(schema, value, ctx);\n};\nexport const encode = /* @__PURE__*/ _encode(errors.$ZodRealError);\nexport const _decode = (_Err) => (schema, value, _ctx) => {\n return _parse(_Err)(schema, value, _ctx);\n};\nexport const decode = /* @__PURE__*/ _decode(errors.$ZodRealError);\nexport const _encodeAsync = (_Err) => async (schema, value, _ctx) => {\n const ctx = _ctx ? Object.assign(_ctx, { direction: \"backward\" }) : { direction: \"backward\" };\n return _parseAsync(_Err)(schema, value, ctx);\n};\nexport const encodeAsync = /* @__PURE__*/ _encodeAsync(errors.$ZodRealError);\nexport const _decodeAsync = (_Err) => async (schema, value, _ctx) => {\n return _parseAsync(_Err)(schema, value, _ctx);\n};\nexport const decodeAsync = /* @__PURE__*/ _decodeAsync(errors.$ZodRealError);\nexport const _safeEncode = (_Err) => (schema, value, _ctx) => {\n const ctx = _ctx ? Object.assign(_ctx, { direction: \"backward\" }) : { direction: \"backward\" };\n return _safeParse(_Err)(schema, value, ctx);\n};\nexport const safeEncode = /* @__PURE__*/ _safeEncode(errors.$ZodRealError);\nexport const _safeDecode = (_Err) => (schema, value, _ctx) => {\n return _safeParse(_Err)(schema, value, _ctx);\n};\nexport const safeDecode = /* @__PURE__*/ _safeDecode(errors.$ZodRealError);\nexport const _safeEncodeAsync = (_Err) => async (schema, value, _ctx) => {\n const ctx = _ctx ? Object.assign(_ctx, { direction: \"backward\" }) : { direction: \"backward\" };\n return _safeParseAsync(_Err)(schema, value, ctx);\n};\nexport const safeEncodeAsync = /* @__PURE__*/ _safeEncodeAsync(errors.$ZodRealError);\nexport const _safeDecodeAsync = (_Err) => async (schema, value, _ctx) => {\n return _safeParseAsync(_Err)(schema, value, _ctx);\n};\nexport const safeDecodeAsync = /* @__PURE__*/ _safeDecodeAsync(errors.$ZodRealError);\n"],"names":["util.finalizeIssue","core.config","util.captureStackTrace","errors.$ZodRealError","core.$ZodAsyncError","errors.$ZodError"],"mappings":";;;AAiBY,MAAC,cAAc,CAAC,SAAS,OAAO,QAAQ,OAAO,MAAM,WAAW;AACxE,QAAM,MAAM,OAAO,OAAO,OAAO,MAAM,EAAE,OAAO,KAAI,CAAE,IAAI,EAAE,OAAO,KAAI;AACvE,MAAI,SAAS,OAAO,KAAK,IAAI,EAAE,OAAO,QAAQ,GAAE,GAAI,GAAG;AACvD,MAAI,kBAAkB;AAClB,aAAS,MAAM;AACnB,MAAI,OAAO,OAAO,QAAQ;AACtB,UAAM,IAAI,KAAK,QAAQ,OAAO,MAAM,OAAO,OAAO,IAAI,CAAC,QAAQA,cAAmB,KAAK,KAAKC,OAAW,CAAE,CAAC,CAAC;AAC3GC,sBAAuB,GAAG,QAAQ,MAAM;AACxC,UAAM;AAAA,EACV;AACA,SAAO,OAAO;AAClB;AACY,MAAC,aAA4B,4BAAYC,aAAoB;AAC7D,MAAC,aAAa,CAAC,SAAS,CAAC,QAAQ,OAAO,SAAS;AACzD,QAAM,MAAM,OAAO,EAAE,GAAG,MAAM,OAAO,MAAK,IAAK,EAAE,OAAO,MAAK;AAC7D,QAAM,SAAS,OAAO,KAAK,IAAI,EAAE,OAAO,QAAQ,GAAE,GAAI,GAAG;AACzD,MAAI,kBAAkB,SAAS;AAC3B,UAAM,IAAIC,eAAmB;AAAA,EACjC;AACA,SAAO,OAAO,OAAO,SACf;AAAA,IACE,SAAS;AAAA,IACT,OAAO,KAAK,QAAQC,WAAkB,OAAO,OAAO,IAAI,CAAC,QAAQL,cAAmB,KAAK,KAAKC,OAAW,CAAE,CAAC,CAAC;AAAA,EACzH,IACU,EAAE,SAAS,MAAM,MAAM,OAAO,MAAK;AAC7C;AACY,MAAC,YAA2B,2BAAWE,aAAoB;AAC3D,MAAC,kBAAkB,CAAC,SAAS,OAAO,QAAQ,OAAO,SAAS;AACpE,QAAM,MAAM,OAAO,OAAO,OAAO,MAAM,EAAE,OAAO,KAAI,CAAE,IAAI,EAAE,OAAO,KAAI;AACvE,MAAI,SAAS,OAAO,KAAK,IAAI,EAAE,OAAO,QAAQ,GAAE,GAAI,GAAG;AACvD,MAAI,kBAAkB;AAClB,aAAS,MAAM;AACnB,SAAO,OAAO,OAAO,SACf;AAAA,IACE,SAAS;AAAA,IACT,OAAO,IAAI,KAAK,OAAO,OAAO,IAAI,CAAC,QAAQH,cAAmB,KAAK,KAAKC,OAAW,CAAE,CAAC,CAAC;AAAA,EACnG,IACU,EAAE,SAAS,MAAM,MAAM,OAAO,MAAK;AAC7C;AACY,MAAC,iBAAgC,gCAAgBE,aAAoB;","x_google_ignoreList":[0]}
@@ -1,56 +1,102 @@
1
- import { __export } from "./index.es52.js";
2
- import { isZodSchemaV4, interopZodTransformInputSchema, isZodObjectV4, interopZodObjectStrict, isZodSchemaV3 } from "./index.es103.js";
3
- import { zodToJsonSchema } from "./index.es245.js";
4
- import { deepCompareStrict } from "./index.es246.js";
5
- import { Validator } from "./index.es247.js";
6
- import { toJSONSchema } from "./index.es248.js";
7
- import { dereference } from "./index.es249.js";
8
- var json_schema_exports = {};
9
- __export(json_schema_exports, {
10
- Validator: () => Validator,
11
- deepCompareStrict: () => deepCompareStrict,
12
- toJsonSchema: () => toJsonSchema,
13
- validatesOnlyStrings: () => validatesOnlyStrings
14
- });
15
- function toJsonSchema(schema, params) {
16
- if (isZodSchemaV4(schema)) {
17
- const inputSchema = interopZodTransformInputSchema(schema, true);
18
- if (isZodObjectV4(inputSchema)) {
19
- const strictSchema = interopZodObjectStrict(inputSchema, true);
20
- return toJSONSchema(strictSchema, params);
21
- } else return toJSONSchema(schema, params);
22
- }
23
- if (isZodSchemaV3(schema)) return zodToJsonSchema(schema);
24
- return schema;
1
+ import { toBase64Url } from "./index.es103.js";
2
+ function _escapeNodeLabel(nodeLabel) {
3
+ return nodeLabel.replace(/[^a-zA-Z-_0-9]/g, "_");
4
+ }
5
+ const MARKDOWN_SPECIAL_CHARS = [
6
+ "*",
7
+ "_",
8
+ "`"
9
+ ];
10
+ function _generateMermaidGraphStyles(nodeColors) {
11
+ let styles = "";
12
+ for (const [className, color] of Object.entries(nodeColors)) styles += ` classDef ${className} ${color};
13
+ `;
14
+ return styles;
25
15
  }
26
- function validatesOnlyStrings(schema) {
27
- if (!schema || typeof schema !== "object" || Object.keys(schema).length === 0 || Array.isArray(schema)) return false;
28
- if ("type" in schema) {
29
- if (typeof schema.type === "string") return schema.type === "string";
30
- if (Array.isArray(schema.type)) return schema.type.every((t) => t === "string");
31
- return false;
16
+ function drawMermaid(nodes, edges, config) {
17
+ const { firstNode, lastNode, nodeColors, withStyles = true, curveStyle = "linear", wrapLabelNWords = 9 } = config ?? {};
18
+ let mermaidGraph = withStyles ? `%%{init: {'flowchart': {'curve': '${curveStyle}'}}}%%
19
+ graph TD;
20
+ ` : "graph TD;\n";
21
+ if (withStyles) {
22
+ const defaultClassLabel = "default";
23
+ const formatDict = { [defaultClassLabel]: "{0}({1})" };
24
+ if (firstNode !== void 0) formatDict[firstNode] = "{0}([{1}]):::first";
25
+ if (lastNode !== void 0) formatDict[lastNode] = "{0}([{1}]):::last";
26
+ for (const [key, node] of Object.entries(nodes)) {
27
+ const nodeName = node.name.split(":").pop() ?? "";
28
+ const label = MARKDOWN_SPECIAL_CHARS.some((char) => nodeName.startsWith(char) && nodeName.endsWith(char)) ? `<p>${nodeName}</p>` : nodeName;
29
+ let finalLabel = label;
30
+ if (Object.keys(node.metadata ?? {}).length) finalLabel += `<hr/><small><em>${Object.entries(node.metadata ?? {}).map(([k, v]) => `${k} = ${v}`).join("\n")}</em></small>`;
31
+ const nodeLabel = (formatDict[key] ?? formatDict[defaultClassLabel]).replace("{0}", _escapeNodeLabel(key)).replace("{1}", finalLabel);
32
+ mermaidGraph += ` ${nodeLabel}
33
+ `;
34
+ }
35
+ }
36
+ const edgeGroups = {};
37
+ for (const edge of edges) {
38
+ const srcParts = edge.source.split(":");
39
+ const tgtParts = edge.target.split(":");
40
+ const commonPrefix = srcParts.filter((src, i) => src === tgtParts[i]).join(":");
41
+ if (!edgeGroups[commonPrefix]) edgeGroups[commonPrefix] = [];
42
+ edgeGroups[commonPrefix].push(edge);
32
43
  }
33
- if ("enum" in schema) return Array.isArray(schema.enum) && schema.enum.length > 0 && schema.enum.every((val) => typeof val === "string");
34
- if ("const" in schema) return typeof schema.const === "string";
35
- if ("allOf" in schema && Array.isArray(schema.allOf)) return schema.allOf.some((subschema) => validatesOnlyStrings(subschema));
36
- if ("anyOf" in schema && Array.isArray(schema.anyOf) || "oneOf" in schema && Array.isArray(schema.oneOf)) {
37
- const subschemas = "anyOf" in schema ? schema.anyOf : schema.oneOf;
38
- return subschemas.length > 0 && subschemas.every((subschema) => validatesOnlyStrings(subschema));
44
+ const seenSubgraphs = /* @__PURE__ */ new Set();
45
+ function sortPrefixesByDepth(prefixes) {
46
+ return [...prefixes].sort((a, b) => {
47
+ return a.split(":").length - b.split(":").length;
48
+ });
39
49
  }
40
- if ("not" in schema) return false;
41
- if ("$ref" in schema && typeof schema.$ref === "string") {
42
- const ref = schema.$ref;
43
- const resolved = dereference(schema);
44
- if (resolved[ref]) return validatesOnlyStrings(resolved[ref]);
45
- return false;
50
+ function addSubgraph(edges$1, prefix) {
51
+ const selfLoop = edges$1.length === 1 && edges$1[0].source === edges$1[0].target;
52
+ if (prefix && !selfLoop) {
53
+ const subgraph = prefix.split(":").pop();
54
+ if (seenSubgraphs.has(prefix)) throw new Error(`Found duplicate subgraph '${subgraph}' at '${prefix} -- this likely means that you're reusing a subgraph node with the same name. Please adjust your graph to have subgraph nodes with unique names.`);
55
+ seenSubgraphs.add(prefix);
56
+ mermaidGraph += ` subgraph ${subgraph}
57
+ `;
58
+ }
59
+ const nestedPrefixes = sortPrefixesByDepth(Object.keys(edgeGroups).filter((nestedPrefix) => nestedPrefix.startsWith(`${prefix}:`) && nestedPrefix !== prefix && nestedPrefix.split(":").length === prefix.split(":").length + 1));
60
+ for (const nestedPrefix of nestedPrefixes) addSubgraph(edgeGroups[nestedPrefix], nestedPrefix);
61
+ for (const edge of edges$1) {
62
+ const { source, target, data, conditional } = edge;
63
+ let edgeLabel = "";
64
+ if (data !== void 0) {
65
+ let edgeData = data;
66
+ const words = edgeData.split(" ");
67
+ if (words.length > wrapLabelNWords) edgeData = Array.from({ length: Math.ceil(words.length / wrapLabelNWords) }, (_, i) => words.slice(i * wrapLabelNWords, (i + 1) * wrapLabelNWords).join(" ")).join("&nbsp;<br>&nbsp;");
68
+ edgeLabel = conditional ? ` -. &nbsp;${edgeData}&nbsp; .-> ` : ` -- &nbsp;${edgeData}&nbsp; --> `;
69
+ } else edgeLabel = conditional ? " -.-> " : " --> ";
70
+ mermaidGraph += ` ${_escapeNodeLabel(source)}${edgeLabel}${_escapeNodeLabel(target)};
71
+ `;
72
+ }
73
+ if (prefix && !selfLoop) mermaidGraph += " end\n";
74
+ }
75
+ addSubgraph(edgeGroups[""] ?? [], "");
76
+ for (const prefix in edgeGroups) if (!prefix.includes(":") && prefix !== "") addSubgraph(edgeGroups[prefix], prefix);
77
+ if (withStyles) mermaidGraph += _generateMermaidGraphStyles(nodeColors ?? {});
78
+ return mermaidGraph;
79
+ }
80
+ async function drawMermaidImage(mermaidSyntax, config) {
81
+ let backgroundColor = config?.backgroundColor ?? "white";
82
+ const imageType = config?.imageType ?? "png";
83
+ const mermaidSyntaxEncoded = toBase64Url(mermaidSyntax);
84
+ if (backgroundColor !== void 0) {
85
+ const hexColorPattern = /^#(?:[0-9a-fA-F]{3}){1,2}$/;
86
+ if (!hexColorPattern.test(backgroundColor)) backgroundColor = `!${backgroundColor}`;
46
87
  }
47
- return false;
88
+ const imageUrl = `https://mermaid.ink/img/${mermaidSyntaxEncoded}?bgColor=${backgroundColor}&type=${imageType}`;
89
+ const res = await fetch(imageUrl);
90
+ if (!res.ok) throw new Error([
91
+ `Failed to render the graph using the Mermaid.INK API.`,
92
+ `Status code: ${res.status}`,
93
+ `Status text: ${res.statusText}`
94
+ ].join("\n"));
95
+ const content = await res.blob();
96
+ return content;
48
97
  }
49
98
  export {
50
- Validator,
51
- deepCompareStrict,
52
- json_schema_exports,
53
- toJsonSchema,
54
- validatesOnlyStrings
99
+ drawMermaid,
100
+ drawMermaidImage
55
101
  };
56
102
  //# sourceMappingURL=index.es132.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.es132.js","sources":["../node_modules/.pnpm/@langchain+core@1.1.13_openai@6.16.0_zod@4.3.5_/node_modules/@langchain/core/dist/utils/json_schema.js"],"sourcesContent":["import { __export } from \"../_virtual/rolldown_runtime.js\";\nimport { interopZodObjectStrict, interopZodTransformInputSchema, isZodObjectV4, isZodSchemaV3, isZodSchemaV4 } from \"./types/zod.js\";\nimport { zodToJsonSchema } from \"./zod-to-json-schema/zodToJsonSchema.js\";\nimport \"./zod-to-json-schema/index.js\";\nimport { toJSONSchema } from \"zod/v4/core\";\nimport { Validator, deepCompareStrict, dereference } from \"@cfworker/json-schema\";\n\n//#region src/utils/json_schema.ts\nvar json_schema_exports = {};\n__export(json_schema_exports, {\n\tValidator: () => Validator,\n\tdeepCompareStrict: () => deepCompareStrict,\n\ttoJsonSchema: () => toJsonSchema,\n\tvalidatesOnlyStrings: () => validatesOnlyStrings\n});\n/**\n* Converts a Zod schema or JSON schema to a JSON schema.\n* @param schema - The schema to convert.\n* @param params - The parameters to pass to the toJSONSchema function.\n* @returns The converted schema.\n*/\nfunction toJsonSchema(schema, params) {\n\tif (isZodSchemaV4(schema)) {\n\t\tconst inputSchema = interopZodTransformInputSchema(schema, true);\n\t\tif (isZodObjectV4(inputSchema)) {\n\t\t\tconst strictSchema = interopZodObjectStrict(inputSchema, true);\n\t\t\treturn toJSONSchema(strictSchema, params);\n\t\t} else return toJSONSchema(schema, params);\n\t}\n\tif (isZodSchemaV3(schema)) return zodToJsonSchema(schema);\n\treturn schema;\n}\n/**\n* Validates if a JSON schema validates only strings. May return false negatives in some edge cases\n* (like recursive or unresolvable refs).\n*\n* @param schema - The schema to validate.\n* @returns `true` if the schema validates only strings, `false` otherwise.\n*/\nfunction validatesOnlyStrings(schema) {\n\tif (!schema || typeof schema !== \"object\" || Object.keys(schema).length === 0 || Array.isArray(schema)) return false;\n\tif (\"type\" in schema) {\n\t\tif (typeof schema.type === \"string\") return schema.type === \"string\";\n\t\tif (Array.isArray(schema.type)) return schema.type.every((t) => t === \"string\");\n\t\treturn false;\n\t}\n\tif (\"enum\" in schema) return Array.isArray(schema.enum) && schema.enum.length > 0 && schema.enum.every((val) => typeof val === \"string\");\n\tif (\"const\" in schema) return typeof schema.const === \"string\";\n\tif (\"allOf\" in schema && Array.isArray(schema.allOf)) return schema.allOf.some((subschema) => validatesOnlyStrings(subschema));\n\tif (\"anyOf\" in schema && Array.isArray(schema.anyOf) || \"oneOf\" in schema && Array.isArray(schema.oneOf)) {\n\t\tconst subschemas = \"anyOf\" in schema ? schema.anyOf : schema.oneOf;\n\t\treturn subschemas.length > 0 && subschemas.every((subschema) => validatesOnlyStrings(subschema));\n\t}\n\tif (\"not\" in schema) return false;\n\tif (\"$ref\" in schema && typeof schema.$ref === \"string\") {\n\t\tconst ref = schema.$ref;\n\t\tconst resolved = dereference(schema);\n\t\tif (resolved[ref]) return validatesOnlyStrings(resolved[ref]);\n\t\treturn false;\n\t}\n\treturn false;\n}\n\n//#endregion\nexport { Validator, deepCompareStrict, json_schema_exports, toJsonSchema, validatesOnlyStrings };\n//# sourceMappingURL=json_schema.js.map"],"names":[],"mappings":";;;;;;;AAQG,IAAC,sBAAsB,CAAA;AAC1B,SAAS,qBAAqB;AAAA,EAC7B,WAAW,MAAM;AAAA,EACjB,mBAAmB,MAAM;AAAA,EACzB,cAAc,MAAM;AAAA,EACpB,sBAAsB,MAAM;AAC7B,CAAC;AAOD,SAAS,aAAa,QAAQ,QAAQ;AACrC,MAAI,cAAc,MAAM,GAAG;AAC1B,UAAM,cAAc,+BAA+B,QAAQ,IAAI;AAC/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AAI,SAAS,GAAG,EAAG,QAAO,qBAAqB,SAAS,GAAG,CAAC;AAC5D,WAAO;AAAA,EACR;AACA,SAAO;AACR;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index.es132.js","sources":["../node_modules/.pnpm/@langchain+core@1.1.13_openai@6.16.0_zod@4.3.5_/node_modules/@langchain/core/dist/runnables/graph_mermaid.js"],"sourcesContent":["import { toBase64Url } from \"./utils.js\";\n\n//#region src/runnables/graph_mermaid.ts\nfunction _escapeNodeLabel(nodeLabel) {\n\treturn nodeLabel.replace(/[^a-zA-Z-_0-9]/g, \"_\");\n}\nconst MARKDOWN_SPECIAL_CHARS = [\n\t\"*\",\n\t\"_\",\n\t\"`\"\n];\nfunction _generateMermaidGraphStyles(nodeColors) {\n\tlet styles = \"\";\n\tfor (const [className, color] of Object.entries(nodeColors)) styles += `\\tclassDef ${className} ${color};\\n`;\n\treturn styles;\n}\n/**\n* Draws a Mermaid graph using the provided graph data\n*/\nfunction drawMermaid(nodes, edges, config) {\n\tconst { firstNode, lastNode, nodeColors, withStyles = true, curveStyle = \"linear\", wrapLabelNWords = 9 } = config ?? {};\n\tlet mermaidGraph = withStyles ? `%%{init: {'flowchart': {'curve': '${curveStyle}'}}}%%\\ngraph TD;\\n` : \"graph TD;\\n\";\n\tif (withStyles) {\n\t\tconst defaultClassLabel = \"default\";\n\t\tconst formatDict = { [defaultClassLabel]: \"{0}({1})\" };\n\t\tif (firstNode !== void 0) formatDict[firstNode] = \"{0}([{1}]):::first\";\n\t\tif (lastNode !== void 0) formatDict[lastNode] = \"{0}([{1}]):::last\";\n\t\tfor (const [key, node] of Object.entries(nodes)) {\n\t\t\tconst nodeName = node.name.split(\":\").pop() ?? \"\";\n\t\t\tconst label = MARKDOWN_SPECIAL_CHARS.some((char) => nodeName.startsWith(char) && nodeName.endsWith(char)) ? `<p>${nodeName}</p>` : nodeName;\n\t\t\tlet finalLabel = label;\n\t\t\tif (Object.keys(node.metadata ?? {}).length) finalLabel += `<hr/><small><em>${Object.entries(node.metadata ?? {}).map(([k, v]) => `${k} = ${v}`).join(\"\\n\")}</em></small>`;\n\t\t\tconst nodeLabel = (formatDict[key] ?? formatDict[defaultClassLabel]).replace(\"{0}\", _escapeNodeLabel(key)).replace(\"{1}\", finalLabel);\n\t\t\tmermaidGraph += `\\t${nodeLabel}\\n`;\n\t\t}\n\t}\n\tconst edgeGroups = {};\n\tfor (const edge of edges) {\n\t\tconst srcParts = edge.source.split(\":\");\n\t\tconst tgtParts = edge.target.split(\":\");\n\t\tconst commonPrefix = srcParts.filter((src, i) => src === tgtParts[i]).join(\":\");\n\t\tif (!edgeGroups[commonPrefix]) edgeGroups[commonPrefix] = [];\n\t\tedgeGroups[commonPrefix].push(edge);\n\t}\n\tconst seenSubgraphs = /* @__PURE__ */ new Set();\n\tfunction sortPrefixesByDepth(prefixes) {\n\t\treturn [...prefixes].sort((a, b) => {\n\t\t\treturn a.split(\":\").length - b.split(\":\").length;\n\t\t});\n\t}\n\tfunction addSubgraph(edges$1, prefix) {\n\t\tconst selfLoop = edges$1.length === 1 && edges$1[0].source === edges$1[0].target;\n\t\tif (prefix && !selfLoop) {\n\t\t\tconst subgraph = prefix.split(\":\").pop();\n\t\t\tif (seenSubgraphs.has(prefix)) throw new Error(`Found duplicate subgraph '${subgraph}' at '${prefix} -- this likely means that you're reusing a subgraph node with the same name. Please adjust your graph to have subgraph nodes with unique names.`);\n\t\t\tseenSubgraphs.add(prefix);\n\t\t\tmermaidGraph += `\\tsubgraph ${subgraph}\\n`;\n\t\t}\n\t\tconst nestedPrefixes = sortPrefixesByDepth(Object.keys(edgeGroups).filter((nestedPrefix) => nestedPrefix.startsWith(`${prefix}:`) && nestedPrefix !== prefix && nestedPrefix.split(\":\").length === prefix.split(\":\").length + 1));\n\t\tfor (const nestedPrefix of nestedPrefixes) addSubgraph(edgeGroups[nestedPrefix], nestedPrefix);\n\t\tfor (const edge of edges$1) {\n\t\t\tconst { source, target, data, conditional } = edge;\n\t\t\tlet edgeLabel = \"\";\n\t\t\tif (data !== void 0) {\n\t\t\t\tlet edgeData = data;\n\t\t\t\tconst words = edgeData.split(\" \");\n\t\t\t\tif (words.length > wrapLabelNWords) edgeData = Array.from({ length: Math.ceil(words.length / wrapLabelNWords) }, (_, i) => words.slice(i * wrapLabelNWords, (i + 1) * wrapLabelNWords).join(\" \")).join(\"&nbsp;<br>&nbsp;\");\n\t\t\t\tedgeLabel = conditional ? ` -. &nbsp;${edgeData}&nbsp; .-> ` : ` -- &nbsp;${edgeData}&nbsp; --> `;\n\t\t\t} else edgeLabel = conditional ? \" -.-> \" : \" --> \";\n\t\t\tmermaidGraph += `\\t${_escapeNodeLabel(source)}${edgeLabel}${_escapeNodeLabel(target)};\\n`;\n\t\t}\n\t\tif (prefix && !selfLoop) mermaidGraph += \"\tend\\n\";\n\t}\n\taddSubgraph(edgeGroups[\"\"] ?? [], \"\");\n\tfor (const prefix in edgeGroups) if (!prefix.includes(\":\") && prefix !== \"\") addSubgraph(edgeGroups[prefix], prefix);\n\tif (withStyles) mermaidGraph += _generateMermaidGraphStyles(nodeColors ?? {});\n\treturn mermaidGraph;\n}\n/**\n* Renders Mermaid graph using the Mermaid.INK API.\n*\n* @example\n* ```javascript\n* const image = await drawMermaidImage(mermaidSyntax, {\n* backgroundColor: \"white\",\n* imageType: \"png\",\n* });\n* fs.writeFileSync(\"image.png\", image);\n* ```\n*\n* @param mermaidSyntax - The Mermaid syntax to render.\n* @param config - The configuration for the image.\n* @returns The image as a Blob.\n*/\nasync function drawMermaidImage(mermaidSyntax, config) {\n\tlet backgroundColor = config?.backgroundColor ?? \"white\";\n\tconst imageType = config?.imageType ?? \"png\";\n\tconst mermaidSyntaxEncoded = toBase64Url(mermaidSyntax);\n\tif (backgroundColor !== void 0) {\n\t\tconst hexColorPattern = /^#(?:[0-9a-fA-F]{3}){1,2}$/;\n\t\tif (!hexColorPattern.test(backgroundColor)) backgroundColor = `!${backgroundColor}`;\n\t}\n\tconst imageUrl = `https://mermaid.ink/img/${mermaidSyntaxEncoded}?bgColor=${backgroundColor}&type=${imageType}`;\n\tconst res = await fetch(imageUrl);\n\tif (!res.ok) throw new Error([\n\t\t`Failed to render the graph using the Mermaid.INK API.`,\n\t\t`Status code: ${res.status}`,\n\t\t`Status text: ${res.statusText}`\n\t].join(\"\\n\"));\n\tconst content = await res.blob();\n\treturn content;\n}\n\n//#endregion\nexport { drawMermaid, drawMermaidImage };\n//# sourceMappingURL=graph_mermaid.js.map"],"names":[],"mappings":";AAGA,SAAS,iBAAiB,WAAW;AACpC,SAAO,UAAU,QAAQ,mBAAmB,GAAG;AAChD;AACA,MAAM,yBAAyB;AAAA,EAC9B;AAAA,EACA;AAAA,EACA;AACD;AACA,SAAS,4BAA4B,YAAY;AAChD,MAAI,SAAS;AACb,aAAW,CAAC,WAAW,KAAK,KAAK,OAAO,QAAQ,UAAU,EAAG,WAAU,aAAc,SAAS,IAAI,KAAK;AAAA;AACvG,SAAO;AACR;AAIA,SAAS,YAAY,OAAO,OAAO,QAAQ;AAC1C,QAAM,EAAE,WAAW,UAAU,YAAY,aAAa,MAAM,aAAa,UAAU,kBAAkB,EAAC,IAAK,UAAU,CAAA;AACrH,MAAI,eAAe,aAAa,qCAAqC,UAAU;AAAA;AAAA,IAAwB;AACvG,MAAI,YAAY;AACf,UAAM,oBAAoB;AAC1B,UAAM,aAAa,EAAE,CAAC,iBAAiB,GAAG,WAAU;AACpD,QAAI,cAAc,OAAQ,YAAW,SAAS,IAAI;AAClD,QAAI,aAAa,OAAQ,YAAW,QAAQ,IAAI;AAChD,eAAW,CAAC,KAAK,IAAI,KAAK,OAAO,QAAQ,KAAK,GAAG;AAChD,YAAM,WAAW,KAAK,KAAK,MAAM,GAAG,EAAE,IAAG,KAAM;AAC/C,YAAM,QAAQ,uBAAuB,KAAK,CAAC,SAAS,SAAS,WAAW,IAAI,KAAK,SAAS,SAAS,IAAI,CAAC,IAAI,MAAM,QAAQ,SAAS;AACnI,UAAI,aAAa;AACjB,UA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,YAAY,QAAQ,aAAa;AACvC,QAAM,uBAAuB,YAAY,aAAa;AACtD,MAAI,oBAAoB,QAAQ;AAC/B,UAAM,kBAAkB;AACxB,QAAI,CAAC,gBAAgB,KAAK,eAAe,EAAG,mBAAkB,IAAI,eAAe;AAAA,EAClF;AACA,QAAM,WAAW,2BAA2B,oBAAoB,YAAY,eAAe,SAAS,SAAS;AAC7G,QAAM,MAAM,MAAM,MAAM,QAAQ;AAChC,MAAI,CAAC,IAAI,GAAI,OAAM,IAAI,MAAM;AAAA,IAC5B;AAAA,IACA,gBAAgB,IAAI,MAAM;AAAA,IAC1B,gBAAgB,IAAI,UAAU;AAAA,EAChC,EAAG,KAAK,IAAI,CAAC;AACZ,QAAM,UAAU,MAAM,IAAI,KAAI;AAC9B,SAAO;AACR;","x_google_ignoreList":[0]}
@@ -1,19 +1,56 @@
1
- function lowerBound(array, value, comparator) {
2
- let first = 0;
3
- let count = array.length;
4
- while (count > 0) {
5
- const step = Math.trunc(count / 2);
6
- let it = first + step;
7
- if (comparator(array[it], value) <= 0) {
8
- first = ++it;
9
- count -= step + 1;
10
- } else {
11
- count = step;
12
- }
1
+ import { __export } from "./index.es55.js";
2
+ import { isZodSchemaV4, interopZodTransformInputSchema, isZodObjectV4, interopZodObjectStrict, isZodSchemaV3 } from "./index.es104.js";
3
+ import { zodToJsonSchema } from "./index.es202.js";
4
+ import { deepCompareStrict } from "./index.es203.js";
5
+ import { Validator } from "./index.es204.js";
6
+ import { toJSONSchema } from "./index.es205.js";
7
+ import { dereference } from "./index.es206.js";
8
+ var json_schema_exports = {};
9
+ __export(json_schema_exports, {
10
+ Validator: () => Validator,
11
+ deepCompareStrict: () => deepCompareStrict,
12
+ toJsonSchema: () => toJsonSchema,
13
+ validatesOnlyStrings: () => validatesOnlyStrings
14
+ });
15
+ function toJsonSchema(schema, params) {
16
+ if (isZodSchemaV4(schema)) {
17
+ const inputSchema = interopZodTransformInputSchema(schema, true);
18
+ if (isZodObjectV4(inputSchema)) {
19
+ const strictSchema = interopZodObjectStrict(inputSchema, true);
20
+ return toJSONSchema(strictSchema, params);
21
+ } else return toJSONSchema(schema, params);
13
22
  }
14
- return first;
23
+ if (isZodSchemaV3(schema)) return zodToJsonSchema(schema);
24
+ return schema;
25
+ }
26
+ function validatesOnlyStrings(schema) {
27
+ if (!schema || typeof schema !== "object" || Object.keys(schema).length === 0 || Array.isArray(schema)) return false;
28
+ if ("type" in schema) {
29
+ if (typeof schema.type === "string") return schema.type === "string";
30
+ if (Array.isArray(schema.type)) return schema.type.every((t) => t === "string");
31
+ return false;
32
+ }
33
+ if ("enum" in schema) return Array.isArray(schema.enum) && schema.enum.length > 0 && schema.enum.every((val) => typeof val === "string");
34
+ if ("const" in schema) return typeof schema.const === "string";
35
+ if ("allOf" in schema && Array.isArray(schema.allOf)) return schema.allOf.some((subschema) => validatesOnlyStrings(subschema));
36
+ if ("anyOf" in schema && Array.isArray(schema.anyOf) || "oneOf" in schema && Array.isArray(schema.oneOf)) {
37
+ const subschemas = "anyOf" in schema ? schema.anyOf : schema.oneOf;
38
+ return subschemas.length > 0 && subschemas.every((subschema) => validatesOnlyStrings(subschema));
39
+ }
40
+ if ("not" in schema) return false;
41
+ if ("$ref" in schema && typeof schema.$ref === "string") {
42
+ const ref = schema.$ref;
43
+ const resolved = dereference(schema);
44
+ if (resolved[ref]) return validatesOnlyStrings(resolved[ref]);
45
+ return false;
46
+ }
47
+ return false;
15
48
  }
16
49
  export {
17
- lowerBound as default
50
+ Validator,
51
+ deepCompareStrict,
52
+ json_schema_exports,
53
+ toJsonSchema,
54
+ validatesOnlyStrings
18
55
  };
19
56
  //# sourceMappingURL=index.es133.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.es133.js","sources":["../node_modules/.pnpm/p-queue@9.1.0/node_modules/p-queue/dist/lower-bound.js"],"sourcesContent":["// Port of lower_bound from https://en.cppreference.com/w/cpp/algorithm/lower_bound\n// Used to compute insertion index to keep queue sorted after insertion\nexport default function lowerBound(array, value, comparator) {\n let first = 0;\n let count = array.length;\n while (count > 0) {\n const step = Math.trunc(count / 2);\n let it = first + step;\n if (comparator(array[it], value) <= 0) {\n first = ++it;\n count -= step + 1;\n }\n else {\n count = step;\n }\n }\n return first;\n}\n"],"names":[],"mappings":"AAEe,SAAS,WAAW,OAAO,OAAO,YAAY;AACzD,MAAI,QAAQ;AACZ,MAAI,QAAQ,MAAM;AAClB,SAAO,QAAQ,GAAG;AACd,UAAM,OAAO,KAAK,MAAM,QAAQ,CAAC;AACjC,QAAI,KAAK,QAAQ;AACjB,QAAI,WAAW,MAAM,EAAE,GAAG,KAAK,KAAK,GAAG;AACnC,cAAQ,EAAE;AACV,eAAS,OAAO;AAAA,IACpB,OACK;AACD,cAAQ;AAAA,IACZ;AAAA,EACJ;AACA,SAAO;AACX;","x_google_ignoreList":[0]}
1
+ {"version":3,"file":"index.es133.js","sources":["../node_modules/.pnpm/@langchain+core@1.1.13_openai@6.16.0_zod@4.3.5_/node_modules/@langchain/core/dist/utils/json_schema.js"],"sourcesContent":["import { __export } from \"../_virtual/rolldown_runtime.js\";\nimport { interopZodObjectStrict, interopZodTransformInputSchema, isZodObjectV4, isZodSchemaV3, isZodSchemaV4 } from \"./types/zod.js\";\nimport { zodToJsonSchema } from \"./zod-to-json-schema/zodToJsonSchema.js\";\nimport \"./zod-to-json-schema/index.js\";\nimport { toJSONSchema } from \"zod/v4/core\";\nimport { Validator, deepCompareStrict, dereference } from \"@cfworker/json-schema\";\n\n//#region src/utils/json_schema.ts\nvar json_schema_exports = {};\n__export(json_schema_exports, {\n\tValidator: () => Validator,\n\tdeepCompareStrict: () => deepCompareStrict,\n\ttoJsonSchema: () => toJsonSchema,\n\tvalidatesOnlyStrings: () => validatesOnlyStrings\n});\n/**\n* Converts a Zod schema or JSON schema to a JSON schema.\n* @param schema - The schema to convert.\n* @param params - The parameters to pass to the toJSONSchema function.\n* @returns The converted schema.\n*/\nfunction toJsonSchema(schema, params) {\n\tif (isZodSchemaV4(schema)) {\n\t\tconst inputSchema = interopZodTransformInputSchema(schema, true);\n\t\tif (isZodObjectV4(inputSchema)) {\n\t\t\tconst strictSchema = interopZodObjectStrict(inputSchema, true);\n\t\t\treturn toJSONSchema(strictSchema, params);\n\t\t} else return toJSONSchema(schema, params);\n\t}\n\tif (isZodSchemaV3(schema)) return zodToJsonSchema(schema);\n\treturn schema;\n}\n/**\n* Validates if a JSON schema validates only strings. May return false negatives in some edge cases\n* (like recursive or unresolvable refs).\n*\n* @param schema - The schema to validate.\n* @returns `true` if the schema validates only strings, `false` otherwise.\n*/\nfunction validatesOnlyStrings(schema) {\n\tif (!schema || typeof schema !== \"object\" || Object.keys(schema).length === 0 || Array.isArray(schema)) return false;\n\tif (\"type\" in schema) {\n\t\tif (typeof schema.type === \"string\") return schema.type === \"string\";\n\t\tif (Array.isArray(schema.type)) return schema.type.every((t) => t === \"string\");\n\t\treturn false;\n\t}\n\tif (\"enum\" in schema) return Array.isArray(schema.enum) && schema.enum.length > 0 && schema.enum.every((val) => typeof val === \"string\");\n\tif (\"const\" in schema) return typeof schema.const === \"string\";\n\tif (\"allOf\" in schema && Array.isArray(schema.allOf)) return schema.allOf.some((subschema) => validatesOnlyStrings(subschema));\n\tif (\"anyOf\" in schema && Array.isArray(schema.anyOf) || \"oneOf\" in schema && Array.isArray(schema.oneOf)) {\n\t\tconst subschemas = \"anyOf\" in schema ? schema.anyOf : schema.oneOf;\n\t\treturn subschemas.length > 0 && subschemas.every((subschema) => validatesOnlyStrings(subschema));\n\t}\n\tif (\"not\" in schema) return false;\n\tif (\"$ref\" in schema && typeof schema.$ref === \"string\") {\n\t\tconst ref = schema.$ref;\n\t\tconst resolved = dereference(schema);\n\t\tif (resolved[ref]) return validatesOnlyStrings(resolved[ref]);\n\t\treturn false;\n\t}\n\treturn false;\n}\n\n//#endregion\nexport { Validator, deepCompareStrict, json_schema_exports, toJsonSchema, validatesOnlyStrings };\n//# sourceMappingURL=json_schema.js.map"],"names":[],"mappings":";;;;;;;AA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AM,aAAa,WAAW,SAAS,OAAO,QAAQ,OAAO;AAC7D,WAAO,WAAW,SAAS,KAAK,WAAW,MAAM,CAAC,cAAc,qBAAqB,SAAS,CAAC;AAAA,EAChG;AACA,MAAI,SAAS,OAAQ,QAAO;AAC5B,MAAI,UAAU,UAAU,OAAO,OAAO,SAAS,UAAU;AACxD,UAAM,MAAM,OAAO;AACnB,UAAM,WAAW,YAAY,MAAM;AACnC,QAAI,SAAS,GAAG,EAAG,QAAO,qBAAqB,SAAS,GAAG,CAAC;AAC5D,WAAO;AAAA,EACR;AACA,SAAO;AACR;","x_google_ignoreList":[0]}
@@ -1,4 +1,4 @@
1
- import tsx from "./index.es79.js";
1
+ import tsx from "./index.es110.js";
2
2
  export {
3
3
  tsx as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import python from "./index.es80.js";
1
+ import python from "./index.es111.js";
2
2
  export {
3
3
  python as default
4
4
  };
@@ -1,4 +1,4 @@
1
- import { __module as interopRequireDefault } from "./index.es186.js";
1
+ import { __module as interopRequireDefault } from "./index.es207.js";
2
2
  var hasRequiredInteropRequireDefault;
3
3
  function requireInteropRequireDefault() {
4
4
  if (hasRequiredInteropRequireDefault) return interopRequireDefault.exports;
@@ -1,4 +1,4 @@
1
- import { __exports as coy } from "./index.es187.js";
1
+ import { __exports as coy } from "./index.es208.js";
2
2
  var hasRequiredCoy;
3
3
  function requireCoy() {
4
4
  if (hasRequiredCoy) return coy;
@@ -1,4 +1,4 @@
1
- import { __exports as dark } from "./index.es188.js";
1
+ import { __exports as dark } from "./index.es209.js";
2
2
  var hasRequiredDark;
3
3
  function requireDark() {
4
4
  if (hasRequiredDark) return dark;
@@ -1,4 +1,4 @@
1
- import { __exports as funky } from "./index.es189.js";
1
+ import { __exports as funky } from "./index.es210.js";
2
2
  var hasRequiredFunky;
3
3
  function requireFunky() {
4
4
  if (hasRequiredFunky) return funky;
@@ -1,4 +1,4 @@
1
- import { __exports as okaidia } from "./index.es190.js";
1
+ import { __exports as okaidia } from "./index.es211.js";
2
2
  var hasRequiredOkaidia;
3
3
  function requireOkaidia() {
4
4
  if (hasRequiredOkaidia) return okaidia;
@@ -1,4 +1,4 @@
1
- import { __exports as solarizedlight } from "./index.es191.js";
1
+ import { __exports as solarizedlight } from "./index.es212.js";
2
2
  var hasRequiredSolarizedlight;
3
3
  function requireSolarizedlight() {
4
4
  if (hasRequiredSolarizedlight) return solarizedlight;
@@ -1,4 +1,4 @@
1
- import { __exports as tomorrow } from "./index.es192.js";
1
+ import { __exports as tomorrow } from "./index.es213.js";
2
2
  var hasRequiredTomorrow;
3
3
  function requireTomorrow() {
4
4
  if (hasRequiredTomorrow) return tomorrow;
@@ -1,4 +1,4 @@
1
- import { __exports as twilight } from "./index.es193.js";
1
+ import { __exports as twilight } from "./index.es214.js";
2
2
  var hasRequiredTwilight;
3
3
  function requireTwilight() {
4
4
  if (hasRequiredTwilight) return twilight;
@@ -1,4 +1,4 @@
1
- import { __exports as prism } from "./index.es194.js";
1
+ import { __exports as prism } from "./index.es215.js";
2
2
  var hasRequiredPrism;
3
3
  function requirePrism() {
4
4
  if (hasRequiredPrism) return prism;