@bkm016/basalt 0.1.3 → 0.1.5

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 (287) hide show
  1. package/README.md +53 -5
  2. package/{chunk-y648fzx0.js → chunk-0039s4jt.js} +3 -3
  3. package/{chunk-m40gxwq4.js → chunk-00gwse5r.js} +3 -3
  4. package/{chunk-t6zs4kw0.js → chunk-0fwdxd45.js} +2 -2
  5. package/{chunk-6hssbcgj.js → chunk-0j0qggej.js} +1 -1
  6. package/chunk-0n99m9m4.js +2 -0
  7. package/{chunk-d8gtbw9g.js → chunk-0stvywr8.js} +1 -1
  8. package/{chunk-ztsjgssj.js → chunk-1xa7d5mh.js} +1 -1
  9. package/chunk-2nb3d92s.js +2 -0
  10. package/chunk-2nkfxhef.js +3868 -0
  11. package/chunk-2pa1z37c.js +2 -0
  12. package/{chunk-fw2bpqmw.js → chunk-2qcpq99g.js} +1 -1
  13. package/{chunk-981f9dw8.js → chunk-36cqq0ga.js} +6 -6
  14. package/{chunk-3cjsd292.js → chunk-3c330qna.js} +2 -2
  15. package/chunk-3k627vf2.js +3 -0
  16. package/{chunk-r7fpkb49.js → chunk-3k7ejpkc.js} +1 -1
  17. package/chunk-4g5f43ea.js +3 -0
  18. package/{chunk-fjtvjrkg.js → chunk-539ekagy.js} +4 -4
  19. package/{chunk-97rzj7f6.js → chunk-5v4g21rw.js} +1 -1
  20. package/{chunk-aefadsy6.js → chunk-6dsq0fns.js} +2 -2
  21. package/{chunk-pbcy6zdt.js → chunk-7as47pcw.js} +1 -1
  22. package/{chunk-g2t6t8fk.js → chunk-7jezts2n.js} +2 -2
  23. package/{chunk-8tjad3r0.js → chunk-7qq99360.js} +6 -6
  24. package/{chunk-gp7y0fja.js → chunk-7tgqhveh.js} +15 -15
  25. package/{chunk-mvfsxdx6.js → chunk-7w0mefgk.js} +10 -10
  26. package/{chunk-y58ygzn9.js → chunk-818nd6s1.js} +3 -3
  27. package/{chunk-vv7fp27r.js → chunk-8mezk0cb.js} +2 -2
  28. package/{chunk-rtzqqngy.js → chunk-8xb636vr.js} +5 -5
  29. package/{chunk-2esbgxps.js → chunk-980drajf.js} +15 -15
  30. package/{chunk-c7x1zq39.js → chunk-9z7sdh5e.js} +3 -3
  31. package/{chunk-10xzzn07.js → chunk-a4b75ekk.js} +2 -2
  32. package/{chunk-5j1krv9v.js → chunk-ar3dbfp9.js} +1 -1
  33. package/{chunk-vk1gxk1t.js → chunk-aw65h276.js} +1 -1
  34. package/{chunk-75m78j7x.js → chunk-b9fqretv.js} +2 -2
  35. package/{chunk-y0m980k3.js → chunk-bgkegf0k.js} +22 -22
  36. package/{chunk-0y7ne3d0.js → chunk-bwawt15q.js} +2 -2
  37. package/{chunk-pxsrqrd0.js → chunk-c4qr1f41.js} +2 -2
  38. package/chunk-dddsrff6.js +478 -0
  39. package/{chunk-xfvvh1s5.js → chunk-e63c1186.js} +1 -1
  40. package/{chunk-8296hw9m.js → chunk-ebzkckyw.js} +2 -2
  41. package/chunk-eegztdzb.js +2 -0
  42. package/{chunk-hwr56pfj.js → chunk-gw05p4g3.js} +1 -1
  43. package/{chunk-k23t7vhs.js → chunk-h1rypb99.js} +5 -5
  44. package/{chunk-nbb9trwz.js → chunk-hq5ke1yp.js} +2 -2
  45. package/{chunk-jwdb0ccj.js → chunk-jvwg4rn1.js} +3 -3
  46. package/{chunk-fm0k0qtz.js → chunk-jyrwk08p.js} +2 -2
  47. package/chunk-kns4kv7b.js +3 -0
  48. package/{chunk-8d46jtbj.js → chunk-mat08ab1.js} +2 -2
  49. package/{chunk-bannb9xm.js → chunk-mkp28k1x.js} +2 -2
  50. package/{chunk-d2j735sd.js → chunk-npez1492.js} +2 -2
  51. package/{chunk-shadcb9z.js → chunk-nx3jnbv8.js} +2 -2
  52. package/{chunk-ykens1hy.js → chunk-nxkmd29x.js} +1 -1
  53. package/{chunk-y7nma9rk.js → chunk-pjr91g6k.js} +2 -2
  54. package/{chunk-m8vkwdgr.js → chunk-r0jc8e7t.js} +4 -4
  55. package/chunk-rxj6tct8.js +2 -0
  56. package/{chunk-362g64pd.js → chunk-sqaam5ak.js} +1 -1
  57. package/{chunk-gzxnene8.js → chunk-srjgvdvs.js} +12 -12
  58. package/{chunk-r9aatvwm.js → chunk-stj493dn.js} +2 -2
  59. package/{chunk-k6w6y71k.js → chunk-t7sc0wwc.js} +2 -2
  60. package/{chunk-27gntzs5.js → chunk-v4k3qmdm.js} +2 -2
  61. package/{chunk-x1xss1d7.js → chunk-vt1anydc.js} +4 -4
  62. package/chunk-wd3z74av.js +2 -0
  63. package/{chunk-z55bmysw.js → chunk-wfyrfvfn.js} +1 -1
  64. package/{chunk-v9fea96h.js → chunk-wnzvnskb.js} +2 -2
  65. package/{chunk-cjc90f84.js → chunk-x89em726.js} +3 -3
  66. package/{chunk-1qpces5a.js → chunk-xtq1xpq0.js} +2 -2
  67. package/chunk-yna8bwqc.js +2 -0
  68. package/{chunk-k506w58v.js → chunk-zn0g0859.js} +2 -2
  69. package/{chunk-qe0teyn1.js → chunk-zrkh5dw7.js} +1 -1
  70. package/chunk-zzwjt7fp.js +2 -0
  71. package/compiled.js +12 -12
  72. package/package.json +1 -1
  73. package/ui-test-worker.js +20 -20
  74. package/web/chunk-01hcjafh.js +2 -0
  75. package/web/{chunk-n8sky2q6.js → chunk-07agqp8h.js} +1 -1
  76. package/web/{chunk-tx8240k4.js → chunk-0k9aec1s.js} +20 -20
  77. package/web/{chunk-74j07k8k.js → chunk-0p1nmj5n.js} +2 -2
  78. package/web/chunk-0qr891eq.js +70 -0
  79. package/web/{chunk-ts7zrf5b.js → chunk-0whceqes.js} +2 -2
  80. package/web/chunk-0ytga215.js +1 -0
  81. package/web/{chunk-h288yd5w.js → chunk-12z7d0hp.js} +3 -3
  82. package/web/chunk-14bad871.js +2 -0
  83. package/web/chunk-1amzv4ha.js +1 -0
  84. package/web/chunk-1cfh0e2e.js +324 -0
  85. package/web/chunk-1pasbxwh.js +89 -0
  86. package/web/{chunk-j0bwwc1g.js → chunk-1s2hp6h1.js} +1 -1
  87. package/web/chunk-26bwh1sb.js +169 -0
  88. package/web/{chunk-b0a8nbj0.js → chunk-2nht58dc.js} +5 -5
  89. package/web/chunk-2y0rc1fe.js +1 -0
  90. package/web/chunk-3hkgdw6f.js +36 -0
  91. package/web/chunk-4a4j030b.js +1 -0
  92. package/web/{chunk-4fzj0azw.js → chunk-4m3zdd41.js} +6 -6
  93. package/web/chunk-4w298aqs.js +1 -0
  94. package/web/{chunk-2hd1pe9w.js → chunk-56krfj3b.js} +7 -7
  95. package/web/{chunk-ds7srg4p.js → chunk-5nda24gv.js} +1 -1
  96. package/web/{chunk-5hmfk69r.js → chunk-5shygfgb.js} +19 -19
  97. package/web/chunk-65nwc4cf.js +1 -0
  98. package/web/chunk-6bwgdvf6.js +1 -0
  99. package/web/chunk-6enn8p66.js +1 -0
  100. package/web/chunk-6stt9d18.js +1 -0
  101. package/web/{chunk-4gavbw65.js → chunk-7a3c137d.js} +1 -1
  102. package/web/chunk-7e47b1sn.js +1 -0
  103. package/web/chunk-7pypx5h8.js +2 -0
  104. package/web/chunk-7znyd1mj.js +39 -0
  105. package/web/{chunk-0z0jycs8.js → chunk-892nf39p.js} +7 -7
  106. package/web/chunk-8r0s8tx7.js +1 -0
  107. package/web/chunk-9dy7z3ej.js +2 -0
  108. package/web/chunk-9mq2cdtq.js +1 -0
  109. package/web/chunk-9w5tf22s.js +1 -0
  110. package/web/{chunk-es28k2t7.js → chunk-9xgspn75.js} +2 -2
  111. package/web/{chunk-0xc2c540.js → chunk-abhad4zj.js} +56 -56
  112. package/web/chunk-advfpyb9.js +140 -0
  113. package/web/chunk-affear07.js +3 -0
  114. package/web/chunk-ahztazsg.js +1 -0
  115. package/web/chunk-aqt7kc3s.js +106 -0
  116. package/web/chunk-b5hah4mf.js +1 -0
  117. package/web/chunk-b8tfetd8.js +1 -0
  118. package/web/{chunk-7yc083xj.js → chunk-bnb9xhgw.js} +15 -15
  119. package/web/{chunk-n1dmrz44.js → chunk-c01176kn.js} +2 -2
  120. package/web/chunk-c3nn0vvc.js +1 -0
  121. package/web/chunk-c53xmf48.js +30 -0
  122. package/web/chunk-ckgpy4r4.js +1 -0
  123. package/web/chunk-crzseqbx.js +24 -0
  124. package/web/chunk-d22wq71s.js +1 -0
  125. package/web/{chunk-97b62pvb.js → chunk-d60dpf69.js} +19 -19
  126. package/web/{chunk-sn9ecfvy.js → chunk-d6ddkh6e.js} +1 -1
  127. package/web/{chunk-cg3jterp.js → chunk-d9wdsjkk.js} +2 -2
  128. package/web/{chunk-ttg6tbwx.js → chunk-da7m1kva.js} +2 -2
  129. package/web/chunk-dbnrfxt1.js +8 -0
  130. package/web/chunk-ddxf8e84.js +1 -0
  131. package/web/chunk-dzg1pv80.js +200 -0
  132. package/web/{chunk-xnq41dgs.js → chunk-e8h45nyr.js} +1 -1
  133. package/web/chunk-ej9vb61c.js +1 -0
  134. package/web/chunk-f9k3xrwb.js +2 -0
  135. package/web/{chunk-7xk0ntav.js → chunk-fjag6yg8.js} +2 -2
  136. package/web/chunk-fnnrrzqa.js +78 -0
  137. package/web/{chunk-n90cqdvg.js → chunk-fv6vm14n.js} +2 -2
  138. package/web/{chunk-axkyft9f.js → chunk-g5jxwkdh.js} +1 -1
  139. package/web/{chunk-ep37qp12.js → chunk-g8kkc6vz.js} +1 -1
  140. package/web/chunk-g9sqbafw.js +2 -0
  141. package/web/{chunk-g46f421r.js → chunk-gcv91974.js} +4 -4
  142. package/web/{chunk-7qxhk1kz.js → chunk-gxqaa4sv.js} +7 -7
  143. package/web/chunk-gxsb5tx3.js +1 -0
  144. package/web/{chunk-54thej0t.js → chunk-gyp6v7jd.js} +2 -2
  145. package/web/chunk-h0c42zy3.js +1 -0
  146. package/web/chunk-h2ag4kvz.js +2 -0
  147. package/web/{chunk-eqsd8zta.js → chunk-h6gh63xj.js} +2 -2
  148. package/web/{chunk-6m69hczt.js → chunk-h6k1x096.js} +2 -2
  149. package/web/{chunk-24mfx6w1.js → chunk-j1bw5v1g.js} +2 -2
  150. package/web/chunk-j34q5jn6.js +1 -0
  151. package/web/{chunk-0pbjgdgp.js → chunk-ja7w629n.js} +2 -2
  152. package/web/{chunk-zbj1trar.js → chunk-jam45rqg.js} +2 -2
  153. package/web/{chunk-23c1df7e.js → chunk-jcdw85mv.js} +1 -1
  154. package/web/chunk-jfvxxp5c.js +1 -0
  155. package/web/chunk-jg6fmz2d.js +1 -0
  156. package/web/{chunk-90xqeczk.js → chunk-k67v6dyg.js} +40 -40
  157. package/web/chunk-ka7c5rhx.js +99 -0
  158. package/web/{chunk-acybsx44.js → chunk-kza0t0gj.js} +1 -1
  159. package/web/{chunk-7520nrbb.js → chunk-m8knte9z.js} +1 -1
  160. package/web/{chunk-v5cnt7c8.js → chunk-mnzramhc.js} +1 -1
  161. package/web/{chunk-7v5rxabp.js → chunk-mpfgr049.js} +1 -1
  162. package/web/chunk-mz1dabxh.js +1 -0
  163. package/web/chunk-mz9b5bsa.js +1 -0
  164. package/web/chunk-p53n0hwr.js +1 -0
  165. package/web/chunk-paywgcf7.js +40 -0
  166. package/web/chunk-pfcnr9tw.js +1 -0
  167. package/web/chunk-pyg1mr80.js +303 -0
  168. package/web/chunk-q7xkscc5.js +1 -0
  169. package/web/{chunk-xzp7jf7e.js → chunk-qcge7d6s.js} +2 -2
  170. package/web/chunk-qmbgb79a.js +1139 -0
  171. package/web/{chunk-5b2nw6j1.js → chunk-qq5gh5zr.js} +1 -1
  172. package/web/chunk-qrdh9j62.js +1 -0
  173. package/web/{chunk-w7snhcyg.js → chunk-s24qs1bn.js} +9 -9
  174. package/web/chunk-sd22cnjy.js +1 -0
  175. package/web/{chunk-ydtrc1ay.js → chunk-sd3cdqcm.js} +2 -2
  176. package/web/{chunk-rykfak98.js → chunk-sf101c23.js} +2 -2
  177. package/web/{chunk-p9hsd3rn.js → chunk-sfq6cw45.js} +2 -2
  178. package/web/chunk-svqj4az8.js +1 -0
  179. package/web/chunk-t7jwyvvr.js +1 -0
  180. package/web/{chunk-47q4hmfp.js → chunk-tcp77cp2.js} +2 -2
  181. package/web/chunk-tf18d2dk.css +1 -0
  182. package/web/chunk-thbqwq6b.js +1 -0
  183. package/web/chunk-v0g4cqc1.js +4 -0
  184. package/web/chunk-vhzys0rr.js +292 -0
  185. package/web/chunk-vnt34mkb.js +1 -0
  186. package/web/chunk-vqfz99ff.js +1 -0
  187. package/web/chunk-vttgyb5v.js +2 -0
  188. package/web/chunk-x7sb3bwf.js +370 -0
  189. package/web/chunk-xce8n339.js +1 -0
  190. package/web/{chunk-mb4qx9hy.js → chunk-xk1t58c4.js} +12 -12
  191. package/web/chunk-xsrvw7dt.js +4 -0
  192. package/web/chunk-xtss82z2.js +1 -0
  193. package/web/{chunk-2j4m0bh1.js → chunk-y7jq61nv.js} +2 -2
  194. package/web/{chunk-7ba8vrfc.js → chunk-ybw6vgf6.js} +2 -2
  195. package/web/{chunk-24h1rfje.js → chunk-yvgs6bm3.js} +4 -4
  196. package/web/{chunk-sb1cjpq8.js → chunk-z4aj066q.js} +1 -1
  197. package/web/chunk-zazs8p6c.js +1 -0
  198. package/web/{chunk-n8gfjj9a.js → chunk-zc1mk10n.js} +19 -19
  199. package/web/{chunk-5qqw2e0t.js → chunk-zqht0jzx.js} +6 -6
  200. package/web/{chunk-mwj9tpkz.js → chunk-zz397b0v.js} +12 -12
  201. package/web/index.html +1 -1
  202. package/worker.js +1 -1
  203. package/chunk-06hdzq5n.js +0 -2
  204. package/chunk-09rj27b2.js +0 -2
  205. package/chunk-1zdwrgd4.js +0 -2
  206. package/chunk-5c9j8qe4.js +0 -478
  207. package/chunk-9mmz6wt3.js +0 -2
  208. package/chunk-bpw6q7g0.js +0 -3
  209. package/chunk-bxn5kmpz.js +0 -3753
  210. package/chunk-n6e43rvk.js +0 -3
  211. package/chunk-pmqtkqsf.js +0 -2
  212. package/chunk-ry0z4ev6.js +0 -2
  213. package/chunk-v258nxcz.js +0 -2
  214. package/chunk-zmsgwr3s.js +0 -2
  215. package/web/chunk-0s80zw00.js +0 -1
  216. package/web/chunk-166qe5j6.js +0 -2
  217. package/web/chunk-1c95wfvq.js +0 -1
  218. package/web/chunk-329rtxa9.js +0 -1
  219. package/web/chunk-33qwz9bc.js +0 -2
  220. package/web/chunk-3qjnwsph.js +0 -1
  221. package/web/chunk-4rm1vy7w.js +0 -1
  222. package/web/chunk-59kqahb3.js +0 -1
  223. package/web/chunk-61jahh35.js +0 -292
  224. package/web/chunk-6beqrmtq.js +0 -1
  225. package/web/chunk-6gxf3vsg.js +0 -1
  226. package/web/chunk-6parf7sy.js +0 -2
  227. package/web/chunk-89fkdgbp.js +0 -2
  228. package/web/chunk-8qgpfxkz.js +0 -1
  229. package/web/chunk-9a3q0jsh.js +0 -36
  230. package/web/chunk-9bgey148.js +0 -169
  231. package/web/chunk-9xh96b33.js +0 -2
  232. package/web/chunk-a5sg33w2.js +0 -3
  233. package/web/chunk-a91vxtx4.js +0 -1
  234. package/web/chunk-agec7jj4.js +0 -1
  235. package/web/chunk-c516cghj.js +0 -1
  236. package/web/chunk-cqp1d4p0.js +0 -1
  237. package/web/chunk-cwtdnacf.js +0 -1
  238. package/web/chunk-dg1vas6z.js +0 -8
  239. package/web/chunk-dy2gm1fs.js +0 -1
  240. package/web/chunk-f91wzwtk.js +0 -1
  241. package/web/chunk-fc0nx23g.js +0 -1
  242. package/web/chunk-fhnypcrm.js +0 -1139
  243. package/web/chunk-fv60p68p.js +0 -1
  244. package/web/chunk-g1ev11wx.js +0 -1
  245. package/web/chunk-h18tnrf2.js +0 -1
  246. package/web/chunk-hfaffkrh.js +0 -1
  247. package/web/chunk-hszjc2ny.js +0 -70
  248. package/web/chunk-j2vt8c8v.js +0 -1
  249. package/web/chunk-jqa39f8t.js +0 -78
  250. package/web/chunk-jvbbrnpa.js +0 -1
  251. package/web/chunk-jzfd7cyh.js +0 -2
  252. package/web/chunk-ka3q31t1.js +0 -1
  253. package/web/chunk-ka9ak8wr.js +0 -1
  254. package/web/chunk-m2d1sp30.js +0 -1
  255. package/web/chunk-mnjd59jk.js +0 -1
  256. package/web/chunk-ng0nbfhh.js +0 -1
  257. package/web/chunk-nz9nxk48.js +0 -1
  258. package/web/chunk-phw908hn.js +0 -1
  259. package/web/chunk-pjmmma1k.js +0 -1
  260. package/web/chunk-pxe3vna4.js +0 -1
  261. package/web/chunk-q7yn4m3t.js +0 -1
  262. package/web/chunk-qh15dxav.css +0 -1
  263. package/web/chunk-qnhqexe0.js +0 -1
  264. package/web/chunk-rcx1aee5.js +0 -99
  265. package/web/chunk-rjqj6ffe.js +0 -1
  266. package/web/chunk-rks7ksv3.js +0 -106
  267. package/web/chunk-rtf2zzzv.js +0 -1
  268. package/web/chunk-sgvp8vge.js +0 -1
  269. package/web/chunk-sjjwte12.js +0 -1
  270. package/web/chunk-srrfphes.js +0 -1
  271. package/web/chunk-t7bwsdbr.js +0 -1
  272. package/web/chunk-tse9gvyq.js +0 -89
  273. package/web/chunk-vd6y2pcm.js +0 -39
  274. package/web/chunk-vpa55vje.js +0 -4
  275. package/web/chunk-vymqrpm3.js +0 -303
  276. package/web/chunk-wdtnhpd6.js +0 -4
  277. package/web/chunk-wmvd6j0b.js +0 -200
  278. package/web/chunk-xvsmtetz.js +0 -30
  279. package/web/chunk-y3ajqthy.js +0 -370
  280. package/web/chunk-yd1ez3wd.js +0 -2
  281. package/web/chunk-yfbxtg5p.js +0 -1
  282. package/web/chunk-ywp4s71k.js +0 -40
  283. package/web/chunk-z4x331rx.js +0 -140
  284. package/web/chunk-z6bpamwq.js +0 -24
  285. package/web/chunk-zmdnxn6m.js +0 -2
  286. package/web/install.ps1 +0 -91
  287. package/web/install.sh +0 -177
package/chunk-n6e43rvk.js DELETED
@@ -1,3 +0,0 @@
1
- // @bun
2
- function g(u){return u.replace(/[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?<![\uD800-\uDBFF])[\uDC00-\uDFFF]/g,"")}
3
- export{g};
package/chunk-pmqtkqsf.js DELETED
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{Yt,go}from"./chunk-2esbgxps.js";import"./chunk-pxsrqrd0.js";import"./chunk-m8vkwdgr.js";export{Yt as stream,go as streamSimple};
package/chunk-ry0z4ev6.js DELETED
@@ -1,2 +0,0 @@
1
- // @bun
2
- import*as mo from"child_process";import*as St from"crypto";import*as st from"fs";import*as x from"path";import*as an from"stream";import*as ho from"util";export{mo,St,st,x,an,ho};
package/chunk-v258nxcz.js DELETED
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{L}from"./chunk-jwdb0ccj.js";import{b}from"./chunk-981f9dw8.js";import{i}from"./chunk-0y7ne3d0.js";var _=i(L()),N=i(b()),Nr="AWS_ACCESS_KEY_ID",Dr="AWS_SECRET_ACCESS_KEY",S="AWS_SESSION_TOKEN",C="AWS_CREDENTIAL_EXPIRATION",A="AWS_CREDENTIAL_SCOPE",p="AWS_ACCOUNT_ID",Rn=(e)=>async()=>{e?.logger?.debug("@aws-sdk/credential-provider-env - fromEnv");let o=process.env[Nr],E=process.env[Dr],r=process.env[S],n=process.env[C],s=process.env[A],t=process.env[p];if(o&&E){let c={accessKeyId:o,secretAccessKey:E,...r&&{sessionToken:r},...n&&{expiration:new Date(n)},...s&&{credentialScope:s},...t&&{accountId:t}};return _.setCredentialFeature(c,"CREDENTIALS_ENV_VARS","g"),c}throw new N.CredentialsProviderError("Unable to find environment variable credentials.",{logger:e?.logger})};export{Nr,Dr,Rn};
package/chunk-zmsgwr3s.js DELETED
@@ -1,2 +0,0 @@
1
- // @bun
2
- import{de,Be,Lt}from"./chunk-y0m980k3.js";export{de as UnauthorizedError,Be as auth,Lt as extractWWWAuthenticateParams};
@@ -1 +0,0 @@
1
- import{Kn}from"./chunk-54thej0t.js";export{Kn as default};
@@ -1,2 +0,0 @@
1
- import{F,De}from"./chunk-vymqrpm3.js";var n=(r,o)=>F.lang.round(De.parse(r)[o]),Ot=n;
2
- export{Ot};
@@ -1 +0,0 @@
1
- import"./chunk-vymqrpm3.js";import"./chunk-7xk0ntav.js";import"./chunk-jzfd7cyh.js";import{Ji}from"./chunk-wdtnhpd6.js";export{Ji as render};
@@ -1 +0,0 @@
1
- import{ki}from"./chunk-n8gfjj9a.js";export{ki as createPieServices};
@@ -1,2 +0,0 @@
1
- import{e,r,B,V}from"./chunk-vymqrpm3.js";import{X}from"./chunk-n8gfjj9a.js";var i={parse:e(async(t)=>{let a=await X("info",t);r.debug(a)},"parse")},s={version:"12.2.0"},p=e(()=>s.version,"getVersion"),g={getVersion:p},m=e((t,a,n)=>{r.debug(`rendering info diagram
2
- `+t);let o=V(a);B(o,100,400,!0),o.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${n}`)},"draw"),v={draw:m},y={parser:i,db:g,renderer:v};export{y as diagram};
@@ -1 +0,0 @@
1
- import{e,r}from"./chunk-vymqrpm3.js";import{K,It,Rt}from"./chunk-tse9gvyq.js";import{W}from"./chunk-89fkdgbp.js";import{ar,_t}from"./chunk-n8gfjj9a.js";var i=ar().RailroadEbnf.parser.LangiumParser,o=e((t)=>{let n=t.alternatives.map(m);if(n.length===1)return n[0];return{type:"choice",alternatives:n}},"transformChoice"),m=e((t)=>{let n=t.elements.map(p);if(n.length===1)return n[0];return{type:"sequence",elements:n}},"transformSequence"),s=e((t)=>{switch(t.$type){case"EbnfTerminal":return{type:"terminal",value:t.value};case"EbnfNonTerminal":return{type:"nonterminal",name:t.name};case"EbnfSpecial":return{type:"special",text:t.text};case"EbnfGroup":return o(t.element);case"EbnfOptional":return{type:"optional",element:o(t.element)};case"EbnfRepetition":return{type:"repetition",element:o(t.element),min:0,max:1/0};default:throw Error(`Unsupported EBNF primary node: ${t.$type}`)}},"transformPrimary"),l=e((t,n)=>{switch(n.$type){case"EbnfOptionalPostfix":return{type:"optional",element:t};case"EbnfZeroOrMorePostfix":return{type:"repetition",element:t,min:0,max:1/0};case"EbnfOneOrMorePostfix":return{type:"repetition",element:t,min:1,max:1/0};case"EbnfExceptionPostfix":return{type:"sequence",elements:[t,{type:"terminal",value:"-"},s(n.except)]};default:throw Error(`Unsupported EBNF postfix node: ${n.$type}`)}},"transformPostfix"),p=e((t)=>t.postfixes.reduce((n,a)=>l(n,a),s(t.base)),"transformTerm"),f=e((t)=>({name:t.name,definition:o(t.definition)}),"transformRule"),u=e((t)=>{if(W(t,K),t.title)K.setTitle(t.title);t.rules.map((n)=>K.addRule(f(n)))},"populateDb"),c={parse:e((t)=>{K.clear(),r.debug("[EBNF Parser] Starting Langium parse");let n=i.parse(t);if(n.lexerErrors.length>0||n.parserErrors.length>0)throw new _t(n);let a=n.value;r.debug("[EBNF Parser] Parsed rules:",a.rules.length),u(a),r.debug("[EBNF Parser] Parse complete")},"parse"),parser:{yy:K}},x={parser:c,db:K,renderer:Rt,styles:It};export{x as diagram};
@@ -1 +0,0 @@
1
- import{Xn}from"./chunk-74j07k8k.js";export{Xn as default};
@@ -1 +0,0 @@
1
- import{Zn}from"./chunk-6m69hczt.js";export{Zn as default};
@@ -1,292 +0,0 @@
1
- import{e,ka,r,y,B,C,S,E,T,A,I,L,s,p,En,kr,An,Pi,qe,lo,on,Gn,N}from"./chunk-vymqrpm3.js";import"./chunk-ds7srg4p.js";import{On,mn}from"./chunk-ttg6tbwx.js";import{nr,Pr,na,Or,xt}from"./chunk-eqsd8zta.js";import{Mt}from"./chunk-cqp1d4p0.js";import{Ce,Se}from"./chunk-fhnypcrm.js";var vn=Se(function(rr,ir){(function(t,n){typeof rr=="object"&&typeof ir<"u"?ir.exports=n():typeof define=="function"&&define.amd?define(n):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_isoWeek=n()})(rr,function(){var t="day";return function(n,i,a){var o=function(M){return M.add(4-M.isoWeekday(),t)},c=i.prototype;c.isoWeekYear=function(){return o(this).year()},c.isoWeek=function(M){if(!this.$utils().u(M))return this.add(7*(M-this.isoWeek()),t);var D,R,W,G,O=o(this),z=(D=this.isoWeekYear(),R=this.$u,W=(R?a.utc:a)().year(D).startOf("year"),G=4-W.isoWeekday(),W.isoWeekday()>4&&(G+=7),W.add(G,t));return O.diff(z,"week")+1},c.isoWeekday=function(M){return this.$utils().u(M)?this.day()||7:this.day(this.day()%7?M:M-7)};var l=c.startOf;c.startOf=function(M,D){var R=this.$utils(),W=!!R.u(D)||D;return R.p(M)==="isoweek"?W?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):l.bind(this)(M,D)}}})});var xn=Se(function(ar,sr){(function(t,n){typeof ar=="object"&&typeof sr<"u"?sr.exports=n():typeof define=="function"&&define.amd?define(n):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_customParseFormat=n()})(ar,function(){var t={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},n=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d/,a=/\d\d/,o=/\d\d?/,c=/\d*[^-_:/,()\s\d]+/,l={},M=function(U){return(U=+U)+(U>68?1900:2000)},D=function(U){return function(Z){this[U]=+Z}},R=[/[+-]\d\d:?(\d\d)?|Z/,function(U){(this.zone||(this.zone={})).offset=function(Z){if(!Z)return 0;if(Z==="Z")return 0;var H=Z.match(/([+-]|\d\d)/g),tt=60*H[1]+(+H[2]||0);return tt===0?0:H[0]==="+"?-tt:tt}(U)}],W=function(U){var Z=l[U];return Z&&(Z.indexOf?Z:Z.s.concat(Z.f))},G=function(U,Z){var H,tt=l.meridiem;if(tt){for(var ft=1;ft<=24;ft+=1)if(U.indexOf(tt(ft,0,Z))>-1){H=ft>12;break}}else H=U===(Z?"pm":"PM");return H},O={A:[c,function(U){this.afternoon=G(U,!1)}],a:[c,function(U){this.afternoon=G(U,!0)}],Q:[i,function(U){this.month=3*(U-1)+1}],S:[i,function(U){this.milliseconds=100*+U}],SS:[a,function(U){this.milliseconds=10*+U}],SSS:[/\d{3}/,function(U){this.milliseconds=+U}],s:[o,D("seconds")],ss:[o,D("seconds")],m:[o,D("minutes")],mm:[o,D("minutes")],H:[o,D("hours")],h:[o,D("hours")],HH:[o,D("hours")],hh:[o,D("hours")],D:[o,D("day")],DD:[a,D("day")],Do:[c,function(U){var Z=l.ordinal,H=U.match(/\d+/);if(this.day=H[0],Z)for(var tt=1;tt<=31;tt+=1)Z(tt).replace(/\[|\]/g,"")===U&&(this.day=tt)}],w:[o,D("week")],ww:[a,D("week")],M:[o,D("month")],MM:[a,D("month")],MMM:[c,function(U){var Z=W("months"),H=(W("monthsShort")||Z.map(function(tt){return tt.slice(0,3)})).indexOf(U)+1;if(H<1)throw Error();this.month=H%12||H}],MMMM:[c,function(U){var Z=W("months").indexOf(U)+1;if(Z<1)throw Error();this.month=Z%12||Z}],Y:[/[+-]?\d+/,D("year")],YY:[a,function(U){this.year=M(U)}],YYYY:[/\d{4}/,D("year")],Z:R,ZZ:R};function z(U){var Z,H;Z=U,H=l&&l.formats;for(var tt=(U=Z.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(rt,nt,b){var F=b&&b.toUpperCase();return nt||H[b]||t[b]||H[F].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(Y,V,d){return V||d.slice(1)})})).match(n),ft=tt.length,at=0;at<ft;at+=1){var j=tt[at],_=O[j],f=_&&_[0],P=_&&_[1];tt[at]=P?{regex:f,parser:P}:j.replace(/^\[|\]$/g,"")}return function(rt){for(var nt={},b=0,F=0;b<ft;b+=1){var Y=tt[b];if(typeof Y=="string")F+=Y.length;else{var{regex:V,parser:d}=Y,w=rt.slice(F),x=V.exec(w)[0];d.call(nt,x),rt=rt.replace(x,"")}}return function(v){var Q=v.afternoon;if(Q!==void 0){var u=v.hours;Q?u<12&&(v.hours+=12):u===12&&(v.hours=0),delete v.afternoon}}(nt),nt}}return function(U,Z,H){H.p.customParseFormat=!0,U&&U.parseTwoDigitYear&&(M=U.parseTwoDigitYear);var tt=Z.prototype,ft=tt.parse;tt.parse=function(at){var{date:j,utc:_,args:f}=at;this.$u=_;var P=f[1];if(typeof P=="string"){var rt=f[2]===!0,nt=f[3]===!0,b=rt||nt,F=f[2];nt&&(F=f[2]),l=this.$locale(),!rt&&F&&(l=H.Ls[F]),this.$d=function(w,x,v,Q){try{if(["x","X"].indexOf(x)>-1)return new Date((x==="X"?1000:1)*w);var u=z(x)(w),{year:J,month:h,day:mt,hours:m,minutes:q,seconds:K,milliseconds:ut,zone:lt,week:it}=u,k=new Date,X=mt||(J||h?1:k.getDate()),et=J||k.getFullYear(),g=0;J&&!h||(g=h>0?h-1:k.getMonth());var ht,st=m||0,ot=q||0,yt=K||0,gt=ut||0;return lt?new Date(Date.UTC(et,g,X,st,ot,yt,gt+60*lt.offset*1000)):v?new Date(Date.UTC(et,g,X,st,ot,yt,gt)):(ht=new Date(et,g,X,st,ot,yt,gt),it&&(ht=Q(ht).week(it).toDate()),ht)}catch(Tt){return new Date("")}}(j,P,_,H),this.init(),F&&F!==!0&&(this.$L=this.locale(F).$L),b&&j!=this.format(P)&&(this.$d=new Date("")),l={}}else if(P instanceof Array)for(var Y=P.length,V=1;V<=Y;V+=1){f[1]=P[V-1];var d=H.apply(this,f);if(d.isValid()){this.$d=d.$d,this.$L=d.$L,this.init();break}V===Y&&(this.$d=new Date(""))}else ft.call(this,at)}}})});var bn=Se(function(or,cr){(function(t,n){typeof or=="object"&&typeof cr<"u"?cr.exports=n():typeof define=="function"&&define.amd?define(n):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_advancedFormat=n()})(or,function(){return function(t,n){var i=n.prototype,a=i.format;i.format=function(o){var c=this,l=this.$locale();if(!this.isValid())return a.bind(this)(o);var M=this.$utils(),D=(o||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(R){switch(R){case"Q":return Math.ceil((c.$M+1)/3);case"Do":return l.ordinal(c.$D);case"gggg":return c.weekYear();case"GGGG":return c.isoWeekYear();case"wo":return l.ordinal(c.week(),"W");case"w":case"ww":return M.s(c.week(),R==="w"?1:2,"0");case"W":case"WW":return M.s(c.isoWeek(),R==="W"?1:2,"0");case"k":case"kk":return M.s(String(c.$H===0?24:c.$H),R==="k"?1:2,"0");case"X":return Math.floor(c.$d.getTime()/1000);case"x":return c.$d.getTime();case"z":return"["+c.offsetName()+"]";case"zzz":return"["+c.offsetName("long")+"]";default:return R}});return a.bind(this)(D)}}})});var wn=Se(function(ur,lr){(function(t,n){typeof ur=="object"&&typeof lr<"u"?lr.exports=n():typeof define=="function"&&define.amd?define(n):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_duration=n()})(ur,function(){var t,n,i=1000,a=60000,o=3600000,c=86400000,l=31536000000,M=2628000000,D=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,R=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,W={years:l,months:M,days:c,hours:o,minutes:a,seconds:i,milliseconds:1,weeks:604800000},G=function(j){return j instanceof ft},O=function(j,_,f){return new ft(j,f,_.$l)},z=function(j){return n.p(j)+"s"},U=function(j){return j<0},Z=function(j){return U(j)?Math.ceil(j):Math.floor(j)},H=function(j){return Math.abs(j)},tt=function(j,_){return j?U(j)?{negative:!0,format:""+H(j)+_}:{negative:!1,format:""+j+_}:{negative:!1,format:""}},ft=function(){function j(f,P,rt){var nt=this;if(this.$d={},this.$l=rt,f===void 0&&(this.$ms=0,this.parseFromMilliseconds()),P)return O(f*W[z(P)],this);if(typeof f=="number")return this.$ms=f,this.parseFromMilliseconds(),this;if(typeof f=="object")return Object.keys(f).forEach(function(Y){nt.$d[z(Y)]=f[Y]}),this.calMilliseconds(),this;if(typeof f=="string"){var b=f.match(D);if(b){var F=b.slice(2).map(function(Y){return Y!=null?Number(Y):0});return this.$d.years=F[0],this.$d.months=F[1],this.$d.weeks=F[2],this.$d.days=F[3],this.$d.hours=F[4],this.$d.minutes=F[5],this.$d.seconds=F[6],this.calMilliseconds(),this}}return this}var _=j.prototype;return _.calMilliseconds=function(){var f=this;this.$ms=Object.keys(this.$d).reduce(function(P,rt){return P+(f.$d[rt]||0)*W[rt]},0)},_.parseFromMilliseconds=function(){var f=this.$ms;this.$d.years=Z(f/l),f%=l,this.$d.months=Z(f/M),f%=M,this.$d.days=Z(f/c),f%=c,this.$d.hours=Z(f/o),f%=o,this.$d.minutes=Z(f/a),f%=a,this.$d.seconds=Z(f/i),f%=i,this.$d.milliseconds=f},_.toISOString=function(){var f=tt(this.$d.years,"Y"),P=tt(this.$d.months,"M"),rt=+this.$d.days||0;this.$d.weeks&&(rt+=7*this.$d.weeks);var nt=tt(rt,"D"),b=tt(this.$d.hours,"H"),F=tt(this.$d.minutes,"M"),Y=this.$d.seconds||0;this.$d.milliseconds&&(Y+=this.$d.milliseconds/1000,Y=Math.round(1000*Y)/1000);var V=tt(Y,"S"),d=f.negative||P.negative||nt.negative||b.negative||F.negative||V.negative,w=b.format||F.format||V.format?"T":"",x=(d?"-":"")+"P"+f.format+P.format+nt.format+w+b.format+F.format+V.format;return x==="P"||x==="-P"?"P0D":x},_.toJSON=function(){return this.toISOString()},_.format=function(f){var P=f||"YYYY-MM-DDTHH:mm:ss",rt={Y:this.$d.years,YY:n.s(this.$d.years,2,"0"),YYYY:n.s(this.$d.years,4,"0"),M:this.$d.months,MM:n.s(this.$d.months,2,"0"),D:this.$d.days,DD:n.s(this.$d.days,2,"0"),H:this.$d.hours,HH:n.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:n.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:n.s(this.$d.seconds,2,"0"),SSS:n.s(this.$d.milliseconds,3,"0")};return P.replace(R,function(nt,b){return b||String(rt[nt])})},_.as=function(f){return this.$ms/W[z(f)]},_.get=function(f){var P=this.$ms,rt=z(f);return rt==="milliseconds"?P%=1000:P=rt==="weeks"?Z(P/W[rt]):this.$d[rt],P||0},_.add=function(f,P,rt){var nt;return nt=P?f*W[z(P)]:G(f)?f.$ms:O(f,this).$ms,O(this.$ms+nt*(rt?-1:1),this)},_.subtract=function(f,P){return this.add(f,P,!0)},_.locale=function(f){var P=this.clone();return P.$l=f,P},_.clone=function(){return O(this.$ms,this)},_.humanize=function(f){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!f)},_.valueOf=function(){return this.asMilliseconds()},_.milliseconds=function(){return this.get("milliseconds")},_.asMilliseconds=function(){return this.as("milliseconds")},_.seconds=function(){return this.get("seconds")},_.asSeconds=function(){return this.as("seconds")},_.minutes=function(){return this.get("minutes")},_.asMinutes=function(){return this.as("minutes")},_.hours=function(){return this.get("hours")},_.asHours=function(){return this.as("hours")},_.days=function(){return this.get("days")},_.asDays=function(){return this.as("days")},_.weeks=function(){return this.get("weeks")},_.asWeeks=function(){return this.as("weeks")},_.months=function(){return this.get("months")},_.asMonths=function(){return this.as("months")},_.years=function(){return this.get("years")},_.asYears=function(){return this.as("years")},j}(),at=function(j,_,f){return j.add(_.years()*f,"y").add(_.months()*f,"M").add(_.days()*f,"d").add(_.hours()*f,"h").add(_.minutes()*f,"m").add(_.seconds()*f,"s").add(_.milliseconds()*f,"ms")};return function(j,_,f){t=f,n=f().$utils(),f.duration=function(nt,b){var F=f.locale();return O(nt,{$l:F},b)},f.isDuration=G;var P=_.prototype.add,rt=_.prototype.subtract;_.prototype.add=function(nt,b){return G(nt)?at(this,nt,1):P.bind(this)(nt,b)},_.prototype.subtract=function(nt,b){return G(nt)?at(this,nt,-1):rt.bind(this)(nt,b)}}})});function Ee(t){return t}var ye=1,Ae=2,Oe=3,he=4,_r=0.000001;function Bn(t){return"translate("+t+",0)"}function Zn(t){return"translate(0,"+t+")"}function jn(t){return(n)=>+t(n)}function Xn(t,n){if(n=Math.max(0,t.bandwidth()-n*2)/2,t.round())n=Math.round(n);return(i)=>+t(i)+n}function qn(){return!this.__axis}function Yr(t,n){var i=[],a=null,o=null,c=6,l=6,M=3,D=typeof window<"u"&&window.devicePixelRatio>1?0:0.5,R=t===ye||t===he?-1:1,W=t===he||t===Ae?"x":"y",G=t===ye||t===Oe?Bn:Zn;function O(z){var U=a==null?n.ticks?n.ticks.apply(n,i):n.domain():a,Z=o==null?n.tickFormat?n.tickFormat.apply(n,i):Ee:o,H=Math.max(c,0)+M,tt=n.range(),ft=+tt[0]+D,at=+tt[tt.length-1]+D,j=(n.bandwidth?Xn:jn)(n.copy(),D),_=z.selection?z.selection():z,f=_.selectAll(".domain").data([null]),P=_.selectAll(".tick").data(U,n).order(),rt=P.exit(),nt=P.enter().append("g").attr("class","tick"),b=P.select("line"),F=P.select("text");if(f=f.merge(f.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),P=P.merge(nt),b=b.merge(nt.append("line").attr("stroke","currentColor").attr(W+"2",R*c)),F=F.merge(nt.append("text").attr("fill","currentColor").attr(W,R*H).attr("dy",t===ye?"0em":t===Oe?"0.71em":"0.32em")),z!==_)f=f.transition(z),P=P.transition(z),b=b.transition(z),F=F.transition(z),rt=rt.transition(z).attr("opacity",_r).attr("transform",function(Y){return isFinite(Y=j(Y))?G(Y+D):this.getAttribute("transform")}),nt.attr("opacity",_r).attr("transform",function(Y){var V=this.parentNode.__axis;return G((V&&isFinite(V=V(Y))?V:j(Y))+D)});rt.remove(),f.attr("d",t===he||t===Ae?l?"M"+R*l+","+ft+"H"+D+"V"+at+"H"+R*l:"M"+D+","+ft+"V"+at:l?"M"+ft+","+R*l+"V"+D+"H"+at+"V"+R*l:"M"+ft+","+D+"H"+at),P.attr("opacity",1).attr("transform",function(Y){return G(j(Y)+D)}),b.attr(W+"2",R*c),F.attr(W,R*H).text(Z),_.filter(qn).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===Ae?"start":t===he?"end":"middle"),_.each(function(){this.__axis=j})}return O.scale=function(z){return arguments.length?(n=z,O):n},O.ticks=function(){return i=Array.from(arguments),O},O.tickArguments=function(z){return arguments.length?(i=z==null?[]:Array.from(z),O):i.slice()},O.tickValues=function(z){return arguments.length?(a=z==null?null:Array.from(z),O):a&&a.slice()},O.tickFormat=function(z){return arguments.length?(o=z,O):o},O.tickSize=function(z){return arguments.length?(c=l=+z,O):c},O.tickSizeInner=function(z){return arguments.length?(c=+z,O):c},O.tickSizeOuter=function(z){return arguments.length?(l=+z,O):l},O.tickPadding=function(z){return arguments.length?(M=+z,O):M},O.offset=function(z){return arguments.length?(D=+z,O):D},O}function $e(t){return Yr(ye,t)}function He(t){return Yr(Oe,t)}var Fr=Math.PI/180,Ir=180/Math.PI;var ge=18,Ur=0.96422,Lr=1,Wr=0.82521,Er=0.13793103448275862,Qt=0.20689655172413793,Ar=3*Qt*Qt,Qn=Qt*Qt*Qt;function $r(t){if(t instanceof It)return new It(t.l,t.a,t.b,t.opacity);if(t instanceof Ot)return Nr(t);if(!(t instanceof qe))t=Pi(t);var n=ze(t.r),i=ze(t.g),a=ze(t.b),o=Ne((0.2225045*n+0.7168786*i+0.0606169*a)/Lr),c,l;if(n===i&&i===a)c=l=o;else c=Ne((0.4360747*n+0.3850649*i+0.1430804*a)/Ur),l=Ne((0.0139322*n+0.0971045*i+0.7141733*a)/Wr);return new It(116*o-16,500*(c-o),200*(o-l),t.opacity)}function Hr(t,n,i,a){return arguments.length===1?$r(t):new It(t,n,i,a==null?1:a)}function It(t,n,i,a){this.l=+t,this.a=+n,this.b=+i,this.opacity=+a}En(It,Hr,kr(An,{brighter(t){return new It(this.l+ge*(t==null?1:t),this.a,this.b,this.opacity)},darker(t){return new It(this.l-ge*(t==null?1:t),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,n=isNaN(this.a)?t:t+this.a/500,i=isNaN(this.b)?t:t-this.b/200;return n=Ur*Pe(n),t=Lr*Pe(t),i=Wr*Pe(i),new qe(Ve(3.1338561*n-1.6168667*t-0.4906146*i),Ve(-0.9787684*n+1.9161415*t+0.033454*i),Ve(0.0719453*n-0.2289914*t+1.4052427*i),this.opacity)}}));function Ne(t){return t>Qn?Math.pow(t,0.3333333333333333):t/Ar+Er}function Pe(t){return t>Qt?t*t*t:Ar*(t-Er)}function Ve(t){return 255*(t<=0.0031308?12.92*t:1.055*Math.pow(t,0.4166666666666667)-0.055)}function ze(t){return(t/=255)<=0.04045?t/12.92:Math.pow((t+0.055)/1.055,2.4)}function Jn(t){if(t instanceof Ot)return new Ot(t.h,t.c,t.l,t.opacity);if(!(t instanceof It))t=$r(t);if(t.a===0&&t.b===0)return new Ot(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var n=Math.atan2(t.b,t.a)*Ir;return new Ot(n<0?n+360:n,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function ke(t,n,i,a){return arguments.length===1?Jn(t):new Ot(t,n,i,a==null?1:a)}function Ot(t,n,i,a){this.h=+t,this.c=+n,this.l=+i,this.opacity=+a}function Nr(t){if(isNaN(t.h))return new It(t.l,0,0,t.opacity);var n=t.h*Fr;return new It(t.l,Math.cos(n)*t.c,Math.sin(n)*t.c,t.opacity)}En(Ot,ke,kr(An,{brighter(t){return new Ot(this.h,this.c,this.l+ge*(t==null?1:t),this.opacity)},darker(t){return new Ot(this.h,this.c,this.l-ge*(t==null?1:t),this.opacity)},rgb(){return Nr(this).rgb()}}));function Vr(t){return function(n,i){var a=t((n=ke(n)).h,(i=ke(i)).h),o=on(n.c,i.c),c=on(n.l,i.l),l=on(n.opacity,i.opacity);return function(M){return n.h=a(M),n.c=o(M),n.l=c(M),n.opacity=l(M),n+""}}}var zr=Vr(lo),Ls=Vr(on);function Re(t,n){t=t.slice();var i=0,a=t.length-1,o=t[i],c=t[a],l;if(c<o)l=i,i=a,a=l,l=o,o=c,c=l;return t[i]=n.floor(o),t[a]=n.ceil(c),t}var Be=new Date,Ze=new Date;function dt(t,n,i,a){function o(c){return t(c=arguments.length===0?new Date:new Date(+c)),c}if(o.floor=(c)=>(t(c=new Date(+c)),c),o.ceil=(c)=>(t(c=new Date(c-1)),n(c,1),t(c),c),o.round=(c)=>{let l=o(c),M=o.ceil(c);return c-l<M-c?l:M},o.offset=(c,l)=>(n(c=new Date(+c),l==null?1:Math.floor(l)),c),o.range=(c,l,M)=>{let D=[];if(c=o.ceil(c),M=M==null?1:Math.floor(M),!(c<l)||!(M>0))return D;let R;do D.push(R=new Date(+c)),n(c,M),t(c);while(R<c&&c<l);return D},o.filter=(c)=>dt((l)=>{if(l>=l)while(t(l),!c(l))l.setTime(l-1)},(l,M)=>{if(l>=l)if(M<0)while(++M<=0)while(n(l,-1),!c(l));else while(--M>=0)while(n(l,1),!c(l));}),i)o.count=(c,l)=>(Be.setTime(+c),Ze.setTime(+l),t(Be),t(Ze),Math.floor(i(Be,Ze))),o.every=(c)=>(c=Math.floor(c),!isFinite(c)||!(c>0)?null:!(c>1)?o:o.filter(a?(l)=>a(l)%c===0:(l)=>o.count(0,l)%c===0));return o}var Ut=dt(()=>{},(t,n)=>{t.setTime(+t+n)},(t,n)=>n-t);Ut.every=(t)=>{if(t=Math.floor(t),!isFinite(t)||!(t>0))return null;if(!(t>1))return Ut;return dt((n)=>{n.setTime(Math.floor(n/t)*t)},(n,i)=>{n.setTime(+n+i*t)},(n,i)=>(i-n)/t)};var Rr=Ut.range;var St=1000,vt=60000,Lt=3600000,Vt=86400000,se=604800000,je=2592000000,pe=31536000000;var bt=dt((t)=>{t.setTime(t-t.getMilliseconds())},(t,n)=>{t.setTime(+t+n*St)},(t,n)=>(n-t)/St,(t)=>t.getUTCSeconds()),Br=bt.range;var $t=dt((t)=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*St)},(t,n)=>{t.setTime(+t+n*vt)},(t,n)=>(n-t)/vt,(t)=>t.getMinutes()),Kn=$t.range,Te=dt((t)=>{t.setUTCSeconds(0,0)},(t,n)=>{t.setTime(+t+n*vt)},(t,n)=>(n-t)/vt,(t)=>t.getUTCMinutes()),ti=Te.range;var Ht=dt((t)=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*St-t.getMinutes()*vt)},(t,n)=>{t.setTime(+t+n*Lt)},(t,n)=>(n-t)/Lt,(t)=>t.getHours()),ei=Ht.range,ve=dt((t)=>{t.setUTCMinutes(0,0,0)},(t,n)=>{t.setTime(+t+n*Lt)},(t,n)=>(n-t)/Lt,(t)=>t.getUTCHours()),ri=ve.range;var _t=dt((t)=>t.setHours(0,0,0,0),(t,n)=>t.setDate(t.getDate()+n),(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*vt)/Vt,(t)=>t.getDate()-1),ni=_t.range,oe=dt((t)=>{t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n)},(t,n)=>(n-t)/Vt,(t)=>t.getUTCDate()-1),ii=oe.range,xe=dt((t)=>{t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n)},(t,n)=>(n-t)/Vt,(t)=>Math.floor(t/Vt)),ai=xe.range;function Bt(t){return dt((n)=>{n.setDate(n.getDate()-(n.getDay()+7-t)%7),n.setHours(0,0,0,0)},(n,i)=>{n.setDate(n.getDate()+i*7)},(n,i)=>(i-n-(i.getTimezoneOffset()-n.getTimezoneOffset())*vt)/se)}var Yt=Bt(0),zt=Bt(1),be=Bt(2),we=Bt(3),Wt=Bt(4),Me=Bt(5),De=Bt(6),Zr=Yt.range,si=zt.range,oi=be.range,ci=we.range,ui=Wt.range,li=Me.range,fi=De.range;function Zt(t){return dt((n)=>{n.setUTCDate(n.getUTCDate()-(n.getUTCDay()+7-t)%7),n.setUTCHours(0,0,0,0)},(n,i)=>{n.setUTCDate(n.getUTCDate()+i*7)},(n,i)=>(i-n)/se)}var jt=Zt(0),Jt=Zt(1),jr=Zt(2),Xr=Zt(3),Rt=Zt(4),Gr=Zt(5),qr=Zt(6),Qr=jt.range,di=Jt.range,mi=jr.range,hi=Xr.range,yi=Rt.range,gi=Gr.range,ki=qr.range;var Nt=dt((t)=>{t.setDate(1),t.setHours(0,0,0,0)},(t,n)=>{t.setMonth(t.getMonth()+n)},(t,n)=>n.getMonth()-t.getMonth()+(n.getFullYear()-t.getFullYear())*12,(t)=>t.getMonth()),pi=Nt.range,_e=dt((t)=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCMonth(t.getUTCMonth()+n)},(t,n)=>n.getUTCMonth()-t.getUTCMonth()+(n.getUTCFullYear()-t.getUTCFullYear())*12,(t)=>t.getUTCMonth()),Ti=_e.range;var wt=dt((t)=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n)},(t,n)=>n.getFullYear()-t.getFullYear(),(t)=>t.getFullYear());wt.every=(t)=>!isFinite(t=Math.floor(t))||!(t>0)?null:dt((n)=>{n.setFullYear(Math.floor(n.getFullYear()/t)*t),n.setMonth(0,1),n.setHours(0,0,0,0)},(n,i)=>{n.setFullYear(n.getFullYear()+i*t)});var vi=wt.range,Ft=dt((t)=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n)},(t,n)=>n.getUTCFullYear()-t.getUTCFullYear(),(t)=>t.getUTCFullYear());Ft.every=(t)=>!isFinite(t=Math.floor(t))||!(t>0)?null:dt((n)=>{n.setUTCFullYear(Math.floor(n.getUTCFullYear()/t)*t),n.setUTCMonth(0,1),n.setUTCHours(0,0,0,0)},(n,i)=>{n.setUTCFullYear(n.getUTCFullYear()+i*t)});var xi=Ft.range;function Jr(t,n,i,a,o,c){let l=[[bt,1,St],[bt,5,5*St],[bt,15,15*St],[bt,30,30*St],[c,1,vt],[c,5,5*vt],[c,15,15*vt],[c,30,30*vt],[o,1,Lt],[o,3,3*Lt],[o,6,6*Lt],[o,12,12*Lt],[a,1,Vt],[a,2,2*Vt],[i,1,se],[n,1,je],[n,3,3*je],[t,1,pe]];function M(R,W,G){let O=W<R;if(O)[R,W]=[W,R];let z=G&&typeof G.range==="function"?G:D(R,W,G),U=z?z.range(R,+W+1):[];return O?U.reverse():U}function D(R,W,G){let O=Math.abs(W-R)/G,z=nr(([,,H])=>H).right(l,O);if(z===l.length)return t.every(Pr(R/pe,W/pe,G));if(z===0)return Ut.every(Math.max(Pr(R,W,G),1));let[U,Z]=l[O/l[z-1][2]<l[z][2]/O?z-1:z];return U.every(Z)}return[M,D]}var[bi,wi]=Jr(Ft,_e,jt,xe,ve,Te),[Xe,Ge]=Jr(wt,Nt,Yt,_t,Ht,$t);function Qe(t){if(0<=t.y&&t.y<100){var n=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return n.setFullYear(t.y),n}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function Je(t){if(0<=t.y&&t.y<100){var n=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return n.setUTCFullYear(t.y),n}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function ce(t,n,i){return{y:t,m:n,d:i,H:0,M:0,S:0,L:0}}function Ke(t){var{dateTime:n,date:i,time:a,periods:o,days:c,shortDays:l,months:M,shortMonths:D}=t,R=ue(o),W=le(o),G=ue(c),O=le(c),z=ue(l),U=le(l),Z=ue(M),H=le(M),tt=ue(D),ft=le(D),at={a:v,A:Q,b:u,B:J,c:null,d:an,e:an,f:ji,g:ia,G:sa,H:Ri,I:Bi,j:Zi,L:fn,m:Xi,M:Gi,p:h,q:mt,Q:un,s:ln,S:qi,u:Qi,U:Ji,V:Ki,w:ta,W:ea,x:null,X:null,y:ra,Y:aa,Z:oa,"%":cn},j={a:m,A:q,b:K,B:ut,c:null,d:sn,e:sn,f:fa,g:ba,G:Ma,H:ca,I:ua,j:la,L:hn,m:da,M:ma,p:lt,q:it,Q:un,s:ln,S:ha,u:ya,U:ga,V:pa,w:Ta,W:va,x:null,X:null,y:xa,Y:wa,Z:Da,"%":cn},_={a:b,A:F,b:Y,B:V,c:d,d:rn,e:rn,f:Hi,g:en,G:tn,H:nn,I:nn,j:Ei,L:$i,m:Wi,M:Ai,p:nt,q:Li,Q:Vi,s:zi,S:Oi,u:_i,U:Yi,V:Fi,w:Si,W:Ii,x:w,X:x,y:en,Y:tn,Z:Ui,"%":Ni};at.x=f(i,at),at.X=f(a,at),at.c=f(n,at),j.x=f(i,j),j.X=f(a,j),j.c=f(n,j);function f(k,X){return function(et){var g=[],ht=-1,st=0,ot=k.length,yt,gt,Tt;if(!(et instanceof Date))et=new Date(+et);while(++ht<ot)if(k.charCodeAt(ht)===37){if(g.push(k.slice(st,ht)),(gt=Kr[yt=k.charAt(++ht)])!=null)yt=k.charAt(++ht);else gt=yt==="e"?" ":"0";if(Tt=X[yt])yt=Tt(et,gt);g.push(yt),st=ht+1}return g.push(k.slice(st,ht)),g.join("")}}function P(k,X){return function(et){var g=ce(1900,void 0,1),ht=rt(g,k,et+="",0),st,ot;if(ht!=et.length)return null;if("Q"in g)return new Date(g.Q);if("s"in g)return new Date(g.s*1000+("L"in g?g.L:0));if(X&&!("Z"in g))g.Z=0;if("p"in g)g.H=g.H%12+g.p*12;if(g.m===void 0)g.m="q"in g?g.q:0;if("V"in g){if(g.V<1||g.V>53)return null;if(!("w"in g))g.w=1;if("Z"in g)st=Je(ce(g.y,0,1)),ot=st.getUTCDay(),st=ot>4||ot===0?Jt.ceil(st):Jt(st),st=oe.offset(st,(g.V-1)*7),g.y=st.getUTCFullYear(),g.m=st.getUTCMonth(),g.d=st.getUTCDate()+(g.w+6)%7;else st=Qe(ce(g.y,0,1)),ot=st.getDay(),st=ot>4||ot===0?zt.ceil(st):zt(st),st=_t.offset(st,(g.V-1)*7),g.y=st.getFullYear(),g.m=st.getMonth(),g.d=st.getDate()+(g.w+6)%7}else if("W"in g||"U"in g){if(!("w"in g))g.w="u"in g?g.u%7:("W"in g)?1:0;ot="Z"in g?Je(ce(g.y,0,1)).getUTCDay():Qe(ce(g.y,0,1)).getDay(),g.m=0,g.d="W"in g?(g.w+6)%7+g.W*7-(ot+5)%7:g.w+g.U*7-(ot+6)%7}if("Z"in g)return g.H+=g.Z/100|0,g.M+=g.Z%100,Je(g);return Qe(g)}}function rt(k,X,et,g){var ht=0,st=X.length,ot=et.length,yt,gt;while(ht<st){if(g>=ot)return-1;if(yt=X.charCodeAt(ht++),yt===37){if(yt=X.charAt(ht++),gt=_[yt in Kr?X.charAt(ht++):yt],!gt||(g=gt(k,et,g))<0)return-1}else if(yt!=et.charCodeAt(g++))return-1}return g}function nt(k,X,et){var g=R.exec(X.slice(et));return g?(k.p=W.get(g[0].toLowerCase()),et+g[0].length):-1}function b(k,X,et){var g=z.exec(X.slice(et));return g?(k.w=U.get(g[0].toLowerCase()),et+g[0].length):-1}function F(k,X,et){var g=G.exec(X.slice(et));return g?(k.w=O.get(g[0].toLowerCase()),et+g[0].length):-1}function Y(k,X,et){var g=tt.exec(X.slice(et));return g?(k.m=ft.get(g[0].toLowerCase()),et+g[0].length):-1}function V(k,X,et){var g=Z.exec(X.slice(et));return g?(k.m=H.get(g[0].toLowerCase()),et+g[0].length):-1}function d(k,X,et){return rt(k,n,X,et)}function w(k,X,et){return rt(k,i,X,et)}function x(k,X,et){return rt(k,a,X,et)}function v(k){return l[k.getDay()]}function Q(k){return c[k.getDay()]}function u(k){return D[k.getMonth()]}function J(k){return M[k.getMonth()]}function h(k){return o[+(k.getHours()>=12)]}function mt(k){return 1+~~(k.getMonth()/3)}function m(k){return l[k.getUTCDay()]}function q(k){return c[k.getUTCDay()]}function K(k){return D[k.getUTCMonth()]}function ut(k){return M[k.getUTCMonth()]}function lt(k){return o[+(k.getUTCHours()>=12)]}function it(k){return 1+~~(k.getUTCMonth()/3)}return{format:function(k){var X=f(k+="",at);return X.toString=function(){return k},X},parse:function(k){var X=P(k+="",!1);return X.toString=function(){return k},X},utcFormat:function(k){var X=f(k+="",j);return X.toString=function(){return k},X},utcParse:function(k){var X=P(k+="",!0);return X.toString=function(){return k},X}}}var Kr={"-":"",_:" ","0":"0"},pt=/^\s*\d+/,Mi=/^%/,Di=/[\\^$*+?|[\]().{}]/g;function ct(t,n,i){var a=t<0?"-":"",o=(a?-t:t)+"",c=o.length;return a+(c<i?Array(i-c+1).join(n)+o:o)}function Ci(t){return t.replace(Di,"\\$&")}function ue(t){return new RegExp("^(?:"+t.map(Ci).join("|")+")","i")}function le(t){return new Map(t.map((n,i)=>[n.toLowerCase(),i]))}function Si(t,n,i){var a=pt.exec(n.slice(i,i+1));return a?(t.w=+a[0],i+a[0].length):-1}function _i(t,n,i){var a=pt.exec(n.slice(i,i+1));return a?(t.u=+a[0],i+a[0].length):-1}function Yi(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.U=+a[0],i+a[0].length):-1}function Fi(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.V=+a[0],i+a[0].length):-1}function Ii(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.W=+a[0],i+a[0].length):-1}function tn(t,n,i){var a=pt.exec(n.slice(i,i+4));return a?(t.y=+a[0],i+a[0].length):-1}function en(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.y=+a[0]+(+a[0]>68?1900:2000),i+a[0].length):-1}function Ui(t,n,i){var a=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(n.slice(i,i+6));return a?(t.Z=a[1]?0:-(a[2]+(a[3]||"00")),i+a[0].length):-1}function Li(t,n,i){var a=pt.exec(n.slice(i,i+1));return a?(t.q=a[0]*3-3,i+a[0].length):-1}function Wi(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.m=a[0]-1,i+a[0].length):-1}function rn(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.d=+a[0],i+a[0].length):-1}function Ei(t,n,i){var a=pt.exec(n.slice(i,i+3));return a?(t.m=0,t.d=+a[0],i+a[0].length):-1}function nn(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.H=+a[0],i+a[0].length):-1}function Ai(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.M=+a[0],i+a[0].length):-1}function Oi(t,n,i){var a=pt.exec(n.slice(i,i+2));return a?(t.S=+a[0],i+a[0].length):-1}function $i(t,n,i){var a=pt.exec(n.slice(i,i+3));return a?(t.L=+a[0],i+a[0].length):-1}function Hi(t,n,i){var a=pt.exec(n.slice(i,i+6));return a?(t.L=Math.floor(a[0]/1000),i+a[0].length):-1}function Ni(t,n,i){var a=Mi.exec(n.slice(i,i+1));return a?i+a[0].length:-1}function Vi(t,n,i){var a=pt.exec(n.slice(i));return a?(t.Q=+a[0],i+a[0].length):-1}function zi(t,n,i){var a=pt.exec(n.slice(i));return a?(t.s=+a[0],i+a[0].length):-1}function an(t,n){return ct(t.getDate(),n,2)}function Ri(t,n){return ct(t.getHours(),n,2)}function Bi(t,n){return ct(t.getHours()%12||12,n,2)}function Zi(t,n){return ct(1+_t.count(wt(t),t),n,3)}function fn(t,n){return ct(t.getMilliseconds(),n,3)}function ji(t,n){return fn(t,n)+"000"}function Xi(t,n){return ct(t.getMonth()+1,n,2)}function Gi(t,n){return ct(t.getMinutes(),n,2)}function qi(t,n){return ct(t.getSeconds(),n,2)}function Qi(t){var n=t.getDay();return n===0?7:n}function Ji(t,n){return ct(Yt.count(wt(t)-1,t),n,2)}function dn(t){var n=t.getDay();return n>=4||n===0?Wt(t):Wt.ceil(t)}function Ki(t,n){return t=dn(t),ct(Wt.count(wt(t),t)+(wt(t).getDay()===4),n,2)}function ta(t){return t.getDay()}function ea(t,n){return ct(zt.count(wt(t)-1,t),n,2)}function ra(t,n){return ct(t.getFullYear()%100,n,2)}function ia(t,n){return t=dn(t),ct(t.getFullYear()%100,n,2)}function aa(t,n){return ct(t.getFullYear()%1e4,n,4)}function sa(t,n){var i=t.getDay();return t=i>=4||i===0?Wt(t):Wt.ceil(t),ct(t.getFullYear()%1e4,n,4)}function oa(t){var n=t.getTimezoneOffset();return(n>0?"-":(n*=-1,"+"))+ct(n/60|0,"0",2)+ct(n%60,"0",2)}function sn(t,n){return ct(t.getUTCDate(),n,2)}function ca(t,n){return ct(t.getUTCHours(),n,2)}function ua(t,n){return ct(t.getUTCHours()%12||12,n,2)}function la(t,n){return ct(1+oe.count(Ft(t),t),n,3)}function hn(t,n){return ct(t.getUTCMilliseconds(),n,3)}function fa(t,n){return hn(t,n)+"000"}function da(t,n){return ct(t.getUTCMonth()+1,n,2)}function ma(t,n){return ct(t.getUTCMinutes(),n,2)}function ha(t,n){return ct(t.getUTCSeconds(),n,2)}function ya(t){var n=t.getUTCDay();return n===0?7:n}function ga(t,n){return ct(jt.count(Ft(t)-1,t),n,2)}function yn(t){var n=t.getUTCDay();return n>=4||n===0?Rt(t):Rt.ceil(t)}function pa(t,n){return t=yn(t),ct(Rt.count(Ft(t),t)+(Ft(t).getUTCDay()===4),n,2)}function Ta(t){return t.getUTCDay()}function va(t,n){return ct(Jt.count(Ft(t)-1,t),n,2)}function xa(t,n){return ct(t.getUTCFullYear()%100,n,2)}function ba(t,n){return t=yn(t),ct(t.getUTCFullYear()%100,n,2)}function wa(t,n){return ct(t.getUTCFullYear()%1e4,n,4)}function Ma(t,n){var i=t.getUTCDay();return t=i>=4||i===0?Rt(t):Rt.ceil(t),ct(t.getUTCFullYear()%1e4,n,4)}function Da(){return"+0000"}function cn(){return"%"}function un(t){return+t}function ln(t){return Math.floor(+t/1000)}var Kt,Xt,gn,kn,pn;tr({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function tr(t){return Kt=Ke(t),Xt=Kt.format,gn=Kt.parse,kn=Kt.utcFormat,pn=Kt.utcParse,Kt}function Ca(t){return new Date(t)}function Sa(t){return t instanceof Date?+t:+new Date(+t)}function Tn(t,n,i,a,o,c,l,M,D,R){var W=Or(),{invert:G,domain:O}=W,z=R(".%L"),U=R(":%S"),Z=R("%I:%M"),H=R("%I %p"),tt=R("%a %d"),ft=R("%b %d"),at=R("%B"),j=R("%Y");function _(f){return(D(f)<f?z:M(f)<f?U:l(f)<f?Z:c(f)<f?H:a(f)<f?o(f)<f?tt:ft:i(f)<f?at:j)(f)}return W.invert=function(f){return new Date(G(f))},W.domain=function(f){return arguments.length?O(Array.from(f,Sa)):O().map(Ca)},W.ticks=function(f){var P=O();return t(P[0],P[P.length-1],f==null?10:f)},W.tickFormat=function(f,P){return P==null?_:R(P)},W.nice=function(f){var P=O();if(!f||typeof f.range!=="function")f=n(P[0],P[P.length-1],f==null?10:f);return f?O(Re(P,f)):W},W.copy=function(){return na(W,Tn(t,n,i,a,o,c,l,M,D,R))},W}function er(){return Mt.apply(Tn(Xe,Ge,wt,Nt,Yt,_t,Ht,$t,bt,Xt).domain([new Date(2000,0,1),new Date(2000,0,2)]),arguments)}var Sn=Ce(Gn(),1),Dt=Ce(ka(),1),_n=Ce(vn(),1),Yn=Ce(xn(),1),Fn=Ce(bn(),1),ee=Ce(ka(),1),Rn=Ce(wn(),1);var dr=function(){var t=e(function(V,d,w,x){for(w=w||{},x=V.length;x--;w[V[x]]=d);return w},"o"),n=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],i=[1,26],a=[1,27],o=[1,28],c=[1,29],l=[1,30],M=[1,31],D=[1,32],R=[1,33],W=[1,34],G=[1,9],O=[1,10],z=[1,11],U=[1,12],Z=[1,13],H=[1,14],tt=[1,15],ft=[1,16],at=[1,19],j=[1,20],_=[1,21],f=[1,22],P=[1,23],rt=[1,25],nt=[1,35],b={trace:e(function(){},"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:e(function(d,w,x,v,Q,u,J){var h=u.length-1;switch(Q){case 1:return u[h-1];case 2:this.$=[];break;case 3:u[h-1].push(u[h]),this.$=u[h-1];break;case 4:case 5:this.$=u[h];break;case 6:case 7:this.$=[];break;case 8:v.setWeekday("monday");break;case 9:v.setWeekday("tuesday");break;case 10:v.setWeekday("wednesday");break;case 11:v.setWeekday("thursday");break;case 12:v.setWeekday("friday");break;case 13:v.setWeekday("saturday");break;case 14:v.setWeekday("sunday");break;case 15:v.setWeekend("friday");break;case 16:v.setWeekend("saturday");break;case 17:v.setDateFormat(u[h].substr(11)),this.$=u[h].substr(11);break;case 18:v.enableInclusiveEndDates(),this.$=u[h].substr(18);break;case 19:v.TopAxis(),this.$=u[h].substr(8);break;case 20:v.setAxisFormat(u[h].substr(11)),this.$=u[h].substr(11);break;case 21:v.setTickInterval(u[h].substr(13)),this.$=u[h].substr(13);break;case 22:v.setExcludes(u[h].substr(9)),this.$=u[h].substr(9);break;case 23:v.setIncludes(u[h].substr(9)),this.$=u[h].substr(9);break;case 24:v.setTodayMarker(u[h].substr(12)),this.$=u[h].substr(12);break;case 27:v.setDiagramTitle(u[h].substr(6)),this.$=u[h].substr(6);break;case 28:this.$=u[h].trim(),v.setAccTitle(this.$);break;case 29:case 30:this.$=u[h].trim(),v.setAccDescription(this.$);break;case 31:v.addSection(u[h].substr(8)),this.$=u[h].substr(8);break;case 33:v.addTask(u[h-1],u[h]),this.$="task";break;case 34:this.$=u[h-1],v.setClickEvent(u[h-1],u[h],null);break;case 35:this.$=u[h-2],v.setClickEvent(u[h-2],u[h-1],u[h]);break;case 36:this.$=u[h-2],v.setClickEvent(u[h-2],u[h-1],null),v.setLink(u[h-2],u[h]);break;case 37:this.$=u[h-3],v.setClickEvent(u[h-3],u[h-2],u[h-1]),v.setLink(u[h-3],u[h]);break;case 38:this.$=u[h-2],v.setClickEvent(u[h-2],u[h],null),v.setLink(u[h-2],u[h-1]);break;case 39:this.$=u[h-3],v.setClickEvent(u[h-3],u[h-1],u[h]),v.setLink(u[h-3],u[h-2]);break;case 40:this.$=u[h-1],v.setLink(u[h-1],u[h]);break;case 41:case 47:this.$=u[h-1]+" "+u[h];break;case 42:case 43:case 45:this.$=u[h-2]+" "+u[h-1]+" "+u[h];break;case 44:case 46:this.$=u[h-3]+" "+u[h-2]+" "+u[h-1]+" "+u[h];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(n,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:i,13:a,14:o,15:c,16:l,17:M,18:D,19:18,20:R,21:W,22:G,23:O,24:z,25:U,26:Z,27:H,28:tt,29:ft,30:at,31:j,33:_,35:f,36:P,37:24,38:rt,40:nt},t(n,[2,7],{1:[2,1]}),t(n,[2,3]),{9:36,11:17,12:i,13:a,14:o,15:c,16:l,17:M,18:D,19:18,20:R,21:W,22:G,23:O,24:z,25:U,26:Z,27:H,28:tt,29:ft,30:at,31:j,33:_,35:f,36:P,37:24,38:rt,40:nt},t(n,[2,5]),t(n,[2,6]),t(n,[2,17]),t(n,[2,18]),t(n,[2,19]),t(n,[2,20]),t(n,[2,21]),t(n,[2,22]),t(n,[2,23]),t(n,[2,24]),t(n,[2,25]),t(n,[2,26]),t(n,[2,27]),{32:[1,37]},{34:[1,38]},t(n,[2,30]),t(n,[2,31]),t(n,[2,32]),{39:[1,39]},t(n,[2,8]),t(n,[2,9]),t(n,[2,10]),t(n,[2,11]),t(n,[2,12]),t(n,[2,13]),t(n,[2,14]),t(n,[2,15]),t(n,[2,16]),{41:[1,40],43:[1,41]},t(n,[2,4]),t(n,[2,28]),t(n,[2,29]),t(n,[2,33]),t(n,[2,34],{42:[1,42],43:[1,43]}),t(n,[2,40],{41:[1,44]}),t(n,[2,35],{43:[1,45]}),t(n,[2,36]),t(n,[2,38],{42:[1,46]}),t(n,[2,37]),t(n,[2,39])],defaultActions:{},parseError:e(function(d,w){if(w.recoverable)this.trace(d);else{var x=Error(d);throw x.hash=w,x}},"parseError"),parse:e(function(d){var w=this,x=[0],v=[],Q=[null],u=[],J=this.table,h="",mt=0,m=0,q=0,K=2,ut=1,lt=u.slice.call(arguments,1),it=Object.create(this.lexer),k={yy:{}};for(var X in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,X))k.yy[X]=this.yy[X];if(it.setInput(d,k.yy),k.yy.lexer=it,k.yy.parser=this,typeof it.yylloc>"u")it.yylloc={};var et=it.yylloc;u.push(et);var g=it.options&&it.options.ranges;if(typeof k.yy.parseError==="function")this.parseError=k.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function ht(Ct){x.length=x.length-2*Ct,Q.length=Q.length-Ct,u.length=u.length-Ct}e(ht,"popStack");function st(){var Ct=v.pop()||it.lex()||ut;if(typeof Ct!=="number"){if(Ct instanceof Array)v=Ct,Ct=v.pop();Ct=w.symbols_[Ct]||Ct}return Ct}e(st,"lex");var ot,yt,gt,Tt,ps,Le,qt={},de,At,Sr,me;while(!0){if(gt=x[x.length-1],this.defaultActions[gt])Tt=this.defaultActions[gt];else{if(ot===null||typeof ot>"u")ot=st();Tt=J[gt]&&J[gt][ot]}if(typeof Tt>"u"||!Tt.length||!Tt[0]){var We="";me=[];for(de in J[gt])if(this.terminals_[de]&&de>K)me.push("'"+this.terminals_[de]+"'");if(it.showPosition)We="Parse error on line "+(mt+1)+`:
2
- `+it.showPosition()+`
3
- Expecting `+me.join(", ")+", got '"+(this.terminals_[ot]||ot)+"'";else We="Parse error on line "+(mt+1)+": Unexpected "+(ot==ut?"end of input":"'"+(this.terminals_[ot]||ot)+"'");this.parseError(We,{text:it.match,token:this.terminals_[ot]||ot,line:it.yylineno,loc:et,expected:me})}if(Tt[0]instanceof Array&&Tt.length>1)throw Error("Parse Error: multiple actions possible at state: "+gt+", token: "+ot);switch(Tt[0]){case 1:if(x.push(ot),Q.push(it.yytext),u.push(it.yylloc),x.push(Tt[1]),ot=null,!yt){if(m=it.yyleng,h=it.yytext,mt=it.yylineno,et=it.yylloc,q>0)q--}else ot=yt,yt=null;break;case 2:if(At=this.productions_[Tt[1]][1],qt.$=Q[Q.length-At],qt._$={first_line:u[u.length-(At||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(At||1)].first_column,last_column:u[u.length-1].last_column},g)qt._$.range=[u[u.length-(At||1)].range[0],u[u.length-1].range[1]];if(Le=this.performAction.apply(qt,[h,m,mt,k.yy,Tt[1],Q,u].concat(lt)),typeof Le<"u")return Le;if(At)x=x.slice(0,-1*At*2),Q=Q.slice(0,-1*At),u=u.slice(0,-1*At);x.push(this.productions_[Tt[1]][0]),Q.push(qt.$),u.push(qt._$),Sr=J[x[x.length-2]][x[x.length-1]],x.push(Sr);break;case 3:return!0}}return!0},"parse")},F=function(){var V={EOF:1,parseError:e(function(w,x){if(this.yy.parser)this.yy.parser.parseError(w,x);else throw Error(w)},"parseError"),setInput:e(function(d,w){if(this.yy=w||this.yy||{},this._input=d,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:e(function(){var d=this._input[0];this.yytext+=d,this.yyleng++,this.offset++,this.match+=d,this.matched+=d;var w=d.match(/(?:\r\n?|\n).*/g);if(w)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),d},"input"),unput:e(function(d){var w=d.length,x=d.split(/(?:\r\n?|\n)/g);this._input=d+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-w),this.offset-=w;var v=this.match.split(/(?:\r\n?|\n)/g);if(this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),x.length-1)this.yylineno-=x.length-1;var Q=this.yylloc.range;if(this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:x?(x.length===v.length?this.yylloc.first_column:0)+v[v.length-x.length].length-x[0].length:this.yylloc.first_column-w},this.options.ranges)this.yylloc.range=[Q[0],Q[0]+this.yyleng-w];return this.yyleng=this.yytext.length,this},"unput"),more:e(function(){return this._more=!0,this},"more"),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
- `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:e(function(d){this.unput(this.match.slice(d))},"less"),pastInput:e(function(){var d=this.matched.substr(0,this.matched.length-this.match.length);return(d.length>20?"...":"")+d.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:e(function(){var d=this.match;if(d.length<20)d+=this._input.substr(0,20-d.length);return(d.substr(0,20)+(d.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:e(function(){var d=this.pastInput(),w=Array(d.length+1).join("-");return d+this.upcomingInput()+`
5
- `+w+"^"},"showPosition"),test_match:e(function(d,w){var x,v,Q;if(this.options.backtrack_lexer){if(Q={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges)Q.yylloc.range=this.yylloc.range.slice(0)}if(v=d[0].match(/(?:\r\n?|\n).*/g),v)this.yylineno+=v.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:v?v[v.length-1].length-v[v.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+d[0].length},this.yytext+=d[0],this.match+=d[0],this.matches=d,this.yyleng=this.yytext.length,this.options.ranges)this.yylloc.range=[this.offset,this.offset+=this.yyleng];if(this._more=!1,this._backtrack=!1,this._input=this._input.slice(d[0].length),this.matched+=d[0],x=this.performAction.call(this,this.yy,this,w,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(x)return x;else if(this._backtrack){for(var u in Q)this[u]=Q[u];return!1}return!1},"test_match"),next:e(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var d,w,x,v;if(!this._more)this.yytext="",this.match="";var Q=this._currentRules();for(var u=0;u<Q.length;u++)if(x=this._input.match(this.rules[Q[u]]),x&&(!w||x[0].length>w[0].length)){if(w=x,v=u,this.options.backtrack_lexer)if(d=this.test_match(x,Q[u]),d!==!1)return d;else if(this._backtrack){w=!1;continue}else return!1;else if(!this.options.flex)break}if(w){if(d=this.test_match(w,Q[v]),d!==!1)return d;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
- `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var w=this.next();if(w)return w;else return this.lex()},"lex"),begin:e(function(w){this.conditionStack.push(w)},"begin"),popState:e(function(){var w=this.conditionStack.length-1;if(w>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:e(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:e(function(w){if(w=this.conditionStack.length-1-Math.abs(w||0),w>=0)return this.conditionStack[w];else return"INITIAL"},"topState"),pushState:e(function(w){this.begin(w)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:e(function(w,x,v,Q){var u=Q;switch(v){case 0:return this.begin("open_directive"),"open_directive";break;case 1:return this.begin("acc_title"),31;break;case 2:return this.popState(),"acc_title_value";break;case 3:return this.begin("acc_descr"),33;break;case 4:return this.popState(),"acc_descr_value";break;case 5:this.begin("acc_descr_multiline");break;case 6:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:break;case 9:break;case 10:break;case 11:return 10;case 12:break;case 13:break;case 14:this.begin("href");break;case 15:this.popState();break;case 16:return 43;case 17:this.begin("callbackname");break;case 18:this.popState();break;case 19:this.popState(),this.begin("callbackargs");break;case 20:return 41;case 21:this.popState();break;case 22:return 42;case 23:this.begin("click");break;case 24:this.popState();break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return"date";case 45:return 30;case 46:return"accDescription";case 47:return 36;case 48:return 38;case 49:return 39;case 50:return":";case 51:return 6;case 52:return"INVALID"}},"anonymous"),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}};return V}();b.lexer=F;function Y(){this.yy={}}return e(Y,"Parser"),Y.prototype=b,b.Parser=Y,new Y}();dr.parser=dr;var _a=dr;Dt.default.extend(_n.default);Dt.default.extend(Yn.default);Dt.default.extend(Fn.default);var Mn={friday:5,saturday:6},Et="",gr="",pr=void 0,Tr="",ne=[],ie=[],vr=new Map,xr=[],Ie=[],ae="",br="",In=["active","done","crit","milestone","vert"],wr=[],te="",fe=!1,Mr=!1,Dr="sunday",Ue="saturday",mr=0,Ya=e(function(){xr=[],Ie=[],ae="",wr=[],Ye=0,yr=void 0,Fe=void 0,kt=[],Et="",gr="",br="",pr=void 0,Tr="",ne=[],ie=[],fe=!1,Mr=!1,mr=0,vr=new Map,te="",C(),Dr="sunday",Ue="saturday"},"clear"),Fa=e(function(t){te=t},"setDiagramId"),Ia=e(function(t){gr=t},"setAxisFormat"),Ua=e(function(){return gr},"getAxisFormat"),La=e(function(t){pr=t},"setTickInterval"),Wa=e(function(){return pr},"getTickInterval"),Ea=e(function(t){Tr=t},"setTodayMarker"),Aa=e(function(){return Tr},"getTodayMarker"),Oa=e(function(t){Et=t},"setDateFormat"),$a=e(function(){fe=!0},"enableInclusiveEndDates"),Ha=e(function(){return fe},"endDatesAreInclusive"),Na=e(function(){Mr=!0},"enableTopAxis"),Pa=e(function(){return Mr},"topAxisEnabled"),Va=e(function(t){br=t},"setDisplayMode"),za=e(function(){return br},"getDisplayMode"),Ra=e(function(){return Et},"getDateFormat"),Un=e((t,n)=>{let i=n.toLowerCase().split(/[\s,]+/).filter((a)=>a!=="");return[...new Set([...t,...i])]},"mergeTokens"),Ba=e(function(t){ne=Un(ne,t)},"setIncludes"),Za=e(function(){return ne},"getIncludes"),ja=e(function(t){ie=Un(ie,t)},"setExcludes"),Xa=e(function(){return ie},"getExcludes"),Ga=e(function(){return vr},"getLinks"),qa=e(function(t){ae=t,xr.push(t)},"addSection"),Qa=e(function(){return xr},"getSections"),Ja=e(function(){let t=Dn(),n=10,i=0;while(!t&&i<n)t=Dn(),i++;return Ie=kt,Ie},"getTasks"),Ln=e(function(t,n,i,a){let o=t.format(n.trim()),c=t.format("YYYY-MM-DD");if(a.includes(o)||a.includes(c))return!1;if(i.includes("weekends")&&(t.isoWeekday()===Mn[Ue]||t.isoWeekday()===Mn[Ue]+1))return!0;if(i.includes(t.format("dddd").toLowerCase()))return!0;return i.includes(o)||i.includes(c)},"isInvalidDate"),Ka=e(function(t){Dr=t},"setWeekday"),ts=e(function(){return Dr},"getWeekday"),es=e(function(t){Ue=t},"setWeekend"),Wn=e(function(t,n,i,a){if(!i.length||t.manualEndTime)return;let o;if(t.startTime instanceof Date)o=Dt.default(t.startTime);else o=Dt.default(t.startTime,n,!0);o=o.add(1,"d");let c;if(t.endTime instanceof Date)c=Dt.default(t.endTime);else c=Dt.default(t.endTime,n,!0);let[l,M]=rs(o,c,n,i,a);t.endTime=l.toDate(),t.renderEndTime=M},"checkTaskDates"),rs=e(function(t,n,i,a,o){let c=!1,l=null,M=n.add(1e4,"d");while(t<=n){if(!c)l=n.toDate();if(c=Ln(t,i,a,o),c){if(n=n.add(1,"d"),n>M)throw Error("Failed to find a valid date that was not excluded by `excludes` after 10,000 iterations.")}t=t.add(1,"d")}return[n,l]},"fixTaskDates"),$n=e(function(t,n){r.warn(`Gantt: the "${t}" statement references unknown task id(s): ${n.join(", ")}. Make sure the referenced tasks exist and declare an id. Milestones need both an id and a duration, e.g. "Milestone :milestone, m1, 2023-01-01, 0d".`)},"warnAboutUnknownTaskIds"),hr=e(function(t,n,i){if(i=i.trim(),e((M)=>{let D=M.trim();return D==="x"||D==="X"},"isTimestampFormat")(n)&&/^\d+$/.test(i))return new Date(Number(i));let c=/^after\s+(?<ids>[\d\w- ]+)/.exec(i);if(c!==null){let M=null,D=[],R=c.groups.ids.split(" ").filter((G)=>G!=="");for(let G of R){let O=Gt(G);if(O===void 0){D.push(G);continue}if(!M||O.endTime>M.endTime)M=O}if(D.length>0)$n("after",D);if(M)return M.endTime;let W=new Date;return W.setHours(0,0,0,0),W}let l=Dt.default(i,n.trim(),!0);if(l.isValid())return l.toDate();else{r.debug("Invalid date:"+i),r.debug("With date format:"+n.trim());let M=new Date(i);if(M===void 0||isNaN(M.getTime())||M.getFullYear()<-1e4||M.getFullYear()>1e4)throw Error("Invalid date:"+i);return M}},"getStartDate"),Hn=e(function(t){let n=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());if(n!==null)return[Number.parseFloat(n[1]),n[2]];return[NaN,"ms"]},"parseDuration"),Nn=e(function(t,n,i,a=!1){i=i.trim();let c=/^until\s+(?<ids>[\d\w- ]+)/.exec(i);if(c!==null){let W=null,G=[],O=c.groups.ids.split(" ").filter((U)=>U!=="");for(let U of O){let Z=Gt(U);if(Z===void 0){G.push(U);continue}if(!W||Z.startTime<W.startTime)W=Z}if(G.length>0)$n("until",G);if(W)return W.startTime;let z=new Date;return z.setHours(0,0,0,0),z}let l=Dt.default(i,n.trim(),!0);if(l.isValid()){if(a)l=l.add(1,"d");return l.toDate()}let M=Dt.default(t),[D,R]=Hn(i);if(Number.isNaN(D))r.warn(`Gantt: "${i}" is neither a valid date for the "${n.trim()}" date format nor a valid duration (e.g. "3d"), so it is ignored and the task gets a zero duration. Milestones need a duration too, e.g. "Milestone :milestone, m1, 2023-01-01, 0d".`);else{let W=M.add(D,R);if(W.isValid())M=W}return M.toDate()},"getEndDate"),Ye=0,re=e(function(t){if(t===void 0)return Ye=Ye+1,"task"+Ye;return t},"parseId"),ns=e(function(t,n){let i;if(n.substr(0,1)===":")i=n.substr(1,n.length);else i=n;let a=i.split(","),o={};Cr(a,o,In);for(let l=0;l<a.length;l++)a[l]=a[l].trim();let c="";switch(a.length){case 1:o.id=re(),o.startTime=t.endTime,c=a[0];break;case 2:o.id=re(),o.startTime=hr(void 0,Et,a[0]),c=a[1];break;case 3:o.id=re(a[0]),o.startTime=hr(void 0,Et,a[1]),c=a[2];break;default:}if(c)o.endTime=Nn(o.startTime,Et,c,fe),o.manualEndTime=Dt.default(c,"YYYY-MM-DD",!0).isValid(),Wn(o,Et,ie,ne);return o},"compileData"),is=e(function(t,n){let i;if(n.substr(0,1)===":")i=n.substr(1,n.length);else i=n;let a=i.split(","),o={};Cr(a,o,In);for(let c=0;c<a.length;c++)a[c]=a[c].trim();switch(a.length){case 1:o.id=re(),o.startTime={type:"prevTaskEnd",id:t},o.endTime={data:a[0]};break;case 2:o.id=re(),o.startTime={type:"getStartDate",startData:a[0]},o.endTime={data:a[1]};break;case 3:o.id=re(a[0]),o.startTime={type:"getStartDate",startData:a[1]},o.endTime={data:a[2]};break;default:}return o},"parseData"),yr,Fe,kt=[],Pn={},as=e(function(t,n){let i={section:ae,type:ae,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:n},task:t,classes:[]},a=is(Fe,n);if(i.raw.startTime=a.startTime,i.raw.endTime=a.endTime,i.id=a.id,i.prevTaskId=Fe,i.active=a.active,i.done=a.done,i.crit=a.crit,i.milestone=a.milestone,i.vert=a.vert,i.vert)i.order=-1;else i.order=mr,mr++;let o=kt.push(i);Fe=i.id,Pn[i.id]=o-1},"addTask"),Gt=e(function(t){let n=Pn[t];return kt[n]},"findTaskById"),ss=e(function(t,n){let i={section:ae,type:ae,description:t,task:t,classes:[]},a=ns(yr,n);i.startTime=a.startTime,i.endTime=a.endTime,i.id=a.id,i.active=a.active,i.done=a.done,i.crit=a.crit,i.milestone=a.milestone,i.vert=a.vert,yr=i,Ie.push(i)},"addTaskOrg"),Dn=e(function(){let t=e(function(i){let a=kt[i],o="";switch(kt[i].raw.startTime.type){case"prevTaskEnd":{let c=Gt(a.prevTaskId);a.startTime=c.endTime;break}case"getStartDate":if(o=hr(void 0,Et,kt[i].raw.startTime.startData),o)kt[i].startTime=o;break}if(kt[i].startTime){if(kt[i].endTime=Nn(kt[i].startTime,Et,kt[i].raw.endTime.data,fe),kt[i].endTime)kt[i].processed=!0,kt[i].manualEndTime=Dt.default(kt[i].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),Wn(kt[i],Et,ie,ne)}return kt[i].processed},"compileTask"),n=!0;for(let[i,a]of kt.entries())t(i),n=n&&a.processed;return n},"compileTasks"),os=e(function(t,n){let i=n;if(s().securityLevel!=="loose")i=Sn.sanitizeUrl(n);t.split(",").forEach(function(a){if(Gt(a)!==void 0)zn(a,()=>{window.open(i,"_self")}),vr.set(a,i)}),Vn(t,"clickable")},"setLink"),Vn=e(function(t,n){t.split(",").forEach(function(i){let a=Gt(i);if(a!==void 0)a.classes.push(n)})},"setClass"),cs=e(function(t,n,i){if(s().securityLevel!=="loose")return;if(n===void 0)return;let a=[];if(typeof i==="string"){a=i.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let c=0;c<a.length;c++){let l=a[c].trim();if(l.startsWith('"')&&l.endsWith('"'))l=l.substr(1,l.length-2);a[c]=l}}if(a.length===0)a.push(t);if(Gt(t)!==void 0)zn(t,()=>{N.runFunc(n,...a)})},"setClickFun"),zn=e(function(t,n){wr.push(function(){let i=te?`${te}-${t}`:t,a=document.querySelector(`[id="${i}"]`);if(a!==null)a.addEventListener("click",function(){n()})},function(){let i=te?`${te}-${t}`:t,a=document.querySelector(`[id="${i}-text"]`);if(a!==null)a.addEventListener("click",function(){n()})})},"pushFun"),us=e(function(t,n,i){t.split(",").forEach(function(a){cs(a,n,i)}),Vn(t,"clickable")},"setClickEvent"),ls=e(function(t){wr.forEach(function(n){n(t)})},"bindFunctions"),fs={getConfig:e(()=>s().gantt,"getConfig"),clear:Ya,setDateFormat:Oa,getDateFormat:Ra,enableInclusiveEndDates:$a,endDatesAreInclusive:Ha,enableTopAxis:Na,topAxisEnabled:Pa,setAxisFormat:Ia,getAxisFormat:Ua,setTickInterval:La,getTickInterval:Wa,setTodayMarker:Ea,getTodayMarker:Aa,setAccTitle:S,getAccTitle:E,setDiagramTitle:I,getDiagramTitle:L,setDiagramId:Fa,setDisplayMode:Va,getDisplayMode:za,setAccDescription:T,getAccDescription:A,addSection:qa,getSections:Qa,getTasks:Ja,addTask:as,findTaskById:Gt,addTaskOrg:ss,setIncludes:Ba,getIncludes:Za,setExcludes:ja,getExcludes:Xa,setClickEvent:us,setLink:os,getLinks:Ga,bindFunctions:ls,parseDuration:Hn,isInvalidDate:Ln,setWeekday:Ka,getWeekday:ts,setWeekend:es};function Cr(t,n,i){let a=!0;while(a)a=!1,i.forEach(function(o){let c="^\\s*"+o+"\\s*$",l=new RegExp(c);if(t[0].match(l))n[o]=!0,t.shift(1),a=!0})}e(Cr,"getTaskTags");ee.default.extend(Rn.default);var ds=e(function(){r.debug("Something is calling, setConf, remove the call")},"setConf"),Cn={monday:zt,tuesday:be,wednesday:we,thursday:Wt,friday:Me,saturday:De,sunday:Yt},ms=e((t,n)=>{let i=[...t].map(()=>-1/0),a=[...t].sort((c,l)=>c.startTime-l.startTime||c.order-l.order),o=0;for(let c of a)for(let l=0;l<i.length;l++)if(c.startTime>=i[l]){if(i[l]=c.endTime,c.order=l+n,l>o)o=l;break}return o},"getMaxIntersections"),Pt,fr=1e4,hs=e(function(t,n,i,a){let o=s().gantt;a.db.setDiagramId(n);let c=s().securityLevel,l;if(c==="sandbox")l=p("#i"+n);let M=c==="sandbox"?p(l.nodes()[0].contentDocument.body):p("body"),D=c==="sandbox"?l.nodes()[0].contentDocument:document,R=D.getElementById(n);if(Pt=R.parentElement.offsetWidth,Pt===void 0)Pt=1200;if(o.useWidth!==void 0)Pt=o.useWidth;let W=a.db.getTasks(),G=W.filter((b)=>!b.vert),O=[];for(let b of G)O.push(b.type);O=nt(O);let z={},U=2*o.topPadding;if(a.db.getDisplayMode()==="compact"||o.displayMode==="compact"){let b={};for(let Y of G)if(b[Y.section]===void 0)b[Y.section]=[Y];else b[Y.section].push(Y);let F=0;for(let Y of Object.keys(b)){let V=ms(b[Y],F)+1;F+=V,U+=V*(o.barHeight+o.barGap),z[Y]=V}}else{U+=G.length*(o.barHeight+o.barGap);for(let b of O)z[b]=G.filter((F)=>F.type===b).length}R.setAttribute("viewBox","0 0 "+Pt+" "+U);let Z=M.select(`[id="${n}"]`),H=er().domain([mn(W,function(b){return b.startTime}),On(W,function(b){return b.endTime})]).rangeRound([0,Pt-o.leftPadding-o.rightPadding]);function tt(b,F){let Y=b.startTime,V=F.startTime,d=0;if(Y>V)d=1;else if(Y<V)d=-1;return d}e(tt,"taskCompare"),W.sort(tt),ft(W,Pt,U),B(Z,U,Pt,o.useMaxWidth),Z.append("text").text(a.db.getDiagramTitle()).attr("x",Pt/2).attr("y",o.titleTopMargin).attr("class","titleText");function ft(b,F,Y){let V=o.barHeight,d=V+o.barGap,{topPadding:w,leftPadding:x}=o,v=xt().domain([0,O.length]).range(["#00B9FA","#F95002"]).interpolate(zr);j(d,w,x,F,Y,b,a.db.getExcludes(),a.db.getIncludes()),f(x,w,F,Y),at(b,d,w,x,V,v,F,Y),P(d,w,x,V,v),rt(x,w,F,Y)}e(ft,"makeGantt");function at(b,F,Y,V,d,w,x){b.sort((m,q)=>m.vert===q.vert?0:m.vert?1:-1);let v=b.filter((m)=>!m.vert),u=[...new Set(v.map((m)=>m.order))].map((m)=>v.find((q)=>q.order===m));Z.append("g").selectAll("rect").data(u).enter().append("rect").attr("x",0).attr("y",function(m,q){return q=m.order,q*F+Y-2}).attr("width",function(){return x-o.rightPadding/2}).attr("height",F).attr("class",function(m){for(let[q,K]of O.entries())if(m.type===K)return"section section"+q%o.numberSectionStyles;return"section section0"}).enter();let J=Z.append("g").selectAll("rect").data(b).enter(),h=a.db.getLinks();if(J.append("rect").attr("id",function(m){return n+"-"+m.id}).attr("rx",3).attr("ry",3).attr("x",function(m){if(m.milestone)return H(m.startTime)+V+0.5*(H(m.endTime)-H(m.startTime))-0.5*d;return H(m.startTime)+V}).attr("y",function(m,q){if(q=m.order,m.vert)return o.gridLineStartPadding;return q*F+Y}).attr("width",function(m){if(m.milestone)return d;if(m.vert)return 0.08*d;return H(m.renderEndTime||m.endTime)-H(m.startTime)}).attr("height",function(m){if(m.vert)return v.length*(o.barHeight+o.barGap)+o.barHeight*2;return d}).attr("transform-origin",function(m,q){return q=m.order,(H(m.startTime)+V+0.5*(H(m.endTime)-H(m.startTime))).toString()+"px "+(q*F+Y+0.5*d).toString()+"px"}).attr("class",function(m){let K="";if(m.classes.length>0)K=m.classes.join(" ");let ut=0;for(let[it,k]of O.entries())if(m.type===k)ut=it%o.numberSectionStyles;let lt="";if(m.active)if(m.crit)lt+=" activeCrit";else lt=" active";else if(m.done)if(m.crit)lt=" doneCrit";else lt=" done";else if(m.crit)lt+=" crit";if(lt.length===0)lt=" task";if(m.milestone)lt=" milestone "+lt;if(m.vert)lt=" vert "+lt;return lt+=ut,lt+=" "+K,"task"+lt}),J.append("text").attr("id",function(m){return n+"-"+m.id+"-text"}).text(function(m){return m.task}).attr("font-size",o.fontSize).attr("x",function(m){let q=H(m.startTime),K=H(m.renderEndTime||m.endTime);if(m.milestone)q+=0.5*(H(m.endTime)-H(m.startTime))-0.5*d,K=q+d;if(m.vert)return H(m.startTime)+V;let ut=this.getBBox().width;if(ut>K-q)if(K+ut+1.5*o.leftPadding>x)return q+V-5;else return K+V+5;else return(K-q)/2+q+V}).attr("y",function(m,q){if(m.vert)return o.gridLineStartPadding+v.length*(o.barHeight+o.barGap)+60;return q=m.order,q*F+o.barHeight/2+(o.fontSize/2-2)+Y}).attr("text-height",d).attr("class",function(m){let q=H(m.startTime),K=H(m.endTime);if(m.milestone)K=q+d;let ut=this.getBBox().width,lt="";if(m.classes.length>0)lt=m.classes.join(" ");let it=0;for(let[X,et]of O.entries())if(m.type===et)it=X%o.numberSectionStyles;let k="";if(m.active)if(m.crit)k="activeCritText"+it;else k="activeText"+it;if(m.done)if(m.crit)k=k+" doneCritText"+it;else k=k+" doneText"+it;else if(m.crit)k=k+" critText"+it;if(m.milestone)k+=" milestoneText";if(m.vert)k+=" vertText";if(ut>K-q)if(K+ut+1.5*o.leftPadding>x)return lt+" taskTextOutsideLeft taskTextOutside"+it+" "+k;else return lt+" taskTextOutsideRight taskTextOutside"+it+" "+k+" width-"+ut;else return lt+" taskText taskText"+it+" "+k+" width-"+ut}),s().securityLevel==="sandbox"){let m;m=p("#i"+n);let q=m.nodes()[0].contentDocument;J.filter(function(K){return h.has(K.id)}).each(function(K){var ut=q.querySelector("#"+CSS.escape(n+"-"+K.id)),lt=q.querySelector("#"+CSS.escape(n+"-"+K.id+"-text"));let it=ut.parentNode;var k=q.createElement("a");k.setAttribute("xlink:href",h.get(K.id)),k.setAttribute("target","_top"),it.appendChild(k),k.appendChild(ut),k.appendChild(lt)})}}e(at,"drawRects");function j(b,F,Y,V,d,w,x,v){if(x.length===0&&v.length===0)return;let Q,u;for(let{startTime:K,endTime:ut}of w){if(Q===void 0||K<Q)Q=K;if(u===void 0||ut>u)u=ut}if(!Q||!u)return;if(ee.default(u).diff(ee.default(Q),"year")>5){r.warn("The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.");return}let J=a.db.getDateFormat(),h=[],mt=null,m=ee.default(Q);while(m.valueOf()<=u){if(a.db.isInvalidDate(m,J,x,v))if(!mt)mt={start:m,end:m};else mt.end=m;else if(mt)h.push(mt),mt=null;m=m.add(1,"d")}Z.append("g").selectAll("rect").data(h).enter().append("rect").attr("id",(K)=>n+"-exclude-"+K.start.format("YYYY-MM-DD")).attr("x",(K)=>H(K.start.startOf("day"))+Y).attr("y",o.gridLineStartPadding).attr("width",(K)=>H(K.end.endOf("day"))-H(K.start.startOf("day"))).attr("height",d-F-o.gridLineStartPadding).attr("transform-origin",function(K,ut){return(H(K.start)+Y+0.5*(H(K.end)-H(K.start))).toString()+"px "+(ut*b+0.5*d).toString()+"px"}).attr("class","exclude-range")}e(j,"drawExcludeDays");function _(b,F,Y,V){if(Y<=0||b>F)return 1/0;let d=F-b,w=ee.default.duration({[V??"day"]:Y}).asMilliseconds();if(w<=0)return 1/0;return Math.ceil(d/w)}e(_,"getEstimatedTickCount");function f(b,F,Y,V){let d=a.db.getDateFormat(),w=a.db.getAxisFormat(),x;if(w)x=w;else if(d==="D")x="%d";else x=o.axisFormat??"%Y-%m-%d";let v=He(H).tickSize(-V+F+o.gridLineStartPadding).tickFormat(Xt(x)),u=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(a.db.getTickInterval()||o.tickInterval);if(u!==null){let J=parseInt(u[1],10);if(isNaN(J)||J<=0)r.warn(`Invalid tick interval value: "${u[1]}". Skipping custom tick interval.`);else{let h=u[2],mt=a.db.getWeekday()||o.weekday,m=H.domain(),q=m[0],K=m[1],ut=_(q,K,J,h);if(ut>fr)r.warn(`The tick interval "${J}${h}" would generate ${ut} ticks, which exceeds the maximum allowed (${fr}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(h){case"millisecond":v.ticks(Ut.every(J));break;case"second":v.ticks(bt.every(J));break;case"minute":v.ticks($t.every(J));break;case"hour":v.ticks(Ht.every(J));break;case"day":v.ticks(_t.every(J));break;case"week":v.ticks(Cn[mt].every(J));break;case"month":v.ticks(Nt.every(J));break}}}if(Z.append("g").attr("class","grid").attr("transform","translate("+b+", "+(V-50)+")").call(v).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),a.db.topAxisEnabled()||o.topAxis){let J=$e(H).tickSize(-V+F+o.gridLineStartPadding).tickFormat(Xt(x));if(u!==null){let h=parseInt(u[1],10);if(isNaN(h)||h<=0)r.warn(`Invalid tick interval value: "${u[1]}". Skipping custom tick interval.`);else{let mt=u[2],m=a.db.getWeekday()||o.weekday,q=H.domain(),K=q[0],ut=q[1];if(_(K,ut,h,mt)<=fr)switch(mt){case"millisecond":J.ticks(Ut.every(h));break;case"second":J.ticks(bt.every(h));break;case"minute":J.ticks($t.every(h));break;case"hour":J.ticks(Ht.every(h));break;case"day":J.ticks(_t.every(h));break;case"week":J.ticks(Cn[m].every(h));break;case"month":J.ticks(Nt.every(h));break}}}Z.append("g").attr("class","grid").attr("transform","translate("+b+", "+F+")").call(J).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}e(f,"makeGrid");function P(b,F){let Y=0,V=Object.keys(z).map((d)=>[d,z[d]]);Z.append("g").selectAll("text").data(V).enter().append(function(d){let w=d[0].split(y.lineBreakRegex),x=-(w.length-1)/2,v=D.createElementNS("http://www.w3.org/2000/svg","text");v.setAttribute("dy",x+"em");for(let[Q,u]of w.entries()){let J=D.createElementNS("http://www.w3.org/2000/svg","tspan");if(J.setAttribute("alignment-baseline","central"),J.setAttribute("x","10"),Q>0)J.setAttribute("dy","1em");J.textContent=u,v.appendChild(J)}return v}).attr("x",10).attr("y",function(d,w){if(w>0)for(let x=0;x<w;x++)return Y+=V[w-1][1],d[1]*b/2+Y*b+F;else return d[1]*b/2+F}).attr("font-size",o.sectionFontSize).attr("class",function(d){for(let[w,x]of O.entries())if(d[0]===x)return"sectionTitle sectionTitle"+w%o.numberSectionStyles;return"sectionTitle"})}e(P,"vertLabels");function rt(b,F,Y,V){let d=a.db.getTodayMarker();if(d==="off")return;let w=Z.append("g").attr("class","today"),x=new Date,v=w.append("line");if(v.attr("x1",H(x)+b).attr("x2",H(x)+b).attr("y1",o.titleTopMargin).attr("y2",V-o.titleTopMargin).attr("class","today"),d!=="")v.attr("style",d.replace(/,/g,";"))}e(rt,"drawToday");function nt(b){let F={},Y=[];for(let V=0,d=b.length;V<d;++V)if(!Object.prototype.hasOwnProperty.call(F,b[V]))F[b[V]]=!0,Y.push(b[V]);return Y}e(nt,"checkUnique")},"draw"),ys={setConf:ds,draw:hs},gs=e((t)=>`
7
- .mermaid-main-font {
8
- font-family: ${t.fontFamily};
9
- }
10
-
11
- .exclude-range {
12
- fill: ${t.excludeBkgColor};
13
- }
14
-
15
- .section {
16
- stroke: none;
17
- opacity: 0.2;
18
- }
19
-
20
- .section0 {
21
- fill: ${t.sectionBkgColor};
22
- }
23
-
24
- .section2 {
25
- fill: ${t.sectionBkgColor2};
26
- }
27
-
28
- .section1,
29
- .section3 {
30
- fill: ${t.altSectionBkgColor};
31
- opacity: 0.2;
32
- }
33
-
34
- .sectionTitle0 {
35
- fill: ${t.titleColor};
36
- }
37
-
38
- .sectionTitle1 {
39
- fill: ${t.titleColor};
40
- }
41
-
42
- .sectionTitle2 {
43
- fill: ${t.titleColor};
44
- }
45
-
46
- .sectionTitle3 {
47
- fill: ${t.titleColor};
48
- }
49
-
50
- .sectionTitle {
51
- text-anchor: start;
52
- font-family: ${t.fontFamily};
53
- }
54
-
55
-
56
- /* Grid and axis */
57
-
58
- .grid .tick {
59
- stroke: ${t.gridColor};
60
- opacity: 0.8;
61
- shape-rendering: crispEdges;
62
- }
63
-
64
- .grid .tick text {
65
- font-family: ${t.fontFamily};
66
- fill: ${t.textColor};
67
- }
68
-
69
- .grid path {
70
- stroke-width: 0;
71
- }
72
-
73
-
74
- /* Today line */
75
-
76
- .today {
77
- fill: none;
78
- stroke: ${t.todayLineColor};
79
- stroke-width: 2px;
80
- }
81
-
82
-
83
- /* Task styling */
84
-
85
- /* Default task */
86
-
87
- .task {
88
- stroke-width: 2;
89
- }
90
-
91
- .taskText {
92
- text-anchor: middle;
93
- font-family: ${t.fontFamily};
94
- }
95
-
96
- .taskTextOutsideRight {
97
- fill: ${t.taskTextDarkColor};
98
- text-anchor: start;
99
- font-family: ${t.fontFamily};
100
- }
101
-
102
- .taskTextOutsideLeft {
103
- fill: ${t.taskTextDarkColor};
104
- text-anchor: end;
105
- }
106
-
107
-
108
- /* Special case clickable */
109
-
110
- .task.clickable {
111
- cursor: pointer;
112
- }
113
-
114
- .taskText.clickable {
115
- cursor: pointer;
116
- fill: ${t.taskTextClickableColor} !important;
117
- font-weight: bold;
118
- }
119
-
120
- .taskTextOutsideLeft.clickable {
121
- cursor: pointer;
122
- fill: ${t.taskTextClickableColor} !important;
123
- font-weight: bold;
124
- }
125
-
126
- .taskTextOutsideRight.clickable {
127
- cursor: pointer;
128
- fill: ${t.taskTextClickableColor} !important;
129
- font-weight: bold;
130
- }
131
-
132
-
133
- /* Specific task settings for the sections*/
134
-
135
- .taskText0,
136
- .taskText1,
137
- .taskText2,
138
- .taskText3 {
139
- fill: ${t.taskTextColor};
140
- }
141
-
142
- .task0,
143
- .task1,
144
- .task2,
145
- .task3 {
146
- fill: ${t.taskBkgColor};
147
- stroke: ${t.taskBorderColor};
148
- }
149
-
150
- .taskTextOutside0,
151
- .taskTextOutside2
152
- {
153
- fill: ${t.taskTextOutsideColor};
154
- }
155
-
156
- .taskTextOutside1,
157
- .taskTextOutside3 {
158
- fill: ${t.taskTextOutsideColor};
159
- }
160
-
161
-
162
- /* Active task */
163
-
164
- .active0,
165
- .active1,
166
- .active2,
167
- .active3 {
168
- fill: ${t.activeTaskBkgColor};
169
- stroke: ${t.activeTaskBorderColor};
170
- }
171
-
172
- .activeText0,
173
- .activeText1,
174
- .activeText2,
175
- .activeText3 {
176
- fill: ${t.taskTextDarkColor} !important;
177
- }
178
-
179
-
180
- /* Completed task */
181
-
182
- .done0,
183
- .done1,
184
- .done2,
185
- .done3 {
186
- stroke: ${t.doneTaskBorderColor};
187
- fill: ${t.doneTaskBkgColor};
188
- stroke-width: 2;
189
- }
190
-
191
- .doneText0,
192
- .doneText1,
193
- .doneText2,
194
- .doneText3 {
195
- fill: ${t.taskTextDarkColor} !important;
196
- }
197
-
198
- /* Done task text displayed outside the bar sits against the diagram background,
199
- not against the done-task bar, so it must use the outside/contrast color. */
200
- .doneText0.taskTextOutsideLeft,
201
- .doneText0.taskTextOutsideRight,
202
- .doneText1.taskTextOutsideLeft,
203
- .doneText1.taskTextOutsideRight,
204
- .doneText2.taskTextOutsideLeft,
205
- .doneText2.taskTextOutsideRight,
206
- .doneText3.taskTextOutsideLeft,
207
- .doneText3.taskTextOutsideRight {
208
- fill: ${t.taskTextOutsideColor} !important;
209
- }
210
-
211
-
212
- /* Tasks on the critical line */
213
-
214
- .crit0,
215
- .crit1,
216
- .crit2,
217
- .crit3 {
218
- stroke: ${t.critBorderColor};
219
- fill: ${t.critBkgColor};
220
- stroke-width: 2;
221
- }
222
-
223
- .activeCrit0,
224
- .activeCrit1,
225
- .activeCrit2,
226
- .activeCrit3 {
227
- stroke: ${t.critBorderColor};
228
- fill: ${t.activeTaskBkgColor};
229
- stroke-width: 2;
230
- }
231
-
232
- .doneCrit0,
233
- .doneCrit1,
234
- .doneCrit2,
235
- .doneCrit3 {
236
- stroke: ${t.critBorderColor};
237
- fill: ${t.doneTaskBkgColor};
238
- stroke-width: 2;
239
- cursor: pointer;
240
- shape-rendering: crispEdges;
241
- }
242
-
243
- .milestone {
244
- transform: rotate(45deg) scale(0.8,0.8);
245
- }
246
-
247
- .milestoneText {
248
- font-style: italic;
249
- }
250
- .doneCritText0,
251
- .doneCritText1,
252
- .doneCritText2,
253
- .doneCritText3 {
254
- fill: ${t.taskTextDarkColor} !important;
255
- }
256
-
257
- /* Done-crit task text outside the bar — same reasoning as doneText above. */
258
- .doneCritText0.taskTextOutsideLeft,
259
- .doneCritText0.taskTextOutsideRight,
260
- .doneCritText1.taskTextOutsideLeft,
261
- .doneCritText1.taskTextOutsideRight,
262
- .doneCritText2.taskTextOutsideLeft,
263
- .doneCritText2.taskTextOutsideRight,
264
- .doneCritText3.taskTextOutsideLeft,
265
- .doneCritText3.taskTextOutsideRight {
266
- fill: ${t.taskTextOutsideColor} !important;
267
- }
268
-
269
- .vert {
270
- stroke: ${t.vertLineColor};
271
- }
272
-
273
- .vertText {
274
- font-size: 15px;
275
- text-anchor: middle;
276
- fill: ${t.vertLineColor} !important;
277
- }
278
-
279
- .activeCritText0,
280
- .activeCritText1,
281
- .activeCritText2,
282
- .activeCritText3 {
283
- fill: ${t.taskTextDarkColor} !important;
284
- }
285
-
286
- .titleText {
287
- text-anchor: middle;
288
- font-size: 18px;
289
- fill: ${t.titleColor||t.textColor};
290
- font-family: ${t.fontFamily};
291
- }
292
- `,"getStyles"),ks=gs,Bo={parser:_a,db:fs,renderer:ys,styles:ks};export{Bo as diagram};
@@ -1 +0,0 @@
1
- import{mi}from"./chunk-zbj1trar.js";export{mi as default};
@@ -1 +0,0 @@
1
- import{wi}from"./chunk-n8gfjj9a.js";export{wi as createPacketServices};
@@ -1,2 +0,0 @@
1
- import{J,Oi,Ve,Ln,co,La,Ft,zn,Be,Tr,Vr,Un,uo,$i,jn}from"./chunk-vymqrpm3.js";function k(l){return l.innerRadius}function b(l){return l.outerRadius}function _(l){return l.startAngle}function nn(l){return l.endAngle}function en(l){return l&&l.padAngle}function rn(l,d,q,P,x,h,S,r){var D=q-l,a=P-d,n=S-x,y=r-h,u=y*D-n*a;if(u*u<Be)return;return u=(n*(d-h)-y*(l-x))/u,[l+u*D,d+u*a]}function M(l,d,q,P,x,h,S){var r=l-q,D=d-P,a=(S?h:-h)/zn(r*r+D*D),n=a*D,y=-a*r,u=l+n,s=d+y,t=q+n,f=P+y,j=(u+t)/2,o=(s+f)/2,g=t-u,c=f-s,v=g*g+c*c,A=x-h,R=u*f-t*s,E=(c<0?-1:1)*zn(co(0,A*A*v-R*R)),I=(R*c-g*E)/v,O=(-R*g-c*E)/v,T=(R*c+g*E)/v,m=(-R*g+c*E)/v,p=I-j,e=O-o,i=T-j,z=m-o;if(p*p+e*e>i*i+z*z)I=T,O=m;return{cx:I,cy:O,x01:-n,y01:-y,x11:I*(x/A-1),y11:O*(x/A-1)}}function bt(){var l=k,d=b,q=J(0),P=null,x=_,h=nn,S=en,r=null,D=jn(a);function a(){var n,y,u=+l.apply(this,arguments),s=+d.apply(this,arguments),t=x.apply(this,arguments)-Vr,f=h.apply(this,arguments)-Vr,j=Oi(f-t),o=f>t;if(!r)r=n=D();if(s<u)y=s,s=u,u=y;if(!(s>Be))r.moveTo(0,0);else if(j>Un-Be){if(r.moveTo(s*Ln(t),s*Ft(t)),r.arc(0,0,s,t,f,!o),u>Be)r.moveTo(u*Ln(f),u*Ft(f)),r.arc(0,0,u,f,t,o)}else{var g=t,c=f,v=t,A=f,R=j,E=j,I=S.apply(this,arguments)/2,O=I>Be&&(P?+P.apply(this,arguments):zn(u*u+s*s)),T=La(Oi(s-u)/2,+q.apply(this,arguments)),m=T,p=T,e,i;if(O>Be){var z=$i(O/u*Ft(I)),F=$i(O/s*Ft(I));if((R-=z*2)>Be)z*=o?1:-1,v+=z,A-=z;else R=0,v=A=(t+f)/2;if((E-=F*2)>Be)F*=o?1:-1,g+=F,c-=F;else E=0,g=c=(t+f)/2}var B=s*Ln(g),C=s*Ft(g),G=u*Ln(A),H=u*Ft(A);if(T>Be){var K=s*Ln(c),L=s*Ft(c),N=u*Ln(v),Q=u*Ft(v),w;if(j<Tr)if(w=rn(B,C,N,Q,K,L,G,H)){var U=B-w[0],V=C-w[1],W=K-w[0],X=L-w[1],Y=1/Ft(uo((U*W+V*X)/(zn(U*U+V*V)*zn(W*W+X*X)))/2),Z=zn(w[0]*w[0]+w[1]*w[1]);m=La(T,(u-Z)/(Y-1)),p=La(T,(s-Z)/(Y+1))}else m=p=0}if(!(E>Be))r.moveTo(B,C);else if(p>Be)if(e=M(N,Q,B,C,s,p,o),i=M(K,L,G,H,s,p,o),r.moveTo(e.cx+e.x01,e.cy+e.y01),p<T)r.arc(e.cx,e.cy,p,Ve(e.y01,e.x01),Ve(i.y01,i.x01),!o);else r.arc(e.cx,e.cy,p,Ve(e.y01,e.x01),Ve(e.y11,e.x11),!o),r.arc(0,0,s,Ve(e.cy+e.y11,e.cx+e.x11),Ve(i.cy+i.y11,i.cx+i.x11),!o),r.arc(i.cx,i.cy,p,Ve(i.y11,i.x11),Ve(i.y01,i.x01),!o);else r.moveTo(B,C),r.arc(0,0,s,g,c,!o);if(!(u>Be)||!(R>Be))r.lineTo(G,H);else if(m>Be)if(e=M(G,H,K,L,u,-m,o),i=M(B,C,N,Q,u,-m,o),r.lineTo(e.cx+e.x01,e.cy+e.y01),m<T)r.arc(e.cx,e.cy,m,Ve(e.y01,e.x01),Ve(i.y01,i.x01),!o);else r.arc(e.cx,e.cy,m,Ve(e.y01,e.x01),Ve(e.y11,e.x11),!o),r.arc(0,0,u,Ve(e.cy+e.y11,e.cx+e.x11),Ve(i.cy+i.y11,i.cx+i.x11),o),r.arc(i.cx,i.cy,m,Ve(i.y11,i.x11),Ve(i.y01,i.x01),!o);else r.arc(0,0,u,A,v,o)}if(r.closePath(),n)return r=null,n+""||null}return a.centroid=function(){var n=(+l.apply(this,arguments)+ +d.apply(this,arguments))/2,y=(+x.apply(this,arguments)+ +h.apply(this,arguments))/2-Tr/2;return[Ln(y)*n,Ft(y)*n]},a.innerRadius=function(n){return arguments.length?(l=typeof n==="function"?n:J(+n),a):l},a.outerRadius=function(n){return arguments.length?(d=typeof n==="function"?n:J(+n),a):d},a.cornerRadius=function(n){return arguments.length?(q=typeof n==="function"?n:J(+n),a):q},a.padRadius=function(n){return arguments.length?(P=n==null?null:typeof n==="function"?n:J(+n),a):P},a.startAngle=function(n){return arguments.length?(x=typeof n==="function"?n:J(+n),a):x},a.endAngle=function(n){return arguments.length?(h=typeof n==="function"?n:J(+n),a):h},a.padAngle=function(n){return arguments.length?(S=typeof n==="function"?n:J(+n),a):S},a.context=function(n){return arguments.length?(r=n==null?null:n,a):r},a}
2
- export{bt};
@@ -1,2 +0,0 @@
1
- import{e}from"./chunk-vymqrpm3.js";function W(c,i){if(c.accDescr)i.setAccDescription?.(c.accDescr);if(c.accTitle)i.setAccTitle?.(c.accTitle);if(c.title)i.setDiagramTitle?.(c.title)}e(W,"populateCommonDb");
2
- export{W};
@@ -1 +0,0 @@
1
- import{h,o,i,a,v,t,n,_,l,Z,gt,yt,un,ve,Re,te,de,jt,ot,re,tn,oe}from"./chunk-fhnypcrm.js";var Se=[["path",{d:"M2.586 17.414A2 2 0 0 0 2 18.828V21a1 1 0 0 0 1 1h3a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h1a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1h.172a2 2 0 0 0 1.414-.586l.814-.814a6.5 6.5 0 1 0-4-4z",key:"1s6t7t"}],["circle",{cx:"16.5",cy:"7.5",r:".5",fill:"currentColor",key:"w0ekpg"}]],fe=l("key-round",Se);function ge(e){let d=[],g="",y,N=!1;for(let u=0;u<e.length;u++){let c=e[u];if(y)if(c===y)y=void 0;else if(c==="\\"&&y==='"'&&u+1<e.length)g+=e[++u];else g+=c;else if(c==='"'||c==="'")y=c,N=!0;else if(c==="\\"&&u+1<e.length)g+=e[++u],N=!0;else if(/\s/.test(c)){if(N||g)d.push(g);g="",N=!1}else g+=c,N=!0}if(N||g)d.push(g);return d}function le(e){return e.map((d)=>d===""||/[\s"'\\]/.test(d)?`"${d.replace(/(["\\])/g,"\\$1")}"`:d).join(" ")}var xe="size-4 cursor-pointer rounded border-line text-accent accent-accent focus-visible:outline-2 focus-visible:outline-accent",je={connected:{label:"已连接",dot:"bg-success"},idle:{label:"待连接",dot:"bg-faint"},disabled:{label:"已停用",dot:"bg-faint"},failed:{label:"连接失败",dot:"bg-danger"},needs_auth:{label:"需要认证",dot:"bg-warning"}};function X(e){return e.type==="local"?le(e.command):e.url}function he({info:e,tools:d=!1}){let g=je[e.status.status];return n("span",{className:"inline-flex shrink-0 items-center gap-1.5 text-xs text-dim",children:[t("span",{"aria-hidden":!0,className:`size-1.5 shrink-0 rounded-full ${g.dot}`}),t("span",{className:d?void 0:"hidden @md/panel:inline",children:g.label}),d&&e.status.status==="connected"&&n("span",{className:"text-faint",children:["· ",e.toolCount," 个工具"]})]})}function Te(e){if(typeof e!=="object"||e===null||!("type"in e))return"any";let d=e.type;if(typeof d==="string")return d;if(Array.isArray(d))return d.filter((g)=>typeof g==="string").join(" | ")||"any";return"any"}function be(e){let{Button:d,CopyButton:g,Dialog:y,StatusChip:N,confirm:u,style:c,useTheme:k}=_();k();let{info:s,connection:I}=e,[m,q]=a(),[G,K]=a(),[S,j]=a(!1),W=s.status.status==="connected",z=s.status.status==="needs_auth",V=s.status.status==="failed",A=s.config.type==="remote"&&Boolean(s.config.oauth);o(()=>{function p(x){if(x&&x!==s.name)return;let J=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"";I.request(`/api/mcp/${encodeURIComponent(s.name)}/connect${J}`,{method:"POST"}).then((ee)=>e.onChanged(ee)).catch(()=>{})}function f(x){if(x.data?.type==="mcp-oauth-success")p(x.data.name)}function D(x){if(x.key==="basalt-mcp-oauth-event"&&x.newValue)try{let J=JSON.parse(x.newValue);p(J.name)}catch(J){}}window.addEventListener("message",f),window.addEventListener("storage",D);let R;if("BroadcastChannel"in window)R=new BroadcastChannel("basalt-mcp-oauth"),R.onmessage=(x)=>{if(x.data?.type==="mcp-oauth-success")p(x.data.name)};return()=>{window.removeEventListener("message",f),window.removeEventListener("storage",D),R?.close()}},[I,s.name,s.projectID,e]),o(()=>{if(s.status.status!=="connected")return;let p=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"";I.request(`/api/mcp/${encodeURIComponent(s.name)}/tools${p}`).then((f)=>{if(Array.isArray(f))q(f),K(void 0)}).catch((f)=>{K(f instanceof Error?f.message:"获取工具失败")})},[I,s.name,s.projectID,s.status.status]);async function O(p){j(!0);try{let f=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"",D=await I.request(`/api/mcp/${encodeURIComponent(s.name)}/${p}${f}`,{method:"POST"});e.onChanged(D)}catch{}finally{j(!1)}}async function U(){j(!0);try{let p=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"",f=s.status.status==="needs_auth"?s.status.authorizationUrl:void 0;if(!f)f=(await I.request(`/api/mcp/${encodeURIComponent(s.name)}/oauth/authorize${p}`,{method:"POST"})).authorizationUrl;if(f)window.open(f,"_blank","width=600,height=700")}catch(p){K(p instanceof Error?p.message:"获取授权链接失败")}finally{j(!1)}}async function Y(){j(!0);try{let p=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"",f=await I.request(`/api/mcp/${encodeURIComponent(s.name)}/oauth/clear${p}`,{method:"POST"});e.onChanged(f)}finally{j(!1)}}async function E(){if(!await u({title:`删除 ${s.name}?`,description:"删除后将断开连接并不再向会话提供其工具。",action:"删除",danger:!0}))return;j(!0);try{let f=s.projectID?`?projectID=${encodeURIComponent(s.projectID)}`:"";await I.request(`/api/mcp/${encodeURIComponent(s.name)}${f}`,{method:"DELETE"}),e.onChanged(),e.onClose()}finally{j(!1)}}let T=s.config,r=X(T),C="error"in s.status?s.status.error:void 0,M=m?.length??s.toolCount??0;return t(y,{open:!0,className:"bg-panel shadow-float",onOpenChange:(p)=>{if(!p&&!S)e.onClose()},title:n("div",{className:"flex flex-wrap items-center gap-3",children:[t("div",{className:"flex size-8 items-center justify-center rounded-[10px] border border-accent/20 bg-accent-soft text-accent",children:T.type==="local"?t(ot,{className:"size-4"}):t(ve,{className:"size-4"})}),t("span",{className:"font-serif text-lg font-semibold tracking-tight text-ink",children:s.name}),W?t(N,{tone:"success",pulse:!0,children:"已连接"}):z?t(N,{tone:"warning",pulse:!0,children:"需要授权"}):V?t(N,{tone:"danger",children:"连接失败"}):s.status.status==="disabled"?t(N,{tone:"neutral",children:"已停用"}):t(N,{tone:"neutral",children:"未连接"})]}),description:n("div",{className:"mt-2 flex min-w-0 flex-wrap items-center gap-1.5 text-xs",children:[n("span",{className:"flex min-w-0 max-w-full items-center gap-1 rounded-lg border border-line bg-raised/60 py-0.5 pr-1 pl-2.5 font-mono text-[11.5px] text-ink",children:[t("span",{className:"min-w-0 truncate",title:r,children:r}),t(g,{text:r,label:"复制地址",size:"icon-xs",className:"shrink-0 text-dim hover:text-ink"})]}),t("span",{className:"rounded-lg border border-line px-2 py-1 text-[11px] leading-none text-dim",children:T.type==="local"?"本地命令":"远程 HTTP"}),A&&n("span",{className:c("control.badgeAccent","gap-1 rounded-lg border border-accent/25 px-2 py-1"),children:[t(jt,{className:"size-3"}),"OAuth 2.0"]})]}),size:"lg",footer:n("div",{className:"flex w-full items-center justify-between gap-2 max-sm:flex-col",children:[n("div",{className:"flex items-center gap-1 max-sm:w-full",children:[A&&t(d,{type:"button",variant:"ghost",onClick:Y,disabled:S,title:"清除已保存的 OAuth 凭据",children:"清除凭据"}),t(d,{type:"button",variant:"danger-ghost",size:"icon-sm","aria-label":"删除服务器",onClick:E,disabled:S,title:"删除服务器",children:t(re,{className:"size-4"})})]}),n("div",{className:"flex items-center gap-2 max-sm:w-full max-sm:justify-end",children:[t(d,{type:"button",variant:"ghost",onClick:e.onEdit,disabled:S,children:"编辑配置"}),!z&&t(d,{type:"button",variant:"secondary",onClick:()=>O(W?"disconnect":"connect"),disabled:S,children:S?"处理中...":W?"断开连接":"立即连接"}),t(d,{type:"button",variant:"primary",onClick:e.onClose,children:"完成"})]})]}),children:n("div",{className:"space-y-6 pt-1",children:[z&&t("div",{className:"relative overflow-hidden rounded-2xl border border-warning/30 bg-[radial-gradient(120%_140%_at_0%_0%,color-mix(in_oklch,var(--color-warning)_16%,transparent),transparent_65%)] p-5",children:n("div",{className:"flex items-start gap-4 max-sm:flex-col",children:[t("div",{className:"relative flex size-11 shrink-0 items-center justify-center rounded-xl border border-warning/30 bg-panel text-warning shadow-[0_0_28px_-4px_color-mix(in_oklch,var(--color-warning)_55%,transparent)]",children:t(fe,{className:"size-5"})}),n("div",{className:"min-w-0 flex-1 space-y-1.5",children:[t("h4",{className:"text-sm font-semibold text-ink",children:"授权后即可使用此服务器"}),t("p",{className:"text-[13px] leading-relaxed text-dim",children:"该端点要求 OAuth 2.0 身份许可。在浏览器中完成授权后,令牌会自动保存并载入全部工具。"}),C&&t("p",{className:"line-clamp-2 break-words font-mono text-[11.5px] text-faint",title:C,children:C})]}),n(d,{type:"button",variant:"primary",onClick:U,disabled:S,className:"shrink-0",children:[t(un,{className:"mr-1.5 size-3.5"}),S?"正在拉起授权...":"前往授权"]})]})}),V&&n("div",{className:c("callout.base",c("callout.danger"),"gap-3 rounded-2xl p-4"),children:[t(gt,{className:"mt-0.5 size-4 shrink-0 text-danger"}),n("div",{className:"min-w-0 space-y-1",children:[t("h4",{className:"text-sm font-medium text-ink",children:"连接失败"}),t("p",{className:"font-mono text-[11.5px] leading-relaxed break-words text-dim",children:C})]})]}),n("section",{className:"space-y-3",children:[n("div",{className:"flex items-baseline justify-between gap-3 px-0.5",children:[n("h4",{className:"flex items-center gap-2 text-[13px] font-medium text-ink",children:["可用工具",t("span",{className:"rounded-full bg-raised px-1.5 py-0.5 font-mono text-[11px] leading-none text-dim",children:M})]}),t("span",{className:"text-[11.5px] text-faint",children:"对所有会话可用"})]}),G?t("div",{className:c("callout.base",c("callout.danger"),"text-xs leading-relaxed break-words"),children:G}):!W?n("div",{className:c("surface.emptyDashed","gap-2 py-10"),children:[t("div",{className:"flex size-10 items-center justify-center rounded-full bg-raised text-faint",children:t(tn,{className:"size-4.5"})}),t("p",{className:"text-[13px] font-medium text-dim",children:z?"等待授权":"尚未连接"}),t("p",{className:"max-w-xs text-xs leading-relaxed text-faint",children:z?"授权完成后会自动连接并列出工具。":"连接服务器后,这里会列出它提供的全部工具。"})]}):!m?t("div",{role:"status","aria-label":"正在获取工具列表",className:"grid gap-2",children:[0,1,2].map((p)=>n("div",{className:"animate-pulse space-y-2.5 rounded-xl border border-line p-3.5",children:[t("div",{className:"h-3.5 w-32 rounded bg-raised"}),t("div",{className:"h-3 w-4/5 rounded bg-raised/70"})]},p))}):m.length===0?n("div",{className:c("surface.emptyDashed","gap-2 py-10"),children:[t("div",{className:"flex size-10 items-center justify-center rounded-full bg-raised text-faint",children:t(tn,{className:"size-4.5"})}),t("p",{className:"text-[13px] font-medium text-dim",children:"没有可用工具"}),t("p",{className:"max-w-xs text-xs leading-relaxed text-faint",children:"已连接成功,但该服务器没有声明任何工具。"})]}):t("ul",{className:"grid gap-2",children:m.map((p)=>{let f=p.inputSchema?.properties??{},D=p.inputSchema?.required??[],R=Object.entries(f);return n("li",{className:c("surface.subtle","border-line bg-raised/30 p-3.5 transition-colors hover:border-line-strong hover:bg-raised/60"),children:[t("span",{className:"font-mono text-[13px] font-medium break-all text-accent",children:p.name}),p.description&&t("p",{className:"mt-1.5 text-[13px] leading-relaxed break-words text-dim",children:p.description}),R.length>0&&t("div",{className:"mt-3 flex flex-wrap gap-1.5",children:R.map(([x,J])=>n("span",{title:D.includes(x)?"必填参数":"可选参数",className:"inline-flex items-center gap-1 rounded-md border border-line bg-panel px-1.5 py-1 font-mono text-[11px] leading-none",children:[t("span",{className:"text-ink",children:x}),D.includes(x)&&t("span",{className:"text-warning",children:"*"}),t("span",{className:"text-faint",children:Te(J)})]},x))})]},p.name)})})]})]})})}var $e=/^[A-Za-z0-9_-]{1,64}$/;function H(e){return t("span",{className:"truncate text-xs text-faint",children:e.children})}function ye(e){let{pairs:d,onChange:g,InputComponent:y}=e,N=(u,c)=>g(d.map((k,s)=>s===u?{...k,...c}:k));return n("div",{className:"space-y-2",children:[n("div",{className:"flex min-h-7 items-center gap-2",children:[t("span",{className:"shrink-0 text-[13px] font-medium text-dim",children:e.label}),t(H,{children:e.tip}),n("button",{type:"button",className:"ml-auto inline-flex h-7 shrink-0 cursor-pointer items-center gap-1 rounded-lg px-2 text-xs font-medium text-dim transition-colors hover:bg-raised hover:text-ink",onClick:()=>g([...d,{key:"",value:"",saved:!1}]),children:[t(Re,{className:"size-3.5"}),"添加"]})]}),d.map((u,c)=>n("div",{className:"flex min-w-0 items-center gap-1.5",children:[t(y,{"aria-label":`${e.keyLabel} ${c+1}`,placeholder:e.keyLabel,value:u.key,readOnly:u.saved,onChange:(k)=>N(c,{key:k.target.value}),className:"min-w-0 flex-[2] font-mono text-xs"}),t(y,{"aria-label":`${e.keyLabel} ${u.key||c+1} 的值`,type:"password",autoComplete:"off",placeholder:u.saved?"已保存,留空保持不变":"值",value:u.value,onChange:(k)=>N(c,{value:k.target.value}),className:"min-w-0 flex-[3] font-mono text-xs"}),t("button",{type:"button","aria-label":`删除 ${u.key||"该项"}`,className:"flex size-8 shrink-0 cursor-pointer items-center justify-center rounded-lg text-faint transition-colors hover:bg-danger/10 hover:text-danger",onClick:()=>g(d.filter((k,s)=>s!==c)),children:t(oe,{className:"size-4"})})]},c))]})}function Ne(e){return Object.keys(e??{}).map((d)=>({key:d,value:"",saved:!0}))}function Ce(e){let{Button:d,Segmented:g,Dialog:y,Form:N,Field:u,Input:c,Switch:k,style:s,useTheme:I}=_();I();let{existing:m}=e,[q,G]=a(m?.config.type??"local"),[K,S]=a(m?.name??""),[j,W]=a(m?.config.type==="local"?le(m.config.command):""),[z,V]=a(m?.config.type==="remote"?m.config.url:""),[A,O]=a(Ne(m?.config.type==="local"?m.config.environment:void 0)),[U,Y]=a(Ne(m?.config.type==="remote"?m.config.headers:void 0)),E=m?.config.type==="remote"?m.config.oauth:void 0,[T,r]=a(Boolean(E)),[C,M]=a(typeof E==="object"&&E.clientId?E.clientId:""),[p,f]=a(""),[D,R]=a(typeof E==="object"&&E.scope?E.scope:""),[x,J]=a(m?.config.defer??"default"),[ee,we]=a(m?.config.timeout!==void 0?String(m.config.timeout):""),[se,ke]=a(m?.config.defer!==void 0||m?.config.timeout!==void 0),[me,Q]=a(),[ie,pe]=a(!1);async function Ie(b){b.preventDefault(),Q(void 0);let w=K.trim();if(!m&&!$e.test(w)){Q("名称只能包含英文字母、数字、下划线与中划线,长度 1-64");return}if(!m&&e.taken.includes(w)){Q("同名服务器已存在");return}let ne=ee.trim()?Number.parseInt(ee.trim(),10):void 0;if(ne!==void 0&&(!Number.isFinite(ne)||ne<=0)){Q("超时时间须为大于 0 的毫秒数");return}let ce;if(q==="local"){let L=ge(j.trim());if(!L.length){Q("请输入启动命令");return}let F={};for(let B of A){let P=B.key.trim();if(!P)continue;if(!B.saved||B.value)F[P]=B.value}ce={type:"local",command:L,environment:Object.keys(F).length?F:void 0,enabled:m?m.config.enabled:!0,defer:x==="default"?void 0:x,timeout:ne}}else{let L=z.trim();try{let P=new URL(L);if(P.protocol!=="http:"&&P.protocol!=="https:")throw Error("bad protocol")}catch{Q("请输入合法的 HTTP 或 HTTPS 地址");return}let F={};for(let P of U){let ae=P.key.trim();if(!ae)continue;if(!P.saved||P.value)F[ae]=P.value}let B;if(T){let P=C.trim(),ae=p.trim(),ue=D.trim();if(P||ae||ue)B={clientId:P||void 0,clientSecret:ae||void 0,scope:ue||void 0};else B=!0}else B=!1;ce={type:"remote",url:L,headers:Object.keys(F).length?F:void 0,oauth:B,enabled:m?m.config.enabled:!0,defer:x==="default"?void 0:x,timeout:ne}}pe(!0);try{let L=m?.name??w,F=m?m.projectID:e.projectID,B=F?`?projectID=${encodeURIComponent(F)}`:"";await e.connection.request(`/api/mcp/${encodeURIComponent(L)}${B}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(ce)}),e.onSaved()}catch(L){Q(L instanceof Error?L.message:"保存失败")}finally{pe(!1)}}return t(y,{open:!0,onOpenChange:(b)=>{if(!b&&!ie)e.onClose()},title:m?`编辑 ${m.name}`:"添加 MCP 服务器",size:"lg",footer:n("div",{className:"flex w-full justify-end gap-2.5",children:[t(d,{type:"button",variant:"ghost",onClick:e.onClose,disabled:ie,className:"min-w-20",children:"取消"}),t(d,{type:"submit",form:"mcp-server-form",variant:"primary",disabled:ie,className:"min-w-24",children:ie?"保存中...":"保存"})]}),children:n(N,{id:"mcp-server-form",onSubmit:Ie,children:[t(g,{value:q,onChange:(b)=>G(b),className:"w-full [&>button]:flex-1",options:[{value:"local",label:"本地(标准输入输出)"},{value:"remote",label:"远程(HTTP / SSE)"}]}),!m&&t(u,{label:"名称",aside:t(H,{children:"唯一标识,如 postgres"}),children:(b)=>t(c,{id:b,value:K,onChange:(w)=>S(w.target.value),placeholder:"postgres",className:"font-mono text-xs"})}),q==="local"?n(v,{children:[t(u,{label:"启动命令",aside:t(H,{children:"完整命令及参数"}),children:(b)=>t(c,{id:b,value:j,onChange:(w)=>W(w.target.value),placeholder:"npx -y @modelcontextprotocol/server-postgres ...",className:"font-mono text-xs"})}),t(ye,{label:"环境变量",tip:"启动进程时注入",keyLabel:"变量名",pairs:A,onChange:O,InputComponent:c})]}):n(v,{children:[t(u,{label:"服务地址",aside:t(H,{children:"HTTP / HTTPS 端点"}),children:(b)=>t(c,{id:b,value:z,onChange:(w)=>V(w.target.value),placeholder:"https://example.com/mcp",className:"font-mono text-xs"})}),t(ye,{label:"请求头",tip:"随每次请求发送",keyLabel:"头字段",pairs:U,onChange:Y,InputComponent:c}),n("div",{className:"flex items-center justify-between gap-4",children:[n("div",{className:"min-w-0",children:[t("span",{className:"block text-[13px] font-medium text-dim",children:"OAuth 2.0 认证"}),t("span",{className:"block truncate text-xs text-faint",children:"自动发现授权端点,使用 PKCE 并刷新令牌"})]}),t(k,{checked:T,onCheckedChange:r,label:"启用 OAuth 2.0"})]}),T&&n(v,{children:[t(u,{label:"Client ID",aside:t(H,{children:"留空自动动态注册(DCR)"}),children:(b)=>t(c,{id:b,value:C,onChange:(w)=>M(w.target.value),placeholder:"留空自动动态注册",className:"font-mono text-xs"})}),t(u,{label:"Client Secret",aside:t(H,{children:"留空保持不变"}),children:(b)=>t(c,{id:b,type:"password",autoComplete:"off",value:p,onChange:(w)=>f(w.target.value),placeholder:"••••••••",className:"font-mono text-xs"})}),t(u,{label:"Scope",aside:t(H,{children:"选填授权范围"}),children:(b)=>t(c,{id:b,value:D,onChange:(w)=>R(w.target.value),placeholder:"repo read:org",className:"font-mono text-xs"})})]})]}),n("div",{className:"space-y-3 border-t border-line/60 pt-3",children:[n("button",{type:"button","aria-expanded":se,className:"flex w-full cursor-pointer items-center gap-1.5 text-[13px] font-medium text-dim transition-colors hover:text-ink",onClick:()=>ke(!se),children:[t(yt,{className:`size-3.5 transition-transform ${se?"rotate-90":""}`}),"高级设置",t("span",{className:"truncate text-xs font-normal text-faint",children:"加载时机、超时"})]}),se&&n("div",{className:"grid grid-cols-2 gap-3 max-sm:grid-cols-1",children:[t(u,{label:"加载时机",aside:t(H,{children:"延迟 = 按需加载"}),children:()=>t(g,{value:x,onChange:(b)=>J(b),className:"w-full [&>button]:flex-1",options:[{value:"default",label:"默认"},{value:"defer",label:"延迟"},{value:"always",label:"常驻"}]})}),t(u,{label:"超时(毫秒)",aside:t(H,{children:"留空用默认"}),children:(b)=>t(c,{id:b,value:ee,onChange:(w)=>we(w.target.value),placeholder:"默认",className:"font-mono text-xs"})})]})]}),me&&n("div",{role:"alert",className:s("callout.base",s("callout.danger"),"px-3 py-2.5 text-xs"),children:[t(Z,{className:"mt-0.5 size-3.5 shrink-0"}),t("span",{className:"min-w-0 break-words",children:me})]})]})})}function tt({connection:e}){let{Button:d,Input:g,style:y,useTheme:N}=_();N();let[u,c]=a(""),[k,s]=a(),[I,m]=a(),[q,G]=a(!1),[K,S]=a(),[j,W]=a(!1),z=i(!1),[V,A]=a(),O=i(0),U=h(async()=>{let r=++O.current;G(!0);try{let C=await e.request("/api/mcp");if(r!==O.current)return;s(C),m(void 0)}catch(C){if(r===O.current)m(C instanceof Error?C.message:"读取失败")}finally{if(r===O.current)G(!1)}},[e]);o(()=>(U(),()=>{O.current++}),[U]);async function Y(r,C){if(z.current)return;z.current=!0,W(!0);let M=O.current;try{let p=r.projectID?`?projectID=${encodeURIComponent(r.projectID)}`:"",f=await e.request(`/api/mcp/${encodeURIComponent(r.name)}${p}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify({...r.config,enabled:C})});if(M===O.current)s((D)=>D?.map((R)=>R.name===f.name&&R.projectID===f.projectID?f:R))}finally{z.current=!1,W(!1)}}let E=k?.filter((r)=>`${r.name} ${X(r.config)}`.toLowerCase().includes(u.trim().toLowerCase())),T=k?.find((r)=>r.name===K);return n("div",{className:"min-w-0 space-y-6",children:[n("section",{className:"min-w-0",children:[n("div",{className:"mb-2.5 flex flex-wrap items-end justify-between gap-3 px-0.5",children:[n("div",{className:"min-w-0 flex-1 basis-48",children:[t("h2",{className:y("settings.groupTitle"),children:"MCP 服务器"}),t("p",{className:y("settings.groupDesc"),children:"外部工具与数据源管理"})]}),n("div",{className:"flex gap-2",children:[t(d,{variant:"ghost",disabled:q,onClick:U,className:"h-9 px-2.5 text-xs",children:t(te,{className:`size-3.5 ${q?"animate-spin":""}`})}),n(d,{variant:"secondary",onClick:()=>A({}),className:"h-9 px-2.5 text-xs",children:[t(Re,{className:"size-3.5 mr-1"}),"添加服务器"]})]})]}),I&&n("div",{role:"alert",className:y("callout.base",y("callout.danger"),"mb-3 flex-wrap items-center justify-between"),children:[n("p",{className:"min-w-0 flex-1 break-words text-sm text-danger",children:["无法读取 MCP 服务器:",I]}),t(d,{disabled:q,onClick:U,children:"重试"})]}),n("div",{className:"relative mb-3 min-w-0",children:[t(de,{"aria-hidden":!0,className:"pointer-events-none absolute top-3 left-3 size-4 text-faint"}),t(g,{type:"search","aria-label":"搜索 MCP 服务器",placeholder:"搜索服务器",value:u,onChange:(r)=>c(r.target.value),className:"h-10 min-w-0 pl-9"})]}),t("div",{className:y("settings.groupBox"),children:!k?t("div",{role:"status","aria-label":"正在加载",className:"divide-y divide-line",children:[0,1,2].map((r)=>n("div",{className:"h-16 space-y-2 px-4 py-3",children:[t("div",{className:"h-3 w-24 animate-pulse rounded bg-raised"}),t("div",{className:"h-3 w-2/3 animate-pulse rounded bg-raised"})]},r))}):E?.length===0?t("p",{className:"p-4 text-sm text-dim",children:"没有匹配的 MCP 服务器"}):t("ul",{className:"divide-y divide-line",children:E?.map((r)=>{let C=r.config.enabled===!1,M=r.scope==="file";return n("li",{className:`flex min-w-0 items-center justify-between gap-3 px-4 py-2.5 transition-colors hover:bg-raised/40 ${C?"opacity-55":""}`,children:[n("button",{type:"button",className:"group flex min-h-12 min-w-0 flex-1 cursor-pointer items-center gap-3 py-1 text-left focus-visible:outline-2 focus-visible:outline-accent","aria-label":`查看 ${r.name}`,disabled:M,title:M?"来自项目的 .mcp.json,只读":void 0,onClick:()=>S(r.name),children:[t("span",{"aria-hidden":!0,className:"flex size-9 shrink-0 items-center justify-center rounded-lg bg-raised text-dim",children:r.config.type==="local"?t(ot,{className:"size-4"}):t(ve,{className:"size-4"})}),n("span",{className:"min-w-0 flex-1",children:[t("span",{className:"block truncate text-sm font-medium text-ink",title:r.name,children:r.name}),t("span",{className:"mt-0.5 block truncate font-mono text-xs text-dim",title:X(r.config),children:X(r.config)})]}),t("span",{className:y("control.badge","shrink-0 text-[11px] text-dim"),children:r.scope==="project"?"项目":r.scope==="file"?".mcp.json":"全局"}),t(he,{info:r})]}),t("span",{className:"relative flex size-10 shrink-0 items-center justify-center",children:!M&&t("input",{type:"checkbox","aria-label":`启用服务器 ${r.name}`,className:xe,disabled:j||q,checked:!C,onChange:(p)=>Y(r,p.target.checked)})})]},r.name)})})})]}),T&&!V&&t(be,{connection:e,info:T,onClose:()=>S(void 0),onEdit:()=>A({info:T}),onChanged:(r)=>r?s((C)=>C?.map((M)=>M.name===r.name?r:M)):U()},`${T.projectID}:${T.name}`),V&&t(Ce,{connection:e,existing:V.info,taken:(k??[]).map((r)=>r.name),onClose:()=>A(void 0),onSaved:()=>{A(void 0),U()}})]})}export{tt as McpSection};