@bkm016/basalt 0.1.24 → 0.1.25
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.
- package/{chunk-bdr1170y.js → chunk-2c6seev1.js} +1 -1
- package/{chunk-9y8v1vrt.js → chunk-4mwx4pet.js} +1 -1
- package/{chunk-4x7xnfw1.js → chunk-61e7nvw9.js} +1 -1
- package/{chunk-979mxkzt.js → chunk-93bcazsp.js} +1 -1
- package/{chunk-y16fqzad.js → chunk-9fccgczj.js} +1 -1
- package/{chunk-kh4yq4rd.js → chunk-ff293dj0.js} +1 -1
- package/{chunk-cte9wd9x.js → chunk-g23dnf4y.js} +1 -1
- package/{chunk-c4nxr37s.js → chunk-gwcstcqs.js} +4 -4
- package/{chunk-ma91f4qj.js → chunk-m839588n.js} +1 -1
- package/{chunk-0nxcbf6d.js → chunk-pjv9mppd.js} +109 -108
- package/{chunk-pcd14q8r.js → chunk-rkn6bven.js} +4 -4
- package/compiled.js +1 -1
- package/package.json +1 -1
- package/ui-test-worker.js +1 -1
- package/web/{chunk-ppccb30x.js → chunk-00wh99xz.js} +4 -4
- package/web/chunk-00wh99xz.js.br +0 -0
- package/web/chunk-00wh99xz.js.gz +0 -0
- package/web/{chunk-g7t1bvvx.js → chunk-0a1t2j8h.js} +1 -1
- package/web/chunk-0a1t2j8h.js.br +0 -0
- package/web/chunk-0a1t2j8h.js.gz +0 -0
- package/web/{chunk-59ybhv47.js → chunk-1ar2phwa.js} +1 -1
- package/web/chunk-1ar2phwa.js.br +0 -0
- package/web/chunk-1ar2phwa.js.gz +0 -0
- package/web/{chunk-hqtm67yw.js → chunk-1jfydncj.js} +2 -2
- package/web/chunk-1jfydncj.js.br +0 -0
- package/web/chunk-1jfydncj.js.gz +0 -0
- package/web/{chunk-qqtj88e0.js → chunk-1p1jtvrt.js} +1 -1
- package/web/chunk-1p1jtvrt.js.br +0 -0
- package/web/chunk-1p1jtvrt.js.gz +0 -0
- package/web/chunk-1x38r11w.js +1 -0
- package/web/chunk-1x38r11w.js.br +2 -0
- package/web/chunk-1x38r11w.js.gz +0 -0
- package/web/{chunk-bbyqcvdz.js → chunk-25rf3svt.js} +2 -2
- package/web/chunk-25rf3svt.js.br +0 -0
- package/web/chunk-25rf3svt.js.gz +0 -0
- package/web/chunk-2cfv55j2.js +1 -0
- package/web/chunk-2cfv55j2.js.br +0 -0
- package/web/chunk-2cfv55j2.js.gz +0 -0
- package/web/{chunk-bg2ps35t.js → chunk-2q37qdq2.js} +1 -1
- package/web/chunk-2q37qdq2.js.br +0 -0
- package/web/chunk-2q37qdq2.js.gz +0 -0
- package/web/{chunk-13x3xyyh.js → chunk-2yhmab75.js} +4 -4
- package/web/chunk-2yhmab75.js.br +0 -0
- package/web/chunk-2yhmab75.js.gz +0 -0
- package/web/{chunk-bvmvj35k.js → chunk-3at57qna.js} +1 -1
- package/web/chunk-3at57qna.js.br +0 -0
- package/web/chunk-3at57qna.js.gz +0 -0
- package/web/{chunk-nb3jk1wk.js → chunk-3z9kpkec.js} +1 -1
- package/web/chunk-3z9kpkec.js.br +0 -0
- package/web/chunk-3z9kpkec.js.gz +0 -0
- package/web/chunk-4ncnt1c2.js +2 -0
- package/web/chunk-4ncnt1c2.js.br +0 -0
- package/web/{chunk-k69ysa0v.js → chunk-4ncnt1c2.js.gz} +0 -0
- package/web/chunk-4vc07x6t.js +1 -0
- package/web/chunk-4vc07x6t.js.br +0 -0
- package/web/chunk-4vc07x6t.js.gz +0 -0
- package/web/{chunk-921qw2jf.js → chunk-4ytc5sth.js} +1 -1
- package/web/chunk-4ytc5sth.js.br +0 -0
- package/web/chunk-4ytc5sth.js.gz +0 -0
- package/web/{chunk-zs7c2db4.js → chunk-5c5h90k0.js} +1 -1
- package/web/chunk-5c5h90k0.js.br +0 -0
- package/web/chunk-5c5h90k0.js.gz +0 -0
- package/web/chunk-5zpn3n5a.js +1 -0
- package/web/chunk-5zpn3n5a.js.br +0 -0
- package/web/chunk-5zpn3n5a.js.gz +0 -0
- package/web/chunk-64k06g43.js +1 -0
- package/web/chunk-64k06g43.js.br +0 -0
- package/web/chunk-64k06g43.js.gz +0 -0
- package/web/{chunk-bh0a254y.js → chunk-6pbrtp4e.js} +4 -4
- package/web/chunk-6pbrtp4e.js.br +0 -0
- package/web/chunk-6pbrtp4e.js.gz +0 -0
- package/web/chunk-6sehssym.js +1 -0
- package/web/chunk-6sehssym.js.br +2 -0
- package/web/chunk-6sehssym.js.gz +0 -0
- package/web/chunk-7hxj251q.js +1 -0
- package/web/chunk-7hxj251q.js.br +0 -0
- package/web/chunk-7hxj251q.js.gz +0 -0
- package/web/{chunk-abvtsz6z.js → chunk-7qcmg5ns.js} +1 -1
- package/web/chunk-7qcmg5ns.js.br +0 -0
- package/web/chunk-7qcmg5ns.js.gz +0 -0
- package/web/{chunk-172gywq4.js → chunk-82j6713x.js} +6 -6
- package/web/chunk-82j6713x.js.br +0 -0
- package/web/chunk-82j6713x.js.gz +0 -0
- package/web/{chunk-kbvzxsz7.js → chunk-9vexd52p.js} +1 -1
- package/web/chunk-9vexd52p.js.br +0 -0
- package/web/chunk-9vexd52p.js.gz +0 -0
- package/web/{chunk-crhbhsrh.js → chunk-ajj3nc80.js} +1 -1
- package/web/chunk-ajj3nc80.js.br +0 -0
- package/web/chunk-ajj3nc80.js.gz +0 -0
- package/web/chunk-amrkb4dd.js +1 -0
- package/web/chunk-amrkb4dd.js.br +0 -0
- package/web/chunk-amrkb4dd.js.gz +0 -0
- package/web/{chunk-w563538j.js → chunk-b7d5k9sp.js} +35 -35
- package/web/chunk-b7d5k9sp.js.br +0 -0
- package/web/chunk-b7d5k9sp.js.gz +0 -0
- package/web/chunk-bavn0z5d.js +1 -0
- package/web/chunk-bavn0z5d.js.br +0 -0
- package/web/chunk-bavn0z5d.js.gz +0 -0
- package/web/{chunk-yp75a6yh.js → chunk-bjw74xvy.js} +1 -1
- package/web/chunk-bjw74xvy.js.br +0 -0
- package/web/chunk-bjw74xvy.js.gz +0 -0
- package/web/chunk-bn68ks4x.js +1 -0
- package/web/chunk-bn68ks4x.js.br +0 -0
- package/web/chunk-bn68ks4x.js.gz +0 -0
- package/web/chunk-c59d2j14.js +8 -0
- package/web/chunk-c59d2j14.js.br +0 -0
- package/web/chunk-c59d2j14.js.gz +0 -0
- package/web/{chunk-634vc92s.js → chunk-cfz9ftze.js} +3 -3
- package/web/chunk-cfz9ftze.js.br +0 -0
- package/web/chunk-cfz9ftze.js.gz +0 -0
- package/web/{chunk-zsae1tn8.js → chunk-chq476ch.js} +4 -4
- package/web/chunk-chq476ch.js.br +0 -0
- package/web/chunk-chq476ch.js.gz +0 -0
- package/web/{chunk-5zkw2kkb.js → chunk-d0ey112q.js} +5 -5
- package/web/chunk-d0ey112q.js.br +0 -0
- package/web/chunk-d0ey112q.js.gz +0 -0
- package/web/{chunk-h1cv1kke.js → chunk-d71z7s5r.js} +1 -1
- package/web/chunk-d71z7s5r.js.br +0 -0
- package/web/chunk-d71z7s5r.js.gz +0 -0
- package/web/{chunk-8de69eyx.js → chunk-dembnhph.js} +1 -1
- package/web/chunk-dembnhph.js.br +0 -0
- package/web/chunk-dembnhph.js.gz +0 -0
- package/web/{chunk-m5nt857c.js → chunk-dfq4w8mf.js} +1 -1
- package/web/chunk-dfq4w8mf.js.br +0 -0
- package/web/chunk-dfq4w8mf.js.gz +0 -0
- package/web/{chunk-bbs6yq60.js → chunk-dwdxczxc.js} +3 -3
- package/web/chunk-dwdxczxc.js.br +0 -0
- package/web/chunk-dwdxczxc.js.gz +0 -0
- package/web/chunk-e3b2krd7.js +1 -0
- package/web/chunk-e3b2krd7.js.br +0 -0
- package/web/chunk-e3b2krd7.js.gz +0 -0
- package/web/{chunk-91s1ns6b.js → chunk-e4wbkc1x.js} +11 -11
- package/web/chunk-e4wbkc1x.js.br +0 -0
- package/web/chunk-e4wbkc1x.js.gz +0 -0
- package/web/{chunk-ygzgrjj7.js → chunk-f2qrf0he.js} +1 -1
- package/web/chunk-f2qrf0he.js.br +0 -0
- package/web/chunk-f2qrf0he.js.gz +0 -0
- package/web/{chunk-ca8hnmmv.js → chunk-f88vhwan.js} +5 -5
- package/web/chunk-f88vhwan.js.br +0 -0
- package/web/chunk-f88vhwan.js.gz +0 -0
- package/web/{chunk-yg9a23mv.js → chunk-fpp6jtb4.js} +1 -1
- package/web/chunk-fpp6jtb4.js.br +0 -0
- package/web/chunk-fpp6jtb4.js.gz +0 -0
- package/web/chunk-ft62hfnt.js +1 -0
- package/web/chunk-ft62hfnt.js.br +0 -0
- package/web/chunk-ft62hfnt.js.gz +0 -0
- package/web/{chunk-176tsg6e.js → chunk-g3fahpjw.js} +2 -2
- package/web/chunk-g3fahpjw.js.br +0 -0
- package/web/chunk-g3fahpjw.js.gz +0 -0
- package/web/{chunk-xw8tzrmm.js → chunk-g5b4wjwp.js} +94 -94
- package/web/chunk-g5b4wjwp.js.br +0 -0
- package/web/chunk-g5b4wjwp.js.gz +0 -0
- package/web/chunk-ga3tn73a.js +1 -0
- package/web/chunk-ga3tn73a.js.br +0 -0
- package/web/chunk-ga3tn73a.js.gz +0 -0
- package/web/{chunk-4cbcqcd2.js → chunk-gf4vtpw2.js} +1 -1
- package/web/chunk-gf4vtpw2.js.br +0 -0
- package/web/chunk-gf4vtpw2.js.gz +0 -0
- package/web/{chunk-n9npqkxf.js → chunk-ghxfjwhq.js} +1 -1
- package/web/chunk-ghxfjwhq.js.br +0 -0
- package/web/chunk-ghxfjwhq.js.gz +0 -0
- package/web/{chunk-hsgtzrkh.js → chunk-gxqs7zmy.js} +1 -1
- package/web/chunk-gxqs7zmy.js.br +0 -0
- package/web/chunk-gxqs7zmy.js.gz +0 -0
- package/web/{chunk-9k9p5dat.js → chunk-jpdp0xkd.js} +1 -1
- package/web/chunk-jpdp0xkd.js.br +0 -0
- package/web/chunk-jpdp0xkd.js.gz +0 -0
- package/web/{chunk-kn9bc5z2.js → chunk-jtzbk251.js} +2 -2
- package/web/chunk-jtzbk251.js.br +0 -0
- package/web/chunk-jtzbk251.js.gz +0 -0
- package/web/{chunk-ac8vmj54.js → chunk-kc6k0ect.js} +1 -1
- package/web/chunk-kc6k0ect.js.br +0 -0
- package/web/chunk-kc6k0ect.js.gz +0 -0
- package/web/{chunk-gy2y4zfa.js → chunk-kk7k8xc8.js} +5 -5
- package/web/chunk-kk7k8xc8.js.br +0 -0
- package/web/chunk-kk7k8xc8.js.gz +0 -0
- package/web/{chunk-6n3cwe1h.js → chunk-kmpyntam.js} +19 -19
- package/web/chunk-kmpyntam.js.br +0 -0
- package/web/chunk-kmpyntam.js.gz +0 -0
- package/web/{chunk-q17rem99.js → chunk-mejpj22t.js} +5 -5
- package/web/chunk-mejpj22t.js.br +0 -0
- package/web/chunk-mejpj22t.js.gz +0 -0
- package/web/{chunk-sapy54hm.js → chunk-mm10pm0x.js} +3 -3
- package/web/chunk-mm10pm0x.js.br +0 -0
- package/web/chunk-mm10pm0x.js.gz +0 -0
- package/web/{chunk-r4cr8rvt.js → chunk-mpve4748.js} +1 -1
- package/web/chunk-mpve4748.js.br +0 -0
- package/web/chunk-mpve4748.js.gz +0 -0
- package/web/chunk-ms022qq9.js +1 -0
- package/web/chunk-ms022qq9.js.br +2 -0
- package/web/chunk-ms022qq9.js.gz +0 -0
- package/web/{chunk-xv1d350x.js → chunk-mxf122px.js} +1 -1
- package/web/chunk-mxf122px.js.br +0 -0
- package/web/chunk-mxf122px.js.gz +0 -0
- package/web/chunk-mzv41kv9.js +1 -0
- package/web/chunk-mzv41kv9.js.br +2 -0
- package/web/chunk-mzv41kv9.js.gz +0 -0
- package/web/{chunk-2fms67zg.js → chunk-mzyg8zga.js} +1 -1
- package/web/chunk-mzyg8zga.js.br +0 -0
- package/web/chunk-mzyg8zga.js.gz +0 -0
- package/web/{chunk-c2eqwepm.js → chunk-n8j9jdsh.js} +1 -1
- package/web/chunk-n8j9jdsh.js.br +0 -0
- package/web/chunk-n8j9jdsh.js.gz +0 -0
- package/web/{chunk-fp7q643n.js → chunk-n8ts6ra2.js} +3 -3
- package/web/chunk-n8ts6ra2.js.br +0 -0
- package/web/chunk-n8ts6ra2.js.gz +0 -0
- package/web/chunk-nefchfa1.js +1 -0
- package/web/chunk-nefchfa1.js.br +0 -0
- package/web/chunk-nefchfa1.js.gz +0 -0
- package/web/chunk-ng0bsm6n.js +1 -0
- package/web/chunk-ng0bsm6n.js.br +0 -0
- package/web/chunk-ng0bsm6n.js.gz +0 -0
- package/web/{chunk-ced8pdbc.js → chunk-nz1mm18x.js} +1 -1
- package/web/chunk-nz1mm18x.js.br +0 -0
- package/web/chunk-nz1mm18x.js.gz +0 -0
- package/web/{chunk-mbaw66b5.js → chunk-pdxqp4rh.js} +1 -1
- package/web/chunk-pdxqp4rh.js.br +0 -0
- package/web/chunk-pdxqp4rh.js.gz +0 -0
- package/web/{chunk-g1penf6y.js → chunk-pe2zvyjt.js} +1 -1
- package/web/chunk-pe2zvyjt.js.br +0 -0
- package/web/chunk-pe2zvyjt.js.gz +0 -0
- package/web/{chunk-t7vwsg9r.js → chunk-q8ve5wqt.js} +2 -2
- package/web/chunk-q8ve5wqt.js.br +0 -0
- package/web/chunk-q8ve5wqt.js.gz +0 -0
- package/web/{chunk-ny87aq2j.js → chunk-qh93t9tv.js} +1 -1
- package/web/chunk-qh93t9tv.js.br +0 -0
- package/web/chunk-qh93t9tv.js.gz +0 -0
- package/web/{chunk-3vdw9nn7.js → chunk-qqewmk3y.js} +1 -1
- package/web/chunk-qqewmk3y.js.br +0 -0
- package/web/chunk-qqewmk3y.js.gz +0 -0
- package/web/{chunk-n59nyqcr.js → chunk-qzb06me8.js} +34 -34
- package/web/chunk-qzb06me8.js.br +0 -0
- package/web/chunk-qzb06me8.js.gz +0 -0
- package/web/{chunk-tt7j0m6m.js → chunk-r2zernvz.js} +5 -5
- package/web/chunk-r2zernvz.js.br +0 -0
- package/web/chunk-r2zernvz.js.gz +0 -0
- package/web/{chunk-qdq6wvgt.js → chunk-r8ykja8v.js} +3 -3
- package/web/chunk-r8ykja8v.js.br +0 -0
- package/web/chunk-r8ykja8v.js.gz +0 -0
- package/web/{chunk-qhr6hegh.js → chunk-r9b7eh2j.js} +1 -1
- package/web/chunk-r9b7eh2j.js.br +0 -0
- package/web/chunk-r9b7eh2j.js.gz +0 -0
- package/web/{chunk-eq28qb33.js → chunk-ry1wp3v8.js} +2 -2
- package/web/chunk-ry1wp3v8.js.br +0 -0
- package/web/chunk-ry1wp3v8.js.gz +0 -0
- package/web/chunk-s2bfc2vk.js +1 -0
- package/web/chunk-s2bfc2vk.js.br +0 -0
- package/web/chunk-s2bfc2vk.js.gz +0 -0
- package/web/{chunk-2psxv4dk.js → chunk-s4c6nzj9.js} +5 -5
- package/web/chunk-s4c6nzj9.js.br +0 -0
- package/web/chunk-s4c6nzj9.js.gz +0 -0
- package/web/{chunk-b9fqnzqd.js → chunk-ss23nnmc.js} +4 -4
- package/web/chunk-ss23nnmc.js.br +0 -0
- package/web/chunk-ss23nnmc.js.gz +0 -0
- package/web/{chunk-b2t33c3t.js → chunk-sxmv80th.js} +1 -1
- package/web/chunk-sxmv80th.js.br +0 -0
- package/web/chunk-sxmv80th.js.gz +0 -0
- package/web/{chunk-3sszg3gr.js → chunk-sy2cdka3.js} +1 -1
- package/web/chunk-sy2cdka3.js.br +0 -0
- package/web/chunk-sy2cdka3.js.gz +0 -0
- package/web/{chunk-vgpyff03.js → chunk-sysebfkg.js} +3 -3
- package/web/chunk-sysebfkg.js.br +0 -0
- package/web/chunk-sysebfkg.js.gz +0 -0
- package/web/{chunk-vb3sy3hv.js → chunk-t3620hrb.js} +2 -2
- package/web/chunk-t3620hrb.js.br +0 -0
- package/web/chunk-t3620hrb.js.gz +0 -0
- package/web/{chunk-phr7yps3.js → chunk-t5srz1hs.js} +2 -2
- package/web/chunk-t5srz1hs.js.br +0 -0
- package/web/chunk-t5srz1hs.js.gz +0 -0
- package/web/{chunk-sarkb4p9.js → chunk-v25k7n3r.js} +1 -1
- package/web/chunk-v25k7n3r.js.br +0 -0
- package/web/chunk-v25k7n3r.js.gz +0 -0
- package/web/{chunk-e3d6kvwm.js → chunk-vf0p4ayw.js} +1 -1
- package/web/chunk-vf0p4ayw.js.br +0 -0
- package/web/chunk-vf0p4ayw.js.gz +0 -0
- package/web/chunk-vr6n4pvt.js +1 -0
- package/web/chunk-vr6n4pvt.js.br +0 -0
- package/web/chunk-vr6n4pvt.js.gz +0 -0
- package/web/{chunk-713ygtrs.js → chunk-vx9g94x2.js} +4 -4
- package/web/chunk-vx9g94x2.js.br +0 -0
- package/web/chunk-vx9g94x2.js.gz +0 -0
- package/web/{chunk-cj0cmvbm.js → chunk-w5v80bmk.js} +4 -4
- package/web/chunk-w5v80bmk.js.br +0 -0
- package/web/chunk-w5v80bmk.js.gz +0 -0
- package/web/{chunk-y5zd05mz.js → chunk-wj0ck0pa.js} +1 -1
- package/web/chunk-wj0ck0pa.js.br +0 -0
- package/web/chunk-wj0ck0pa.js.gz +0 -0
- package/web/chunk-wjzdpyhs.css +1 -0
- package/web/chunk-wjzdpyhs.css.br +0 -0
- package/web/chunk-wjzdpyhs.css.gz +0 -0
- package/web/{chunk-17d30546.js → chunk-wmt8d7zv.js} +5 -5
- package/web/chunk-wmt8d7zv.js.br +0 -0
- package/web/chunk-wmt8d7zv.js.gz +0 -0
- package/web/{chunk-ksr360js.js → chunk-wqf0qjbv.js} +2 -2
- package/web/chunk-wqf0qjbv.js.br +0 -0
- package/web/chunk-wqf0qjbv.js.gz +0 -0
- package/web/{chunk-2z4zhtw4.js → chunk-y5f7gy03.js} +2 -2
- package/web/chunk-y5f7gy03.js.br +0 -0
- package/web/chunk-y5f7gy03.js.gz +0 -0
- package/web/{chunk-96n0nem7.js → chunk-yg78fas7.js} +1 -1
- package/web/chunk-yg78fas7.js.br +0 -0
- package/web/chunk-yg78fas7.js.gz +0 -0
- package/web/{chunk-k8x1xbf6.js → chunk-yvkbc3s5.js} +1 -1
- package/web/chunk-yvkbc3s5.js.br +0 -0
- package/web/chunk-yvkbc3s5.js.gz +0 -0
- package/web/{chunk-wrqazg2v.js → chunk-z9nj64n7.js} +1 -1
- package/web/chunk-z9nj64n7.js.br +0 -0
- package/web/chunk-z9nj64n7.js.gz +0 -0
- package/web/{chunk-ms7cscs9.js → chunk-zc0e01j4.js} +1 -1
- package/web/chunk-zc0e01j4.js.br +0 -0
- package/web/chunk-zc0e01j4.js.gz +0 -0
- package/web/{chunk-290wy4yk.js → chunk-zj9s9w76.js} +1 -1
- package/web/chunk-zj9s9w76.js.br +0 -0
- package/web/chunk-zj9s9w76.js.gz +0 -0
- package/web/{chunk-085ttz7c.js → chunk-znwpavn5.js} +4 -4
- package/web/chunk-znwpavn5.js.br +0 -0
- package/web/chunk-znwpavn5.js.gz +0 -0
- package/web/index.html +1 -1
- package/web/index.html.br +0 -0
- package/web/index.html.gz +0 -0
- package/web/chunk-085ttz7c.js.br +0 -0
- package/web/chunk-085ttz7c.js.gz +0 -0
- package/web/chunk-13x3xyyh.js.br +0 -0
- package/web/chunk-13x3xyyh.js.gz +0 -0
- package/web/chunk-172gywq4.js.br +0 -0
- package/web/chunk-172gywq4.js.gz +0 -0
- package/web/chunk-176tsg6e.js.br +0 -0
- package/web/chunk-176tsg6e.js.gz +0 -0
- package/web/chunk-17d30546.js.br +0 -0
- package/web/chunk-17d30546.js.gz +0 -0
- package/web/chunk-1k6jx4hs.js +0 -1
- package/web/chunk-1k6jx4hs.js.br +0 -0
- package/web/chunk-1k6jx4hs.js.gz +0 -0
- package/web/chunk-1kts05s6.css +0 -1
- package/web/chunk-1kts05s6.css.br +0 -0
- package/web/chunk-1kts05s6.css.gz +0 -0
- package/web/chunk-1z0x1j6q.js +0 -1
- package/web/chunk-1z0x1j6q.js.br +0 -0
- package/web/chunk-1z0x1j6q.js.gz +0 -0
- package/web/chunk-290wy4yk.js.br +0 -0
- package/web/chunk-290wy4yk.js.gz +0 -0
- package/web/chunk-2cdw1299.js +0 -1
- package/web/chunk-2cdw1299.js.br +0 -0
- package/web/chunk-2cdw1299.js.gz +0 -0
- package/web/chunk-2fms67zg.js.br +0 -0
- package/web/chunk-2fms67zg.js.gz +0 -0
- package/web/chunk-2psxv4dk.js.br +0 -0
- package/web/chunk-2psxv4dk.js.gz +0 -0
- package/web/chunk-2z4zhtw4.js.br +0 -0
- package/web/chunk-2z4zhtw4.js.gz +0 -0
- package/web/chunk-3sszg3gr.js.br +0 -0
- package/web/chunk-3sszg3gr.js.gz +0 -0
- package/web/chunk-3vdw9nn7.js.br +0 -0
- package/web/chunk-3vdw9nn7.js.gz +0 -0
- package/web/chunk-4cbcqcd2.js.br +0 -0
- package/web/chunk-4cbcqcd2.js.gz +0 -0
- package/web/chunk-4v6n6b36.js +0 -1
- package/web/chunk-4v6n6b36.js.br +0 -0
- package/web/chunk-4v6n6b36.js.gz +0 -0
- package/web/chunk-59ybhv47.js.br +0 -0
- package/web/chunk-59ybhv47.js.gz +0 -0
- package/web/chunk-5zkw2kkb.js.br +0 -0
- package/web/chunk-5zkw2kkb.js.gz +0 -0
- package/web/chunk-634vc92s.js.br +0 -0
- package/web/chunk-634vc92s.js.gz +0 -0
- package/web/chunk-6n3cwe1h.js.br +0 -0
- package/web/chunk-6n3cwe1h.js.gz +0 -0
- package/web/chunk-6zr2j7xj.js +0 -1
- package/web/chunk-6zr2j7xj.js.br +0 -0
- package/web/chunk-6zr2j7xj.js.gz +0 -0
- package/web/chunk-713ygtrs.js.br +0 -0
- package/web/chunk-713ygtrs.js.gz +0 -0
- package/web/chunk-7m4gmjvp.js +0 -1
- package/web/chunk-7m4gmjvp.js.br +0 -0
- package/web/chunk-7m4gmjvp.js.gz +0 -0
- package/web/chunk-7x90pq42.js +0 -1
- package/web/chunk-7x90pq42.js.br +0 -0
- package/web/chunk-7x90pq42.js.gz +0 -0
- package/web/chunk-8de69eyx.js.br +0 -0
- package/web/chunk-8de69eyx.js.gz +0 -0
- package/web/chunk-91s1ns6b.js.br +0 -0
- package/web/chunk-91s1ns6b.js.gz +0 -0
- package/web/chunk-921qw2jf.js.br +0 -0
- package/web/chunk-921qw2jf.js.gz +0 -0
- package/web/chunk-96n0nem7.js.br +0 -0
- package/web/chunk-96n0nem7.js.gz +0 -0
- package/web/chunk-9k9p5dat.js.br +0 -0
- package/web/chunk-9k9p5dat.js.gz +0 -0
- package/web/chunk-a529550j.js +0 -1
- package/web/chunk-a529550j.js.br +0 -0
- package/web/chunk-a529550j.js.gz +0 -0
- package/web/chunk-abvtsz6z.js.br +0 -0
- package/web/chunk-abvtsz6z.js.gz +0 -0
- package/web/chunk-ac8vmj54.js.br +0 -0
- package/web/chunk-ac8vmj54.js.gz +0 -0
- package/web/chunk-b2t33c3t.js.br +0 -0
- package/web/chunk-b2t33c3t.js.gz +0 -0
- package/web/chunk-b9fqnzqd.js.br +0 -0
- package/web/chunk-b9fqnzqd.js.gz +0 -0
- package/web/chunk-bbs6yq60.js.br +0 -0
- package/web/chunk-bbs6yq60.js.gz +0 -0
- package/web/chunk-bbyqcvdz.js.br +0 -0
- package/web/chunk-bbyqcvdz.js.gz +0 -0
- package/web/chunk-bg2ps35t.js.br +0 -0
- package/web/chunk-bg2ps35t.js.gz +0 -0
- package/web/chunk-bh0a254y.js.br +0 -0
- package/web/chunk-bh0a254y.js.gz +0 -0
- package/web/chunk-bvmvj35k.js.br +0 -0
- package/web/chunk-bvmvj35k.js.gz +0 -0
- package/web/chunk-c2eqwepm.js.br +0 -0
- package/web/chunk-c2eqwepm.js.gz +0 -0
- package/web/chunk-ca8hnmmv.js.br +0 -0
- package/web/chunk-ca8hnmmv.js.gz +0 -0
- package/web/chunk-ced8pdbc.js.br +0 -0
- package/web/chunk-ced8pdbc.js.gz +0 -0
- package/web/chunk-cj0cmvbm.js.br +0 -0
- package/web/chunk-cj0cmvbm.js.gz +0 -0
- package/web/chunk-crhbhsrh.js.br +0 -0
- package/web/chunk-crhbhsrh.js.gz +0 -0
- package/web/chunk-e3d6kvwm.js.br +0 -0
- package/web/chunk-e3d6kvwm.js.gz +0 -0
- package/web/chunk-eq28qb33.js.br +0 -3
- package/web/chunk-eq28qb33.js.gz +0 -0
- package/web/chunk-f8ac76br.js +0 -2
- package/web/chunk-f8ac76br.js.br +0 -3
- package/web/chunk-f8ac76br.js.gz +0 -0
- package/web/chunk-fp7q643n.js.br +0 -0
- package/web/chunk-fp7q643n.js.gz +0 -0
- package/web/chunk-g1penf6y.js.br +0 -0
- package/web/chunk-g1penf6y.js.gz +0 -0
- package/web/chunk-g7t1bvvx.js.br +0 -0
- package/web/chunk-g7t1bvvx.js.gz +0 -0
- package/web/chunk-gf4ky7tp.js +0 -8
- package/web/chunk-gf4ky7tp.js.br +0 -0
- package/web/chunk-gf4ky7tp.js.gz +0 -0
- package/web/chunk-gtcjwz0j.js +0 -1
- package/web/chunk-gtcjwz0j.js.br +0 -2
- package/web/chunk-gtcjwz0j.js.gz +0 -0
- package/web/chunk-gy2y4zfa.js.br +0 -0
- package/web/chunk-gy2y4zfa.js.gz +0 -0
- package/web/chunk-h1cv1kke.js.br +0 -0
- package/web/chunk-h1cv1kke.js.gz +0 -0
- package/web/chunk-h6k80vqf.js +0 -1
- package/web/chunk-h6k80vqf.js.br +0 -0
- package/web/chunk-h6k80vqf.js.gz +0 -0
- package/web/chunk-hqtm67yw.js.br +0 -0
- package/web/chunk-hqtm67yw.js.gz +0 -0
- package/web/chunk-hsgtzrkh.js.br +0 -0
- package/web/chunk-hsgtzrkh.js.gz +0 -0
- package/web/chunk-j7phw79h.js +0 -1
- package/web/chunk-j7phw79h.js.br +0 -0
- package/web/chunk-j7phw79h.js.gz +0 -0
- package/web/chunk-k69ysa0v.js.br +0 -0
- package/web/chunk-k69ysa0v.js.gz +0 -0
- package/web/chunk-k7h5g8qj.js +0 -1
- package/web/chunk-k7h5g8qj.js.br +0 -2
- package/web/chunk-k7h5g8qj.js.gz +0 -0
- package/web/chunk-k8x1xbf6.js.br +0 -0
- package/web/chunk-k8x1xbf6.js.gz +0 -0
- package/web/chunk-kbvzxsz7.js.br +0 -0
- package/web/chunk-kbvzxsz7.js.gz +0 -0
- package/web/chunk-kn9bc5z2.js.br +0 -0
- package/web/chunk-kn9bc5z2.js.gz +0 -0
- package/web/chunk-ksr360js.js.br +0 -0
- package/web/chunk-ksr360js.js.gz +0 -0
- package/web/chunk-m5nt857c.js.br +0 -0
- package/web/chunk-m5nt857c.js.gz +0 -0
- package/web/chunk-mbaw66b5.js.br +0 -0
- package/web/chunk-mbaw66b5.js.gz +0 -0
- package/web/chunk-ms7cscs9.js.br +0 -0
- package/web/chunk-ms7cscs9.js.gz +0 -0
- package/web/chunk-n59nyqcr.js.br +0 -0
- package/web/chunk-n59nyqcr.js.gz +0 -0
- package/web/chunk-n9npqkxf.js.br +0 -0
- package/web/chunk-n9npqkxf.js.gz +0 -0
- package/web/chunk-nb3jk1wk.js.br +0 -0
- package/web/chunk-nb3jk1wk.js.gz +0 -0
- package/web/chunk-ny87aq2j.js.br +0 -0
- package/web/chunk-ny87aq2j.js.gz +0 -0
- package/web/chunk-phr7yps3.js.br +0 -0
- package/web/chunk-phr7yps3.js.gz +0 -0
- package/web/chunk-ppccb30x.js.br +0 -0
- package/web/chunk-ppccb30x.js.gz +0 -0
- package/web/chunk-q17rem99.js.br +0 -0
- package/web/chunk-q17rem99.js.gz +0 -0
- package/web/chunk-qdq6wvgt.js.br +0 -0
- package/web/chunk-qdq6wvgt.js.gz +0 -0
- package/web/chunk-qhr6hegh.js.br +0 -0
- package/web/chunk-qhr6hegh.js.gz +0 -0
- package/web/chunk-qqtj88e0.js.br +0 -0
- package/web/chunk-qqtj88e0.js.gz +0 -0
- package/web/chunk-r165xpp5.js +0 -1
- package/web/chunk-r165xpp5.js.br +0 -0
- package/web/chunk-r165xpp5.js.gz +0 -0
- package/web/chunk-r4cr8rvt.js.br +0 -0
- package/web/chunk-r4cr8rvt.js.gz +0 -0
- package/web/chunk-sapy54hm.js.br +0 -0
- package/web/chunk-sapy54hm.js.gz +0 -0
- package/web/chunk-sarkb4p9.js.br +0 -0
- package/web/chunk-sarkb4p9.js.gz +0 -0
- package/web/chunk-t7vwsg9r.js.br +0 -0
- package/web/chunk-t7vwsg9r.js.gz +0 -0
- package/web/chunk-tt7j0m6m.js.br +0 -0
- package/web/chunk-tt7j0m6m.js.gz +0 -0
- package/web/chunk-va1rkfan.js +0 -1
- package/web/chunk-va1rkfan.js.br +0 -0
- package/web/chunk-va1rkfan.js.gz +0 -0
- package/web/chunk-vb3sy3hv.js.br +0 -0
- package/web/chunk-vb3sy3hv.js.gz +0 -0
- package/web/chunk-vgpyff03.js.br +0 -0
- package/web/chunk-vgpyff03.js.gz +0 -0
- package/web/chunk-w563538j.js.br +0 -0
- package/web/chunk-w563538j.js.gz +0 -0
- package/web/chunk-w71t7mes.js +0 -1
- package/web/chunk-w71t7mes.js.br +0 -0
- package/web/chunk-w71t7mes.js.gz +0 -0
- package/web/chunk-w96etr1w.js +0 -1
- package/web/chunk-w96etr1w.js.br +0 -0
- package/web/chunk-w96etr1w.js.gz +0 -0
- package/web/chunk-wrqazg2v.js.br +0 -0
- package/web/chunk-wrqazg2v.js.gz +0 -0
- package/web/chunk-xv1d350x.js.br +0 -0
- package/web/chunk-xv1d350x.js.gz +0 -0
- package/web/chunk-xw8tzrmm.js.br +0 -0
- package/web/chunk-xw8tzrmm.js.gz +0 -0
- package/web/chunk-xwsh4jx7.js +0 -1
- package/web/chunk-xwsh4jx7.js.br +0 -2
- package/web/chunk-xwsh4jx7.js.gz +0 -0
- package/web/chunk-xxk7xkrs.js +0 -1
- package/web/chunk-xxk7xkrs.js.br +0 -0
- package/web/chunk-xxk7xkrs.js.gz +0 -0
- package/web/chunk-y5zd05mz.js.br +0 -0
- package/web/chunk-y5zd05mz.js.gz +0 -0
- package/web/chunk-yg9a23mv.js.br +0 -0
- package/web/chunk-yg9a23mv.js.gz +0 -0
- package/web/chunk-ygzgrjj7.js.br +0 -0
- package/web/chunk-ygzgrjj7.js.gz +0 -0
- package/web/chunk-yp75a6yh.js.br +0 -0
- package/web/chunk-yp75a6yh.js.gz +0 -0
- package/web/chunk-zs7c2db4.js.br +0 -0
- package/web/chunk-zs7c2db4.js.gz +0 -0
- package/web/chunk-zsae1tn8.js.br +0 -0
- package/web/chunk-zsae1tn8.js.gz +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import{Ke,Ze,S}from"./chunk-xw8tzrmm.js";var bo=Ze(function(rh,ih){(function(r,e){typeof rh=="object"&&typeof ih<"u"?ih.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis<"u"?globalThis:r||self).dayjs=e()})(rh,function(){var r=1000,e=60000,o=3600000,a="millisecond",s="second",n="minute",c="hour",l="day",p="week",m="month",u="quarter",y="year",x="date",k="Invalid Date",w=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,_=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(Ct){var rt=["th","st","nd","rd"],it=Ct%100;return"["+Ct+(rt[(it-20)%10]||rt[it]||rt[0])+"]"}},q=function(Ct,rt,it){var gt=String(Ct);return!gt||gt.length>=rt?Ct:""+Array(rt+1-gt.length).join(it)+Ct},Y={s:q,z:function(Ct){var rt=-Ct.utcOffset(),it=Math.abs(rt),gt=Math.floor(it/60),et=it%60;return(rt<=0?"+":"-")+q(gt,2,"0")+":"+q(et,2,"0")},m:function Ct(rt,it){if(rt.date()<it.date())return-Ct(it,rt);var gt=12*(it.year()-rt.year())+(it.month()-rt.month()),et=rt.clone().add(gt,m),wt=it-et<0,vt=rt.clone().add(gt+(wt?-1:1),m);return+(-(gt+(it-et)/(wt?et-vt:vt-et))||0)},a:function(Ct){return Ct<0?Math.ceil(Ct)||0:Math.floor(Ct)},p:function(Ct){return{M:m,y,w:p,d:l,D:x,h:c,m:n,s,ms:a,Q:u}[Ct]||String(Ct||"").toLowerCase().replace(/s$/,"")},u:function(Ct){return Ct===void 0}},V="en",Q={};Q[V]=M;var tt="$isDayjsObject",at=function(Ct){return Ct instanceof Bt||!(!Ct||!Ct[tt])},ot=function Ct(rt,it,gt){var et;if(!rt)return V;if(typeof rt=="string"){var wt=rt.toLowerCase();Q[wt]&&(et=wt),it&&(Q[wt]=it,et=wt);var vt=rt.split("-");if(!et&&vt.length>1)return Ct(vt[0])}else{var Xt=rt.name;Q[Xt]=rt,et=Xt}return!gt&&et&&(V=et),et||!gt&&V},ht=function(Ct,rt){if(at(Ct))return Ct.clone();var it=typeof rt=="object"?rt:{};return it.date=Ct,it.args=arguments,new Bt(it)},yt=Y;yt.l=ot,yt.i=at,yt.w=function(Ct,rt){return ht(Ct,{locale:rt.$L,utc:rt.$u,x:rt.$x,$offset:rt.$offset})};var Bt=function(){function Ct(it){this.$L=ot(it.locale,null,!0),this.parse(it),this.$x=this.$x||it.x||{},this[tt]=!0}var rt=Ct.prototype;return rt.parse=function(it){this.$d=function(gt){var{date:et,utc:wt}=gt;if(et===null)return new Date(NaN);if(yt.u(et))return new Date;if(et instanceof Date)return new Date(et);if(typeof et=="string"&&!/Z$/i.test(et)){var vt=et.match(w);if(vt){var Xt=vt[2]-1||0,jt=(vt[7]||"0").substring(0,3);return wt?new Date(Date.UTC(vt[1],Xt,vt[3]||1,vt[4]||0,vt[5]||0,vt[6]||0,jt)):new Date(vt[1],Xt,vt[3]||1,vt[4]||0,vt[5]||0,vt[6]||0,jt)}}return new Date(et)}(it),this.init()},rt.init=function(){var it=this.$d;this.$y=it.getFullYear(),this.$M=it.getMonth(),this.$D=it.getDate(),this.$W=it.getDay(),this.$H=it.getHours(),this.$m=it.getMinutes(),this.$s=it.getSeconds(),this.$ms=it.getMilliseconds()},rt.$utils=function(){return yt},rt.isValid=function(){return this.$d.toString()!==k},rt.isSame=function(it,gt){var et=ht(it);return this.startOf(gt)<=et&&et<=this.endOf(gt)},rt.isAfter=function(it,gt){return ht(it)<this.startOf(gt)},rt.isBefore=function(it,gt){return this.endOf(gt)<ht(it)},rt.$g=function(it,gt,et){return yt.u(it)?this[gt]:this.set(et,it)},rt.unix=function(){return Math.floor(this.valueOf()/1000)},rt.valueOf=function(){return this.$d.getTime()},rt.startOf=function(it,gt){var et=this,wt=!!yt.u(gt)||gt,vt=yt.p(it),Xt=function(re,ae){var ne=yt.w(et.$u?Date.UTC(et.$y,ae,re):new Date(et.$y,ae,re),et);return wt?ne:ne.endOf(l)},jt=function(re,ae){return yt.w(et.toDate()[re].apply(et.toDate("s"),(wt?[0,0,0,0]:[23,59,59,999]).slice(ae)),et)},se=this.$W,oe=this.$M,fe=this.$D,ge="set"+(this.$u?"UTC":"");switch(vt){case y:return wt?Xt(1,0):Xt(31,11);case m:return wt?Xt(1,oe):Xt(0,oe+1);case p:var he=this.$locale().weekStart||0,Ut=(se<he?se+7:se)-he;return Xt(wt?fe-Ut:fe+(6-Ut),oe);case l:case x:return jt(ge+"Hours",0);case c:return jt(ge+"Minutes",1);case n:return jt(ge+"Seconds",2);case s:return jt(ge+"Milliseconds",3);default:return this.clone()}},rt.endOf=function(it){return this.startOf(it,!1)},rt.$set=function(it,gt){var et,wt=yt.p(it),vt="set"+(this.$u?"UTC":""),Xt=(et={},et[l]=vt+"Date",et[x]=vt+"Date",et[m]=vt+"Month",et[y]=vt+"FullYear",et[c]=vt+"Hours",et[n]=vt+"Minutes",et[s]=vt+"Seconds",et[a]=vt+"Milliseconds",et)[wt],jt=wt===l?this.$D+(gt-this.$W):gt;if(wt===m||wt===y){var se=this.clone().set(x,1);se.$d[Xt](jt),se.init(),this.$d=se.set(x,Math.min(this.$D,se.daysInMonth())).$d}else Xt&&this.$d[Xt](jt);return this.init(),this},rt.set=function(it,gt){return this.clone().$set(it,gt)},rt.get=function(it){return this[yt.p(it)]()},rt.add=function(it,gt){var et,wt=this;it=Number(it);var vt=yt.p(gt),Xt=function(oe){var fe=ht(wt);return yt.w(fe.date(fe.date()+Math.round(oe*it)),wt)};if(vt===m)return this.set(m,this.$M+it);if(vt===y)return this.set(y,this.$y+it);if(vt===l)return Xt(1);if(vt===p)return Xt(7);var jt=(et={},et[n]=e,et[c]=o,et[s]=r,et)[vt]||1,se=this.$d.getTime()+it*jt;return yt.w(se,this)},rt.subtract=function(it,gt){return this.add(-1*it,gt)},rt.format=function(it){var gt=this,et=this.$locale();if(!this.isValid())return et.invalidDate||k;var wt=it||"YYYY-MM-DDTHH:mm:ssZ",vt=yt.z(this),Xt=this.$H,jt=this.$m,se=this.$M,{weekdays:oe,months:fe,meridiem:ge}=et,he=function(ae,ne,Le,ve){return ae&&(ae[ne]||ae(gt,wt))||Le[ne].slice(0,ve)},Ut=function(ae){return yt.s(Xt%12||12,ae,"0")},re=ge||function(ae,ne,Le){var ve=ae<12?"AM":"PM";return Le?ve.toLowerCase():ve};return wt.replace(_,function(ae,ne){return ne||function(Le){switch(Le){case"YY":return String(gt.$y).slice(-2);case"YYYY":return yt.s(gt.$y,4,"0");case"M":return se+1;case"MM":return yt.s(se+1,2,"0");case"MMM":return he(et.monthsShort,se,fe,3);case"MMMM":return he(fe,se);case"D":return gt.$D;case"DD":return yt.s(gt.$D,2,"0");case"d":return String(gt.$W);case"dd":return he(et.weekdaysMin,gt.$W,oe,2);case"ddd":return he(et.weekdaysShort,gt.$W,oe,3);case"dddd":return oe[gt.$W];case"H":return String(Xt);case"HH":return yt.s(Xt,2,"0");case"h":return Ut(1);case"hh":return Ut(2);case"a":return re(Xt,jt,!0);case"A":return re(Xt,jt,!1);case"m":return String(jt);case"mm":return yt.s(jt,2,"0");case"s":return String(gt.$s);case"ss":return yt.s(gt.$s,2,"0");case"SSS":return yt.s(gt.$ms,3,"0");case"Z":return vt}return null}(ae)||vt.replace(":","")})},rt.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},rt.diff=function(it,gt,et){var wt,vt=this,Xt=yt.p(gt),jt=ht(it),se=(jt.utcOffset()-this.utcOffset())*e,oe=this-jt,fe=function(){return yt.m(vt,jt)};switch(Xt){case y:wt=fe()/12;break;case m:wt=fe();break;case u:wt=fe()/3;break;case p:wt=(oe-se)/604800000;break;case l:wt=(oe-se)/86400000;break;case c:wt=oe/o;break;case n:wt=oe/e;break;case s:wt=oe/r;break;default:wt=oe}return et?wt:yt.a(wt)},rt.daysInMonth=function(){return this.endOf(m).$D},rt.$locale=function(){return Q[this.$L]},rt.locale=function(it,gt){if(!it)return this.$L;var et=this.clone(),wt=ot(it,gt,!0);return wt&&(et.$L=wt),et},rt.clone=function(){return yt.w(this.$d,this)},rt.toDate=function(){return new Date(this.valueOf())},rt.toJSON=function(){return this.isValid()?this.toISOString():null},rt.toISOString=function(){return this.$d.toISOString()},rt.toString=function(){return this.$d.toUTCString()},Ct}(),kt=Bt.prototype;return ht.prototype=kt,[["$ms",a],["$s",s],["$m",n],["$H",c],["$W",l],["$M",m],["$y",y],["$D",x]].forEach(function(Ct){kt[Ct[1]]=function(rt){return this.$g(rt,Ct[0],Ct[1])}}),ht.extend=function(Ct,rt){return Ct.$i||(Ct(rt,Bt,ht),Ct.$i=!0),ht},ht.locale=ot,ht.isDayjs=at,ht.unix=function(Ct){return ht(1000*Ct)},ht.en=Q[V],ht.Ls=Q,ht.p={},ht})});var sm=Ze(function(im){Object.defineProperty(im,"__esModule",{value:!0});im.BLANK_URL=im.relativeFirstCharacters=im.whitespaceEscapeCharsRegex=im.urlSchemeRegex=im.ctrlCharactersRegex=im.htmlCtrlEntityRegex=im.htmlEntitiesRegex=im.invalidProtocolRegex=void 0;im.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im;im.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g;im.htmlCtrlEntityRegex=/&(newline|tab);/gi;im.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim;im.urlSchemeRegex=/^.+(:|:)/gim;im.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g;im.relativeFirstCharacters=[".","/"];im.BLANK_URL="about:blank"});var la=Ze(function(nm){Object.defineProperty(nm,"__esModule",{value:!0});nm.sanitizeUrl=T2;var ur=sm();function k2(r){return ur.relativeFirstCharacters.indexOf(r[0])>-1}function w2(r){var e=r.replace(ur.ctrlCharactersRegex,"");return e.replace(ur.htmlEntitiesRegex,function(o,a){return String.fromCharCode(a)})}function S2(r){return URL.canParse(r)}function am(r){try{return decodeURIComponent(r)}catch(e){return r}}function T2(r){if(!r)return ur.BLANK_URL;var e,o=am(r.trim());do o=w2(o).replace(ur.htmlCtrlEntityRegex,"").replace(ur.ctrlCharactersRegex,"").replace(ur.whitespaceEscapeCharsRegex,"").trim(),o=am(o),e=o.match(ur.ctrlCharactersRegex)||o.match(ur.htmlEntitiesRegex)||o.match(ur.htmlCtrlEntityRegex)||o.match(ur.whitespaceEscapeCharsRegex);while(e&&e.length>0);var a=o;if(!a)return ur.BLANK_URL;if(k2(a))return a;var s=a.trimStart(),n=s.match(ur.urlSchemeRegex);if(!n)return a;var c=n[0].toLowerCase().trim();if(ur.invalidProtocolRegex.test(c))return ur.BLANK_URL;var l=s.replace(/\\/g,"/");if(c==="mailto:"||c.includes("://"))return l;if(c==="http:"||c==="https:"){if(!S2(l))return ur.BLANK_URL;var p=new URL(l);return p.protocol=p.protocol.toLowerCase(),p.hostname=p.hostname.toLowerCase(),p.toString()}return l}});var _d=Object.defineProperty,t=(r,e)=>_d(r,"name",{value:e,configurable:!0}),er=(r,e)=>{for(var o in e)_d(r,o,{get:e[o],enumerable:!0})};var Bd=Ke(bo(),1),yi={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},i={trace:t((...r)=>{},"trace"),debug:t((...r)=>{},"debug"),info:t((...r)=>{},"info"),warn:t((...r)=>{},"warn"),error:t((...r)=>{},"error"),fatal:t((...r)=>{},"fatal")},Ti=t(function(r="fatal"){let e=yi.fatal;if(typeof r==="string"){if(r.toLowerCase()in yi)e=yi[r]}else if(typeof r==="number")e=r;if(i.trace=()=>{},i.debug=()=>{},i.info=()=>{},i.warn=()=>{},i.error=()=>{},i.fatal=()=>{},e<=yi.fatal)i.fatal=console.error?console.error.bind(console,Or("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",Or("FATAL"));if(e<=yi.error)i.error=console.error?console.error.bind(console,Or("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",Or("ERROR"));if(e<=yi.warn)i.warn=console.warn?console.warn.bind(console,Or("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",Or("WARN"));if(e<=yi.info)i.info=console.info?console.info.bind(console,Or("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",Or("INFO"));if(e<=yi.debug)i.debug=console.debug?console.debug.bind(console,Or("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Or("DEBUG"));if(e<=yi.trace)i.trace=console.debug?console.debug.bind(console,Or("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Or("TRACE"))},"setLogLevel"),Or=t((r)=>`%c${Bd.default().format("ss.SSS")} : ${r} : `,"format");var Cn={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:(r)=>r>=255?255:r<0?0:r,g:(r)=>r>=255?255:r<0?0:r,b:(r)=>r>=255?255:r<0?0:r,h:(r)=>r%360,s:(r)=>r>=100?100:r<0?0:r,l:(r)=>r>=100?100:r<0?0:r,a:(r)=>r>=1?1:r<0?0:r},toLinear:(r)=>{let e=r/255;return r>0.03928?Math.pow((e+0.055)/1.055,2.4):e/12.92},hue2rgb:(r,e,o)=>{if(o<0)o+=1;if(o>1)o-=1;if(o<0.16666666666666666)return r+(e-r)*6*o;if(o<0.5)return e;if(o<0.6666666666666666)return r+(e-r)*(0.6666666666666666-o)*6;return r},hsl2rgb:({h:r,s:e,l:o},a)=>{if(!e)return o*2.55;r/=360,e/=100,o/=100;let s=o<0.5?o*(1+e):o+e-o*e,n=2*o-s;switch(a){case"r":return Cn.hue2rgb(n,s,r+0.3333333333333333)*255;case"g":return Cn.hue2rgb(n,s,r)*255;case"b":return Cn.hue2rgb(n,s,r-0.3333333333333333)*255}},rgb2hsl:({r,g:e,b:o},a)=>{r/=255,e/=255,o/=255;let s=Math.max(r,e,o),n=Math.min(r,e,o),c=(s+n)/2;if(a==="l")return c*100;if(s===n)return 0;let l=s-n,p=c>0.5?l/(2-s-n):l/(s+n);if(a==="s")return p*100;switch(s){case r:return((e-o)/l+(e<o?6:0))*60;case e:return((o-r)/l+2)*60;case o:return((r-e)/l+4)*60;default:return-1}}},vd=Cn;var rC={clamp:(r,e,o)=>{if(e>o)return Math.min(e,Math.max(o,r));return Math.min(o,Math.max(e,r))},round:(r)=>Math.round(r*10000000000)/10000000000},Ld=rC;var iC={dec2hex:(r)=>{let e=Math.round(r).toString(16);return e.length>1?e:`0${e}`}},Fd=iC;var oC={channel:vd,lang:Ld,unit:Fd},X=oC;var xi={};for(let r=0;r<=255;r++)xi[r]=X.unit.dec2hex(r);var je={ALL:0,RGB:1,HSL:2};class Ad{constructor(){this.type=je.ALL}get(){return this.type}set(r){if(this.type&&this.type!==r)throw Error("Cannot change both RGB and HSL channels at the same time");this.type=r}reset(){this.type=je.ALL}is(r){return this.type===r}}var Md=Ad;class Ed{constructor(r,e){this.color=e,this.changed=!1,this.data=r,this.type=new Md}set(r,e){return this.color=e,this.changed=!1,this.data=r,this.type.type=je.ALL,this}_ensureHSL(){let r=this.data,{h:e,s:o,l:a}=r;if(e===void 0)r.h=X.channel.rgb2hsl(r,"h");if(o===void 0)r.s=X.channel.rgb2hsl(r,"s");if(a===void 0)r.l=X.channel.rgb2hsl(r,"l")}_ensureRGB(){let r=this.data,{r:e,g:o,b:a}=r;if(e===void 0)r.r=X.channel.hsl2rgb(r,"r");if(o===void 0)r.g=X.channel.hsl2rgb(r,"g");if(a===void 0)r.b=X.channel.hsl2rgb(r,"b")}get r(){let r=this.data,e=r.r;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"r")}get g(){let r=this.data,e=r.g;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"g")}get b(){let r=this.data,e=r.b;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"b")}get h(){let r=this.data,e=r.h;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"h")}get s(){let r=this.data,e=r.s;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"s")}get l(){let r=this.data,e=r.l;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"l")}get a(){return this.data.a}set r(r){this.type.set(je.RGB),this.changed=!0,this.data.r=r}set g(r){this.type.set(je.RGB),this.changed=!0,this.data.g=r}set b(r){this.type.set(je.RGB),this.changed=!0,this.data.b=r}set h(r){this.type.set(je.HSL),this.changed=!0,this.data.h=r}set s(r){this.type.set(je.HSL),this.changed=!0,this.data.s=r}set l(r){this.type.set(je.HSL),this.changed=!0,this.data.l=r}set a(r){this.changed=!0,this.data.a=r}}var Od=Ed;var sC=new Od({r:0,g:0,b:0,a:0},"transparent"),ji=sC;var Id={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:(r)=>{if(r.charCodeAt(0)!==35)return;let e=r.match(Id.re);if(!e)return;let o=e[1],a=parseInt(o,16),s=o.length,n=s%4===0,c=s>4,l=c?1:17,p=c?8:4,m=n?0:-1,u=c?255:15;return ji.set({r:(a>>p*(m+3)&u)*l,g:(a>>p*(m+2)&u)*l,b:(a>>p*(m+1)&u)*l,a:n?(a&u)*l/255:1},r)},stringify:(r)=>{let{r:e,g:o,b:a,a:s}=r;if(s<1)return`#${xi[Math.round(e)]}${xi[Math.round(o)]}${xi[Math.round(a)]}${xi[Math.round(s*255)]}`;else return`#${xi[Math.round(e)]}${xi[Math.round(o)]}${xi[Math.round(a)]}`}},to=Id;var bn={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:(r)=>{let e=r.match(bn.hueRe);if(e){let[,o,a]=e;switch(a){case"grad":return X.channel.clamp.h(parseFloat(o)*0.9);case"rad":return X.channel.clamp.h(parseFloat(o)*180/Math.PI);case"turn":return X.channel.clamp.h(parseFloat(o)*360)}}return X.channel.clamp.h(parseFloat(r))},parse:(r)=>{let e=r.charCodeAt(0);if(e!==104&&e!==72)return;let o=r.match(bn.re);if(!o)return;let[,a,s,n,c,l]=o;return ji.set({h:bn._hue2deg(a),s:X.channel.clamp.s(parseFloat(s)),l:X.channel.clamp.l(parseFloat(n)),a:c?X.channel.clamp.a(l?parseFloat(c)/100:parseFloat(c)):1},r)},stringify:(r)=>{let{h:e,s:o,l:a,a:s}=r;if(s<1)return`hsla(${X.lang.round(e)}, ${X.lang.round(o)}%, ${X.lang.round(a)}%, ${s})`;else return`hsl(${X.lang.round(e)}, ${X.lang.round(o)}%, ${X.lang.round(a)}%)`}},Ls=bn;var Sn={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:(r)=>{r=r.toLowerCase();let e=Sn.colors[r];if(!e)return;return to.parse(e)},stringify:(r)=>{let e=to.stringify(r);for(let o in Sn.colors)if(Sn.colors[o]===e)return o;return}},oh=Sn;var $d={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:(r)=>{let e=r.charCodeAt(0);if(e!==114&&e!==82)return;let o=r.match($d.re);if(!o)return;let[,a,s,n,c,l,p,m,u]=o;return ji.set({r:X.channel.clamp.r(s?parseFloat(a)*2.55:parseFloat(a)),g:X.channel.clamp.g(c?parseFloat(n)*2.55:parseFloat(n)),b:X.channel.clamp.b(p?parseFloat(l)*2.55:parseFloat(l)),a:m?X.channel.clamp.a(u?parseFloat(m)/100:parseFloat(m)):1},r)},stringify:(r)=>{let{r:e,g:o,b:a,a:s}=r;if(s<1)return`rgba(${X.lang.round(e)}, ${X.lang.round(o)}, ${X.lang.round(a)}, ${X.lang.round(s)})`;else return`rgb(${X.lang.round(e)}, ${X.lang.round(o)}, ${X.lang.round(a)})`}},Fs=$d;var aC={format:{keyword:oh,hex:to,rgb:Fs,rgba:Fs,hsl:Ls,hsla:Ls},parse:(r)=>{if(typeof r!=="string")return r;let e=to.parse(r)||Fs.parse(r)||Ls.parse(r)||oh.parse(r);if(e)return e;throw Error(`Unsupported color format: "${r}"`)},stringify:(r)=>{if(!r.changed&&r.color)return r.color;if(r.type.is(je.HSL)||r.data.r===void 0)return Ls.stringify(r);else if(r.a<1||!Number.isInteger(r.r)||!Number.isInteger(r.g)||!Number.isInteger(r.b))return Fs.stringify(r);else return to.stringify(r)}},pt=aC;var nC=(r,e)=>{let o=pt.parse(r);for(let a in e)o[a]=X.channel.clamp[a](e[a]);return pt.stringify(o)},Tn=nC;var lC=(r,e,o=0,a=1)=>{if(typeof r!=="number")return Tn(r,{a:e});let s=ji.set({r:X.channel.clamp.r(r),g:X.channel.clamp.g(e),b:X.channel.clamp.b(o),a:X.channel.clamp.a(a)});return pt.stringify(s)},Pe=lC;var hC=(r)=>{let{r:e,g:o,b:a}=pt.parse(r),s=0.2126*X.channel.toLinear(e)+0.7152*X.channel.toLinear(o)+0.0722*X.channel.toLinear(a);return X.lang.round(s)},Dd=hC;var cC=(r)=>Dd(r)>=0.5,Pd=cC;var uC=(r)=>!Pd(r),pe=uC;var fC=(r,e,o)=>{let a=pt.parse(r),s=a[e],n=X.channel.clamp[e](s+o);if(s!==n)a[e]=n;return pt.stringify(a)},ja=fC;var dC=(r,e)=>ja(r,"l",e),f=dC;var pC=(r,e)=>ja(r,"l",-e),h=pC;var gC=(r,e)=>{let o=pt.parse(r),a={};for(let s in e){if(!e[s])continue;a[s]=o[s]+e[s]}return Tn(r,a)},z=gC;var mC=(r,e,o=50)=>{let{r:a,g:s,b:n,a:c}=pt.parse(r),{r:l,g:p,b:m,a:u}=pt.parse(e),y=o/100,x=y*2-1,k=c-u,_=((x*k===-1?x:(x+k)/(1+x*k))+1)/2,M=1-_,q=a*_+l*M,Y=s*_+p*M,V=n*_+m*M,Q=c*y+u*(1-y);return Pe(q,Y,V,Q)},Rd=mC;var yC=(r,e=100)=>{let o=pt.parse(r);return o.r=255-o.r,o.g=255-o.g,o.b=255-o.b,Rd(o,r,e)},nt=yC;/*! @license DOMPurify 3.4.17 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.17/LICENSE */function xC(r,e){this.v=r,this.k=e}function qd(r,e){(e==null||e>r.length)&&(e=r.length);for(var o=0,a=Array(e);o<e;o++)a[o]=r[o];return a}function CC(r){if(Array.isArray(r))return r}function bC(r,e){var o=r==null?null:typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(o!=null){var a,s,n,c,l=[],p=!0,m=!1;try{if(n=(o=o.call(r)).next,e===0){if(Object(o)!==o)return;p=!1}else for(;!(p=(a=n.call(o)).done)&&(l.push(a.value),l.length!==e);p=!0);}catch(u){m=!0,s=u}finally{try{if(!p&&o.return!=null&&(c=o.return(),Object(c)!==c))return}finally{if(m)throw s}}return l}}function kC(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */function wC(r,e){return CC(r)||bC(r,e)||SC(r,e)||kC()}function SC(r,e){if(r){if(typeof r=="string")return qd(r,e);var o={}.toString.call(r).slice(8,-1);return o==="Object"&&r.constructor&&(o=r.constructor.name),o==="Map"||o==="Set"?Array.from(r):o==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?qd(r,e):void 0}}function vn(r){var e,o;function a(n,c){try{var l=r[n](c),p=l.value,m=p instanceof xC;Promise.resolve(m?p.v:p).then(function(u){if(m){var y=n==="return"&&p.k?n:"next";if(!p.k||u.done)return a(y,u);u=r[y](u).value}s(!!l.done,u)},function(u){a("throw",u)})}catch(u){s(2,u)}}function s(n,c){n===2?e.reject(c):e.resolve({value:c,done:n}),(e=e.next)?a(e.key,e.arg):o=null}this._invoke=function(n,c){return new Promise(function(l,p){var m={key:n,arg:c,resolve:l,reject:p,next:null};o?o=o.next=m:(e=o=m,a(n,c))})},typeof r.return!="function"&&(this.return=void 0)}vn.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},vn.prototype.next=function(r){return this._invoke("next",r)},vn.prototype.throw=function(r){return this._invoke("throw",r)},vn.prototype.return=function(r){return this._invoke("return",r)};var{entries:tp,setPrototypeOf:Nd,isFrozen:TC,getPrototypeOf:ep,getOwnPropertyDescriptor:rp,freeze:Ve,seal:ir,create:vo}=Object,ip=typeof Reflect<"u"&&Reflect,{apply:ph,construct:gh}=ip;if(!Ve)Ve=function(e){return e};if(!ir)ir=function(e){return e};if(!ph)ph=function(e,o){for(var a=arguments.length,s=Array(a>2?a-2:0),n=2;n<a;n++)s[n-2]=arguments[n];return e.apply(o,s)};if(!gh)gh=function(e){for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return new e(...a)};var Ci=Fe(Array.prototype.forEach);Array.prototype.indexOf;var _C=Fe(Array.prototype.lastIndexOf),Wd=Fe(Array.prototype.pop),As=Fe(Array.prototype.push),BC=Fe(Array.prototype.slice),vC=Fe(Array.prototype.splice),Qo=Array.isArray,sh=op(Set),ah=Fe(Set.prototype.add),Ms=Fe(Set.prototype.has),eo=Fe(String.prototype.toLowerCase),nh=Fe(String.prototype.toString),zd=Fe(String.prototype.match),Es=Fe(String.prototype.replace),Hd=Fe(String.prototype.indexOf),LC=Fe(String.prototype.trim),FC=Fe(Number.prototype.toString),AC=Fe(Boolean.prototype.toString),Yd=typeof BigInt>"u"?null:Fe(BigInt.prototype.toString),Ud=typeof Symbol>"u"?null:Fe(Symbol.prototype.toString),wr=Fe(Object.prototype.hasOwnProperty),Os=Fe(Object.prototype.toString),Je=Fe(RegExp.prototype.test),bi=op(TypeError);function Fe(r){return function(e){if(e instanceof RegExp)e.lastIndex=0;for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return ph(r,e,a)}}function op(r){return function(){for(var e=arguments.length,o=Array(e),a=0;a<e;a++)o[a]=arguments[a];return gh(r,o)}}function xe(r,e){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:eo;if(Nd)Nd(r,null);if(!Qo(e))return r;let a=e.length;while(a--){let s=e[a];if(typeof s==="string"){let n=o(s);if(n!==s){if(!TC(e))e[a]=n;s=n}}r[s]=!0}return r}function MC(r){for(let e=0;e<r.length;e++)if(!wr(r,e))r[e]=null;return r}function _r(r){let e=vo(null);for(let a of tp(r)){var o=wC(a,2);let s=o[0],n=o[1];if(wr(r,s))if(Qo(n))e[s]=MC(n);else if(n&&typeof n==="object"&&n.constructor===Object)e[s]=_r(n);else e[s]=n}return e}function EC(r){switch(typeof r){case"string":return r;case"number":return FC(r);case"boolean":return AC(r);case"bigint":return Yd?Yd(r):"0";case"symbol":return Ud?Ud(r):"Symbol()";case"undefined":return Os(r);case"function":case"object":{if(r===null)return Os(r);let e=r,o=Ir(e,"toString");if(typeof o==="function"){let a=o(e);return typeof a==="string"?a:Os(a)}return Os(r)}default:return Os(r)}}function Ir(r,e){while(r!==null){let a=rp(r,e);if(a){if(a.get)return Fe(a.get);if(typeof a.value==="function")return Fe(a.value)}r=ep(r)}function o(){return null}return o}function OC(r,e){while(r!==null){let o=rp(r,e);if(o)return o.get?Fe(o.get):null;r=ep(r)}return null}function IC(r){try{return Je(r,""),!0}catch(e){return!1}}var jd=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),lh=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),hh=Ve(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),$C=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),ch=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),DC=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Gd=Ve(["#text"]),Xd=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),uh=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dominant-baseline","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","pointer-events","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Vd=Ve(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Ln=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),PC=ir(/{{[\w\W]*|^[\w\W]*}}/g),RC=ir(/<%[\w\W]*|^[\w\W]*%>/g),qC=ir(/\${[\w\W]*/g),NC=ir(/^data-[\-\w.\u00B7-\uFFFF]+$/),WC=ir(/^aria-[\-\w]+$/),Kd=ir(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),zC=ir(/^(?:\w+script|data):/i),HC=ir(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),YC=ir(/^html$/i),UC=ir(/^[a-z][.\w]*(-[.\w]+)+$/i),fh=ir(/<[/\w!]/g),Zd=ir(/<[/\w]/g),jC=ir(/<\/no(script|embed|frames)/i),Qd=ir(/\/>/i),We={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},GC=Ve(xe({},["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"])),XC=function(){return typeof window>"u"?null:window},VC=function(e,o){if(typeof e!=="object"||typeof e.createPolicy!=="function")return null;let a=null,s="data-tt-policy-suffix";if(o&&o.hasAttribute(s))a=o.getAttribute(s);let n="dompurify"+(a?"#"+a:"");try{return e.createPolicy(n,{createHTML(c){return c},createScriptURL(c){return c}})}catch(c){return console.warn("TrustedTypes policy "+n+" could not be created."),null}},Jd=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Gi=function(e,o,a,s){return wr(e,o)&&Qo(e[o])?xe(s.base?_r(s.base):{},e[o],s.transform):a},dh=function(e,o,a){let s=wr(e,o)?e[o]:void 0;return s&&typeof s==="object"?_r(s):a()};function sp(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:XC(),e=(zt)=>sp(zt);if(e.version="3.4.17",e.removed=[],!r||!r.document||r.document.nodeType!==We.document||!r.Element)return e.isSupported=!1,e;let o=r.document,a=o,s=a.currentScript;r.DocumentFragment;let{HTMLTemplateElement:n,Node:c,Element:l,NodeFilter:p}=r;r.NamedNodeMap===void 0&&(r.NamedNodeMap||r.MozNamedAttrMap),r.HTMLFormElement;let{DOMParser:m,trustedTypes:u}=r,y=l.prototype,x=Ir(y,"cloneNode"),k=Ir(y,"remove"),w=Ir(y,"removeAttributeNode"),_=Ir(y,"nextSibling"),M=Ir(y,"childNodes"),q=Ir(y,"parentNode"),Y=Ir(y,"shadowRoot"),V=Ir(y,"attributes"),Q=c&&c.prototype?Ir(c.prototype,"nodeType"):null,tt=c&&c.prototype?Ir(c.prototype,"nodeName"):null,at=c&&c.prototype?Ir(c.prototype,"ownerDocument"):null,ot=function(K){return Q?Q(K):K.nodeType},ht=function(K){return tt?tt(K):K.nodeName},yt=OC(y,"namespaceURI"),Bt=function(K){return yt?yt(K):K.namespaceURI};if(typeof n==="function"){let zt=o.createElement("template");if(zt.content&&zt.content.ownerDocument)o=zt.content.ownerDocument}let kt,Ct="",rt,it=!1,gt=0,et=function(){if(gt>0)throw bi('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},wt=function(K){et(),gt++;try{return kt.createHTML(K)}finally{gt--}},vt=function(K){et(),gt++;try{return kt.createScriptURL(K)}finally{gt--}},Xt=function(){if(!it)rt=VC(u,s),it=!0;return rt},jt=o,{implementation:se,createNodeIterator:oe,createDocumentFragment:fe,getElementsByTagName:ge}=jt,he=a.importNode,Ut=Jd();e.isSupported=typeof tp==="function"&&typeof q==="function"&&se&&se.createHTMLDocument!==void 0;let re=PC,ae=RC,ne=qC,Le=NC,ve=WC,Dr=zC,di=HC,Mr=UC,Ai=Kd,_e=null,Cr=xe({},[...jd,...lh,...hh,...ch,...Gd]),be=null,pi=xe({},[...Xd,...uh,...Vd,...Ln]),Qe=Object.seal(vo(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Er=null,qi=null,Ne=Object.seal(vo(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),Wi=!0,Xr=!0,gi=!1,mi=!0,b=!1,ft=!0,Tt=!1,At=!1,St=null,Yt=null,G=!1,mt=!1,Dt=!1,Ft=!1,Mt=!0,Ht=!1,Wt="user-content-",Qt=!0,Zt=!1,Jt=null,ee={},de=null,Be=xe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]),Ts=null,zi=xe({},["audio","video","img","source","image","track"]),Hi=null,ld=xe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),fn="http://www.w3.org/1998/Math/MathML",gn="http://www.w3.org/2000/svg",Kr="http://www.w3.org/1999/xhtml",fo=Kr,zl=!1,Hl=null,D0=xe({},[fn,gn,Kr],nh),hd=Ve(["mi","mo","mn","ms","mtext"]),Yl=xe({},hd),cd=Ve(["annotation-xml"]),Ul=xe({},cd),P0=xe({},["title","style","font","a","script"]),_s=null,R0=["application/xhtml+xml","text/html"],q0="text/html",De=null,po=null,N0=o.createElement("form"),ud=function(K){return K instanceof RegExp||K instanceof Function},jl=function(){let K=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(po&&po===K)return;if(!K||typeof K!=="object")K={};K=_r(K),_s=R0.indexOf(K.PARSER_MEDIA_TYPE)===-1?q0:K.PARSER_MEDIA_TYPE,De=_s==="application/xhtml+xml"?nh:eo,_e=Gi(K,"ALLOWED_TAGS",Cr,{transform:De}),be=Gi(K,"ALLOWED_ATTR",pi,{transform:De}),Hl=Gi(K,"ALLOWED_NAMESPACES",D0,{transform:nh}),Hi=Gi(K,"ADD_URI_SAFE_ATTR",ld,{transform:De,base:ld}),Ts=Gi(K,"ADD_DATA_URI_TAGS",zi,{transform:De,base:zi}),de=Gi(K,"FORBID_CONTENTS",Be,{transform:De}),Er=Gi(K,"FORBID_TAGS",_r({}),{transform:De}),qi=Gi(K,"FORBID_ATTR",_r({}),{transform:De}),ee=wr(K,"USE_PROFILES")?K.USE_PROFILES&&typeof K.USE_PROFILES==="object"?_r(K.USE_PROFILES):K.USE_PROFILES:!1,Wi=K.ALLOW_ARIA_ATTR!==!1,Xr=K.ALLOW_DATA_ATTR!==!1,gi=K.ALLOW_UNKNOWN_PROTOCOLS||!1,mi=K.ALLOW_SELF_CLOSE_IN_ATTR!==!1,b=K.SAFE_FOR_TEMPLATES||!1,ft=K.SAFE_FOR_XML!==!1,Tt=K.WHOLE_DOCUMENT||!1,mt=K.RETURN_DOM||!1,Dt=K.RETURN_DOM_FRAGMENT||!1,Ft=K.RETURN_TRUSTED_TYPE||!1,G=K.FORCE_BODY||!1,Mt=K.SANITIZE_DOM!==!1,Ht=K.SANITIZE_NAMED_PROPS||!1,Qt=K.KEEP_CONTENT!==!1,Zt=K.IN_PLACE||!1,Ai=IC(K.ALLOWED_URI_REGEXP)?K.ALLOWED_URI_REGEXP:Kd,fo=typeof K.NAMESPACE==="string"?K.NAMESPACE:Kr,Yl=dh(K,"MATHML_TEXT_INTEGRATION_POINTS",()=>xe({},hd)),Ul=dh(K,"HTML_INTEGRATION_POINTS",()=>xe({},cd));let lt=dh(K,"CUSTOM_ELEMENT_HANDLING",()=>vo(null));if(Qe=vo(null),wr(lt,"tagNameCheck")&&ud(lt.tagNameCheck))Qe.tagNameCheck=lt.tagNameCheck;if(wr(lt,"attributeNameCheck")&&ud(lt.attributeNameCheck))Qe.attributeNameCheck=lt.attributeNameCheck;if(wr(lt,"allowCustomizedBuiltInElements")&&typeof lt.allowCustomizedBuiltInElements==="boolean")Qe.allowCustomizedBuiltInElements=lt.allowCustomizedBuiltInElements;if(ir(Qe),b)Xr=!1;if(Dt)mt=!0;if(ee){if(_e=xe({},Gd),be=vo(null),ee.html===!0)xe(_e,jd),xe(be,Xd);if(ee.svg===!0)xe(_e,lh),xe(be,uh),xe(be,Ln);if(ee.svgFilters===!0)xe(_e,hh),xe(be,uh),xe(be,Ln);if(ee.mathMl===!0)xe(_e,ch),xe(be,Vd),xe(be,Ln)}if(Ne.tagCheck=null,Ne.attributeCheck=null,wr(K,"ADD_TAGS")){if(typeof K.ADD_TAGS==="function")Ne.tagCheck=K.ADD_TAGS;else if(Qo(K.ADD_TAGS)){if(_e===Cr)_e=_r(_e);xe(_e,K.ADD_TAGS,De)}}if(wr(K,"ADD_ATTR")){if(typeof K.ADD_ATTR==="function")Ne.attributeCheck=K.ADD_ATTR;else if(Qo(K.ADD_ATTR)){if(be===pi)be=_r(be);xe(be,K.ADD_ATTR,De)}}if(wr(K,"ADD_FORBID_CONTENTS")&&Qo(K.ADD_FORBID_CONTENTS)){if(de===Be)de=_r(de);xe(de,K.ADD_FORBID_CONTENTS,De)}if(Qt)_e["#text"]=!0;if(Tt)xe(_e,["html","head","body"]);if(_e.table)xe(_e,["tbody"]),delete Er.tbody;if(K.TRUSTED_TYPES_POLICY){if(typeof K.TRUSTED_TYPES_POLICY.createHTML!=="function")throw bi('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof K.TRUSTED_TYPES_POLICY.createScriptURL!=="function")throw bi('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');let Ot=kt;kt=K.TRUSTED_TYPES_POLICY;try{Ct=wt("")}catch($t){throw kt=Ot,$t}}else if(K.TRUSTED_TYPES_POLICY===null)kt=void 0,Ct="";else{if(kt===void 0)kt=Xt();if(kt&&typeof Ct==="string")Ct=wt("")}if(Ve)Ve(K);po=K},fd=xe({},[...lh,...hh,...$C]),dd=xe({},[...ch,...DC]),W0=function(K,lt,Ot){if(lt.namespaceURI===Kr)return K==="svg";if(lt.namespaceURI===fn)return K==="svg"&&(Ot==="annotation-xml"||Yl[Ot]);return Boolean(fd[K])},z0=function(K,lt,Ot){if(lt.namespaceURI===Kr)return K==="math";if(lt.namespaceURI===gn)return K==="math"&&Ul[Ot];return Boolean(dd[K])},H0=function(K,lt,Ot){if(lt.namespaceURI===gn&&!Ul[Ot])return!1;if(lt.namespaceURI===fn&&!Yl[Ot])return!1;return!dd[K]&&(P0[K]||!fd[K])},Y0=function(K){let lt=Bt(K),Ot=eo(ht(K)),$t=q(K),ie,ue;if($t&&ot($t)===We.element)ie={namespaceURI:Bt($t)},ue=eo(ht($t));else ie={namespaceURI:fo},ue="template";if(!Hl[lt])return!1;if(lt===gn)return W0(Ot,ie,ue);if(lt===fn)return z0(Ot,ie,ue);if(lt===Kr)return H0(Ot,ie,ue);if(_s==="application/xhtml+xml"&&Hl[lt])return!0;return!1},Yi=function(K){As(e.removed,{element:K});try{q(K).removeChild(K)}catch(lt){if(k(K),!q(K))throw bi("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},pd=function(K,lt,Ot){try{w(K,lt)}catch($t){try{K.removeAttribute(Ot)}catch(ie){}}},Gl=function(K){Vl(K);let lt=M(K);if(lt)Ci(BC(lt),($t)=>{try{k($t)}catch(ie){}});let Ot=ot(K)===We.element?V(K):null;if(Ot)for(let $t=Ot.length-1;$t>=0;--$t){let ie=Ot[$t],ue=ie&&ie.name;if(typeof ue==="string")pd(K,ie,ue)}},go=function(K,lt,Ot){if(!Ot)try{Ot=lt.getAttributeNode(K)}catch($t){Ot=null}As(e.removed,{attribute:Ot||null,from:lt});try{if(Ot)w(lt,Ot);else lt.removeAttribute(K)}catch($t){try{lt.removeAttribute(K)}catch(ie){}}if(K==="is")if(mt||Dt)try{Yi(lt)}catch($t){}else try{lt.setAttribute(K,"")}catch($t){}},gd=function(K){let lt=V(K);if(!lt)return;for(let Ot=lt.length-1;Ot>=0;--Ot){let $t=lt[Ot],ie=$t&&$t.name;if(typeof ie!=="string"||be[De(ie)])continue;pd(K,$t,ie)}},Xl=function(K,lt){let Ot=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,$t=[K];while($t.length>0){let ie=$t.pop();if(lt(ie)===!1)continue;if(Ot&&ot(ie)===We.element){let me=Y(ie);if(Ui(me))$t.push(me)}let ue=M(ie);if(ue)for(let me=ue.length-1;me>=0;--me)$t.push(ue[me])}},Vl=function(K){Xl(K,(lt)=>{if(ot(lt)===We.element)gd(lt)})},Kl=function(K){let lt=[];return Xl(K,(Ot)=>{lt.push(Ot)},!0),lt},U0=function(K,lt){let Ot=sh();Ci(Kl(K),($t)=>{if(ot($t)===We.element)ah(Ot,$t)}),Ci(lt,($t)=>{if(ot($t)===We.element&&!Ms(Ot,$t))gd($t)})},md=function(K,lt){let Ot=!1;return Ci(e.removed,($t)=>{if($t.element)Ot=Ot||$t.element===K,Vl($t.element)}),U0(K,lt),Ot},j0=8,G0=function(K,lt){let Ot=Jt,$t=null,ie=()=>{if(!$t)$t=sh(),Ci(lt,(ue)=>{ah($t,ue)});return $t};for(let ue=0;;ue++){let me=Kl(K),ze=[K],Zr=!1;if(Ci(me,(dr)=>{if(ot(dr)===We.documentFragment)As(ze,dr);else if(!Zr&&!Ms(Ot,dr))Zr=Ms(ie(),dr)}),!Zr)return;if(ue>=j0)throw bi("the tree kept changing during in-place sanitization; refusing to return it");Ci(ze,(dr,br)=>{X0(dr,br>0,K,ie())})}},X0=function(K,lt,Ot,$t){let ie=Zl(K),ue;while(ue=ie.nextNode()){if(!Ms($t,ue)||Ms(Jt,ue))continue;if(lt)Pr(Ut.uponSanitizeShadowNode,ue,null);if(Jl(ue,Ot),th(ue,Ot),Ui(ue.content))vs(ue.content)}},V0=function(K){if(Jt)ah(Jt,K)},yd=function(K,lt){if(!ft)return!1;if(K==="patchsrc")return!0;return K==="for"&<!=="label"&<!=="output"},K0=function(K){if(!ft)return;Xl(K,(lt)=>{let Ot=ot(lt);if(Ot===We.processingInstruction||Ot===We.comment&&Je(Zd,lt.data)){try{k(lt)}catch($t){}return!1}if(Ot===We.element){let $t=lt,ie=De(ht(lt));try{if($t.hasAttribute&&$t.hasAttribute("patchsrc"))$t.removeAttribute("patchsrc");if($t.hasAttribute&&$t.hasAttribute("for")&&yd("for",ie))$t.removeAttribute("for")}catch(ue){}}return!0})},xd=function(K){let lt=null,Ot=null;if(G)K="<remove></remove>"+K;else{let ue=zd(K,/^[\r\n\t ]+/);Ot=ue&&ue[0]}if(_s==="application/xhtml+xml"&&fo===Kr)K='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+K+"</body></html>";let $t=kt?wt(K):K;if(fo===Kr)try{lt=new m().parseFromString($t,_s)}catch(ue){}if(!lt||!lt.documentElement){lt=se.createDocument(fo,"template",null);try{lt.documentElement.innerHTML=zl?Ct:$t}catch(ue){}}let ie=lt.body||lt.documentElement;if(K&&Ot)ie.insertBefore(o.createTextNode(Ot),ie.childNodes[0]||null);if(fo===Kr)return ge.call(lt,Tt?"html":"body")[0];return Tt?lt.documentElement:ie},Zl=function(K){let lt=at?at(K):K.ownerDocument;return oe.call(lt||K,K,p.SHOW_ELEMENT|p.SHOW_COMMENT|p.SHOW_TEXT|p.SHOW_PROCESSING_INSTRUCTION|p.SHOW_CDATA_SECTION,null)},mn=function(K){return K=Es(K,re," "),K=Es(K,ae," "),K=Es(K,ne," "),K},Ql=function(K){var lt;Cd(K);let Ot=(lt=K.querySelectorAll)===null||lt===void 0?void 0:lt.call(K,"template");if(Ot)Ci(Ot,($t)=>{if(Ui($t.content))Ql($t.content)})},Cd=function(K){K.normalize();let lt=at?at(K):K.ownerDocument,Ot=oe.call(lt||K,K,p.SHOW_TEXT|p.SHOW_COMMENT|p.SHOW_CDATA_SECTION|p.SHOW_PROCESSING_INSTRUCTION,null),$t=Ot.nextNode();while($t)$t.data=mn($t.data),$t=Ot.nextNode()},yn=function(K){let lt=tt?tt(K):null;if(typeof lt!=="string")return!1;if(De(lt)!=="form")return!1;return typeof K.nodeName!=="string"||typeof K.textContent!=="string"||typeof K.removeChild!=="function"||K.attributes!==V(K)||typeof K.removeAttribute!=="function"||typeof K.removeAttributeNode!=="function"||typeof K.getAttributeNode!=="function"||typeof K.setAttribute!=="function"||typeof K.namespaceURI!=="string"||typeof K.insertBefore!=="function"||typeof K.hasChildNodes!=="function"||K.nodeType!==Q(K)||K.childNodes!==M(K)},Ui=function(K){if(!Q||typeof K!=="object"||K===null)return!1;try{return Q(K)===We.documentFragment}catch(lt){return!1}},Bs=function(K){if(!Q||typeof K!=="object"||K===null)return!1;try{return typeof Q(K)==="number"}catch(lt){return!1}};function Pr(zt,K,lt){if(zt.length===0)return;Ci(zt,(Ot)=>{Ot.call(e,K,lt,po)})}let Z0=function(K,lt){if(ft&&K.hasChildNodes()&&!Bs(K.firstElementChild)&&Je(fh,K.textContent)&&Je(fh,K.innerHTML))return!0;if(ft&&GC[lt]&&ot(K)===We.element&&Bt(K)===Kr&&(Bs(K.firstElementChild)||typeof K.textContent==="string"&&Je(fh,K.textContent)))return!0;if(K.nodeType===We.processingInstruction)return!0;if(ft&&K.nodeType===We.comment&&Je(Zd,K.data))return!0;return!1},xn=function(K,lt){if(K instanceof RegExp)return Je(K,lt);if(K instanceof Function){for(var Ot=arguments.length,$t=Array(Ot>2?Ot-2:0),ie=2;ie<Ot;ie++)$t[ie-2]=arguments[ie];return Boolean(K(lt,...$t))}return!1},Q0=function(K,lt,Ot){if(!Er[lt]&&wd(lt)&&xn(Qe.tagNameCheck,lt))return!1;if(Qt&&!de[lt]&&!de[eo(lt)]){let $t=q(K),ie=M(K);if(ie&&$t){let ue=ie.length;for(let me=ue-1;me>=0;--me){let ze=K===Ot?x(ie[me],!0):ie[me];$t.insertBefore(ze,_(K))}}}return Yi(K),!0},bd=function(K,lt,Ot,$t){if(K.length===0)return lt;return lt===Ot||lt===$t?_r(lt):lt},mo=function(K,lt){if(K===lt||q(K)!==null)return!1;if(Zt)Vl(K);return!0},Jl=function(K,lt){if(V0(K),Pr(Ut.beforeSanitizeElements,K,null),mo(K,lt))return!0;if(yn(K))return Yi(K),!0;let Ot=De(ht(K));if(_e=bd(Ut.uponSanitizeElement,_e,Cr,St),Pr(Ut.uponSanitizeElement,K,{tagName:Ot,allowedTags:_e}),mo(K,lt))return!0;if(Z0(K,Ot))return Yi(K),!0;if(Er[Ot]||!(Ne.tagCheck instanceof Function&&Ne.tagCheck(Ot))&&!_e[Ot]){let $t=Q0(K,Ot,lt);if($t===!1){if(Pr(Ut.afterSanitizeElements,K,null),mo(K,lt))return!0}return $t}if(ot(K)===We.element&&!Y0(K))return Yi(K),!0;if((Ot==="noscript"||Ot==="noembed"||Ot==="noframes")&&Je(jC,K.innerHTML))return Yi(K),!0;if(b&&K.nodeType===We.text){let $t=mn(K.textContent);if(K.textContent!==$t)As(e.removed,{element:K.cloneNode()}),K.textContent=$t}return Pr(Ut.afterSanitizeElements,K,null),mo(K,lt)},kd=function(K,lt,Ot){if(qi[lt])return!1;if(yd(lt,K))return!1;if(Mt&&(lt==="id"||lt==="name")&&((Ot in o)||(Ot in N0)))return!1;let $t=be[lt]||Ne.attributeCheck instanceof Function&&Ne.attributeCheck(lt,K);if(Xr&&Je(Le,lt))return!0;if(Wi&&Je(ve,lt))return!0;if(!$t)return wd(K)&&xn(Qe.tagNameCheck,K)&&xn(Qe.attributeNameCheck,lt,K)||lt==="is"&&Qe.allowCustomizedBuiltInElements&&xn(Qe.tagNameCheck,Ot);if(Hi[lt])return!0;if(Je(Ai,Es(Ot,di,"")))return!0;if((lt==="src"||lt==="xlink:href"||lt==="href")&&K!=="script"&&Hd(Ot,"data:")===0&&Ts[K])return!0;if(gi&&!Je(Dr,Es(Ot,di,"")))return!0;return!Ot},J0=xe({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),wd=function(K){return!J0[eo(K)]&&Je(Mr,K)},tC=function(K,lt,Ot,$t){if(kt&&typeof u==="object"&&typeof u.getAttributeType==="function"&&!Ot)switch(u.getAttributeType(K,lt)){case"TrustedHTML":return wt($t);case"TrustedScriptURL":return vt($t)}return $t},eC=function(K,lt,Ot,$t){try{if(Ot)K.setAttributeNS(Ot,lt,$t);else K.setAttribute(lt,$t);if(yn(K))return Yi(K),!1;return!0}catch(ie){return go(lt,K),!1}},Sd=function(K,lt){if(ft&&Je(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,lt))return!0;return eo(K)==="attributename"&&zd(lt,"href")!==null},th=function(K,lt){if(Pr(Ut.beforeSanitizeAttributes,K,null),mo(K,lt))return;let Ot=K.attributes;if(!Ot||yn(K))return;be=bd(Ut.uponSanitizeAttribute,be,pi,Yt);let $t={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:be,forceKeepAttr:void 0},ie=Ot.length,ue=De(K.nodeName);while(ie--){let me=Ot[ie],{name:ze,namespaceURI:Zr,value:dr}=me,br=De(ze),yo=dr,kr=ze==="value"?yo:LC(yo),Td=!1;if($t.attrName=br,$t.attrValue=kr,$t.keepAttr=!0,$t.forceKeepAttr=void 0,Pr(Ut.uponSanitizeAttribute,K,$t),kr=$t.attrValue,Ht&&(br==="id"||br==="name")&&Hd(kr,Wt)!==0)go(ze,K,me),kr=Wt+kr,Td=!0;if(Sd(ze,kr)){go(ze,K,me);continue}if($t.forceKeepAttr)continue;if(!$t.keepAttr){go(ze,K,me);continue}if(!mi&&Je(Qd,kr)){go(ze,K,me);continue}if(b)kr=mn(kr);if(!kd(ue,br,kr)){go(ze,K,me);continue}if(kr=tC(ue,br,Zr,kr),kr!==yo){if(eC(K,ze,Zr,kr)&&Td)Wd(e.removed)}}Pr(Ut.afterSanitizeAttributes,K,null),mo(K,lt)},vs=function(K){let lt=null,Ot=Zl(K);Pr(Ut.beforeSanitizeShadowDOM,K,null);while(lt=Ot.nextNode()){if(Pr(Ut.uponSanitizeShadowNode,lt,null),Jl(lt,K),th(lt,K),Ui(lt.content))vs(lt.content);if(ot(lt)===We.element){let $t=Y(lt);if(Ui($t))eh($t),vs($t)}}if(b)Cd(K);Pr(Ut.afterSanitizeShadowDOM,K,null)},eh=function(K){let lt=[{node:K,shadow:null}];while(lt.length>0){let Ot=lt.pop();if(Ot.shadow){vs(Ot.shadow);continue}let $t=Ot.node,ie=ot($t)===We.element,ue=M($t);if(ue)for(let me=ue.length-1;me>=0;--me)lt.push({node:ue[me],shadow:null});if(ie){let me=tt?tt($t):null;if(typeof me==="string"&&De(me)==="template"){let ze=$t.content;if(Ui(ze))lt.push({node:ze,shadow:null})}}if(ie){let me=Y($t);if(Ui(me))lt.push({node:null,shadow:me},{node:me,shadow:null})}}};return e.sanitize=function(zt){let K=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},lt=null,Ot=null,$t=null,ie=null;if(zl=!zt,zl)zt="<!-->";if(typeof zt!=="string"&&!Bs(zt)){if(zt=EC(zt),typeof zt!=="string")throw bi("dirty is not a string, aborting")}if(!e.isSupported)return zt;if(At)_e=St,be=Yt;else jl(K);if(Ut.uponSanitizeElement.length>0||Ut.uponSanitizeAttribute.length>0)_e=_r(_e);if(Ut.uponSanitizeAttribute.length>0)be=_r(be);e.removed=[];let ue=Zt&&typeof zt!=="string"&&Bs(zt),me=[],ze=Jt;if(ue){K0(zt);let br=ht(zt);if(typeof br==="string"){let yo=De(br);if(!_e[yo]||Er[yo])throw Gl(zt),bi("root node is forbidden and cannot be sanitized in-place")}if(yn(zt))throw Gl(zt),bi("root node is clobbered and cannot be sanitized in-place");me=Kl(zt),Jt=sh()}else if(Bs(zt)){if(lt=xd("<!---->"),Ot=lt.ownerDocument.importNode(zt,!0),Ot.nodeType===We.element&&Ot.nodeName==="BODY")lt=Ot;else if(Ot.nodeName==="HTML")lt=Ot;else lt.appendChild(Ot);eh(lt)}else{if(!mt&&!b&&!Tt&&zt.indexOf("<")===-1)return kt&&Ft?wt(zt):zt;if(lt=xd(zt),!lt)return mt?null:Ft?Ct:""}if(lt&&G)Yi(lt.firstChild);let Zr=ue?zt:lt;try{if(ue)eh(zt);let br=Zl(Zr);while($t=br.nextNode())if(Jl($t,Zr),th($t,Zr),Ui($t.content))vs($t.content);if(ue)G0(zt,me)}catch(br){if(ue)Gl(zt),md(zt,me);throw br}finally{Jt=ze}if(ue){if(md(zt,me))throw bi("a node selected for removal could not be safely returned; refusing to sanitize in place");if(b)Ql(zt);return zt}if(mt){if(b)Ql(lt);if(Dt){ie=fe.call(lt.ownerDocument);while(lt.firstChild)ie.appendChild(lt.firstChild)}else ie=lt;if(be.shadowroot||be.shadowrootmode)ie=he.call(a,ie,!0);return ie}let dr=Tt?lt.outerHTML:lt.innerHTML;if(Tt&&_e["!doctype"]&<.ownerDocument&<.ownerDocument.doctype&<.ownerDocument.doctype.name&&Je(YC,lt.ownerDocument.doctype.name))dr="<!DOCTYPE "+lt.ownerDocument.doctype.name+`>
|
|
3
|
-
`+dr;if(b)dr=mn(dr);return kt&&Ft?wt(dr):dr},e.setConfig=function(){let zt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};jl(zt),At=!0,St=
|
|
1
|
+
import{Ke,Ze,S}from"./chunk-g5b4wjwp.js";var bo=Ze(function(rh,ih){(function(r,e){typeof rh=="object"&&typeof ih<"u"?ih.exports=e():typeof define=="function"&&define.amd?define(e):(r=typeof globalThis<"u"?globalThis:r||self).dayjs=e()})(rh,function(){var r=1000,e=60000,o=3600000,a="millisecond",s="second",n="minute",c="hour",l="day",p="week",m="month",u="quarter",y="year",x="date",k="Invalid Date",w=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,_=/\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(Ct){var rt=["th","st","nd","rd"],it=Ct%100;return"["+Ct+(rt[(it-20)%10]||rt[it]||rt[0])+"]"}},W=function(Ct,rt,it){var gt=String(Ct);return!gt||gt.length>=rt?Ct:""+Array(rt+1-gt.length).join(it)+Ct},U={s:W,z:function(Ct){var rt=-Ct.utcOffset(),it=Math.abs(rt),gt=Math.floor(it/60),et=it%60;return(rt<=0?"+":"-")+W(gt,2,"0")+":"+W(et,2,"0")},m:function Ct(rt,it){if(rt.date()<it.date())return-Ct(it,rt);var gt=12*(it.year()-rt.year())+(it.month()-rt.month()),et=rt.clone().add(gt,m),wt=it-et<0,vt=rt.clone().add(gt+(wt?-1:1),m);return+(-(gt+(it-et)/(wt?et-vt:vt-et))||0)},a:function(Ct){return Ct<0?Math.ceil(Ct)||0:Math.floor(Ct)},p:function(Ct){return{M:m,y,w:p,d:l,D:x,h:c,m:n,s,ms:a,Q:u}[Ct]||String(Ct||"").toLowerCase().replace(/s$/,"")},u:function(Ct){return Ct===void 0}},V="en",Z={};Z[V]=M;var tt="$isDayjsObject",at=function(Ct){return Ct instanceof Bt||!(!Ct||!Ct[tt])},ot=function Ct(rt,it,gt){var et;if(!rt)return V;if(typeof rt=="string"){var wt=rt.toLowerCase();Z[wt]&&(et=wt),it&&(Z[wt]=it,et=wt);var vt=rt.split("-");if(!et&&vt.length>1)return Ct(vt[0])}else{var Xt=rt.name;Z[Xt]=rt,et=Xt}return!gt&&et&&(V=et),et||!gt&&V},ht=function(Ct,rt){if(at(Ct))return Ct.clone();var it=typeof rt=="object"?rt:{};return it.date=Ct,it.args=arguments,new Bt(it)},yt=U;yt.l=ot,yt.i=at,yt.w=function(Ct,rt){return ht(Ct,{locale:rt.$L,utc:rt.$u,x:rt.$x,$offset:rt.$offset})};var Bt=function(){function Ct(it){this.$L=ot(it.locale,null,!0),this.parse(it),this.$x=this.$x||it.x||{},this[tt]=!0}var rt=Ct.prototype;return rt.parse=function(it){this.$d=function(gt){var{date:et,utc:wt}=gt;if(et===null)return new Date(NaN);if(yt.u(et))return new Date;if(et instanceof Date)return new Date(et);if(typeof et=="string"&&!/Z$/i.test(et)){var vt=et.match(w);if(vt){var Xt=vt[2]-1||0,jt=(vt[7]||"0").substring(0,3);return wt?new Date(Date.UTC(vt[1],Xt,vt[3]||1,vt[4]||0,vt[5]||0,vt[6]||0,jt)):new Date(vt[1],Xt,vt[3]||1,vt[4]||0,vt[5]||0,vt[6]||0,jt)}}return new Date(et)}(it),this.init()},rt.init=function(){var it=this.$d;this.$y=it.getFullYear(),this.$M=it.getMonth(),this.$D=it.getDate(),this.$W=it.getDay(),this.$H=it.getHours(),this.$m=it.getMinutes(),this.$s=it.getSeconds(),this.$ms=it.getMilliseconds()},rt.$utils=function(){return yt},rt.isValid=function(){return this.$d.toString()!==k},rt.isSame=function(it,gt){var et=ht(it);return this.startOf(gt)<=et&&et<=this.endOf(gt)},rt.isAfter=function(it,gt){return ht(it)<this.startOf(gt)},rt.isBefore=function(it,gt){return this.endOf(gt)<ht(it)},rt.$g=function(it,gt,et){return yt.u(it)?this[gt]:this.set(et,it)},rt.unix=function(){return Math.floor(this.valueOf()/1000)},rt.valueOf=function(){return this.$d.getTime()},rt.startOf=function(it,gt){var et=this,wt=!!yt.u(gt)||gt,vt=yt.p(it),Xt=function(re,ae){var ne=yt.w(et.$u?Date.UTC(et.$y,ae,re):new Date(et.$y,ae,re),et);return wt?ne:ne.endOf(l)},jt=function(re,ae){return yt.w(et.toDate()[re].apply(et.toDate("s"),(wt?[0,0,0,0]:[23,59,59,999]).slice(ae)),et)},se=this.$W,oe=this.$M,de=this.$D,ge="set"+(this.$u?"UTC":"");switch(vt){case y:return wt?Xt(1,0):Xt(31,11);case m:return wt?Xt(1,oe):Xt(0,oe+1);case p:var he=this.$locale().weekStart||0,Ut=(se<he?se+7:se)-he;return Xt(wt?de-Ut:de+(6-Ut),oe);case l:case x:return jt(ge+"Hours",0);case c:return jt(ge+"Minutes",1);case n:return jt(ge+"Seconds",2);case s:return jt(ge+"Milliseconds",3);default:return this.clone()}},rt.endOf=function(it){return this.startOf(it,!1)},rt.$set=function(it,gt){var et,wt=yt.p(it),vt="set"+(this.$u?"UTC":""),Xt=(et={},et[l]=vt+"Date",et[x]=vt+"Date",et[m]=vt+"Month",et[y]=vt+"FullYear",et[c]=vt+"Hours",et[n]=vt+"Minutes",et[s]=vt+"Seconds",et[a]=vt+"Milliseconds",et)[wt],jt=wt===l?this.$D+(gt-this.$W):gt;if(wt===m||wt===y){var se=this.clone().set(x,1);se.$d[Xt](jt),se.init(),this.$d=se.set(x,Math.min(this.$D,se.daysInMonth())).$d}else Xt&&this.$d[Xt](jt);return this.init(),this},rt.set=function(it,gt){return this.clone().$set(it,gt)},rt.get=function(it){return this[yt.p(it)]()},rt.add=function(it,gt){var et,wt=this;it=Number(it);var vt=yt.p(gt),Xt=function(oe){var de=ht(wt);return yt.w(de.date(de.date()+Math.round(oe*it)),wt)};if(vt===m)return this.set(m,this.$M+it);if(vt===y)return this.set(y,this.$y+it);if(vt===l)return Xt(1);if(vt===p)return Xt(7);var jt=(et={},et[n]=e,et[c]=o,et[s]=r,et)[vt]||1,se=this.$d.getTime()+it*jt;return yt.w(se,this)},rt.subtract=function(it,gt){return this.add(-1*it,gt)},rt.format=function(it){var gt=this,et=this.$locale();if(!this.isValid())return et.invalidDate||k;var wt=it||"YYYY-MM-DDTHH:mm:ssZ",vt=yt.z(this),Xt=this.$H,jt=this.$m,se=this.$M,{weekdays:oe,months:de,meridiem:ge}=et,he=function(ae,ne,Be,_e){return ae&&(ae[ne]||ae(gt,wt))||Be[ne].slice(0,_e)},Ut=function(ae){return yt.s(Xt%12||12,ae,"0")},re=ge||function(ae,ne,Be){var _e=ae<12?"AM":"PM";return Be?_e.toLowerCase():_e};return wt.replace(_,function(ae,ne){return ne||function(Be){switch(Be){case"YY":return String(gt.$y).slice(-2);case"YYYY":return yt.s(gt.$y,4,"0");case"M":return se+1;case"MM":return yt.s(se+1,2,"0");case"MMM":return he(et.monthsShort,se,de,3);case"MMMM":return he(de,se);case"D":return gt.$D;case"DD":return yt.s(gt.$D,2,"0");case"d":return String(gt.$W);case"dd":return he(et.weekdaysMin,gt.$W,oe,2);case"ddd":return he(et.weekdaysShort,gt.$W,oe,3);case"dddd":return oe[gt.$W];case"H":return String(Xt);case"HH":return yt.s(Xt,2,"0");case"h":return Ut(1);case"hh":return Ut(2);case"a":return re(Xt,jt,!0);case"A":return re(Xt,jt,!1);case"m":return String(jt);case"mm":return yt.s(jt,2,"0");case"s":return String(gt.$s);case"ss":return yt.s(gt.$s,2,"0");case"SSS":return yt.s(gt.$ms,3,"0");case"Z":return vt}return null}(ae)||vt.replace(":","")})},rt.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},rt.diff=function(it,gt,et){var wt,vt=this,Xt=yt.p(gt),jt=ht(it),se=(jt.utcOffset()-this.utcOffset())*e,oe=this-jt,de=function(){return yt.m(vt,jt)};switch(Xt){case y:wt=de()/12;break;case m:wt=de();break;case u:wt=de()/3;break;case p:wt=(oe-se)/604800000;break;case l:wt=(oe-se)/86400000;break;case c:wt=oe/o;break;case n:wt=oe/e;break;case s:wt=oe/r;break;default:wt=oe}return et?wt:yt.a(wt)},rt.daysInMonth=function(){return this.endOf(m).$D},rt.$locale=function(){return Z[this.$L]},rt.locale=function(it,gt){if(!it)return this.$L;var et=this.clone(),wt=ot(it,gt,!0);return wt&&(et.$L=wt),et},rt.clone=function(){return yt.w(this.$d,this)},rt.toDate=function(){return new Date(this.valueOf())},rt.toJSON=function(){return this.isValid()?this.toISOString():null},rt.toISOString=function(){return this.$d.toISOString()},rt.toString=function(){return this.$d.toUTCString()},Ct}(),kt=Bt.prototype;return ht.prototype=kt,[["$ms",a],["$s",s],["$m",n],["$H",c],["$W",l],["$M",m],["$y",y],["$D",x]].forEach(function(Ct){kt[Ct[1]]=function(rt){return this.$g(rt,Ct[0],Ct[1])}}),ht.extend=function(Ct,rt){return Ct.$i||(Ct(rt,Bt,ht),Ct.$i=!0),ht},ht.locale=ot,ht.isDayjs=at,ht.unix=function(Ct){return ht(1000*Ct)},ht.en=Z[V],ht.Ls=Z,ht.p={},ht})});var sm=Ze(function(im){Object.defineProperty(im,"__esModule",{value:!0});im.BLANK_URL=im.relativeFirstCharacters=im.whitespaceEscapeCharsRegex=im.urlSchemeRegex=im.ctrlCharactersRegex=im.htmlCtrlEntityRegex=im.htmlEntitiesRegex=im.invalidProtocolRegex=void 0;im.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im;im.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g;im.htmlCtrlEntityRegex=/&(newline|tab);/gi;im.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim;im.urlSchemeRegex=/^.+(:|:)/gim;im.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g;im.relativeFirstCharacters=[".","/"];im.BLANK_URL="about:blank"});var la=Ze(function(nm){Object.defineProperty(nm,"__esModule",{value:!0});nm.sanitizeUrl=T2;var ur=sm();function k2(r){return ur.relativeFirstCharacters.indexOf(r[0])>-1}function w2(r){var e=r.replace(ur.ctrlCharactersRegex,"");return e.replace(ur.htmlEntitiesRegex,function(o,a){return String.fromCharCode(a)})}function S2(r){return URL.canParse(r)}function am(r){try{return decodeURIComponent(r)}catch(e){return r}}function T2(r){if(!r)return ur.BLANK_URL;var e,o=am(r.trim());do o=w2(o).replace(ur.htmlCtrlEntityRegex,"").replace(ur.ctrlCharactersRegex,"").replace(ur.whitespaceEscapeCharsRegex,"").trim(),o=am(o),e=o.match(ur.ctrlCharactersRegex)||o.match(ur.htmlEntitiesRegex)||o.match(ur.htmlCtrlEntityRegex)||o.match(ur.whitespaceEscapeCharsRegex);while(e&&e.length>0);var a=o;if(!a)return ur.BLANK_URL;if(k2(a))return a;var s=a.trimStart(),n=s.match(ur.urlSchemeRegex);if(!n)return a;var c=n[0].toLowerCase().trim();if(ur.invalidProtocolRegex.test(c))return ur.BLANK_URL;var l=s.replace(/\\/g,"/");if(c==="mailto:"||c.includes("://"))return l;if(c==="http:"||c==="https:"){if(!S2(l))return ur.BLANK_URL;var p=new URL(l);return p.protocol=p.protocol.toLowerCase(),p.hostname=p.hostname.toLowerCase(),p.toString()}return l}});var _d=Object.defineProperty,t=(r,e)=>_d(r,"name",{value:e,configurable:!0}),er=(r,e)=>{for(var o in e)_d(r,o,{get:e[o],enumerable:!0})};var Bd=Ke(bo(),1),yi={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},i={trace:t((...r)=>{},"trace"),debug:t((...r)=>{},"debug"),info:t((...r)=>{},"info"),warn:t((...r)=>{},"warn"),error:t((...r)=>{},"error"),fatal:t((...r)=>{},"fatal")},Ti=t(function(r="fatal"){let e=yi.fatal;if(typeof r==="string"){if(r.toLowerCase()in yi)e=yi[r]}else if(typeof r==="number")e=r;if(i.trace=()=>{},i.debug=()=>{},i.info=()=>{},i.warn=()=>{},i.error=()=>{},i.fatal=()=>{},e<=yi.fatal)i.fatal=console.error?console.error.bind(console,Or("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",Or("FATAL"));if(e<=yi.error)i.error=console.error?console.error.bind(console,Or("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",Or("ERROR"));if(e<=yi.warn)i.warn=console.warn?console.warn.bind(console,Or("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",Or("WARN"));if(e<=yi.info)i.info=console.info?console.info.bind(console,Or("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",Or("INFO"));if(e<=yi.debug)i.debug=console.debug?console.debug.bind(console,Or("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Or("DEBUG"));if(e<=yi.trace)i.trace=console.debug?console.debug.bind(console,Or("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Or("TRACE"))},"setLogLevel"),Or=t((r)=>`%c${Bd.default().format("ss.SSS")} : ${r} : `,"format");var Cn={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:(r)=>r>=255?255:r<0?0:r,g:(r)=>r>=255?255:r<0?0:r,b:(r)=>r>=255?255:r<0?0:r,h:(r)=>r%360,s:(r)=>r>=100?100:r<0?0:r,l:(r)=>r>=100?100:r<0?0:r,a:(r)=>r>=1?1:r<0?0:r},toLinear:(r)=>{let e=r/255;return r>0.03928?Math.pow((e+0.055)/1.055,2.4):e/12.92},hue2rgb:(r,e,o)=>{if(o<0)o+=1;if(o>1)o-=1;if(o<0.16666666666666666)return r+(e-r)*6*o;if(o<0.5)return e;if(o<0.6666666666666666)return r+(e-r)*(0.6666666666666666-o)*6;return r},hsl2rgb:({h:r,s:e,l:o},a)=>{if(!e)return o*2.55;r/=360,e/=100,o/=100;let s=o<0.5?o*(1+e):o+e-o*e,n=2*o-s;switch(a){case"r":return Cn.hue2rgb(n,s,r+0.3333333333333333)*255;case"g":return Cn.hue2rgb(n,s,r)*255;case"b":return Cn.hue2rgb(n,s,r-0.3333333333333333)*255}},rgb2hsl:({r,g:e,b:o},a)=>{r/=255,e/=255,o/=255;let s=Math.max(r,e,o),n=Math.min(r,e,o),c=(s+n)/2;if(a==="l")return c*100;if(s===n)return 0;let l=s-n,p=c>0.5?l/(2-s-n):l/(s+n);if(a==="s")return p*100;switch(s){case r:return((e-o)/l+(e<o?6:0))*60;case e:return((o-r)/l+2)*60;case o:return((r-e)/l+4)*60;default:return-1}}},vd=Cn;var rC={clamp:(r,e,o)=>{if(e>o)return Math.min(e,Math.max(o,r));return Math.min(o,Math.max(e,r))},round:(r)=>Math.round(r*10000000000)/10000000000},Ld=rC;var iC={dec2hex:(r)=>{let e=Math.round(r).toString(16);return e.length>1?e:`0${e}`}},Fd=iC;var oC={channel:vd,lang:Ld,unit:Fd},X=oC;var xi={};for(let r=0;r<=255;r++)xi[r]=X.unit.dec2hex(r);var je={ALL:0,RGB:1,HSL:2};class Ad{constructor(){this.type=je.ALL}get(){return this.type}set(r){if(this.type&&this.type!==r)throw Error("Cannot change both RGB and HSL channels at the same time");this.type=r}reset(){this.type=je.ALL}is(r){return this.type===r}}var Md=Ad;class Ed{constructor(r,e){this.color=e,this.changed=!1,this.data=r,this.type=new Md}set(r,e){return this.color=e,this.changed=!1,this.data=r,this.type.type=je.ALL,this}_ensureHSL(){let r=this.data,{h:e,s:o,l:a}=r;if(e===void 0)r.h=X.channel.rgb2hsl(r,"h");if(o===void 0)r.s=X.channel.rgb2hsl(r,"s");if(a===void 0)r.l=X.channel.rgb2hsl(r,"l")}_ensureRGB(){let r=this.data,{r:e,g:o,b:a}=r;if(e===void 0)r.r=X.channel.hsl2rgb(r,"r");if(o===void 0)r.g=X.channel.hsl2rgb(r,"g");if(a===void 0)r.b=X.channel.hsl2rgb(r,"b")}get r(){let r=this.data,e=r.r;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"r")}get g(){let r=this.data,e=r.g;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"g")}get b(){let r=this.data,e=r.b;if(!this.type.is(je.HSL)&&e!==void 0)return e;return this._ensureHSL(),X.channel.hsl2rgb(r,"b")}get h(){let r=this.data,e=r.h;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"h")}get s(){let r=this.data,e=r.s;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"s")}get l(){let r=this.data,e=r.l;if(!this.type.is(je.RGB)&&e!==void 0)return e;return this._ensureRGB(),X.channel.rgb2hsl(r,"l")}get a(){return this.data.a}set r(r){this.type.set(je.RGB),this.changed=!0,this.data.r=r}set g(r){this.type.set(je.RGB),this.changed=!0,this.data.g=r}set b(r){this.type.set(je.RGB),this.changed=!0,this.data.b=r}set h(r){this.type.set(je.HSL),this.changed=!0,this.data.h=r}set s(r){this.type.set(je.HSL),this.changed=!0,this.data.s=r}set l(r){this.type.set(je.HSL),this.changed=!0,this.data.l=r}set a(r){this.changed=!0,this.data.a=r}}var Od=Ed;var sC=new Od({r:0,g:0,b:0,a:0},"transparent"),ji=sC;var Id={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:(r)=>{if(r.charCodeAt(0)!==35)return;let e=r.match(Id.re);if(!e)return;let o=e[1],a=parseInt(o,16),s=o.length,n=s%4===0,c=s>4,l=c?1:17,p=c?8:4,m=n?0:-1,u=c?255:15;return ji.set({r:(a>>p*(m+3)&u)*l,g:(a>>p*(m+2)&u)*l,b:(a>>p*(m+1)&u)*l,a:n?(a&u)*l/255:1},r)},stringify:(r)=>{let{r:e,g:o,b:a,a:s}=r;if(s<1)return`#${xi[Math.round(e)]}${xi[Math.round(o)]}${xi[Math.round(a)]}${xi[Math.round(s*255)]}`;else return`#${xi[Math.round(e)]}${xi[Math.round(o)]}${xi[Math.round(a)]}`}},to=Id;var bn={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:(r)=>{let e=r.match(bn.hueRe);if(e){let[,o,a]=e;switch(a){case"grad":return X.channel.clamp.h(parseFloat(o)*0.9);case"rad":return X.channel.clamp.h(parseFloat(o)*180/Math.PI);case"turn":return X.channel.clamp.h(parseFloat(o)*360)}}return X.channel.clamp.h(parseFloat(r))},parse:(r)=>{let e=r.charCodeAt(0);if(e!==104&&e!==72)return;let o=r.match(bn.re);if(!o)return;let[,a,s,n,c,l]=o;return ji.set({h:bn._hue2deg(a),s:X.channel.clamp.s(parseFloat(s)),l:X.channel.clamp.l(parseFloat(n)),a:c?X.channel.clamp.a(l?parseFloat(c)/100:parseFloat(c)):1},r)},stringify:(r)=>{let{h:e,s:o,l:a,a:s}=r;if(s<1)return`hsla(${X.lang.round(e)}, ${X.lang.round(o)}%, ${X.lang.round(a)}%, ${s})`;else return`hsl(${X.lang.round(e)}, ${X.lang.round(o)}%, ${X.lang.round(a)}%)`}},Ls=bn;var Sn={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:(r)=>{r=r.toLowerCase();let e=Sn.colors[r];if(!e)return;return to.parse(e)},stringify:(r)=>{let e=to.stringify(r);for(let o in Sn.colors)if(Sn.colors[o]===e)return o;return}},oh=Sn;var $d={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:(r)=>{let e=r.charCodeAt(0);if(e!==114&&e!==82)return;let o=r.match($d.re);if(!o)return;let[,a,s,n,c,l,p,m,u]=o;return ji.set({r:X.channel.clamp.r(s?parseFloat(a)*2.55:parseFloat(a)),g:X.channel.clamp.g(c?parseFloat(n)*2.55:parseFloat(n)),b:X.channel.clamp.b(p?parseFloat(l)*2.55:parseFloat(l)),a:m?X.channel.clamp.a(u?parseFloat(m)/100:parseFloat(m)):1},r)},stringify:(r)=>{let{r:e,g:o,b:a,a:s}=r;if(s<1)return`rgba(${X.lang.round(e)}, ${X.lang.round(o)}, ${X.lang.round(a)}, ${X.lang.round(s)})`;else return`rgb(${X.lang.round(e)}, ${X.lang.round(o)}, ${X.lang.round(a)})`}},Fs=$d;var aC={format:{keyword:oh,hex:to,rgb:Fs,rgba:Fs,hsl:Ls,hsla:Ls},parse:(r)=>{if(typeof r!=="string")return r;let e=to.parse(r)||Fs.parse(r)||Ls.parse(r)||oh.parse(r);if(e)return e;throw Error(`Unsupported color format: "${r}"`)},stringify:(r)=>{if(!r.changed&&r.color)return r.color;if(r.type.is(je.HSL)||r.data.r===void 0)return Ls.stringify(r);else if(r.a<1||!Number.isInteger(r.r)||!Number.isInteger(r.g)||!Number.isInteger(r.b))return Fs.stringify(r);else return to.stringify(r)}},pt=aC;var nC=(r,e)=>{let o=pt.parse(r);for(let a in e)o[a]=X.channel.clamp[a](e[a]);return pt.stringify(o)},Tn=nC;var lC=(r,e,o=0,a=1)=>{if(typeof r!=="number")return Tn(r,{a:e});let s=ji.set({r:X.channel.clamp.r(r),g:X.channel.clamp.g(e),b:X.channel.clamp.b(o),a:X.channel.clamp.a(a)});return pt.stringify(s)},Ie=lC;var hC=(r)=>{let{r:e,g:o,b:a}=pt.parse(r),s=0.2126*X.channel.toLinear(e)+0.7152*X.channel.toLinear(o)+0.0722*X.channel.toLinear(a);return X.lang.round(s)},Dd=hC;var cC=(r)=>Dd(r)>=0.5,Pd=cC;var uC=(r)=>!Pd(r),ue=uC;var fC=(r,e,o)=>{let a=pt.parse(r),s=a[e],n=X.channel.clamp[e](s+o);if(s!==n)a[e]=n;return pt.stringify(a)},ja=fC;var dC=(r,e)=>ja(r,"l",e),f=dC;var pC=(r,e)=>ja(r,"l",-e),h=pC;var gC=(r,e)=>{let o=pt.parse(r),a={};for(let s in e){if(!e[s])continue;a[s]=o[s]+e[s]}return Tn(r,a)},z=gC;var mC=(r,e,o=50)=>{let{r:a,g:s,b:n,a:c}=pt.parse(r),{r:l,g:p,b:m,a:u}=pt.parse(e),y=o/100,x=y*2-1,k=c-u,_=((x*k===-1?x:(x+k)/(1+x*k))+1)/2,M=1-_,W=a*_+l*M,U=s*_+p*M,V=n*_+m*M,Z=c*y+u*(1-y);return Ie(W,U,V,Z)},Rd=mC;var yC=(r,e=100)=>{let o=pt.parse(r);return o.r=255-o.r,o.g=255-o.g,o.b=255-o.b,Rd(o,r,e)},nt=yC;/*! @license DOMPurify 3.4.17 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.17/LICENSE */function xC(r,e){this.v=r,this.k=e}function qd(r,e){(e==null||e>r.length)&&(e=r.length);for(var o=0,a=Array(e);o<e;o++)a[o]=r[o];return a}function CC(r){if(Array.isArray(r))return r}function bC(r,e){var o=r==null?null:typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(o!=null){var a,s,n,c,l=[],p=!0,m=!1;try{if(n=(o=o.call(r)).next,e===0){if(Object(o)!==o)return;p=!1}else for(;!(p=(a=n.call(o)).done)&&(l.push(a.value),l.length!==e);p=!0);}catch(u){m=!0,s=u}finally{try{if(!p&&o.return!=null&&(c=o.return(),Object(c)!==c))return}finally{if(m)throw s}}return l}}function kC(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */function wC(r,e){return CC(r)||bC(r,e)||SC(r,e)||kC()}function SC(r,e){if(r){if(typeof r=="string")return qd(r,e);var o={}.toString.call(r).slice(8,-1);return o==="Object"&&r.constructor&&(o=r.constructor.name),o==="Map"||o==="Set"?Array.from(r):o==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o)?qd(r,e):void 0}}function vn(r){var e,o;function a(n,c){try{var l=r[n](c),p=l.value,m=p instanceof xC;Promise.resolve(m?p.v:p).then(function(u){if(m){var y=n==="return"&&p.k?n:"next";if(!p.k||u.done)return a(y,u);u=r[y](u).value}s(!!l.done,u)},function(u){a("throw",u)})}catch(u){s(2,u)}}function s(n,c){n===2?e.reject(c):e.resolve({value:c,done:n}),(e=e.next)?a(e.key,e.arg):o=null}this._invoke=function(n,c){return new Promise(function(l,p){var m={key:n,arg:c,resolve:l,reject:p,next:null};o?o=o.next=m:(e=o=m,a(n,c))})},typeof r.return!="function"&&(this.return=void 0)}vn.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},vn.prototype.next=function(r){return this._invoke("next",r)},vn.prototype.throw=function(r){return this._invoke("throw",r)},vn.prototype.return=function(r){return this._invoke("return",r)};var{entries:tp,setPrototypeOf:Nd,isFrozen:TC,getPrototypeOf:ep,getOwnPropertyDescriptor:rp,freeze:Ve,seal:ir,create:vo}=Object,ip=typeof Reflect<"u"&&Reflect,{apply:ph,construct:gh}=ip;if(!Ve)Ve=function(e){return e};if(!ir)ir=function(e){return e};if(!ph)ph=function(e,o){for(var a=arguments.length,s=Array(a>2?a-2:0),n=2;n<a;n++)s[n-2]=arguments[n];return e.apply(o,s)};if(!gh)gh=function(e){for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return new e(...a)};var Ci=ve(Array.prototype.forEach);Array.prototype.indexOf;var _C=ve(Array.prototype.lastIndexOf),Wd=ve(Array.prototype.pop),As=ve(Array.prototype.push),BC=ve(Array.prototype.slice),vC=ve(Array.prototype.splice),Qo=Array.isArray,sh=op(Set),ah=ve(Set.prototype.add),Ms=ve(Set.prototype.has),eo=ve(String.prototype.toLowerCase),nh=ve(String.prototype.toString),zd=ve(String.prototype.match),Es=ve(String.prototype.replace),Hd=ve(String.prototype.indexOf),LC=ve(String.prototype.trim),FC=ve(Number.prototype.toString),AC=ve(Boolean.prototype.toString),Yd=typeof BigInt>"u"?null:ve(BigInt.prototype.toString),Ud=typeof Symbol>"u"?null:ve(Symbol.prototype.toString),wr=ve(Object.prototype.hasOwnProperty),Os=ve(Object.prototype.toString),Je=ve(RegExp.prototype.test),bi=op(TypeError);function ve(r){return function(e){if(e instanceof RegExp)e.lastIndex=0;for(var o=arguments.length,a=Array(o>1?o-1:0),s=1;s<o;s++)a[s-1]=arguments[s];return ph(r,e,a)}}function op(r){return function(){for(var e=arguments.length,o=Array(e),a=0;a<e;a++)o[a]=arguments[a];return gh(r,o)}}function xe(r,e){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:eo;if(Nd)Nd(r,null);if(!Qo(e))return r;let a=e.length;while(a--){let s=e[a];if(typeof s==="string"){let n=o(s);if(n!==s){if(!TC(e))e[a]=n;s=n}}r[s]=!0}return r}function MC(r){for(let e=0;e<r.length;e++)if(!wr(r,e))r[e]=null;return r}function _r(r){let e=vo(null);for(let a of tp(r)){var o=wC(a,2);let s=o[0],n=o[1];if(wr(r,s))if(Qo(n))e[s]=MC(n);else if(n&&typeof n==="object"&&n.constructor===Object)e[s]=_r(n);else e[s]=n}return e}function EC(r){switch(typeof r){case"string":return r;case"number":return FC(r);case"boolean":return AC(r);case"bigint":return Yd?Yd(r):"0";case"symbol":return Ud?Ud(r):"Symbol()";case"undefined":return Os(r);case"function":case"object":{if(r===null)return Os(r);let e=r,o=Ir(e,"toString");if(typeof o==="function"){let a=o(e);return typeof a==="string"?a:Os(a)}return Os(r)}default:return Os(r)}}function Ir(r,e){while(r!==null){let a=rp(r,e);if(a){if(a.get)return ve(a.get);if(typeof a.value==="function")return ve(a.value)}r=ep(r)}function o(){return null}return o}function OC(r,e){while(r!==null){let o=rp(r,e);if(o)return o.get?ve(o.get):null;r=ep(r)}return null}function IC(r){try{return Je(r,""),!0}catch(e){return!1}}var jd=Ve(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),lh=Ve(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),hh=Ve(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),$C=Ve(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),ch=Ve(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),DC=Ve(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Gd=Ve(["#text"]),Xd=Ve(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","command","commandfor","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns"]),uh=Ve(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dominant-baseline","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","pointer-events","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-orientation","text-rendering","textlength","type","u1","u2","unicode","values","vector-effect","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Vd=Ve(["accent","accentunder","align","bevelled","close","columnalign","columnlines","columnspacing","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lquote","lspace","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Ln=Ve(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),PC=ir(/{{[\w\W]*|^[\w\W]*}}/g),RC=ir(/<%[\w\W]*|^[\w\W]*%>/g),qC=ir(/\${[\w\W]*/g),NC=ir(/^data-[\-\w.\u00B7-\uFFFF]+$/),WC=ir(/^aria-[\-\w]+$/),Kd=ir(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),zC=ir(/^(?:\w+script|data):/i),HC=ir(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),YC=ir(/^html$/i),UC=ir(/^[a-z][.\w]*(-[.\w]+)+$/i),fh=ir(/<[/\w!]/g),Zd=ir(/<[/\w]/g),jC=ir(/<\/no(script|embed|frames)/i),Qd=ir(/\/>/i),We={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},GC=Ve(xe({},["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"])),XC=function(){return typeof window>"u"?null:window},VC=function(e,o){if(typeof e!=="object"||typeof e.createPolicy!=="function")return null;let a=null,s="data-tt-policy-suffix";if(o&&o.hasAttribute(s))a=o.getAttribute(s);let n="dompurify"+(a?"#"+a:"");try{return e.createPolicy(n,{createHTML(c){return c},createScriptURL(c){return c}})}catch(c){return console.warn("TrustedTypes policy "+n+" could not be created."),null}},Jd=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Gi=function(e,o,a,s){return wr(e,o)&&Qo(e[o])?xe(s.base?_r(s.base):{},e[o],s.transform):a},dh=function(e,o,a){let s=wr(e,o)?e[o]:void 0;return s&&typeof s==="object"?_r(s):a()};function sp(){let r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:XC(),e=(zt)=>sp(zt);if(e.version="3.4.17",e.removed=[],!r||!r.document||r.document.nodeType!==We.document||!r.Element)return e.isSupported=!1,e;let o=r.document,a=o,s=a.currentScript;r.DocumentFragment;let{HTMLTemplateElement:n,Node:c,Element:l,NodeFilter:p}=r;r.NamedNodeMap===void 0&&(r.NamedNodeMap||r.MozNamedAttrMap),r.HTMLFormElement;let{DOMParser:m,trustedTypes:u}=r,y=l.prototype,x=Ir(y,"cloneNode"),k=Ir(y,"remove"),w=Ir(y,"removeAttributeNode"),_=Ir(y,"nextSibling"),M=Ir(y,"childNodes"),W=Ir(y,"parentNode"),U=Ir(y,"shadowRoot"),V=Ir(y,"attributes"),Z=c&&c.prototype?Ir(c.prototype,"nodeType"):null,tt=c&&c.prototype?Ir(c.prototype,"nodeName"):null,at=c&&c.prototype?Ir(c.prototype,"ownerDocument"):null,ot=function(K){return Z?Z(K):K.nodeType},ht=function(K){return tt?tt(K):K.nodeName},yt=OC(y,"namespaceURI"),Bt=function(K){return yt?yt(K):K.namespaceURI};if(typeof n==="function"){let zt=o.createElement("template");if(zt.content&&zt.content.ownerDocument)o=zt.content.ownerDocument}let kt,Ct="",rt,it=!1,gt=0,et=function(){if(gt>0)throw bi('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},wt=function(K){et(),gt++;try{return kt.createHTML(K)}finally{gt--}},vt=function(K){et(),gt++;try{return kt.createScriptURL(K)}finally{gt--}},Xt=function(){if(!it)rt=VC(u,s),it=!0;return rt},jt=o,{implementation:se,createNodeIterator:oe,createDocumentFragment:de,getElementsByTagName:ge}=jt,he=a.importNode,Ut=Jd();e.isSupported=typeof tp==="function"&&typeof W==="function"&&se&&se.createHTMLDocument!==void 0;let re=PC,ae=RC,ne=qC,Be=NC,_e=WC,Dr=zC,di=HC,Mr=UC,Ai=Kd,Se=null,Cr=xe({},[...jd,...lh,...hh,...ch,...Gd]),be=null,pi=xe({},[...Xd,...uh,...Vd,...Ln]),Qe=Object.seal(vo(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Er=null,qi=null,qe=Object.seal(vo(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),Wi=!0,Xr=!0,gi=!1,mi=!0,b=!1,ft=!0,Tt=!1,At=!1,St=null,Yt=null,G=!1,mt=!1,Dt=!1,Ft=!1,Mt=!0,Ht=!1,Wt="user-content-",Qt=!0,Zt=!1,Jt=null,ee={},pe=null,Te=xe({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","selectedcontent","style","svg","template","thead","title","video","xmp"]),Ts=null,zi=xe({},["audio","video","img","source","image","track"]),Hi=null,ld=xe({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),fn="http://www.w3.org/1998/Math/MathML",gn="http://www.w3.org/2000/svg",Kr="http://www.w3.org/1999/xhtml",fo=Kr,zl=!1,Hl=null,D0=xe({},[fn,gn,Kr],nh),hd=Ve(["mi","mo","mn","ms","mtext"]),Yl=xe({},hd),cd=Ve(["annotation-xml"]),Ul=xe({},cd),P0=xe({},["title","style","font","a","script"]),_s=null,R0=["application/xhtml+xml","text/html"],q0="text/html",Pe=null,po=null,N0=o.createElement("form"),ud=function(K){return K instanceof RegExp||K instanceof Function},jl=function(){let K=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(po&&po===K)return;if(!K||typeof K!=="object")K={};K=_r(K),_s=R0.indexOf(K.PARSER_MEDIA_TYPE)===-1?q0:K.PARSER_MEDIA_TYPE,Pe=_s==="application/xhtml+xml"?nh:eo,Se=Gi(K,"ALLOWED_TAGS",Cr,{transform:Pe}),be=Gi(K,"ALLOWED_ATTR",pi,{transform:Pe}),Hl=Gi(K,"ALLOWED_NAMESPACES",D0,{transform:nh}),Hi=Gi(K,"ADD_URI_SAFE_ATTR",ld,{transform:Pe,base:ld}),Ts=Gi(K,"ADD_DATA_URI_TAGS",zi,{transform:Pe,base:zi}),pe=Gi(K,"FORBID_CONTENTS",Te,{transform:Pe}),Er=Gi(K,"FORBID_TAGS",_r({}),{transform:Pe}),qi=Gi(K,"FORBID_ATTR",_r({}),{transform:Pe}),ee=wr(K,"USE_PROFILES")?K.USE_PROFILES&&typeof K.USE_PROFILES==="object"?_r(K.USE_PROFILES):K.USE_PROFILES:!1,Wi=K.ALLOW_ARIA_ATTR!==!1,Xr=K.ALLOW_DATA_ATTR!==!1,gi=K.ALLOW_UNKNOWN_PROTOCOLS||!1,mi=K.ALLOW_SELF_CLOSE_IN_ATTR!==!1,b=K.SAFE_FOR_TEMPLATES||!1,ft=K.SAFE_FOR_XML!==!1,Tt=K.WHOLE_DOCUMENT||!1,mt=K.RETURN_DOM||!1,Dt=K.RETURN_DOM_FRAGMENT||!1,Ft=K.RETURN_TRUSTED_TYPE||!1,G=K.FORCE_BODY||!1,Mt=K.SANITIZE_DOM!==!1,Ht=K.SANITIZE_NAMED_PROPS||!1,Qt=K.KEEP_CONTENT!==!1,Zt=K.IN_PLACE||!1,Ai=IC(K.ALLOWED_URI_REGEXP)?K.ALLOWED_URI_REGEXP:Kd,fo=typeof K.NAMESPACE==="string"?K.NAMESPACE:Kr,Yl=dh(K,"MATHML_TEXT_INTEGRATION_POINTS",()=>xe({},hd)),Ul=dh(K,"HTML_INTEGRATION_POINTS",()=>xe({},cd));let lt=dh(K,"CUSTOM_ELEMENT_HANDLING",()=>vo(null));if(Qe=vo(null),wr(lt,"tagNameCheck")&&ud(lt.tagNameCheck))Qe.tagNameCheck=lt.tagNameCheck;if(wr(lt,"attributeNameCheck")&&ud(lt.attributeNameCheck))Qe.attributeNameCheck=lt.attributeNameCheck;if(wr(lt,"allowCustomizedBuiltInElements")&&typeof lt.allowCustomizedBuiltInElements==="boolean")Qe.allowCustomizedBuiltInElements=lt.allowCustomizedBuiltInElements;if(ir(Qe),b)Xr=!1;if(Dt)mt=!0;if(ee){if(Se=xe({},Gd),be=vo(null),ee.html===!0)xe(Se,jd),xe(be,Xd);if(ee.svg===!0)xe(Se,lh),xe(be,uh),xe(be,Ln);if(ee.svgFilters===!0)xe(Se,hh),xe(be,uh),xe(be,Ln);if(ee.mathMl===!0)xe(Se,ch),xe(be,Vd),xe(be,Ln)}if(qe.tagCheck=null,qe.attributeCheck=null,wr(K,"ADD_TAGS")){if(typeof K.ADD_TAGS==="function")qe.tagCheck=K.ADD_TAGS;else if(Qo(K.ADD_TAGS)){if(Se===Cr)Se=_r(Se);xe(Se,K.ADD_TAGS,Pe)}}if(wr(K,"ADD_ATTR")){if(typeof K.ADD_ATTR==="function")qe.attributeCheck=K.ADD_ATTR;else if(Qo(K.ADD_ATTR)){if(be===pi)be=_r(be);xe(be,K.ADD_ATTR,Pe)}}if(wr(K,"ADD_FORBID_CONTENTS")&&Qo(K.ADD_FORBID_CONTENTS)){if(pe===Te)pe=_r(pe);xe(pe,K.ADD_FORBID_CONTENTS,Pe)}if(Qt)Se["#text"]=!0;if(Tt)xe(Se,["html","head","body"]);if(Se.table)xe(Se,["tbody"]),delete Er.tbody;if(K.TRUSTED_TYPES_POLICY){if(typeof K.TRUSTED_TYPES_POLICY.createHTML!=="function")throw bi('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof K.TRUSTED_TYPES_POLICY.createScriptURL!=="function")throw bi('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');let Ot=kt;kt=K.TRUSTED_TYPES_POLICY;try{Ct=wt("")}catch($t){throw kt=Ot,$t}}else if(K.TRUSTED_TYPES_POLICY===null)kt=void 0,Ct="";else{if(kt===void 0)kt=Xt();if(kt&&typeof Ct==="string")Ct=wt("")}if(Ve)Ve(K);po=K},fd=xe({},[...lh,...hh,...$C]),dd=xe({},[...ch,...DC]),W0=function(K,lt,Ot){if(lt.namespaceURI===Kr)return K==="svg";if(lt.namespaceURI===fn)return K==="svg"&&(Ot==="annotation-xml"||Yl[Ot]);return Boolean(fd[K])},z0=function(K,lt,Ot){if(lt.namespaceURI===Kr)return K==="math";if(lt.namespaceURI===gn)return K==="math"&&Ul[Ot];return Boolean(dd[K])},H0=function(K,lt,Ot){if(lt.namespaceURI===gn&&!Ul[Ot])return!1;if(lt.namespaceURI===fn&&!Yl[Ot])return!1;return!dd[K]&&(P0[K]||!fd[K])},Y0=function(K){let lt=Bt(K),Ot=eo(ht(K)),$t=W(K),ie,fe;if($t&&ot($t)===We.element)ie={namespaceURI:Bt($t)},fe=eo(ht($t));else ie={namespaceURI:fo},fe="template";if(!Hl[lt])return!1;if(lt===gn)return W0(Ot,ie,fe);if(lt===fn)return z0(Ot,ie,fe);if(lt===Kr)return H0(Ot,ie,fe);if(_s==="application/xhtml+xml"&&Hl[lt])return!0;return!1},Yi=function(K){As(e.removed,{element:K});try{W(K).removeChild(K)}catch(lt){if(k(K),!W(K))throw bi("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},pd=function(K,lt,Ot){try{w(K,lt)}catch($t){try{K.removeAttribute(Ot)}catch(ie){}}},Gl=function(K){Vl(K);let lt=M(K);if(lt)Ci(BC(lt),($t)=>{try{k($t)}catch(ie){}});let Ot=ot(K)===We.element?V(K):null;if(Ot)for(let $t=Ot.length-1;$t>=0;--$t){let ie=Ot[$t],fe=ie&&ie.name;if(typeof fe==="string")pd(K,ie,fe)}},go=function(K,lt,Ot){if(!Ot)try{Ot=lt.getAttributeNode(K)}catch($t){Ot=null}As(e.removed,{attribute:Ot||null,from:lt});try{if(Ot)w(lt,Ot);else lt.removeAttribute(K)}catch($t){try{lt.removeAttribute(K)}catch(ie){}}if(K==="is")if(mt||Dt)try{Yi(lt)}catch($t){}else try{lt.setAttribute(K,"")}catch($t){}},gd=function(K){let lt=V(K);if(!lt)return;for(let Ot=lt.length-1;Ot>=0;--Ot){let $t=lt[Ot],ie=$t&&$t.name;if(typeof ie!=="string"||be[Pe(ie)])continue;pd(K,$t,ie)}},Xl=function(K,lt){let Ot=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,$t=[K];while($t.length>0){let ie=$t.pop();if(lt(ie)===!1)continue;if(Ot&&ot(ie)===We.element){let me=U(ie);if(Ui(me))$t.push(me)}let fe=M(ie);if(fe)for(let me=fe.length-1;me>=0;--me)$t.push(fe[me])}},Vl=function(K){Xl(K,(lt)=>{if(ot(lt)===We.element)gd(lt)})},Kl=function(K){let lt=[];return Xl(K,(Ot)=>{lt.push(Ot)},!0),lt},U0=function(K,lt){let Ot=sh();Ci(Kl(K),($t)=>{if(ot($t)===We.element)ah(Ot,$t)}),Ci(lt,($t)=>{if(ot($t)===We.element&&!Ms(Ot,$t))gd($t)})},md=function(K,lt){let Ot=!1;return Ci(e.removed,($t)=>{if($t.element)Ot=Ot||$t.element===K,Vl($t.element)}),U0(K,lt),Ot},j0=8,G0=function(K,lt){let Ot=Jt,$t=null,ie=()=>{if(!$t)$t=sh(),Ci(lt,(fe)=>{ah($t,fe)});return $t};for(let fe=0;;fe++){let me=Kl(K),ze=[K],Zr=!1;if(Ci(me,(dr)=>{if(ot(dr)===We.documentFragment)As(ze,dr);else if(!Zr&&!Ms(Ot,dr))Zr=Ms(ie(),dr)}),!Zr)return;if(fe>=j0)throw bi("the tree kept changing during in-place sanitization; refusing to return it");Ci(ze,(dr,br)=>{X0(dr,br>0,K,ie())})}},X0=function(K,lt,Ot,$t){let ie=Zl(K),fe;while(fe=ie.nextNode()){if(!Ms($t,fe)||Ms(Jt,fe))continue;if(lt)Pr(Ut.uponSanitizeShadowNode,fe,null);if(Jl(fe,Ot),th(fe,Ot),Ui(fe.content))vs(fe.content)}},V0=function(K){if(Jt)ah(Jt,K)},yd=function(K,lt){if(!ft)return!1;if(K==="patchsrc")return!0;return K==="for"&<!=="label"&<!=="output"},K0=function(K){if(!ft)return;Xl(K,(lt)=>{let Ot=ot(lt);if(Ot===We.processingInstruction||Ot===We.comment&&Je(Zd,lt.data)){try{k(lt)}catch($t){}return!1}if(Ot===We.element){let $t=lt,ie=Pe(ht(lt));try{if($t.hasAttribute&&$t.hasAttribute("patchsrc"))$t.removeAttribute("patchsrc");if($t.hasAttribute&&$t.hasAttribute("for")&&yd("for",ie))$t.removeAttribute("for")}catch(fe){}}return!0})},xd=function(K){let lt=null,Ot=null;if(G)K="<remove></remove>"+K;else{let fe=zd(K,/^[\r\n\t ]+/);Ot=fe&&fe[0]}if(_s==="application/xhtml+xml"&&fo===Kr)K='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+K+"</body></html>";let $t=kt?wt(K):K;if(fo===Kr)try{lt=new m().parseFromString($t,_s)}catch(fe){}if(!lt||!lt.documentElement){lt=se.createDocument(fo,"template",null);try{lt.documentElement.innerHTML=zl?Ct:$t}catch(fe){}}let ie=lt.body||lt.documentElement;if(K&&Ot)ie.insertBefore(o.createTextNode(Ot),ie.childNodes[0]||null);if(fo===Kr)return ge.call(lt,Tt?"html":"body")[0];return Tt?lt.documentElement:ie},Zl=function(K){let lt=at?at(K):K.ownerDocument;return oe.call(lt||K,K,p.SHOW_ELEMENT|p.SHOW_COMMENT|p.SHOW_TEXT|p.SHOW_PROCESSING_INSTRUCTION|p.SHOW_CDATA_SECTION,null)},mn=function(K){return K=Es(K,re," "),K=Es(K,ae," "),K=Es(K,ne," "),K},Ql=function(K){var lt;Cd(K);let Ot=(lt=K.querySelectorAll)===null||lt===void 0?void 0:lt.call(K,"template");if(Ot)Ci(Ot,($t)=>{if(Ui($t.content))Ql($t.content)})},Cd=function(K){K.normalize();let lt=at?at(K):K.ownerDocument,Ot=oe.call(lt||K,K,p.SHOW_TEXT|p.SHOW_COMMENT|p.SHOW_CDATA_SECTION|p.SHOW_PROCESSING_INSTRUCTION,null),$t=Ot.nextNode();while($t)$t.data=mn($t.data),$t=Ot.nextNode()},yn=function(K){let lt=tt?tt(K):null;if(typeof lt!=="string")return!1;if(Pe(lt)!=="form")return!1;return typeof K.nodeName!=="string"||typeof K.textContent!=="string"||typeof K.removeChild!=="function"||K.attributes!==V(K)||typeof K.removeAttribute!=="function"||typeof K.removeAttributeNode!=="function"||typeof K.getAttributeNode!=="function"||typeof K.setAttribute!=="function"||typeof K.namespaceURI!=="string"||typeof K.insertBefore!=="function"||typeof K.hasChildNodes!=="function"||K.nodeType!==Z(K)||K.childNodes!==M(K)},Ui=function(K){if(!Z||typeof K!=="object"||K===null)return!1;try{return Z(K)===We.documentFragment}catch(lt){return!1}},Bs=function(K){if(!Z||typeof K!=="object"||K===null)return!1;try{return typeof Z(K)==="number"}catch(lt){return!1}};function Pr(zt,K,lt){if(zt.length===0)return;Ci(zt,(Ot)=>{Ot.call(e,K,lt,po)})}let Z0=function(K,lt){if(ft&&K.hasChildNodes()&&!Bs(K.firstElementChild)&&Je(fh,K.textContent)&&Je(fh,K.innerHTML))return!0;if(ft&&GC[lt]&&ot(K)===We.element&&Bt(K)===Kr&&(Bs(K.firstElementChild)||typeof K.textContent==="string"&&Je(fh,K.textContent)))return!0;if(K.nodeType===We.processingInstruction)return!0;if(ft&&K.nodeType===We.comment&&Je(Zd,K.data))return!0;return!1},xn=function(K,lt){if(K instanceof RegExp)return Je(K,lt);if(K instanceof Function){for(var Ot=arguments.length,$t=Array(Ot>2?Ot-2:0),ie=2;ie<Ot;ie++)$t[ie-2]=arguments[ie];return Boolean(K(lt,...$t))}return!1},Q0=function(K,lt,Ot){if(!Er[lt]&&wd(lt)&&xn(Qe.tagNameCheck,lt))return!1;if(Qt&&!pe[lt]&&!pe[eo(lt)]){let $t=W(K),ie=M(K);if(ie&&$t){let fe=ie.length;for(let me=fe-1;me>=0;--me){let ze=K===Ot?x(ie[me],!0):ie[me];$t.insertBefore(ze,_(K))}}}return Yi(K),!0},bd=function(K,lt,Ot,$t){if(K.length===0)return lt;return lt===Ot||lt===$t?_r(lt):lt},mo=function(K,lt){if(K===lt||W(K)!==null)return!1;if(Zt)Vl(K);return!0},Jl=function(K,lt){if(V0(K),Pr(Ut.beforeSanitizeElements,K,null),mo(K,lt))return!0;if(yn(K))return Yi(K),!0;let Ot=Pe(ht(K));if(Se=bd(Ut.uponSanitizeElement,Se,Cr,St),Pr(Ut.uponSanitizeElement,K,{tagName:Ot,allowedTags:Se}),mo(K,lt))return!0;if(Z0(K,Ot))return Yi(K),!0;if(Er[Ot]||!(qe.tagCheck instanceof Function&&qe.tagCheck(Ot))&&!Se[Ot]){let $t=Q0(K,Ot,lt);if($t===!1){if(Pr(Ut.afterSanitizeElements,K,null),mo(K,lt))return!0}return $t}if(ot(K)===We.element&&!Y0(K))return Yi(K),!0;if((Ot==="noscript"||Ot==="noembed"||Ot==="noframes")&&Je(jC,K.innerHTML))return Yi(K),!0;if(b&&K.nodeType===We.text){let $t=mn(K.textContent);if(K.textContent!==$t)As(e.removed,{element:K.cloneNode()}),K.textContent=$t}return Pr(Ut.afterSanitizeElements,K,null),mo(K,lt)},kd=function(K,lt,Ot){if(qi[lt])return!1;if(yd(lt,K))return!1;if(Mt&&(lt==="id"||lt==="name")&&((Ot in o)||(Ot in N0)))return!1;let $t=be[lt]||qe.attributeCheck instanceof Function&&qe.attributeCheck(lt,K);if(Xr&&Je(Be,lt))return!0;if(Wi&&Je(_e,lt))return!0;if(!$t)return wd(K)&&xn(Qe.tagNameCheck,K)&&xn(Qe.attributeNameCheck,lt,K)||lt==="is"&&Qe.allowCustomizedBuiltInElements&&xn(Qe.tagNameCheck,Ot);if(Hi[lt])return!0;if(Je(Ai,Es(Ot,di,"")))return!0;if((lt==="src"||lt==="xlink:href"||lt==="href")&&K!=="script"&&Hd(Ot,"data:")===0&&Ts[K])return!0;if(gi&&!Je(Dr,Es(Ot,di,"")))return!0;return!Ot},J0=xe({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),wd=function(K){return!J0[eo(K)]&&Je(Mr,K)},tC=function(K,lt,Ot,$t){if(kt&&typeof u==="object"&&typeof u.getAttributeType==="function"&&!Ot)switch(u.getAttributeType(K,lt)){case"TrustedHTML":return wt($t);case"TrustedScriptURL":return vt($t)}return $t},eC=function(K,lt,Ot,$t){try{if(Ot)K.setAttributeNS(Ot,lt,$t);else K.setAttribute(lt,$t);if(yn(K))return Yi(K),!1;return!0}catch(ie){return go(lt,K),!1}},Sd=function(K,lt){if(ft&&Je(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,lt))return!0;return eo(K)==="attributename"&&zd(lt,"href")!==null},th=function(K,lt){if(Pr(Ut.beforeSanitizeAttributes,K,null),mo(K,lt))return;let Ot=K.attributes;if(!Ot||yn(K))return;be=bd(Ut.uponSanitizeAttribute,be,pi,Yt);let $t={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:be,forceKeepAttr:void 0},ie=Ot.length,fe=Pe(K.nodeName);while(ie--){let me=Ot[ie],{name:ze,namespaceURI:Zr,value:dr}=me,br=Pe(ze),yo=dr,kr=ze==="value"?yo:LC(yo),Td=!1;if($t.attrName=br,$t.attrValue=kr,$t.keepAttr=!0,$t.forceKeepAttr=void 0,Pr(Ut.uponSanitizeAttribute,K,$t),kr=$t.attrValue,Ht&&(br==="id"||br==="name")&&Hd(kr,Wt)!==0)go(ze,K,me),kr=Wt+kr,Td=!0;if(Sd(ze,kr)){go(ze,K,me);continue}if($t.forceKeepAttr)continue;if(!$t.keepAttr){go(ze,K,me);continue}if(!mi&&Je(Qd,kr)){go(ze,K,me);continue}if(b)kr=mn(kr);if(!kd(fe,br,kr)){go(ze,K,me);continue}if(kr=tC(fe,br,Zr,kr),kr!==yo){if(eC(K,ze,Zr,kr)&&Td)Wd(e.removed)}}Pr(Ut.afterSanitizeAttributes,K,null),mo(K,lt)},vs=function(K){let lt=null,Ot=Zl(K);Pr(Ut.beforeSanitizeShadowDOM,K,null);while(lt=Ot.nextNode()){if(Pr(Ut.uponSanitizeShadowNode,lt,null),Jl(lt,K),th(lt,K),Ui(lt.content))vs(lt.content);if(ot(lt)===We.element){let $t=U(lt);if(Ui($t))eh($t),vs($t)}}if(b)Cd(K);Pr(Ut.afterSanitizeShadowDOM,K,null)},eh=function(K){let lt=[{node:K,shadow:null}];while(lt.length>0){let Ot=lt.pop();if(Ot.shadow){vs(Ot.shadow);continue}let $t=Ot.node,ie=ot($t)===We.element,fe=M($t);if(fe)for(let me=fe.length-1;me>=0;--me)lt.push({node:fe[me],shadow:null});if(ie){let me=tt?tt($t):null;if(typeof me==="string"&&Pe(me)==="template"){let ze=$t.content;if(Ui(ze))lt.push({node:ze,shadow:null})}}if(ie){let me=U($t);if(Ui(me))lt.push({node:null,shadow:me},{node:me,shadow:null})}}};return e.sanitize=function(zt){let K=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},lt=null,Ot=null,$t=null,ie=null;if(zl=!zt,zl)zt="<!-->";if(typeof zt!=="string"&&!Bs(zt)){if(zt=EC(zt),typeof zt!=="string")throw bi("dirty is not a string, aborting")}if(!e.isSupported)return zt;if(At)Se=St,be=Yt;else jl(K);if(Ut.uponSanitizeElement.length>0||Ut.uponSanitizeAttribute.length>0)Se=_r(Se);if(Ut.uponSanitizeAttribute.length>0)be=_r(be);e.removed=[];let fe=Zt&&typeof zt!=="string"&&Bs(zt),me=[],ze=Jt;if(fe){K0(zt);let br=ht(zt);if(typeof br==="string"){let yo=Pe(br);if(!Se[yo]||Er[yo])throw Gl(zt),bi("root node is forbidden and cannot be sanitized in-place")}if(yn(zt))throw Gl(zt),bi("root node is clobbered and cannot be sanitized in-place");me=Kl(zt),Jt=sh()}else if(Bs(zt)){if(lt=xd("<!---->"),Ot=lt.ownerDocument.importNode(zt,!0),Ot.nodeType===We.element&&Ot.nodeName==="BODY")lt=Ot;else if(Ot.nodeName==="HTML")lt=Ot;else lt.appendChild(Ot);eh(lt)}else{if(!mt&&!b&&!Tt&&zt.indexOf("<")===-1)return kt&&Ft?wt(zt):zt;if(lt=xd(zt),!lt)return mt?null:Ft?Ct:""}if(lt&&G)Yi(lt.firstChild);let Zr=fe?zt:lt;try{if(fe)eh(zt);let br=Zl(Zr);while($t=br.nextNode())if(Jl($t,Zr),th($t,Zr),Ui($t.content))vs($t.content);if(fe)G0(zt,me)}catch(br){if(fe)Gl(zt),md(zt,me);throw br}finally{Jt=ze}if(fe){if(md(zt,me))throw bi("a node selected for removal could not be safely returned; refusing to sanitize in place");if(b)Ql(zt);return zt}if(mt){if(b)Ql(lt);if(Dt){ie=de.call(lt.ownerDocument);while(lt.firstChild)ie.appendChild(lt.firstChild)}else ie=lt;if(be.shadowroot||be.shadowrootmode)ie=he.call(a,ie,!0);return ie}let dr=Tt?lt.outerHTML:lt.innerHTML;if(Tt&&Se["!doctype"]&<.ownerDocument&<.ownerDocument.doctype&<.ownerDocument.doctype.name&&Je(YC,lt.ownerDocument.doctype.name))dr="<!DOCTYPE "+lt.ownerDocument.doctype.name+`>
|
|
3
|
+
`+dr;if(b)dr=mn(dr);return kt&&Ft?wt(dr):dr},e.setConfig=function(){let zt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};jl(zt),At=!0,St=Se,Yt=be},e.clearConfig=function(){po=null,At=!1,St=null,Yt=null,kt=rt,Ct=""},e.isValidAttribute=function(zt,K,lt){if(!po)jl({});let Ot=Pe(zt),$t=Pe(K);if(typeof lt==="string"&&(Sd(K,lt)||!mi&&Je(Qd,lt)))return!1;return kd(Ot,$t,lt)},e.addHook=function(zt,K){if(typeof K!=="function")return;if(!wr(Ut,zt))return;As(Ut[zt],K)},e.removeHook=function(zt,K){if(!wr(Ut,zt))return;if(K!==void 0){let lt=_C(Ut[zt],K);return lt===-1?void 0:vC(Ut[zt],lt,1)[0]}return Wd(Ut[zt])},e.removeHooks=function(zt){if(!wr(Ut,zt))return;Ut[zt]=[]},e.removeAllHooks=function(){Ut=Jd()},e}var st=sp();var Jo=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,On=/\s/,KC=t((r)=>{let e="",o=0,a=0;while(a<r.length){let s=r.indexOf("%%",a);if(s===-1)break;let n=r.indexOf(`
|
|
4
4
|
`,s);if(n===-1)break;let c=s;while(c>o&&On.test(r[c-1]))c--;e+=r.slice(o,c)+`
|
|
5
5
|
`,o=n+1,a=o}return e+r.slice(o)},"stripAnyComments"),An=t((r)=>r===`
|
|
6
|
-
`||r==="\r","isLineBreak"),ZC=t((r,e)=>{let o=-1;for(let a=e;a<r.length&&On.test(r[a]);a++)if(An(r[a]))o=a;return o},"lastLineBreakInWhitespaceRun"),zs=t((r)=>{let e=0;while(e<r.length&&On.test(r[e])&&!An(r[e]))e++;let o=r.slice(0,e);if(!r.startsWith("---",e))return;let a=[];for(let u=e+3;u<r.length&&On.test(r[u]);u++)if(An(r[u]))a.push(u);if(a.length===0)return;let s=`${o}---`,n=t((u)=>An(r[u])&&r.startsWith(s,u+1)?ZC(r,u+1+s.length):-1,"closingEnd"),c=a[0]+1,l=-1;for(let u=c;u<r.length;u++)if(n(u)!==-1)l=u;if(l===-1)return;let p=a[0];for(let u of a)if(u<l)p=u;let m=p+1;for(let u=m;u<=l;u++){let y=n(u);if(y!==-1)return{indent:o,body:r.slice(m,u),length:y+1}}return},"matchFrontMatter"),Hs=class extends Error{static{t(this,"UnknownDiagramError")}constructor(r){super(r);this.name="UnknownDiagramError"}},Br={},qa=t(function(r,e){let o=zs(r);r=KC((o?r.slice(o.length):r).replace(Jo,""));for(let[a,{detector:s}]of Object.entries(Br))if(s(r,e))return a;throw new Hs(`No diagram type detected matching given configuration for text: ${r}`)},"detectType"),xo=t((...r)=>{for(let{id:e,detector:o,loader:a}of r)up(e,o,a)},"registerLazyLoadedDiagrams"),up=t((r,e,o)=>{if(Br[r])i.warn(`Detector with key ${r} already exists. Overwriting.`);Br[r]={detector:e,loader:o},i.debug(`Detector with key ${r} added${o?" with loader":""}`)},"addDetector"),gc=t((r)=>Br[r].loader,"getDiagramLoader"),mh=t((r,e,{depth:o=2}={})=>{let a={depth:o};if(Array.isArray(e)&&!Array.isArray(r))return e.forEach((s)=>mh(r,s,a)),r;else if(Array.isArray(e)&&Array.isArray(r))return e.forEach((s)=>{if(!r.includes(s))r.push(s)}),r;if(r===void 0||r===null||o<=0)if(r!==void 0&&r!==null&&typeof r==="object"&&typeof e==="object")return Object.assign(r,e);else return e;if(e!==void 0&&e!==null&&typeof r==="object"&&typeof e==="object"){let s=r;Object.entries(e).forEach(([n,c])=>{if(typeof c==="object"){if(c===null)return;if(!Object.hasOwn(r,n))Object.defineProperty(r,n,{value:void 0,writable:!0,enumerable:!0,configurable:!0});if(s[n]===void 0)s[n]=Array.isArray(c)?[]:{};if(typeof s[n]==="object")s[n]=mh(s[n],c,{depth:o-1})}else if(typeof s[n]!=="object")if(Object.hasOwn(r,n))s[n]=c;else Object.defineProperty(r,n,{value:c,writable:!0,enumerable:!0,configurable:!0})})}return r},"assignWithDepth"),Se=mh,Qr="#ffffff",Jr="#f2f2f2",ce=t((r,e)=>e?z(r,{s:-40,l:10}):z(r,{s:-40,l:-10}),"mkBorder"),ap=t((r)=>typeof r==="object"&&r!==null&&!Array.isArray(r),"isPlainObject"),Rr=t((r,e)=>ap(r)&&ap(e)?{...r,...e}:e,"applyOverride"),QC=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.useGradient=!0,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode)this.rowOdd=this.rowOdd||h(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||h(this.mainBkg,10);else this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||f(this.mainBkg,5);if(this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.archEdgeColor=this.archEdgeColor||"#777",this.archEdgeArrowColor=this.archEdgeArrowColor||"#777",this.archEdgeWidth=this.archEdgeWidth||"3",this.archGroupBorderColor=this.archGroupBorderColor||"#000",this.archGroupBorderWidth=this.archGroupBorderWidth||"2px",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);if(e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])}),Object.hasOwn(r,"nodeBorder")&&!Object.hasOwn(r,"useGradient"))this.useGradient=!1}},JC=t((r)=>{let e=new QC;return e.calculate(r),e},"getThemeVariables"),tb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=Pe(255,255,255,0.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.clusterBkg="#302F3D",this.sectionBkgColor=h("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=h(this.sectionBkgColor,10),this.taskBorderColor=Pe(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Pe(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||f(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||h(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal"}updateColors(){this.secondBkg=f(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=f(this.labelBackground,25),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.background,this.taskBkgColor=f(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=nt(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330});for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||nt(this["cScale"+r]);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScalePeer"+r]=this["cScalePeer"+r]||f(this["cScale"+r],10);for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,s:-30,l:-(-10+r*4)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,s:-30,l:-(-7+r*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["pie"+r]=this["cScale"+r];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.mainContrastColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.mainContrastColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let r=0;r<8;r++)this["venn"+(r+1)]=this["venn"+(r+1)]??f(this["cScale"+r],30);this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#FF6B6B",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#1B5E20",complicatedBg:this.cynefin?.complicatedBg||"#0D47A1",chaoticBg:this.cynefin?.chaoticBg||"#BF360C",clearBg:this.cynefin?.clearBg||"#F57F17",confusionBg:this.cynefin?.confusionBg||"#4A148C",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#ff6b6b",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.mainBkg,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.mainBkg},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=f(this.secondaryColor,20),this.git1=f(this.pie2||this.secondaryColor,20),this.git2=f(this.pie3||this.tertiaryColor,20),this.git3=f(this.pie4||z(this.primaryColor,{h:-30}),20),this.git4=f(this.pie5||z(this.primaryColor,{h:-60}),20),this.git5=f(this.pie6||z(this.primaryColor,{h:-90}),10),this.git6=f(this.pie7||z(this.primaryColor,{h:60}),10),this.git7=f(this.pie8||z(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"#2d2d2d",this.emUiStroke=this.emUiStroke||"#555",this.emProcessorFill=this.emProcessorFill||f("#5a3d5c",10),this.emProcessorStroke=this.emProcessorStroke||"#8a6d8c",this.emReadModelFill=this.emReadModelFill||f("#3d5a2d",10),this.emReadModelStroke=this.emReadModelStroke||"#6d8c5c",this.emCommandFill=this.emCommandFill||f("#2d3d5a",10),this.emCommandStroke=this.emCommandStroke||"#5c6d8c",this.emEventFill=this.emEventFill||f("#5a452d",10),this.emEventStroke=this.emEventStroke||"#8c755c",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||f(this.background,5),this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||f(this.background,12),this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||f(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||f(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},eb=t((r)=>{let e=new tb;return e.calculate(r),e},"getThemeVariables"),rb=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=z(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.clusterBkg="#FBFBFF",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=Pe(102,102,255,0.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||h(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||h(this.tertiaryColor,40);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=h(this["cScale"+r],10),this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],25);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||z(this["cScale"+r],{h:180});for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,l:-(7+r*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||nt(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||nt(this.labelTextColor);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.labelTextColor}if(this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||f(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||f(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||z(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-30}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||z(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-40}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||h(nt(this.git0),25),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(Object.keys(this).forEach((o)=>{if(this[o]==="calculated")this[o]=void 0}),typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},Ye=t((r)=>{let e=new rb;return e.calculate(r),e},"getThemeVariables"),ib=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=f("#cde498",10),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.primaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))"}updateColors(){this.actorBorder=h(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||h(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||h(this.tertiaryColor,40);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=h(this["cScale"+r],10),this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],25);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||z(this["cScale"+r],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,s:-30,l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,s:-30,l:-(8+r*5)});if(this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||f(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-30}),this.pie5=this.pie5||z(this.secondaryColor,{l:-30}),this.pie6=this.pie6||z(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B4513",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#C8E6C9",complicatedBg:this.cynefin?.complicatedBg||"#DCEDC8",chaoticBg:this.cynefin?.chaoticBg||"#FFE0B2",clearBg:this.cynefin?.clearBg||"#FFF9C4",confusionBg:this.cynefin?.confusionBg||"#D7CCC8",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},ob=t((r)=>{let e=new ib;return e.calculate(r),e},"getThemeVariables"),sb=class{static{t(this,"Theme")}constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=f(this.contrast,55),this.background="#ffffff",this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){this.secondBkg=f(this.contrast,55),this.border2=this.contrast,this.actorBorder=f(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||nt(this["cScale"+r]);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)if(this.darkMode)this["cScalePeer"+r]=this["cScalePeer"+r]||f(this["cScale"+r],10);else this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{l:-(8+r*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.sectionBkgColor=f(this.contrast,30),this.sectionBkgColor2=f(this.contrast,30),this.taskBorderColor=h(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=f(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=h(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128});for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["pie"+r]=this["cScale"+r];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let r=0;r<8;r++)this["venn"+(r+1)]=this["venn"+(r+1)]??this["cScale"+r];this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=h(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||z(this.primaryColor,{h:-30}),this.git4=this.pie5||z(this.primaryColor,{h:-60}),this.git5=this.pie6||z(this.primaryColor,{h:-90}),this.git6=this.pie7||z(this.primaryColor,{h:60}),this.git7=this.pie8||z(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},ab=t((r)=>{let e=new sb;return e.calculate(r),e},"getThemeVariables"),nb=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.nodeBorder="#000000",this.stateBorder="#000000",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));",this.tertiaryColor="#ffffff",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(pe(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||o,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||e,this.sectionBkgColor2=this.sectionBkgColor2||r,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||r,this.cScale1=this.cScale1||e,this.cScale2=this.cScale2||o,this.cScale3=this.cScale3||z(r,{h:30}),this.cScale4=this.cScale4||z(r,{h:60}),this.cScale5=this.cScale5||z(r,{h:90}),this.cScale6=this.cScale6||z(r,{h:120}),this.cScale7=this.cScale7||z(r,{h:150}),this.cScale8=this.cScale8||z(r,{h:210,l:150}),this.cScale9=this.cScale9||z(r,{h:270}),this.cScale10=this.cScale10||z(r,{h:300}),this.cScale11=this.cScale11||z(r,{h:330}),this.darkMode)for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],75);else for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],25);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||r,this.fillType1=this.fillType1||e,this.fillType2=this.fillType2||z(r,{h:64}),this.fillType3=this.fillType3||z(e,{h:64}),this.fillType4=this.fillType4||z(r,{h:-64}),this.fillType5=this.fillType5||z(e,{h:-64}),this.fillType6=this.fillType6||z(r,{h:128}),this.fillType7=this.fillType7||z(e,{h:128}),this.pie1=this.pie1||r,this.pie2=this.pie2||e,this.pie3=this.pie3||o,this.pie4=this.pie4||z(r,{l:-10}),this.pie5=this.pie5||z(e,{l:-10}),this.pie6=this.pie6||z(o,{l:-10}),this.pie7=this.pie7||z(r,{h:60,l:-10}),this.pie8=this.pie8||z(r,{h:-60,l:-10}),this.pie9=this.pie9||z(r,{h:120,l:0}),this.pie10=this.pie10||z(r,{h:60,l:-20}),this.pie11=this.pie11||z(r,{h:-60,l:-20}),this.pie12=this.pie12||z(r,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},lb=t((r)=>{let e=new nb;return e.calculate(r),e},"getThemeVariables"),hb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#2a2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Pe(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily="arial, sans-serif",this.fontSize="14px",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||"#0b0000",this.git1=this.git1||"#4d1037",this.git2=this.git2||"#3f5258",this.git3=this.git3||"#4f2f1b",this.git4=this.git4||"#6e0a0a",this.git5=this.git5||"#3b0048",this.git6=this.git6||"#995a01",this.git7=this.git7||"#154706",this.gitDarkMode=!0,this.gitDarkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}};var cb=t((r)=>{let e=new hb;return e.calculate(r),e},"getThemeVariables"),ub=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ce("#28253D",this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.clusterBkg="#F9F9FB",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.filterColor="#000000"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#FEF9C3",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(pe(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||o,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||e,this.sectionBkgColor2=this.sectionBkgColor2||r,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground="#F9F9FB",this.altBackground="#F9F9FB",this.stateEdgeLabelBackground="#FFFFFF",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=this.mainBkg;if(this.darkMode)for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],75);else for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],25);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||r,this.fillType1=this.fillType1||e,this.fillType2=this.fillType2||z(r,{h:64}),this.fillType3=this.fillType3||z(e,{h:64}),this.fillType4=this.fillType4||z(r,{h:-64}),this.fillType5=this.fillType5||z(e,{h:-64}),this.fillType6=this.fillType6||z(r,{h:128}),this.fillType7=this.fillType7||z(e,{h:128}),this.pie1=this.pie1||r,this.pie2=this.pie2||e,this.pie3=this.pie3||o,this.pie4=this.pie4||z(r,{l:-10}),this.pie5=this.pie5||z(e,{l:-10}),this.pie6=this.pie6||z(o,{l:-10}),this.pie7=this.pie7||z(r,{h:60,l:-10}),this.pie8=this.pie8||z(r,{h:-60,l:-10}),this.pie9=this.pie9||z(r,{h:120,l:0}),this.pie10=this.pie10||z(r,{h:60,l:-20}),this.pie11=this.pie11||z(r,{h:-60,l:-20}),this.pie12=this.pie12||z(r,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},fb=t((r)=>{let e=new ub;return e.calculate(r),e},"getThemeVariables"),db=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Pe(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.filterColor="#FFFFFF"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground="#16141F",this.altBackground="#16141F",this.compositeTitleBackground="#16141F",this.stateEdgeLabelBackground="#16141F",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#16141F",this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},pb=t((r)=>{let e=new db;return e.calculate(r),e},"getThemeVariables"),gb=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ce("#28253D",this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.clusterBkg="#F9F9FB",this.clusterBorder="#BDBCCC",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=["#FDF4FF","#F0FDFA","#FFF7ED","#ECFEFF","#F0FDF4","#F5F3FF","#FEF2F2","#FEFCE8","#EEF2FF","#F7FEE7","#F0F9FF","#FFF1F2"],this.usecaseActorBorder="#A78BFA",this.usecaseActorBkg="#F5F3FF",this.usecaseBorder="#2DD4BF",this.usecaseBkg="#F0FDFA",this.usecaseBoundaryBorder="#BDBCCC",this.usecaseBoundaryBkg="#FAFAFC",this.usecaseIncludeLine="#38BDF8",this.usecaseExtendLine="#FB923C",this.filterColor="#000000"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(pe(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||"#FFFFFF",this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#F9F9FB",this.compositeTitleBackground=this.compositeTitleBackground||"#F9F9FB",this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad",this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||"white";for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});this.classText=this.classText||this.textColor;for(let s=0;s<8;s++)this["fillType"+s]=this["fillType"+s]||this.bkgColorArray[s];for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["pie"+(s+1)]=this["pie"+(s+1)]||this["cScale"+s];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let s=0;s<8;s++)this["venn"+(s+1)]=this["venn"+(s+1)]??this.borderColorArray[s%this.borderColorArray.length];if(this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLineColor=this.commitLineColor??"#BDBCCC",this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.fontWeight=600,this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},mb=t((r)=>{let e=new gb;return e.calculate(r),e},"getThemeVariables"),yb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Pe(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=[],this.usecaseActorBorder="#A78BFA",this.usecaseBorder="#2DD4BF",this.usecaseBoundaryBorder="#BDBCCC",this.usecaseIncludeLine="#38BDF8",this.usecaseExtendLine="#FB923C",this.filterColor="#FFFFFF"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.rootLabelColor="#FFFFFF",this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||"#16141F",this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||"#16141F",this.altBackground=this.altBackground||"#16141F",this.compositeTitleBackground=this.compositeTitleBackground||"#16141F",this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad",this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||this.background;for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["cScaleInv"+o]=this["cScaleInv"+o]||nt(this["cScale"+o]);for(let o=0;o<this.THEME_COLOR_LIMIT;o++)if(this.darkMode)this["cScalePeer"+o]=this["cScalePeer"+o]||f(this["cScale"+o],10);else this["cScalePeer"+o]=this["cScalePeer"+o]||h(this["cScale"+o],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["cScaleLabel"+o]=h(this["cScale"+o],75);let r=this.darkMode?-4:-1;for(let o=0;o<5;o++)this["surface"+o]=this["surface"+o]||z(this.mainBkg,{h:180,s:-15,l:r*(5+o*3)}),this["surfacePeer"+o]=this["surfacePeer"+o]||z(this.mainBkg,{h:180,s:-15,l:r*(8+o*3)});this.classText=this.classText||this.textColor,["#701a75","#134e4a","#7c2d12","#581c87","#14532d","#4c1d95","#7f1d1d","#713f12"].forEach((o,a)=>{this["fillType"+a]=this["fillType"+a]||o});for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["pie"+(o+1)]=this["pie"+(o+1)]||this["cScale"+o];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||"#28253D",this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let o=0;o<8;o++)this["venn"+(o+1)]=this["venn"+(o+1)]??this.borderColorArray[o%this.borderColorArray.length];if(this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||pe(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#16141F",this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.fontWeight=600,this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},xb=t((r)=>{let e=new yb;return e.calculate(r),e},"getThemeVariables"),tr={base:{getThemeVariables:JC},dark:{getThemeVariables:eb},default:{getThemeVariables:Ye},forest:{getThemeVariables:ob},neutral:{getThemeVariables:ab},neo:{getThemeVariables:lb},"neo-dark":{getThemeVariables:cb},redux:{getThemeVariables:fb},"redux-dark":{getThemeVariables:pb},"redux-color":{getThemeVariables:mb},"redux-dark-color":{getThemeVariables:xb}},qe={flowchart:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,wrappingWidth:120,minNodeWidth:120,inheritDir:!1},swimlane:{useMaxWidth:!0,theme:"redux-color",look:"neo",layout:"swimlane",lineHops:"arc",ignoreCrossLaneEdges:!0,optimizeRanksByCrossings:!0,automaticLaneOrdering:!1},agentflow:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,diagramPadding:8,nodeSpacing:50,rankSpacing:50,wrappingWidth:120,minNodeWidth:120},sequence:{useMaxWidth:!0,theme:"redux-color",look:"neo",hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,htmlLabels:!1,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},state:{useMaxWidth:!0,theme:"redux-color",look:"neo",layout:"elk",wrappingWidth:120,minNodeWidth:120,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5},er:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:0.75,donutHole:0,legendPosition:"right",highlightSlice:""},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,showLegend:!0,legendFontSize:14,legendPadding:10,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,theme:"redux-color",look:"neo",rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,colorBy:"branch",padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:"",nodeWidth:10,nodePadding:12,labelStyle:"legacy"},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,bitOrder:"ascending",paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1,showIcons:!1,defaultIconPack:"",filenameIcons:{},extensionIcons:{}},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1,nodeSeparation:75,idealEdgeLengthMultiplier:1.5,edgeElasticity:0.45,numIter:2500,seed:1},eventmodeling:{useMaxWidth:!0,padding:30,rowHeight:32},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:0.17},usecase:{useMaxWidth:!0,theme:"redux-color",look:"neo",wrappingWidth:120,minNodeWidth:120,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:"normal",usecaseFontSize:12,usecaseFontFamily:'"Open Sans", sans-serif',usecaseFontWeight:"normal",nodeSpacing:50,rankSpacing:50,diagramPadding:20,colorScheme:"role"},venn:{useMaxWidth:!0,theme:"redux-color",look:"neo",width:800,height:450,padding:8,useDebugLayout:!1},cynefin:{useMaxWidth:!0,width:800,height:600,padding:40,showDomainDescriptions:!0,boundaryAmplitude:8,seed:0},theme:"default",look:"classic",handDrawnSeed:0,layout:"elk",maxTextSize:50000,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},fp={...qe,deterministicIDSeed:void 0,elk:{mergeEdges:!1,straightenEdges:!0,lineHops:!0,preset:"default",nodePlacementStrategy:void 0,layeringStrategy:void 0,cycleBreakingStrategy:void 0,layeringLayerBound:4,nodePlacementAlignment:void 0,forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES",keepEntryNodeOnTop:!1,orientFeedbackEdges:!0},themeCSS:void 0,themeVariables:tr.default.getThemeVariables(),sequence:{...qe.sequence,messageFont:t(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:t(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:t(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{theme:qe.class?.theme,look:qe.class?.look,layout:qe.class?.layout,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...qe.gantt,tickInterval:void 0,useWidth:void 0},c4:{...qe.c4,useWidth:void 0,personFont:t(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...qe.flowchart,inheritDir:!1},external_personFont:t(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:t(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:t(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:t(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:t(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:t(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:t(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:t(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:t(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:t(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:t(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:t(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:t(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:t(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:t(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:t(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:t(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:t(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:t(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:t(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:t(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...qe.pie,useWidth:984},xyChart:{...qe.xyChart,useWidth:void 0},requirement:{...qe.requirement,useWidth:void 0},packet:{...qe.packet},eventmodeling:{...qe.eventmodeling},treeView:{...qe.treeView,useWidth:void 0},radar:{...qe.radar},usecase:{...qe.usecase},railroad:{...qe.railroad,fontSize:void 0,fontFamily:void 0,terminalFill:void 0,terminalStroke:void 0,terminalTextColor:void 0,nonTerminalFill:void 0,nonTerminalStroke:void 0,nonTerminalTextColor:void 0,lineColor:void 0,markerFill:void 0,commentFill:void 0,commentStroke:void 0,commentTextColor:void 0,specialFill:void 0,specialStroke:void 0,ruleNameColor:void 0},ishikawa:{...qe.ishikawa},sankey:{...qe.sankey,nodeColors:void 0},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","},venn:{...qe.venn},cynefin:{...qe.cynefin}},dp=t((r,e="")=>Object.keys(r).reduce((o,a)=>{if(Array.isArray(r[a]))return o;else if(typeof r[a]==="object"&&r[a]!==null)return[...o,e+a,...dp(r[a],"")];return[...o,e+a]},[]),"keyify"),Cb=new Set(dp(fp,"")),F=fp,bb={"flowchart-v2":"flowchart","flowchart-elk":"flowchart",classDiagram:"class",stateDiagram:"state",xychart:"xyChart",railroadAbnf:"railroad",railroadEbnf:"railroad",railroadPeg:"railroad"},kb=t((r)=>bb[r]??r,"getDiagramConfigKey"),wb={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},Sb=t((r,e)=>{for(let o of Object.keys(r)){let a=r[o];if(o.startsWith("__")||o.includes("proto")||o.includes("constr")||typeof a!=="string"||!e.test(a))i.debug("sanitize deleting dictionary entry:",o,a),delete r[o]}},"sanitizeDictionaryConfig"),Ds=t((r)=>{if(i.debug("sanitizeDirective called with",r),typeof r!=="object"||r==null)return;if(Array.isArray(r)){r.forEach((e)=>Ds(e));return}for(let e of Object.keys(r)){if(i.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!Cb.has(e)||r[e]==null){i.debug("sanitize deleting key: ",e),delete r[e];continue}if(typeof r[e]==="object"){let a=wb[e];if(a)Sb(r[e],a);else i.debug("sanitizing object",e),Ds(r[e]);continue}let o=["themeCSS","fontFamily","altFontFamily"];for(let a of o)if(e.includes(a))i.debug("sanitizing css option",e),r[e]=Us(r[e])}if(r.themeVariables)for(let e of Object.keys(r.themeVariables)){let o=r.themeVariables[e];if(o?.match&&!o.match(/^[\d "#%(),.;A-Za-z]+$/))r.themeVariables[e]=""}i.debug("After sanitization",r)},"sanitizeDirective"),Us=t((r)=>{let e=0,o=0;for(let a of r){if(e<o)return"{ /* ERROR: Unbalanced CSS */ }";if(a==="{")e++;else if(a==="}")o++}if(e!==o)return"{ /* ERROR: Unbalanced CSS */ }";return r},"sanitizeCss"),mr=Object.freeze(F),Tb=["theme","look","layout"],_b=new Set(["classic","handDrawn","neo"]),Bb=t((r,e)=>{if(r==="theme")return e==="null"||Object.hasOwn(tr,e);return r!=="look"||_b.has(e)},"isUsableAppearance"),vb=t((r,e,o)=>{if(!r)return;return[r[e]?.[o],r[o]].find((s)=>s!==void 0&&Bb(o,s))},"readAppearance"),ln=t((r)=>r===!1||["false","null","0"].includes(String(r).trim().toLowerCase())?!1:!0,"evaluate"),pr=Se({},mr),In,Dn={},ki=[],Is=Se({},mr),$s,Lb=t((r,e)=>{if(!$s)return;let o=[e,...[...ki].reverse(),Dn,mr],a=r[$s];for(let s of Tb)for(let n of o){let c=vb(n,$s,s);if(c===void 0)continue;if(r[s]=c,a?.[s]!==void 0)a[s]=c;break}},"resolveAppearance"),ts=t((r,e)=>{let o=Se({},r),a={};for(let n of e)pp(n),a=Se(a,n);if(o=Se(o,a),Lb(o,a),(Boolean(a.theme)||o.theme!==r.theme)&&o.theme&&Object.hasOwn(tr,o.theme)){let n=Se({},In),c=Se(n.themeVariables||{},a.themeVariables);o.themeVariables=tr[o.theme].getThemeVariables(c)}return Is=o,Ab(Is),Is},"updateCurrentConfig"),_o=t((r)=>{$s=r===void 0?void 0:kb(r),ts(pr,ki)},"setDiagramConfigScope"),vc=t((r)=>{if(pr=Se({},mr),pr=Se(pr,r),Dn=Se({},r),r.theme&&Object.hasOwn(tr,r.theme))pr.themeVariables=tr[r.theme].getThemeVariables(r.themeVariables);return ts(pr,ki),pr},"setSiteConfig"),yc=t((r)=>{In=Se({},r)},"saveConfigFromInitialize"),bc=t((r)=>(pr=Se(pr,r),Dn=Se(Dn,r),ts(pr,ki),pr),"updateSiteConfig"),js=t(()=>Se({},pr),"getSiteConfig"),qs=t((r)=>(ts(Is,[r]),A()),"setConfig"),A=t(()=>Se({},Is),"getConfig"),pp=t((r)=>{if(!r)return;["secure",...pr.secure??[]].forEach((e)=>{if(Object.hasOwn(r,e))i.debug(`Denied attempt to modify a secure key ${e}`,r[e]),delete r[e]}),Object.keys(r).forEach((e)=>{if(e.startsWith("__"))delete r[e]}),Object.keys(r).forEach((e)=>{if(typeof r[e]==="string"&&(r[e].includes("<")||r[e].includes(">")||r[e].includes("url(data:")))delete r[e];if(typeof r[e]==="object")pp(r[e])})},"sanitize"),xc=t((r)=>{if(Ds(r),r.fontFamily&&!r.themeVariables?.fontFamily)r.themeVariables={...r.themeVariables,fontFamily:r.fontFamily};ki.push(r),ts(pr,ki)},"addDirective"),Ei=t((r=pr)=>{ki=[],$s=void 0,ts(r,ki)},"reset"),Fb={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.",FLOWCHART_HTML_LABELS_DEPRECATED:"flowchart.htmlLabels is deprecated. Please use global htmlLabels instead."},np={},gp=t((r)=>{if(np[r])return;i.warn(Fb[r]),np[r]=!0},"issueWarning"),Ab=t((r)=>{if(!r)return;if(r.lazyLoadedDiagrams||r.loadExternalDiagramsAtStartup)gp("LAZY_LOAD_DEPRECATED")},"checkConfig"),_c=t(()=>{let r={};if(In)r=Se(r,In);for(let e of ki)r=Se(r,e);return r},"getUserDefinedConfig"),Xe=t((r)=>{if(r.flowchart?.htmlLabels!=null)gp("FLOWCHART_HTML_LABELS_DEPRECATED");return ln(r.htmlLabels??r.flowchart?.htmlLabels??!0)},"getEffectiveHtmlLabels"),na=/<\/?br\s*\/?>/gi,Mb=new RegExp(na.source,"i"),Eb=t((r)=>{if(!r)return[""];return xp(r).replace(/\\n/g,"#br#").split("#br#")},"getRows"),Ob=(()=>{let r=!1;return()=>{if(!r)mp(),r=!0}})();function mp(){st.addHook("beforeSanitizeAttributes",(e)=>{if(e.tagName==="A"&&e.hasAttribute("target"))e.setAttribute("data-temp-href-target",e.getAttribute("target")??"")}),st.addHook("afterSanitizeAttributes",(e)=>{if(e.tagName==="A"&&e.hasAttribute("data-temp-href-target")){if(e.setAttribute("target",e.getAttribute("data-temp-href-target")??""),e.removeAttribute("data-temp-href-target"),e.getAttribute("target")==="_blank")e.setAttribute("rel","noopener")}})}t(mp,"setupDompurifyHooks");var yp=t((r)=>(Ob(),st.sanitize(r)),"removeScript"),lp=t((r,e)=>{if(Xe(e)){let o=e.securityLevel;if(o==="antiscript"||o==="strict"||o==="sandbox")r=yp(r);else if(o!=="loose")r=xp(r),r=r.replace(/</g,"<").replace(/>/g,">"),r=r.replace(/=/g,"="),r=Pb(r)}return r},"sanitizeMore"),j=t((r,e)=>{if(!r)return r;if(e.dompurifyConfig)r=st.sanitize(lp(r,e),e.dompurifyConfig).toString();else r=st.sanitize(lp(r,e),{FORBID_TAGS:["style"]}).toString();return r},"sanitizeText"),Ib=t((r,e)=>{if(typeof r==="string")return j(r,e);return r.flat().map((o)=>j(o,e))},"sanitizeTextOrArray"),$b=t((r)=>Mb.test(r),"hasBreaks"),Db=t((r)=>r.split(na),"splitBreaks"),Pb=t((r)=>r.replace(/#br#/g,"<br/>"),"placeholderToBreak"),xp=t((r)=>r.replace(na,"#br#"),"breakToPlaceholder"),Vs=t((r)=>{let e="";if(r)e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=CSS.escape(e);return e},"getUrl"),Rb=t(function(...r){let e=r.filter((o)=>!isNaN(o));return Math.max(...e)},"getMax"),qb=t(function(...r){let e=r.filter((o)=>!isNaN(o));return Math.min(...e)},"getMin"),nr=t(function(r){let e=r.split(/(,)/),o=[];for(let a=0;a<e.length;a++){let s=e[a];if(s===","&&a>0&&a+1<e.length){let n=e[a-1],c=e[a+1];if(Nb(n,c))s=n+","+c,a++,o.pop()}o.push(Wb(s))}return o.join("")},"parseGenericTypes"),yh=t((r,e)=>Math.max(0,r.split(e).length-1),"countOccurrence"),Nb=t((r,e)=>{let o=yh(r,"~"),a=yh(e,"~");return o===1&&a===1},"shouldCombineSets"),Wb=t((r)=>{let e=yh(r,"~"),o=!1;if(e<=1)return r;if(e%2!==0&&r.startsWith("~"))r=r.substring(1),o=!0;let a=[...r],s=a.indexOf("~"),n=a.lastIndexOf("~");while(s!==-1&&n!==-1&&s!==n)a[s]="<",a[n]=">",s=a.indexOf("~"),n=a.lastIndexOf("~");if(o)a.unshift("~");return a.join("")},"processSet"),hp=t(()=>window.MathMLElement!==void 0,"isMathMLSupported"),Mn=/\$\$(.*?)\$\$/g,$e=t((r)=>(r.match(Mn)?.length??0)>0,"hasKatex"),Va=t(async(r,e)=>{let o=document.createElement("div");o.innerHTML=await Ga(r,e),o.id="katex-temp",o.style.visibility="hidden",o.style.position="absolute",o.style.top="0",document.querySelector("body")?.insertAdjacentElement("beforeend",o);let s={width:o.clientWidth,height:o.clientHeight};return o.remove(),s},"calculateMathMLDimensions"),zb=t(async(r,e)=>{if(!$e(r))return r;if(!(hp()||e.legacyMathML||e.forceLegacyMathML))return r.replace(Mn,"MathML is unsupported in this environment.");{let{default:o}=await (S("nj0cv1cq"),import("./chunk-nj0cv1cq.js")),a=e.forceLegacyMathML||!hp()&&e.legacyMathML?"htmlAndMathml":"mathml";return r.split(na).map((s)=>$e(s)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${s}</div>`:`<div>${s}</div>`).join("").replace(Mn,(s,n)=>o.renderToString(n,{throwOnError:!0,displayMode:!0,output:a}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}return r.replace(Mn,"Katex is not supported in @mermaid-js/tiny. Please use the full mermaid library.")},"renderKatexUnsanitized"),Ga=t(async(r,e)=>j(await zb(r,e),e),"renderKatexSanitized"),C={getRows:Eb,sanitizeText:j,sanitizeTextOrArray:Ib,hasBreaks:$b,splitBreaks:Db,lineBreakRegex:na,removeScript:yp,getUrl:Vs,evaluate:ln,getMax:Rb,getMin:qb},Hb=t(function(r,e){for(let o of e)r.attr(o[0],o[1])},"d3Attrs"),Yb=t(function(r,e,o){let a=new Map;if(o)a.set("width","100%"),a.set("style",`max-width: ${e}px;`);else a.set("height",r),a.set("width",e);return a},"calculateSvgSizeAttrs"),W=t(function(r,e,o,a){let s=Yb(e,o,a);Hb(r,s)},"configureSvgSize"),pn=t(function(r,e,o,a){let s=e.node().getBBox(),{width:n,height:c}=s;i.info(`SVG bounds: ${n}x${c}`,s);let l=0,p=0;i.info(`Graph bounds: ${l}x${p}`,r),l=n+o*2,p=c+o*2,i.info(`Calculated bounds: ${l}x${p}`),W(e,p,l,a);let m=`${s.x-o} ${s.y-o} ${s.width+2*o} ${s.height+2*o}`;e.attr("viewBox",m)},"setupGraphViewbox"),En={};function wo(r){return[...r.cssRules].map((e)=>e.cssText).join(`
|
|
6
|
+
`||r==="\r","isLineBreak"),ZC=t((r,e)=>{let o=-1;for(let a=e;a<r.length&&On.test(r[a]);a++)if(An(r[a]))o=a;return o},"lastLineBreakInWhitespaceRun"),zs=t((r)=>{let e=0;while(e<r.length&&On.test(r[e])&&!An(r[e]))e++;let o=r.slice(0,e);if(!r.startsWith("---",e))return;let a=[];for(let u=e+3;u<r.length&&On.test(r[u]);u++)if(An(r[u]))a.push(u);if(a.length===0)return;let s=`${o}---`,n=t((u)=>An(r[u])&&r.startsWith(s,u+1)?ZC(r,u+1+s.length):-1,"closingEnd"),c=a[0]+1,l=-1;for(let u=c;u<r.length;u++)if(n(u)!==-1)l=u;if(l===-1)return;let p=a[0];for(let u of a)if(u<l)p=u;let m=p+1;for(let u=m;u<=l;u++){let y=n(u);if(y!==-1)return{indent:o,body:r.slice(m,u),length:y+1}}return},"matchFrontMatter"),Hs=class extends Error{static{t(this,"UnknownDiagramError")}constructor(r){super(r);this.name="UnknownDiagramError"}},Br={},qa=t(function(r,e){let o=zs(r);r=KC((o?r.slice(o.length):r).replace(Jo,""));for(let[a,{detector:s}]of Object.entries(Br))if(s(r,e))return a;throw new Hs(`No diagram type detected matching given configuration for text: ${r}`)},"detectType"),xo=t((...r)=>{for(let{id:e,detector:o,loader:a}of r)up(e,o,a)},"registerLazyLoadedDiagrams"),up=t((r,e,o)=>{if(Br[r])i.warn(`Detector with key ${r} already exists. Overwriting.`);Br[r]={detector:e,loader:o},i.debug(`Detector with key ${r} added${o?" with loader":""}`)},"addDetector"),gc=t((r)=>Br[r].loader,"getDiagramLoader"),mh=t((r,e,{depth:o=2}={})=>{let a={depth:o};if(Array.isArray(e)&&!Array.isArray(r))return e.forEach((s)=>mh(r,s,a)),r;else if(Array.isArray(e)&&Array.isArray(r))return e.forEach((s)=>{if(!r.includes(s))r.push(s)}),r;if(r===void 0||r===null||o<=0)if(r!==void 0&&r!==null&&typeof r==="object"&&typeof e==="object")return Object.assign(r,e);else return e;if(e!==void 0&&e!==null&&typeof r==="object"&&typeof e==="object"){let s=r;Object.entries(e).forEach(([n,c])=>{if(typeof c==="object"){if(c===null)return;if(!Object.hasOwn(r,n))Object.defineProperty(r,n,{value:void 0,writable:!0,enumerable:!0,configurable:!0});if(s[n]===void 0)s[n]=Array.isArray(c)?[]:{};if(typeof s[n]==="object")s[n]=mh(s[n],c,{depth:o-1})}else if(typeof s[n]!=="object")if(Object.hasOwn(r,n))s[n]=c;else Object.defineProperty(r,n,{value:c,writable:!0,enumerable:!0,configurable:!0})})}return r},"assignWithDepth"),Ae=mh,Qr="#ffffff",Jr="#f2f2f2",ce=t((r,e)=>e?z(r,{s:-40,l:10}):z(r,{s:-40,l:-10}),"mkBorder"),ap=t((r)=>typeof r==="object"&&r!==null&&!Array.isArray(r),"isPlainObject"),Rr=t((r,e)=>ap(r)&&ap(e)?{...r,...e}:e,"applyOverride"),QC=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.useGradient=!0,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode)this.rowOdd=this.rowOdd||h(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||h(this.mainBkg,10);else this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||f(this.mainBkg,5);if(this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.archEdgeColor=this.archEdgeColor||"#777",this.archEdgeArrowColor=this.archEdgeArrowColor||"#777",this.archEdgeWidth=this.archEdgeWidth||"3",this.archGroupBorderColor=this.archGroupBorderColor||"#000",this.archGroupBorderWidth=this.archGroupBorderWidth||"2px",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);if(e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])}),Object.hasOwn(r,"nodeBorder")&&!Object.hasOwn(r,"useGradient"))this.useGradient=!1}},JC=t((r)=>{let e=new QC;return e.calculate(r),e},"getThemeVariables"),tb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=Ie(255,255,255,0.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.clusterBkg="#302F3D",this.sectionBkgColor=h("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=h(this.sectionBkgColor,10),this.taskBorderColor=Ie(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Ie(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||f(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||h(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal"}updateColors(){this.secondBkg=f(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=f(this.labelBackground,25),this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.background,this.taskBkgColor=f(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=nt(this.doneTaskBkgColor),this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330});for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||nt(this["cScale"+r]);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScalePeer"+r]=this["cScalePeer"+r]||f(this["cScale"+r],10);for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,s:-30,l:-(-10+r*4)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,s:-30,l:-(-7+r*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["pie"+r]=this["cScale"+r];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.mainContrastColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.mainContrastColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let r=0;r<8;r++)this["venn"+(r+1)]=this["venn"+(r+1)]??f(this["cScale"+r],30);this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#FF6B6B",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#1B5E20",complicatedBg:this.cynefin?.complicatedBg||"#0D47A1",chaoticBg:this.cynefin?.chaoticBg||"#BF360C",clearBg:this.cynefin?.clearBg||"#F57F17",confusionBg:this.cynefin?.confusionBg||"#4A148C",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#ff6b6b",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.mainBkg,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.mainBkg},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=f(this.secondaryColor,20),this.git1=f(this.pie2||this.secondaryColor,20),this.git2=f(this.pie3||this.tertiaryColor,20),this.git3=f(this.pie4||z(this.primaryColor,{h:-30}),20),this.git4=f(this.pie5||z(this.primaryColor,{h:-60}),20),this.git5=f(this.pie6||z(this.primaryColor,{h:-90}),10),this.git6=f(this.pie7||z(this.primaryColor,{h:60}),10),this.git7=f(this.pie8||z(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"#2d2d2d",this.emUiStroke=this.emUiStroke||"#555",this.emProcessorFill=this.emProcessorFill||f("#5a3d5c",10),this.emProcessorStroke=this.emProcessorStroke||"#8a6d8c",this.emReadModelFill=this.emReadModelFill||f("#3d5a2d",10),this.emReadModelStroke=this.emReadModelStroke||"#6d8c5c",this.emCommandFill=this.emCommandFill||f("#2d3d5a",10),this.emCommandStroke=this.emCommandStroke||"#5c6d8c",this.emEventFill=this.emEventFill||f("#5a452d",10),this.emEventStroke=this.emEventStroke||"#8c755c",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||f(this.background,5),this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||f(this.background,12),this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||f(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||f(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},eb=t((r)=>{let e=new tb;return e.calculate(r),e},"getThemeVariables"),rb=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=z(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.clusterBkg="#FBFBFF",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=Ie(102,102,255,0.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.noteFontWeight=this.noteFontWeight||"normal",this.fontWeight=this.fontWeight||"normal",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!1,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow(1px 2px 2px rgba(185, 185, 185, 1))",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||h(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||h(this.tertiaryColor,40);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=h(this["cScale"+r],10),this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],25);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||z(this["cScale"+r],{h:180});for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,l:-(7+r*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||nt(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||nt(this.labelTextColor);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.labelTextColor}if(this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||f(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||f(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||z(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-30}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||z(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-40}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||h(nt(this.git0),25),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(Object.keys(this).forEach((o)=>{if(this[o]==="calculated")this[o]=void 0}),typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},Ye=t((r)=>{let e=new rb;return e.calculate(r),e},"getThemeVariables"),ib=class{static{t(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=f("#cde498",10),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.primaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.5))"}updateColors(){this.actorBorder=h(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||h(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||h(this.tertiaryColor,40);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=h(this["cScale"+r],10),this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],25);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||z(this["cScale"+r],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{h:30,s:-30,l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{h:30,s:-30,l:-(8+r*5)});if(this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||f(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-30}),this.pie5=this.pie5||z(this.secondaryColor,{l:-30}),this.pie6=this.pie6||z(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.venn1=this.venn1??z(this.primaryColor,{l:-30}),this.venn2=this.venn2??z(this.secondaryColor,{l:-30}),this.venn3=this.venn3??z(this.tertiaryColor,{l:-30}),this.venn4=this.venn4??z(this.primaryColor,{h:60,l:-30}),this.venn5=this.venn5??z(this.primaryColor,{h:-60,l:-30}),this.venn6=this.venn6??z(this.secondaryColor,{h:60,l:-30}),this.venn7=this.venn7??z(this.primaryColor,{h:120,l:-30}),this.venn8=this.venn8??z(this.secondaryColor,{h:120,l:-30}),this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B4513",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#C8E6C9",complicatedBg:this.cynefin?.complicatedBg||"#DCEDC8",chaoticBg:this.cynefin?.chaoticBg||"#FFE0B2",clearBg:this.cynefin?.clearBg||"#FFF9C4",confusionBg:this.cynefin?.confusionBg||"#D7CCC8",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||nt(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||nt(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},ob=t((r)=>{let e=new ib;return e.calculate(r),e},"getThemeVariables"),sb=class{static{t(this,"Theme")}constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=f(this.contrast,55),this.background="#ffffff",this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.lineColor=nt(this.background),this.textColor=nt(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.radius=5,this.strokeWidth=1,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal",this.rowOdd=this.rowOdd||f(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.useGradient=!0,this.gradientStart=this.primaryBorderColor,this.gradientStop=this.secondaryBorderColor,this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,1))"}updateColors(){this.secondBkg=f(this.contrast,55),this.border2=this.contrast,this.actorBorder=f(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||nt(this["cScale"+r]);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)if(this.darkMode)this["cScalePeer"+r]=this["cScalePeer"+r]||f(this["cScale"+r],10);else this["cScalePeer"+r]=this["cScalePeer"+r]||h(this["cScale"+r],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||z(this.mainBkg,{l:-(5+r*5)}),this["surfacePeer"+r]=this["surfacePeer"+r]||z(this.mainBkg,{l:-(8+r*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.sectionBkgColor=f(this.contrast,30),this.sectionBkgColor2=f(this.contrast,30),this.taskBorderColor=h(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=f(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=h(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=z(this.primaryColor,{h:64}),this.fillType3=z(this.secondaryColor,{h:64}),this.fillType4=z(this.primaryColor,{h:-64}),this.fillType5=z(this.secondaryColor,{h:-64}),this.fillType6=z(this.primaryColor,{h:128}),this.fillType7=z(this.secondaryColor,{h:128});for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["pie"+r]=this["cScale"+r];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let r=0;r<8;r++)this["venn"+(r+1)]=this["venn"+(r+1)]??this["cScale"+r];this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.cynefin={domainFontSize:this.cynefin?.domainFontSize||16,itemFontSize:this.cynefin?.itemFontSize||12,boundaryColor:this.cynefin?.boundaryColor||this.lineColor,boundaryWidth:this.cynefin?.boundaryWidth||2,cliffColor:this.cynefin?.cliffColor||"#8B0000",cliffWidth:this.cynefin?.cliffWidth||4,arrowColor:this.cynefin?.arrowColor||this.lineColor,arrowWidth:this.cynefin?.arrowWidth||2,complexBg:this.cynefin?.complexBg||"#E8F5E9",complicatedBg:this.cynefin?.complicatedBg||"#E3F2FD",chaoticBg:this.cynefin?.chaoticBg||"#FBE9E7",clearBg:this.cynefin?.clearBg||"#FFF8E1",confusionBg:this.cynefin?.confusionBg||"#F3E5F5",textColor:this.cynefin?.textColor||this.textColor,labelColor:this.cynefin?.labelColor||this.primaryTextColor},this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,dataLabelColor:this.xyChart?.dataLabelColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||0.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||0.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.wardleyEvolutionColor=this.wardleyEvolutionColor||"#dc3545",this.wardley={backgroundColor:this.wardley?.backgroundColor||this.background,axisColor:this.wardley?.axisColor||this.lineColor,axisTextColor:this.wardley?.axisTextColor||this.primaryTextColor,gridColor:this.wardley?.gridColor||this.gridColor,componentFill:this.wardley?.componentFill||this.background,componentStroke:this.wardley?.componentStroke||this.lineColor,componentLabelColor:this.wardley?.componentLabelColor||this.primaryTextColor,linkStroke:this.wardley?.linkStroke||this.lineColor,evolutionStroke:this.wardley?.evolutionStroke||this.wardleyEvolutionColor,annotationStroke:this.wardley?.annotationStroke||this.lineColor,annotationTextColor:this.wardley?.annotationTextColor||this.primaryTextColor,annotationFill:this.wardley?.annotationFill||this.background},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=h(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||z(this.primaryColor,{h:-30}),this.git4=this.pie5||z(this.primaryColor,{h:-60}),this.git5=this.pie6||z(this.primaryColor,{h:-90}),this.git6=this.pie7||z(this.primaryColor,{h:60}),this.git7=this.pie8||z(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.emUiFill=this.emUiFill||"white",this.emUiStroke=this.emUiStroke||"#dbdada",this.emProcessorFill=this.emProcessorFill||"#edb3f6",this.emProcessorStroke=this.emProcessorStroke||"#b88cbf",this.emReadModelFill=this.emReadModelFill||"#d3f1a2",this.emReadModelStroke=this.emReadModelStroke||"#a3b732",this.emCommandFill=this.emCommandFill||"#bcd6fe",this.emCommandStroke=this.emCommandStroke||"#679ac3",this.emEventFill=this.emEventFill||"#ffb778",this.emEventStroke=this.emEventStroke||"#c19a0f",this.emSwimlaneBackgroundOdd=this.emSwimlaneBackgroundOdd||"rgb(250,250,250)",this.emSwimlaneBackgroundStroke=this.emSwimlaneBackgroundStroke||"rgb(240,240,240)",this.emArrowhead=this.emArrowhead||this.lineColor,this.emRelationStroke=this.emRelationStroke||this.lineColor,this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},ab=t((r)=>{let e=new sb;return e.calculate(r),e},"getThemeVariables"),nb=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=2,this.primaryBorderColor=ce(this.primaryColor,this.darkMode),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.nodeBorder="#000000",this.stateBorder="#000000",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 0px 1px 2px rgba(0, 0, 0, 0.25));",this.tertiaryColor="#ffffff",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(ue(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});if(this.sectionBkgColor=this.sectionBkgColor||o,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||e,this.sectionBkgColor2=this.sectionBkgColor2||r,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||r,this.cScale1=this.cScale1||e,this.cScale2=this.cScale2||o,this.cScale3=this.cScale3||z(r,{h:30}),this.cScale4=this.cScale4||z(r,{h:60}),this.cScale5=this.cScale5||z(r,{h:90}),this.cScale6=this.cScale6||z(r,{h:120}),this.cScale7=this.cScale7||z(r,{h:150}),this.cScale8=this.cScale8||z(r,{h:210,l:150}),this.cScale9=this.cScale9||z(r,{h:270}),this.cScale10=this.cScale10||z(r,{h:300}),this.cScale11=this.cScale11||z(r,{h:330}),this.darkMode)for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],75);else for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],25);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||r,this.fillType1=this.fillType1||e,this.fillType2=this.fillType2||z(r,{h:64}),this.fillType3=this.fillType3||z(e,{h:64}),this.fillType4=this.fillType4||z(r,{h:-64}),this.fillType5=this.fillType5||z(e,{h:-64}),this.fillType6=this.fillType6||z(r,{h:128}),this.fillType7=this.fillType7||z(e,{h:128}),this.pie1=this.pie1||r,this.pie2=this.pie2||e,this.pie3=this.pie3||o,this.pie4=this.pie4||z(r,{l:-10}),this.pie5=this.pie5||z(e,{l:-10}),this.pie6=this.pie6||z(o,{l:-10}),this.pie7=this.pie7||z(r,{h:60,l:-10}),this.pie8=this.pie8||z(r,{h:-60,l:-10}),this.pie9=this.pie9||z(r,{h:120,l:0}),this.pie10=this.pie10||z(r,{h:60,l:-20}),this.pie11=this.pie11||z(r,{h:-60,l:-20}),this.pie12=this.pie12||z(r,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},lb=t((r)=>{let e=new nb;return e.calculate(r),e},"getThemeVariables"),hb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#2a2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Ie(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily="arial, sans-serif",this.fontSize="14px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=3,this.strokeWidth=1,this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily="arial, sans-serif",this.fontSize="14px",this.useGradient=!0,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="drop-shadow( 1px 2px 2px rgba(185,185,185,0.2))",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.noteFontWeight="normal",this.fontWeight="normal"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||"#0b0000",this.git1=this.git1||"#4d1037",this.git2=this.git2||"#3f5258",this.git3=this.git3||"#4f2f1b",this.git4=this.git4||"#6e0a0a",this.git5=this.git5||"#3b0048",this.git6=this.git6||"#995a01",this.git7=this.git7||"#154706",this.gitDarkMode=!0,this.gitDarkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}};var cb=t((r)=>{let e=new hb;return e.calculate(r),e},"getThemeVariables"),ub=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ce("#28253D",this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.clusterBkg="#F9F9FB",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.filterColor="#000000"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#FEF9C3",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.noteFontWeight=600,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(ue(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});this.sectionBkgColor=this.sectionBkgColor||o,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||e,this.sectionBkgColor2=this.sectionBkgColor2||r,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.compositeTitleBackground="#F9F9FB",this.altBackground="#F9F9FB",this.stateEdgeLabelBackground="#FFFFFF",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=this.mainBkg;if(this.darkMode)for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],75);else for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScale"+s]=h(this["cScale"+s],25);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||r,this.fillType1=this.fillType1||e,this.fillType2=this.fillType2||z(r,{h:64}),this.fillType3=this.fillType3||z(e,{h:64}),this.fillType4=this.fillType4||z(r,{h:-64}),this.fillType5=this.fillType5||z(e,{h:-64}),this.fillType6=this.fillType6||z(r,{h:128}),this.fillType7=this.fillType7||z(e,{h:128}),this.pie1=this.pie1||r,this.pie2=this.pie2||e,this.pie3=this.pie3||o,this.pie4=this.pie4||z(r,{l:-10}),this.pie5=this.pie5||z(e,{l:-10}),this.pie6=this.pie6||z(o,{l:-10}),this.pie7=this.pie7||z(r,{h:60,l:-10}),this.pie8=this.pie8||z(r,{h:-60,l:-10}),this.pie9=this.pie9||z(r,{h:120,l:0}),this.pie10=this.pie10||z(r,{h:60,l:-20}),this.pie11=this.pie11||z(r,{h:-60,l:-20}),this.pie12=this.pie12||z(r,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},fb=t((r)=>{let e=new ub;return e.calculate(r),e},"getThemeVariables"),db=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Ie(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.filterColor="#FFFFFF"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.compositeBackground="#16141F",this.altBackground="#16141F",this.compositeTitleBackground="#16141F",this.stateEdgeLabelBackground="#16141F",this.fontWeight=600,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||z(this.primaryColor,{h:30}),this.cScale4=this.cScale4||z(this.primaryColor,{h:60}),this.cScale5=this.cScale5||z(this.primaryColor,{h:90}),this.cScale6=this.cScale6||z(this.primaryColor,{h:120}),this.cScale7=this.cScale7||z(this.primaryColor,{h:150}),this.cScale8=this.cScale8||z(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||z(this.primaryColor,{h:270}),this.cScale10=this.cScale10||z(this.primaryColor,{h:300}),this.cScale11=this.cScale11||z(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],75);else for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScale"+e]=h(this["cScale"+e],25);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleInv"+e]=this["cScaleInv"+e]||nt(this["cScale"+e]);for(let e=0;e<this.THEME_COLOR_LIMIT;e++)if(this.darkMode)this["cScalePeer"+e]=this["cScalePeer"+e]||f(this["cScale"+e],10);else this["cScalePeer"+e]=this["cScalePeer"+e]||h(this["cScale"+e],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let e=0;e<this.THEME_COLOR_LIMIT;e++)this["cScaleLabel"+e]=this["cScaleLabel"+e]||this.scaleLabelColor;let r=this.darkMode?-4:-1;for(let e=0;e<5;e++)this["surface"+e]=this["surface"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(5+e*3)}),this["surfacePeer"+e]=this["surfacePeer"+e]||z(this.mainBkg,{h:180,s:-15,l:r*(8+e*3)});if(this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||z(this.primaryColor,{h:64}),this.fillType3=this.fillType3||z(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||z(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||z(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||z(this.primaryColor,{h:128}),this.fillType7=this.fillType7||z(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||z(this.primaryColor,{l:-10}),this.pie5=this.pie5||z(this.secondaryColor,{l:-10}),this.pie6=this.pie6||z(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||z(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||z(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||z(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||z(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||z(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||z(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#16141F",this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},pb=t((r)=>{let e=new db;return e.calculate(r),e},"getThemeVariables"),gb=class{static{t(this,"Theme")}constructor(){this.background="#ffffff",this.primaryColor="#cccccc",this.mainBkg="#ffffff",this.noteBkgColor="#fff5ad",this.noteTextColor="#28253D",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.primaryBorderColor=ce("#28253D",this.darkMode),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#28253D",this.stateBorder="#28253D",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.tertiaryColor="#ffffff",this.clusterBkg="#F9F9FB",this.clusterBorder="#BDBCCC",this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.actorBorder="#28253D",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=["#FDF4FF","#F0FDFA","#FFF7ED","#ECFEFF","#F0FDF4","#F5F3FF","#FEF2F2","#FEFCE8","#EEF2FF","#F7FEE7","#F0F9FF","#FFF1F2"],this.usecaseActorBorder="#A78BFA",this.usecaseActorBkg="#F5F3FF",this.usecaseBorder="#2DD4BF",this.usecaseBkg="#F0FDFA",this.usecaseBoundaryBorder="#BDBCCC",this.usecaseBoundaryBkg="#FAFAFC",this.usecaseIncludeLine="#38BDF8",this.usecaseExtendLine="#FB923C",this.filterColor="#000000"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#28253D"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#28253D",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||(ue(this.background)?f(this.background,4):h(this.background,4));let r="#ECECFE",e="#E9E9F1",o=z(r,{h:180,l:5});this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||r,this.activeTaskBorderColor=this.activeTaskBorderColor||r,this.activeTaskBkgColor=this.activeTaskBkgColor||f(r,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||"#FFFFFF",this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#F9F9FB",this.compositeTitleBackground=this.compositeTitleBackground||"#F9F9FB",this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad",this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||"white";for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleInv"+s]=this["cScaleInv"+s]||nt(this["cScale"+s]);for(let s=0;s<this.THEME_COLOR_LIMIT;s++)if(this.darkMode)this["cScalePeer"+s]=this["cScalePeer"+s]||f(this["cScale"+s],10);else this["cScalePeer"+s]=this["cScalePeer"+s]||h(this["cScale"+s],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["cScaleLabel"+s]=this["cScaleLabel"+s]||this.scaleLabelColor;let a=this.darkMode?-4:-1;for(let s=0;s<5;s++)this["surface"+s]=this["surface"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(5+s*3)}),this["surfacePeer"+s]=this["surfacePeer"+s]||z(this.mainBkg,{h:180,s:-15,l:a*(8+s*3)});this.classText=this.classText||this.textColor;for(let s=0;s<8;s++)this["fillType"+s]=this["fillType"+s]||this.bkgColorArray[s];for(let s=0;s<this.THEME_COLOR_LIMIT;s++)this["pie"+(s+1)]=this["pie"+(s+1)]||this["cScale"+s];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let s=0;s<8;s++)this["venn"+(s+1)]=this["venn"+(s+1)]??this.borderColorArray[s%this.borderColorArray.length];if(this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||r,this.quadrant2Fill=this.quadrant2Fill||z(r,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(r,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(r,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||r,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#FFFFFF",this.git0=this.git0||r,this.git1=this.git1||e,this.git2=this.git2||o,this.git3=this.git3||z(r,{h:-30}),this.git4=this.git4||z(r,{h:-60}),this.git5=this.git5||z(r,{h:-90}),this.git6=this.git6||z(r,{h:60}),this.git7=this.git7||z(r,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLineColor=this.commitLineColor??"#BDBCCC",this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.fontWeight=600,this.erEdgeLabelBackground="#FFFFFF",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},mb=t((r)=>{let e=new gb;return e.calculate(r),e},"getThemeVariables"),yb=class{static{t(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=f(this.primaryColor,16),this.tertiaryColor=z(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.background),this.secondaryBorderColor=ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ce(this.tertiaryColor,this.darkMode),this.primaryTextColor=nt(this.primaryColor),this.secondaryTextColor=nt(this.secondaryColor),this.tertiaryTextColor=nt(this.tertiaryColor),this.mainBkg="#111113",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=f(nt("#323D47"),10),this.border1="#ccc",this.border2=Ie(255,255,255,0.25),this.arrowheadColor=nt(this.background),this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.labelBackground="#111113",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.radius=12,this.strokeWidth=2,this.noteBkgColor=this.noteBkgColor??"#FEF9C3",this.noteTextColor=this.noteTextColor??"#28253D",this.THEME_COLOR_LIMIT=12,this.fontFamily='"Recursive Variable", arial, sans-serif',this.fontSize="14px",this.nodeBorder="#FFFFFF",this.stateBorder="#FFFFFF",this.useGradient=!1,this.gradientStart="#0042eb",this.gradientStop="#eb0042",this.dropShadow="url(#drop-shadow)",this.nodeShadow=!0,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.clusterBkg="#1E1A2E",this.clusterBorder="#BDBCCC",this.noteBorderColor="#FACC15",this.noteFontWeight=600,this.borderColorArray=["#E879F9","#2DD4BF","#FB923C","#22D3EE","#4ADE80","#A78BFA","#F87171","#FACC15","#818CF8","#A3E635 ","#38BDF8","#FB7185"],this.bkgColorArray=[],this.usecaseActorBorder="#A78BFA",this.usecaseBorder="#2DD4BF",this.usecaseBoundaryBorder="#BDBCCC",this.usecaseIncludeLine="#38BDF8",this.usecaseExtendLine="#FB923C",this.filterColor="#FFFFFF"}updateColors(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#FFFFFF"),this.secondaryColor=this.secondaryColor||z(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||z(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ce(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ce(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ce(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ce(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#FFFFFF",this.secondaryTextColor=this.secondaryTextColor||nt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||nt(this.tertiaryColor),this.lineColor=this.lineColor||nt(this.background),this.arrowheadColor=this.arrowheadColor||nt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.secondBkg=this.secondBkg==="calculated"?f(this.mainBkg,16):this.secondBkg,this.nodeBorder=this.nodeBorder||this.border1,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.flowContainerStroke=this.flowContainerStroke||this.secondaryBorderColor,this.actorBorder="#FFFFFF",this.signalColor="#FFFFFF",this.labelBoxBorderColor="#BDBCCC",this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||h(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||nt(this.lineColor),this.rectBkgColor=this.rectBkgColor||this.tertiaryColor,this.rootLabelColor="#FFFFFF",this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||f(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||this.secondBkg,this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.vertLineColor=this.vertLineColor||this.primaryBorderColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateEdgeLabelBackground=this.stateEdgeLabelBackground||"#16141F",this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||"#16141F",this.altBackground=this.altBackground||"#16141F",this.compositeTitleBackground=this.compositeTitleBackground||"#16141F",this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||"#f4a8ff",this.cScale1=this.cScale1||"#46ecd5",this.cScale2=this.cScale2||"#ffb86a",this.cScale3=this.cScale3||"#dab2ff",this.cScale4=this.cScale4||"#7bf1a8",this.cScale5=this.cScale5||"#c4b4ff",this.cScale6=this.cScale6||"#ffa2a2",this.cScale7=this.cScale7||"#ffdf20",this.cScale8=this.cScale8||"#a3b3ff",this.cScale9=this.cScale9||"#bbf451",this.cScale10=this.cScale10||"#74d4ff",this.cScale11=this.cScale11||"#ffa1ad",this.sectionBkgColor=this.sectionBkgColor||this.cScale0,this.sectionBkgColor2=this.sectionBkgColor2||this.cScale1,this.altSectionBkgColor=this.altSectionBkgColor||this.background;for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["cScaleInv"+o]=this["cScaleInv"+o]||nt(this["cScale"+o]);for(let o=0;o<this.THEME_COLOR_LIMIT;o++)if(this.darkMode)this["cScalePeer"+o]=this["cScalePeer"+o]||f(this["cScale"+o],10);else this["cScalePeer"+o]=this["cScalePeer"+o]||h(this["cScale"+o],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["cScaleLabel"+o]=h(this["cScale"+o],75);let r=this.darkMode?-4:-1;for(let o=0;o<5;o++)this["surface"+o]=this["surface"+o]||z(this.mainBkg,{h:180,s:-15,l:r*(5+o*3)}),this["surfacePeer"+o]=this["surfacePeer"+o]||z(this.mainBkg,{h:180,s:-15,l:r*(8+o*3)});this.classText=this.classText||this.textColor,["#701a75","#134e4a","#7c2d12","#581c87","#14532d","#4c1d95","#7f1d1d","#713f12"].forEach((o,a)=>{this["fillType"+a]=this["fillType"+a]||o});for(let o=0;o<this.THEME_COLOR_LIMIT;o++)this["pie"+(o+1)]=this["pie"+(o+1)]||this["cScale"+o];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||"#28253D",this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7";for(let o=0;o<8;o++)this["venn"+(o+1)]=this["venn"+(o+1)]??this.borderColorArray[o%this.borderColorArray.length];if(this.vennTitleTextColor=this.vennTitleTextColor??this.titleColor,this.vennSetTextColor=this.vennSetTextColor??this.textColor,this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||z(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||z(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||z(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||z(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||z(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||z(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||ue(this.quadrant1Fill)?f(this.quadrant1Fill):h(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,legendTextColor:this.xyChart?.legendTextColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?h(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.requirementEdgeLabelBackground="#16141F",this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||z(this.primaryColor,{h:-30}),this.git4=this.git4||z(this.primaryColor,{h:-60}),this.git5=this.git5||z(this.primaryColor,{h:-90}),this.git6=this.git6||z(this.primaryColor,{h:60}),this.git7=this.git7||z(this.primaryColor,{h:120}),this.darkMode)this.git0=f(this.git0,25),this.git1=f(this.git1,25),this.git2=f(this.git2,25),this.git3=f(this.git3,25),this.git4=f(this.git4,25),this.git5=f(this.git5,25),this.git6=f(this.git6,25),this.git7=f(this.git7,25);else this.git0=h(this.git0,25),this.git1=h(this.git1,25),this.git2=h(this.git2,25),this.git3=h(this.git3,25),this.git4=h(this.git4,25),this.git5=h(this.git5,25),this.git6=h(this.git6,25),this.git7=h(this.git7,25);this.gitInv0=this.gitInv0||nt(this.git0),this.gitInv1=this.gitInv1||nt(this.git1),this.gitInv2=this.gitInv2||nt(this.git2),this.gitInv3=this.gitInv3||nt(this.git3),this.gitInv4=this.gitInv4||nt(this.git4),this.gitInv5=this.gitInv5||nt(this.git5),this.gitInv6=this.gitInv6||nt(this.git6),this.gitInv7=this.gitInv7||nt(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.commitLineColor=this.commitLineColor??"#BDBCCC",this.fontWeight=600,this.erEdgeLabelBackground="#16141F",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Qr,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Jr}calculate(r){if(typeof r!=="object"){this.updateColors();return}let e=Object.keys(r);e.forEach((o)=>{this[o]=r[o]}),this.updateColors(),e.forEach((o)=>{this[o]=Rr(this[o],r[o])})}},xb=t((r)=>{let e=new yb;return e.calculate(r),e},"getThemeVariables"),tr={base:{getThemeVariables:JC},dark:{getThemeVariables:eb},default:{getThemeVariables:Ye},forest:{getThemeVariables:ob},neutral:{getThemeVariables:ab},neo:{getThemeVariables:lb},"neo-dark":{getThemeVariables:cb},redux:{getThemeVariables:fb},"redux-dark":{getThemeVariables:pb},"redux-color":{getThemeVariables:mb},"redux-dark-color":{getThemeVariables:xb}},Re={flowchart:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:null,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,wrappingWidth:120,minNodeWidth:120,inheritDir:!1},swimlane:{useMaxWidth:!0,theme:"redux-color",look:"neo",layout:"swimlane",lineHops:"arc",ignoreCrossLaneEdges:!0,optimizeRanksByCrossings:!0,automaticLaneOrdering:!1},agentflow:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,diagramPadding:8,nodeSpacing:50,rankSpacing:50,wrappingWidth:120,minNodeWidth:120},sequence:{useMaxWidth:!0,theme:"redux-color",look:"neo",hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,htmlLabels:!1,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},state:{useMaxWidth:!0,theme:"redux-color",look:"neo",layout:"elk",wrappingWidth:120,minNodeWidth:120,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5},er:{useMaxWidth:!0,theme:"redux-color",look:"neo",titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:0.75,donutHole:0,legendPosition:"right",highlightSlice:""},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showDataLabelOutsideBar:!1,showTitle:!0,showLegend:!0,legendFontSize:14,legendPadding:10,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2,labelRotation:0},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,theme:"redux-color",look:"neo",rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,colorBy:"branch",padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},ishikawa:{useMaxWidth:!0,diagramPadding:20},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:"",nodeWidth:10,nodePadding:12,labelStyle:"legacy"},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,bitOrder:"ascending",paddingX:5,paddingY:5},treeView:{useMaxWidth:!0,rowIndent:10,paddingX:5,paddingY:5,lineThickness:1,showIcons:!1,defaultIconPack:"",filenameIcons:{},extensionIcons:{}},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16,randomize:!1,nodeSeparation:75,idealEdgeLengthMultiplier:1.5,edgeElasticity:0.45,numIter:2500,seed:1},eventmodeling:{useMaxWidth:!0,padding:30,rowHeight:32},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:0.17},usecase:{useMaxWidth:!0,theme:"redux-color",look:"neo",wrappingWidth:120,minNodeWidth:120,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:"normal",usecaseFontSize:12,usecaseFontFamily:'"Open Sans", sans-serif',usecaseFontWeight:"normal",nodeSpacing:50,rankSpacing:50,diagramPadding:20,colorScheme:"role"},venn:{useMaxWidth:!0,theme:"redux-color",look:"neo",width:800,height:450,padding:8,useDebugLayout:!1},cynefin:{useMaxWidth:!0,width:800,height:600,padding:40,showDomainDescriptions:!0,boundaryAmplitude:8,seed:0},theme:"default",look:"classic",handDrawnSeed:0,layout:"elk",maxTextSize:50000,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},fp={...Re,deterministicIDSeed:void 0,elk:{mergeEdges:!1,straightenEdges:!0,lineHops:!0,preset:"default",nodePlacementStrategy:void 0,layeringStrategy:void 0,cycleBreakingStrategy:void 0,layeringLayerBound:4,nodePlacementAlignment:void 0,forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES",keepEntryNodeOnTop:!1,orientFeedbackEdges:!0},themeCSS:void 0,themeVariables:tr.default.getThemeVariables(),sequence:{...Re.sequence,messageFont:t(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:t(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:t(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{theme:Re.class?.theme,look:Re.class?.look,layout:Re.class?.layout,hideEmptyMembersBox:!1,hierarchicalNamespaces:!0},gantt:{...Re.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Re.c4,useWidth:void 0,personFont:t(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...Re.flowchart,inheritDir:!1},external_personFont:t(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:t(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:t(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:t(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:t(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:t(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:t(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:t(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:t(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:t(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:t(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:t(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:t(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:t(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:t(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:t(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:t(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:t(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:t(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:t(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:t(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...Re.pie,useWidth:984},xyChart:{...Re.xyChart,useWidth:void 0},requirement:{...Re.requirement,useWidth:void 0},packet:{...Re.packet},eventmodeling:{...Re.eventmodeling},treeView:{...Re.treeView,useWidth:void 0},radar:{...Re.radar},usecase:{...Re.usecase},railroad:{...Re.railroad,fontSize:void 0,fontFamily:void 0,terminalFill:void 0,terminalStroke:void 0,terminalTextColor:void 0,nonTerminalFill:void 0,nonTerminalStroke:void 0,nonTerminalTextColor:void 0,lineColor:void 0,markerFill:void 0,commentFill:void 0,commentStroke:void 0,commentTextColor:void 0,specialFill:void 0,specialStroke:void 0,ruleNameColor:void 0},ishikawa:{...Re.ishikawa},sankey:{...Re.sankey,nodeColors:void 0},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","},venn:{...Re.venn},cynefin:{...Re.cynefin}},dp=t((r,e="")=>Object.keys(r).reduce((o,a)=>{if(Array.isArray(r[a]))return o;else if(typeof r[a]==="object"&&r[a]!==null)return[...o,e+a,...dp(r[a],"")];return[...o,e+a]},[]),"keyify"),Cb=new Set(dp(fp,"")),F=fp,bb={"flowchart-v2":"flowchart","flowchart-elk":"flowchart",classDiagram:"class",stateDiagram:"state",xychart:"xyChart",railroadAbnf:"railroad",railroadEbnf:"railroad",railroadPeg:"railroad"},kb=t((r)=>bb[r]??r,"getDiagramConfigKey"),wb={nodeColors:/^#[\da-f]{3,8}$|^rgb\([\d\s%,.]+\)$|^hsl\([\d\s%,.]+\)$|^[a-z]+$/i,filenameIcons:/^[\w-]+(?::[\w-]+)?$/,extensionIcons:/^[\w-]+(?::[\w-]+)?$/},Sb=t((r,e)=>{for(let o of Object.keys(r)){let a=r[o];if(o.startsWith("__")||o.includes("proto")||o.includes("constr")||typeof a!=="string"||!e.test(a))i.debug("sanitize deleting dictionary entry:",o,a),delete r[o]}},"sanitizeDictionaryConfig"),Ds=t((r)=>{if(i.debug("sanitizeDirective called with",r),typeof r!=="object"||r==null)return;if(Array.isArray(r)){r.forEach((e)=>Ds(e));return}for(let e of Object.keys(r)){if(i.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!Cb.has(e)||r[e]==null){i.debug("sanitize deleting key: ",e),delete r[e];continue}if(typeof r[e]==="object"){let a=wb[e];if(a)Sb(r[e],a);else i.debug("sanitizing object",e),Ds(r[e]);continue}let o=["themeCSS","fontFamily","altFontFamily"];for(let a of o)if(e.includes(a))i.debug("sanitizing css option",e),r[e]=Us(r[e])}if(r.themeVariables)for(let e of Object.keys(r.themeVariables)){let o=r.themeVariables[e];if(o?.match&&!o.match(/^[\d "#%(),.;A-Za-z]+$/))r.themeVariables[e]=""}i.debug("After sanitization",r)},"sanitizeDirective"),Us=t((r)=>{let e=0,o=0;for(let a of r){if(e<o)return"{ /* ERROR: Unbalanced CSS */ }";if(a==="{")e++;else if(a==="}")o++}if(e!==o)return"{ /* ERROR: Unbalanced CSS */ }";return r},"sanitizeCss"),mr=Object.freeze(F),Tb=["theme","look","layout"],_b=new Set(["classic","handDrawn","neo"]),Bb=t((r,e)=>{if(r==="theme")return e==="null"||Object.hasOwn(tr,e);return r!=="look"||_b.has(e)},"isUsableAppearance"),vb=t((r,e,o)=>{if(!r)return;return[r[e]?.[o],r[o]].find((s)=>s!==void 0&&Bb(o,s))},"readAppearance"),ln=t((r)=>r===!1||["false","null","0"].includes(String(r).trim().toLowerCase())?!1:!0,"evaluate"),pr=Ae({},mr),In,Dn={},ki=[],Is=Ae({},mr),$s,Lb=t((r,e)=>{if(!$s)return;let o=[e,...[...ki].reverse(),Dn,mr],a=r[$s];for(let s of Tb)for(let n of o){let c=vb(n,$s,s);if(c===void 0)continue;if(r[s]=c,a?.[s]!==void 0)a[s]=c;break}},"resolveAppearance"),ts=t((r,e)=>{let o=Ae({},r),a={};for(let n of e)pp(n),a=Ae(a,n);if(o=Ae(o,a),Lb(o,a),(Boolean(a.theme)||o.theme!==r.theme)&&o.theme&&Object.hasOwn(tr,o.theme)){let n=Ae({},In),c=Ae(n.themeVariables||{},a.themeVariables);o.themeVariables=tr[o.theme].getThemeVariables(c)}return Is=o,Ab(Is),Is},"updateCurrentConfig"),_o=t((r)=>{$s=r===void 0?void 0:kb(r),ts(pr,ki)},"setDiagramConfigScope"),vc=t((r)=>{if(pr=Ae({},mr),pr=Ae(pr,r),Dn=Ae({},r),r.theme&&Object.hasOwn(tr,r.theme))pr.themeVariables=tr[r.theme].getThemeVariables(r.themeVariables);return ts(pr,ki),pr},"setSiteConfig"),yc=t((r)=>{In=Ae({},r)},"saveConfigFromInitialize"),bc=t((r)=>(pr=Ae(pr,r),Dn=Ae(Dn,r),ts(pr,ki),pr),"updateSiteConfig"),js=t(()=>Ae({},pr),"getSiteConfig"),qs=t((r)=>(ts(Is,[r]),A()),"setConfig"),A=t(()=>Ae({},Is),"getConfig"),pp=t((r)=>{if(!r)return;["secure",...pr.secure??[]].forEach((e)=>{if(Object.hasOwn(r,e))i.debug(`Denied attempt to modify a secure key ${e}`,r[e]),delete r[e]}),Object.keys(r).forEach((e)=>{if(e.startsWith("__"))delete r[e]}),Object.keys(r).forEach((e)=>{if(typeof r[e]==="string"&&(r[e].includes("<")||r[e].includes(">")||r[e].includes("url(data:")))delete r[e];if(typeof r[e]==="object")pp(r[e])})},"sanitize"),xc=t((r)=>{if(Ds(r),r.fontFamily&&!r.themeVariables?.fontFamily)r.themeVariables={...r.themeVariables,fontFamily:r.fontFamily};ki.push(r),ts(pr,ki)},"addDirective"),Ei=t((r=pr)=>{ki=[],$s=void 0,ts(r,ki)},"reset"),Fb={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead.",FLOWCHART_HTML_LABELS_DEPRECATED:"flowchart.htmlLabels is deprecated. Please use global htmlLabels instead."},np={},gp=t((r)=>{if(np[r])return;i.warn(Fb[r]),np[r]=!0},"issueWarning"),Ab=t((r)=>{if(!r)return;if(r.lazyLoadedDiagrams||r.loadExternalDiagramsAtStartup)gp("LAZY_LOAD_DEPRECATED")},"checkConfig"),_c=t(()=>{let r={};if(In)r=Ae(r,In);for(let e of ki)r=Ae(r,e);return r},"getUserDefinedConfig"),Xe=t((r)=>{if(r.flowchart?.htmlLabels!=null)gp("FLOWCHART_HTML_LABELS_DEPRECATED");return ln(r.htmlLabels??r.flowchart?.htmlLabels??!0)},"getEffectiveHtmlLabels"),na=/<\/?br\s*\/?>/gi,Mb=new RegExp(na.source,"i"),Eb=t((r)=>{if(!r)return[""];return xp(r).replace(/\\n/g,"#br#").split("#br#")},"getRows"),Ob=(()=>{let r=!1;return()=>{if(!r)mp(),r=!0}})();function mp(){st.addHook("beforeSanitizeAttributes",(e)=>{if(e.tagName==="A"&&e.hasAttribute("target"))e.setAttribute("data-temp-href-target",e.getAttribute("target")??"")}),st.addHook("afterSanitizeAttributes",(e)=>{if(e.tagName==="A"&&e.hasAttribute("data-temp-href-target")){if(e.setAttribute("target",e.getAttribute("data-temp-href-target")??""),e.removeAttribute("data-temp-href-target"),e.getAttribute("target")==="_blank")e.setAttribute("rel","noopener")}})}t(mp,"setupDompurifyHooks");var yp=t((r)=>(Ob(),st.sanitize(r)),"removeScript"),lp=t((r,e)=>{if(Xe(e)){let o=e.securityLevel;if(o==="antiscript"||o==="strict"||o==="sandbox")r=yp(r);else if(o!=="loose")r=xp(r),r=r.replace(/</g,"<").replace(/>/g,">"),r=r.replace(/=/g,"="),r=Pb(r)}return r},"sanitizeMore"),q=t((r,e)=>{if(!r)return r;if(e.dompurifyConfig)r=st.sanitize(lp(r,e),e.dompurifyConfig).toString();else r=st.sanitize(lp(r,e),{FORBID_TAGS:["style"]}).toString();return r},"sanitizeText"),Ib=t((r,e)=>{if(typeof r==="string")return q(r,e);return r.flat().map((o)=>q(o,e))},"sanitizeTextOrArray"),$b=t((r)=>Mb.test(r),"hasBreaks"),Db=t((r)=>r.split(na),"splitBreaks"),Pb=t((r)=>r.replace(/#br#/g,"<br/>"),"placeholderToBreak"),xp=t((r)=>r.replace(na,"#br#"),"breakToPlaceholder"),Vs=t((r)=>{let e="";if(r)e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=CSS.escape(e);return e},"getUrl"),Rb=t(function(...r){let e=r.filter((o)=>!isNaN(o));return Math.max(...e)},"getMax"),qb=t(function(...r){let e=r.filter((o)=>!isNaN(o));return Math.min(...e)},"getMin"),nr=t(function(r){let e=r.split(/(,)/),o=[];for(let a=0;a<e.length;a++){let s=e[a];if(s===","&&a>0&&a+1<e.length){let n=e[a-1],c=e[a+1];if(Nb(n,c))s=n+","+c,a++,o.pop()}o.push(Wb(s))}return o.join("")},"parseGenericTypes"),yh=t((r,e)=>Math.max(0,r.split(e).length-1),"countOccurrence"),Nb=t((r,e)=>{let o=yh(r,"~"),a=yh(e,"~");return o===1&&a===1},"shouldCombineSets"),Wb=t((r)=>{let e=yh(r,"~"),o=!1;if(e<=1)return r;if(e%2!==0&&r.startsWith("~"))r=r.substring(1),o=!0;let a=[...r],s=a.indexOf("~"),n=a.lastIndexOf("~");while(s!==-1&&n!==-1&&s!==n)a[s]="<",a[n]=">",s=a.indexOf("~"),n=a.lastIndexOf("~");if(o)a.unshift("~");return a.join("")},"processSet"),hp=t(()=>window.MathMLElement!==void 0,"isMathMLSupported"),Mn=/\$\$(.*?)\$\$/g,$e=t((r)=>(r.match(Mn)?.length??0)>0,"hasKatex"),Va=t(async(r,e)=>{let o=document.createElement("div");o.innerHTML=await Ga(r,e),o.id="katex-temp",o.style.visibility="hidden",o.style.position="absolute",o.style.top="0",document.querySelector("body")?.insertAdjacentElement("beforeend",o);let s={width:o.clientWidth,height:o.clientHeight};return o.remove(),s},"calculateMathMLDimensions"),zb=t(async(r,e)=>{if(!$e(r))return r;if(!(hp()||e.legacyMathML||e.forceLegacyMathML))return r.replace(Mn,"MathML is unsupported in this environment.");{let{default:o}=await (S("nj0cv1cq"),import("./chunk-nj0cv1cq.js")),a=e.forceLegacyMathML||!hp()&&e.legacyMathML?"htmlAndMathml":"mathml";return r.split(na).map((s)=>$e(s)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${s}</div>`:`<div>${s}</div>`).join("").replace(Mn,(s,n)=>o.renderToString(n,{throwOnError:!0,displayMode:!0,output:a}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}return r.replace(Mn,"Katex is not supported in @mermaid-js/tiny. Please use the full mermaid library.")},"renderKatexUnsanitized"),Ga=t(async(r,e)=>q(await zb(r,e),e),"renderKatexSanitized"),C={getRows:Eb,sanitizeText:q,sanitizeTextOrArray:Ib,hasBreaks:$b,splitBreaks:Db,lineBreakRegex:na,removeScript:yp,getUrl:Vs,evaluate:ln,getMax:Rb,getMin:qb},Hb=t(function(r,e){for(let o of e)r.attr(o[0],o[1])},"d3Attrs"),Yb=t(function(r,e,o){let a=new Map;if(o)a.set("width","100%"),a.set("style",`max-width: ${e}px;`);else a.set("height",r),a.set("width",e);return a},"calculateSvgSizeAttrs"),Y=t(function(r,e,o,a){let s=Yb(e,o,a);Hb(r,s)},"configureSvgSize"),pn=t(function(r,e,o,a){let s=e.node().getBBox(),{width:n,height:c}=s;i.info(`SVG bounds: ${n}x${c}`,s);let l=0,p=0;i.info(`Graph bounds: ${l}x${p}`,r),l=n+o*2,p=c+o*2,i.info(`Calculated bounds: ${l}x${p}`),Y(e,p,l,a);let m=`${s.x-o} ${s.y-o} ${s.width+2*o} ${s.height+2*o}`;e.attr("viewBox",m)},"setupGraphViewbox"),En={};function wo(r){return[...r.cssRules].map((e)=>e.cssText).join(`
|
|
7
7
|
`)}t(wo,"cssStyleSheetToString");var Ub=t((r,e,o,a)=>{let s="";if(r in En&&En[r])s=En[r]({...o,svgId:a});else i.warn(`No theme found for ${r}`);return`& {
|
|
8
8
|
font-family: ${o.fontFamily};
|
|
9
9
|
font-size: ${o.fontSize};
|
|
@@ -125,40 +125,40 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
125
125
|
}
|
|
126
126
|
|
|
127
127
|
${e}
|
|
128
|
-
`},"getStyles"),jb=t((r,e)=>{if(e!==void 0)En[r]=e},"addStylesForDiagram"),wc=Ub,ko={};er(ko,{clear:()=>L,getAccDescription:()=>I,getAccTitle:()=>R,getDiagramTitle:()=>D,setAccDescription:()=>P,setAccTitle:()=>N,setDiagramTitle:()=>O});var xh="",Ch="",bh="",kh=t((r)=>
|
|
129
|
-
`)},"setAccDescription"),I=t(()=>bh,"getAccDescription"),O=t((r)=>{Ch=kh(r)},"setDiagramTitle"),D=t(()=>Ch,"getDiagramTitle"),cp=i,Gb=Ti,d=A,fr=qs,Fr=mr,Rn=t((r)=>j(r,d()),"sanitizeText"),Wa=pn,Xb=t(()=>ko,"getCommonDb"),Pn={},Li=t((r,e,o)=>{if(Pn[r])cp.warn(`Diagram with id ${r} already registered. Overwriting.`);if(Pn[r]=e,o)up(r,o);jb(r,e.styles),e.injectUtils?.(cp,Gb,d,Rn,Wa,Xb(),()=>{})},"registerDiagram"),Co=t((r)=>{if(r in Pn)return Pn[r];throw new Vb(r)},"getDiagram"),Vb=class extends Error{static{t(this,"DiagramNotFoundError")}constructor(r){super(`Diagram ${r} not found.`)}};var Kb={value:()=>{}};function bp(){for(var r=0,e=arguments.length,o={},a;r<e;++r){if(!(a=arguments[r]+"")||a in o||/[\s.]/.test(a))throw Error("illegal type: "+a);o[a]=[]}return new qn(o)}function qn(r){this._=r}function Zb(r,e){return r.trim().split(/^|\s+/).map(function(o){var a="",s=o.indexOf(".");if(s>=0)a=o.slice(s+1),o=o.slice(0,s);if(o&&!e.hasOwnProperty(o))throw Error("unknown type: "+o);return{type:o,name:a}})}qn.prototype=bp.prototype={constructor:qn,on:function(r,e){var o=this._,a=Zb(r+"",o),s,n=-1,c=a.length;if(arguments.length<2){while(++n<c)if((s=(r=a[n]).type)&&(s=Qb(o[s],r.name)))return s;return}if(e!=null&&typeof e!=="function")throw Error("invalid callback: "+e);while(++n<c)if(s=(r=a[n]).type)o[s]=Cp(o[s],r.name,e);else if(e==null)for(s in o)o[s]=Cp(o[s],r.name,null);return this},copy:function(){var r={},e=this._;for(var o in e)r[o]=e[o].slice();return new qn(r)},call:function(r,e){if((s=arguments.length-2)>0)for(var o=Array(s),a=0,s,n;a<s;++a)o[a]=arguments[a+2];if(!this._.hasOwnProperty(r))throw Error("unknown type: "+r);for(n=this._[r],a=0,s=n.length;a<s;++a)n[a].value.apply(e,o)},apply:function(r,e,o){if(!this._.hasOwnProperty(r))throw Error("unknown type: "+r);for(var a=this._[r],s=0,n=a.length;s<n;++s)a[s].value.apply(e,o)}};function Qb(r,e){for(var o=0,a=r.length,s;o<a;++o)if((s=r[o]).name===e)return s.value}function Cp(r,e,o){for(var a=0,s=r.length;a<s;++a)if(r[a].name===e){r[a]=Kb,r=r.slice(0,a).concat(r.slice(a+1));break}if(o!=null)r.push({name:e,value:o});return r}var wh=bp;var Nn="http://www.w3.org/1999/xhtml",Sh={svg:"http://www.w3.org/2000/svg",xhtml:Nn,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function ii(r){var e=r+="",o=e.indexOf(":");if(o>=0&&(e=r.slice(0,o))!=="xmlns")r=r.slice(o+1);return Sh.hasOwnProperty(e)?{space:Sh[e],local:r}:r}function Jb(r){return function(){var e=this.ownerDocument,o=this.namespaceURI;return o===Nn&&e.documentElement.namespaceURI===Nn?e.createElement(r):e.createElementNS(o,r)}}function tk(r){return function(){return this.ownerDocument.createElementNS(r.space,r.local)}}function Ps(r){var e=ii(r);return(e.local?tk:Jb)(e)}function ek(){}function Xi(r){return r==null?ek:function(){return this.querySelector(r)}}function Th(r){if(typeof r!=="function")r=Xi(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=Array(c),p,m,u=0;u<c;++u)if((p=n[u])&&(m=r.call(p,p.__data__,u,n))){if("__data__"in p)m.__data__=p.__data__;l[u]=m}return new Oe(a,this._parents)}function _h(r){return r==null?[]:Array.isArray(r)?r:Array.from(r)}function rk(){return[]}function es(r){return r==null?rk:function(){return this.querySelectorAll(r)}}function ik(r){return function(){return _h(r.apply(this,arguments))}}function Bh(r){if(typeof r==="function")r=ik(r);else r=es(r);for(var e=this._groups,o=e.length,a=[],s=[],n=0;n<o;++n)for(var c=e[n],l=c.length,p,m=0;m<l;++m)if(p=c[m])a.push(r.call(p,p.__data__,m,c)),s.push(p);return new Oe(a,s)}function rs(r){return function(){return this.matches(r)}}function Wn(r){return function(e){return e.matches(r)}}var ok=Array.prototype.find;function sk(r){return function(){return ok.call(this.children,r)}}function ak(){return this.firstElementChild}function vh(r){return this.select(r==null?ak:sk(typeof r==="function"?r:Wn(r)))}var nk=Array.prototype.filter;function lk(){return Array.from(this.children)}function hk(r){return function(){return nk.call(this.children,r)}}function Lh(r){return this.selectAll(r==null?lk:hk(typeof r==="function"?r:Wn(r)))}function Fh(r){if(typeof r!=="function")r=rs(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=[],p,m=0;m<c;++m)if((p=n[m])&&r.call(p,p.__data__,m,n))l.push(p);return new Oe(a,this._parents)}function Rs(r){return Array(r.length)}function Ah(){return new Oe(this._enter||this._groups.map(Rs),this._parents)}function Ns(r,e){this.ownerDocument=r.ownerDocument,this.namespaceURI=r.namespaceURI,this._next=null,this._parent=r,this.__data__=e}Ns.prototype={constructor:Ns,appendChild:function(r){return this._parent.insertBefore(r,this._next)},insertBefore:function(r,e){return this._parent.insertBefore(r,e)},querySelector:function(r){return this._parent.querySelector(r)},querySelectorAll:function(r){return this._parent.querySelectorAll(r)}};function Mh(r){return function(){return r}}function ck(r,e,o,a,s,n){var c=0,l,p=e.length,m=n.length;for(;c<m;++c)if(l=e[c])l.__data__=n[c],a[c]=l;else o[c]=new Ns(r,n[c]);for(;c<p;++c)if(l=e[c])s[c]=l}function uk(r,e,o,a,s,n,c){var l,p,m=new Map,u=e.length,y=n.length,x=Array(u),k;for(l=0;l<u;++l)if(p=e[l])if(x[l]=k=c.call(p,p.__data__,l,e)+"",m.has(k))s[l]=p;else m.set(k,p);for(l=0;l<y;++l)if(k=c.call(r,n[l],l,n)+"",p=m.get(k))a[l]=p,p.__data__=n[l],m.delete(k);else o[l]=new Ns(r,n[l]);for(l=0;l<u;++l)if((p=e[l])&&m.get(x[l])===p)s[l]=p}function fk(r){return r.__data__}function Eh(r,e){if(!arguments.length)return Array.from(this,fk);var o=e?uk:ck,a=this._parents,s=this._groups;if(typeof r!=="function")r=Mh(r);for(var n=s.length,c=Array(n),l=Array(n),p=Array(n),m=0;m<n;++m){var u=a[m],y=s[m],x=y.length,k=dk(r.call(u,u&&u.__data__,m,a)),w=k.length,_=l[m]=Array(w),M=c[m]=Array(w),q=p[m]=Array(x);o(u,y,_,M,q,k,e);for(var Y=0,V=0,Q,tt;Y<w;++Y)if(Q=_[Y]){if(Y>=V)V=Y+1;while(!(tt=M[V])&&++V<w);Q._next=tt||null}}return c=new Oe(c,a),c._enter=l,c._exit=p,c}function dk(r){return typeof r==="object"&&"length"in r?r:Array.from(r)}function Oh(){return new Oe(this._exit||this._groups.map(Rs),this._parents)}function Ih(r,e,o){var a=this.enter(),s=this,n=this.exit();if(typeof r==="function"){if(a=r(a),a)a=a.selection()}else a=a.append(r+"");if(e!=null){if(s=e(s),s)s=s.selection()}if(o==null)n.remove();else o(n);return a&&s?a.merge(s).order():s}function $h(r){var e=r.selection?r.selection():r;for(var o=this._groups,a=e._groups,s=o.length,n=a.length,c=Math.min(s,n),l=Array(s),p=0;p<c;++p)for(var m=o[p],u=a[p],y=m.length,x=l[p]=Array(y),k,w=0;w<y;++w)if(k=m[w]||u[w])x[w]=k;for(;p<s;++p)l[p]=o[p];return new Oe(l,this._parents)}function Dh(){for(var r=this._groups,e=-1,o=r.length;++e<o;)for(var a=r[e],s=a.length-1,n=a[s],c;--s>=0;)if(c=a[s]){if(n&&c.compareDocumentPosition(n)^4)n.parentNode.insertBefore(c,n);n=c}return this}function Ph(r){if(!r)r=pk;function e(y,x){return y&&x?r(y.__data__,x.__data__):!y-!x}for(var o=this._groups,a=o.length,s=Array(a),n=0;n<a;++n){for(var c=o[n],l=c.length,p=s[n]=Array(l),m,u=0;u<l;++u)if(m=c[u])p[u]=m;p.sort(e)}return new Oe(s,this._parents).order()}function pk(r,e){return r<e?-1:r>e?1:r>=e?0:NaN}function Rh(){var r=arguments[0];return arguments[0]=this,r.apply(null,arguments),this}function qh(){return Array.from(this)}function Nh(){for(var r=this._groups,e=0,o=r.length;e<o;++e)for(var a=r[e],s=0,n=a.length;s<n;++s){var c=a[s];if(c)return c}return null}function Wh(){let r=0;for(let e of this)++r;return r}function zh(){return!this.node()}function Hh(r){for(var e=this._groups,o=0,a=e.length;o<a;++o)for(var s=e[o],n=0,c=s.length,l;n<c;++n)if(l=s[n])r.call(l,l.__data__,n,s);return this}function gk(r){return function(){this.removeAttribute(r)}}function mk(r){return function(){this.removeAttributeNS(r.space,r.local)}}function yk(r,e){return function(){this.setAttribute(r,e)}}function xk(r,e){return function(){this.setAttributeNS(r.space,r.local,e)}}function Ck(r,e){return function(){var o=e.apply(this,arguments);if(o==null)this.removeAttribute(r);else this.setAttribute(r,o)}}function bk(r,e){return function(){var o=e.apply(this,arguments);if(o==null)this.removeAttributeNS(r.space,r.local);else this.setAttributeNS(r.space,r.local,o)}}function Yh(r,e){var o=ii(r);if(arguments.length<2){var a=this.node();return o.local?a.getAttributeNS(o.space,o.local):a.getAttribute(o)}return this.each((e==null?o.local?mk:gk:typeof e==="function"?o.local?bk:Ck:o.local?xk:yk)(o,e))}function ta(r){return r.ownerDocument&&r.ownerDocument.defaultView||r.document&&r||r.defaultView}function kk(r){return function(){this.style.removeProperty(r)}}function wk(r,e,o){return function(){this.style.setProperty(r,e,o)}}function Sk(r,e,o){return function(){var a=e.apply(this,arguments);if(a==null)this.style.removeProperty(r);else this.style.setProperty(r,a,o)}}function Uh(r,e,o){return arguments.length>1?this.each((e==null?kk:typeof e==="function"?Sk:wk)(r,e,o==null?"":o)):Vi(this.node(),r)}function Vi(r,e){return r.style.getPropertyValue(e)||ta(r).getComputedStyle(r,null).getPropertyValue(e)}function Tk(r){return function(){delete this[r]}}function _k(r,e){return function(){this[r]=e}}function Bk(r,e){return function(){var o=e.apply(this,arguments);if(o==null)delete this[r];else this[r]=o}}function jh(r,e){return arguments.length>1?this.each((e==null?Tk:typeof e==="function"?Bk:_k)(r,e)):this.node()[r]}function kp(r){return r.trim().split(/^|\s+/)}function Gh(r){return r.classList||new wp(r)}function wp(r){this._node=r,this._names=kp(r.getAttribute("class")||"")}wp.prototype={add:function(r){var e=this._names.indexOf(r);if(e<0)this._names.push(r),this._node.setAttribute("class",this._names.join(" "))},remove:function(r){var e=this._names.indexOf(r);if(e>=0)this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" "))},contains:function(r){return this._names.indexOf(r)>=0}};function Sp(r,e){var o=Gh(r),a=-1,s=e.length;while(++a<s)o.add(e[a])}function Tp(r,e){var o=Gh(r),a=-1,s=e.length;while(++a<s)o.remove(e[a])}function vk(r){return function(){Sp(this,r)}}function Lk(r){return function(){Tp(this,r)}}function Fk(r,e){return function(){(e.apply(this,arguments)?Sp:Tp)(this,r)}}function Xh(r,e){var o=kp(r+"");if(arguments.length<2){var a=Gh(this.node()),s=-1,n=o.length;while(++s<n)if(!a.contains(o[s]))return!1;return!0}return this.each((typeof e==="function"?Fk:e?vk:Lk)(o,e))}function Ak(){this.textContent=""}function Mk(r){return function(){this.textContent=r}}function Ek(r){return function(){var e=r.apply(this,arguments);this.textContent=e==null?"":e}}function Vh(r){return arguments.length?this.each(r==null?Ak:(typeof r==="function"?Ek:Mk)(r)):this.node().textContent}function Ok(){this.innerHTML=""}function Ik(r){return function(){this.innerHTML=r}}function $k(r){return function(){var e=r.apply(this,arguments);this.innerHTML=e==null?"":e}}function Kh(r){return arguments.length?this.each(r==null?Ok:(typeof r==="function"?$k:Ik)(r)):this.node().innerHTML}function Dk(){if(this.nextSibling)this.parentNode.appendChild(this)}function Zh(){return this.each(Dk)}function Pk(){if(this.previousSibling)this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Qh(){return this.each(Pk)}function Jh(r){var e=typeof r==="function"?r:Ps(r);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function Rk(){return null}function ic(r,e){var o=typeof r==="function"?r:Ps(r),a=e==null?Rk:typeof e==="function"?e:Xi(e);return this.select(function(){return this.insertBefore(o.apply(this,arguments),a.apply(this,arguments)||null)})}function qk(){var r=this.parentNode;if(r)r.removeChild(this)}function oc(){return this.each(qk)}function Nk(){var r=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(r,this.nextSibling):r}function Wk(){var r=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(r,this.nextSibling):r}function sc(r){return this.select(r?Wk:Nk)}function ac(r){return arguments.length?this.property("__data__",r):this.node().__data__}function zk(r){return function(e){r.call(this,e,this.__data__)}}function Hk(r){return r.trim().split(/^|\s+/).map(function(e){var o="",a=e.indexOf(".");if(a>=0)o=e.slice(a+1),e=e.slice(0,a);return{type:e,name:o}})}function Yk(r){return function(){var e=this.__on;if(!e)return;for(var o=0,a=-1,s=e.length,n;o<s;++o)if(n=e[o],(!r.type||n.type===r.type)&&n.name===r.name)this.removeEventListener(n.type,n.listener,n.options);else e[++a]=n;if(++a)e.length=a;else delete this.__on}}function Uk(r,e,o){return function(){var a=this.__on,s,n=zk(e);if(a){for(var c=0,l=a.length;c<l;++c)if((s=a[c]).type===r.type&&s.name===r.name){this.removeEventListener(s.type,s.listener,s.options),this.addEventListener(s.type,s.listener=n,s.options=o),s.value=e;return}}if(this.addEventListener(r.type,n,o),s={type:r.type,name:r.name,value:e,listener:n,options:o},!a)this.__on=[s];else a.push(s)}}function lc(r,e,o){var a=Hk(r+""),s,n=a.length,c;if(arguments.length<2){var l=this.node().__on;if(l){for(var p=0,m=l.length,u;p<m;++p)for(s=0,u=l[p];s<n;++s)if((c=a[s]).type===u.type&&c.name===u.name)return u.value}return}l=e?Uk:Yk;for(s=0;s<n;++s)this.each(l(a[s],e,o));return this}function _p(r,e,o){var a=ta(r),s=a.CustomEvent;if(typeof s==="function")s=new s(e,o);else if(s=a.document.createEvent("Event"),o)s.initEvent(e,o.bubbles,o.cancelable),s.detail=o.detail;else s.initEvent(e,!1,!1);r.dispatchEvent(s)}function jk(r,e){return function(){return _p(this,r,e)}}function Gk(r,e){return function(){return _p(this,r,e.apply(this,arguments))}}function hc(r,e){return this.each((typeof e==="function"?Gk:jk)(r,e))}function*cc(){for(var r=this._groups,e=0,o=r.length;e<o;++e)for(var a=r[e],s=0,n=a.length,c;s<n;++s)if(c=a[s])yield c}var uc=[null];function Oe(r,e){this._groups=r,this._parents=e}function Bp(){return new Oe([[document.documentElement]],uc)}function Xk(){return this}Oe.prototype=Bp.prototype={constructor:Oe,select:Th,selectAll:Bh,selectChild:vh,selectChildren:Lh,filter:Fh,data:Eh,enter:Ah,exit:Oh,join:Ih,merge:$h,selection:Xk,order:Dh,sort:Ph,call:Rh,nodes:qh,node:Nh,size:Wh,empty:zh,each:Hh,attr:Yh,style:Uh,property:jh,classed:Xh,text:Vh,html:Kh,raise:Zh,lower:Qh,append:Jh,insert:ic,remove:oc,clone:sc,datum:ac,on:lc,dispatch:hc,[Symbol.iterator]:cc};var wi=Bp;function g(r){return typeof r==="string"?new Oe([[document.querySelector(r)]],[document.documentElement]):new Oe([[r]],uc)}function zr(r,e,o){r.prototype=e.prototype=o,o.constructor=r}function Ya(r,e){var o=Object.create(r.prototype);for(var a in e)o[a]=e[a];return o}function Hr(){}var ea=0.7,Yn=1/ea,is="\\s*([+-]?\\d+)\\s*",ha="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",oi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Vk=/^#([0-9a-f]{3,8})$/,Kk=new RegExp(`^rgb\\(${is},${is},${is}\\)$`),Zk=new RegExp(`^rgb\\(${oi},${oi},${oi}\\)$`),Qk=new RegExp(`^rgba\\(${is},${is},${is},${ha}\\)$`),Jk=new RegExp(`^rgba\\(${oi},${oi},${oi},${ha}\\)$`),t1=new RegExp(`^hsl\\(${ha},${oi},${oi}\\)$`),e1=new RegExp(`^hsla\\(${ha},${oi},${oi},${ha}\\)$`),vp={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};zr(Hr,$n,{copy(r){return Object.assign(new this.constructor,this,r)},displayable(){return this.rgb().displayable()},hex:Lp,formatHex:Lp,formatHex8:r1,formatHsl:i1,formatRgb:Fp,toString:Fp});function Lp(){return this.rgb().formatHex()}function r1(){return this.rgb().formatHex8()}function i1(){return $p(this).formatHsl()}function Fp(){return this.rgb().formatRgb()}function $n(r){var e,o;return r=(r+"").trim().toLowerCase(),(e=Vk.exec(r))?(o=e[1].length,e=parseInt(e[1],16),o===6?Ap(e):o===3?new Et(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):o===8?zn(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):o===4?zn(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=Kk.exec(r))?new Et(e[1],e[2],e[3],1):(e=Zk.exec(r))?new Et(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=Qk.exec(r))?zn(e[1],e[2],e[3],e[4]):(e=Jk.exec(r))?zn(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=t1.exec(r))?Op(e[1],e[2]/100,e[3]/100,1):(e=e1.exec(r))?Op(e[1],e[2]/100,e[3]/100,e[4]):vp.hasOwnProperty(r)?Ap(vp[r]):r==="transparent"?new Et(NaN,NaN,NaN,0):null}function Ap(r){return new Et(r>>16&255,r>>8&255,r&255,1)}function zn(r,e,o,a){if(a<=0)r=e=o=NaN;return new Et(r,e,o,a)}function Gs(r){if(!(r instanceof Hr))r=$n(r);if(!r)return new Et;return r=r.rgb(),new Et(r.r,r.g,r.b,r.opacity)}function os(r,e,o,a){return arguments.length===1?Gs(r):new Et(r,e,o,a==null?1:a)}function Et(r,e,o,a){this.r=+r,this.g=+e,this.b=+o,this.opacity=+a}zr(Et,os,Ya(Hr,{brighter(r){return r=r==null?Yn:Math.pow(Yn,r),new Et(this.r*r,this.g*r,this.b*r,this.opacity)},darker(r){return r=r==null?ea:Math.pow(ea,r),new Et(this.r*r,this.g*r,this.b*r,this.opacity)},rgb(){return this},clamp(){return new Et(io(this.r),io(this.g),io(this.b),Un(this.opacity))},displayable(){return-0.5<=this.r&&this.r<255.5&&(-0.5<=this.g&&this.g<255.5)&&(-0.5<=this.b&&this.b<255.5)&&(0<=this.opacity&&this.opacity<=1)},hex:Mp,formatHex:Mp,formatHex8:o1,formatRgb:Ep,toString:Ep}));function Mp(){return`#${ro(this.r)}${ro(this.g)}${ro(this.b)}`}function o1(){return`#${ro(this.r)}${ro(this.g)}${ro(this.b)}${ro((isNaN(this.opacity)?1:this.opacity)*255)}`}function Ep(){let r=Un(this.opacity);return`${r===1?"rgb(":"rgba("}${io(this.r)}, ${io(this.g)}, ${io(this.b)}${r===1?")":`, ${r})`}`}function Un(r){return isNaN(r)?1:Math.max(0,Math.min(1,r))}function io(r){return Math.max(0,Math.min(255,Math.round(r)||0))}function ro(r){return r=io(r),(r<16?"0":"")+r.toString(16)}function Op(r,e,o,a){if(a<=0)r=e=o=NaN;else if(o<=0||o>=1)r=e=NaN;else if(e<=0)r=NaN;return new Nr(r,e,o,a)}function $p(r){if(r instanceof Nr)return new Nr(r.h,r.s,r.l,r.opacity);if(!(r instanceof Hr))r=$n(r);if(!r)return new Nr;if(r instanceof Nr)return r;r=r.rgb();var e=r.r/255,o=r.g/255,a=r.b/255,s=Math.min(e,o,a),n=Math.max(e,o,a),c=NaN,l=n-s,p=(n+s)/2;if(l){if(e===n)c=(o-a)/l+(o<a)*6;else if(o===n)c=(a-e)/l+2;else c=(e-o)/l+4;l/=p<0.5?n+s:2-n-s,c*=60}else l=p>0&&p<1?0:c;return new Nr(c,l,p,r.opacity)}function Dp(r,e,o,a){return arguments.length===1?$p(r):new Nr(r,e,o,a==null?1:a)}function Nr(r,e,o,a){this.h=+r,this.s=+e,this.l=+o,this.opacity=+a}zr(Nr,Dp,Ya(Hr,{brighter(r){return r=r==null?Yn:Math.pow(Yn,r),new Nr(this.h,this.s,this.l*r,this.opacity)},darker(r){return r=r==null?ea:Math.pow(ea,r),new Nr(this.h,this.s,this.l*r,this.opacity)},rgb(){var r=this.h%360+(this.h<0)*360,e=isNaN(r)||isNaN(this.s)?0:this.s,o=this.l,a=o+(o<0.5?o:1-o)*e,s=2*o-a;return new Et(fc(r>=240?r-240:r+120,s,a),fc(r,s,a),fc(r<120?r+240:r-120,s,a),this.opacity)},clamp(){return new Nr(Ip(this.h),Hn(this.s),Hn(this.l),Un(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&(0<=this.l&&this.l<=1)&&(0<=this.opacity&&this.opacity<=1)},formatHsl(){let r=Un(this.opacity);return`${r===1?"hsl(":"hsla("}${Ip(this.h)}, ${Hn(this.s)*100}%, ${Hn(this.l)*100}%${r===1?")":`, ${r})`}`}}));function Ip(r){return r=(r||0)%360,r<0?r+360:r}function Hn(r){return Math.max(0,Math.min(1,r||0))}function fc(r,e,o){return(r<60?e+(o-e)*r/60:r<180?o:r<240?e+(o-e)*(240-r)/60:e)*255}function dc(r,e,o,a,s){var n=r*r,c=n*r;return((1-3*r+3*n-c)*e+(4-6*n+3*c)*o+(1+3*r+3*n-3*c)*a+c*s)/6}function pc(r){var e=r.length-1;return function(o){var a=o<=0?o=0:o>=1?(o=1,e-1):Math.floor(o*e),s=r[a],n=r[a+1],c=a>0?r[a-1]:2*s-n,l=a<e-1?r[a+2]:2*n-s;return dc((o-a/e)*e,c,s,n,l)}}function mc(r){var e=r.length;return function(o){var a=Math.floor(((o%=1)<0?++o:o)*e),s=r[(a+e-1)%e],n=r[a%e],c=r[(a+1)%e],l=r[(a+2)%e];return dc((o-a/e)*e,s,n,c,l)}}var Xa=(r)=>()=>r;function Pp(r,e){return function(o){return r+o*e}}function s1(r,e,o){return r=Math.pow(r,o),e=Math.pow(e,o)-r,o=1/o,function(a){return Math.pow(r+a*e,o)}}function kc(r,e){var o=e-r;return o?Pp(r,o>180||o<-180?o-360*Math.round(o/360):o):Xa(isNaN(r)?e:r)}function Rp(r){return(r=+r)===1?hr:function(e,o){return o-e?s1(e,o,r):Xa(isNaN(e)?o:e)}}function hr(r,e){var o=e-r;return o?Pp(r,o):Xa(isNaN(r)?e:r)}var ra=function r(e){var o=Rp(e);function a(s,n){var c=o((s=os(s)).r,(n=os(n)).r),l=o(s.g,n.g),p=o(s.b,n.b),m=hr(s.opacity,n.opacity);return function(u){return s.r=c(u),s.g=l(u),s.b=p(u),s.opacity=m(u),s+""}}return a.gamma=r,a}(1);function qp(r){return function(e){var o=e.length,a=Array(o),s=Array(o),n=Array(o),c,l;for(c=0;c<o;++c)l=os(e[c]),a[c]=l.r||0,s[c]=l.g||0,n[c]=l.b||0;return a=r(a),s=r(s),n=r(n),l.opacity=1,function(p){return l.r=a(p),l.g=s(p),l.b=n(p),l+""}}}var a1=qp(pc),n1=qp(mc);function bt(r,e){return r=+r,e=+e,function(o){return r*(1-o)+e*o}}var Fc=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Bc=new RegExp(Fc.source,"g");function l1(r){return function(){return r}}function h1(r){return function(e){return r(e)+""}}function Ka(r,e){var o=Fc.lastIndex=Bc.lastIndex=0,a,s,n,c=-1,l=[],p=[];r=r+"",e=e+"";while((a=Fc.exec(r))&&(s=Bc.exec(e))){if((n=s.index)>o)if(n=e.slice(o,n),l[c])l[c]+=n;else l[++c]=n;if((a=a[0])===(s=s[0]))if(l[c])l[c]+=s;else l[++c]=s;else l[++c]=null,p.push({i:c,x:bt(a,s)});o=Bc.lastIndex}if(o<e.length)if(n=e.slice(o),l[c])l[c]+=n;else l[++c]=n;return l.length<2?p[0]?h1(p[0].x):l1(e):(e=p.length,function(m){for(var u=0,y;u<e;++u)l[(y=p[u]).i]=y.x(m);return l.join("")})}var Np=180/Math.PI,jn={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Gn(r,e,o,a,s,n){var c,l,p;if(c=Math.sqrt(r*r+e*e))r/=c,e/=c;if(p=r*o+e*a)o-=r*p,a-=e*p;if(l=Math.sqrt(o*o+a*a))o/=l,a/=l,p/=l;if(r*a<e*o)r=-r,e=-e,p=-p,c=-c;return{translateX:s,translateY:n,rotate:Math.atan2(e,r)*Np,skewX:Math.atan(p)*Np,scaleX:c,scaleY:l}}var Xn;function Wp(r){let e=new(typeof DOMMatrix==="function"?DOMMatrix:WebKitCSSMatrix)(r+"");return e.isIdentity?jn:Gn(e.a,e.b,e.c,e.d,e.e,e.f)}function zp(r){if(r==null)return jn;if(!Xn)Xn=document.createElementNS("http://www.w3.org/2000/svg","g");if(Xn.setAttribute("transform",r),!(r=Xn.transform.baseVal.consolidate()))return jn;return r=r.matrix,Gn(r.a,r.b,r.c,r.d,r.e,r.f)}function Hp(r,e,o,a){function s(m){return m.length?m.pop()+" ":""}function n(m,u,y,x,k,w){if(m!==y||u!==x){var _=k.push("translate(",null,e,null,o);w.push({i:_-4,x:bt(m,y)},{i:_-2,x:bt(u,x)})}else if(y||x)k.push("translate("+y+e+x+o)}function c(m,u,y,x){if(m!==u){if(m-u>180)u+=360;else if(u-m>180)m+=360;x.push({i:y.push(s(y)+"rotate(",null,a)-2,x:bt(m,u)})}else if(u)y.push(s(y)+"rotate("+u+a)}function l(m,u,y,x){if(m!==u)x.push({i:y.push(s(y)+"skewX(",null,a)-2,x:bt(m,u)});else if(u)y.push(s(y)+"skewX("+u+a)}function p(m,u,y,x,k,w){if(m!==y||u!==x){var _=k.push(s(k)+"scale(",null,",",null,")");w.push({i:_-4,x:bt(m,y)},{i:_-2,x:bt(u,x)})}else if(y!==1||x!==1)k.push(s(k)+"scale("+y+","+x+")")}return function(m,u){var y=[],x=[];return m=r(m),u=r(u),n(m.translateX,m.translateY,u.translateX,u.translateY,y,x),c(m.rotate,u.rotate,y,x),l(m.skewX,u.skewX,y,x),p(m.scaleX,m.scaleY,u.scaleX,u.scaleY,y,x),m=u=null,function(k){var w=-1,_=x.length,M;while(++w<_)y[(M=x[w]).i]=M.x(k);return y.join("")}}}var Oc=Hp(Wp,"px, ","px)","deg)"),Ic=Hp(zp,", ",")",")");var ss=0,ga=0,fa=0,Up=1000,Vn,ma,Kn=0,oo=0,Zn=0,ya=typeof performance==="object"&&performance.now?performance:Date,jp=typeof window==="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(r){setTimeout(r,17)};function Ca(){return oo||(jp(c1),oo=ya.now()+Zn)}function c1(){oo=0}function xa(){this._call=this._time=this._next=null}xa.prototype=Qn.prototype={constructor:xa,restart:function(r,e,o){if(typeof r!=="function")throw TypeError("callback is not a function");if(o=(o==null?Ca():+o)+(e==null?0:+e),!this._next&&ma!==this){if(ma)ma._next=this;else Vn=this;ma=this}this._call=r,this._time=o,$c()},stop:function(){if(this._call)this._call=null,this._time=1/0,$c()}};function Qn(r,e,o){var a=new xa;return a.restart(r,e,o),a}function Gp(){Ca(),++ss;var r=Vn,e;while(r){if((e=oo-r._time)>=0)r._call.call(void 0,e);r=r._next}--ss}function Yp(){oo=(Kn=ya.now())+Zn,ss=ga=0;try{Gp()}finally{ss=0,f1(),oo=0}}function u1(){var r=ya.now(),e=r-Kn;if(e>Up)Zn-=e,Kn=r}function f1(){var r,e=Vn,o,a=1/0;while(e)if(e._call){if(a>e._time)a=e._time;r=e,e=e._next}else o=e._next,e._next=null,e=r?r._next=o:Vn=o;ma=r,$c(a)}function $c(r){if(ss)return;if(ga)ga=clearTimeout(ga);var e=r-oo;if(e>24){if(r<1/0)ga=setTimeout(Yp,r-ya.now()-Zn);if(fa)fa=clearInterval(fa)}else{if(!fa)Kn=ya.now(),fa=setInterval(u1,Up);ss=1,jp(Yp)}}function ba(r,e,o){var a=new xa;return e=e==null?0:+e,a.restart((s)=>{a.stop(),r(s+e)},e,o),a}var d1=wh("start","end","cancel","interrupt"),p1=[],Kp=0,Xp=1,tl=2,Jn=3,Vp=4,el=5,ka=6;function Si(r,e,o,a,s,n){var c=r.__transition;if(!c)r.__transition={};else if(o in c)return;g1(r,o,{name:e,index:a,group:s,on:d1,tween:p1,time:n.time,delay:n.delay,duration:n.duration,ease:n.ease,timer:null,state:Kp})}function wa(r,e){var o=Ge(r,e);if(o.state>Kp)throw Error("too late; already scheduled");return o}function or(r,e){var o=Ge(r,e);if(o.state>Jn)throw Error("too late; already running");return o}function Ge(r,e){var o=r.__transition;if(!o||!(o=o[e]))throw Error("transition not found");return o}function g1(r,e,o){var a=r.__transition,s;a[e]=o,o.timer=Qn(n,0,o.time);function n(m){if(o.state=Xp,o.timer.restart(c,o.delay,o.time),o.delay<=m)c(m-o.delay)}function c(m){var u,y,x,k;if(o.state!==Xp)return p();for(u in a){if(k=a[u],k.name!==o.name)continue;if(k.state===Jn)return ba(c);if(k.state===Vp)k.state=ka,k.timer.stop(),k.on.call("interrupt",r,r.__data__,k.index,k.group),delete a[u];else if(+u<e)k.state=ka,k.timer.stop(),k.on.call("cancel",r,r.__data__,k.index,k.group),delete a[u]}if(ba(function(){if(o.state===Jn)o.state=Vp,o.timer.restart(l,o.delay,o.time),l(m)}),o.state=tl,o.on.call("start",r,r.__data__,o.index,o.group),o.state!==tl)return;o.state=Jn,s=Array(x=o.tween.length);for(u=0,y=-1;u<x;++u)if(k=o.tween[u].value.call(r,r.__data__,o.index,o.group))s[++y]=k;s.length=y+1}function l(m){var u=m<o.duration?o.ease.call(null,m/o.duration):(o.timer.restart(p),o.state=el,1),y=-1,x=s.length;while(++y<x)s[y].call(r,u);if(o.state===el)o.on.call("end",r,r.__data__,o.index,o.group),p()}function p(){o.state=ka,o.timer.stop(),delete a[e];for(var m in a)return;delete r.__transition}}function Sa(r,e){var o=r.__transition,a,s,n=!0,c;if(!o)return;e=e==null?null:e+"";for(c in o){if((a=o[c]).name!==e){n=!1;continue}s=a.state>tl&&a.state<el,a.state=ka,a.timer.stop(),a.on.call(s?"interrupt":"cancel",r,r.__data__,a.index,a.group),delete o[c]}if(n)delete r.__transition}function Dc(r){return this.each(function(){Sa(this,r)})}function m1(r,e){var o,a;return function(){var s=or(this,r),n=s.tween;if(n!==o){a=o=n;for(var c=0,l=a.length;c<l;++c)if(a[c].name===e){a=a.slice(),a.splice(c,1);break}}s.tween=a}}function y1(r,e,o){var a,s;if(typeof o!=="function")throw Error();return function(){var n=or(this,r),c=n.tween;if(c!==a){s=(a=c).slice();for(var l={name:e,value:o},p=0,m=s.length;p<m;++p)if(s[p].name===e){s[p]=l;break}if(p===m)s.push(l)}n.tween=s}}function Rc(r,e){var o=this._id;if(r+="",arguments.length<2){var a=Ge(this.node(),o).tween;for(var s=0,n=a.length,c;s<n;++s)if((c=a[s]).name===r)return c.value;return null}return this.each((e==null?m1:y1)(o,r,e))}function as(r,e,o){var a=r._id;return r.each(function(){var s=or(this,a);(s.value||(s.value={}))[e]=o.apply(this,arguments)}),function(s){return Ge(s,a).value[e]}}function Ta(r,e){var o;return(typeof e==="number"?bt:e instanceof $n?ra:(o=$n(e))?(e=o,ra):Ka)(r,e)}function x1(r){return function(){this.removeAttribute(r)}}function C1(r){return function(){this.removeAttributeNS(r.space,r.local)}}function b1(r,e,o){var a,s=o+"",n;return function(){var c=this.getAttribute(r);return c===s?null:c===a?n:n=e(a=c,o)}}function k1(r,e,o){var a,s=o+"",n;return function(){var c=this.getAttributeNS(r.space,r.local);return c===s?null:c===a?n:n=e(a=c,o)}}function w1(r,e,o){var a,s,n;return function(){var c,l=o(this),p;if(l==null)return void this.removeAttribute(r);return c=this.getAttribute(r),p=l+"",c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function S1(r,e,o){var a,s,n;return function(){var c,l=o(this),p;if(l==null)return void this.removeAttributeNS(r.space,r.local);return c=this.getAttributeNS(r.space,r.local),p=l+"",c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function qc(r,e){var o=ii(r),a=o==="transform"?Ic:Ta;return this.attrTween(r,typeof e==="function"?(o.local?S1:w1)(o,a,as(this,"attr."+r,e)):e==null?(o.local?C1:x1)(o):(o.local?k1:b1)(o,a,e))}function T1(r,e){return function(o){this.setAttribute(r,e.call(this,o))}}function _1(r,e){return function(o){this.setAttributeNS(r.space,r.local,e.call(this,o))}}function B1(r,e){var o,a;function s(){var n=e.apply(this,arguments);if(n!==a)o=(a=n)&&_1(r,n);return o}return s._value=e,s}function v1(r,e){var o,a;function s(){var n=e.apply(this,arguments);if(n!==a)o=(a=n)&&T1(r,n);return o}return s._value=e,s}function Wc(r,e){var o="attr."+r;if(arguments.length<2)return(o=this.tween(o))&&o._value;if(e==null)return this.tween(o,null);if(typeof e!=="function")throw Error();var a=ii(r);return this.tween(o,(a.local?B1:v1)(a,e))}function L1(r,e){return function(){wa(this,r).delay=+e.apply(this,arguments)}}function F1(r,e){return e=+e,function(){wa(this,r).delay=e}}function zc(r){var e=this._id;return arguments.length?this.each((typeof r==="function"?L1:F1)(e,r)):Ge(this.node(),e).delay}function A1(r,e){return function(){or(this,r).duration=+e.apply(this,arguments)}}function M1(r,e){return e=+e,function(){or(this,r).duration=e}}function Hc(r){var e=this._id;return arguments.length?this.each((typeof r==="function"?A1:M1)(e,r)):Ge(this.node(),e).duration}function E1(r,e){if(typeof e!=="function")throw Error();return function(){or(this,r).ease=e}}function Yc(r){var e=this._id;return arguments.length?this.each(E1(e,r)):Ge(this.node(),e).ease}function O1(r,e){return function(){var o=e.apply(this,arguments);if(typeof o!=="function")throw Error();or(this,r).ease=o}}function Uc(r){if(typeof r!=="function")throw Error();return this.each(O1(this._id,r))}function jc(r){if(typeof r!=="function")r=rs(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=[],p,m=0;m<c;++m)if((p=n[m])&&r.call(p,p.__data__,m,n))l.push(p);return new yr(a,this._parents,this._name,this._id)}function Gc(r){if(r._id!==this._id)throw Error();for(var e=this._groups,o=r._groups,a=e.length,s=o.length,n=Math.min(a,s),c=Array(a),l=0;l<n;++l)for(var p=e[l],m=o[l],u=p.length,y=c[l]=Array(u),x,k=0;k<u;++k)if(x=p[k]||m[k])y[k]=x;for(;l<a;++l)c[l]=e[l];return new yr(c,this._parents,this._name,this._id)}function I1(r){return(r+"").trim().split(/^|\s+/).every(function(e){var o=e.indexOf(".");if(o>=0)e=e.slice(0,o);return!e||e==="start"})}function $1(r,e,o){var a,s,n=I1(e)?wa:or;return function(){var c=n(this,r),l=c.on;if(l!==a)(s=(a=l).copy()).on(e,o);c.on=s}}function Xc(r,e){var o=this._id;return arguments.length<2?Ge(this.node(),o).on.on(r):this.each($1(o,r,e))}function D1(r){return function(){var e=this.parentNode;for(var o in this.__transition)if(+o!==r)return;if(e)e.removeChild(this)}}function Vc(){return this.on("end.remove",D1(this._id))}function Kc(r){var e=this._name,o=this._id;if(typeof r!=="function")r=Xi(r);for(var a=this._groups,s=a.length,n=Array(s),c=0;c<s;++c)for(var l=a[c],p=l.length,m=n[c]=Array(p),u,y,x=0;x<p;++x)if((u=l[x])&&(y=r.call(u,u.__data__,x,l))){if("__data__"in u)y.__data__=u.__data__;m[x]=y,Si(m[x],e,o,x,m,Ge(u,o))}return new yr(n,this._parents,e,o)}function Zc(r){var e=this._name,o=this._id;if(typeof r!=="function")r=es(r);for(var a=this._groups,s=a.length,n=[],c=[],l=0;l<s;++l)for(var p=a[l],m=p.length,u,y=0;y<m;++y)if(u=p[y]){for(var x=r.call(u,u.__data__,y,p),k,w=Ge(u,o),_=0,M=x.length;_<M;++_)if(k=x[_])Si(k,e,o,_,x,w);n.push(x),c.push(u)}return new yr(n,c,e,o)}var P1=wi.prototype.constructor;function Qc(){return new P1(this._groups,this._parents)}function R1(r,e){var o,a,s;return function(){var n=Vi(this,r),c=(this.style.removeProperty(r),Vi(this,r));return n===c?null:n===o&&c===a?s:s=e(o=n,a=c)}}function Zp(r){return function(){this.style.removeProperty(r)}}function q1(r,e,o){var a,s=o+"",n;return function(){var c=Vi(this,r);return c===s?null:c===a?n:n=e(a=c,o)}}function N1(r,e,o){var a,s,n;return function(){var c=Vi(this,r),l=o(this),p=l+"";if(l==null)p=l=(this.style.removeProperty(r),Vi(this,r));return c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function W1(r,e){var o,a,s,n="style."+e,c="end."+n,l;return function(){var p=or(this,r),m=p.on,u=p.value[n]==null?l||(l=Zp(e)):void 0;if(m!==o||s!==u)(a=(o=m).copy()).on(c,s=u);p.on=a}}function Jc(r,e,o){var a=(r+="")==="transform"?Oc:Ta;return e==null?this.styleTween(r,R1(r,a)).on("end.style."+r,Zp(r)):typeof e==="function"?this.styleTween(r,N1(r,a,as(this,"style."+r,e))).each(W1(this._id,r)):this.styleTween(r,q1(r,a,e),o).on("end.style."+r,null)}function z1(r,e,o){return function(a){this.style.setProperty(r,e.call(this,a),o)}}function H1(r,e,o){var a,s;function n(){var c=e.apply(this,arguments);if(c!==s)a=(s=c)&&z1(r,c,o);return a}return n._value=e,n}function tu(r,e,o){var a="style."+(r+="");if(arguments.length<2)return(a=this.tween(a))&&a._value;if(e==null)return this.tween(a,null);if(typeof e!=="function")throw Error();return this.tween(a,H1(r,e,o==null?"":o))}function Y1(r){return function(){this.textContent=r}}function U1(r){return function(){var e=r(this);this.textContent=e==null?"":e}}function eu(r){return this.tween("text",typeof r==="function"?U1(as(this,"text",r)):Y1(r==null?"":r+""))}function j1(r){return function(e){this.textContent=r.call(this,e)}}function G1(r){var e,o;function a(){var s=r.apply(this,arguments);if(s!==o)e=(o=s)&&j1(s);return e}return a._value=r,a}function ru(r){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(r==null)return this.tween(e,null);if(typeof r!=="function")throw Error();return this.tween(e,G1(r))}function iu(){var r=this._name,e=this._id,o=rl();for(var a=this._groups,s=a.length,n=0;n<s;++n)for(var c=a[n],l=c.length,p,m=0;m<l;++m)if(p=c[m]){var u=Ge(p,e);Si(p,r,o,m,c,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new yr(a,this._parents,r,o)}function ou(){var r,e,o=this,a=o._id,s=o.size();return new Promise(function(n,c){var l={value:c},p={value:function(){if(--s===0)n()}};if(o.each(function(){var m=or(this,a),u=m.on;if(u!==r)e=(r=u).copy(),e._.cancel.push(l),e._.interrupt.push(l),e._.end.push(p);m.on=e}),s===0)n()})}var X1=0;function yr(r,e,o,a){this._groups=r,this._parents=e,this._name=o,this._id=a}function Qp(r){return wi().transition(r)}function rl(){return++X1}var _i=wi.prototype;yr.prototype=Qp.prototype={constructor:yr,select:Kc,selectAll:Zc,selectChild:_i.selectChild,selectChildren:_i.selectChildren,filter:jc,merge:Gc,selection:Qc,transition:iu,call:_i.call,nodes:_i.nodes,node:_i.node,size:_i.size,empty:_i.empty,each:_i.each,on:Xc,attr:qc,attrTween:Wc,style:Jc,styleTween:tu,text:eu,textTween:ru,remove:Vc,tween:Rc,delay:zc,duration:Hc,ease:Yc,easeVarying:Uc,end:ou,[Symbol.iterator]:_i[Symbol.iterator]};function il(r){return((r*=2)<=1?r*r*r:(r-=2)*r*r+2)/2}var V1={time:null,delay:0,duration:250,ease:il};function K1(r,e){var o;while(!(o=r.__transition)||!(o=o[e]))if(!(r=r.parentNode))throw Error(`transition ${e} not found`);return o}function su(r){var e,o;if(r instanceof yr)e=r._id,r=r._name;else e=rl(),(o=V1).time=Ca(),r=r==null?null:r+"";for(var a=this._groups,s=a.length,n=0;n<s;++n)for(var c=a[n],l=c.length,p,m=0;m<l;++m)if(p=c[m])Si(p,r,e,m,c,o||K1(p,e));return new yr(a,this._parents,r,e)}wi.prototype.interrupt=Dc;wi.prototype.transition=su;var{abs:tE,max:eE,min:rE}=Math;function Jp(r){return[+r[0],+r[1]]}function Z1(r){return[Jp(r[0]),Jp(r[1])]}var iE={name:"x",handles:["w","e"].map(au),input:function(r,e){return r==null?null:[[+r[0],e[0][1]],[+r[1],e[1][1]]]},output:function(r){return r&&[r[0][0],r[1][0]]}},oE={name:"y",handles:["n","s"].map(au),input:function(r,e){return r==null?null:[[e[0][0],+r[0]],[e[1][0],+r[1]]]},output:function(r){return r&&[r[0][1],r[1][1]]}},sE={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(au),input:function(r){return r==null?null:Z1(r)},output:function(r){return r}};function au(r){return{type:r}}var nu=Math.PI,lu=2*nu;var Q1=lu-0.000001;function tg(r){this._+=r[0];for(let e=1,o=r.length;e<o;++e)this._+=arguments[e]+r[e]}function J1(r){let e=Math.floor(r);if(!(e>=0))throw Error(`invalid digits: ${r}`);if(e>15)return tg;let o=10**e;return function(a){this._+=a[0];for(let s=1,n=a.length;s<n;++s)this._+=Math.round(arguments[s]*o)/o+a[s]}}class ns{constructor(r){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=r==null?tg:J1(r)}moveTo(r,e){this._append`M${this._x0=this._x1=+r},${this._y0=this._y1=+e}`}closePath(){if(this._x1!==null)this._x1=this._x0,this._y1=this._y0,this._append`Z`}lineTo(r,e){this._append`L${this._x1=+r},${this._y1=+e}`}quadraticCurveTo(r,e,o,a){this._append`Q${+r},${+e},${this._x1=+o},${this._y1=+a}`}bezierCurveTo(r,e,o,a,s,n){this._append`C${+r},${+e},${+o},${+a},${this._x1=+s},${this._y1=+n}`}arcTo(r,e,o,a,s){if(r=+r,e=+e,o=+o,a=+a,s=+s,s<0)throw Error(`negative radius: ${s}`);let n=this._x1,c=this._y1,l=o-r,p=a-e,m=n-r,u=c-e,y=m*m+u*u;if(this._x1===null)this._append`M${this._x1=r},${this._y1=e}`;else if(!(y>0.000001));else if(!(Math.abs(u*l-p*m)>0.000001)||!s)this._append`L${this._x1=r},${this._y1=e}`;else{let x=o-n,k=a-c,w=l*l+p*p,_=x*x+k*k,M=Math.sqrt(w),q=Math.sqrt(y),Y=s*Math.tan((nu-Math.acos((w+y-_)/(2*M*q)))/2),V=Y/q,Q=Y/M;if(Math.abs(V-1)>0.000001)this._append`L${r+V*m},${e+V*u}`;this._append`A${s},${s},0,0,${+(u*x>m*k)},${this._x1=r+Q*l},${this._y1=e+Q*p}`}}arc(r,e,o,a,s,n){if(r=+r,e=+e,o=+o,n=!!n,o<0)throw Error(`negative radius: ${o}`);let c=o*Math.cos(a),l=o*Math.sin(a),p=r+c,m=e+l,u=1^n,y=n?a-s:s-a;if(this._x1===null)this._append`M${p},${m}`;else if(Math.abs(this._x1-p)>0.000001||Math.abs(this._y1-m)>0.000001)this._append`L${p},${m}`;if(!o)return;if(y<0)y=y%lu+lu;if(y>Q1)this._append`A${o},${o},0,1,${u},${r-c},${e-l}A${o},${o},0,1,${u},${this._x1=p},${this._y1=m}`;else if(y>0.000001)this._append`A${o},${o},0,${+(y>=nu)},${u},${this._x1=r+o*Math.cos(s)},${this._y1=e+o*Math.sin(s)}`}rect(r,e,o,a){this._append`M${this._x0=this._x1=+r},${this._y0=this._y1=+e}h${o=+o}v${+a}h${-o}Z`}toString(){return this._}}function eg(){return new ns}eg.prototype=ns.prototype;function we(r){return function(){return r}}var{abs:Ws,atan2:Lt,cos:Ur,max:Cc,min:So,sin:Bn,sqrt:aa}=Math,xt=0.000000000001,Za=Math.PI,Ni=Za/2,ia=2*Za;function Sc(r){return r>1?0:r<-1?Za:Math.acos(r)}function Ys(r){return r>=1?Ni:r<=-1?-Ni:Math.asin(r)}function oa(r){let e=3;return r.digits=function(o){if(!arguments.length)return e;if(o==null)e=null;else{let a=Math.floor(o);if(!(a>=0))throw RangeError(`invalid digits: ${o}`);e=a}return r},()=>new ns(e)}var Ac=Array.prototype.slice;function Mi(r){return typeof r==="object"&&"length"in r?r:Array.from(r)}function rg(r){this._context=r}rg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;default:this._context.lineTo(r,e);break}}};function si(r){return new rg(r)}function Ao(r){return r[0]}function To(r){return r[1]}function sa(r,e){var o=we(!0),a=null,s=si,n=null,c=oa(l);r=typeof r==="function"?r:r===void 0?Ao:we(r),e=typeof e==="function"?e:e===void 0?To:we(e);function l(p){var m,u=(p=Mi(p)).length,y,x=!1,k;if(a==null)n=s(k=c());for(m=0;m<=u;++m){if(!(m<u&&o(y=p[m],m,p))===x)if(x=!x)n.lineStart();else n.lineEnd();if(x)n.point(+r(y,m,p),+e(y,m,p))}if(k)return n=null,k+""||null}return l.x=function(p){return arguments.length?(r=typeof p==="function"?p:we(+p),l):r},l.y=function(p){return arguments.length?(e=typeof p==="function"?p:we(+p),l):e},l.defined=function(p){return arguments.length?(o=typeof p==="function"?p:we(!!p),l):o},l.curve=function(p){return arguments.length?(s=p,a!=null&&(n=s(a)),l):s},l.context=function(p){return arguments.length?(p==null?a=n=null:n=s(a=p),l):a},l}class hu{constructor(r,e){this._context=r,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line}point(r,e){switch(r=+r,e=+e,this._point){case 0:{if(this._point=1,this._line)this._context.lineTo(r,e);else this._context.moveTo(r,e);break}case 1:this._point=2;default:{if(this._x)this._context.bezierCurveTo(this._x0=(this._x0+r)/2,this._y0,this._x0,e,r,e);else this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,r,this._y0,r,e);break}}this._x0=r,this._y0=e}}function ca(r){return new hu(r,!0)}function _a(r){return new hu(r,!1)}function Lr(){}function ls(r,e,o){r._context.bezierCurveTo((2*r._x0+r._x1)/3,(2*r._y0+r._y1)/3,(r._x0+2*r._x1)/3,(r._y0+2*r._y1)/3,(r._x0+4*r._x1+e)/6,(r._y0+4*r._y1+o)/6)}function Ba(r){this._context=r}Ba.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:ls(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function so(r){return new Ba(r)}function ig(r){this._context=r}ig.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._x2=r,this._y2=e;break;case 1:this._point=2,this._x3=r,this._y3=e;break;case 2:this._point=3,this._x4=r,this._y4=e,this._context.moveTo((this._x0+4*this._x1+r)/6,(this._y0+4*this._y1+e)/6);break;default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function ol(r){return new ig(r)}function og(r){this._context=r}og.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var o=(this._x0+4*this._x1+r)/6,a=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(o,a):this._context.moveTo(o,a);break;case 3:this._point=4;default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function sl(r){return new og(r)}function sg(r,e){this._basis=new Ba(r),this._beta=e}sg.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var r=this._x,e=this._y,o=r.length-1;if(o>0){var a=r[0],s=e[0],n=r[o]-a,c=e[o]-s,l=-1,p;while(++l<=o)p=l/o,this._basis.point(this._beta*r[l]+(1-this._beta)*(a+p*n),this._beta*e[l]+(1-this._beta)*(s+p*c))}this._x=this._y=null,this._basis.lineEnd()},point:function(r,e){this._x.push(+r),this._y.push(+e)}};var cu=function r(e){function o(a){return e===1?new Ba(a):new sg(a,e)}return o.beta=function(a){return r(+a)},o}(0.85);function hs(r,e,o){r._context.bezierCurveTo(r._x1+r._k*(r._x2-r._x0),r._y1+r._k*(r._y2-r._y0),r._x2+r._k*(r._x1-e),r._y2+r._k*(r._y1-o),r._x2,r._y2)}function al(r,e){this._context=r,this._k=(1-e)/6}al.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:hs(this,this._x1,this._y1);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2,this._x1=r,this._y1=e;break;case 2:this._point=3;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var va=function r(e){function o(a){return new al(a,e)}return o.tension=function(a){return r(+a)},o}(0);function nl(r,e){this._context=r,this._k=(1-e)/6}nl.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._x3=r,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=r,this._y4=e);break;case 2:this._point=3,this._x5=r,this._y5=e;break;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var uu=function r(e){function o(a){return new nl(a,e)}return o.tension=function(a){return r(+a)},o}(0);function ll(r,e){this._context=r,this._k=(1-e)/6}ll.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var fu=function r(e){function o(a){return new ll(a,e)}return o.tension=function(a){return r(+a)},o}(0);function La(r,e,o){var{_x1:a,_y1:s,_x2:n,_y2:c}=r;if(r._l01_a>xt){var l=2*r._l01_2a+3*r._l01_a*r._l12_a+r._l12_2a,p=3*r._l01_a*(r._l01_a+r._l12_a);a=(a*l-r._x0*r._l12_2a+r._x2*r._l01_2a)/p,s=(s*l-r._y0*r._l12_2a+r._y2*r._l01_2a)/p}if(r._l23_a>xt){var m=2*r._l23_2a+3*r._l23_a*r._l12_a+r._l12_2a,u=3*r._l23_a*(r._l23_a+r._l12_a);n=(n*m+r._x1*r._l23_2a-e*r._l12_2a)/u,c=(c*m+r._y1*r._l23_2a-o*r._l12_2a)/u}r._context.bezierCurveTo(a,s,n,c,r._x2,r._y2)}function ag(r,e){this._context=r,this._alpha=e}ag.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Fa=function r(e){function o(a){return e?new ag(a,e):new al(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function ng(r,e){this._context=r,this._alpha=e}ng.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=r,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=r,this._y4=e);break;case 2:this._point=3,this._x5=r,this._y5=e;break;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var du=function r(e){function o(a){return e?new ng(a,e):new nl(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function lg(r,e){this._context=r,this._alpha=e}lg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var pu=function r(e){function o(a){return e?new lg(a,e):new ll(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function hg(r){this._context=r}hg.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._point=0},lineEnd:function(){if(this._point)this._context.closePath()},point:function(r,e){if(r=+r,e=+e,this._point)this._context.lineTo(r,e);else this._point=1,this._context.moveTo(r,e)}};function hl(r){return new hg(r)}function cg(r){return r<0?-1:1}function ug(r,e,o){var a=r._x1-r._x0,s=e-r._x1,n=(r._y1-r._y0)/(a||s<0&&-0),c=(o-r._y1)/(s||a<0&&-0),l=(n*s+c*a)/(a+s);return(cg(n)+cg(c))*Math.min(Math.abs(n),Math.abs(c),0.5*Math.abs(l))||0}function fg(r,e){var o=r._x1-r._x0;return o?(3*(r._y1-r._y0)/o-e)/2:e}function gu(r,e,o){var{_x0:a,_y0:s,_x1:n,_y1:c}=r,l=(n-a)/3;r._context.bezierCurveTo(a+l,s+l*e,n-l,c-l*o,n,c)}function cl(r){this._context=r}cl.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:gu(this,this._t0,fg(this,this._t0));break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){var o=NaN;if(r=+r,e=+e,r===this._x1&&e===this._y1)return;switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3,gu(this,fg(this,o=ug(this,r,e)),o);break;default:gu(this,this._t0,o=ug(this,r,e));break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e,this._t0=o}};function dg(r){this._context=new pg(r)}(dg.prototype=Object.create(cl.prototype)).point=function(r,e){cl.prototype.point.call(this,e,r)};function pg(r){this._context=r}pg.prototype={moveTo:function(r,e){this._context.moveTo(e,r)},closePath:function(){this._context.closePath()},lineTo:function(r,e){this._context.lineTo(e,r)},bezierCurveTo:function(r,e,o,a,s,n){this._context.bezierCurveTo(e,r,a,o,n,s)}};function Aa(r){return new cl(r)}function Ma(r){return new dg(r)}function mg(r){this._context=r}mg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var r=this._x,e=this._y,o=r.length;if(o)if(this._line?this._context.lineTo(r[0],e[0]):this._context.moveTo(r[0],e[0]),o===2)this._context.lineTo(r[1],e[1]);else{var a=gg(r),s=gg(e);for(var n=0,c=1;c<o;++n,++c)this._context.bezierCurveTo(a[0][n],s[0][n],a[1][n],s[1][n],r[c],e[c])}if(this._line||this._line!==0&&o===1)this._context.closePath();this._line=1-this._line,this._x=this._y=null},point:function(r,e){this._x.push(+r),this._y.push(+e)}};function gg(r){var e,o=r.length-1,a,s=Array(o),n=Array(o),c=Array(o);s[0]=0,n[0]=2,c[0]=r[0]+2*r[1];for(e=1;e<o-1;++e)s[e]=1,n[e]=4,c[e]=4*r[e]+2*r[e+1];s[o-1]=2,n[o-1]=7,c[o-1]=8*r[o-1]+r[o];for(e=1;e<o;++e)a=s[e]/n[e-1],n[e]-=a,c[e]-=a*c[e-1];s[o-1]=c[o-1]/n[o-1];for(e=o-2;e>=0;--e)s[e]=(c[e]-s[e+1])/n[e];n[o-1]=(r[o]+s[o-1])/2;for(e=0;e<o-1;++e)n[e]=2*r[e+1]-s[e+1];return[s,n]}function cs(r){return new mg(r)}function ul(r,e){this._context=r,this._t=e}ul.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){if(0<this._t&&this._t<1&&this._point===2)this._context.lineTo(this._x,this._y);if(this._line||this._line!==0&&this._point===1)this._context.closePath();if(this._line>=0)this._t=1-this._t,this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(r,e);else{var o=this._x*(1-this._t)+r*this._t;this._context.lineTo(o,this._y),this._context.lineTo(o,e)}break}}this._x=r,this._y=e}};function us(r){return new ul(r,0.5)}function Ea(r){return new ul(r,0)}function Oa(r){return new ul(r,1)}function Ki(r,e,o){this.k=r,this.x=e,this.y=o}Ki.prototype={constructor:Ki,scale:function(r){return r===1?this:new Ki(this.k*r,this.x,this.y)},translate:function(r,e){return r===0&e===0?this:new Ki(this.k,this.x+this.k*r,this.y+this.k*e)},apply:function(r){return[r[0]*this.k+this.x,r[1]*this.k+this.y]},applyX:function(r){return r*this.k+this.x},applyY:function(r){return r*this.k+this.y},invert:function(r){return[(r[0]-this.x)/this.k,(r[1]-this.y)/this.k]},invertX:function(r){return(r-this.x)/this.k},invertY:function(r){return(r-this.y)/this.k},rescaleX:function(r){return r.copy().domain(r.range().map(this.invertX,this).map(r.invert,r))},rescaleY:function(r){return r.copy().domain(r.range().map(this.invertY,this).map(r.invert,r))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var mu=new Ki(1,0,0);yu.prototype=Ki.prototype;function yu(r){while(!r.__zoom)if(!(r=r.parentNode))return mu;return r.__zoom}var J=t((r)=>{let{securityLevel:e}=d(),o=g("body");if(e==="sandbox"){let n=g(`#i${r}`).node()?.contentDocument??document;o=g(n.body)}return o.select(`#${r}`)},"selectSvgElement");function zg(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}t(zg,"getDefaultExportFromCjs");var lr={},fl={},Zi={},yg;function fs(){if(yg)return Zi;yg=1;function r(c){return typeof c>"u"||c===null}t(r,"isNothing");function e(c){return typeof c==="object"&&c!==null}t(e,"isObject");function o(c){if(Array.isArray(c))return c;else if(r(c))return[];return[c]}t(o,"toArray");function a(c,l){if(l){let p=Object.keys(l);for(let m=0,u=p.length;m<u;m+=1){let y=p[m];c[y]=l[y]}}return c}t(a,"extend");function s(c,l){let p="";for(let m=0;m<l;m+=1)p+=c;return p}t(s,"repeat");function n(c){return c===0&&Number.NEGATIVE_INFINITY===1/c}return t(n,"isNegativeZero"),Zi.isNothing=r,Zi.isObject=e,Zi.toArray=o,Zi.repeat=s,Zi.isNegativeZero=n,Zi.extend=a,Zi}t(fs,"requireCommon");var xu,xg;function ds(){if(xg)return xu;xg=1;function r(o,a){let s="",n=o.reason||"(unknown reason)";if(!o.mark)return n;if(o.mark.name)s+='in "'+o.mark.name+'" ';if(s+="("+(o.mark.line+1)+":"+(o.mark.column+1)+")",!a&&o.mark.snippet)s+=`
|
|
128
|
+
`},"getStyles"),jb=t((r,e)=>{if(e!==void 0)En[r]=e},"addStylesForDiagram"),wc=Ub,ko={};er(ko,{clear:()=>L,getAccDescription:()=>I,getAccTitle:()=>R,getDiagramTitle:()=>D,setAccDescription:()=>P,setAccTitle:()=>N,setDiagramTitle:()=>O});var xh="",Ch="",bh="",kh=t((r)=>q(r,A()),"sanitizeText"),L=t(()=>{xh="",bh="",Ch=""},"clear"),N=t((r)=>{xh=kh(r).replace(/^\s+/g,"")},"setAccTitle"),R=t(()=>xh,"getAccTitle"),P=t((r)=>{bh=kh(r).replace(/\n\s+/g,`
|
|
129
|
+
`)},"setAccDescription"),I=t(()=>bh,"getAccDescription"),O=t((r)=>{Ch=kh(r)},"setDiagramTitle"),D=t(()=>Ch,"getDiagramTitle"),cp=i,Gb=Ti,d=A,fr=qs,Fr=mr,Rn=t((r)=>q(r,d()),"sanitizeText"),Wa=pn,Xb=t(()=>ko,"getCommonDb"),Pn={},Li=t((r,e,o)=>{if(Pn[r])cp.warn(`Diagram with id ${r} already registered. Overwriting.`);if(Pn[r]=e,o)up(r,o);jb(r,e.styles),e.injectUtils?.(cp,Gb,d,Rn,Wa,Xb(),()=>{})},"registerDiagram"),Co=t((r)=>{if(r in Pn)return Pn[r];throw new Vb(r)},"getDiagram"),Vb=class extends Error{static{t(this,"DiagramNotFoundError")}constructor(r){super(`Diagram ${r} not found.`)}};var Kb={value:()=>{}};function bp(){for(var r=0,e=arguments.length,o={},a;r<e;++r){if(!(a=arguments[r]+"")||a in o||/[\s.]/.test(a))throw Error("illegal type: "+a);o[a]=[]}return new qn(o)}function qn(r){this._=r}function Zb(r,e){return r.trim().split(/^|\s+/).map(function(o){var a="",s=o.indexOf(".");if(s>=0)a=o.slice(s+1),o=o.slice(0,s);if(o&&!e.hasOwnProperty(o))throw Error("unknown type: "+o);return{type:o,name:a}})}qn.prototype=bp.prototype={constructor:qn,on:function(r,e){var o=this._,a=Zb(r+"",o),s,n=-1,c=a.length;if(arguments.length<2){while(++n<c)if((s=(r=a[n]).type)&&(s=Qb(o[s],r.name)))return s;return}if(e!=null&&typeof e!=="function")throw Error("invalid callback: "+e);while(++n<c)if(s=(r=a[n]).type)o[s]=Cp(o[s],r.name,e);else if(e==null)for(s in o)o[s]=Cp(o[s],r.name,null);return this},copy:function(){var r={},e=this._;for(var o in e)r[o]=e[o].slice();return new qn(r)},call:function(r,e){if((s=arguments.length-2)>0)for(var o=Array(s),a=0,s,n;a<s;++a)o[a]=arguments[a+2];if(!this._.hasOwnProperty(r))throw Error("unknown type: "+r);for(n=this._[r],a=0,s=n.length;a<s;++a)n[a].value.apply(e,o)},apply:function(r,e,o){if(!this._.hasOwnProperty(r))throw Error("unknown type: "+r);for(var a=this._[r],s=0,n=a.length;s<n;++s)a[s].value.apply(e,o)}};function Qb(r,e){for(var o=0,a=r.length,s;o<a;++o)if((s=r[o]).name===e)return s.value}function Cp(r,e,o){for(var a=0,s=r.length;a<s;++a)if(r[a].name===e){r[a]=Kb,r=r.slice(0,a).concat(r.slice(a+1));break}if(o!=null)r.push({name:e,value:o});return r}var wh=bp;var Nn="http://www.w3.org/1999/xhtml",Sh={svg:"http://www.w3.org/2000/svg",xhtml:Nn,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function ii(r){var e=r+="",o=e.indexOf(":");if(o>=0&&(e=r.slice(0,o))!=="xmlns")r=r.slice(o+1);return Sh.hasOwnProperty(e)?{space:Sh[e],local:r}:r}function Jb(r){return function(){var e=this.ownerDocument,o=this.namespaceURI;return o===Nn&&e.documentElement.namespaceURI===Nn?e.createElement(r):e.createElementNS(o,r)}}function tk(r){return function(){return this.ownerDocument.createElementNS(r.space,r.local)}}function Ps(r){var e=ii(r);return(e.local?tk:Jb)(e)}function ek(){}function Xi(r){return r==null?ek:function(){return this.querySelector(r)}}function Th(r){if(typeof r!=="function")r=Xi(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=Array(c),p,m,u=0;u<c;++u)if((p=n[u])&&(m=r.call(p,p.__data__,u,n))){if("__data__"in p)m.__data__=p.__data__;l[u]=m}return new Ee(a,this._parents)}function _h(r){return r==null?[]:Array.isArray(r)?r:Array.from(r)}function rk(){return[]}function es(r){return r==null?rk:function(){return this.querySelectorAll(r)}}function ik(r){return function(){return _h(r.apply(this,arguments))}}function Bh(r){if(typeof r==="function")r=ik(r);else r=es(r);for(var e=this._groups,o=e.length,a=[],s=[],n=0;n<o;++n)for(var c=e[n],l=c.length,p,m=0;m<l;++m)if(p=c[m])a.push(r.call(p,p.__data__,m,c)),s.push(p);return new Ee(a,s)}function rs(r){return function(){return this.matches(r)}}function Wn(r){return function(e){return e.matches(r)}}var ok=Array.prototype.find;function sk(r){return function(){return ok.call(this.children,r)}}function ak(){return this.firstElementChild}function vh(r){return this.select(r==null?ak:sk(typeof r==="function"?r:Wn(r)))}var nk=Array.prototype.filter;function lk(){return Array.from(this.children)}function hk(r){return function(){return nk.call(this.children,r)}}function Lh(r){return this.selectAll(r==null?lk:hk(typeof r==="function"?r:Wn(r)))}function Fh(r){if(typeof r!=="function")r=rs(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=[],p,m=0;m<c;++m)if((p=n[m])&&r.call(p,p.__data__,m,n))l.push(p);return new Ee(a,this._parents)}function Rs(r){return Array(r.length)}function Ah(){return new Ee(this._enter||this._groups.map(Rs),this._parents)}function Ns(r,e){this.ownerDocument=r.ownerDocument,this.namespaceURI=r.namespaceURI,this._next=null,this._parent=r,this.__data__=e}Ns.prototype={constructor:Ns,appendChild:function(r){return this._parent.insertBefore(r,this._next)},insertBefore:function(r,e){return this._parent.insertBefore(r,e)},querySelector:function(r){return this._parent.querySelector(r)},querySelectorAll:function(r){return this._parent.querySelectorAll(r)}};function Mh(r){return function(){return r}}function ck(r,e,o,a,s,n){var c=0,l,p=e.length,m=n.length;for(;c<m;++c)if(l=e[c])l.__data__=n[c],a[c]=l;else o[c]=new Ns(r,n[c]);for(;c<p;++c)if(l=e[c])s[c]=l}function uk(r,e,o,a,s,n,c){var l,p,m=new Map,u=e.length,y=n.length,x=Array(u),k;for(l=0;l<u;++l)if(p=e[l])if(x[l]=k=c.call(p,p.__data__,l,e)+"",m.has(k))s[l]=p;else m.set(k,p);for(l=0;l<y;++l)if(k=c.call(r,n[l],l,n)+"",p=m.get(k))a[l]=p,p.__data__=n[l],m.delete(k);else o[l]=new Ns(r,n[l]);for(l=0;l<u;++l)if((p=e[l])&&m.get(x[l])===p)s[l]=p}function fk(r){return r.__data__}function Eh(r,e){if(!arguments.length)return Array.from(this,fk);var o=e?uk:ck,a=this._parents,s=this._groups;if(typeof r!=="function")r=Mh(r);for(var n=s.length,c=Array(n),l=Array(n),p=Array(n),m=0;m<n;++m){var u=a[m],y=s[m],x=y.length,k=dk(r.call(u,u&&u.__data__,m,a)),w=k.length,_=l[m]=Array(w),M=c[m]=Array(w),W=p[m]=Array(x);o(u,y,_,M,W,k,e);for(var U=0,V=0,Z,tt;U<w;++U)if(Z=_[U]){if(U>=V)V=U+1;while(!(tt=M[V])&&++V<w);Z._next=tt||null}}return c=new Ee(c,a),c._enter=l,c._exit=p,c}function dk(r){return typeof r==="object"&&"length"in r?r:Array.from(r)}function Oh(){return new Ee(this._exit||this._groups.map(Rs),this._parents)}function Ih(r,e,o){var a=this.enter(),s=this,n=this.exit();if(typeof r==="function"){if(a=r(a),a)a=a.selection()}else a=a.append(r+"");if(e!=null){if(s=e(s),s)s=s.selection()}if(o==null)n.remove();else o(n);return a&&s?a.merge(s).order():s}function $h(r){var e=r.selection?r.selection():r;for(var o=this._groups,a=e._groups,s=o.length,n=a.length,c=Math.min(s,n),l=Array(s),p=0;p<c;++p)for(var m=o[p],u=a[p],y=m.length,x=l[p]=Array(y),k,w=0;w<y;++w)if(k=m[w]||u[w])x[w]=k;for(;p<s;++p)l[p]=o[p];return new Ee(l,this._parents)}function Dh(){for(var r=this._groups,e=-1,o=r.length;++e<o;)for(var a=r[e],s=a.length-1,n=a[s],c;--s>=0;)if(c=a[s]){if(n&&c.compareDocumentPosition(n)^4)n.parentNode.insertBefore(c,n);n=c}return this}function Ph(r){if(!r)r=pk;function e(y,x){return y&&x?r(y.__data__,x.__data__):!y-!x}for(var o=this._groups,a=o.length,s=Array(a),n=0;n<a;++n){for(var c=o[n],l=c.length,p=s[n]=Array(l),m,u=0;u<l;++u)if(m=c[u])p[u]=m;p.sort(e)}return new Ee(s,this._parents).order()}function pk(r,e){return r<e?-1:r>e?1:r>=e?0:NaN}function Rh(){var r=arguments[0];return arguments[0]=this,r.apply(null,arguments),this}function qh(){return Array.from(this)}function Nh(){for(var r=this._groups,e=0,o=r.length;e<o;++e)for(var a=r[e],s=0,n=a.length;s<n;++s){var c=a[s];if(c)return c}return null}function Wh(){let r=0;for(let e of this)++r;return r}function zh(){return!this.node()}function Hh(r){for(var e=this._groups,o=0,a=e.length;o<a;++o)for(var s=e[o],n=0,c=s.length,l;n<c;++n)if(l=s[n])r.call(l,l.__data__,n,s);return this}function gk(r){return function(){this.removeAttribute(r)}}function mk(r){return function(){this.removeAttributeNS(r.space,r.local)}}function yk(r,e){return function(){this.setAttribute(r,e)}}function xk(r,e){return function(){this.setAttributeNS(r.space,r.local,e)}}function Ck(r,e){return function(){var o=e.apply(this,arguments);if(o==null)this.removeAttribute(r);else this.setAttribute(r,o)}}function bk(r,e){return function(){var o=e.apply(this,arguments);if(o==null)this.removeAttributeNS(r.space,r.local);else this.setAttributeNS(r.space,r.local,o)}}function Yh(r,e){var o=ii(r);if(arguments.length<2){var a=this.node();return o.local?a.getAttributeNS(o.space,o.local):a.getAttribute(o)}return this.each((e==null?o.local?mk:gk:typeof e==="function"?o.local?bk:Ck:o.local?xk:yk)(o,e))}function ta(r){return r.ownerDocument&&r.ownerDocument.defaultView||r.document&&r||r.defaultView}function kk(r){return function(){this.style.removeProperty(r)}}function wk(r,e,o){return function(){this.style.setProperty(r,e,o)}}function Sk(r,e,o){return function(){var a=e.apply(this,arguments);if(a==null)this.style.removeProperty(r);else this.style.setProperty(r,a,o)}}function Uh(r,e,o){return arguments.length>1?this.each((e==null?kk:typeof e==="function"?Sk:wk)(r,e,o==null?"":o)):Vi(this.node(),r)}function Vi(r,e){return r.style.getPropertyValue(e)||ta(r).getComputedStyle(r,null).getPropertyValue(e)}function Tk(r){return function(){delete this[r]}}function _k(r,e){return function(){this[r]=e}}function Bk(r,e){return function(){var o=e.apply(this,arguments);if(o==null)delete this[r];else this[r]=o}}function jh(r,e){return arguments.length>1?this.each((e==null?Tk:typeof e==="function"?Bk:_k)(r,e)):this.node()[r]}function kp(r){return r.trim().split(/^|\s+/)}function Gh(r){return r.classList||new wp(r)}function wp(r){this._node=r,this._names=kp(r.getAttribute("class")||"")}wp.prototype={add:function(r){var e=this._names.indexOf(r);if(e<0)this._names.push(r),this._node.setAttribute("class",this._names.join(" "))},remove:function(r){var e=this._names.indexOf(r);if(e>=0)this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" "))},contains:function(r){return this._names.indexOf(r)>=0}};function Sp(r,e){var o=Gh(r),a=-1,s=e.length;while(++a<s)o.add(e[a])}function Tp(r,e){var o=Gh(r),a=-1,s=e.length;while(++a<s)o.remove(e[a])}function vk(r){return function(){Sp(this,r)}}function Lk(r){return function(){Tp(this,r)}}function Fk(r,e){return function(){(e.apply(this,arguments)?Sp:Tp)(this,r)}}function Xh(r,e){var o=kp(r+"");if(arguments.length<2){var a=Gh(this.node()),s=-1,n=o.length;while(++s<n)if(!a.contains(o[s]))return!1;return!0}return this.each((typeof e==="function"?Fk:e?vk:Lk)(o,e))}function Ak(){this.textContent=""}function Mk(r){return function(){this.textContent=r}}function Ek(r){return function(){var e=r.apply(this,arguments);this.textContent=e==null?"":e}}function Vh(r){return arguments.length?this.each(r==null?Ak:(typeof r==="function"?Ek:Mk)(r)):this.node().textContent}function Ok(){this.innerHTML=""}function Ik(r){return function(){this.innerHTML=r}}function $k(r){return function(){var e=r.apply(this,arguments);this.innerHTML=e==null?"":e}}function Kh(r){return arguments.length?this.each(r==null?Ok:(typeof r==="function"?$k:Ik)(r)):this.node().innerHTML}function Dk(){if(this.nextSibling)this.parentNode.appendChild(this)}function Zh(){return this.each(Dk)}function Pk(){if(this.previousSibling)this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Qh(){return this.each(Pk)}function Jh(r){var e=typeof r==="function"?r:Ps(r);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}function Rk(){return null}function ic(r,e){var o=typeof r==="function"?r:Ps(r),a=e==null?Rk:typeof e==="function"?e:Xi(e);return this.select(function(){return this.insertBefore(o.apply(this,arguments),a.apply(this,arguments)||null)})}function qk(){var r=this.parentNode;if(r)r.removeChild(this)}function oc(){return this.each(qk)}function Nk(){var r=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(r,this.nextSibling):r}function Wk(){var r=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(r,this.nextSibling):r}function sc(r){return this.select(r?Wk:Nk)}function ac(r){return arguments.length?this.property("__data__",r):this.node().__data__}function zk(r){return function(e){r.call(this,e,this.__data__)}}function Hk(r){return r.trim().split(/^|\s+/).map(function(e){var o="",a=e.indexOf(".");if(a>=0)o=e.slice(a+1),e=e.slice(0,a);return{type:e,name:o}})}function Yk(r){return function(){var e=this.__on;if(!e)return;for(var o=0,a=-1,s=e.length,n;o<s;++o)if(n=e[o],(!r.type||n.type===r.type)&&n.name===r.name)this.removeEventListener(n.type,n.listener,n.options);else e[++a]=n;if(++a)e.length=a;else delete this.__on}}function Uk(r,e,o){return function(){var a=this.__on,s,n=zk(e);if(a){for(var c=0,l=a.length;c<l;++c)if((s=a[c]).type===r.type&&s.name===r.name){this.removeEventListener(s.type,s.listener,s.options),this.addEventListener(s.type,s.listener=n,s.options=o),s.value=e;return}}if(this.addEventListener(r.type,n,o),s={type:r.type,name:r.name,value:e,listener:n,options:o},!a)this.__on=[s];else a.push(s)}}function lc(r,e,o){var a=Hk(r+""),s,n=a.length,c;if(arguments.length<2){var l=this.node().__on;if(l){for(var p=0,m=l.length,u;p<m;++p)for(s=0,u=l[p];s<n;++s)if((c=a[s]).type===u.type&&c.name===u.name)return u.value}return}l=e?Uk:Yk;for(s=0;s<n;++s)this.each(l(a[s],e,o));return this}function _p(r,e,o){var a=ta(r),s=a.CustomEvent;if(typeof s==="function")s=new s(e,o);else if(s=a.document.createEvent("Event"),o)s.initEvent(e,o.bubbles,o.cancelable),s.detail=o.detail;else s.initEvent(e,!1,!1);r.dispatchEvent(s)}function jk(r,e){return function(){return _p(this,r,e)}}function Gk(r,e){return function(){return _p(this,r,e.apply(this,arguments))}}function hc(r,e){return this.each((typeof e==="function"?Gk:jk)(r,e))}function*cc(){for(var r=this._groups,e=0,o=r.length;e<o;++e)for(var a=r[e],s=0,n=a.length,c;s<n;++s)if(c=a[s])yield c}var uc=[null];function Ee(r,e){this._groups=r,this._parents=e}function Bp(){return new Ee([[document.documentElement]],uc)}function Xk(){return this}Ee.prototype=Bp.prototype={constructor:Ee,select:Th,selectAll:Bh,selectChild:vh,selectChildren:Lh,filter:Fh,data:Eh,enter:Ah,exit:Oh,join:Ih,merge:$h,selection:Xk,order:Dh,sort:Ph,call:Rh,nodes:qh,node:Nh,size:Wh,empty:zh,each:Hh,attr:Yh,style:Uh,property:jh,classed:Xh,text:Vh,html:Kh,raise:Zh,lower:Qh,append:Jh,insert:ic,remove:oc,clone:sc,datum:ac,on:lc,dispatch:hc,[Symbol.iterator]:cc};var wi=Bp;function g(r){return typeof r==="string"?new Ee([[document.querySelector(r)]],[document.documentElement]):new Ee([[r]],uc)}function zr(r,e,o){r.prototype=e.prototype=o,o.constructor=r}function Ya(r,e){var o=Object.create(r.prototype);for(var a in e)o[a]=e[a];return o}function Hr(){}var ea=0.7,Yn=1/ea,is="\\s*([+-]?\\d+)\\s*",ha="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",oi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Vk=/^#([0-9a-f]{3,8})$/,Kk=new RegExp(`^rgb\\(${is},${is},${is}\\)$`),Zk=new RegExp(`^rgb\\(${oi},${oi},${oi}\\)$`),Qk=new RegExp(`^rgba\\(${is},${is},${is},${ha}\\)$`),Jk=new RegExp(`^rgba\\(${oi},${oi},${oi},${ha}\\)$`),t1=new RegExp(`^hsl\\(${ha},${oi},${oi}\\)$`),e1=new RegExp(`^hsla\\(${ha},${oi},${oi},${ha}\\)$`),vp={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};zr(Hr,$n,{copy(r){return Object.assign(new this.constructor,this,r)},displayable(){return this.rgb().displayable()},hex:Lp,formatHex:Lp,formatHex8:r1,formatHsl:i1,formatRgb:Fp,toString:Fp});function Lp(){return this.rgb().formatHex()}function r1(){return this.rgb().formatHex8()}function i1(){return $p(this).formatHsl()}function Fp(){return this.rgb().formatRgb()}function $n(r){var e,o;return r=(r+"").trim().toLowerCase(),(e=Vk.exec(r))?(o=e[1].length,e=parseInt(e[1],16),o===6?Ap(e):o===3?new Et(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):o===8?zn(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):o===4?zn(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=Kk.exec(r))?new Et(e[1],e[2],e[3],1):(e=Zk.exec(r))?new Et(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=Qk.exec(r))?zn(e[1],e[2],e[3],e[4]):(e=Jk.exec(r))?zn(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=t1.exec(r))?Op(e[1],e[2]/100,e[3]/100,1):(e=e1.exec(r))?Op(e[1],e[2]/100,e[3]/100,e[4]):vp.hasOwnProperty(r)?Ap(vp[r]):r==="transparent"?new Et(NaN,NaN,NaN,0):null}function Ap(r){return new Et(r>>16&255,r>>8&255,r&255,1)}function zn(r,e,o,a){if(a<=0)r=e=o=NaN;return new Et(r,e,o,a)}function Gs(r){if(!(r instanceof Hr))r=$n(r);if(!r)return new Et;return r=r.rgb(),new Et(r.r,r.g,r.b,r.opacity)}function os(r,e,o,a){return arguments.length===1?Gs(r):new Et(r,e,o,a==null?1:a)}function Et(r,e,o,a){this.r=+r,this.g=+e,this.b=+o,this.opacity=+a}zr(Et,os,Ya(Hr,{brighter(r){return r=r==null?Yn:Math.pow(Yn,r),new Et(this.r*r,this.g*r,this.b*r,this.opacity)},darker(r){return r=r==null?ea:Math.pow(ea,r),new Et(this.r*r,this.g*r,this.b*r,this.opacity)},rgb(){return this},clamp(){return new Et(io(this.r),io(this.g),io(this.b),Un(this.opacity))},displayable(){return-0.5<=this.r&&this.r<255.5&&(-0.5<=this.g&&this.g<255.5)&&(-0.5<=this.b&&this.b<255.5)&&(0<=this.opacity&&this.opacity<=1)},hex:Mp,formatHex:Mp,formatHex8:o1,formatRgb:Ep,toString:Ep}));function Mp(){return`#${ro(this.r)}${ro(this.g)}${ro(this.b)}`}function o1(){return`#${ro(this.r)}${ro(this.g)}${ro(this.b)}${ro((isNaN(this.opacity)?1:this.opacity)*255)}`}function Ep(){let r=Un(this.opacity);return`${r===1?"rgb(":"rgba("}${io(this.r)}, ${io(this.g)}, ${io(this.b)}${r===1?")":`, ${r})`}`}function Un(r){return isNaN(r)?1:Math.max(0,Math.min(1,r))}function io(r){return Math.max(0,Math.min(255,Math.round(r)||0))}function ro(r){return r=io(r),(r<16?"0":"")+r.toString(16)}function Op(r,e,o,a){if(a<=0)r=e=o=NaN;else if(o<=0||o>=1)r=e=NaN;else if(e<=0)r=NaN;return new Nr(r,e,o,a)}function $p(r){if(r instanceof Nr)return new Nr(r.h,r.s,r.l,r.opacity);if(!(r instanceof Hr))r=$n(r);if(!r)return new Nr;if(r instanceof Nr)return r;r=r.rgb();var e=r.r/255,o=r.g/255,a=r.b/255,s=Math.min(e,o,a),n=Math.max(e,o,a),c=NaN,l=n-s,p=(n+s)/2;if(l){if(e===n)c=(o-a)/l+(o<a)*6;else if(o===n)c=(a-e)/l+2;else c=(e-o)/l+4;l/=p<0.5?n+s:2-n-s,c*=60}else l=p>0&&p<1?0:c;return new Nr(c,l,p,r.opacity)}function Dp(r,e,o,a){return arguments.length===1?$p(r):new Nr(r,e,o,a==null?1:a)}function Nr(r,e,o,a){this.h=+r,this.s=+e,this.l=+o,this.opacity=+a}zr(Nr,Dp,Ya(Hr,{brighter(r){return r=r==null?Yn:Math.pow(Yn,r),new Nr(this.h,this.s,this.l*r,this.opacity)},darker(r){return r=r==null?ea:Math.pow(ea,r),new Nr(this.h,this.s,this.l*r,this.opacity)},rgb(){var r=this.h%360+(this.h<0)*360,e=isNaN(r)||isNaN(this.s)?0:this.s,o=this.l,a=o+(o<0.5?o:1-o)*e,s=2*o-a;return new Et(fc(r>=240?r-240:r+120,s,a),fc(r,s,a),fc(r<120?r+240:r-120,s,a),this.opacity)},clamp(){return new Nr(Ip(this.h),Hn(this.s),Hn(this.l),Un(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&(0<=this.l&&this.l<=1)&&(0<=this.opacity&&this.opacity<=1)},formatHsl(){let r=Un(this.opacity);return`${r===1?"hsl(":"hsla("}${Ip(this.h)}, ${Hn(this.s)*100}%, ${Hn(this.l)*100}%${r===1?")":`, ${r})`}`}}));function Ip(r){return r=(r||0)%360,r<0?r+360:r}function Hn(r){return Math.max(0,Math.min(1,r||0))}function fc(r,e,o){return(r<60?e+(o-e)*r/60:r<180?o:r<240?e+(o-e)*(240-r)/60:e)*255}function dc(r,e,o,a,s){var n=r*r,c=n*r;return((1-3*r+3*n-c)*e+(4-6*n+3*c)*o+(1+3*r+3*n-3*c)*a+c*s)/6}function pc(r){var e=r.length-1;return function(o){var a=o<=0?o=0:o>=1?(o=1,e-1):Math.floor(o*e),s=r[a],n=r[a+1],c=a>0?r[a-1]:2*s-n,l=a<e-1?r[a+2]:2*n-s;return dc((o-a/e)*e,c,s,n,l)}}function mc(r){var e=r.length;return function(o){var a=Math.floor(((o%=1)<0?++o:o)*e),s=r[(a+e-1)%e],n=r[a%e],c=r[(a+1)%e],l=r[(a+2)%e];return dc((o-a/e)*e,s,n,c,l)}}var Xa=(r)=>()=>r;function Pp(r,e){return function(o){return r+o*e}}function s1(r,e,o){return r=Math.pow(r,o),e=Math.pow(e,o)-r,o=1/o,function(a){return Math.pow(r+a*e,o)}}function kc(r,e){var o=e-r;return o?Pp(r,o>180||o<-180?o-360*Math.round(o/360):o):Xa(isNaN(r)?e:r)}function Rp(r){return(r=+r)===1?hr:function(e,o){return o-e?s1(e,o,r):Xa(isNaN(e)?o:e)}}function hr(r,e){var o=e-r;return o?Pp(r,o):Xa(isNaN(r)?e:r)}var ra=function r(e){var o=Rp(e);function a(s,n){var c=o((s=os(s)).r,(n=os(n)).r),l=o(s.g,n.g),p=o(s.b,n.b),m=hr(s.opacity,n.opacity);return function(u){return s.r=c(u),s.g=l(u),s.b=p(u),s.opacity=m(u),s+""}}return a.gamma=r,a}(1);function qp(r){return function(e){var o=e.length,a=Array(o),s=Array(o),n=Array(o),c,l;for(c=0;c<o;++c)l=os(e[c]),a[c]=l.r||0,s[c]=l.g||0,n[c]=l.b||0;return a=r(a),s=r(s),n=r(n),l.opacity=1,function(p){return l.r=a(p),l.g=s(p),l.b=n(p),l+""}}}var a1=qp(pc),n1=qp(mc);function bt(r,e){return r=+r,e=+e,function(o){return r*(1-o)+e*o}}var Fc=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Bc=new RegExp(Fc.source,"g");function l1(r){return function(){return r}}function h1(r){return function(e){return r(e)+""}}function Ka(r,e){var o=Fc.lastIndex=Bc.lastIndex=0,a,s,n,c=-1,l=[],p=[];r=r+"",e=e+"";while((a=Fc.exec(r))&&(s=Bc.exec(e))){if((n=s.index)>o)if(n=e.slice(o,n),l[c])l[c]+=n;else l[++c]=n;if((a=a[0])===(s=s[0]))if(l[c])l[c]+=s;else l[++c]=s;else l[++c]=null,p.push({i:c,x:bt(a,s)});o=Bc.lastIndex}if(o<e.length)if(n=e.slice(o),l[c])l[c]+=n;else l[++c]=n;return l.length<2?p[0]?h1(p[0].x):l1(e):(e=p.length,function(m){for(var u=0,y;u<e;++u)l[(y=p[u]).i]=y.x(m);return l.join("")})}var Np=180/Math.PI,jn={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Gn(r,e,o,a,s,n){var c,l,p;if(c=Math.sqrt(r*r+e*e))r/=c,e/=c;if(p=r*o+e*a)o-=r*p,a-=e*p;if(l=Math.sqrt(o*o+a*a))o/=l,a/=l,p/=l;if(r*a<e*o)r=-r,e=-e,p=-p,c=-c;return{translateX:s,translateY:n,rotate:Math.atan2(e,r)*Np,skewX:Math.atan(p)*Np,scaleX:c,scaleY:l}}var Xn;function Wp(r){let e=new(typeof DOMMatrix==="function"?DOMMatrix:WebKitCSSMatrix)(r+"");return e.isIdentity?jn:Gn(e.a,e.b,e.c,e.d,e.e,e.f)}function zp(r){if(r==null)return jn;if(!Xn)Xn=document.createElementNS("http://www.w3.org/2000/svg","g");if(Xn.setAttribute("transform",r),!(r=Xn.transform.baseVal.consolidate()))return jn;return r=r.matrix,Gn(r.a,r.b,r.c,r.d,r.e,r.f)}function Hp(r,e,o,a){function s(m){return m.length?m.pop()+" ":""}function n(m,u,y,x,k,w){if(m!==y||u!==x){var _=k.push("translate(",null,e,null,o);w.push({i:_-4,x:bt(m,y)},{i:_-2,x:bt(u,x)})}else if(y||x)k.push("translate("+y+e+x+o)}function c(m,u,y,x){if(m!==u){if(m-u>180)u+=360;else if(u-m>180)m+=360;x.push({i:y.push(s(y)+"rotate(",null,a)-2,x:bt(m,u)})}else if(u)y.push(s(y)+"rotate("+u+a)}function l(m,u,y,x){if(m!==u)x.push({i:y.push(s(y)+"skewX(",null,a)-2,x:bt(m,u)});else if(u)y.push(s(y)+"skewX("+u+a)}function p(m,u,y,x,k,w){if(m!==y||u!==x){var _=k.push(s(k)+"scale(",null,",",null,")");w.push({i:_-4,x:bt(m,y)},{i:_-2,x:bt(u,x)})}else if(y!==1||x!==1)k.push(s(k)+"scale("+y+","+x+")")}return function(m,u){var y=[],x=[];return m=r(m),u=r(u),n(m.translateX,m.translateY,u.translateX,u.translateY,y,x),c(m.rotate,u.rotate,y,x),l(m.skewX,u.skewX,y,x),p(m.scaleX,m.scaleY,u.scaleX,u.scaleY,y,x),m=u=null,function(k){var w=-1,_=x.length,M;while(++w<_)y[(M=x[w]).i]=M.x(k);return y.join("")}}}var Oc=Hp(Wp,"px, ","px)","deg)"),Ic=Hp(zp,", ",")",")");var ss=0,ga=0,fa=0,Up=1000,Vn,ma,Kn=0,oo=0,Zn=0,ya=typeof performance==="object"&&performance.now?performance:Date,jp=typeof window==="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(r){setTimeout(r,17)};function Ca(){return oo||(jp(c1),oo=ya.now()+Zn)}function c1(){oo=0}function xa(){this._call=this._time=this._next=null}xa.prototype=Qn.prototype={constructor:xa,restart:function(r,e,o){if(typeof r!=="function")throw TypeError("callback is not a function");if(o=(o==null?Ca():+o)+(e==null?0:+e),!this._next&&ma!==this){if(ma)ma._next=this;else Vn=this;ma=this}this._call=r,this._time=o,$c()},stop:function(){if(this._call)this._call=null,this._time=1/0,$c()}};function Qn(r,e,o){var a=new xa;return a.restart(r,e,o),a}function Gp(){Ca(),++ss;var r=Vn,e;while(r){if((e=oo-r._time)>=0)r._call.call(void 0,e);r=r._next}--ss}function Yp(){oo=(Kn=ya.now())+Zn,ss=ga=0;try{Gp()}finally{ss=0,f1(),oo=0}}function u1(){var r=ya.now(),e=r-Kn;if(e>Up)Zn-=e,Kn=r}function f1(){var r,e=Vn,o,a=1/0;while(e)if(e._call){if(a>e._time)a=e._time;r=e,e=e._next}else o=e._next,e._next=null,e=r?r._next=o:Vn=o;ma=r,$c(a)}function $c(r){if(ss)return;if(ga)ga=clearTimeout(ga);var e=r-oo;if(e>24){if(r<1/0)ga=setTimeout(Yp,r-ya.now()-Zn);if(fa)fa=clearInterval(fa)}else{if(!fa)Kn=ya.now(),fa=setInterval(u1,Up);ss=1,jp(Yp)}}function ba(r,e,o){var a=new xa;return e=e==null?0:+e,a.restart((s)=>{a.stop(),r(s+e)},e,o),a}var d1=wh("start","end","cancel","interrupt"),p1=[],Kp=0,Xp=1,tl=2,Jn=3,Vp=4,el=5,ka=6;function Si(r,e,o,a,s,n){var c=r.__transition;if(!c)r.__transition={};else if(o in c)return;g1(r,o,{name:e,index:a,group:s,on:d1,tween:p1,time:n.time,delay:n.delay,duration:n.duration,ease:n.ease,timer:null,state:Kp})}function wa(r,e){var o=Ge(r,e);if(o.state>Kp)throw Error("too late; already scheduled");return o}function or(r,e){var o=Ge(r,e);if(o.state>Jn)throw Error("too late; already running");return o}function Ge(r,e){var o=r.__transition;if(!o||!(o=o[e]))throw Error("transition not found");return o}function g1(r,e,o){var a=r.__transition,s;a[e]=o,o.timer=Qn(n,0,o.time);function n(m){if(o.state=Xp,o.timer.restart(c,o.delay,o.time),o.delay<=m)c(m-o.delay)}function c(m){var u,y,x,k;if(o.state!==Xp)return p();for(u in a){if(k=a[u],k.name!==o.name)continue;if(k.state===Jn)return ba(c);if(k.state===Vp)k.state=ka,k.timer.stop(),k.on.call("interrupt",r,r.__data__,k.index,k.group),delete a[u];else if(+u<e)k.state=ka,k.timer.stop(),k.on.call("cancel",r,r.__data__,k.index,k.group),delete a[u]}if(ba(function(){if(o.state===Jn)o.state=Vp,o.timer.restart(l,o.delay,o.time),l(m)}),o.state=tl,o.on.call("start",r,r.__data__,o.index,o.group),o.state!==tl)return;o.state=Jn,s=Array(x=o.tween.length);for(u=0,y=-1;u<x;++u)if(k=o.tween[u].value.call(r,r.__data__,o.index,o.group))s[++y]=k;s.length=y+1}function l(m){var u=m<o.duration?o.ease.call(null,m/o.duration):(o.timer.restart(p),o.state=el,1),y=-1,x=s.length;while(++y<x)s[y].call(r,u);if(o.state===el)o.on.call("end",r,r.__data__,o.index,o.group),p()}function p(){o.state=ka,o.timer.stop(),delete a[e];for(var m in a)return;delete r.__transition}}function Sa(r,e){var o=r.__transition,a,s,n=!0,c;if(!o)return;e=e==null?null:e+"";for(c in o){if((a=o[c]).name!==e){n=!1;continue}s=a.state>tl&&a.state<el,a.state=ka,a.timer.stop(),a.on.call(s?"interrupt":"cancel",r,r.__data__,a.index,a.group),delete o[c]}if(n)delete r.__transition}function Dc(r){return this.each(function(){Sa(this,r)})}function m1(r,e){var o,a;return function(){var s=or(this,r),n=s.tween;if(n!==o){a=o=n;for(var c=0,l=a.length;c<l;++c)if(a[c].name===e){a=a.slice(),a.splice(c,1);break}}s.tween=a}}function y1(r,e,o){var a,s;if(typeof o!=="function")throw Error();return function(){var n=or(this,r),c=n.tween;if(c!==a){s=(a=c).slice();for(var l={name:e,value:o},p=0,m=s.length;p<m;++p)if(s[p].name===e){s[p]=l;break}if(p===m)s.push(l)}n.tween=s}}function Rc(r,e){var o=this._id;if(r+="",arguments.length<2){var a=Ge(this.node(),o).tween;for(var s=0,n=a.length,c;s<n;++s)if((c=a[s]).name===r)return c.value;return null}return this.each((e==null?m1:y1)(o,r,e))}function as(r,e,o){var a=r._id;return r.each(function(){var s=or(this,a);(s.value||(s.value={}))[e]=o.apply(this,arguments)}),function(s){return Ge(s,a).value[e]}}function Ta(r,e){var o;return(typeof e==="number"?bt:e instanceof $n?ra:(o=$n(e))?(e=o,ra):Ka)(r,e)}function x1(r){return function(){this.removeAttribute(r)}}function C1(r){return function(){this.removeAttributeNS(r.space,r.local)}}function b1(r,e,o){var a,s=o+"",n;return function(){var c=this.getAttribute(r);return c===s?null:c===a?n:n=e(a=c,o)}}function k1(r,e,o){var a,s=o+"",n;return function(){var c=this.getAttributeNS(r.space,r.local);return c===s?null:c===a?n:n=e(a=c,o)}}function w1(r,e,o){var a,s,n;return function(){var c,l=o(this),p;if(l==null)return void this.removeAttribute(r);return c=this.getAttribute(r),p=l+"",c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function S1(r,e,o){var a,s,n;return function(){var c,l=o(this),p;if(l==null)return void this.removeAttributeNS(r.space,r.local);return c=this.getAttributeNS(r.space,r.local),p=l+"",c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function qc(r,e){var o=ii(r),a=o==="transform"?Ic:Ta;return this.attrTween(r,typeof e==="function"?(o.local?S1:w1)(o,a,as(this,"attr."+r,e)):e==null?(o.local?C1:x1)(o):(o.local?k1:b1)(o,a,e))}function T1(r,e){return function(o){this.setAttribute(r,e.call(this,o))}}function _1(r,e){return function(o){this.setAttributeNS(r.space,r.local,e.call(this,o))}}function B1(r,e){var o,a;function s(){var n=e.apply(this,arguments);if(n!==a)o=(a=n)&&_1(r,n);return o}return s._value=e,s}function v1(r,e){var o,a;function s(){var n=e.apply(this,arguments);if(n!==a)o=(a=n)&&T1(r,n);return o}return s._value=e,s}function Wc(r,e){var o="attr."+r;if(arguments.length<2)return(o=this.tween(o))&&o._value;if(e==null)return this.tween(o,null);if(typeof e!=="function")throw Error();var a=ii(r);return this.tween(o,(a.local?B1:v1)(a,e))}function L1(r,e){return function(){wa(this,r).delay=+e.apply(this,arguments)}}function F1(r,e){return e=+e,function(){wa(this,r).delay=e}}function zc(r){var e=this._id;return arguments.length?this.each((typeof r==="function"?L1:F1)(e,r)):Ge(this.node(),e).delay}function A1(r,e){return function(){or(this,r).duration=+e.apply(this,arguments)}}function M1(r,e){return e=+e,function(){or(this,r).duration=e}}function Hc(r){var e=this._id;return arguments.length?this.each((typeof r==="function"?A1:M1)(e,r)):Ge(this.node(),e).duration}function E1(r,e){if(typeof e!=="function")throw Error();return function(){or(this,r).ease=e}}function Yc(r){var e=this._id;return arguments.length?this.each(E1(e,r)):Ge(this.node(),e).ease}function O1(r,e){return function(){var o=e.apply(this,arguments);if(typeof o!=="function")throw Error();or(this,r).ease=o}}function Uc(r){if(typeof r!=="function")throw Error();return this.each(O1(this._id,r))}function jc(r){if(typeof r!=="function")r=rs(r);for(var e=this._groups,o=e.length,a=Array(o),s=0;s<o;++s)for(var n=e[s],c=n.length,l=a[s]=[],p,m=0;m<c;++m)if((p=n[m])&&r.call(p,p.__data__,m,n))l.push(p);return new yr(a,this._parents,this._name,this._id)}function Gc(r){if(r._id!==this._id)throw Error();for(var e=this._groups,o=r._groups,a=e.length,s=o.length,n=Math.min(a,s),c=Array(a),l=0;l<n;++l)for(var p=e[l],m=o[l],u=p.length,y=c[l]=Array(u),x,k=0;k<u;++k)if(x=p[k]||m[k])y[k]=x;for(;l<a;++l)c[l]=e[l];return new yr(c,this._parents,this._name,this._id)}function I1(r){return(r+"").trim().split(/^|\s+/).every(function(e){var o=e.indexOf(".");if(o>=0)e=e.slice(0,o);return!e||e==="start"})}function $1(r,e,o){var a,s,n=I1(e)?wa:or;return function(){var c=n(this,r),l=c.on;if(l!==a)(s=(a=l).copy()).on(e,o);c.on=s}}function Xc(r,e){var o=this._id;return arguments.length<2?Ge(this.node(),o).on.on(r):this.each($1(o,r,e))}function D1(r){return function(){var e=this.parentNode;for(var o in this.__transition)if(+o!==r)return;if(e)e.removeChild(this)}}function Vc(){return this.on("end.remove",D1(this._id))}function Kc(r){var e=this._name,o=this._id;if(typeof r!=="function")r=Xi(r);for(var a=this._groups,s=a.length,n=Array(s),c=0;c<s;++c)for(var l=a[c],p=l.length,m=n[c]=Array(p),u,y,x=0;x<p;++x)if((u=l[x])&&(y=r.call(u,u.__data__,x,l))){if("__data__"in u)y.__data__=u.__data__;m[x]=y,Si(m[x],e,o,x,m,Ge(u,o))}return new yr(n,this._parents,e,o)}function Zc(r){var e=this._name,o=this._id;if(typeof r!=="function")r=es(r);for(var a=this._groups,s=a.length,n=[],c=[],l=0;l<s;++l)for(var p=a[l],m=p.length,u,y=0;y<m;++y)if(u=p[y]){for(var x=r.call(u,u.__data__,y,p),k,w=Ge(u,o),_=0,M=x.length;_<M;++_)if(k=x[_])Si(k,e,o,_,x,w);n.push(x),c.push(u)}return new yr(n,c,e,o)}var P1=wi.prototype.constructor;function Qc(){return new P1(this._groups,this._parents)}function R1(r,e){var o,a,s;return function(){var n=Vi(this,r),c=(this.style.removeProperty(r),Vi(this,r));return n===c?null:n===o&&c===a?s:s=e(o=n,a=c)}}function Zp(r){return function(){this.style.removeProperty(r)}}function q1(r,e,o){var a,s=o+"",n;return function(){var c=Vi(this,r);return c===s?null:c===a?n:n=e(a=c,o)}}function N1(r,e,o){var a,s,n;return function(){var c=Vi(this,r),l=o(this),p=l+"";if(l==null)p=l=(this.style.removeProperty(r),Vi(this,r));return c===p?null:c===a&&p===s?n:(s=p,n=e(a=c,l))}}function W1(r,e){var o,a,s,n="style."+e,c="end."+n,l;return function(){var p=or(this,r),m=p.on,u=p.value[n]==null?l||(l=Zp(e)):void 0;if(m!==o||s!==u)(a=(o=m).copy()).on(c,s=u);p.on=a}}function Jc(r,e,o){var a=(r+="")==="transform"?Oc:Ta;return e==null?this.styleTween(r,R1(r,a)).on("end.style."+r,Zp(r)):typeof e==="function"?this.styleTween(r,N1(r,a,as(this,"style."+r,e))).each(W1(this._id,r)):this.styleTween(r,q1(r,a,e),o).on("end.style."+r,null)}function z1(r,e,o){return function(a){this.style.setProperty(r,e.call(this,a),o)}}function H1(r,e,o){var a,s;function n(){var c=e.apply(this,arguments);if(c!==s)a=(s=c)&&z1(r,c,o);return a}return n._value=e,n}function tu(r,e,o){var a="style."+(r+="");if(arguments.length<2)return(a=this.tween(a))&&a._value;if(e==null)return this.tween(a,null);if(typeof e!=="function")throw Error();return this.tween(a,H1(r,e,o==null?"":o))}function Y1(r){return function(){this.textContent=r}}function U1(r){return function(){var e=r(this);this.textContent=e==null?"":e}}function eu(r){return this.tween("text",typeof r==="function"?U1(as(this,"text",r)):Y1(r==null?"":r+""))}function j1(r){return function(e){this.textContent=r.call(this,e)}}function G1(r){var e,o;function a(){var s=r.apply(this,arguments);if(s!==o)e=(o=s)&&j1(s);return e}return a._value=r,a}function ru(r){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(r==null)return this.tween(e,null);if(typeof r!=="function")throw Error();return this.tween(e,G1(r))}function iu(){var r=this._name,e=this._id,o=rl();for(var a=this._groups,s=a.length,n=0;n<s;++n)for(var c=a[n],l=c.length,p,m=0;m<l;++m)if(p=c[m]){var u=Ge(p,e);Si(p,r,o,m,c,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new yr(a,this._parents,r,o)}function ou(){var r,e,o=this,a=o._id,s=o.size();return new Promise(function(n,c){var l={value:c},p={value:function(){if(--s===0)n()}};if(o.each(function(){var m=or(this,a),u=m.on;if(u!==r)e=(r=u).copy(),e._.cancel.push(l),e._.interrupt.push(l),e._.end.push(p);m.on=e}),s===0)n()})}var X1=0;function yr(r,e,o,a){this._groups=r,this._parents=e,this._name=o,this._id=a}function Qp(r){return wi().transition(r)}function rl(){return++X1}var _i=wi.prototype;yr.prototype=Qp.prototype={constructor:yr,select:Kc,selectAll:Zc,selectChild:_i.selectChild,selectChildren:_i.selectChildren,filter:jc,merge:Gc,selection:Qc,transition:iu,call:_i.call,nodes:_i.nodes,node:_i.node,size:_i.size,empty:_i.empty,each:_i.each,on:Xc,attr:qc,attrTween:Wc,style:Jc,styleTween:tu,text:eu,textTween:ru,remove:Vc,tween:Rc,delay:zc,duration:Hc,ease:Yc,easeVarying:Uc,end:ou,[Symbol.iterator]:_i[Symbol.iterator]};function il(r){return((r*=2)<=1?r*r*r:(r-=2)*r*r+2)/2}var V1={time:null,delay:0,duration:250,ease:il};function K1(r,e){var o;while(!(o=r.__transition)||!(o=o[e]))if(!(r=r.parentNode))throw Error(`transition ${e} not found`);return o}function su(r){var e,o;if(r instanceof yr)e=r._id,r=r._name;else e=rl(),(o=V1).time=Ca(),r=r==null?null:r+"";for(var a=this._groups,s=a.length,n=0;n<s;++n)for(var c=a[n],l=c.length,p,m=0;m<l;++m)if(p=c[m])Si(p,r,e,m,c,o||K1(p,e));return new yr(a,this._parents,r,e)}wi.prototype.interrupt=Dc;wi.prototype.transition=su;var{abs:tE,max:eE,min:rE}=Math;function Jp(r){return[+r[0],+r[1]]}function Z1(r){return[Jp(r[0]),Jp(r[1])]}var iE={name:"x",handles:["w","e"].map(au),input:function(r,e){return r==null?null:[[+r[0],e[0][1]],[+r[1],e[1][1]]]},output:function(r){return r&&[r[0][0],r[1][0]]}},oE={name:"y",handles:["n","s"].map(au),input:function(r,e){return r==null?null:[[e[0][0],+r[0]],[e[1][0],+r[1]]]},output:function(r){return r&&[r[0][1],r[1][1]]}},sE={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(au),input:function(r){return r==null?null:Z1(r)},output:function(r){return r}};function au(r){return{type:r}}var nu=Math.PI,lu=2*nu;var Q1=lu-0.000001;function tg(r){this._+=r[0];for(let e=1,o=r.length;e<o;++e)this._+=arguments[e]+r[e]}function J1(r){let e=Math.floor(r);if(!(e>=0))throw Error(`invalid digits: ${r}`);if(e>15)return tg;let o=10**e;return function(a){this._+=a[0];for(let s=1,n=a.length;s<n;++s)this._+=Math.round(arguments[s]*o)/o+a[s]}}class ns{constructor(r){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=r==null?tg:J1(r)}moveTo(r,e){this._append`M${this._x0=this._x1=+r},${this._y0=this._y1=+e}`}closePath(){if(this._x1!==null)this._x1=this._x0,this._y1=this._y0,this._append`Z`}lineTo(r,e){this._append`L${this._x1=+r},${this._y1=+e}`}quadraticCurveTo(r,e,o,a){this._append`Q${+r},${+e},${this._x1=+o},${this._y1=+a}`}bezierCurveTo(r,e,o,a,s,n){this._append`C${+r},${+e},${+o},${+a},${this._x1=+s},${this._y1=+n}`}arcTo(r,e,o,a,s){if(r=+r,e=+e,o=+o,a=+a,s=+s,s<0)throw Error(`negative radius: ${s}`);let n=this._x1,c=this._y1,l=o-r,p=a-e,m=n-r,u=c-e,y=m*m+u*u;if(this._x1===null)this._append`M${this._x1=r},${this._y1=e}`;else if(!(y>0.000001));else if(!(Math.abs(u*l-p*m)>0.000001)||!s)this._append`L${this._x1=r},${this._y1=e}`;else{let x=o-n,k=a-c,w=l*l+p*p,_=x*x+k*k,M=Math.sqrt(w),W=Math.sqrt(y),U=s*Math.tan((nu-Math.acos((w+y-_)/(2*M*W)))/2),V=U/W,Z=U/M;if(Math.abs(V-1)>0.000001)this._append`L${r+V*m},${e+V*u}`;this._append`A${s},${s},0,0,${+(u*x>m*k)},${this._x1=r+Z*l},${this._y1=e+Z*p}`}}arc(r,e,o,a,s,n){if(r=+r,e=+e,o=+o,n=!!n,o<0)throw Error(`negative radius: ${o}`);let c=o*Math.cos(a),l=o*Math.sin(a),p=r+c,m=e+l,u=1^n,y=n?a-s:s-a;if(this._x1===null)this._append`M${p},${m}`;else if(Math.abs(this._x1-p)>0.000001||Math.abs(this._y1-m)>0.000001)this._append`L${p},${m}`;if(!o)return;if(y<0)y=y%lu+lu;if(y>Q1)this._append`A${o},${o},0,1,${u},${r-c},${e-l}A${o},${o},0,1,${u},${this._x1=p},${this._y1=m}`;else if(y>0.000001)this._append`A${o},${o},0,${+(y>=nu)},${u},${this._x1=r+o*Math.cos(s)},${this._y1=e+o*Math.sin(s)}`}rect(r,e,o,a){this._append`M${this._x0=this._x1=+r},${this._y0=this._y1=+e}h${o=+o}v${+a}h${-o}Z`}toString(){return this._}}function eg(){return new ns}eg.prototype=ns.prototype;function we(r){return function(){return r}}var{abs:Ws,atan2:Lt,cos:Ur,max:Cc,min:So,sin:Bn,sqrt:aa}=Math,xt=0.000000000001,Za=Math.PI,Ni=Za/2,ia=2*Za;function Sc(r){return r>1?0:r<-1?Za:Math.acos(r)}function Ys(r){return r>=1?Ni:r<=-1?-Ni:Math.asin(r)}function oa(r){let e=3;return r.digits=function(o){if(!arguments.length)return e;if(o==null)e=null;else{let a=Math.floor(o);if(!(a>=0))throw RangeError(`invalid digits: ${o}`);e=a}return r},()=>new ns(e)}var Ac=Array.prototype.slice;function Mi(r){return typeof r==="object"&&"length"in r?r:Array.from(r)}function rg(r){this._context=r}rg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;default:this._context.lineTo(r,e);break}}};function si(r){return new rg(r)}function Ao(r){return r[0]}function To(r){return r[1]}function sa(r,e){var o=we(!0),a=null,s=si,n=null,c=oa(l);r=typeof r==="function"?r:r===void 0?Ao:we(r),e=typeof e==="function"?e:e===void 0?To:we(e);function l(p){var m,u=(p=Mi(p)).length,y,x=!1,k;if(a==null)n=s(k=c());for(m=0;m<=u;++m){if(!(m<u&&o(y=p[m],m,p))===x)if(x=!x)n.lineStart();else n.lineEnd();if(x)n.point(+r(y,m,p),+e(y,m,p))}if(k)return n=null,k+""||null}return l.x=function(p){return arguments.length?(r=typeof p==="function"?p:we(+p),l):r},l.y=function(p){return arguments.length?(e=typeof p==="function"?p:we(+p),l):e},l.defined=function(p){return arguments.length?(o=typeof p==="function"?p:we(!!p),l):o},l.curve=function(p){return arguments.length?(s=p,a!=null&&(n=s(a)),l):s},l.context=function(p){return arguments.length?(p==null?a=n=null:n=s(a=p),l):a},l}class hu{constructor(r,e){this._context=r,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line}point(r,e){switch(r=+r,e=+e,this._point){case 0:{if(this._point=1,this._line)this._context.lineTo(r,e);else this._context.moveTo(r,e);break}case 1:this._point=2;default:{if(this._x)this._context.bezierCurveTo(this._x0=(this._x0+r)/2,this._y0,this._x0,e,r,e);else this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,r,this._y0,r,e);break}}this._x0=r,this._y0=e}}function ca(r){return new hu(r,!0)}function _a(r){return new hu(r,!1)}function Lr(){}function ls(r,e,o){r._context.bezierCurveTo((2*r._x0+r._x1)/3,(2*r._y0+r._y1)/3,(r._x0+2*r._x1)/3,(r._y0+2*r._y1)/3,(r._x0+4*r._x1+e)/6,(r._y0+4*r._y1+o)/6)}function Ba(r){this._context=r}Ba.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:ls(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function so(r){return new Ba(r)}function ig(r){this._context=r}ig.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._x2=r,this._y2=e;break;case 1:this._point=2,this._x3=r,this._y3=e;break;case 2:this._point=3,this._x4=r,this._y4=e,this._context.moveTo((this._x0+4*this._x1+r)/6,(this._y0+4*this._y1+e)/6);break;default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function ol(r){return new ig(r)}function og(r){this._context=r}og.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var o=(this._x0+4*this._x1+r)/6,a=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(o,a):this._context.moveTo(o,a);break;case 3:this._point=4;default:ls(this,r,e);break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e}};function sl(r){return new og(r)}function sg(r,e){this._basis=new Ba(r),this._beta=e}sg.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var r=this._x,e=this._y,o=r.length-1;if(o>0){var a=r[0],s=e[0],n=r[o]-a,c=e[o]-s,l=-1,p;while(++l<=o)p=l/o,this._basis.point(this._beta*r[l]+(1-this._beta)*(a+p*n),this._beta*e[l]+(1-this._beta)*(s+p*c))}this._x=this._y=null,this._basis.lineEnd()},point:function(r,e){this._x.push(+r),this._y.push(+e)}};var cu=function r(e){function o(a){return e===1?new Ba(a):new sg(a,e)}return o.beta=function(a){return r(+a)},o}(0.85);function hs(r,e,o){r._context.bezierCurveTo(r._x1+r._k*(r._x2-r._x0),r._y1+r._k*(r._y2-r._y0),r._x2+r._k*(r._x1-e),r._y2+r._k*(r._y1-o),r._x2,r._y2)}function al(r,e){this._context=r,this._k=(1-e)/6}al.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:hs(this,this._x1,this._y1);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2,this._x1=r,this._y1=e;break;case 2:this._point=3;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var va=function r(e){function o(a){return new al(a,e)}return o.tension=function(a){return r(+a)},o}(0);function nl(r,e){this._context=r,this._k=(1-e)/6}nl.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._x3=r,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=r,this._y4=e);break;case 2:this._point=3,this._x5=r,this._y5=e;break;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var uu=function r(e){function o(a){return new nl(a,e)}return o.tension=function(a){return r(+a)},o}(0);function ll(r,e){this._context=r,this._k=(1-e)/6}ll.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:hs(this,r,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var fu=function r(e){function o(a){return new ll(a,e)}return o.tension=function(a){return r(+a)},o}(0);function La(r,e,o){var{_x1:a,_y1:s,_x2:n,_y2:c}=r;if(r._l01_a>xt){var l=2*r._l01_2a+3*r._l01_a*r._l12_a+r._l12_2a,p=3*r._l01_a*(r._l01_a+r._l12_a);a=(a*l-r._x0*r._l12_2a+r._x2*r._l01_2a)/p,s=(s*l-r._y0*r._l12_2a+r._y2*r._l01_2a)/p}if(r._l23_a>xt){var m=2*r._l23_2a+3*r._l23_a*r._l12_a+r._l12_2a,u=3*r._l23_a*(r._l23_a+r._l12_a);n=(n*m+r._x1*r._l23_2a-e*r._l12_2a)/u,c=(c*m+r._y1*r._l23_2a-o*r._l12_2a)/u}r._context.bezierCurveTo(a,s,n,c,r._x2,r._y2)}function ag(r,e){this._context=r,this._alpha=e}ag.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var Fa=function r(e){function o(a){return e?new ag(a,e):new al(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function ng(r,e){this._context=r,this._alpha=e}ng.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=r,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=r,this._y4=e);break;case 2:this._point=3,this._x5=r,this._y5=e;break;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var du=function r(e){function o(a){return e?new ng(a,e):new nl(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function lg(r,e){this._context=r,this._alpha=e}lg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){if(this._line||this._line!==0&&this._point===3)this._context.closePath();this._line=1-this._line},point:function(r,e){if(r=+r,e=+e,this._point){var o=this._x2-r,a=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(o*o+a*a,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:La(this,r,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=r,this._y0=this._y1,this._y1=this._y2,this._y2=e}};var pu=function r(e){function o(a){return e?new lg(a,e):new ll(a,0)}return o.alpha=function(a){return r(+a)},o}(0.5);function hg(r){this._context=r}hg.prototype={areaStart:Lr,areaEnd:Lr,lineStart:function(){this._point=0},lineEnd:function(){if(this._point)this._context.closePath()},point:function(r,e){if(r=+r,e=+e,this._point)this._context.lineTo(r,e);else this._point=1,this._context.moveTo(r,e)}};function hl(r){return new hg(r)}function cg(r){return r<0?-1:1}function ug(r,e,o){var a=r._x1-r._x0,s=e-r._x1,n=(r._y1-r._y0)/(a||s<0&&-0),c=(o-r._y1)/(s||a<0&&-0),l=(n*s+c*a)/(a+s);return(cg(n)+cg(c))*Math.min(Math.abs(n),Math.abs(c),0.5*Math.abs(l))||0}function fg(r,e){var o=r._x1-r._x0;return o?(3*(r._y1-r._y0)/o-e)/2:e}function gu(r,e,o){var{_x0:a,_y0:s,_x1:n,_y1:c}=r,l=(n-a)/3;r._context.bezierCurveTo(a+l,s+l*e,n-l,c-l*o,n,c)}function cl(r){this._context=r}cl.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:gu(this,this._t0,fg(this,this._t0));break}if(this._line||this._line!==0&&this._point===1)this._context.closePath();this._line=1-this._line},point:function(r,e){var o=NaN;if(r=+r,e=+e,r===this._x1&&e===this._y1)return;switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;break;case 2:this._point=3,gu(this,fg(this,o=ug(this,r,e)),o);break;default:gu(this,this._t0,o=ug(this,r,e));break}this._x0=this._x1,this._x1=r,this._y0=this._y1,this._y1=e,this._t0=o}};function dg(r){this._context=new pg(r)}(dg.prototype=Object.create(cl.prototype)).point=function(r,e){cl.prototype.point.call(this,e,r)};function pg(r){this._context=r}pg.prototype={moveTo:function(r,e){this._context.moveTo(e,r)},closePath:function(){this._context.closePath()},lineTo:function(r,e){this._context.lineTo(e,r)},bezierCurveTo:function(r,e,o,a,s,n){this._context.bezierCurveTo(e,r,a,o,n,s)}};function Aa(r){return new cl(r)}function Ma(r){return new dg(r)}function mg(r){this._context=r}mg.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var r=this._x,e=this._y,o=r.length;if(o)if(this._line?this._context.lineTo(r[0],e[0]):this._context.moveTo(r[0],e[0]),o===2)this._context.lineTo(r[1],e[1]);else{var a=gg(r),s=gg(e);for(var n=0,c=1;c<o;++n,++c)this._context.bezierCurveTo(a[0][n],s[0][n],a[1][n],s[1][n],r[c],e[c])}if(this._line||this._line!==0&&o===1)this._context.closePath();this._line=1-this._line,this._x=this._y=null},point:function(r,e){this._x.push(+r),this._y.push(+e)}};function gg(r){var e,o=r.length-1,a,s=Array(o),n=Array(o),c=Array(o);s[0]=0,n[0]=2,c[0]=r[0]+2*r[1];for(e=1;e<o-1;++e)s[e]=1,n[e]=4,c[e]=4*r[e]+2*r[e+1];s[o-1]=2,n[o-1]=7,c[o-1]=8*r[o-1]+r[o];for(e=1;e<o;++e)a=s[e]/n[e-1],n[e]-=a,c[e]-=a*c[e-1];s[o-1]=c[o-1]/n[o-1];for(e=o-2;e>=0;--e)s[e]=(c[e]-s[e+1])/n[e];n[o-1]=(r[o]+s[o-1])/2;for(e=0;e<o-1;++e)n[e]=2*r[e+1]-s[e+1];return[s,n]}function cs(r){return new mg(r)}function ul(r,e){this._context=r,this._t=e}ul.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){if(0<this._t&&this._t<1&&this._point===2)this._context.lineTo(this._x,this._y);if(this._line||this._line!==0&&this._point===1)this._context.closePath();if(this._line>=0)this._t=1-this._t,this._line=1-this._line},point:function(r,e){switch(r=+r,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(r,e):this._context.moveTo(r,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(r,e);else{var o=this._x*(1-this._t)+r*this._t;this._context.lineTo(o,this._y),this._context.lineTo(o,e)}break}}this._x=r,this._y=e}};function us(r){return new ul(r,0.5)}function Ea(r){return new ul(r,0)}function Oa(r){return new ul(r,1)}function Ki(r,e,o){this.k=r,this.x=e,this.y=o}Ki.prototype={constructor:Ki,scale:function(r){return r===1?this:new Ki(this.k*r,this.x,this.y)},translate:function(r,e){return r===0&e===0?this:new Ki(this.k,this.x+this.k*r,this.y+this.k*e)},apply:function(r){return[r[0]*this.k+this.x,r[1]*this.k+this.y]},applyX:function(r){return r*this.k+this.x},applyY:function(r){return r*this.k+this.y},invert:function(r){return[(r[0]-this.x)/this.k,(r[1]-this.y)/this.k]},invertX:function(r){return(r-this.x)/this.k},invertY:function(r){return(r-this.y)/this.k},rescaleX:function(r){return r.copy().domain(r.range().map(this.invertX,this).map(r.invert,r))},rescaleY:function(r){return r.copy().domain(r.range().map(this.invertY,this).map(r.invert,r))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var mu=new Ki(1,0,0);yu.prototype=Ki.prototype;function yu(r){while(!r.__zoom)if(!(r=r.parentNode))return mu;return r.__zoom}var J=t((r)=>{let{securityLevel:e}=d(),o=g("body");if(e==="sandbox"){let n=g(`#i${r}`).node()?.contentDocument??document;o=g(n.body)}return o.select(`#${r}`)},"selectSvgElement");function zg(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}t(zg,"getDefaultExportFromCjs");var lr={},fl={},Zi={},yg;function fs(){if(yg)return Zi;yg=1;function r(c){return typeof c>"u"||c===null}t(r,"isNothing");function e(c){return typeof c==="object"&&c!==null}t(e,"isObject");function o(c){if(Array.isArray(c))return c;else if(r(c))return[];return[c]}t(o,"toArray");function a(c,l){if(l){let p=Object.keys(l);for(let m=0,u=p.length;m<u;m+=1){let y=p[m];c[y]=l[y]}}return c}t(a,"extend");function s(c,l){let p="";for(let m=0;m<l;m+=1)p+=c;return p}t(s,"repeat");function n(c){return c===0&&Number.NEGATIVE_INFINITY===1/c}return t(n,"isNegativeZero"),Zi.isNothing=r,Zi.isObject=e,Zi.toArray=o,Zi.repeat=s,Zi.isNegativeZero=n,Zi.extend=a,Zi}t(fs,"requireCommon");var xu,xg;function ds(){if(xg)return xu;xg=1;function r(o,a){let s="",n=o.reason||"(unknown reason)";if(!o.mark)return n;if(o.mark.name)s+='in "'+o.mark.name+'" ';if(s+="("+(o.mark.line+1)+":"+(o.mark.column+1)+")",!a&&o.mark.snippet)s+=`
|
|
130
130
|
|
|
131
131
|
`+o.mark.snippet;return n+" "+s}t(r,"formatError");function e(o,a){if(Error.call(this),this.name="YAMLException",this.reason=o,this.mark=a,this.message=r(this,!1),Error.captureStackTrace)Error.captureStackTrace(this,this.constructor);else this.stack=Error().stack||""}return t(e,"YAMLException2"),e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e.prototype.toString=t(function(a){return this.name+": "+r(this,a)},"toString"),xu=e,xu}t(ds,"requireException");var Cu,Cg;function Hg(){if(Cg)return Cu;Cg=1;let r=fs();function e(s,n,c,l,p){let m="",u="",y=Math.floor(p/2)-1;if(l-n>y)m=" ... ",n=l-y+m.length;if(c-l>y)u=" ...",c=l+y-u.length;return{str:m+s.slice(n,c).replace(/\t/g,"→")+u,pos:l-n+m.length}}t(e,"getLine");function o(s,n){return r.repeat(" ",n-s.length)+s}t(o,"padStart");function a(s,n){if(n=Object.create(n||null),!s.buffer)return null;if(!n.maxLength)n.maxLength=79;if(typeof n.indent!=="number")n.indent=1;if(typeof n.linesBefore!=="number")n.linesBefore=3;if(typeof n.linesAfter!=="number")n.linesAfter=2;let c=/\r?\n|\r|\0/g,l=[0],p=[],m,u=-1;while(m=c.exec(s.buffer))if(p.push(m.index),l.push(m.index+m[0].length),s.position<=m.index&&u<0)u=l.length-2;if(u<0)u=l.length-1;let y="",x=Math.min(s.line+n.linesAfter,p.length).toString().length,k=n.maxLength-(n.indent+x+3);for(let _=1;_<=n.linesBefore;_++){if(u-_<0)break;let M=e(s.buffer,l[u-_],p[u-_],s.position-(l[u]-l[u-_]),k);y=r.repeat(" ",n.indent)+o((s.line-_+1).toString(),x)+" | "+M.str+`
|
|
132
132
|
`+y}let w=e(s.buffer,l[u],p[u],s.position,k);y+=r.repeat(" ",n.indent)+o((s.line+1).toString(),x)+" | "+w.str+`
|
|
133
133
|
`,y+=r.repeat("-",n.indent+x+3+w.pos)+`^
|
|
134
134
|
`;for(let _=1;_<=n.linesAfter;_++){if(u+_>=p.length)break;let M=e(s.buffer,l[u+_],p[u+_],s.position-(l[u]-l[u+_]),k);y+=r.repeat(" ",n.indent)+o((s.line+_+1).toString(),x)+" | "+M.str+`
|
|
135
|
-
`}return y.replace(/\n$/,"")}return t(a,"makeSnippet"),Cu=a,Cu}t(Hg,"requireSnippet");var bu,bg;function cr(){if(bg)return bu;bg=1;let r=ds(),e=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],o=["scalar","sequence","mapping"];function a(n){let c={};if(n!==null)Object.keys(n).forEach(function(l){n[l].forEach(function(p){c[String(p)]=l})});return c}t(a,"compileStyleAliases");function s(n,c){if(c=c||{},Object.keys(c).forEach(function(l){if(e.indexOf(l)===-1)throw new r('Unknown option "'+l+'" is met in definition of "'+n+'" YAML type.')}),this.options=c,this.tag=n,this.kind=c.kind||null,this.resolve=c.resolve||function(){return!0},this.construct=c.construct||function(l){return l},this.instanceOf=c.instanceOf||null,this.predicate=c.predicate||null,this.represent=c.represent||null,this.representName=c.representName||null,this.defaultStyle=c.defaultStyle||null,this.multi=c.multi||!1,this.styleAliases=a(c.styleAliases||null),o.indexOf(this.kind)===-1)throw new r('Unknown kind "'+this.kind+'" is specified for "'+n+'" YAML type.')}return t(s,"Type2"),bu=s,bu}t(cr,"requireType");var ku,kg;function Nu(){if(kg)return ku;kg=1;let r=ds(),e=cr();function o(n,c){let l=[];return n[c].forEach(function(p){let m=l.length;l.forEach(function(u,y){if(u.tag===p.tag&&u.kind===p.kind&&u.multi===p.multi)m=y}),l[m]=p}),l}t(o,"compileList");function a(){let n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function c(l){if(l.multi)n.multi[l.kind].push(l),n.multi.fallback.push(l);else n[l.kind][l.tag]=n.fallback[l.tag]=l}t(c,"collectType");for(let l=0,p=arguments.length;l<p;l+=1)arguments[l].forEach(c);return n}t(a,"compileMap");function s(n){return this.extend(n)}return t(s,"Schema2"),s.prototype.extend=t(function(c){let l=[],p=[];if(c instanceof e)p.push(c);else if(Array.isArray(c))p=p.concat(c);else if(c&&(Array.isArray(c.implicit)||Array.isArray(c.explicit))){if(c.implicit)l=l.concat(c.implicit);if(c.explicit)p=p.concat(c.explicit)}else throw new r("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");l.forEach(function(u){if(!(u instanceof e))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(u.loadKind&&u.loadKind!=="scalar")throw new r("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(u.multi)throw new r("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),p.forEach(function(u){if(!(u instanceof e))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.")});let m=Object.create(s.prototype);return m.implicit=(this.implicit||[]).concat(l),m.explicit=(this.explicit||[]).concat(p),m.compiledImplicit=o(m,"implicit"),m.compiledExplicit=o(m,"explicit"),m.compiledTypeMap=a(m.compiledImplicit,m.compiledExplicit),m},"extend"),ku=s,ku}t(Nu,"requireSchema");var wu,wg;function Wu(){if(wg)return wu;return wg=1,wu=new(cr())("tag:yaml.org,2002:str",{kind:"scalar",construct:t(function(e){return e!==null?e:""},"construct")}),wu}t(Wu,"requireStr");var Su,Sg;function zu(){if(Sg)return Su;return Sg=1,Su=new(cr())("tag:yaml.org,2002:seq",{kind:"sequence",construct:t(function(e){return e!==null?e:[]},"construct")}),Su}t(zu,"requireSeq");var Tu,Tg;function Hu(){if(Tg)return Tu;return Tg=1,Tu=new(cr())("tag:yaml.org,2002:map",{kind:"mapping",construct:t(function(e){return e!==null?e:{}},"construct")}),Tu}t(Hu,"requireMap");var _u,_g;function Yu(){if(_g)return _u;return _g=1,_u=new(Nu())({explicit:[Wu(),zu(),Hu()]}),_u}t(Yu,"requireFailsafe");var Bu,Bg;function Uu(){if(Bg)return Bu;Bg=1;let r=cr();function e(s){if(s===null)return!0;let n=s.length;return n===1&&s==="~"||n===4&&(s==="null"||s==="Null"||s==="NULL")}t(e,"resolveYamlNull");function o(){return null}t(o,"constructYamlNull");function a(s){return s===null}return t(a,"isNull"),Bu=new r("tag:yaml.org,2002:null",{kind:"scalar",resolve:e,construct:o,predicate:a,represent:{canonical:t(function(){return"~"},"canonical"),lowercase:t(function(){return"null"},"lowercase"),uppercase:t(function(){return"NULL"},"uppercase"),camelcase:t(function(){return"Null"},"camelcase"),empty:t(function(){return""},"empty")},defaultStyle:"lowercase"}),Bu}t(Uu,"require_null");var vu,vg;function ju(){if(vg)return vu;vg=1;let r=cr();function e(s){if(s===null)return!1;let n=s.length;return n===4&&(s==="true"||s==="True"||s==="TRUE")||n===5&&(s==="false"||s==="False"||s==="FALSE")}t(e,"resolveYamlBoolean");function o(s){return s==="true"||s==="True"||s==="TRUE"}t(o,"constructYamlBoolean");function a(s){return Object.prototype.toString.call(s)==="[object Boolean]"}return t(a,"isBoolean"),vu=new r("tag:yaml.org,2002:bool",{kind:"scalar",resolve:e,construct:o,predicate:a,represent:{lowercase:t(function(s){return s?"true":"false"},"lowercase"),uppercase:t(function(s){return s?"TRUE":"FALSE"},"uppercase"),camelcase:t(function(s){return s?"True":"False"},"camelcase")},defaultStyle:"lowercase"}),vu}t(ju,"requireBool");var Lu,Lg;function Gu(){if(Lg)return Lu;Lg=1;let r=fs(),e=cr();function o(m){return m>=48&&m<=57||m>=65&&m<=70||m>=97&&m<=102}t(o,"isHexCode");function a(m){return m>=48&&m<=55}t(a,"isOctCode");function s(m){return m>=48&&m<=57}t(s,"isDecCode");function n(m){if(m===null)return!1;let u=m.length,y=0,x=!1;if(!u)return!1;let k=m[y];if(k==="-"||k==="+")k=m[++y];if(k==="0"){if(y+1===u)return!0;if(k=m[++y],k==="b"){y++;for(;y<u;y++){if(k=m[y],k!=="0"&&k!=="1")return!1;x=!0}return x&&isFinite(c(m))}if(k==="x"){y++;for(;y<u;y++){if(!o(m.charCodeAt(y)))return!1;x=!0}return x&&isFinite(c(m))}if(k==="o"){y++;for(;y<u;y++){if(!a(m.charCodeAt(y)))return!1;x=!0}return x&&isFinite(c(m))}}for(;y<u;y++){if(!s(m.charCodeAt(y)))return!1;x=!0}if(!x)return!1;return isFinite(c(m))}t(n,"resolveYamlInteger");function c(m){let u=m,y=1,x=u[0];if(x==="-"||x==="+"){if(x==="-")y=-1;u=u.slice(1),x=u[0]}if(u==="0")return 0;if(x==="0"){if(u[1]==="b")return y*parseInt(u.slice(2),2);if(u[1]==="x")return y*parseInt(u.slice(2),16);if(u[1]==="o")return y*parseInt(u.slice(2),8)}return y*parseInt(u,10)}t(c,"parseYamlInteger");function l(m){return c(m)}t(l,"constructYamlInteger");function p(m){return Object.prototype.toString.call(m)==="[object Number]"&&(m%1===0&&!r.isNegativeZero(m))}return t(p,"isInteger"),Lu=new e("tag:yaml.org,2002:int",{kind:"scalar",resolve:n,construct:l,predicate:p,represent:{binary:t(function(m){return m>=0?"0b"+m.toString(2):"-0b"+m.toString(2).slice(1)},"binary"),octal:t(function(m){return m>=0?"0o"+m.toString(8):"-0o"+m.toString(8).slice(1)},"octal"),decimal:t(function(m){return m.toString(10)},"decimal"),hexadecimal:t(function(m){return m>=0?"0x"+m.toString(16).toUpperCase():"-0x"+m.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Lu}t(Gu,"requireInt");var Fu,Fg;function Xu(){if(Fg)return Fu;Fg=1;let r=fs(),e=cr(),o=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),a=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function s(m){if(m===null)return!1;if(!o.test(m))return!1;if(isFinite(parseFloat(m,10)))return!0;return a.test(m)}t(s,"resolveYamlFloat");function n(m){let u=m.toLowerCase(),y=u[0]==="-"?-1:1;if("+-".indexOf(u[0])>=0)u=u.slice(1);if(u===".inf")return y===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;else if(u===".nan")return NaN;return y*parseFloat(u,10)}t(n,"constructYamlFloat");let c=/^[-+]?[0-9]+e/;function l(m,u){if(isNaN(m))switch(u){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===m)switch(u){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===m)switch(u){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(r.isNegativeZero(m))return"-0.0";let y=m.toString(10);return c.test(y)?y.replace("e",".e"):y}t(l,"representYamlFloat");function p(m){return Object.prototype.toString.call(m)==="[object Number]"&&(m%1!==0||r.isNegativeZero(m))}return t(p,"isFloat"),Fu=new e("tag:yaml.org,2002:float",{kind:"scalar",resolve:s,construct:n,predicate:p,represent:l,defaultStyle:"lowercase"}),Fu}t(Xu,"requireFloat");var Au,Ag;function Vu(){if(Ag)return Au;return Ag=1,Au=Yu().extend({implicit:[Uu(),ju(),Gu(),Xu()]}),Au}t(Vu,"requireJson");var Mu,Mg;function Ku(){if(Mg)return Mu;return Mg=1,Mu=Vu(),Mu}t(Ku,"requireCore");var Eu,Eg;function Zu(){if(Eg)return Eu;Eg=1;let r=cr(),e=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),o=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function a(c){if(c===null)return!1;if(e.exec(c)!==null)return!0;if(o.exec(c)!==null)return!0;return!1}t(a,"resolveYamlTimestamp");function s(c){let l=0,p=null,m=e.exec(c);if(m===null)m=o.exec(c);if(m===null)throw Error("Date resolve error");let u=+m[1],y=+m[2]-1,x=+m[3];if(!m[4])return new Date(Date.UTC(u,y,x));let k=+m[4],w=+m[5],_=+m[6];if(m[7]){l=m[7].slice(0,3);while(l.length<3)l+="0";l=+l}if(m[9]){let q=+m[10],Y=+(m[11]||0);if(p=(q*60+Y)*60000,m[9]==="-")p=-p}let M=new Date(Date.UTC(u,y,x,k,w,_,l));if(p)M.setTime(M.getTime()-p);return M}t(s,"constructYamlTimestamp");function n(c){return c.toISOString()}return t(n,"representYamlTimestamp"),Eu=new r("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:a,construct:s,instanceOf:Date,represent:n}),Eu}t(Zu,"requireTimestamp");var Ou,Og;function Qu(){if(Og)return Ou;Og=1;let r=cr();function e(o){return o==="<<"||o===null}return t(e,"resolveYamlMerge"),Ou=new r("tag:yaml.org,2002:merge",{kind:"scalar",resolve:e}),Ou}t(Qu,"requireMerge");var Iu,Ig;function Ju(){if(Ig)return Iu;Ig=1;let r=cr(),e=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
136
|
-
\r`;function o(c){if(c===null)return!1;let l=0,p=c.length,m=e;for(let u=0;u<p;u++){let y=m.indexOf(c.charAt(u));if(y>64)continue;if(y<0)return!1;l+=6}return l%8===0}t(o,"resolveYamlBinary");function a(c){let l=c.replace(/[\r\n=]/g,""),p=l.length,m=e,u=0,y=[];for(let k=0;k<p;k++){if(k%4===0&&k)y.push(u>>16&255),y.push(u>>8&255),y.push(u&255);u=u<<6|m.indexOf(l.charAt(k))}let x=p%4*6;if(x===0)y.push(u>>16&255),y.push(u>>8&255),y.push(u&255);else if(x===18)y.push(u>>10&255),y.push(u>>2&255);else if(x===12)y.push(u>>4&255);return new Uint8Array(y)}t(a,"constructYamlBinary");function s(c){let l="",p=0,m=c.length,u=e;for(let x=0;x<m;x++){if(x%3===0&&x)l+=u[p>>18&63],l+=u[p>>12&63],l+=u[p>>6&63],l+=u[p&63];p=(p<<8)+c[x]}let y=m%3;if(y===0)l+=u[p>>18&63],l+=u[p>>12&63],l+=u[p>>6&63],l+=u[p&63];else if(y===2)l+=u[p>>10&63],l+=u[p>>4&63],l+=u[p<<2&63],l+=u[64];else if(y===1)l+=u[p>>2&63],l+=u[p<<4&63],l+=u[64],l+=u[64];return l}t(s,"representYamlBinary");function n(c){return Object.prototype.toString.call(c)==="[object Uint8Array]"}return t(n,"isBinary"),Iu=new r("tag:yaml.org,2002:binary",{kind:"scalar",resolve:o,construct:a,predicate:n,represent:s}),Iu}t(Ju,"requireBinary");var $u,$g;function tf(){if($g)return $u;$g=1;let r=cr(),e=Object.prototype.hasOwnProperty,o=Object.prototype.toString;function a(n){if(n===null)return!0;let c=[],l=n;for(let p=0,m=l.length;p<m;p+=1){let u=l[p],y=!1;if(o.call(u)!=="[object Object]")return!1;let x;for(x in u)if(e.call(u,x))if(!y)y=!0;else return!1;if(!y)return!1;if(c.indexOf(x)===-1)c.push(x);else return!1}return!0}t(a,"resolveYamlOmap");function s(n){return n!==null?n:[]}return t(s,"constructYamlOmap"),$u=new r("tag:yaml.org,2002:omap",{kind:"sequence",resolve:a,construct:s}),$u}t(tf,"requireOmap");var Du,Dg;function ef(){if(Dg)return Du;Dg=1;let r=cr(),e=Object.prototype.toString;function o(s){if(s===null)return!0;let n=s,c=Array(n.length);for(let l=0,p=n.length;l<p;l+=1){let m=n[l];if(e.call(m)!=="[object Object]")return!1;let u=Object.keys(m);if(u.length!==1)return!1;c[l]=[u[0],m[u[0]]]}return!0}t(o,"resolveYamlPairs");function a(s){if(s===null)return[];let n=s,c=Array(n.length);for(let l=0,p=n.length;l<p;l+=1){let m=n[l],u=Object.keys(m);c[l]=[u[0],m[u[0]]]}return c}return t(a,"constructYamlPairs"),Du=new r("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:o,construct:a}),Du}t(ef,"requirePairs");var Pu,Pg;function rf(){if(Pg)return Pu;Pg=1;let r=cr(),e=Object.prototype.hasOwnProperty;function o(s){if(s===null)return!0;let n=s;for(let c in n)if(e.call(n,c)){if(n[c]!==null)return!1}return!0}t(o,"resolveYamlSet");function a(s){return s!==null?s:{}}return t(a,"constructYamlSet"),Pu=new r("tag:yaml.org,2002:set",{kind:"mapping",resolve:o,construct:a}),Pu}t(rf,"requireSet");var Ru,Rg;function dl(){if(Rg)return Ru;return Rg=1,Ru=Ku().extend({implicit:[Zu(),Qu()],explicit:[Ju(),tf(),ef(),rf()]}),Ru}t(dl,"require_default");var qg;function Yg(){if(qg)return fl;qg=1;let r=fs(),e=ds(),o=Hg(),a=dl(),s=Object.prototype.hasOwnProperty,n=1,c=2,l=3,p=4,m=1,u=2,y=3,x=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,k=/[\x85\u2028\u2029]/,w=/[,\[\]{}]/,_=/^(?:!|!!|![0-9A-Za-z-]+!)$/,M=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function
|
|
137
|
-
`;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"
";case 95:return" ";case 76:return"\u2028";case 80:return"\u2029";default:return""}}t(yt,"simpleEscapeSequence");function Bt(b){if(b<=65535)return String.fromCharCode(b);return String.fromCharCode((b-65536>>10)+55296,(b-65536&1023)+56320)}t(Bt,"charFromCodepoint");function kt(b,ft,Tt){if(ft==="__proto__")Object.defineProperty(b,ft,{configurable:!0,enumerable:!0,writable:!0,value:Tt});else b[ft]=Tt}t(kt,"setProperty");let Ct=Array(256),rt=Array(256);for(let b=0;b<256;b++)Ct[b]=yt(b)?1:0,rt[b]=yt(b);function it(b,ft){this.input=b,this.filename=ft.filename||null,this.schema=ft.schema||a,this.onWarning=ft.onWarning||null,this.legacy=ft.legacy||!1,this.json=ft.json||!1,this.listener=ft.listener||null,this.maxDepth=typeof ft.maxDepth==="number"?ft.maxDepth:100,this.maxTotalMergeKeys=typeof ft.maxTotalMergeKeys==="number"?ft.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=b.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}t(it,"State");function gt(b,ft){let Tt={name:b.filename,buffer:b.input.slice(0,-1),position:b.position,line:b.line,column:b.position-b.lineStart};return Tt.snippet=o(Tt),new e(ft,Tt)}t(gt,"generateError");function et(b,ft){throw gt(b,ft)}t(et,"throwError");function wt(b,ft){if(b.onWarning)b.onWarning.call(null,gt(b,ft))}t(wt,"throwWarning");function vt(b,ft,Tt){let At=b.anchorMapTransactions;if(At.length!==0){let St=At[At.length-1];if(!s.call(St,ft))St[ft]={existed:s.call(b.anchorMap,ft),value:b.anchorMap[ft]}}b.anchorMap[ft]=Tt}t(vt,"storeAnchor");function Xt(b){b.anchorMapTransactions.push(Object.create(null))}t(Xt,"beginAnchorTransaction");function jt(b){let ft=b.anchorMapTransactions.pop(),Tt=b.anchorMapTransactions;if(Tt.length===0)return;let At=Tt[Tt.length-1],St=Object.keys(ft);for(let Yt=0,G=St.length;Yt<G;Yt+=1){let mt=St[Yt];if(!s.call(At,mt))At[mt]=ft[mt]}}t(jt,"commitAnchorTransaction");function se(b){let ft=b.anchorMapTransactions.pop(),Tt=Object.keys(ft);for(let At=Tt.length-1;At>=0;At-=1){let St=ft[Tt[At]];if(St.existed)b.anchorMap[Tt[At]]=St.value;else delete b.anchorMap[Tt[At]]}}t(se,"rollbackAnchorTransaction");function oe(b){return{position:b.position,line:b.line,lineStart:b.lineStart,lineIndent:b.lineIndent,firstTabInLine:b.firstTabInLine,tag:b.tag,anchor:b.anchor,kind:b.kind,result:b.result}}t(oe,"snapshotState");function
|
|
138
|
-
`,ft-1)}t(
|
|
135
|
+
`}return y.replace(/\n$/,"")}return t(a,"makeSnippet"),Cu=a,Cu}t(Hg,"requireSnippet");var bu,bg;function cr(){if(bg)return bu;bg=1;let r=ds(),e=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],o=["scalar","sequence","mapping"];function a(n){let c={};if(n!==null)Object.keys(n).forEach(function(l){n[l].forEach(function(p){c[String(p)]=l})});return c}t(a,"compileStyleAliases");function s(n,c){if(c=c||{},Object.keys(c).forEach(function(l){if(e.indexOf(l)===-1)throw new r('Unknown option "'+l+'" is met in definition of "'+n+'" YAML type.')}),this.options=c,this.tag=n,this.kind=c.kind||null,this.resolve=c.resolve||function(){return!0},this.construct=c.construct||function(l){return l},this.instanceOf=c.instanceOf||null,this.predicate=c.predicate||null,this.represent=c.represent||null,this.representName=c.representName||null,this.defaultStyle=c.defaultStyle||null,this.multi=c.multi||!1,this.styleAliases=a(c.styleAliases||null),o.indexOf(this.kind)===-1)throw new r('Unknown kind "'+this.kind+'" is specified for "'+n+'" YAML type.')}return t(s,"Type2"),bu=s,bu}t(cr,"requireType");var ku,kg;function Nu(){if(kg)return ku;kg=1;let r=ds(),e=cr();function o(n,c){let l=[];return n[c].forEach(function(p){let m=l.length;l.forEach(function(u,y){if(u.tag===p.tag&&u.kind===p.kind&&u.multi===p.multi)m=y}),l[m]=p}),l}t(o,"compileList");function a(){let n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function c(l){if(l.multi)n.multi[l.kind].push(l),n.multi.fallback.push(l);else n[l.kind][l.tag]=n.fallback[l.tag]=l}t(c,"collectType");for(let l=0,p=arguments.length;l<p;l+=1)arguments[l].forEach(c);return n}t(a,"compileMap");function s(n){return this.extend(n)}return t(s,"Schema2"),s.prototype.extend=t(function(c){let l=[],p=[];if(c instanceof e)p.push(c);else if(Array.isArray(c))p=p.concat(c);else if(c&&(Array.isArray(c.implicit)||Array.isArray(c.explicit))){if(c.implicit)l=l.concat(c.implicit);if(c.explicit)p=p.concat(c.explicit)}else throw new r("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");l.forEach(function(u){if(!(u instanceof e))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(u.loadKind&&u.loadKind!=="scalar")throw new r("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(u.multi)throw new r("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),p.forEach(function(u){if(!(u instanceof e))throw new r("Specified list of YAML types (or a single Type object) contains a non-Type object.")});let m=Object.create(s.prototype);return m.implicit=(this.implicit||[]).concat(l),m.explicit=(this.explicit||[]).concat(p),m.compiledImplicit=o(m,"implicit"),m.compiledExplicit=o(m,"explicit"),m.compiledTypeMap=a(m.compiledImplicit,m.compiledExplicit),m},"extend"),ku=s,ku}t(Nu,"requireSchema");var wu,wg;function Wu(){if(wg)return wu;return wg=1,wu=new(cr())("tag:yaml.org,2002:str",{kind:"scalar",construct:t(function(e){return e!==null?e:""},"construct")}),wu}t(Wu,"requireStr");var Su,Sg;function zu(){if(Sg)return Su;return Sg=1,Su=new(cr())("tag:yaml.org,2002:seq",{kind:"sequence",construct:t(function(e){return e!==null?e:[]},"construct")}),Su}t(zu,"requireSeq");var Tu,Tg;function Hu(){if(Tg)return Tu;return Tg=1,Tu=new(cr())("tag:yaml.org,2002:map",{kind:"mapping",construct:t(function(e){return e!==null?e:{}},"construct")}),Tu}t(Hu,"requireMap");var _u,_g;function Yu(){if(_g)return _u;return _g=1,_u=new(Nu())({explicit:[Wu(),zu(),Hu()]}),_u}t(Yu,"requireFailsafe");var Bu,Bg;function Uu(){if(Bg)return Bu;Bg=1;let r=cr();function e(s){if(s===null)return!0;let n=s.length;return n===1&&s==="~"||n===4&&(s==="null"||s==="Null"||s==="NULL")}t(e,"resolveYamlNull");function o(){return null}t(o,"constructYamlNull");function a(s){return s===null}return t(a,"isNull"),Bu=new r("tag:yaml.org,2002:null",{kind:"scalar",resolve:e,construct:o,predicate:a,represent:{canonical:t(function(){return"~"},"canonical"),lowercase:t(function(){return"null"},"lowercase"),uppercase:t(function(){return"NULL"},"uppercase"),camelcase:t(function(){return"Null"},"camelcase"),empty:t(function(){return""},"empty")},defaultStyle:"lowercase"}),Bu}t(Uu,"require_null");var vu,vg;function ju(){if(vg)return vu;vg=1;let r=cr();function e(s){if(s===null)return!1;let n=s.length;return n===4&&(s==="true"||s==="True"||s==="TRUE")||n===5&&(s==="false"||s==="False"||s==="FALSE")}t(e,"resolveYamlBoolean");function o(s){return s==="true"||s==="True"||s==="TRUE"}t(o,"constructYamlBoolean");function a(s){return Object.prototype.toString.call(s)==="[object Boolean]"}return t(a,"isBoolean"),vu=new r("tag:yaml.org,2002:bool",{kind:"scalar",resolve:e,construct:o,predicate:a,represent:{lowercase:t(function(s){return s?"true":"false"},"lowercase"),uppercase:t(function(s){return s?"TRUE":"FALSE"},"uppercase"),camelcase:t(function(s){return s?"True":"False"},"camelcase")},defaultStyle:"lowercase"}),vu}t(ju,"requireBool");var Lu,Lg;function Gu(){if(Lg)return Lu;Lg=1;let r=fs(),e=cr();function o(m){return m>=48&&m<=57||m>=65&&m<=70||m>=97&&m<=102}t(o,"isHexCode");function a(m){return m>=48&&m<=55}t(a,"isOctCode");function s(m){return m>=48&&m<=57}t(s,"isDecCode");function n(m){if(m===null)return!1;let u=m.length,y=0,x=!1;if(!u)return!1;let k=m[y];if(k==="-"||k==="+")k=m[++y];if(k==="0"){if(y+1===u)return!0;if(k=m[++y],k==="b"){y++;for(;y<u;y++){if(k=m[y],k!=="0"&&k!=="1")return!1;x=!0}return x&&isFinite(c(m))}if(k==="x"){y++;for(;y<u;y++){if(!o(m.charCodeAt(y)))return!1;x=!0}return x&&isFinite(c(m))}if(k==="o"){y++;for(;y<u;y++){if(!a(m.charCodeAt(y)))return!1;x=!0}return x&&isFinite(c(m))}}for(;y<u;y++){if(!s(m.charCodeAt(y)))return!1;x=!0}if(!x)return!1;return isFinite(c(m))}t(n,"resolveYamlInteger");function c(m){let u=m,y=1,x=u[0];if(x==="-"||x==="+"){if(x==="-")y=-1;u=u.slice(1),x=u[0]}if(u==="0")return 0;if(x==="0"){if(u[1]==="b")return y*parseInt(u.slice(2),2);if(u[1]==="x")return y*parseInt(u.slice(2),16);if(u[1]==="o")return y*parseInt(u.slice(2),8)}return y*parseInt(u,10)}t(c,"parseYamlInteger");function l(m){return c(m)}t(l,"constructYamlInteger");function p(m){return Object.prototype.toString.call(m)==="[object Number]"&&(m%1===0&&!r.isNegativeZero(m))}return t(p,"isInteger"),Lu=new e("tag:yaml.org,2002:int",{kind:"scalar",resolve:n,construct:l,predicate:p,represent:{binary:t(function(m){return m>=0?"0b"+m.toString(2):"-0b"+m.toString(2).slice(1)},"binary"),octal:t(function(m){return m>=0?"0o"+m.toString(8):"-0o"+m.toString(8).slice(1)},"octal"),decimal:t(function(m){return m.toString(10)},"decimal"),hexadecimal:t(function(m){return m>=0?"0x"+m.toString(16).toUpperCase():"-0x"+m.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Lu}t(Gu,"requireInt");var Fu,Fg;function Xu(){if(Fg)return Fu;Fg=1;let r=fs(),e=cr(),o=new RegExp("^(?:[-+]?(?:[0-9]+)(?:\\.[0-9]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"),a=new RegExp("^(?:[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function s(m){if(m===null)return!1;if(!o.test(m))return!1;if(isFinite(parseFloat(m,10)))return!0;return a.test(m)}t(s,"resolveYamlFloat");function n(m){let u=m.toLowerCase(),y=u[0]==="-"?-1:1;if("+-".indexOf(u[0])>=0)u=u.slice(1);if(u===".inf")return y===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY;else if(u===".nan")return NaN;return y*parseFloat(u,10)}t(n,"constructYamlFloat");let c=/^[-+]?[0-9]+e/;function l(m,u){if(isNaN(m))switch(u){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===m)switch(u){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===m)switch(u){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(r.isNegativeZero(m))return"-0.0";let y=m.toString(10);return c.test(y)?y.replace("e",".e"):y}t(l,"representYamlFloat");function p(m){return Object.prototype.toString.call(m)==="[object Number]"&&(m%1!==0||r.isNegativeZero(m))}return t(p,"isFloat"),Fu=new e("tag:yaml.org,2002:float",{kind:"scalar",resolve:s,construct:n,predicate:p,represent:l,defaultStyle:"lowercase"}),Fu}t(Xu,"requireFloat");var Au,Ag;function Vu(){if(Ag)return Au;return Ag=1,Au=Yu().extend({implicit:[Uu(),ju(),Gu(),Xu()]}),Au}t(Vu,"requireJson");var Mu,Mg;function Ku(){if(Mg)return Mu;return Mg=1,Mu=Vu(),Mu}t(Ku,"requireCore");var Eu,Eg;function Zu(){if(Eg)return Eu;Eg=1;let r=cr(),e=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),o=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function a(c){if(c===null)return!1;if(e.exec(c)!==null)return!0;if(o.exec(c)!==null)return!0;return!1}t(a,"resolveYamlTimestamp");function s(c){let l=0,p=null,m=e.exec(c);if(m===null)m=o.exec(c);if(m===null)throw Error("Date resolve error");let u=+m[1],y=+m[2]-1,x=+m[3];if(!m[4])return new Date(Date.UTC(u,y,x));let k=+m[4],w=+m[5],_=+m[6];if(m[7]){l=m[7].slice(0,3);while(l.length<3)l+="0";l=+l}if(m[9]){let W=+m[10],U=+(m[11]||0);if(p=(W*60+U)*60000,m[9]==="-")p=-p}let M=new Date(Date.UTC(u,y,x,k,w,_,l));if(p)M.setTime(M.getTime()-p);return M}t(s,"constructYamlTimestamp");function n(c){return c.toISOString()}return t(n,"representYamlTimestamp"),Eu=new r("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:a,construct:s,instanceOf:Date,represent:n}),Eu}t(Zu,"requireTimestamp");var Ou,Og;function Qu(){if(Og)return Ou;Og=1;let r=cr();function e(o){return o==="<<"||o===null}return t(e,"resolveYamlMerge"),Ou=new r("tag:yaml.org,2002:merge",{kind:"scalar",resolve:e}),Ou}t(Qu,"requireMerge");var Iu,Ig;function Ju(){if(Ig)return Iu;Ig=1;let r=cr(),e=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
136
|
+
\r`;function o(c){if(c===null)return!1;let l=0,p=c.length,m=e;for(let u=0;u<p;u++){let y=m.indexOf(c.charAt(u));if(y>64)continue;if(y<0)return!1;l+=6}return l%8===0}t(o,"resolveYamlBinary");function a(c){let l=c.replace(/[\r\n=]/g,""),p=l.length,m=e,u=0,y=[];for(let k=0;k<p;k++){if(k%4===0&&k)y.push(u>>16&255),y.push(u>>8&255),y.push(u&255);u=u<<6|m.indexOf(l.charAt(k))}let x=p%4*6;if(x===0)y.push(u>>16&255),y.push(u>>8&255),y.push(u&255);else if(x===18)y.push(u>>10&255),y.push(u>>2&255);else if(x===12)y.push(u>>4&255);return new Uint8Array(y)}t(a,"constructYamlBinary");function s(c){let l="",p=0,m=c.length,u=e;for(let x=0;x<m;x++){if(x%3===0&&x)l+=u[p>>18&63],l+=u[p>>12&63],l+=u[p>>6&63],l+=u[p&63];p=(p<<8)+c[x]}let y=m%3;if(y===0)l+=u[p>>18&63],l+=u[p>>12&63],l+=u[p>>6&63],l+=u[p&63];else if(y===2)l+=u[p>>10&63],l+=u[p>>4&63],l+=u[p<<2&63],l+=u[64];else if(y===1)l+=u[p>>2&63],l+=u[p<<4&63],l+=u[64],l+=u[64];return l}t(s,"representYamlBinary");function n(c){return Object.prototype.toString.call(c)==="[object Uint8Array]"}return t(n,"isBinary"),Iu=new r("tag:yaml.org,2002:binary",{kind:"scalar",resolve:o,construct:a,predicate:n,represent:s}),Iu}t(Ju,"requireBinary");var $u,$g;function tf(){if($g)return $u;$g=1;let r=cr(),e=Object.prototype.hasOwnProperty,o=Object.prototype.toString;function a(n){if(n===null)return!0;let c=[],l=n;for(let p=0,m=l.length;p<m;p+=1){let u=l[p],y=!1;if(o.call(u)!=="[object Object]")return!1;let x;for(x in u)if(e.call(u,x))if(!y)y=!0;else return!1;if(!y)return!1;if(c.indexOf(x)===-1)c.push(x);else return!1}return!0}t(a,"resolveYamlOmap");function s(n){return n!==null?n:[]}return t(s,"constructYamlOmap"),$u=new r("tag:yaml.org,2002:omap",{kind:"sequence",resolve:a,construct:s}),$u}t(tf,"requireOmap");var Du,Dg;function ef(){if(Dg)return Du;Dg=1;let r=cr(),e=Object.prototype.toString;function o(s){if(s===null)return!0;let n=s,c=Array(n.length);for(let l=0,p=n.length;l<p;l+=1){let m=n[l];if(e.call(m)!=="[object Object]")return!1;let u=Object.keys(m);if(u.length!==1)return!1;c[l]=[u[0],m[u[0]]]}return!0}t(o,"resolveYamlPairs");function a(s){if(s===null)return[];let n=s,c=Array(n.length);for(let l=0,p=n.length;l<p;l+=1){let m=n[l],u=Object.keys(m);c[l]=[u[0],m[u[0]]]}return c}return t(a,"constructYamlPairs"),Du=new r("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:o,construct:a}),Du}t(ef,"requirePairs");var Pu,Pg;function rf(){if(Pg)return Pu;Pg=1;let r=cr(),e=Object.prototype.hasOwnProperty;function o(s){if(s===null)return!0;let n=s;for(let c in n)if(e.call(n,c)){if(n[c]!==null)return!1}return!0}t(o,"resolveYamlSet");function a(s){return s!==null?s:{}}return t(a,"constructYamlSet"),Pu=new r("tag:yaml.org,2002:set",{kind:"mapping",resolve:o,construct:a}),Pu}t(rf,"requireSet");var Ru,Rg;function dl(){if(Rg)return Ru;return Rg=1,Ru=Ku().extend({implicit:[Zu(),Qu()],explicit:[Ju(),tf(),ef(),rf()]}),Ru}t(dl,"require_default");var qg;function Yg(){if(qg)return fl;qg=1;let r=fs(),e=ds(),o=Hg(),a=dl(),s=Object.prototype.hasOwnProperty,n=1,c=2,l=3,p=4,m=1,u=2,y=3,x=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,k=/[\x85\u2028\u2029]/,w=/[,\[\]{}]/,_=/^(?:!|!!|![0-9A-Za-z-]+!)$/,M=/^(?:!|[^,\[\]{}])(?:%[0-9a-f]{2}|[0-9a-z\-#;/?:@&=+$,_.!~*'()\[\]])*$/i;function W(b){return Object.prototype.toString.call(b)}t(W,"_class");function U(b){return b===10||b===13}t(U,"isEol");function V(b){return b===9||b===32}t(V,"isWhiteSpace");function Z(b){return b===9||b===32||b===10||b===13}t(Z,"isWsOrEol");function tt(b){return b===44||b===91||b===93||b===123||b===125}t(tt,"isFlowIndicator");function at(b){if(b>=48&&b<=57)return b-48;let ft=b|32;if(ft>=97&&ft<=102)return ft-97+10;return-1}t(at,"fromHexCode");function ot(b){if(b===120)return 2;if(b===117)return 4;if(b===85)return 8;return 0}t(ot,"escapedHexLen");function ht(b){if(b>=48&&b<=57)return b-48;return-1}t(ht,"fromDecimalCode");function yt(b){switch(b){case 48:return"\x00";case 97:return"\x07";case 98:return"\b";case 116:return"\t";case 9:return"\t";case 110:return`
|
|
137
|
+
`;case 118:return"\v";case 102:return"\f";case 114:return"\r";case 101:return"\x1B";case 32:return" ";case 34:return'"';case 47:return"/";case 92:return"\\";case 78:return"
";case 95:return" ";case 76:return"\u2028";case 80:return"\u2029";default:return""}}t(yt,"simpleEscapeSequence");function Bt(b){if(b<=65535)return String.fromCharCode(b);return String.fromCharCode((b-65536>>10)+55296,(b-65536&1023)+56320)}t(Bt,"charFromCodepoint");function kt(b,ft,Tt){if(ft==="__proto__")Object.defineProperty(b,ft,{configurable:!0,enumerable:!0,writable:!0,value:Tt});else b[ft]=Tt}t(kt,"setProperty");let Ct=Array(256),rt=Array(256);for(let b=0;b<256;b++)Ct[b]=yt(b)?1:0,rt[b]=yt(b);function it(b,ft){this.input=b,this.filename=ft.filename||null,this.schema=ft.schema||a,this.onWarning=ft.onWarning||null,this.legacy=ft.legacy||!1,this.json=ft.json||!1,this.listener=ft.listener||null,this.maxDepth=typeof ft.maxDepth==="number"?ft.maxDepth:100,this.maxTotalMergeKeys=typeof ft.maxTotalMergeKeys==="number"?ft.maxTotalMergeKeys:1e4,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=b.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.depth=0,this.totalMergeKeys=0,this.firstTabInLine=-1,this.documents=[],this.anchorMapTransactions=[]}t(it,"State");function gt(b,ft){let Tt={name:b.filename,buffer:b.input.slice(0,-1),position:b.position,line:b.line,column:b.position-b.lineStart};return Tt.snippet=o(Tt),new e(ft,Tt)}t(gt,"generateError");function et(b,ft){throw gt(b,ft)}t(et,"throwError");function wt(b,ft){if(b.onWarning)b.onWarning.call(null,gt(b,ft))}t(wt,"throwWarning");function vt(b,ft,Tt){let At=b.anchorMapTransactions;if(At.length!==0){let St=At[At.length-1];if(!s.call(St,ft))St[ft]={existed:s.call(b.anchorMap,ft),value:b.anchorMap[ft]}}b.anchorMap[ft]=Tt}t(vt,"storeAnchor");function Xt(b){b.anchorMapTransactions.push(Object.create(null))}t(Xt,"beginAnchorTransaction");function jt(b){let ft=b.anchorMapTransactions.pop(),Tt=b.anchorMapTransactions;if(Tt.length===0)return;let At=Tt[Tt.length-1],St=Object.keys(ft);for(let Yt=0,G=St.length;Yt<G;Yt+=1){let mt=St[Yt];if(!s.call(At,mt))At[mt]=ft[mt]}}t(jt,"commitAnchorTransaction");function se(b){let ft=b.anchorMapTransactions.pop(),Tt=Object.keys(ft);for(let At=Tt.length-1;At>=0;At-=1){let St=ft[Tt[At]];if(St.existed)b.anchorMap[Tt[At]]=St.value;else delete b.anchorMap[Tt[At]]}}t(se,"rollbackAnchorTransaction");function oe(b){return{position:b.position,line:b.line,lineStart:b.lineStart,lineIndent:b.lineIndent,firstTabInLine:b.firstTabInLine,tag:b.tag,anchor:b.anchor,kind:b.kind,result:b.result}}t(oe,"snapshotState");function de(b,ft){b.position=ft.position,b.line=ft.line,b.lineStart=ft.lineStart,b.lineIndent=ft.lineIndent,b.firstTabInLine=ft.firstTabInLine,b.tag=ft.tag,b.anchor=ft.anchor,b.kind=ft.kind,b.result=ft.result}t(de,"restoreState");let ge={YAML:t(function(ft,Tt,At){if(ft.version!==null)et(ft,"duplication of %YAML directive");if(At.length!==1)et(ft,"YAML directive accepts exactly one argument");let St=/^([0-9]+)\.([0-9]+)$/.exec(At[0]);if(St===null)et(ft,"ill-formed argument of the YAML directive");let Yt=parseInt(St[1],10),G=parseInt(St[2],10);if(Yt!==1)et(ft,"unacceptable YAML version of the document");if(ft.version=At[0],ft.checkLineBreaks=G<2,G!==1&&G!==2)wt(ft,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:t(function(ft,Tt,At){let St;if(At.length!==2)et(ft,"TAG directive accepts exactly two arguments");let Yt=At[0];if(St=At[1],!_.test(Yt))et(ft,"ill-formed tag handle (first argument) of the TAG directive");if(s.call(ft.tagMap,Yt))et(ft,'there is a previously declared suffix for "'+Yt+'" tag handle');if(!M.test(St))et(ft,"ill-formed tag prefix (second argument) of the TAG directive");try{St=decodeURIComponent(St)}catch(G){et(ft,"tag prefix is malformed: "+St)}ft.tagMap[Yt]=St},"handleTagDirective")};function he(b,ft,Tt,At){if(ft<Tt){let St=b.input.slice(ft,Tt);if(At)for(let Yt=0,G=St.length;Yt<G;Yt+=1){let mt=St.charCodeAt(Yt);if(!(mt===9||mt>=32&&mt<=1114111))et(b,"expected valid JSON character")}else if(x.test(St))et(b,"the stream contains non-printable characters");b.result+=St}}t(he,"captureSegment");function Ut(b,ft,Tt,At){if(!r.isObject(Tt))et(b,"cannot merge mappings; the provided source object is unacceptable");let St=Object.keys(Tt);for(let Yt=0,G=St.length;Yt<G;Yt+=1){let mt=St[Yt];if(b.maxTotalMergeKeys!==-1&&++b.totalMergeKeys>b.maxTotalMergeKeys)et(b,"merge keys exceeded maxTotalMergeKeys ("+b.maxTotalMergeKeys+")");if(!s.call(ft,mt))kt(ft,mt,Tt[mt]),At[mt]=!0}}t(Ut,"mergeMappings");function re(b,ft,Tt,At,St,Yt,G,mt,Dt){if(Array.isArray(St)){St=Array.prototype.slice.call(St);for(let Ft=0,Mt=St.length;Ft<Mt;Ft+=1){if(Array.isArray(St[Ft]))et(b,"nested arrays are not supported inside keys");if(typeof St==="object"&&W(St[Ft])==="[object Object]")St[Ft]="[object Object]"}}if(typeof St==="object"&&W(St)==="[object Object]")St="[object Object]";if(St=String(St),ft===null)ft={};if(At==="tag:yaml.org,2002:merge")if(Array.isArray(Yt))for(let Ft=0,Mt=Yt.length;Ft<Mt;Ft+=1)Ut(b,ft,Yt[Ft],Tt);else Ut(b,ft,Yt,Tt);else{if(!b.json&&!s.call(Tt,St)&&s.call(ft,St))b.line=G||b.line,b.lineStart=mt||b.lineStart,b.position=Dt||b.position,et(b,"duplicated mapping key");kt(ft,St,Yt),delete Tt[St]}return ft}t(re,"storeMappingPair");function ae(b){let ft=b.input.charCodeAt(b.position);if(ft===10)b.position++;else if(ft===13){if(b.position++,b.input.charCodeAt(b.position)===10)b.position++}else et(b,"a line break is expected");b.line+=1,b.lineStart=b.position,b.firstTabInLine=-1}t(ae,"readLineBreak");function ne(b,ft,Tt){let At=0,St=b.input.charCodeAt(b.position);while(St!==0){while(V(St)){if(St===9&&b.firstTabInLine===-1)b.firstTabInLine=b.position;St=b.input.charCodeAt(++b.position)}if(ft&&St===35)do St=b.input.charCodeAt(++b.position);while(St!==10&&St!==13&&St!==0);if(U(St)){ae(b),St=b.input.charCodeAt(b.position),At++,b.lineIndent=0;while(St===32)b.lineIndent++,St=b.input.charCodeAt(++b.position)}else break}if(Tt!==-1&&At!==0&&b.lineIndent<Tt)wt(b,"deficient indentation");return At}t(ne,"skipSeparationSpace");function Be(b){let ft=b.position,Tt=b.input.charCodeAt(ft);if((Tt===45||Tt===46)&&Tt===b.input.charCodeAt(ft+1)&&Tt===b.input.charCodeAt(ft+2)){if(ft+=3,Tt=b.input.charCodeAt(ft),Tt===0||Z(Tt))return!0}return!1}t(Be,"testDocumentSeparator");function _e(b,ft){if(ft===1)b.result+=" ";else if(ft>1)b.result+=r.repeat(`
|
|
138
|
+
`,ft-1)}t(_e,"writeFoldedLines");function Dr(b,ft,Tt){let At,St,Yt,G,mt,Dt,{kind:Ft,result:Mt}=b,Ht=b.input.charCodeAt(b.position);if(Z(Ht)||tt(Ht)||Ht===35||Ht===38||Ht===42||Ht===33||Ht===124||Ht===62||Ht===39||Ht===34||Ht===37||Ht===64||Ht===96)return!1;if(Ht===63||Ht===45){let Wt=b.input.charCodeAt(b.position+1);if(Z(Wt)||Tt&&tt(Wt))return!1}b.kind="scalar",b.result="",At=St=b.position,Yt=!1;while(Ht!==0){if(Ht===58){let Wt=b.input.charCodeAt(b.position+1);if(Z(Wt)||Tt&&tt(Wt))break}else if(Ht===35){let Wt=b.input.charCodeAt(b.position-1);if(Z(Wt))break}else if(b.position===b.lineStart&&Be(b)||Tt&&tt(Ht))break;else if(U(Ht))if(G=b.line,mt=b.lineStart,Dt=b.lineIndent,ne(b,!1,-1),b.lineIndent>=ft){Yt=!0,Ht=b.input.charCodeAt(b.position);continue}else{b.position=St,b.line=G,b.lineStart=mt,b.lineIndent=Dt;break}if(Yt)he(b,At,St,!1),_e(b,b.line-G),At=St=b.position,Yt=!1;if(!V(Ht))St=b.position+1;Ht=b.input.charCodeAt(++b.position)}if(he(b,At,St,!1),b.result)return!0;return b.kind=Ft,b.result=Mt,!1}t(Dr,"readPlainScalar");function di(b,ft){let Tt,At,St=b.input.charCodeAt(b.position);if(St!==39)return!1;b.kind="scalar",b.result="",b.position++,Tt=At=b.position;while((St=b.input.charCodeAt(b.position))!==0)if(St===39)if(he(b,Tt,b.position,!0),St=b.input.charCodeAt(++b.position),St===39)Tt=b.position,b.position++,At=b.position;else return!0;else if(U(St))he(b,Tt,At,!0),_e(b,ne(b,!1,ft)),Tt=At=b.position;else if(b.position===b.lineStart&&Be(b))et(b,"unexpected end of the document within a single quoted scalar");else if(b.position++,!V(St))At=b.position;et(b,"unexpected end of the stream within a single quoted scalar")}t(di,"readSingleQuotedScalar");function Mr(b,ft){let Tt,At,St,Yt=b.input.charCodeAt(b.position);if(Yt!==34)return!1;b.kind="scalar",b.result="",b.position++,Tt=At=b.position;while((Yt=b.input.charCodeAt(b.position))!==0)if(Yt===34)return he(b,Tt,b.position,!0),b.position++,!0;else if(Yt===92){if(he(b,Tt,b.position,!0),Yt=b.input.charCodeAt(++b.position),U(Yt))ne(b,!1,ft);else if(Yt<256&&Ct[Yt])b.result+=rt[Yt],b.position++;else if((St=ot(Yt))>0){let G=St,mt=0;for(;G>0;G--)if(Yt=b.input.charCodeAt(++b.position),(St=at(Yt))>=0)mt=(mt<<4)+St;else et(b,"expected hexadecimal character");b.result+=Bt(mt),b.position++}else et(b,"unknown escape sequence");Tt=At=b.position}else if(U(Yt))he(b,Tt,At,!0),_e(b,ne(b,!1,ft)),Tt=At=b.position;else if(b.position===b.lineStart&&Be(b))et(b,"unexpected end of the document within a double quoted scalar");else if(b.position++,!V(Yt))At=b.position;et(b,"unexpected end of the stream within a double quoted scalar")}t(Mr,"readDoubleQuotedScalar");function Ai(b,ft){let Tt=!0,At,St,Yt,G=b.tag,mt,Dt=b.anchor,Ft,Mt,Ht,Wt,Qt=Object.create(null),Zt,Jt,ee,pe=b.input.charCodeAt(b.position);if(pe===91)Ft=93,Wt=!1,mt=[];else if(pe===123)Ft=125,Wt=!0,mt={};else return!1;if(b.anchor!==null)vt(b,b.anchor,mt);pe=b.input.charCodeAt(++b.position);while(pe!==0){if(ne(b,!0,ft),pe=b.input.charCodeAt(b.position),pe===Ft)return b.position++,b.tag=G,b.anchor=Dt,b.kind=Wt?"mapping":"sequence",b.result=mt,!0;else if(!Tt)et(b,"missed comma between flow collection entries");else if(pe===44)et(b,"expected the node content, but found ','");if(Jt=Zt=ee=null,Mt=Ht=!1,pe===63){let Te=b.input.charCodeAt(b.position+1);if(Z(Te))Mt=Ht=!0,b.position++,ne(b,!0,ft)}if(At=b.line,St=b.lineStart,Yt=b.position,qe(b,ft,n,!1,!0),Jt=b.tag,Zt=b.result,ne(b,!0,ft),pe=b.input.charCodeAt(b.position),(Ht||b.line===At)&&pe===58)Mt=!0,pe=b.input.charCodeAt(++b.position),ne(b,!0,ft),qe(b,ft,n,!1,!0),ee=b.result;if(Wt)re(b,mt,Qt,Jt,Zt,ee,At,St,Yt);else if(Mt)mt.push(re(b,null,Qt,Jt,Zt,ee,At,St,Yt));else mt.push(Zt);if(ne(b,!0,ft),pe=b.input.charCodeAt(b.position),pe===44)Tt=!0,pe=b.input.charCodeAt(++b.position);else Tt=!1}et(b,"unexpected end of the stream within a flow collection")}t(Ai,"readFlowCollection");function Se(b,ft){let Tt,At=m,St=!1,Yt=!1,G=ft,mt=0,Dt=!1,Ft,Mt=b.input.charCodeAt(b.position);if(Mt===124)Tt=!1;else if(Mt===62)Tt=!0;else return!1;b.kind="scalar",b.result="";while(Mt!==0)if(Mt=b.input.charCodeAt(++b.position),Mt===43||Mt===45)if(m===At)At=Mt===43?y:u;else et(b,"repeat of a chomping mode identifier");else if((Ft=ht(Mt))>=0)if(Ft===0)et(b,"bad explicit indentation width of a block scalar; it cannot be less than one");else if(!Yt)G=ft+Ft-1,Yt=!0;else et(b,"repeat of an indentation width identifier");else break;if(V(Mt)){do Mt=b.input.charCodeAt(++b.position);while(V(Mt));if(Mt===35)do Mt=b.input.charCodeAt(++b.position);while(!U(Mt)&&Mt!==0)}while(Mt!==0){ae(b),b.lineIndent=0,Mt=b.input.charCodeAt(b.position);while((!Yt||b.lineIndent<G)&&Mt===32)b.lineIndent++,Mt=b.input.charCodeAt(++b.position);if(!Yt&&b.lineIndent>G)G=b.lineIndent;if(U(Mt)){mt++;continue}if(!Yt&&G===0)et(b,"missing indentation for block scalar");if(b.lineIndent<G){if(At===y)b.result+=r.repeat(`
|
|
139
139
|
`,St?1+mt:mt);else if(At===m){if(St)b.result+=`
|
|
140
140
|
`}break}if(Tt)if(V(Mt))Dt=!0,b.result+=r.repeat(`
|
|
141
141
|
`,St?1+mt:mt);else if(Dt)Dt=!1,b.result+=r.repeat(`
|
|
142
142
|
`,mt+1);else if(mt===0){if(St)b.result+=" "}else b.result+=r.repeat(`
|
|
143
143
|
`,mt);else b.result+=r.repeat(`
|
|
144
|
-
`,St?1+mt:mt);St=!0,Yt=!0,mt=0;let Ht=b.position;while(!
|
|
145
|
-
`;if(b.charCodeAt(0)===65279)b=b.slice(1)}let Tt=new it(b,ft),At=b.indexOf("\x00");if(At!==-1)Tt.position=At,et(Tt,"null byte is not allowed in input");Tt.input+="\x00";while(Tt.input.charCodeAt(Tt.position)===32)Tt.lineIndent+=1,Tt.position+=1;while(Tt.position<Tt.length-1)Wi(Tt);return Tt.documents}t(Xr,"loadDocuments");function gi(b,ft,Tt){if(ft!==null&&typeof ft==="object"&&typeof Tt>"u")Tt=ft,ft=null;let At=Xr(b,Tt);if(typeof ft!=="function")return At;for(let St=0,Yt=At.length;St<Yt;St+=1)ft(At[St])}t(gi,"loadAll2");function mi(b,ft){let Tt=Xr(b,ft);if(Tt.length===0)return;else if(Tt.length===1)return Tt[0];throw new e("expected a single document in the stream, but found more")}return t(mi,"load2"),fl.loadAll=gi,fl.load=mi,fl}t(Yg,"requireLoader");var qu={},Ng;function Ug(){if(Ng)return qu;Ng=1;let r=fs(),e=ds(),o=dl(),a=Object.prototype.toString,s=Object.prototype.hasOwnProperty,n=65279,c=9,l=10,p=13,m=32,u=33,y=34,x=35,k=37,w=38,_=39,M=42,
|
|
144
|
+
`,St?1+mt:mt);St=!0,Yt=!0,mt=0;let Ht=b.position;while(!U(Mt)&&Mt!==0)Mt=b.input.charCodeAt(++b.position);he(b,Ht,b.position,!1)}return!0}t(Se,"readBlockScalar");function Cr(b,ft){let{tag:Tt,anchor:At}=b,St=[],Yt=!1;if(b.firstTabInLine!==-1)return!1;if(b.anchor!==null)vt(b,b.anchor,St);let G=b.input.charCodeAt(b.position);while(G!==0){if(b.firstTabInLine!==-1)b.position=b.firstTabInLine,et(b,"tab characters must not be used in indentation");if(G!==45)break;let mt=b.input.charCodeAt(b.position+1);if(!Z(mt))break;if(Yt=!0,b.position++,ne(b,!0,-1)){if(b.lineIndent<=ft){St.push(null),G=b.input.charCodeAt(b.position);continue}}let Dt=b.line;if(qe(b,ft,l,!1,!0),St.push(b.result),ne(b,!0,-1),G=b.input.charCodeAt(b.position),(b.line===Dt||b.lineIndent>ft)&&G!==0)et(b,"bad indentation of a sequence entry");else if(b.lineIndent<ft)break}if(Yt)return b.tag=Tt,b.anchor=At,b.kind="sequence",b.result=St,!0;return!1}t(Cr,"readBlockSequence");function be(b,ft,Tt){let At,St,Yt,G,{tag:mt,anchor:Dt}=b,Ft={},Mt=Object.create(null),Ht=null,Wt=null,Qt=null,Zt=!1,Jt=!1;if(b.firstTabInLine!==-1)return!1;if(b.anchor!==null)vt(b,b.anchor,Ft);let ee=b.input.charCodeAt(b.position);while(ee!==0){if(!Zt&&b.firstTabInLine!==-1)b.position=b.firstTabInLine,et(b,"tab characters must not be used in indentation");let pe=b.input.charCodeAt(b.position+1),Te=b.line;if((ee===63||ee===58)&&Z(pe)){if(ee===63){if(Zt)re(b,Ft,Mt,Ht,Wt,null,St,Yt,G),Ht=Wt=Qt=null;Jt=!0,Zt=!0,At=!0}else if(Zt)Zt=!1,At=!0;else et(b,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line");b.position+=1,ee=pe}else{if(St=b.line,Yt=b.lineStart,G=b.position,!qe(b,Tt,c,!1,!0))break;if(b.line===Te){ee=b.input.charCodeAt(b.position);while(V(ee))ee=b.input.charCodeAt(++b.position);if(ee===58){if(ee=b.input.charCodeAt(++b.position),!Z(ee))et(b,"a whitespace character is expected after the key-value separator within a block mapping");if(Zt)re(b,Ft,Mt,Ht,Wt,null,St,Yt,G),Ht=Wt=Qt=null;Jt=!0,Zt=!1,At=!1,Ht=b.tag,Wt=b.result}else if(Jt)et(b,"can not read an implicit mapping pair; a colon is missed");else return b.tag=mt,b.anchor=Dt,!0}else if(Jt)et(b,"can not read a block mapping entry; a multiline key may not be an implicit key");else return b.tag=mt,b.anchor=Dt,!0}if(b.line===Te||b.lineIndent>ft){if(Zt)St=b.line,Yt=b.lineStart,G=b.position;if(qe(b,ft,p,!0,At))if(Zt)Wt=b.result;else Qt=b.result;if(!Zt)re(b,Ft,Mt,Ht,Wt,Qt,St,Yt,G),Ht=Wt=Qt=null;ne(b,!0,-1),ee=b.input.charCodeAt(b.position)}if((b.line===Te||b.lineIndent>ft)&&ee!==0)et(b,"bad indentation of a mapping entry");else if(b.lineIndent<ft)break}if(Zt)re(b,Ft,Mt,Ht,Wt,null,St,Yt,G);if(Jt)b.tag=mt,b.anchor=Dt,b.kind="mapping",b.result=Ft;return Jt}t(be,"readBlockMapping");function pi(b){let ft=!1,Tt=!1,At,St,Yt=b.input.charCodeAt(b.position);if(Yt!==33)return!1;if(b.tag!==null)et(b,"duplication of a tag property");if(Yt=b.input.charCodeAt(++b.position),Yt===60)ft=!0,Yt=b.input.charCodeAt(++b.position);else if(Yt===33)Tt=!0,At="!!",Yt=b.input.charCodeAt(++b.position);else At="!";let G=b.position;if(ft){do Yt=b.input.charCodeAt(++b.position);while(Yt!==0&&Yt!==62);if(b.position<b.length)St=b.input.slice(G,b.position),Yt=b.input.charCodeAt(++b.position);else et(b,"unexpected end of the stream within a verbatim tag")}else{while(Yt!==0&&!Z(Yt)){if(Yt===33)if(!Tt){if(At=b.input.slice(G-1,b.position+1),!_.test(At))et(b,"named tag handle cannot contain such characters");Tt=!0,G=b.position+1}else et(b,"tag suffix cannot contain exclamation marks");Yt=b.input.charCodeAt(++b.position)}if(St=b.input.slice(G,b.position),w.test(St))et(b,"tag suffix cannot contain flow indicator characters")}if(St&&!M.test(St))et(b,"tag name cannot contain such characters: "+St);try{St=decodeURIComponent(St)}catch(mt){et(b,"tag name is malformed: "+St)}if(ft)b.tag=St;else if(s.call(b.tagMap,At))b.tag=b.tagMap[At]+St;else if(At==="!")b.tag="!"+St;else if(At==="!!")b.tag="tag:yaml.org,2002:"+St;else et(b,'undeclared tag handle "'+At+'"');return!0}t(pi,"readTagProperty");function Qe(b){let ft=b.input.charCodeAt(b.position);if(ft!==38)return!1;if(b.anchor!==null)et(b,"duplication of an anchor property");ft=b.input.charCodeAt(++b.position);let Tt=b.position;while(ft!==0&&!Z(ft)&&!tt(ft))ft=b.input.charCodeAt(++b.position);if(b.position===Tt)et(b,"name of an anchor node must contain at least one character");return b.anchor=b.input.slice(Tt,b.position),!0}t(Qe,"readAnchorProperty");function Er(b){let ft=b.input.charCodeAt(b.position);if(ft!==42)return!1;ft=b.input.charCodeAt(++b.position);let Tt=b.position;while(ft!==0&&!Z(ft)&&!tt(ft))ft=b.input.charCodeAt(++b.position);if(b.position===Tt)et(b,"name of an alias node must contain at least one character");let At=b.input.slice(Tt,b.position);if(!s.call(b.anchorMap,At))et(b,'unidentified alias "'+At+'"');return b.result=b.anchorMap[At],ne(b,!0,-1),!0}t(Er,"readAlias");function qi(b,ft,Tt,At){let St=oe(b);if(Xt(b),de(b,ft),b.tag=null,b.anchor=null,b.kind=null,b.result=null,be(b,Tt,At)&&b.kind==="mapping")return jt(b),!0;return se(b),de(b,St),!1}t(qi,"tryReadBlockMappingFromProperty");function qe(b,ft,Tt,At,St){let Yt,G,mt=1,Dt=!1,Ft=!1,Mt=null,Ht,Wt,Qt;if(b.depth>=b.maxDepth)et(b,"nesting exceeded maxDepth ("+b.maxDepth+")");if(b.depth+=1,b.listener!==null)b.listener("open",b);b.tag=null,b.anchor=null,b.kind=null,b.result=null;let Zt=Yt=G=p===Tt||l===Tt;if(At){if(ne(b,!0,-1)){if(Dt=!0,b.lineIndent>ft)mt=1;else if(b.lineIndent===ft)mt=0;else if(b.lineIndent<ft)mt=-1}}if(mt===1)while(!0){let Jt=b.input.charCodeAt(b.position),ee=oe(b);if(Dt&&(Jt===33&&b.tag!==null||Jt===38&&b.anchor!==null))break;if(!pi(b)&&!Qe(b))break;if(Mt===null)Mt=ee;if(ne(b,!0,-1)){if(Dt=!0,G=Zt,b.lineIndent>ft)mt=1;else if(b.lineIndent===ft)mt=0;else if(b.lineIndent<ft)mt=-1}else G=!1}if(G)G=Dt||St;if(mt===1||p===Tt){if(n===Tt||c===Tt)Wt=ft;else Wt=ft+1;if(Qt=b.position-b.lineStart,mt===1)if(G&&(Cr(b,Qt)||be(b,Qt,Wt))||Ai(b,Wt))Ft=!0;else{let Jt=b.input.charCodeAt(b.position);if(Mt!==null&&Zt&&!G&&Jt!==124&&Jt!==62&&qi(b,Mt,Mt.position-Mt.lineStart,Wt))Ft=!0;else if(Yt&&Se(b,Wt)||di(b,Wt)||Mr(b,Wt))Ft=!0;else if(Er(b)){if(Ft=!0,b.tag!==null||b.anchor!==null)et(b,"alias node should not have any properties")}else if(Dr(b,Wt,n===Tt)){if(Ft=!0,b.tag===null)b.tag="?"}if(b.anchor!==null)vt(b,b.anchor,b.result)}else if(mt===0)Ft=G&&Cr(b,Qt)}if(b.tag===null){if(b.anchor!==null)vt(b,b.anchor,b.result)}else if(b.tag==="?"){if(b.result!==null&&b.kind!=="scalar")et(b,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+b.kind+'"');for(let Jt=0,ee=b.implicitTypes.length;Jt<ee;Jt+=1)if(Ht=b.implicitTypes[Jt],Ht.resolve(b.result)){if(b.result=Ht.construct(b.result),b.tag=Ht.tag,b.anchor!==null)vt(b,b.anchor,b.result);break}}else if(b.tag!=="!"){if(s.call(b.typeMap[b.kind||"fallback"],b.tag))Ht=b.typeMap[b.kind||"fallback"][b.tag];else{Ht=null;let Jt=b.typeMap.multi[b.kind||"fallback"];for(let ee=0,pe=Jt.length;ee<pe;ee+=1)if(b.tag.slice(0,Jt[ee].tag.length)===Jt[ee].tag){Ht=Jt[ee];break}}if(!Ht)et(b,"unknown tag !<"+b.tag+">");if(b.result!==null&&Ht.kind!==b.kind)et(b,"unacceptable node kind for !<"+b.tag+'> tag; it should be "'+Ht.kind+'", not "'+b.kind+'"');if(!Ht.resolve(b.result,b.tag))et(b,"cannot resolve a node with !<"+b.tag+"> explicit tag");else if(b.result=Ht.construct(b.result,b.tag),b.anchor!==null)vt(b,b.anchor,b.result)}if(b.listener!==null)b.listener("close",b);return b.depth-=1,b.tag!==null||b.anchor!==null||Ft}t(qe,"composeNode");function Wi(b){let ft=b.position,Tt=!1,At;b.version=null,b.checkLineBreaks=b.legacy,b.tagMap=Object.create(null),b.anchorMap=Object.create(null);while((At=b.input.charCodeAt(b.position))!==0){if(ne(b,!0,-1),At=b.input.charCodeAt(b.position),b.lineIndent>0||At!==37)break;Tt=!0,At=b.input.charCodeAt(++b.position);let St=b.position;while(At!==0&&!Z(At))At=b.input.charCodeAt(++b.position);let Yt=b.input.slice(St,b.position),G=[];if(Yt.length<1)et(b,"directive name must not be less than one character in length");while(At!==0){while(V(At))At=b.input.charCodeAt(++b.position);if(At===35){do At=b.input.charCodeAt(++b.position);while(At!==0&&!U(At));break}if(U(At))break;St=b.position;while(At!==0&&!Z(At))At=b.input.charCodeAt(++b.position);G.push(b.input.slice(St,b.position))}if(At!==0)ae(b);if(s.call(ge,Yt))ge[Yt](b,Yt,G);else wt(b,'unknown document directive "'+Yt+'"')}if(ne(b,!0,-1),b.lineIndent===0&&b.input.charCodeAt(b.position)===45&&b.input.charCodeAt(b.position+1)===45&&b.input.charCodeAt(b.position+2)===45)b.position+=3,ne(b,!0,-1);else if(Tt)et(b,"directives end mark is expected");if(qe(b,b.lineIndent-1,p,!1,!0),ne(b,!0,-1),b.checkLineBreaks&&k.test(b.input.slice(ft,b.position)))wt(b,"non-ASCII line breaks are interpreted as content");if(b.documents.push(b.result),b.position===b.lineStart&&Be(b)){if(b.input.charCodeAt(b.position)===46)b.position+=3,ne(b,!0,-1);return}if(b.position<b.length-1)et(b,"end of the stream or a document separator is expected")}t(Wi,"readDocument");function Xr(b,ft){if(b=String(b),ft=ft||{},b.length!==0){if(b.charCodeAt(b.length-1)!==10&&b.charCodeAt(b.length-1)!==13)b+=`
|
|
145
|
+
`;if(b.charCodeAt(0)===65279)b=b.slice(1)}let Tt=new it(b,ft),At=b.indexOf("\x00");if(At!==-1)Tt.position=At,et(Tt,"null byte is not allowed in input");Tt.input+="\x00";while(Tt.input.charCodeAt(Tt.position)===32)Tt.lineIndent+=1,Tt.position+=1;while(Tt.position<Tt.length-1)Wi(Tt);return Tt.documents}t(Xr,"loadDocuments");function gi(b,ft,Tt){if(ft!==null&&typeof ft==="object"&&typeof Tt>"u")Tt=ft,ft=null;let At=Xr(b,Tt);if(typeof ft!=="function")return At;for(let St=0,Yt=At.length;St<Yt;St+=1)ft(At[St])}t(gi,"loadAll2");function mi(b,ft){let Tt=Xr(b,ft);if(Tt.length===0)return;else if(Tt.length===1)return Tt[0];throw new e("expected a single document in the stream, but found more")}return t(mi,"load2"),fl.loadAll=gi,fl.load=mi,fl}t(Yg,"requireLoader");var qu={},Ng;function Ug(){if(Ng)return qu;Ng=1;let r=fs(),e=ds(),o=dl(),a=Object.prototype.toString,s=Object.prototype.hasOwnProperty,n=65279,c=9,l=10,p=13,m=32,u=33,y=34,x=35,k=37,w=38,_=39,M=42,W=44,U=45,V=58,Z=61,tt=62,at=63,ot=64,ht=91,yt=93,Bt=96,kt=123,Ct=124,rt=125,it={};it[0]="\\0",it[7]="\\a",it[8]="\\b",it[9]="\\t",it[10]="\\n",it[11]="\\v",it[12]="\\f",it[13]="\\r",it[27]="\\e",it[34]="\\\"",it[92]="\\\\",it[133]="\\N",it[160]="\\_",it[8232]="\\L",it[8233]="\\P";let gt=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],et=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function wt(G,mt){if(mt===null)return{};let Dt={},Ft=Object.keys(mt);for(let Mt=0,Ht=Ft.length;Mt<Ht;Mt+=1){let Wt=Ft[Mt],Qt=String(mt[Wt]);if(Wt.slice(0,2)==="!!")Wt="tag:yaml.org,2002:"+Wt.slice(2);let Zt=G.compiledTypeMap.fallback[Wt];if(Zt&&s.call(Zt.styleAliases,Qt))Qt=Zt.styleAliases[Qt];Dt[Wt]=Qt}return Dt}t(wt,"compileStyleMap");function vt(G){let mt,Dt,Ft=G.toString(16).toUpperCase();if(G<=255)mt="x",Dt=2;else if(G<=65535)mt="u",Dt=4;else if(G<=4294967295)mt="U",Dt=8;else throw new e("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+mt+r.repeat("0",Dt-Ft.length)+Ft}t(vt,"encodeHex");let Xt=1,jt=2;function se(G){this.schema=G.schema||o,this.indent=Math.max(1,G.indent||2),this.noArrayIndent=G.noArrayIndent||!1,this.skipInvalid=G.skipInvalid||!1,this.flowLevel=r.isNothing(G.flowLevel)?-1:G.flowLevel,this.styleMap=wt(this.schema,G.styles||null),this.sortKeys=G.sortKeys||!1,this.lineWidth=G.lineWidth||80,this.noRefs=G.noRefs||!1,this.noCompatMode=G.noCompatMode||!1,this.condenseFlow=G.condenseFlow||!1,this.quotingType=G.quotingType==='"'?jt:Xt,this.forceQuotes=G.forceQuotes||!1,this.replacer=typeof G.replacer==="function"?G.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}t(se,"State");function oe(G,mt){let Dt=r.repeat(" ",mt),Ft=0,Mt="",Ht=G.length;while(Ft<Ht){let Wt,Qt=G.indexOf(`
|
|
146
146
|
`,Ft);if(Qt===-1)Wt=G.slice(Ft),Ft=Ht;else Wt=G.slice(Ft,Qt+1),Ft=Qt+1;if(Wt.length&&Wt!==`
|
|
147
|
-
`)Mt+=Dt;Mt+=Wt}return Mt}t(oe,"indentString");function
|
|
148
|
-
`+r.repeat(" ",G.indent*mt)}t(
|
|
147
|
+
`)Mt+=Dt;Mt+=Wt}return Mt}t(oe,"indentString");function de(G,mt){return`
|
|
148
|
+
`+r.repeat(" ",G.indent*mt)}t(de,"generateNextLine");function ge(G,mt){for(let Dt=0,Ft=G.implicitTypes.length;Dt<Ft;Dt+=1)if(G.implicitTypes[Dt].resolve(mt))return!0;return!1}t(ge,"testImplicitResolving");function he(G){return G===m||G===c}t(he,"isWhitespace");function Ut(G){return G>=32&&G<=126||G>=161&&G<=55295&&G!==8232&&G!==8233||G>=57344&&G<=65533&&G!==n||G>=65536&&G<=1114111}t(Ut,"isPrintable");function re(G){return Ut(G)&&G!==n&&G!==p&&G!==l}t(re,"isNsCharOrWhitespace");function ae(G,mt,Dt){let Ft=re(G),Mt=Ft&&!he(G);return(Dt?Ft:Ft&&G!==W&&G!==ht&&G!==yt&&G!==kt&&G!==rt)&&G!==x&&!(mt===V&&!Mt)||re(mt)&&!he(mt)&&G===x||mt===V&&Mt}t(ae,"isPlainSafe");function ne(G){return Ut(G)&&G!==n&&!he(G)&&G!==U&&G!==at&&G!==V&&G!==W&&G!==ht&&G!==yt&&G!==kt&&G!==rt&&G!==x&&G!==w&&G!==M&&G!==u&&G!==Ct&&G!==Z&&G!==tt&&G!==_&&G!==y&&G!==k&&G!==ot&&G!==Bt}t(ne,"isPlainSafeFirst");function Be(G){return!he(G)&&G!==V}t(Be,"isPlainSafeLast");function _e(G,mt){let Dt=G.charCodeAt(mt),Ft;if(Dt>=55296&&Dt<=56319&&mt+1<G.length){if(Ft=G.charCodeAt(mt+1),Ft>=56320&&Ft<=57343)return(Dt-55296)*1024+Ft-56320+65536}return Dt}t(_e,"codePointAt");function Dr(G){return/^\n* /.test(G)}t(Dr,"needIndentIndicator");let di=1,Mr=2,Ai=3,Se=4,Cr=5;function be(G,mt,Dt,Ft,Mt,Ht,Wt,Qt){let Zt,Jt=0,ee=null,pe=!1,Te=!1,Ts=Ft!==-1,zi=-1,Hi=ne(_e(G,0))&&Be(_e(G,G.length-1));if(mt||Wt)for(Zt=0;Zt<G.length;Jt>=65536?Zt+=2:Zt++){if(Jt=_e(G,Zt),!Ut(Jt))return Cr;Hi=Hi&&ae(Jt,ee,Qt),ee=Jt}else{for(Zt=0;Zt<G.length;Jt>=65536?Zt+=2:Zt++){if(Jt=_e(G,Zt),Jt===l){if(pe=!0,Ts)Te=Te||Zt-zi-1>Ft&&G[zi+1]!==" ",zi=Zt}else if(!Ut(Jt))return Cr;Hi=Hi&&ae(Jt,ee,Qt),ee=Jt}Te=Te||Ts&&(Zt-zi-1>Ft&&G[zi+1]!==" ")}if(!pe&&!Te){if(Hi&&!Wt&&!Mt(G))return di;return Ht===jt?Cr:Mr}if(Dt>9&&Dr(G))return Cr;if(!Wt)return Te?Se:Ai;return Ht===jt?Cr:Mr}t(be,"chooseScalarStyle");function pi(G,mt,Dt,Ft,Mt){G.dump=function(){if(mt.length===0)return G.quotingType===jt?'""':"''";if(!G.noCompatMode){if(gt.indexOf(mt)!==-1||et.test(mt))return G.quotingType===jt?'"'+mt+'"':"'"+mt+"'"}let Ht=G.indent*Math.max(1,Dt),Wt=G.lineWidth===-1?-1:Math.max(Math.min(G.lineWidth,40),G.lineWidth-Ht),Qt=Ft||G.flowLevel>-1&&Dt>=G.flowLevel;function Zt(Jt){return ge(G,Jt)}switch(t(Zt,"testAmbiguity"),be(mt,Qt,G.indent,Wt,Zt,G.quotingType,G.forceQuotes&&!Ft,Mt)){case di:return mt;case Mr:return"'"+mt.replace(/'/g,"''")+"'";case Ai:return"|"+Qe(mt,G.indent)+Er(oe(mt,Ht));case Se:return">"+Qe(mt,G.indent)+Er(oe(qi(mt,Wt),Ht));case Cr:return'"'+Wi(mt)+'"';default:throw new e("impossible error: invalid scalar style")}}()}t(pi,"writeScalar");function Qe(G,mt){let Dt=Dr(G)?String(mt):"",Ft=G[G.length-1]===`
|
|
149
149
|
`,Ht=Ft&&(G[G.length-2]===`
|
|
150
150
|
`||G===`
|
|
151
151
|
`)?"+":Ft?"":"-";return Dt+Ht+`
|
|
152
152
|
`}t(Qe,"blockHeader");function Er(G){return G[G.length-1]===`
|
|
153
153
|
`?G.slice(0,-1):G}t(Er,"dropEndingNewline");function qi(G,mt){let Dt=/(\n+)([^\n]*)/g,Ft=function(){let Qt=G.indexOf(`
|
|
154
|
-
`);return Qt=Qt!==-1?Qt:G.length,Dt.lastIndex=Qt,
|
|
154
|
+
`);return Qt=Qt!==-1?Qt:G.length,Dt.lastIndex=Qt,qe(G.slice(0,Qt),mt)}(),Mt=G[0]===`
|
|
155
155
|
`||G[0]===" ",Ht,Wt;while(Wt=Dt.exec(G)){let Qt=Wt[1],Zt=Wt[2];Ht=Zt[0]===" ",Ft+=Qt+(!Mt&&!Ht&&Zt!==""?`
|
|
156
|
-
`:"")+
|
|
156
|
+
`:"")+qe(Zt,mt),Mt=Ht}return Ft}t(qi,"foldString");function qe(G,mt){if(G===""||G[0]===" ")return G;let Dt=/ [^ ]/g,Ft,Mt=0,Ht,Wt=0,Qt=0,Zt="";while(Ft=Dt.exec(G)){if(Qt=Ft.index,Qt-Mt>mt)Ht=Wt>Mt?Wt:Qt,Zt+=`
|
|
157
157
|
`+G.slice(Mt,Ht),Mt=Ht+1;Wt=Qt}if(Zt+=`
|
|
158
158
|
`,G.length-Mt>mt&&Wt>Mt)Zt+=G.slice(Mt,Wt)+`
|
|
159
|
-
`+G.slice(Wt+1);else Zt+=G.slice(Mt);return Zt.slice(1)}t(
|
|
160
|
-
`;return""}return t(Yt,"dump2"),qu.dump=Yt,qu}t(Ug,"requireDumper");var Wg;function jg(){if(Wg)return lr;Wg=1;let r=Yg(),e=Ug();function o(a,s){return function(){throw Error("Function yaml."+a+" is removed in js-yaml 4. Use yaml."+s+" instead, which is now safe by default.")}}return t(o,"renamed"),lr.Type=cr(),lr.Schema=Nu(),lr.FAILSAFE_SCHEMA=Yu(),lr.JSON_SCHEMA=Vu(),lr.CORE_SCHEMA=Ku(),lr.DEFAULT_SCHEMA=dl(),lr.load=r.load,lr.loadAll=r.loadAll,lr.dump=e.dump,lr.YAMLException=ds(),lr.types={binary:Ju(),float:Xu(),map:Hu(),null:Uu(),pairs:ef(),set:rf(),timestamp:Zu(),bool:ju(),int:Gu(),merge:Qu(),omap:tf(),seq:zu(),str:Wu()},lr.safeLoad=o("safeLoad","load"),lr.safeLoadAll=o("safeLoadAll","loadAll"),lr.safeDump=o("safeDump","dump"),lr}t(jg,"requireJsYaml");var t2=jg(),e2=zg(t2),{Type:I3,Schema:$3,FAILSAFE_SCHEMA:D3,JSON_SCHEMA:qt,CORE_SCHEMA:P3,DEFAULT_SCHEMA:R3,load:Vt,loadAll:q3,dump:N3,YAMLException:W3,types:z3,safeLoad:H3,safeLoadAll:Y3,safeDump:U3}=e2;var Eo=t((r,e)=>{let{theme:o,themeVariables:a}=e,{useGradient:s,gradientStart:n,gradientStop:c}=a??{},l=r.attr("id"),p=o?.includes("dark")?"#FFFFFF":"#000000",m=t((y,x,k)=>r.append("defs").append("filter").attr("id",y).attr("height",x).attr("width",x).append("feDropShadow").attr("dx",k).attr("dy",k).attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",p),"dropShadow");if(m(`${l}-drop-shadow`,"130%","4"),m(`${l}-drop-shadow-small`,"150%","2"),!s)return;let u=r.append("linearGradient").attr("id",`${l}-gradient`).attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");u.append("svg:stop").attr("offset","0%").attr("stop-color",n).attr("stop-opacity",1),u.append("svg:stop").attr("offset","100%").attr("stop-color",c).attr("stop-opacity",1)},"insertLookDefs");var Gg=t((r)=>{let{handDrawnSeed:e}=d();return{fill:r,hachureAngle:120,hachureGap:1.5,fillWeight:1.5,roughness:0.7,stroke:r,seed:e}},"solidStateFill"),r2=t((r)=>{if(Array.isArray(r))return r;if(!r)return[];return r.split(";").map((e)=>e.trim()).filter(Boolean)},"normalizeStyleList"),ai=t((r)=>{let e=i2([...r.cssCompiledStyles||[],...r.cssStyles||[],...r2(r.labelStyle)]);return{stylesMap:e,stylesArray:[...e]}},"compileStyles"),i2=t((r)=>{let e=new Map;return r.forEach((o)=>{let[a,s]=o.split(":");e.set(a.trim(),s?.trim())}),e},"styles2Map"),Pi=t((r)=>r==="color"||r==="font-size"||r==="font-family"||r==="font-weight"||r==="font-style"||r==="text-decoration"||r==="text-align"||r==="text-transform"||r==="line-height"||r==="letter-spacing"||r==="word-spacing"||r==="text-shadow"||r==="text-overflow"||r==="white-space"||r==="word-wrap"||r==="word-break"||r==="overflow-wrap"||r==="hyphens","isLabelStyle"),E=t((r)=>{let{stylesArray:e}=ai(r),o=[],a=[],s=[],n=[];return e.forEach((c)=>{let l=c[0];if(Pi(l))o.push(c.join(":")+" !important");else{if(a.push(c.join(":")+" !important"),l.includes("stroke"))s.push(c.join(":")+" !important");if(l==="fill")n.push(c.join(":")+" !important")}}),{labelStyles:o.join(";"),nodeStyles:a.join(";"),stylesArray:e,borderStyles:s,backgroundStyles:n}},"styles2String"),Kt=t((r,e)=>{let{themeVariables:o,handDrawnSeed:a}=d(),{nodeBorder:s,mainBkg:n}=o,{stylesMap:c}=ai(r);return Object.assign({roughness:0.7,fill:c.get("fill")||n,fillStyle:"hachure",fillWeight:1.5,hachureGap:1.5,stroke:c.get("stroke")||s,seed:a,strokeWidth:c.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0],strokeLineDash:o2(c.get("stroke-dasharray"))},e)},"userNodeOverrides"),o2=t((r)=>{if(!r)return[0,0];let e=r.trim().split(/\s+/).map(Number);if(e.length===1){let s=isNaN(e[0])?0:e[0];return[s,s]}let o=isNaN(e[0])?0:e[0],a=isNaN(e[1])?0:e[1];return[o,a]},"getStrokeDashArray");var of=(r,e,o,a="")=>{let s=r.split(":");if(r.slice(0,1)==="@"){if(s.length<2||s.length>3)return null;a=s.shift().slice(1)}if(s.length>3||!s.length)return null;if(s.length>1){let l=s.pop(),p=s.pop(),m={provider:s.length>0?s[0]:a,prefix:p,name:l};return e&&!pl(m)?null:m}let n=s[0],c=n.split("-");if(c.length>1){let l={provider:a,prefix:c.shift(),name:c.join("-")};return e&&!pl(l)?null:l}if(o&&a===""){let l={provider:a,prefix:"",name:n};return e&&!pl(l,o)?null:l}return null},pl=(r,e)=>{if(!r)return!1;return!!((e&&r.prefix===""||!!r.prefix)&&!!r.name)};var s2=Object.freeze({left:0,top:0,width:16,height:16}),ps=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),sf=Object.freeze({...s2,...ps}),Xg=Object.freeze({...sf,body:"",hidden:!1});function Vg(r,e){let o={};if(!r.hFlip!==!e.hFlip)o.hFlip=!0;if(!r.vFlip!==!e.vFlip)o.vFlip=!0;let a=((r.rotate||0)+(e.rotate||0))%4;if(a)o.rotate=a;return o}function af(r,e){let o=Vg(r,e);for(let a in Xg)if(a in ps){if(a in r&&!(a in o))o[a]=ps[a]}else if(a in e)o[a]=e[a];else if(a in r)o[a]=r[a];return o}function Kg(r,e){let o=r.icons,a=r.aliases||Object.create(null),s=Object.create(null);function n(c){if(o[c])return s[c]=[];if(!(c in s)){s[c]=null;let l=a[c]&&a[c].parent,p=l&&n(l);if(p)s[c]=[l].concat(p)}return s[c]}return(e||Object.keys(o).concat(Object.keys(a))).forEach(n),s}function Zg(r,e,o){let a=r.icons,s=r.aliases||Object.create(null),n={};function c(l){n=af(a[l]||s[l],n)}return c(e),o.forEach(c),af(r,n)}function nf(r,e){if(r.icons[e])return Zg(r,e,[]);let o=Kg(r,[e])[e];return o?Zg(r,e,o):null}var a2=Object.freeze({width:null,height:null}),Qg=Object.freeze({...a2,...ps});var n2=/(-?[0-9.]*[0-9]+[0-9.]*)/g,l2=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function lf(r,e,o){if(e===1)return r;if(o=o||100,typeof r==="number")return Math.ceil(r*e*o)/o;if(typeof r!=="string")return r;let a=r.split(n2);if(a===null||!a.length)return r;let s=[],n=a.shift(),c=l2.test(n);while(!0){if(c){let l=parseFloat(n);if(isNaN(l))s.push(n);else s.push(Math.ceil(l*e*o)/o)}else s.push(n);if(n=a.shift(),n===void 0)return s.join("");c=!c}}function h2(r,e="defs"){let o="",a=r.indexOf("<"+e);while(a>=0){let s=r.indexOf(">",a),n=r.indexOf("</"+e);if(s===-1||n===-1)break;let c=r.indexOf(">",n);if(c===-1)break;o+=r.slice(s+1,n).trim(),r=r.slice(0,a).trim()+r.slice(c+1)}return{defs:o,content:r}}function c2(r,e){return r?"<defs>"+r+"</defs>"+e:e}function Jg(r,e,o){let a=h2(r);return c2(a.defs,e+a.content+o)}var u2=(r)=>r==="unset"||r==="undefined"||r==="none";function hf(r,e){let o={...sf,...r},a={...Qg,...e},s={left:o.left,top:o.top,width:o.width,height:o.height},n=o.body;[o,a].forEach((_)=>{let M=[],{hFlip:q,vFlip:Y,rotate:V}=_;if(q)if(Y)V+=2;else M.push("translate("+(s.width+s.left).toString()+" "+(0-s.top).toString()+")"),M.push("scale(-1 1)"),s.top=s.left=0;else if(Y)M.push("translate("+(0-s.left).toString()+" "+(s.height+s.top).toString()+")"),M.push("scale(1 -1)"),s.top=s.left=0;let Q;if(V<0)V-=Math.floor(V/4)*4;switch(V=V%4,V){case 1:Q=s.height/2+s.top,M.unshift("rotate(90 "+Q.toString()+" "+Q.toString()+")");break;case 2:M.unshift("rotate(180 "+(s.width/2+s.left).toString()+" "+(s.height/2+s.top).toString()+")");break;case 3:Q=s.width/2+s.left,M.unshift("rotate(-90 "+Q.toString()+" "+Q.toString()+")")}if(V%2===1){if(s.left!==s.top)Q=s.left,s.left=s.top,s.top=Q;if(s.width!==s.height)Q=s.width,s.width=s.height,s.height=Q}if(M.length)n=Jg(n,'<g transform="'+M.join(" ")+'">',"</g>")});let{width:c,height:l}=a,{width:p,height:m}=s,u,y;if(c===null)y=l===null?"1em":l==="auto"?m:l,u=lf(y,p/m);else u=c==="auto"?p:c,y=l===null?lf(u,m/p):l==="auto"?m:l;let x={},k=(_,M)=>{if(!u2(M))x[_]=M.toString()};k("width",u),k("height",y);let w=[s.left,s.top,p,m];return x.viewBox=w.join(" "),{attributes:x,viewBox:w,body:n}}var f2=/\sid="(\S+)"/g,tm=new Map;function d2(r){r=r.replace(/[0-9]+$/,"")||"a";let e=tm.get(r)||0;return tm.set(r,e+1),e?`${r}${e}`:r}function cf(r){let e=[],o;while(o=f2.exec(r))e.push(o[1]);if(!e.length)return r;let a="suffix"+(Math.random()*16777216|Date.now()).toString(16);return e.forEach((s)=>{let n=d2(s),c=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");r=r.replace(new RegExp('([#;"])('+c+')([")]|\\.[a-z])',"g"),"$1"+n+a+"$3")}),r=r.replace(new RegExp(a,"g"),""),r}function uf(r,e){let o=r.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(let a in e)o+=" "+a+'="'+e[a]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+o+">"+r+"</svg>"}var Xs={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},ff=new Map,em=new Map,jr=t((r)=>{for(let e of r){if(!e.name)throw Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(i.debug("Registering icon pack:",e.name),"loader"in e)em.set(e.name,e.loader);else if("icons"in e)ff.set(e.name,e.icons);else throw i.error("Invalid icon loader:",e),Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),rm=t(async(r,e)=>{let o=of(r,!0,e!==void 0);if(!o)throw Error(`Invalid icon name: ${r}`);let a=o.prefix||e;if(!a)throw Error(`Icon name must contain a prefix: ${r}`);let s=ff.get(a);if(!s){let c=em.get(a);if(!c)throw Error(`Icon set not found: ${o.prefix}`);try{s={...await c(),prefix:a},ff.set(a,s)}catch(l){throw i.error(l),Error(`Failed to load icon set: ${o.prefix}`)}}let n=nf(s,o.name);if(!n)throw Error(`Icon not found: ${r}`);return n},"getRegisteredIconData"),gl=t(async(r)=>{try{return await rm(r),!0}catch{return!1}},"isIconAvailable"),Gt=t(async(r,e,o)=>{let a;try{a=await rm(r,e?.fallbackPrefix)}catch(c){i.error(c),a=Xs}let s=hf(a,e),n=uf(cf(s.body),{...s.attributes,...o});return j(n,A())},"getIconSVG");var xm=Ke(la(),1);function ao(r,e){if(typeof r!=="function"||e!=null&&typeof e!=="function")throw TypeError("Expected a function");let o=function(...a){let s=e?e.apply(this,a):a[0],n=o.cache;if(n.has(s))return n.get(s);let c=r.apply(this,a);return o.cache=n.set(s,c)||n,c};return o.cache=new(ao.Cache||Map),o}ao.Cache=Map;function qr(r){return r==null||typeof r!=="object"&&typeof r!=="function"}function gr(r){if(r==null)return r===void 0?"[object Undefined]":"[object Null]";return Object.prototype.toString.call(r)}var Lo="[object RegExp]",Qa="[object String]",Ja="[object Number]",ei="[object Boolean]",ti="[object Arguments]",No="[object Symbol]",Mo="[object Date]",Po="[object Map]",Ro="[object Set]",Io="[object Array]";var Do="[object ArrayBuffer]",Oo="[object Object]";var $o="[object DataView]",Bo="[object Uint8Array]",Fo="[object Uint8ClampedArray]",zo="[object Uint16Array]",Ho="[object Uint32Array]";var Uo="[object Int8Array]",jo="[object Int16Array]",qo="[object Int32Array]";var Vo="[object Float32Array]",Go="[object Float64Array]";function gs(r){return ArrayBuffer.isView(r)&&!(r instanceof DataView)}function vr(r){return gs(r)}function lm(){}function hm(r){if(qr(r))return r;if(Array.isArray(r)||gs(r)||r instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&r instanceof SharedArrayBuffer)return r.slice(0);let e=Object.getPrototypeOf(r);if(e==null)return Object.assign(Object.create(e),r);let o=e.constructor;if(r instanceof Date||r instanceof Map||r instanceof Set)return new o(r);if(r instanceof RegExp){let a=new o(r);return a.lastIndex=r.lastIndex,a}if(r instanceof DataView)return new o(r.buffer.slice(0));if(r instanceof Error){let a;if(r instanceof AggregateError)a=new o(r.errors,r.message,{cause:r.cause});else a=new o(r.message,{cause:r.cause});return a.stack=r.stack,Object.assign(a,r),a}if(typeof File<"u"&&r instanceof File)return new o([r],r.name,{type:r.type,lastModified:r.lastModified});if(typeof r==="object")return Object.assign(Object.create(e),r);return r}function ml(r){return Object.getOwnPropertySymbols(r).filter((e)=>Object.prototype.propertyIsEnumerable.call(r,e))}var df=typeof globalThis==="object"&&globalThis||typeof window==="object"&&window||typeof self==="object"&&self||typeof global==="object"&&global||function(){return this}();function ni(r){return typeof df.Buffer<"u"&&df.Buffer.isBuffer(r)}function cm(r){return r==="__proto__"}function yl(r){if(typeof r!=="object")return!1;if(r==null)return!1;if(Object.getPrototypeOf(r)===null)return!0;if(Object.prototype.toString.call(r)!=="[object Object]"){let o=r[Symbol.toStringTag];if(o==null)return!1;if(!Object.getOwnPropertyDescriptor(r,Symbol.toStringTag)?.writable)return!1;return r.toString()===`[object ${o}]`}let e=r;while(Object.getPrototypeOf(e)!==null)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(r)===e}function um(r,e){return ms(r,void 0,r,new Map,e)}function ms(r,e,o,a=new Map,s=void 0){let n=s?.(r,e,o,a);if(n!==void 0)return n;if(qr(r))return r;if(a.has(r))return a.get(r);if(Array.isArray(r)){let c=Array(r.length);a.set(r,c);for(let l=0;l<r.length;l++)c[l]=ms(r[l],l,o,a,s);if(Object.hasOwn(r,"index"))c.index=r.index;if(Object.hasOwn(r,"input"))c.input=r.input;return c}if(r instanceof Date)return new Date(r.getTime());if(r instanceof RegExp){let c=new RegExp(r.source,r.flags);return c.lastIndex=r.lastIndex,c}if(r instanceof Map){let c=new Map;a.set(r,c);for(let[l,p]of r)c.set(l,ms(p,l,o,a,s));return c}if(r instanceof Set){let c=new Set;a.set(r,c);for(let l of r)c.add(ms(l,void 0,o,a,s));return c}if(ni(r))return r.subarray();if(gs(r)){let c=new(Object.getPrototypeOf(r)).constructor(r.length);a.set(r,c);for(let l=0;l<r.length;l++)c[l]=ms(r[l],l,o,a,s);return c}if(r instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&r instanceof SharedArrayBuffer)return r.slice(0);if(r instanceof DataView){let c=new DataView(r.buffer.slice(0),r.byteOffset,r.byteLength);return a.set(r,c),$r(c,r,o,a,s),c}if(typeof File<"u"&&r instanceof File){let c=new File([r],r.name,{type:r.type});return a.set(r,c),$r(c,r,o,a,s),c}if(typeof Blob<"u"&&r instanceof Blob){let c=new Blob([r],{type:r.type});return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof Error){let c=structuredClone(r);return a.set(r,c),c.message=r.message,c.name=r.name,c.stack=r.stack,c.cause=r.cause,c.constructor=r.constructor,$r(c,r,o,a,s),c}if(r instanceof Boolean){let c=new Boolean(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof Number){let c=new Number(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof String){let c=new String(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(typeof r==="object"&&B2(r)){let c=Object.create(Object.getPrototypeOf(r));return a.set(r,c),$r(c,r,o,a,s),c}return r}function $r(r,e,o=r,a,s){let n=[...Object.keys(e),...ml(e)];for(let c=0;c<n.length;c++){let l=n[c],p=Object.getOwnPropertyDescriptor(r,l);if(p==null||p.writable)r[l]=ms(e[l],l,o,a,s)}}function B2(r){switch(gr(r)){case ti:case Io:case Do:case $o:case ei:case Mo:case Vo:case Go:case Uo:case jo:case qo:case Po:case Ja:case Oo:case Lo:case Ro:case Qa:case No:case Bo:case Fo:case zo:case Ho:return!0;default:return!1}}function fm(r,e){return um(r,(o,a,s,n)=>{let c=e?.(o,a,s,n);if(c!==void 0)return c;if(typeof r!=="object")return;if(gr(r)==="[object Object]"&&typeof r.constructor!=="function"){let l={};return n.set(r,l),$r(l,r,s,n),l}switch(Object.prototype.toString.call(r)){case Ja:case Qa:case ei:{let l=new r.constructor(r?.valueOf());return $r(l,r),l}case ti:{let l={};return $r(l,r),l.length=r.length,l[Symbol.iterator]=r[Symbol.iterator],l}default:return}})}function pf(r){return fm(r)}function Ri(r){return r!==null&&typeof r==="object"&&gr(r)==="[object Arguments]"}function Ia(r){return typeof r==="object"&&r!==null}function dm(r){return Number.isSafeInteger(r)&&r>=0}function Wo(r){return r!=null&&typeof r!=="function"&&dm(r.length)}function pm(r){return Ia(r)&&Wo(r)}function gm(r,...e){let o=e.slice(0,-1),a=e[e.length-1],s=r;for(let n=0;n<o.length;n++){let c=o[n];s=xl(s,c,a,new Map)}return s}function xl(r,e,o,a){if(qr(r))r=Object(r);if(e==null||typeof e!=="object")return r;if(a.has(e))return hm(a.get(e));if(a.set(e,r),Array.isArray(e)){e=e.slice();for(let n=0;n<e.length;n++)if(!(n in e))e[n]=void 0}let s=[...Object.keys(e),...ml(e)];for(let n=0;n<s.length;n++){let c=s[n];if(cm(c))continue;let l=e[c],p=r[c];if(Ri(l))l={...l};if(Ri(p))p={...p};if(ni(l))l=pf(l);if(Array.isArray(l))if(Array.isArray(p)){let u=[],y=Reflect.ownKeys(p);for(let x=0;x<y.length;x++){let k=y[x];u[k]=p[k]}p=u}else if(pm(p)){let u=[];for(let y=0;y<p.length;y++)u[y]=p[y];p=u}else p=[];let m=o(p,l,c,r,e,a);if(m!==void 0)r[c]=m;else if(Array.isArray(l))r[c]=xl(p,l,o,a);else if(Ia(p)&&Ia(l)&&(yl(p)||yl(l)||vr(p)||vr(l)))r[c]=xl(p,l,o,a);else if(p==null&&yl(l))r[c]=xl({},l,o,a);else if(p==null&&vr(l))r[c]=pf(l);else if(p===void 0||l!==void 0)r[c]=l}return r}function gf(r,...e){return gm(r,...e,lm)}var Ks="",v2={curveBasis:so,curveBasisClosed:ol,curveBasisOpen:sl,curveBumpX:ca,curveBumpY:_a,curveBundle:cu,curveCardinalClosed:uu,curveCardinalOpen:fu,curveCardinal:va,curveCatmullRomClosed:du,curveCatmullRomOpen:pu,curveCatmullRom:Fa,curveLinear:si,curveLinearClosed:hl,curveMonotoneX:Aa,curveMonotoneY:Ma,curveNatural:cs,curveStep:us,curveStepAfter:Oa,curveStepBefore:Ea},L2=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,F2=t(function(r,e){let o=Cm(r,/(?:init\b)|(?:initialize\b)/),a={};if(Array.isArray(o)){let c=o.map((l)=>l.args);Ds(c),a=Se(a,[...c])}else a=o.args;if(!a)return;let s=qa(r,e),n="config";if(a[n]!==void 0){if(s==="flowchart-v2")s="flowchart";a[s]=a[n],delete a[n]}return a},"detectInit"),Cm=t(function(r,e=null){try{let o=new RegExp(`[%]{2}(?![{]${L2.source})(?=[}][%]{2}).*
|
|
161
|
-
`,"ig");r=r.trim().replace(o,"").replace(/'/gm,'"'),i.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${r}`);let a,s=[];while((a=Jo.exec(r))!==null){if(a.index===Jo.lastIndex)Jo.lastIndex++;if(a&&!e||e&&a[1]?.match(e)||e&&a[2]?.match(e)){let n=a[1]?a[1]:a[2],c=a[3]?a[3].trim():a[4]?JSON.parse(a[4].trim()):null;s.push({type:n,args:c})}}if(s.length===0)return{type:r,args:null};return s.length===1?s[0]:s}catch(o){return i.error(`ERROR: ${o.message} - Unable to parse directive type: '${e}' based on the text: '${r}'`),{type:void 0,args:null}}},"detectDirective"),Tc=t(function(r){return r.replace(Jo,"")},"removeDirectives"),A2=t(function(r,e){for(let[o,a]of e.entries())if(a.match(r))return o;return-1},"isSubstringInArray");function bl(r,e){if(!r)return e;let o=`curve${r.charAt(0).toUpperCase()+r.slice(1)}`;return v2[o]??e}t(bl,"interpolateToCurve");function bm(r,e){let o=r.trim();if(!o)return;if(e.securityLevel!=="loose")return xm.sanitizeUrl(o);return o}t(bm,"formatUrl");var M2=t((r,...e)=>{let o=r.split("."),a=o.length-1,s=o[a],n=window;for(let c=0;c<a;c++)if(n=n[o[c]],!n){i.error(`Function name: ${r} not found in window`);return}n[s](...e)},"runFunc");function mf(r,e){if(!r||!e)return 0;return Math.sqrt(Math.pow(e.x-r.x,2)+Math.pow(e.y-r.y,2))}t(mf,"distance");function km(r){let e,o=0;r.forEach((s)=>{o+=mf(s,e),e=s});let a=o/2;return yf(r,a)}t(km,"traverseEdge");function wm(r){if(r.length===1)return r[0];return km(r)}t(wm,"calcLabelPosition");var mm=t((r,e=2)=>{let o=Math.pow(10,e);return Math.round(r*o)/o},"roundNumber"),yf=t((r,e)=>{let o=void 0,a=e;for(let s of r){if(o){let n=mf(s,o);if(n===0)return o;if(n<a)a-=n;else{let c=a/n;if(c<=0)return o;if(c>=1)return{x:s.x,y:s.y};if(c>0&&c<1)return{x:mm((1-c)*o.x+c*s.x,5),y:mm((1-c)*o.y+c*s.y,5)}}}o=s}throw Error("Could not find a suitable point for the given distance")},"calculatePoint"),E2=t((r,e,o)=>{if(i.info(`our points ${JSON.stringify(e)}`),e[0]!==o)e=e.reverse();let s=yf(e,25),n=r?10:5,c=Math.atan2(e[0].y-s.y,e[0].x-s.x),l={x:0,y:0};return l.x=Math.sin(c)*n+(e[0].x+s.x)/2,l.y=-Math.cos(c)*n+(e[0].y+s.y)/2,l},"calcCardinalityPosition");function Sm(r,e,o){let a=structuredClone(o);if(i.info("our points",a),e!=="start_left"&&e!=="start_right")a.reverse();let s=25+r,n=yf(a,s),c=10+r*0.5,l=Math.atan2(a[0].y-n.y,a[0].x-n.x),p={x:0,y:0};if(e==="start_left")p.x=Math.sin(l+Math.PI)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l+Math.PI)*c+(a[0].y+n.y)/2;else if(e==="end_right")p.x=Math.sin(l-Math.PI)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l-Math.PI)*c+(a[0].y+n.y)/2;else if(e==="end_left")p.x=Math.sin(l)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l)*c+(a[0].y+n.y)/2;else p.x=Math.sin(l)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l)*c+(a[0].y+n.y)/2;return p}t(Sm,"calcTerminalLabelPosition");function Yo(r){let e="",o="";for(let a of r)if(a!==void 0)if(a.startsWith("color:")||a.startsWith("text-align:"))o=o+a+";";else e=e+a+";";return{style:e,labelStyle:o}}t(Yo,"getStylesFromArray");var ym=0,Zs=t(()=>(ym++,"id-"+Math.random().toString(36).substr(2,12)+"-"+ym),"generateId");function Tm(r){let e="",o="0123456789abcdef",a=o.length;for(let s=0;s<r;s++)e+=o.charAt(Math.floor(Math.random()*a));return e}t(Tm,"makeRandomHex");var Qs=t((r)=>Tm(r.length),"random"),O2=t(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),I2=t(function(r,e){let o=e.text.replace(C.lineBreakRegex," "),[,a]=Nt(e.fontSize),s=r.append("text");if(s.attr("x",e.x),s.attr("y",e.y),s.style("text-anchor",e.anchor),s.style("font-family",e.fontFamily),s.style("font-size",a),s.style("font-weight",e.fontWeight),s.attr("fill",e.fill),e.class!==void 0)s.attr("class",e.class);let n=s.append("tspan");return n.attr("x",e.x+e.textMargin*2),n.attr("fill",e.fill),n.text(o),s},"drawSimpleText"),Vr=ao((r,e,o)=>{if(!r)return r;if(o=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},o),C.hasBreaks(r))return r;let a=r.split(" ").filter(Boolean),s=[],n="";return a.forEach((c,l)=>{let p=Pt(`${c} `,o),m=Pt(n,o);if(p>e){let{hyphenatedStrings:x,remainingWord:k}=$2(c,e,"-",o);s.push(n,...x),n=k}else if(m+p>=e)s.push(n),n=c;else n=[n,c].filter(Boolean).join(" ");if(l+1===a.length)s.push(n)}),s.filter((c)=>c!=="").join(o.joinWith)},(r,e,o)=>`${r}${e}${o.fontSize}${o.fontWeight}${o.fontFamily}${o.joinWith}`),$2=ao((r,e,o="-",a)=>{a=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},a);let s=[...r],n=[],c="";return s.forEach((l,p)=>{let m=`${c}${l}`;if(Pt(m,a)>=e){let y=p+1,x=s.length===y,k=`${m}${o}`;n.push(x?m:k),c=""}else c=m}),{hyphenatedStrings:n,remainingWord:c}},(r,e,o="-",a)=>`${r}${e}${o}${a.fontSize}${a.fontWeight}${a.fontFamily}`);function Ii(r,e){return Di(r,e).height}t(Ii,"calculateTextHeight");function Pt(r,e){return Di(r,e).width}t(Pt,"calculateTextWidth");var Di=ao((r,e)=>{let{fontSize:o=12,fontFamily:a="Arial",fontWeight:s=400}=e;if(!r)return{width:0,height:0};let[,n]=Nt(o),c=["sans-serif",a],l=r.split(C.lineBreakRegex),p=[],m=g("body");if(!m.remove)return{width:0,height:0,lineHeight:0};let u=m.append("svg");for(let x of c){let k=0,w={width:0,height:0,lineHeight:0};for(let _ of l){let M=O2();M.text=_||Ks;let q=I2(u,M).style("font-size",n).style("font-weight",s).style("font-family",x),Y=(q._groups||q)[0][0].getBBox();if(Y.width===0&&Y.height===0)throw Error("svg element not in render tree");w.width=Math.round(Math.max(w.width,Y.width)),k=Math.round(Y.height),w.height+=k,w.lineHeight=Math.round(Math.max(w.lineHeight,k))}p.push(w)}u.remove();let y=isNaN(p[1].height)||isNaN(p[1].width)||isNaN(p[1].lineHeight)||p[0].height>p[1].height&&p[0].width>p[1].width&&p[0].lineHeight>p[1].lineHeight?0:1;return p[y]},(r,e)=>`${r}${e.fontSize}${e.fontWeight}${e.fontFamily}`),D2=class{constructor(r=!1,e){this.count=0,this.count=e?e.length:0,this.next=r?()=>this.count++:()=>Date.now()}static{t(this,"InitIDGenerator")}},Cl,P2=t(function(r){return Cl=Cl||document.createElement("div"),r=escape(r).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),Cl.innerHTML=r,unescape(Cl.textContent)},"entityDecode");function Xo(r){return"str"in r}t(Xo,"isDetailedError");function Js(r){if(r instanceof Error)return r.message;return String(r)}t(Js,"getErrorMessage");var R2=t((r,e,o,a)=>{if(!a)return;let s=r.node()?.getBBox();if(!s)return;r.append("text").text(a).attr("text-anchor","middle").attr("x",s.x+s.width/2).attr("y",-o).attr("class",e)},"insertTitle"),Nt=t((r)=>{if(typeof r==="number")return[r,r+"px"];let e=parseInt(r??"",10);if(Number.isNaN(e))return[void 0,void 0];else if(r===String(e))return[e,r+"px"];else return[e,r]},"parseFontSize");function Z(r,e){return gf({},r,e)}t(Z,"cleanAndMerge");var H={assignWithDepth:Se,wrapLabel:Vr,calculateTextHeight:Ii,calculateTextWidth:Pt,calculateTextDimensions:Di,cleanAndMerge:Z,detectInit:F2,detectDirective:Cm,isSubstringInArray:A2,interpolateToCurve:bl,calcLabelPosition:wm,calcCardinalityPosition:E2,calcTerminalLabelPosition:Sm,formatUrl:bm,getStylesFromArray:Yo,generateId:Zs,random:Qs,runFunc:M2,entityDecode:P2,insertTitle:R2,isLabelCoordinateInPath:_m,parseFontSize:Nt,InitIDGenerator:D2},Ec=t(function(r){let e=r;return e=e.replace(/style.*:\S*#.*;/g,function(o){return o.substring(0,o.length-1)}),e=e.replace(/classDef.*:\S*#.*;/g,function(o){return o.substring(0,o.length-1)}),e=e.replace(/#\w+;/g,function(o){let a=o.substring(1,o.length-1);if(/^\+?\d+$/.test(a))return"fl°°"+a+"¶ß";else return"fl°"+a+"¶ß"}),e},"encodeEntities"),Fn=t(function(r){return r.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),_t=t((r,e,{counter:o=0,prefix:a,suffix:s},n)=>{if(n)return n;return`${a?`${a}_`:""}${r}_${e}_${o}${s?`_${s}`:""}`},"getEdgeId");function Me(r){return r??null}t(Me,"handleUndefinedAttr");function _m(r,e){let o=Math.round(r.x),a=Math.round(r.y),s=e.replace(/(\d+\.\d+)/g,(n)=>Math.round(parseFloat(n)).toString());return s.includes(o.toString())||s.includes(a.toString())}t(_m,"isLabelCoordinateInPath");function Cf(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var lo=Cf();function Em(r){lo=r}var Ra={exec:()=>null};function Ce(r,e=""){let o=typeof r=="string"?r:r.source,a={replace:(s,n)=>{let c=typeof n=="string"?n:n.source;return c=c.replace(xr.caret,"$1"),o=o.replace(s,c),a},getRegex:()=>new RegExp(o,e)};return a}var q2=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),xr={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:(r)=>new RegExp(`^( {0,3}${r})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}#`),htmlBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}<(?:[a-z].*>|!--)`,"i")},N2=/^(?:[ \t]*(?:\n|$))+/,W2=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,z2=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Na=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,H2=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,bf=/(?:[*+-]|\d{1,9}[.)])/,Om=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Im=Ce(Om).replace(/bull/g,bf).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),Y2=Ce(Om).replace(/bull/g,bf).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),kf=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,U2=/^[^\n]+/,wf=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,j2=Ce(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",wf).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),G2=Ce(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,bf).getRegex(),_l="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Sf=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,X2=Ce("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",Sf).replace("tag",_l).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),$m=Ce(kf).replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex(),V2=Ce(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",$m).getRegex(),Tf={blockquote:V2,code:W2,def:j2,fences:z2,heading:H2,hr:Na,html:X2,lheading:Im,list:G2,newline:N2,paragraph:$m,table:Ra,text:U2},Bm=Ce("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex(),K2={...Tf,lheading:Y2,table:Bm,paragraph:Ce(kf).replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Bm).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex()},Z2={...Tf,html:Ce(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Sf).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Ra,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Ce(kf).replace("hr",Na).replace("heading",` *#{1,6} *[^
|
|
159
|
+
`+G.slice(Wt+1);else Zt+=G.slice(Mt);return Zt.slice(1)}t(qe,"foldLine");function Wi(G){let mt="",Dt=0;for(let Ft=0;Ft<G.length;Dt>=65536?Ft+=2:Ft++){Dt=_e(G,Ft);let Mt=it[Dt];if(!Mt&&Ut(Dt)){if(mt+=G[Ft],Dt>=65536)mt+=G[Ft+1]}else mt+=Mt||vt(Dt)}return mt}t(Wi,"escapeString");function Xr(G,mt,Dt){let Ft="",Mt=G.tag;for(let Ht=0,Wt=Dt.length;Ht<Wt;Ht+=1){let Qt=Dt[Ht];if(G.replacer)Qt=G.replacer.call(Dt,String(Ht),Qt);if(Tt(G,mt,Qt,!1,!1)||typeof Qt>"u"&&Tt(G,mt,null,!1,!1)){if(Ft!=="")Ft+=","+(!G.condenseFlow?" ":"");Ft+=G.dump}}G.tag=Mt,G.dump="["+Ft+"]"}t(Xr,"writeFlowSequence");function gi(G,mt,Dt,Ft){let Mt="",Ht=G.tag;for(let Wt=0,Qt=Dt.length;Wt<Qt;Wt+=1){let Zt=Dt[Wt];if(G.replacer)Zt=G.replacer.call(Dt,String(Wt),Zt);if(Tt(G,mt+1,Zt,!0,!0,!1,!0)||typeof Zt>"u"&&Tt(G,mt+1,null,!0,!0,!1,!0)){if(!Ft||Mt!=="")Mt+=de(G,mt);if(G.dump&&l===G.dump.charCodeAt(0))Mt+="-";else Mt+="- ";Mt+=G.dump}}G.tag=Ht,G.dump=Mt||"[]"}t(gi,"writeBlockSequence");function mi(G,mt,Dt){let Ft="",Mt=G.tag,Ht=Object.keys(Dt);for(let Wt=0,Qt=Ht.length;Wt<Qt;Wt+=1){let Zt="";if(Ft!=="")Zt+=", ";if(G.condenseFlow)Zt+='"';let Jt=Ht[Wt],ee=Dt[Jt];if(G.replacer)ee=G.replacer.call(Dt,Jt,ee);if(!Tt(G,mt,Jt,!1,!1))continue;if(G.dump.length>1024)Zt+="? ";if(Zt+=G.dump+(G.condenseFlow?'"':"")+":"+(G.condenseFlow?"":" "),!Tt(G,mt,ee,!1,!1))continue;Zt+=G.dump,Ft+=Zt}G.tag=Mt,G.dump="{"+Ft+"}"}t(mi,"writeFlowMapping");function b(G,mt,Dt,Ft){let Mt="",Ht=G.tag,Wt=Object.keys(Dt);if(G.sortKeys===!0)Wt.sort();else if(typeof G.sortKeys==="function")Wt.sort(G.sortKeys);else if(G.sortKeys)throw new e("sortKeys must be a boolean or a function");for(let Qt=0,Zt=Wt.length;Qt<Zt;Qt+=1){let Jt="";if(!Ft||Mt!=="")Jt+=de(G,mt);let ee=Wt[Qt],pe=Dt[ee];if(G.replacer)pe=G.replacer.call(Dt,ee,pe);if(!Tt(G,mt+1,ee,!0,!0,!0))continue;let Te=G.tag!==null&&G.tag!=="?"||G.dump&&G.dump.length>1024;if(Te)if(G.dump&&l===G.dump.charCodeAt(0))Jt+="?";else Jt+="? ";if(Jt+=G.dump,Te)Jt+=de(G,mt);if(!Tt(G,mt+1,pe,!0,Te))continue;if(G.dump&&l===G.dump.charCodeAt(0))Jt+=":";else Jt+=": ";Jt+=G.dump,Mt+=Jt}G.tag=Ht,G.dump=Mt||"{}"}t(b,"writeBlockMapping");function ft(G,mt,Dt){let Ft=Dt?G.explicitTypes:G.implicitTypes;for(let Mt=0,Ht=Ft.length;Mt<Ht;Mt+=1){let Wt=Ft[Mt];if((Wt.instanceOf||Wt.predicate)&&(!Wt.instanceOf||typeof mt==="object"&&mt instanceof Wt.instanceOf)&&(!Wt.predicate||Wt.predicate(mt))){if(Dt)if(Wt.multi&&Wt.representName)G.tag=Wt.representName(mt);else G.tag=Wt.tag;else G.tag="?";if(Wt.represent){let Qt=G.styleMap[Wt.tag]||Wt.defaultStyle,Zt;if(a.call(Wt.represent)==="[object Function]")Zt=Wt.represent(mt,Qt);else if(s.call(Wt.represent,Qt))Zt=Wt.represent[Qt](mt,Qt);else throw new e("!<"+Wt.tag+'> tag resolver accepts not "'+Qt+'" style');G.dump=Zt}return!0}}return!1}t(ft,"detectType");function Tt(G,mt,Dt,Ft,Mt,Ht,Wt){if(G.tag=null,G.dump=Dt,!ft(G,Dt,!1))ft(G,Dt,!0);let Qt=a.call(G.dump),Zt=Ft;if(Ft)Ft=G.flowLevel<0||G.flowLevel>mt;let Jt=Qt==="[object Object]"||Qt==="[object Array]",ee,pe;if(Jt)ee=G.duplicates.indexOf(Dt),pe=ee!==-1;if(G.tag!==null&&G.tag!=="?"||pe||G.indent!==2&&mt>0)Mt=!1;if(pe&&G.usedDuplicates[ee])G.dump="*ref_"+ee;else{if(Jt&&pe&&!G.usedDuplicates[ee])G.usedDuplicates[ee]=!0;if(Qt==="[object Object]"){if(Ft&&Object.keys(G.dump).length!==0){if(b(G,mt,G.dump,Mt),pe)G.dump="&ref_"+ee+G.dump}else if(mi(G,mt,G.dump),pe)G.dump="&ref_"+ee+" "+G.dump}else if(Qt==="[object Array]"){if(Ft&&G.dump.length!==0){if(G.noArrayIndent&&!Wt&&mt>0)gi(G,mt-1,G.dump,Mt);else gi(G,mt,G.dump,Mt);if(pe)G.dump="&ref_"+ee+G.dump}else if(Xr(G,mt,G.dump),pe)G.dump="&ref_"+ee+" "+G.dump}else if(Qt==="[object String]"){if(G.tag!=="?")pi(G,G.dump,mt,Ht,Zt)}else if(Qt==="[object Undefined]")return!1;else{if(G.skipInvalid)return!1;throw new e("unacceptable kind of an object to dump "+Qt)}if(G.tag!==null&&G.tag!=="?"){let Te=encodeURI(G.tag[0]==="!"?G.tag.slice(1):G.tag).replace(/!/g,"%21");if(G.tag[0]==="!")Te="!"+Te;else if(Te.slice(0,18)==="tag:yaml.org,2002:")Te="!!"+Te.slice(18);else Te="!<"+Te+">";G.dump=Te+" "+G.dump}}return!0}t(Tt,"writeNode");function At(G,mt){let Dt=[],Ft=[];St(G,Dt,Ft);let Mt=Ft.length;for(let Ht=0;Ht<Mt;Ht+=1)mt.duplicates.push(Dt[Ft[Ht]]);mt.usedDuplicates=Array(Mt)}t(At,"getDuplicateReferences");function St(G,mt,Dt){if(G!==null&&typeof G==="object"){let Ft=mt.indexOf(G);if(Ft!==-1){if(Dt.indexOf(Ft)===-1)Dt.push(Ft)}else if(mt.push(G),Array.isArray(G))for(let Mt=0,Ht=G.length;Mt<Ht;Mt+=1)St(G[Mt],mt,Dt);else{let Mt=Object.keys(G);for(let Ht=0,Wt=Mt.length;Ht<Wt;Ht+=1)St(G[Mt[Ht]],mt,Dt)}}}t(St,"inspectNode");function Yt(G,mt){mt=mt||{};let Dt=new se(mt);if(!Dt.noRefs)At(G,Dt);let Ft=G;if(Dt.replacer)Ft=Dt.replacer.call({"":Ft},"",Ft);if(Tt(Dt,0,Ft,!0,!0))return Dt.dump+`
|
|
160
|
+
`;return""}return t(Yt,"dump2"),qu.dump=Yt,qu}t(Ug,"requireDumper");var Wg;function jg(){if(Wg)return lr;Wg=1;let r=Yg(),e=Ug();function o(a,s){return function(){throw Error("Function yaml."+a+" is removed in js-yaml 4. Use yaml."+s+" instead, which is now safe by default.")}}return t(o,"renamed"),lr.Type=cr(),lr.Schema=Nu(),lr.FAILSAFE_SCHEMA=Yu(),lr.JSON_SCHEMA=Vu(),lr.CORE_SCHEMA=Ku(),lr.DEFAULT_SCHEMA=dl(),lr.load=r.load,lr.loadAll=r.loadAll,lr.dump=e.dump,lr.YAMLException=ds(),lr.types={binary:Ju(),float:Xu(),map:Hu(),null:Uu(),pairs:ef(),set:rf(),timestamp:Zu(),bool:ju(),int:Gu(),merge:Qu(),omap:tf(),seq:zu(),str:Wu()},lr.safeLoad=o("safeLoad","load"),lr.safeLoadAll=o("safeLoadAll","loadAll"),lr.safeDump=o("safeDump","dump"),lr}t(jg,"requireJsYaml");var t2=jg(),e2=zg(t2),{Type:I3,Schema:$3,FAILSAFE_SCHEMA:D3,JSON_SCHEMA:qt,CORE_SCHEMA:P3,DEFAULT_SCHEMA:R3,load:Vt,loadAll:q3,dump:N3,YAMLException:W3,types:z3,safeLoad:H3,safeLoadAll:Y3,safeDump:U3}=e2;var Eo=t((r,e)=>{let{theme:o,themeVariables:a}=e,{useGradient:s,gradientStart:n,gradientStop:c}=a??{},l=r.attr("id"),p=o?.includes("dark")?"#FFFFFF":"#000000",m=t((y,x,k)=>r.append("defs").append("filter").attr("id",y).attr("height",x).attr("width",x).append("feDropShadow").attr("dx",k).attr("dy",k).attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",p),"dropShadow");if(m(`${l}-drop-shadow`,"130%","4"),m(`${l}-drop-shadow-small`,"150%","2"),!s)return;let u=r.append("linearGradient").attr("id",`${l}-gradient`).attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");u.append("svg:stop").attr("offset","0%").attr("stop-color",n).attr("stop-opacity",1),u.append("svg:stop").attr("offset","100%").attr("stop-color",c).attr("stop-opacity",1)},"insertLookDefs");var Gg=t((r)=>{let{handDrawnSeed:e}=d();return{fill:r,hachureAngle:120,hachureGap:1.5,fillWeight:1.5,roughness:0.7,stroke:r,seed:e}},"solidStateFill"),r2=t((r)=>{if(Array.isArray(r))return r;if(!r)return[];return r.split(";").map((e)=>e.trim()).filter(Boolean)},"normalizeStyleList"),ai=t((r)=>{let e=i2([...r.cssCompiledStyles||[],...r.cssStyles||[],...r2(r.labelStyle)]);return{stylesMap:e,stylesArray:[...e]}},"compileStyles"),i2=t((r)=>{let e=new Map;return r.forEach((o)=>{let[a,s]=o.split(":");e.set(a.trim(),s?.trim())}),e},"styles2Map"),Pi=t((r)=>r==="color"||r==="font-size"||r==="font-family"||r==="font-weight"||r==="font-style"||r==="text-decoration"||r==="text-align"||r==="text-transform"||r==="line-height"||r==="letter-spacing"||r==="word-spacing"||r==="text-shadow"||r==="text-overflow"||r==="white-space"||r==="word-wrap"||r==="word-break"||r==="overflow-wrap"||r==="hyphens","isLabelStyle"),E=t((r)=>{let{stylesArray:e}=ai(r),o=[],a=[],s=[],n=[];return e.forEach((c)=>{let l=c[0];if(Pi(l))o.push(c.join(":")+" !important");else{if(a.push(c.join(":")+" !important"),l.includes("stroke"))s.push(c.join(":")+" !important");if(l==="fill")n.push(c.join(":")+" !important")}}),{labelStyles:o.join(";"),nodeStyles:a.join(";"),stylesArray:e,borderStyles:s,backgroundStyles:n}},"styles2String"),Kt=t((r,e)=>{let{themeVariables:o,handDrawnSeed:a}=d(),{nodeBorder:s,mainBkg:n}=o,{stylesMap:c}=ai(r);return Object.assign({roughness:0.7,fill:c.get("fill")||n,fillStyle:"hachure",fillWeight:1.5,hachureGap:1.5,stroke:c.get("stroke")||s,seed:a,strokeWidth:c.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0],strokeLineDash:o2(c.get("stroke-dasharray"))},e)},"userNodeOverrides"),o2=t((r)=>{if(!r)return[0,0];let e=r.trim().split(/\s+/).map(Number);if(e.length===1){let s=isNaN(e[0])?0:e[0];return[s,s]}let o=isNaN(e[0])?0:e[0],a=isNaN(e[1])?0:e[1];return[o,a]},"getStrokeDashArray");var of=(r,e,o,a="")=>{let s=r.split(":");if(r.slice(0,1)==="@"){if(s.length<2||s.length>3)return null;a=s.shift().slice(1)}if(s.length>3||!s.length)return null;if(s.length>1){let l=s.pop(),p=s.pop(),m={provider:s.length>0?s[0]:a,prefix:p,name:l};return e&&!pl(m)?null:m}let n=s[0],c=n.split("-");if(c.length>1){let l={provider:a,prefix:c.shift(),name:c.join("-")};return e&&!pl(l)?null:l}if(o&&a===""){let l={provider:a,prefix:"",name:n};return e&&!pl(l,o)?null:l}return null},pl=(r,e)=>{if(!r)return!1;return!!((e&&r.prefix===""||!!r.prefix)&&!!r.name)};var s2=Object.freeze({left:0,top:0,width:16,height:16}),ps=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),sf=Object.freeze({...s2,...ps}),Xg=Object.freeze({...sf,body:"",hidden:!1});function Vg(r,e){let o={};if(!r.hFlip!==!e.hFlip)o.hFlip=!0;if(!r.vFlip!==!e.vFlip)o.vFlip=!0;let a=((r.rotate||0)+(e.rotate||0))%4;if(a)o.rotate=a;return o}function af(r,e){let o=Vg(r,e);for(let a in Xg)if(a in ps){if(a in r&&!(a in o))o[a]=ps[a]}else if(a in e)o[a]=e[a];else if(a in r)o[a]=r[a];return o}function Kg(r,e){let o=r.icons,a=r.aliases||Object.create(null),s=Object.create(null);function n(c){if(o[c])return s[c]=[];if(!(c in s)){s[c]=null;let l=a[c]&&a[c].parent,p=l&&n(l);if(p)s[c]=[l].concat(p)}return s[c]}return(e||Object.keys(o).concat(Object.keys(a))).forEach(n),s}function Zg(r,e,o){let a=r.icons,s=r.aliases||Object.create(null),n={};function c(l){n=af(a[l]||s[l],n)}return c(e),o.forEach(c),af(r,n)}function nf(r,e){if(r.icons[e])return Zg(r,e,[]);let o=Kg(r,[e])[e];return o?Zg(r,e,o):null}var a2=Object.freeze({width:null,height:null}),Qg=Object.freeze({...a2,...ps});var n2=/(-?[0-9.]*[0-9]+[0-9.]*)/g,l2=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function lf(r,e,o){if(e===1)return r;if(o=o||100,typeof r==="number")return Math.ceil(r*e*o)/o;if(typeof r!=="string")return r;let a=r.split(n2);if(a===null||!a.length)return r;let s=[],n=a.shift(),c=l2.test(n);while(!0){if(c){let l=parseFloat(n);if(isNaN(l))s.push(n);else s.push(Math.ceil(l*e*o)/o)}else s.push(n);if(n=a.shift(),n===void 0)return s.join("");c=!c}}function h2(r,e="defs"){let o="",a=r.indexOf("<"+e);while(a>=0){let s=r.indexOf(">",a),n=r.indexOf("</"+e);if(s===-1||n===-1)break;let c=r.indexOf(">",n);if(c===-1)break;o+=r.slice(s+1,n).trim(),r=r.slice(0,a).trim()+r.slice(c+1)}return{defs:o,content:r}}function c2(r,e){return r?"<defs>"+r+"</defs>"+e:e}function Jg(r,e,o){let a=h2(r);return c2(a.defs,e+a.content+o)}var u2=(r)=>r==="unset"||r==="undefined"||r==="none";function hf(r,e){let o={...sf,...r},a={...Qg,...e},s={left:o.left,top:o.top,width:o.width,height:o.height},n=o.body;[o,a].forEach((_)=>{let M=[],{hFlip:W,vFlip:U,rotate:V}=_;if(W)if(U)V+=2;else M.push("translate("+(s.width+s.left).toString()+" "+(0-s.top).toString()+")"),M.push("scale(-1 1)"),s.top=s.left=0;else if(U)M.push("translate("+(0-s.left).toString()+" "+(s.height+s.top).toString()+")"),M.push("scale(1 -1)"),s.top=s.left=0;let Z;if(V<0)V-=Math.floor(V/4)*4;switch(V=V%4,V){case 1:Z=s.height/2+s.top,M.unshift("rotate(90 "+Z.toString()+" "+Z.toString()+")");break;case 2:M.unshift("rotate(180 "+(s.width/2+s.left).toString()+" "+(s.height/2+s.top).toString()+")");break;case 3:Z=s.width/2+s.left,M.unshift("rotate(-90 "+Z.toString()+" "+Z.toString()+")")}if(V%2===1){if(s.left!==s.top)Z=s.left,s.left=s.top,s.top=Z;if(s.width!==s.height)Z=s.width,s.width=s.height,s.height=Z}if(M.length)n=Jg(n,'<g transform="'+M.join(" ")+'">',"</g>")});let{width:c,height:l}=a,{width:p,height:m}=s,u,y;if(c===null)y=l===null?"1em":l==="auto"?m:l,u=lf(y,p/m);else u=c==="auto"?p:c,y=l===null?lf(u,m/p):l==="auto"?m:l;let x={},k=(_,M)=>{if(!u2(M))x[_]=M.toString()};k("width",u),k("height",y);let w=[s.left,s.top,p,m];return x.viewBox=w.join(" "),{attributes:x,viewBox:w,body:n}}var f2=/\sid="(\S+)"/g,tm=new Map;function d2(r){r=r.replace(/[0-9]+$/,"")||"a";let e=tm.get(r)||0;return tm.set(r,e+1),e?`${r}${e}`:r}function cf(r){let e=[],o;while(o=f2.exec(r))e.push(o[1]);if(!e.length)return r;let a="suffix"+(Math.random()*16777216|Date.now()).toString(16);return e.forEach((s)=>{let n=d2(s),c=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");r=r.replace(new RegExp('([#;"])('+c+')([")]|\\.[a-z])',"g"),"$1"+n+a+"$3")}),r=r.replace(new RegExp(a,"g"),""),r}function uf(r,e){let o=r.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(let a in e)o+=" "+a+'="'+e[a]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+o+">"+r+"</svg>"}var Xs={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},ff=new Map,em=new Map,jr=t((r)=>{for(let e of r){if(!e.name)throw Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(i.debug("Registering icon pack:",e.name),"loader"in e)em.set(e.name,e.loader);else if("icons"in e)ff.set(e.name,e.icons);else throw i.error("Invalid icon loader:",e),Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),rm=t(async(r,e)=>{let o=of(r,!0,e!==void 0);if(!o)throw Error(`Invalid icon name: ${r}`);let a=o.prefix||e;if(!a)throw Error(`Icon name must contain a prefix: ${r}`);let s=ff.get(a);if(!s){let c=em.get(a);if(!c)throw Error(`Icon set not found: ${o.prefix}`);try{s={...await c(),prefix:a},ff.set(a,s)}catch(l){throw i.error(l),Error(`Failed to load icon set: ${o.prefix}`)}}let n=nf(s,o.name);if(!n)throw Error(`Icon not found: ${r}`);return n},"getRegisteredIconData"),gl=t(async(r)=>{try{return await rm(r),!0}catch{return!1}},"isIconAvailable"),Gt=t(async(r,e,o)=>{let a;try{a=await rm(r,e?.fallbackPrefix)}catch(c){i.error(c),a=Xs}let s=hf(a,e),n=uf(cf(s.body),{...s.attributes,...o});return q(n,A())},"getIconSVG");var xm=Ke(la(),1);function ao(r,e){if(typeof r!=="function"||e!=null&&typeof e!=="function")throw TypeError("Expected a function");let o=function(...a){let s=e?e.apply(this,a):a[0],n=o.cache;if(n.has(s))return n.get(s);let c=r.apply(this,a);return o.cache=n.set(s,c)||n,c};return o.cache=new(ao.Cache||Map),o}ao.Cache=Map;function qr(r){return r==null||typeof r!=="object"&&typeof r!=="function"}function gr(r){if(r==null)return r===void 0?"[object Undefined]":"[object Null]";return Object.prototype.toString.call(r)}var Lo="[object RegExp]",Qa="[object String]",Ja="[object Number]",ei="[object Boolean]",ti="[object Arguments]",No="[object Symbol]",Mo="[object Date]",Po="[object Map]",Ro="[object Set]",Io="[object Array]";var Do="[object ArrayBuffer]",Oo="[object Object]";var $o="[object DataView]",Bo="[object Uint8Array]",Fo="[object Uint8ClampedArray]",zo="[object Uint16Array]",Ho="[object Uint32Array]";var Uo="[object Int8Array]",jo="[object Int16Array]",qo="[object Int32Array]";var Vo="[object Float32Array]",Go="[object Float64Array]";function gs(r){return ArrayBuffer.isView(r)&&!(r instanceof DataView)}function vr(r){return gs(r)}function lm(){}function hm(r){if(qr(r))return r;if(Array.isArray(r)||gs(r)||r instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&r instanceof SharedArrayBuffer)return r.slice(0);let e=Object.getPrototypeOf(r);if(e==null)return Object.assign(Object.create(e),r);let o=e.constructor;if(r instanceof Date||r instanceof Map||r instanceof Set)return new o(r);if(r instanceof RegExp){let a=new o(r);return a.lastIndex=r.lastIndex,a}if(r instanceof DataView)return new o(r.buffer.slice(0));if(r instanceof Error){let a;if(r instanceof AggregateError)a=new o(r.errors,r.message,{cause:r.cause});else a=new o(r.message,{cause:r.cause});return a.stack=r.stack,Object.assign(a,r),a}if(typeof File<"u"&&r instanceof File)return new o([r],r.name,{type:r.type,lastModified:r.lastModified});if(typeof r==="object")return Object.assign(Object.create(e),r);return r}function ml(r){return Object.getOwnPropertySymbols(r).filter((e)=>Object.prototype.propertyIsEnumerable.call(r,e))}var df=typeof globalThis==="object"&&globalThis||typeof window==="object"&&window||typeof self==="object"&&self||typeof global==="object"&&global||function(){return this}();function ni(r){return typeof df.Buffer<"u"&&df.Buffer.isBuffer(r)}function cm(r){return r==="__proto__"}function yl(r){if(typeof r!=="object")return!1;if(r==null)return!1;if(Object.getPrototypeOf(r)===null)return!0;if(Object.prototype.toString.call(r)!=="[object Object]"){let o=r[Symbol.toStringTag];if(o==null)return!1;if(!Object.getOwnPropertyDescriptor(r,Symbol.toStringTag)?.writable)return!1;return r.toString()===`[object ${o}]`}let e=r;while(Object.getPrototypeOf(e)!==null)e=Object.getPrototypeOf(e);return Object.getPrototypeOf(r)===e}function um(r,e){return ms(r,void 0,r,new Map,e)}function ms(r,e,o,a=new Map,s=void 0){let n=s?.(r,e,o,a);if(n!==void 0)return n;if(qr(r))return r;if(a.has(r))return a.get(r);if(Array.isArray(r)){let c=Array(r.length);a.set(r,c);for(let l=0;l<r.length;l++)c[l]=ms(r[l],l,o,a,s);if(Object.hasOwn(r,"index"))c.index=r.index;if(Object.hasOwn(r,"input"))c.input=r.input;return c}if(r instanceof Date)return new Date(r.getTime());if(r instanceof RegExp){let c=new RegExp(r.source,r.flags);return c.lastIndex=r.lastIndex,c}if(r instanceof Map){let c=new Map;a.set(r,c);for(let[l,p]of r)c.set(l,ms(p,l,o,a,s));return c}if(r instanceof Set){let c=new Set;a.set(r,c);for(let l of r)c.add(ms(l,void 0,o,a,s));return c}if(ni(r))return r.subarray();if(gs(r)){let c=new(Object.getPrototypeOf(r)).constructor(r.length);a.set(r,c);for(let l=0;l<r.length;l++)c[l]=ms(r[l],l,o,a,s);return c}if(r instanceof ArrayBuffer||typeof SharedArrayBuffer<"u"&&r instanceof SharedArrayBuffer)return r.slice(0);if(r instanceof DataView){let c=new DataView(r.buffer.slice(0),r.byteOffset,r.byteLength);return a.set(r,c),$r(c,r,o,a,s),c}if(typeof File<"u"&&r instanceof File){let c=new File([r],r.name,{type:r.type});return a.set(r,c),$r(c,r,o,a,s),c}if(typeof Blob<"u"&&r instanceof Blob){let c=new Blob([r],{type:r.type});return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof Error){let c=structuredClone(r);return a.set(r,c),c.message=r.message,c.name=r.name,c.stack=r.stack,c.cause=r.cause,c.constructor=r.constructor,$r(c,r,o,a,s),c}if(r instanceof Boolean){let c=new Boolean(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof Number){let c=new Number(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(r instanceof String){let c=new String(r.valueOf());return a.set(r,c),$r(c,r,o,a,s),c}if(typeof r==="object"&&B2(r)){let c=Object.create(Object.getPrototypeOf(r));return a.set(r,c),$r(c,r,o,a,s),c}return r}function $r(r,e,o=r,a,s){let n=[...Object.keys(e),...ml(e)];for(let c=0;c<n.length;c++){let l=n[c],p=Object.getOwnPropertyDescriptor(r,l);if(p==null||p.writable)r[l]=ms(e[l],l,o,a,s)}}function B2(r){switch(gr(r)){case ti:case Io:case Do:case $o:case ei:case Mo:case Vo:case Go:case Uo:case jo:case qo:case Po:case Ja:case Oo:case Lo:case Ro:case Qa:case No:case Bo:case Fo:case zo:case Ho:return!0;default:return!1}}function fm(r,e){return um(r,(o,a,s,n)=>{let c=e?.(o,a,s,n);if(c!==void 0)return c;if(typeof r!=="object")return;if(gr(r)==="[object Object]"&&typeof r.constructor!=="function"){let l={};return n.set(r,l),$r(l,r,s,n),l}switch(Object.prototype.toString.call(r)){case Ja:case Qa:case ei:{let l=new r.constructor(r?.valueOf());return $r(l,r),l}case ti:{let l={};return $r(l,r),l.length=r.length,l[Symbol.iterator]=r[Symbol.iterator],l}default:return}})}function pf(r){return fm(r)}function Ri(r){return r!==null&&typeof r==="object"&&gr(r)==="[object Arguments]"}function Ia(r){return typeof r==="object"&&r!==null}function dm(r){return Number.isSafeInteger(r)&&r>=0}function Wo(r){return r!=null&&typeof r!=="function"&&dm(r.length)}function pm(r){return Ia(r)&&Wo(r)}function gm(r,...e){let o=e.slice(0,-1),a=e[e.length-1],s=r;for(let n=0;n<o.length;n++){let c=o[n];s=xl(s,c,a,new Map)}return s}function xl(r,e,o,a){if(qr(r))r=Object(r);if(e==null||typeof e!=="object")return r;if(a.has(e))return hm(a.get(e));if(a.set(e,r),Array.isArray(e)){e=e.slice();for(let n=0;n<e.length;n++)if(!(n in e))e[n]=void 0}let s=[...Object.keys(e),...ml(e)];for(let n=0;n<s.length;n++){let c=s[n];if(cm(c))continue;let l=e[c],p=r[c];if(Ri(l))l={...l};if(Ri(p))p={...p};if(ni(l))l=pf(l);if(Array.isArray(l))if(Array.isArray(p)){let u=[],y=Reflect.ownKeys(p);for(let x=0;x<y.length;x++){let k=y[x];u[k]=p[k]}p=u}else if(pm(p)){let u=[];for(let y=0;y<p.length;y++)u[y]=p[y];p=u}else p=[];let m=o(p,l,c,r,e,a);if(m!==void 0)r[c]=m;else if(Array.isArray(l))r[c]=xl(p,l,o,a);else if(Ia(p)&&Ia(l)&&(yl(p)||yl(l)||vr(p)||vr(l)))r[c]=xl(p,l,o,a);else if(p==null&&yl(l))r[c]=xl({},l,o,a);else if(p==null&&vr(l))r[c]=pf(l);else if(p===void 0||l!==void 0)r[c]=l}return r}function gf(r,...e){return gm(r,...e,lm)}var Ks="",v2={curveBasis:so,curveBasisClosed:ol,curveBasisOpen:sl,curveBumpX:ca,curveBumpY:_a,curveBundle:cu,curveCardinalClosed:uu,curveCardinalOpen:fu,curveCardinal:va,curveCatmullRomClosed:du,curveCatmullRomOpen:pu,curveCatmullRom:Fa,curveLinear:si,curveLinearClosed:hl,curveMonotoneX:Aa,curveMonotoneY:Ma,curveNatural:cs,curveStep:us,curveStepAfter:Oa,curveStepBefore:Ea},L2=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,F2=t(function(r,e){let o=Cm(r,/(?:init\b)|(?:initialize\b)/),a={};if(Array.isArray(o)){let c=o.map((l)=>l.args);Ds(c),a=Ae(a,[...c])}else a=o.args;if(!a)return;let s=qa(r,e),n="config";if(a[n]!==void 0){if(s==="flowchart-v2")s="flowchart";a[s]=a[n],delete a[n]}return a},"detectInit"),Cm=t(function(r,e=null){try{let o=new RegExp(`[%]{2}(?![{]${L2.source})(?=[}][%]{2}).*
|
|
161
|
+
`,"ig");r=r.trim().replace(o,"").replace(/'/gm,'"'),i.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${r}`);let a,s=[];while((a=Jo.exec(r))!==null){if(a.index===Jo.lastIndex)Jo.lastIndex++;if(a&&!e||e&&a[1]?.match(e)||e&&a[2]?.match(e)){let n=a[1]?a[1]:a[2],c=a[3]?a[3].trim():a[4]?JSON.parse(a[4].trim()):null;s.push({type:n,args:c})}}if(s.length===0)return{type:r,args:null};return s.length===1?s[0]:s}catch(o){return i.error(`ERROR: ${o.message} - Unable to parse directive type: '${e}' based on the text: '${r}'`),{type:void 0,args:null}}},"detectDirective"),Tc=t(function(r){return r.replace(Jo,"")},"removeDirectives"),A2=t(function(r,e){for(let[o,a]of e.entries())if(a.match(r))return o;return-1},"isSubstringInArray");function bl(r,e){if(!r)return e;let o=`curve${r.charAt(0).toUpperCase()+r.slice(1)}`;return v2[o]??e}t(bl,"interpolateToCurve");function bm(r,e){let o=r.trim();if(!o)return;if(e.securityLevel!=="loose")return xm.sanitizeUrl(o);return o}t(bm,"formatUrl");var M2=t((r,...e)=>{let o=r.split("."),a=o.length-1,s=o[a],n=window;for(let c=0;c<a;c++)if(n=n[o[c]],!n){i.error(`Function name: ${r} not found in window`);return}n[s](...e)},"runFunc");function mf(r,e){if(!r||!e)return 0;return Math.sqrt(Math.pow(e.x-r.x,2)+Math.pow(e.y-r.y,2))}t(mf,"distance");function km(r){let e,o=0;r.forEach((s)=>{o+=mf(s,e),e=s});let a=o/2;return yf(r,a)}t(km,"traverseEdge");function wm(r){if(r.length===1)return r[0];return km(r)}t(wm,"calcLabelPosition");var mm=t((r,e=2)=>{let o=Math.pow(10,e);return Math.round(r*o)/o},"roundNumber"),yf=t((r,e)=>{let o=void 0,a=e;for(let s of r){if(o){let n=mf(s,o);if(n===0)return o;if(n<a)a-=n;else{let c=a/n;if(c<=0)return o;if(c>=1)return{x:s.x,y:s.y};if(c>0&&c<1)return{x:mm((1-c)*o.x+c*s.x,5),y:mm((1-c)*o.y+c*s.y,5)}}}o=s}throw Error("Could not find a suitable point for the given distance")},"calculatePoint"),E2=t((r,e,o)=>{if(i.info(`our points ${JSON.stringify(e)}`),e[0]!==o)e=e.reverse();let s=yf(e,25),n=r?10:5,c=Math.atan2(e[0].y-s.y,e[0].x-s.x),l={x:0,y:0};return l.x=Math.sin(c)*n+(e[0].x+s.x)/2,l.y=-Math.cos(c)*n+(e[0].y+s.y)/2,l},"calcCardinalityPosition");function Sm(r,e,o){let a=structuredClone(o);if(i.info("our points",a),e!=="start_left"&&e!=="start_right")a.reverse();let s=25+r,n=yf(a,s),c=10+r*0.5,l=Math.atan2(a[0].y-n.y,a[0].x-n.x),p={x:0,y:0};if(e==="start_left")p.x=Math.sin(l+Math.PI)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l+Math.PI)*c+(a[0].y+n.y)/2;else if(e==="end_right")p.x=Math.sin(l-Math.PI)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l-Math.PI)*c+(a[0].y+n.y)/2;else if(e==="end_left")p.x=Math.sin(l)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l)*c+(a[0].y+n.y)/2;else p.x=Math.sin(l)*c+(a[0].x+n.x)/2,p.y=-Math.cos(l)*c+(a[0].y+n.y)/2;return p}t(Sm,"calcTerminalLabelPosition");function Yo(r){let e="",o="";for(let a of r)if(a!==void 0)if(a.startsWith("color:")||a.startsWith("text-align:"))o=o+a+";";else e=e+a+";";return{style:e,labelStyle:o}}t(Yo,"getStylesFromArray");var ym=0,Zs=t(()=>(ym++,"id-"+Math.random().toString(36).substr(2,12)+"-"+ym),"generateId");function Tm(r){let e="",o="0123456789abcdef",a=o.length;for(let s=0;s<r;s++)e+=o.charAt(Math.floor(Math.random()*a));return e}t(Tm,"makeRandomHex");var Qs=t((r)=>Tm(r.length),"random"),O2=t(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),I2=t(function(r,e){let o=e.text.replace(C.lineBreakRegex," "),[,a]=Nt(e.fontSize),s=r.append("text");if(s.attr("x",e.x),s.attr("y",e.y),s.style("text-anchor",e.anchor),s.style("font-family",e.fontFamily),s.style("font-size",a),s.style("font-weight",e.fontWeight),s.attr("fill",e.fill),e.class!==void 0)s.attr("class",e.class);let n=s.append("tspan");return n.attr("x",e.x+e.textMargin*2),n.attr("fill",e.fill),n.text(o),s},"drawSimpleText"),Vr=ao((r,e,o)=>{if(!r)return r;if(o=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},o),C.hasBreaks(r))return r;let a=r.split(" ").filter(Boolean),s=[],n="";return a.forEach((c,l)=>{let p=Pt(`${c} `,o),m=Pt(n,o);if(p>e){let{hyphenatedStrings:x,remainingWord:k}=$2(c,e,"-",o);s.push(n,...x),n=k}else if(m+p>=e)s.push(n),n=c;else n=[n,c].filter(Boolean).join(" ");if(l+1===a.length)s.push(n)}),s.filter((c)=>c!=="").join(o.joinWith)},(r,e,o)=>`${r}${e}${o.fontSize}${o.fontWeight}${o.fontFamily}${o.joinWith}`),$2=ao((r,e,o="-",a)=>{a=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},a);let s=[...r],n=[],c="";return s.forEach((l,p)=>{let m=`${c}${l}`;if(Pt(m,a)>=e){let y=p+1,x=s.length===y,k=`${m}${o}`;n.push(x?m:k),c=""}else c=m}),{hyphenatedStrings:n,remainingWord:c}},(r,e,o="-",a)=>`${r}${e}${o}${a.fontSize}${a.fontWeight}${a.fontFamily}`);function Ii(r,e){return Di(r,e).height}t(Ii,"calculateTextHeight");function Pt(r,e){return Di(r,e).width}t(Pt,"calculateTextWidth");var Di=ao((r,e)=>{let{fontSize:o=12,fontFamily:a="Arial",fontWeight:s=400}=e;if(!r)return{width:0,height:0};let[,n]=Nt(o),c=["sans-serif",a],l=r.split(C.lineBreakRegex),p=[],m=g("body");if(!m.remove)return{width:0,height:0,lineHeight:0};let u=m.append("svg");for(let x of c){let k=0,w={width:0,height:0,lineHeight:0};for(let _ of l){let M=O2();M.text=_||Ks;let W=I2(u,M).style("font-size",n).style("font-weight",s).style("font-family",x),U=(W._groups||W)[0][0].getBBox();if(U.width===0&&U.height===0)throw Error("svg element not in render tree");w.width=Math.round(Math.max(w.width,U.width)),k=Math.round(U.height),w.height+=k,w.lineHeight=Math.round(Math.max(w.lineHeight,k))}p.push(w)}u.remove();let y=isNaN(p[1].height)||isNaN(p[1].width)||isNaN(p[1].lineHeight)||p[0].height>p[1].height&&p[0].width>p[1].width&&p[0].lineHeight>p[1].lineHeight?0:1;return p[y]},(r,e)=>`${r}${e.fontSize}${e.fontWeight}${e.fontFamily}`),D2=class{constructor(r=!1,e){this.count=0,this.count=e?e.length:0,this.next=r?()=>this.count++:()=>Date.now()}static{t(this,"InitIDGenerator")}},Cl,P2=t(function(r){return Cl=Cl||document.createElement("div"),r=escape(r).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),Cl.innerHTML=r,unescape(Cl.textContent)},"entityDecode");function Xo(r){return"str"in r}t(Xo,"isDetailedError");function Js(r){if(r instanceof Error)return r.message;return String(r)}t(Js,"getErrorMessage");var R2=t((r,e,o,a)=>{if(!a)return;let s=r.node()?.getBBox();if(!s)return;r.append("text").text(a).attr("text-anchor","middle").attr("x",s.x+s.width/2).attr("y",-o).attr("class",e)},"insertTitle"),Nt=t((r)=>{if(typeof r==="number")return[r,r+"px"];let e=parseInt(r??"",10);if(Number.isNaN(e))return[void 0,void 0];else if(r===String(e))return[e,r+"px"];else return[e,r]},"parseFontSize");function Q(r,e){return gf({},r,e)}t(Q,"cleanAndMerge");var H={assignWithDepth:Ae,wrapLabel:Vr,calculateTextHeight:Ii,calculateTextWidth:Pt,calculateTextDimensions:Di,cleanAndMerge:Q,detectInit:F2,detectDirective:Cm,isSubstringInArray:A2,interpolateToCurve:bl,calcLabelPosition:wm,calcCardinalityPosition:E2,calcTerminalLabelPosition:Sm,formatUrl:bm,getStylesFromArray:Yo,generateId:Zs,random:Qs,runFunc:M2,entityDecode:P2,insertTitle:R2,isLabelCoordinateInPath:_m,parseFontSize:Nt,InitIDGenerator:D2},Ec=t(function(r){let e=r;return e=e.replace(/style.*:\S*#.*;/g,function(o){return o.substring(0,o.length-1)}),e=e.replace(/classDef.*:\S*#.*;/g,function(o){return o.substring(0,o.length-1)}),e=e.replace(/#\w+;/g,function(o){let a=o.substring(1,o.length-1);if(/^\+?\d+$/.test(a))return"fl°°"+a+"¶ß";else return"fl°"+a+"¶ß"}),e},"encodeEntities"),Fn=t(function(r){return r.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),_t=t((r,e,{counter:o=0,prefix:a,suffix:s},n)=>{if(n)return n;return`${a?`${a}_`:""}${r}_${e}_${o}${s?`_${s}`:""}`},"getEdgeId");function Fe(r){return r??null}t(Fe,"handleUndefinedAttr");function _m(r,e){let o=Math.round(r.x),a=Math.round(r.y),s=e.replace(/(\d+\.\d+)/g,(n)=>Math.round(parseFloat(n)).toString());return s.includes(o.toString())||s.includes(a.toString())}t(_m,"isLabelCoordinateInPath");function Cf(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var lo=Cf();function Em(r){lo=r}var Ra={exec:()=>null};function Ce(r,e=""){let o=typeof r=="string"?r:r.source,a={replace:(s,n)=>{let c=typeof n=="string"?n:n.source;return c=c.replace(xr.caret,"$1"),o=o.replace(s,c),a},getRegex:()=>new RegExp(o,e)};return a}var q2=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),xr={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:(r)=>new RegExp(`^( {0,3}${r})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}#`),htmlBeginRegex:(r)=>new RegExp(`^ {0,${Math.min(3,r-1)}}<(?:[a-z].*>|!--)`,"i")},N2=/^(?:[ \t]*(?:\n|$))+/,W2=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,z2=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,Na=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,H2=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,bf=/(?:[*+-]|\d{1,9}[.)])/,Om=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Im=Ce(Om).replace(/bull/g,bf).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),Y2=Ce(Om).replace(/bull/g,bf).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),kf=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,U2=/^[^\n]+/,wf=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,j2=Ce(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",wf).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),G2=Ce(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,bf).getRegex(),_l="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Sf=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,X2=Ce("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",Sf).replace("tag",_l).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),$m=Ce(kf).replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex(),V2=Ce(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",$m).getRegex(),Tf={blockquote:V2,code:W2,def:j2,fences:z2,heading:H2,hr:Na,html:X2,lheading:Im,list:G2,newline:N2,paragraph:$m,table:Ra,text:U2},Bm=Ce("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex(),K2={...Tf,lheading:Y2,table:Bm,paragraph:Ce(kf).replace("hr",Na).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Bm).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",_l).getRegex()},Z2={...Tf,html:Ce(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",Sf).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Ra,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Ce(kf).replace("hr",Na).replace("heading",` *#{1,6} *[^
|
|
162
162
|
]`).replace("lheading",Im).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Q2=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,J2=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Dm=/^( {2,}|\\)\n(?!\s*$)/,tw=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Bl=/[\p{P}\p{S}]/u,_f=/[\s\p{P}\p{S}]/u,Pm=/[^\s\p{P}\p{S}]/u,ew=Ce(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,_f).getRegex(),Rm=/(?!~)[\p{P}\p{S}]/u,rw=/(?!~)[\s\p{P}\p{S}]/u,iw=/(?:[^\s\p{P}\p{S}]|~)/u,ow=Ce(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",q2?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),qm=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,sw=Ce(qm,"u").replace(/punct/g,Bl).getRegex(),aw=Ce(qm,"u").replace(/punct/g,Rm).getRegex(),Nm="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",nw=Ce(Nm,"gu").replace(/notPunctSpace/g,Pm).replace(/punctSpace/g,_f).replace(/punct/g,Bl).getRegex(),lw=Ce(Nm,"gu").replace(/notPunctSpace/g,iw).replace(/punctSpace/g,rw).replace(/punct/g,Rm).getRegex(),hw=Ce("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Pm).replace(/punctSpace/g,_f).replace(/punct/g,Bl).getRegex(),cw=Ce(/\\(punct)/,"gu").replace(/punct/g,Bl).getRegex(),uw=Ce(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),fw=Ce(Sf).replace("(?:-->|$)","-->").getRegex(),dw=Ce("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",fw).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),wl=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,pw=Ce(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",wl).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Wm=Ce(/^!?\[(label)\]\[(ref)\]/).replace("label",wl).replace("ref",wf).getRegex(),zm=Ce(/^!?\[(ref)\](?:\[\])?/).replace("ref",wf).getRegex(),gw=Ce("reflink|nolink(?!\\()","g").replace("reflink",Wm).replace("nolink",zm).getRegex(),vm=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,Bf={_backpedal:Ra,anyPunctuation:cw,autolink:uw,blockSkip:ow,br:Dm,code:J2,del:Ra,emStrongLDelim:sw,emStrongRDelimAst:nw,emStrongRDelimUnd:hw,escape:Q2,link:pw,nolink:zm,punctuation:ew,reflink:Wm,reflinkSearch:gw,tag:dw,text:tw,url:Ra},mw={...Bf,link:Ce(/^!?\[(label)\]\((.*?)\)/).replace("label",wl).getRegex(),reflink:Ce(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",wl).getRegex()},xf={...Bf,emStrongRDelimAst:lw,emStrongLDelim:aw,url:Ce(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",vm).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Ce(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",vm).getRegex()},yw={...xf,br:Ce(Dm).replace("{2,}","*").getRegex(),text:Ce(xf.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},kl={normal:Tf,gfm:K2,pedantic:Z2},$a={normal:Bf,gfm:xf,breaks:yw,pedantic:mw},xw={"&":"&","<":"<",">":">",'"':""","'":"'"},Lm=(r)=>xw[r];function li(r,e){if(e){if(xr.escapeTest.test(r))return r.replace(xr.escapeReplace,Lm)}else if(xr.escapeTestNoEncode.test(r))return r.replace(xr.escapeReplaceNoEncode,Lm);return r}function Fm(r){try{r=encodeURI(r).replace(xr.percentDecode,"%")}catch{return null}return r}function Am(r,e){let o=r.replace(xr.findPipe,(n,c,l)=>{let p=!1,m=c;for(;--m>=0&&l[m]==="\\";)p=!p;return p?"|":" |"}),a=o.split(xr.splitPipe),s=0;if(a[0].trim()||a.shift(),a.length>0&&!a.at(-1)?.trim()&&a.pop(),e)if(a.length>e)a.splice(e);else for(;a.length<e;)a.push("");for(;s<a.length;s++)a[s]=a[s].trim().replace(xr.slashPipe,"|");return a}function Da(r,e,o){let a=r.length;if(a===0)return"";let s=0;for(;s<a;){let n=r.charAt(a-s-1);if(n===e&&!o)s++;else if(n!==e&&o)s++;else break}return r.slice(0,a-s)}function Cw(r,e){if(r.indexOf(e[1])===-1)return-1;let o=0;for(let a=0;a<r.length;a++)if(r[a]==="\\")a++;else if(r[a]===e[0])o++;else if(r[a]===e[1]&&(o--,o<0))return a;return o>0?-2:-1}function Mm(r,e,o,a,s){let n=e.href,c=e.title||null,l=r[1].replace(s.other.outputLinkReplace,"$1");a.state.inLink=!0;let p={type:r[0].charAt(0)==="!"?"image":"link",raw:o,href:n,title:c,text:l,tokens:a.inlineTokens(l)};return a.state.inLink=!1,p}function bw(r,e,o){let a=r.match(o.other.indentCodeCompensation);if(a===null)return e;let s=a[1];return e.split(`
|
|
163
163
|
`).map((n)=>{let c=n.match(o.other.beginningSpace);if(c===null)return n;let[l]=c;return l.length>=s.length?n.slice(s.length):n}).join(`
|
|
164
164
|
`)}var Sl=class{options;rules;lexer;constructor(r){this.options=r||lo}space(r){let e=this.rules.block.newline.exec(r);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(r){let e=this.rules.block.code.exec(r);if(e){let o=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?o:Da(o,`
|
|
@@ -175,11 +175,11 @@ ${u}`:u;let y=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTo
|
|
|
175
175
|
`+o.join(`
|
|
176
176
|
`),_=this.list(w);n[n.length-1]=_,a=a.substring(0,a.length-x.raw.length)+_.raw,s=s.substring(0,s.length-k.raw.length)+_.raw,o=w.substring(n.at(-1).raw.length).split(`
|
|
177
177
|
`);continue}}return{type:"blockquote",raw:a,tokens:n,text:s}}}list(r){let e=this.rules.block.list.exec(r);if(e){let o=e[1].trim(),a=o.length>1,s={type:"list",raw:"",ordered:a,start:a?+o.slice(0,-1):"",loose:!1,items:[]};o=a?`\\d{1,9}\\${o.slice(-1)}`:`\\${o}`,this.options.pedantic&&(o=a?o:"[*+-]");let n=this.rules.other.listItemRegex(o),c=!1;for(;r;){let p=!1,m="",u="";if(!(e=n.exec(r))||this.rules.block.hr.test(r))break;m=e[0],r=r.substring(m.length);let y=e[2].split(`
|
|
178
|
-
`,1)[0].replace(this.rules.other.listReplaceTabs,(
|
|
178
|
+
`,1)[0].replace(this.rules.other.listReplaceTabs,(W)=>" ".repeat(3*W.length)),x=r.split(`
|
|
179
179
|
`,1)[0],k=!y.trim(),w=0;if(this.options.pedantic?(w=2,u=y.trimStart()):k?w=e[1].length+1:(w=e[2].search(this.rules.other.nonSpaceChar),w=w>4?1:w,u=y.slice(w),w+=e[1].length),k&&this.rules.other.blankLine.test(x)&&(m+=x+`
|
|
180
|
-
`,r=r.substring(x.length+1),p=!0),!p){let
|
|
181
|
-
`,1)[0],ot;if(x=at,this.options.pedantic?(x=x.replace(this.rules.other.listReplaceNesting," "),ot=x):ot=x.replace(this.rules.other.tabCharGlobal," "),V.test(x)||
|
|
182
|
-
`+ot.slice(w);else{if(k||y.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||V.test(y)||
|
|
180
|
+
`,r=r.substring(x.length+1),p=!0),!p){let W=this.rules.other.nextBulletRegex(w),U=this.rules.other.hrRegex(w),V=this.rules.other.fencesBeginRegex(w),Z=this.rules.other.headingBeginRegex(w),tt=this.rules.other.htmlBeginRegex(w);for(;r;){let at=r.split(`
|
|
181
|
+
`,1)[0],ot;if(x=at,this.options.pedantic?(x=x.replace(this.rules.other.listReplaceNesting," "),ot=x):ot=x.replace(this.rules.other.tabCharGlobal," "),V.test(x)||Z.test(x)||tt.test(x)||W.test(x)||U.test(x))break;if(ot.search(this.rules.other.nonSpaceChar)>=w||!x.trim())u+=`
|
|
182
|
+
`+ot.slice(w);else{if(k||y.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||V.test(y)||Z.test(y)||U.test(y))break;u+=`
|
|
183
183
|
`+x}!k&&!x.trim()&&(k=!0),m+=at+`
|
|
184
184
|
`,r=r.substring(at.length+1),y=ot.slice(w)}}s.loose||(c?s.loose=!0:this.rules.other.doubleBlankLine.test(m)&&(c=!0));let _=null,M;this.options.gfm&&(_=this.rules.other.listIsTask.exec(u),_&&(M=_[0]!=="[ ] ",u=u.replace(this.rules.other.listReplaceTask,""))),s.items.push({type:"list_item",raw:m,task:!!_,checked:M,loose:!1,text:u,tokens:[]}),s.raw+=m}let l=s.items.at(-1);if(l)l.raw=l.raw.trimEnd(),l.text=l.text.trimEnd();else return;s.raw=s.raw.trimEnd();for(let p=0;p<s.items.length;p++)if(this.lexer.state.top=!1,s.items[p].tokens=this.lexer.blockTokens(s.items[p].text,[]),!s.loose){let m=s.items[p].tokens.filter((y)=>y.type==="space"),u=m.length>0&&m.some((y)=>this.rules.other.anyLine.test(y.raw));s.loose=u}if(s.loose)for(let p=0;p<s.items.length;p++)s.items[p].loose=!0;return s}}html(r){let e=this.rules.block.html.exec(r);if(e)return{type:"html",block:!0,raw:e[0],pre:e[1]==="pre"||e[1]==="script"||e[1]==="style",text:e[0]}}def(r){let e=this.rules.block.def.exec(r);if(e){let o=e[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),a=e[2]?e[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",s=e[3]?e[3].substring(1,e[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):e[3];return{type:"def",tag:o,raw:e[0],href:a,title:s}}}table(r){let e=this.rules.block.table.exec(r);if(!e||!this.rules.other.tableDelimiter.test(e[2]))return;let o=Am(e[1]),a=e[2].replace(this.rules.other.tableAlignChars,"").split("|"),s=e[3]?.trim()?e[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
|
185
185
|
`):[],n={type:"table",raw:e[0],header:[],align:[],rows:[]};if(o.length===a.length){for(let c of a)this.rules.other.tableAlignRight.test(c)?n.align.push("right"):this.rules.other.tableAlignCenter.test(c)?n.align.push("center"):this.rules.other.tableAlignLeft.test(c)?n.align.push("left"):n.align.push(null);for(let c=0;c<o.length;c++)n.header.push({text:o[c],tokens:this.lexer.inline(o[c]),header:!0,align:n.align[c]});for(let c of s)n.rows.push(Am(c,n.header.length).map((l,p)=>({text:l,tokens:this.lexer.inline(l),header:!1,align:n.align[p]})));return n}}lheading(r){let e=this.rules.block.lheading.exec(r);if(e)return{type:"heading",raw:e[0],depth:e[2].charAt(0)==="="?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(r){let e=this.rules.block.paragraph.exec(r);if(e){let o=e[1].charAt(e[1].length-1)===`
|
|
@@ -229,16 +229,16 @@ ${s.join(`
|
|
|
229
229
|
`);return Ko(a)}t(Ym,"preprocessMarkdown");function Um(r){return r.split(/\\n|\n|<br\s*\/?>/gi).map((e)=>e.trim().match(/<[^>]+>|[^\s<>]+/g)?.map((o)=>({content:o,type:"normal"}))??[])}t(Um,"nonMarkdownToLines");function Zo(r,e={}){let o=Ym(r,e),a=ke.lexer(o),s=[[]],n=0;function c(l,p="normal"){if(l.type==="text")l.text.split(`
|
|
230
230
|
`).forEach((u,y)=>{if(y!==0)n++,s.push([]);u.split(" ").forEach((x)=>{if(x=x.replace(/'/g,"'"),x)s[n].push({content:x,type:p})})});else if(l.type==="strong"||l.type==="em")l.tokens.forEach((m)=>{c(m,l.type)});else if(l.type==="html")s[n].push({content:l.text,type:"normal"})}return t(c,"processNode"),a.forEach((l)=>{if(l.type==="paragraph")l.tokens?.forEach((p)=>{c(p)});else if(l.type==="html")s[n].push({content:l.text,type:"normal"});else s[n].push({content:l.raw,type:"normal"})}),s}t(Zo,"markdownToLines");function jm(r){if(!r)return"";return`<p>${r.replace(/\\n|\n/g,"<br />")}</p>`}t(jm,"nonMarkdownToHTML");function Gm(r,{markdownAutoWrap:e}={}){let o=ke.lexer(r);function a(s){if(s.type==="text"){if(e===!1)return s.text.replace(/\n */g,"<br/>").replace(/ /g," ");return s.text.replace(/\n */g,"<br/>")}else if(s.type==="strong")return`<strong>${s.tokens?.map(a).join("")}</strong>`;else if(s.type==="em")return`<em>${s.tokens?.map(a).join("")}</em>`;else if(s.type==="paragraph")return`<p>${s.tokens?.map(a).join("")}</p>`;else if(s.type==="space")return"";else if(s.type==="html")return`${s.text}`;else if(s.type==="escape")return s.text;return i.warn(`Unsupported markdown: ${s.type}`),s.raw}return t(a,"output"),o.map(a).join("")}t(Gm,"markdownToHTML");var _w=function(r){var e=function(){},o=r.requestAnimationFrame||r.webkitRequestAnimationFrame||r.mozRequestAnimationFrame||r.msRequestAnimationFrame||function(m){return setTimeout(m,16)};function a(){var m=this;m.reads=[],m.writes=[],m.raf=o.bind(r),e("initialized",m)}t(a,"FastDom"),a.prototype={constructor:a,runTasks:t(function(m){e("run tasks");var u;while(u=m.shift())u()},"runTasks"),measure:t(function(m,u){e("measure");var y=!u?m:m.bind(u);return this.reads.push(y),s(this),y},"measure"),mutate:t(function(m,u){e("mutate");var y=!u?m:m.bind(u);return this.writes.push(y),s(this),y},"mutate"),clear:t(function(m){return e("clear",m),c(this.reads,m)||c(this.writes,m)},"clear"),extend:t(function(m){if(e("extend",m),typeof m!="object")throw Error("expected object");var u=Object.create(this);if(l(u,m),u.fastdom=this,u.initialize)u.initialize();return u},"extend"),catch:null};function s(m){if(!m.scheduled)m.scheduled=!0,m.raf(n.bind(null,m)),e("flush scheduled")}t(s,"scheduleFlush");function n(m){e("flush");var{writes:u,reads:y}=m,x;try{e("flushing reads",y.length),m.runTasks(y),e("flushing writes",u.length),m.runTasks(u)}catch(k){x=k}if(m.scheduled=!1,y.length||u.length)s(m);if(x)if(e("task errored",x.message),m.catch)m.catch(x);else throw x}t(n,"flush");function c(m,u){var y=m.indexOf(u);return!!~y&&!!m.splice(y,1)}t(c,"remove");function l(m,u){for(var y in u)if(u.hasOwnProperty(y))m[y]=u[y]}t(l,"mixin");var p=r.fastdom=r.fastdom||new a;return p}(typeof window<"u"?window:globalThis),Xm={initialize:t(function(){this._tasks=new Map},"initialize"),mutate:t(function(r,e){return Af(this,"mutate",r,e)},"mutate"),measure:t(function(r,e){return Af(this,"measure",r,e)},"measure"),clear:t(function(r){var e=this._tasks,o=e.get(r);this.fastdom.clear(o),e.delete(r)},"clear")};function Af(r,e,o,a){var{_tasks:s,fastdom:n}=r,c,l=new Promise(function(p,m){c=n[e](function(){s.delete(l);try{p(a?o.call(a):o())}catch(u){m(u)}},a)});return s.set(l,c),l}t(Af,"create");var{initialize:p9,mutate:g9,measure:m9,clear:y9}=Xm,Bw=Xm,vw=_w.extend({raf(r){if(typeof queueMicrotask==="function")queueMicrotask(r);else setTimeout(r,0)}}).extend(Bw),Bi=vw;function Vm(r){if(Intl.Segmenter)return[...new Intl.Segmenter().segment(r)].map((e)=>e.segment);return[...r]}t(Vm,"splitTextToChars");function Km(r,e){let o=Vm(e.content);return Of(r,[],o,e.type)}t(Km,"splitWordToFitWidth");function Of(r,e,o,a){if(o.length===0)return[{content:e.join(""),type:a},{content:"",type:a}];let[s,...n]=o,c=[...e,s];if(r([{content:c.join(""),type:a}]))return Of(r,c,n,a);if(e.length===0&&s)e.push(s),o.shift();return[{content:e.join(""),type:a},{content:o.join(""),type:a}]}t(Of,"splitWordToFitWidthRecursion");function Zm(r,e){if(r.some(({content:o})=>o.includes(`
|
|
231
231
|
`)))throw Error("splitLineToFitWidth does not support newlines in the line");return vl(r,e)}t(Zm,"splitLineToFitWidth");function vl(r,e,o=[],a=[]){if(r.length===0){if(a.length>0)o.push(a);return o.length>0?o:[]}let s="";if(r[0].content===" ")s=" ",r.shift();let n=r.shift()??{content:" ",type:"normal"},c=[...a];if(s!=="")c.push({content:s,type:"normal"});if(c.push(n),e(c))return vl(r,e,o,c);if(a.length>0)o.push(a),r.unshift(n);else if(n.content){let[l,p]=Km(e,n);if(o.push([l]),p.content)r.unshift(p)}return vl(r,e,o)}t(vl,"splitLineToFitWidthRecursion");function Mf(r,e){if(e)r.attr("style",e)}t(Mf,"applyStyle");var Hm=16384;async function Qm(r,e,o,a,s=!1,n=A(),c=0){let l=r.append("foreignObject");l.attr("width",`${Math.min(10*o,Hm)}px`),l.attr("height",`${Math.min(10*o,Hm)}px`);let p=l.append("xhtml:div"),m=$e(e.label)?await Ga(e.label.replace(C.lineBreakRegex,`
|
|
232
|
-
`),n):j(e.label,n),u=e.isNode?"nodeLabel":"edgeLabel",y=p.append("span");if(y.html(m),Mf(y,e.labelStyle),y.attr("class",`${u} ${a}`),Mf(p,e.labelStyle),p.style("display","table-cell"),p.style("white-space","nowrap"),p.style("line-height","1.5"),o!==Number.POSITIVE_INFINITY)p.style("max-width",o+"px"),p.style("text-align","center");if(p.attr("xmlns","http://www.w3.org/1999/xhtml"),s)p.attr("class","labelBkg");let x=await Bi.measure(()=>p.node().getBoundingClientRect());if(x.width===o)p.style("display","table"),p.style("white-space","break-spaces"),p.style("width",o+"px");else if(x.width<c)p.style("display","table"),p.style("width",c+"px"),p.style("text-align","center");return l.node()}t(Qm,"addHtmlSpan");function Ll(r,e,o,a=!1){let s=r.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*o-0.1+"em").attr("dy",o+"em");if(a)s.attr("text-anchor","middle");return s}t(Ll,"createTspan");function Jm(r,e,o){let a=r.append("text"),s=Ll(a,1,e);Fl(s,o);let n=s.node().getComputedTextLength();return a.remove(),n}t(Jm,"computeWidthOfText");function ec(r,e,o){let a=r.append("text"),s=Ll(a,1,e);Fl(s,[{content:o,type:"normal"}]);let n=s.node()?.getBoundingClientRect();if(n)a.remove();return n}t(ec,"computeDimensionOfText");function ty(r,e,o,a=!1,s=!1){let c=e.append("g"),l=c.insert("rect").attr("class","background").attr("style","stroke: none"),p=c.append("text").attr("y","-10.1");if(s)p.attr("text-anchor","middle");let m=0;for(let u of o){let y=t((k)=>Jm(c,1.1,k)<=r,"checkWidth"),x=y(u)?[u]:Zm(u,y);for(let k of x){let w=Ll(p,m,1.1,s);Fl(w,k),m++}}if(a){let u=p.node().getBBox(),y=2;return l.attr("x",u.x-2).attr("y",u.y-2).attr("width",u.width+4).attr("height",u.height+4),c.node()}else return p.node()}t(ty,"createFormattedText");function Ef(r){let e=/&(amp|lt|gt);/g;return r.replace(e,(o,a)=>{switch(a){case"amp":return"&";case"lt":return"<";case"gt":return">";default:return o}})}t(Ef,"decodeHTMLEntities");function Fl(r,e){r.text(""),e.forEach((o,a)=>{let s=r.append("tspan").attr("font-style",o.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",o.type==="strong"?"bold":"normal");if(a===0)s.text(Ef(o.content));else s.text(" "+Ef(o.content))})}t(Fl,"updateTextContentAndStyles");async function ey(r,e={}){let o=[];r.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(s,n,c)=>(o.push((async()=>{let l=`${n}:${c}`;if(await gl(l))return await Gt(l,void 0,{class:"label-icon"});else return`<i class='${j(s,e).replace(":"," ")}'></i>`})()),s));let a=await Promise.all(o);return r.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>a.shift()??"")}t(ey,"replaceIconSubstring");var ct=t(async(r,e="",{style:o="",isTitle:a=!1,classes:s="",useHtmlLabels:n=!0,markdown:c=!0,isNode:l=!0,width:p=200,minWidth:m=0,addSvgBackground:u=!1}={},y)=>{if(i.debug("XYZ createText",e,o,a,s,n,l,"addSvgBackground: ",u),n){let x=c?Gm(e,y):jm(e),k=await ey(Fn(x),y),w=e.replace(/\\\\/g,"\\"),_={isNode:l,label:$e(e)?w:k,labelStyle:o.replace("fill:","color:")};return await Qm(r,_,p,s,u,y,m)}else{let x=Fn(e.replace(/<br\s*\/?>/g,"<br/>")),k=c?Zo(x.replace("<br>","<br/>"),y):Um(x),w=ty(p,r,k,e?u:!1,!l);if(l){if(/stroke:/.exec(o))o=o.replace("stroke:","lineColor:");let _=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");g(w).attr("style",_)}else{let _=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");g(w).select("rect").attr("style",_.replace(/background:/g,"fill:"));let M=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");g(w).select("text").attr("style",M)}if(a)g(w).selectAll("tspan.text-outer-tspan").classed("title-row",!0);else g(w).selectAll("tspan.text-outer-tspan").classed("row",!0);return w}},"createText");var Oi=new Set(["redux-color","redux-dark-color"]),Lw=12,Fw=64,Re=t((r)=>Array.isArray(r)&&r.length>0,"hasPalette"),Te=t((r,e)=>r!=null&&Oi.has(r)&&Re(e),"isColorTheme"),Aw=/^[\w-]+$/,Ee=t((r)=>{let e=typeof r==="string"||typeof r==="number"?String(r):"";return Aw.test(e)?e:"classic"},"safeLook"),un=t((r)=>Re(r)?r.length:0,"paletteSlotCount"),Rt=t((r,e)=>{if(Re(e))return un(e);return typeof r==="number"&&Number.isInteger(r)&&r>0&&r<=Fw?r:Lw},"colorSlotCount"),It=t((r,e,o,a)=>{if(e===void 0||!Te(o,a))return;let s=e%un(a);r.attr("data-color-id",`color-${s}`)},"stampColorSlot");function If(r,e,o){if(r&&r.length){let[a,s]=e,n=Math.PI/180*o,c=Math.cos(n),l=Math.sin(n);for(let p of r){let[m,u]=p;p[0]=(m-a)*c-(u-s)*l+a,p[1]=(m-a)*l+(u-s)*c+s}}}function Mw(r,e){return r[0]===e[0]&&r[1]===e[1]}function Ew(r,e,o,a=1){let s=o,n=Math.max(e,0.1),c=r[0]&&r[0][0]&&typeof r[0][0]=="number"?[r]:r,l=[0,0];if(s)for(let m of c)If(m,l,s);let p=function(m,u,y){let x=[];for(let Y of m){let V=[...Y];Mw(V[0],V[V.length-1])||V.push([V[0][0],V[0][1]]),V.length>2&&x.push(V)}let k=[];u=Math.max(u,0.1);let w=[];for(let Y of x)for(let V=0;V<Y.length-1;V++){let Q=Y[V],tt=Y[V+1];if(Q[1]!==tt[1]){let at=Math.min(Q[1],tt[1]);w.push({ymin:at,ymax:Math.max(Q[1],tt[1]),x:at===Q[1]?Q[0]:tt[0],islope:(tt[0]-Q[0])/(tt[1]-Q[1])})}}if(w.sort((Y,V)=>Y.ymin<V.ymin?-1:Y.ymin>V.ymin?1:Y.x<V.x?-1:Y.x>V.x?1:Y.ymax===V.ymax?0:(Y.ymax-V.ymax)/Math.abs(Y.ymax-V.ymax)),!w.length)return k;let _=[],M=w[0].ymin,q=0;for(;_.length||w.length;){if(w.length){let Y=-1;for(let V=0;V<w.length&&!(w[V].ymin>M);V++)Y=V;w.splice(0,Y+1).forEach((V)=>{_.push({s:M,edge:V})})}if(_=_.filter((Y)=>!(Y.edge.ymax<=M)),_.sort((Y,V)=>Y.edge.x===V.edge.x?0:(Y.edge.x-V.edge.x)/Math.abs(Y.edge.x-V.edge.x)),(y!==1||q%u==0)&&_.length>1)for(let Y=0;Y<_.length;Y+=2){let V=Y+1;if(V>=_.length)break;let Q=_[Y].edge,tt=_[V].edge;k.push([[Math.round(Q.x),M],[Math.round(tt.x),M]])}M+=y,_.forEach((Y)=>{Y.edge.x=Y.edge.x+y*Y.edge.islope}),q++}return k}(c,n,a);if(s){for(let m of c)If(m,l,-s);(function(m,u,y){let x=[];m.forEach((k)=>x.push(...k)),If(x,u,y)})(p,l,-s)}return p}function tn(r,e){var o;let a=e.hachureAngle+90,s=e.hachureGap;s<0&&(s=4*e.strokeWidth),s=Math.round(Math.max(s,0.1));let n=1;return e.roughness>=1&&(((o=e.randomizer)===null||o===void 0?void 0:o.next())||Math.random())>0.7&&(n=s),Ew(r,s,a,n||1)}class Rl{constructor(r){this.helper=r}fillPolygons(r,e){return this._fillPolygons(r,e)}_fillPolygons(r,e){let o=tn(r,e);return{type:"fillSketch",ops:this.renderLines(o,e)}}renderLines(r,e){let o=[];for(let a of r)o.push(...this.helper.doubleLineOps(a[0][0],a[0][1],a[1][0],a[1][1],e));return o}}function ql(r){let e=r[0],o=r[1];return Math.sqrt(Math.pow(e[0]-o[0],2)+Math.pow(e[1]-o[1],2))}class cy extends Rl{fillPolygons(r,e){let o=e.hachureGap;o<0&&(o=4*e.strokeWidth),o=Math.max(o,0.1);let a=tn(r,Object.assign({},e,{hachureGap:o})),s=Math.PI/180*e.hachureAngle,n=[],c=0.5*o*Math.cos(s),l=0.5*o*Math.sin(s);for(let[p,m]of a)ql([p,m])&&n.push([[p[0]-c,p[1]+l],[...m]],[[p[0]+c,p[1]-l],[...m]]);return{type:"fillSketch",ops:this.renderLines(n,e)}}}class uy extends Rl{fillPolygons(r,e){let o=this._fillPolygons(r,e),a=Object.assign({},e,{hachureAngle:e.hachureAngle+90}),s=this._fillPolygons(r,a);return o.ops=o.ops.concat(s.ops),o}}class fy{constructor(r){this.helper=r}fillPolygons(r,e){let o=tn(r,e=Object.assign({},e,{hachureAngle:0}));return this.dotsOnLines(o,e)}dotsOnLines(r,e){let o=[],a=e.hachureGap;a<0&&(a=4*e.strokeWidth),a=Math.max(a,0.1);let s=e.fillWeight;s<0&&(s=e.strokeWidth/2);let n=a/4;for(let c of r){let l=ql(c),p=l/a,m=Math.ceil(p)-1,u=l-m*a,y=(c[0][0]+c[1][0])/2-a/4,x=Math.min(c[0][1],c[1][1]);for(let k=0;k<m;k++){let w=x+u+k*a,_=y-n+2*Math.random()*n,M=w-n+2*Math.random()*n,q=this.helper.ellipse(_,M,s,s,e);o.push(...q.ops)}}return{type:"fillSketch",ops:o}}}class dy{constructor(r){this.helper=r}fillPolygons(r,e){let o=tn(r,e);return{type:"fillSketch",ops:this.dashedLine(o,e)}}dashedLine(r,e){let o=e.dashOffset<0?e.hachureGap<0?4*e.strokeWidth:e.hachureGap:e.dashOffset,a=e.dashGap<0?e.hachureGap<0?4*e.strokeWidth:e.hachureGap:e.dashGap,s=[];return r.forEach((n)=>{let c=ql(n),l=Math.floor(c/(o+a)),p=(c+a-l*(o+a))/2,m=n[0],u=n[1];m[0]>u[0]&&(m=n[1],u=n[0]);let y=Math.atan((u[1]-m[1])/(u[0]-m[0]));for(let x=0;x<l;x++){let k=x*(o+a),w=k+o,_=[m[0]+k*Math.cos(y)+p*Math.cos(y),m[1]+k*Math.sin(y)+p*Math.sin(y)],M=[m[0]+w*Math.cos(y)+p*Math.cos(y),m[1]+w*Math.sin(y)+p*Math.sin(y)];s.push(...this.helper.doubleLineOps(_[0],_[1],M[0],M[1],e))}}),s}}class py{constructor(r){this.helper=r}fillPolygons(r,e){let o=e.hachureGap<0?4*e.strokeWidth:e.hachureGap,a=e.zigzagOffset<0?o:e.zigzagOffset,s=tn(r,e=Object.assign({},e,{hachureGap:o+a}));return{type:"fillSketch",ops:this.zigzagLines(s,a,e)}}zigzagLines(r,e,o){let a=[];return r.forEach((s)=>{let n=ql(s),c=Math.round(n/(2*e)),l=s[0],p=s[1];l[0]>p[0]&&(l=s[1],p=s[0]);let m=Math.atan((p[1]-l[1])/(p[0]-l[0]));for(let u=0;u<c;u++){let y=2*u*e,x=2*(u+1)*e,k=Math.sqrt(2*Math.pow(e,2)),w=[l[0]+y*Math.cos(m),l[1]+y*Math.sin(m)],_=[l[0]+x*Math.cos(m),l[1]+x*Math.sin(m)],M=[w[0]+k*Math.cos(m+Math.PI/4),w[1]+k*Math.sin(m+Math.PI/4)];a.push(...this.helper.doubleLineOps(w[0],w[1],M[0],M[1],o),...this.helper.doubleLineOps(M[0],M[1],_[0],_[1],o))}}),a}}var Sr={};class gy{constructor(r){this.seed=r}next(){return this.seed?(2147483647&(this.seed=Math.imul(48271,this.seed)))/2147483648:Math.random()}}var Ow=0,$f=1,ry=2,Al={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Df(r,e){return r.type===e}function zf(r){let e=[],o=function(c){let l=[];for(;c!=="";)if(c.match(/^([ \t\r\n,]+)/))c=c.substr(RegExp.$1.length);else if(c.match(/^([aAcChHlLmMqQsStTvVzZ])/))l[l.length]={type:Ow,text:RegExp.$1},c=c.substr(RegExp.$1.length);else{if(!c.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];l[l.length]={type:$f,text:`${parseFloat(RegExp.$1)}`},c=c.substr(RegExp.$1.length)}return l[l.length]={type:ry,text:""},l}(r),a="BOD",s=0,n=o[s];for(;!Df(n,ry);){let c=0,l=[];if(a==="BOD"){if(n.text!=="M"&&n.text!=="m")return zf("M0,0"+r);s++,c=Al[n.text],a=n.text}else Df(n,$f)?c=Al[a]:(s++,c=Al[n.text],a=n.text);if(!(s+c<o.length))throw Error("Path data ended short");for(let p=s;p<s+c;p++){let m=o[p];if(!Df(m,$f))throw Error("Param not a number: "+a+","+m.text);l[l.length]=+m.text}if(typeof Al[a]!="number")throw Error("Bad segment: "+a);{let p={key:a,data:l};e.push(p),s+=c,n=o[s],a==="M"&&(a="L"),a==="m"&&(a="l")}}return e}function my(r){let e=0,o=0,a=0,s=0,n=[];for(let{key:c,data:l}of r)switch(c){case"M":n.push({key:"M",data:[...l]}),[e,o]=l,[a,s]=l;break;case"m":e+=l[0],o+=l[1],n.push({key:"M",data:[e,o]}),a=e,s=o;break;case"L":n.push({key:"L",data:[...l]}),[e,o]=l;break;case"l":e+=l[0],o+=l[1],n.push({key:"L",data:[e,o]});break;case"C":n.push({key:"C",data:[...l]}),e=l[4],o=l[5];break;case"c":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"C",data:p}),e=p[4],o=p[5];break}case"Q":n.push({key:"Q",data:[...l]}),e=l[2],o=l[3];break;case"q":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"Q",data:p}),e=p[2],o=p[3];break}case"A":n.push({key:"A",data:[...l]}),e=l[5],o=l[6];break;case"a":e+=l[5],o+=l[6],n.push({key:"A",data:[l[0],l[1],l[2],l[3],l[4],e,o]});break;case"H":n.push({key:"H",data:[...l]}),e=l[0];break;case"h":e+=l[0],n.push({key:"H",data:[e]});break;case"V":n.push({key:"V",data:[...l]}),o=l[0];break;case"v":o+=l[0],n.push({key:"V",data:[o]});break;case"S":n.push({key:"S",data:[...l]}),e=l[2],o=l[3];break;case"s":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"S",data:p}),e=p[2],o=p[3];break}case"T":n.push({key:"T",data:[...l]}),e=l[0],o=l[1];break;case"t":e+=l[0],o+=l[1],n.push({key:"T",data:[e,o]});break;case"Z":case"z":n.push({key:"Z",data:[]}),e=a,o=s}return n}function yy(r){let e=[],o="",a=0,s=0,n=0,c=0,l=0,p=0;for(let{key:m,data:u}of r){switch(m){case"M":e.push({key:"M",data:[...u]}),[a,s]=u,[n,c]=u;break;case"C":e.push({key:"C",data:[...u]}),a=u[4],s=u[5],l=u[2],p=u[3];break;case"L":e.push({key:"L",data:[...u]}),[a,s]=u;break;case"H":a=u[0],e.push({key:"L",data:[a,s]});break;case"V":s=u[0],e.push({key:"L",data:[a,s]});break;case"S":{let y=0,x=0;o==="C"||o==="S"?(y=a+(a-l),x=s+(s-p)):(y=a,x=s),e.push({key:"C",data:[y,x,...u]}),l=u[0],p=u[1],a=u[2],s=u[3];break}case"T":{let[y,x]=u,k=0,w=0;o==="Q"||o==="T"?(k=a+(a-l),w=s+(s-p)):(k=a,w=s);let _=a+2*(k-a)/3,M=s+2*(w-s)/3,q=y+2*(k-y)/3,Y=x+2*(w-x)/3;e.push({key:"C",data:[_,M,q,Y,y,x]}),l=k,p=w,a=y,s=x;break}case"Q":{let[y,x,k,w]=u,_=a+2*(y-a)/3,M=s+2*(x-s)/3,q=k+2*(y-k)/3,Y=w+2*(x-w)/3;e.push({key:"C",data:[_,M,q,Y,k,w]}),l=y,p=x,a=k,s=w;break}case"A":{let y=Math.abs(u[0]),x=Math.abs(u[1]),k=u[2],w=u[3],_=u[4],M=u[5],q=u[6];if(y===0||x===0)e.push({key:"C",data:[a,s,M,q,M,q]}),a=M,s=q;else if(a!==M||s!==q)xy(a,s,M,q,y,x,k,w,_).forEach(function(Y){e.push({key:"C",data:Y})}),a=M,s=q;break}case"Z":e.push({key:"Z",data:[]}),a=n,s=c}o=m}return e}function za(r,e,o){return[r*Math.cos(o)-e*Math.sin(o),r*Math.sin(o)+e*Math.cos(o)]}function xy(r,e,o,a,s,n,c,l,p,m){let u=(y=c,Math.PI*y/180);var y;let x=[],k=0,w=0,_=0,M=0;if(m)[k,w,_,M]=m;else{[r,e]=za(r,e,-u),[o,a]=za(o,a,-u);let rt=(r-o)/2,it=(e-a)/2,gt=rt*rt/(s*s)+it*it/(n*n);gt>1&&(gt=Math.sqrt(gt),s*=gt,n*=gt);let et=s*s,wt=n*n,vt=et*wt-et*it*it-wt*rt*rt,Xt=et*it*it+wt*rt*rt,jt=(l===p?-1:1)*Math.sqrt(Math.abs(vt/Xt));_=jt*s*it/n+(r+o)/2,M=jt*-n*rt/s+(e+a)/2,k=Math.asin(parseFloat(((e-M)/n).toFixed(9))),w=Math.asin(parseFloat(((a-M)/n).toFixed(9))),r<_&&(k=Math.PI-k),o<_&&(w=Math.PI-w),k<0&&(k=2*Math.PI+k),w<0&&(w=2*Math.PI+w),p&&k>w&&(k-=2*Math.PI),!p&&w>k&&(w-=2*Math.PI)}let q=w-k;if(Math.abs(q)>120*Math.PI/180){let rt=w,it=o,gt=a;w=p&&w>k?k+120*Math.PI/180*1:k+120*Math.PI/180*-1,x=xy(o=_+s*Math.cos(w),a=M+n*Math.sin(w),it,gt,s,n,c,0,p,[w,rt,_,M])}q=w-k;let Y=Math.cos(k),V=Math.sin(k),Q=Math.cos(w),tt=Math.sin(w),at=Math.tan(q/4),ot=1.3333333333333333*s*at,ht=1.3333333333333333*n*at,yt=[r,e],Bt=[r+ot*V,e-ht*Y],kt=[o+ot*tt,a-ht*Q],Ct=[o,a];if(Bt[0]=2*yt[0]-Bt[0],Bt[1]=2*yt[1]-Bt[1],m)return[Bt,kt,Ct].concat(x);{x=[Bt,kt,Ct].concat(x);let rt=[];for(let it=0;it<x.length;it+=3){let gt=za(x[it][0],x[it][1],u),et=za(x[it+1][0],x[it+1][1],u),wt=za(x[it+2][0],x[it+2][1],u);rt.push([gt[0],gt[1],et[0],et[1],wt[0],wt[1]])}return rt}}var Iw={randOffset:function(r,e){return le(r,e)},randOffsetWithRange:function(r,e,o){return $l(r,e,o)},ellipse:function(r,e,o,a,s){let n=by(o,a,s);return qf(r,e,s,n).opset},doubleLineOps:function(r,e,o,a,s){return Qi(r,e,o,a,s,!0)}};function Cy(r,e,o,a,s){return{type:"path",ops:Qi(r,e,o,a,s)}}function Ol(r,e,o){let a=(r||[]).length;if(a>2){let s=[];for(let n=0;n<a-1;n++)s.push(...Qi(r[n][0],r[n][1],r[n+1][0],r[n+1][1],o));return e&&s.push(...Qi(r[a-1][0],r[a-1][1],r[0][0],r[0][1],o)),{type:"path",ops:s}}return a===2?Cy(r[0][0],r[0][1],r[1][0],r[1][1],o):{type:"path",ops:[]}}function $w(r,e,o,a,s){return function(n,c){return Ol(n,!0,c)}([[r,e],[r+o,e],[r+o,e+a],[r,e+a]],s)}function iy(r,e){if(r.length){let o=typeof r[0][0]=="number"?[r]:r,a=Ml(o[0],1*(1+0.2*e.roughness),e),s=e.disableMultiStroke?[]:Ml(o[0],1.5*(1+0.22*e.roughness),ay(e));for(let n=1;n<o.length;n++){let c=o[n];if(c.length){let l=Ml(c,1*(1+0.2*e.roughness),e),p=e.disableMultiStroke?[]:Ml(c,1.5*(1+0.22*e.roughness),ay(e));for(let m of l)m.op!=="move"&&a.push(m);for(let m of p)m.op!=="move"&&s.push(m)}}return{type:"path",ops:a.concat(s)}}return{type:"path",ops:[]}}function by(r,e,o){let a=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(r/2,2)+Math.pow(e/2,2))/2)),s=Math.ceil(Math.max(o.curveStepCount,o.curveStepCount/Math.sqrt(200)*a)),n=2*Math.PI/s,c=Math.abs(r/2),l=Math.abs(e/2),p=1-o.curveFitting;return c+=le(c*p,o),l+=le(l*p,o),{increment:n,rx:c,ry:l}}function qf(r,e,o,a){let[s,n]=ny(a.increment,r,e,a.rx,a.ry,1,a.increment*$l(0.1,$l(0.4,1,o),o),o),c=Dl(s,null,o);if(!o.disableMultiStroke&&o.roughness!==0){let[l]=ny(a.increment,r,e,a.rx,a.ry,1.5,0,o),p=Dl(l,null,o);c=c.concat(p)}return{estimatedPoints:n,opset:{type:"path",ops:c}}}function oy(r,e,o,a,s,n,c,l,p){let m=r,u=e,y=Math.abs(o/2),x=Math.abs(a/2);y+=le(0.01*y,p),x+=le(0.01*x,p);let k=s,w=n;for(;k<0;)k+=2*Math.PI,w+=2*Math.PI;w-k>2*Math.PI&&(k=0,w=2*Math.PI);let _=2*Math.PI/p.curveStepCount,M=Math.min(_/2,(w-k)/2),q=ly(M,m,u,y,x,k,w,1,p);if(!p.disableMultiStroke){let Y=ly(M,m,u,y,x,k,w,1.5,p);q.push(...Y)}return c&&(l?q.push(...Qi(m,u,m+y*Math.cos(k),u+x*Math.sin(k),p),...Qi(m,u,m+y*Math.cos(w),u+x*Math.sin(w),p)):q.push({op:"lineTo",data:[m,u]},{op:"lineTo",data:[m+y*Math.cos(k),u+x*Math.sin(k)]})),{type:"path",ops:q}}function sy(r,e){let o=yy(my(zf(r))),a=[],s=[0,0],n=[0,0];for(let{key:c,data:l}of o)switch(c){case"M":n=[l[0],l[1]],s=[l[0],l[1]];break;case"L":a.push(...Qi(n[0],n[1],l[0],l[1],e)),n=[l[0],l[1]];break;case"C":{let[p,m,u,y,x,k]=l;a.push(...Dw(p,m,u,y,x,k,n,e)),n=[x,k];break}case"Z":a.push(...Qi(n[0],n[1],s[0],s[1],e)),n=[s[0],s[1]]}return{type:"path",ops:a}}function Pf(r,e){let o=[];for(let a of r)if(a.length){let s=e.maxRandomnessOffset||0,n=a.length;if(n>2){o.push({op:"move",data:[a[0][0]+le(s,e),a[0][1]+le(s,e)]});for(let c=1;c<n;c++)o.push({op:"lineTo",data:[a[c][0]+le(s,e),a[c][1]+le(s,e)]})}}return{type:"fillPath",ops:o}}function xs(r,e){return function(o,a){let s=o.fillStyle||"hachure";if(!Sr[s])switch(s){case"zigzag":Sr[s]||(Sr[s]=new cy(a));break;case"cross-hatch":Sr[s]||(Sr[s]=new uy(a));break;case"dots":Sr[s]||(Sr[s]=new fy(a));break;case"dashed":Sr[s]||(Sr[s]=new dy(a));break;case"zigzag-line":Sr[s]||(Sr[s]=new py(a));break;default:s="hachure",Sr[s]||(Sr[s]=new Rl(a))}return Sr[s]}(e,Iw).fillPolygons(r,e)}function ay(r){let e=Object.assign({},r);return e.randomizer=void 0,r.seed&&(e.seed=r.seed+1),e}function ky(r){return r.randomizer||(r.randomizer=new gy(r.seed||0)),r.randomizer.next()}function $l(r,e,o,a=1){return o.roughness*a*(ky(o)*(e-r)+r)}function le(r,e,o=1){return $l(-r,r,e,o)}function Qi(r,e,o,a,s,n=!1){let c=n?s.disableMultiStrokeFill:s.disableMultiStroke,l=Nf(r,e,o,a,s,!0,!1);if(c)return l;let p=Nf(r,e,o,a,s,!0,!0);return l.concat(p)}function Nf(r,e,o,a,s,n,c){let l=Math.pow(r-o,2)+Math.pow(e-a,2),p=Math.sqrt(l),m=1;m=p<200?1:p>500?0.4:-0.0016668*p+1.233334;let u=s.maxRandomnessOffset||0;u*u*100>l&&(u=p/10);let y=u/2,x=0.2+0.2*ky(s),k=s.bowing*s.maxRandomnessOffset*(a-e)/200,w=s.bowing*s.maxRandomnessOffset*(r-o)/200;k=le(k,s,m),w=le(w,s,m);let _=[],M=()=>le(y,s,m),q=()=>le(u,s,m),Y=s.preserveVertices;return n&&(c?_.push({op:"move",data:[r+(Y?0:M()),e+(Y?0:M())]}):_.push({op:"move",data:[r+(Y?0:le(u,s,m)),e+(Y?0:le(u,s,m))]})),c?_.push({op:"bcurveTo",data:[k+r+(o-r)*x+M(),w+e+(a-e)*x+M(),k+r+2*(o-r)*x+M(),w+e+2*(a-e)*x+M(),o+(Y?0:M()),a+(Y?0:M())]}):_.push({op:"bcurveTo",data:[k+r+(o-r)*x+q(),w+e+(a-e)*x+q(),k+r+2*(o-r)*x+q(),w+e+2*(a-e)*x+q(),o+(Y?0:q()),a+(Y?0:q())]}),_}function Ml(r,e,o){if(!r.length)return[];let a=[];a.push([r[0][0]+le(e,o),r[0][1]+le(e,o)]),a.push([r[0][0]+le(e,o),r[0][1]+le(e,o)]);for(let s=1;s<r.length;s++)a.push([r[s][0]+le(e,o),r[s][1]+le(e,o)]),s===r.length-1&&a.push([r[s][0]+le(e,o),r[s][1]+le(e,o)]);return Dl(a,null,o)}function Dl(r,e,o){let a=r.length,s=[];if(a>3){let n=[],c=1-o.curveTightness;s.push({op:"move",data:[r[1][0],r[1][1]]});for(let l=1;l+2<a;l++){let p=r[l];n[0]=[p[0],p[1]],n[1]=[p[0]+(c*r[l+1][0]-c*r[l-1][0])/6,p[1]+(c*r[l+1][1]-c*r[l-1][1])/6],n[2]=[r[l+1][0]+(c*r[l][0]-c*r[l+2][0])/6,r[l+1][1]+(c*r[l][1]-c*r[l+2][1])/6],n[3]=[r[l+1][0],r[l+1][1]],s.push({op:"bcurveTo",data:[n[1][0],n[1][1],n[2][0],n[2][1],n[3][0],n[3][1]]})}if(e&&e.length===2){let l=o.maxRandomnessOffset;s.push({op:"lineTo",data:[e[0]+le(l,o),e[1]+le(l,o)]})}}else a===3?(s.push({op:"move",data:[r[1][0],r[1][1]]}),s.push({op:"bcurveTo",data:[r[1][0],r[1][1],r[2][0],r[2][1],r[2][0],r[2][1]]})):a===2&&s.push(...Nf(r[0][0],r[0][1],r[1][0],r[1][1],o,!0,!0));return s}function ny(r,e,o,a,s,n,c,l){let p=[],m=[];if(l.roughness===0){r/=4,m.push([e+a*Math.cos(-r),o+s*Math.sin(-r)]);for(let u=0;u<=2*Math.PI;u+=r){let y=[e+a*Math.cos(u),o+s*Math.sin(u)];p.push(y),m.push(y)}m.push([e+a*Math.cos(0),o+s*Math.sin(0)]),m.push([e+a*Math.cos(r),o+s*Math.sin(r)])}else{let u=le(0.5,l)-Math.PI/2;m.push([le(n,l)+e+0.9*a*Math.cos(u-r),le(n,l)+o+0.9*s*Math.sin(u-r)]);let y=2*Math.PI+u-0.01;for(let x=u;x<y;x+=r){let k=[le(n,l)+e+a*Math.cos(x),le(n,l)+o+s*Math.sin(x)];p.push(k),m.push(k)}m.push([le(n,l)+e+a*Math.cos(u+2*Math.PI+0.5*c),le(n,l)+o+s*Math.sin(u+2*Math.PI+0.5*c)]),m.push([le(n,l)+e+0.98*a*Math.cos(u+c),le(n,l)+o+0.98*s*Math.sin(u+c)]),m.push([le(n,l)+e+0.9*a*Math.cos(u+0.5*c),le(n,l)+o+0.9*s*Math.sin(u+0.5*c)])}return[m,p]}function ly(r,e,o,a,s,n,c,l,p){let m=n+le(0.1,p),u=[];u.push([le(l,p)+e+0.9*a*Math.cos(m-r),le(l,p)+o+0.9*s*Math.sin(m-r)]);for(let y=m;y<=c;y+=r)u.push([le(l,p)+e+a*Math.cos(y),le(l,p)+o+s*Math.sin(y)]);return u.push([e+a*Math.cos(c),o+s*Math.sin(c)]),u.push([e+a*Math.cos(c),o+s*Math.sin(c)]),Dl(u,null,p)}function Dw(r,e,o,a,s,n,c,l){let p=[],m=[l.maxRandomnessOffset||1,(l.maxRandomnessOffset||1)+0.3],u=[0,0],y=l.disableMultiStroke?1:2,x=l.preserveVertices;for(let k=0;k<y;k++)k===0?p.push({op:"move",data:[c[0],c[1]]}):p.push({op:"move",data:[c[0]+(x?0:le(m[0],l)),c[1]+(x?0:le(m[0],l))]}),u=x?[s,n]:[s+le(m[k],l),n+le(m[k],l)],p.push({op:"bcurveTo",data:[r+le(m[k],l),e+le(m[k],l),o+le(m[k],l),a+le(m[k],l),u[0],u[1]]});return p}function Ha(r){return[...r]}function hy(r,e=0){let o=r.length;if(o<3)throw Error("A curve must have at least three points.");let a=[];if(o===3)a.push(Ha(r[0]),Ha(r[1]),Ha(r[2]),Ha(r[2]));else{let s=[];s.push(r[0],r[0]);for(let l=1;l<r.length;l++)s.push(r[l]),l===r.length-1&&s.push(r[l]);let n=[],c=1-e;a.push(Ha(s[0]));for(let l=1;l+2<s.length;l++){let p=s[l];n[0]=[p[0],p[1]],n[1]=[p[0]+(c*s[l+1][0]-c*s[l-1][0])/6,p[1]+(c*s[l+1][1]-c*s[l-1][1])/6],n[2]=[s[l+1][0]+(c*s[l][0]-c*s[l+2][0])/6,s[l+1][1]+(c*s[l][1]-c*s[l+2][1])/6],n[3]=[s[l+1][0],s[l+1][1]],a.push(n[1],n[2],n[3])}}return a}function Il(r,e){return Math.pow(r[0]-e[0],2)+Math.pow(r[1]-e[1],2)}function Pw(r,e,o){let a=Il(e,o);if(a===0)return Il(r,e);let s=((r[0]-e[0])*(o[0]-e[0])+(r[1]-e[1])*(o[1]-e[1]))/a;return s=Math.max(0,Math.min(1,s)),Il(r,ho(e,o,s))}function ho(r,e,o){return[r[0]+(e[0]-r[0])*o,r[1]+(e[1]-r[1])*o]}function Wf(r,e,o,a){let s=a||[];if(function(l,p){let m=l[p+0],u=l[p+1],y=l[p+2],x=l[p+3],k=3*u[0]-2*m[0]-x[0];k*=k;let w=3*u[1]-2*m[1]-x[1];w*=w;let _=3*y[0]-2*x[0]-m[0];_*=_;let M=3*y[1]-2*x[1]-m[1];return M*=M,k<_&&(k=_),w<M&&(w=M),k+w}(r,e)<o){let l=r[e+0];if(s.length)(n=s[s.length-1],c=l,Math.sqrt(Il(n,c)))>1&&s.push(l);else s.push(l);s.push(r[e+3])}else{let p=r[e+0],m=r[e+1],u=r[e+2],y=r[e+3],x=ho(p,m,0.5),k=ho(m,u,0.5),w=ho(u,y,0.5),_=ho(x,k,0.5),M=ho(k,w,0.5),q=ho(_,M,0.5);Wf([p,x,_,q],0,o,s),Wf([q,M,w,y],0,o,s)}var n,c;return s}function Rw(r,e){return Pl(r,0,r.length,e)}function Pl(r,e,o,a,s){let n=s||[],c=r[e],l=r[o-1],p=0,m=1;for(let u=e+1;u<o-1;++u){let y=Pw(r[u],c,l);y>p&&(p=y,m=u)}return Math.sqrt(p)>a?(Pl(r,e,m+1,a,n),Pl(r,m,o,a,n)):(n.length||n.push(c),n.push(l)),n}function Rf(r,e=0.15,o){let a=[],s=(r.length-1)/3;for(let n=0;n<s;n++)Wf(r,3*n,e,a);return o&&o>0?Pl(a,0,a.length,o):a}var Ar="none";class Ua{constructor(r){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:0.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:0.8},this.config=r||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2147483648)}_o(r){return r?Object.assign({},this.defaultOptions,r):this.defaultOptions}_d(r,e,o){return{shape:r,sets:e||[],options:o||this.defaultOptions}}line(r,e,o,a,s){let n=this._o(s);return this._d("line",[Cy(r,e,o,a,n)],n)}rectangle(r,e,o,a,s){let n=this._o(s),c=[],l=$w(r,e,o,a,n);if(n.fill){let p=[[r,e],[r+o,e],[r+o,e+a],[r,e+a]];n.fillStyle==="solid"?c.push(Pf([p],n)):c.push(xs([p],n))}return n.stroke!==Ar&&c.push(l),this._d("rectangle",c,n)}ellipse(r,e,o,a,s){let n=this._o(s),c=[],l=by(o,a,n),p=qf(r,e,n,l);if(n.fill)if(n.fillStyle==="solid"){let m=qf(r,e,n,l).opset;m.type="fillPath",c.push(m)}else c.push(xs([p.estimatedPoints],n));return n.stroke!==Ar&&c.push(p.opset),this._d("ellipse",c,n)}circle(r,e,o,a){let s=this.ellipse(r,e,o,o,a);return s.shape="circle",s}linearPath(r,e){let o=this._o(e);return this._d("linearPath",[Ol(r,!1,o)],o)}arc(r,e,o,a,s,n,c=!1,l){let p=this._o(l),m=[],u=oy(r,e,o,a,s,n,c,!0,p);if(c&&p.fill)if(p.fillStyle==="solid"){let y=Object.assign({},p);y.disableMultiStroke=!0;let x=oy(r,e,o,a,s,n,!0,!1,y);x.type="fillPath",m.push(x)}else m.push(function(y,x,k,w,_,M,q){let Y=y,V=x,Q=Math.abs(k/2),tt=Math.abs(w/2);Q+=le(0.01*Q,q),tt+=le(0.01*tt,q);let at=_,ot=M;for(;at<0;)at+=2*Math.PI,ot+=2*Math.PI;ot-at>2*Math.PI&&(at=0,ot=2*Math.PI);let ht=(ot-at)/q.curveStepCount,yt=[];for(let Bt=at;Bt<=ot;Bt+=ht)yt.push([Y+Q*Math.cos(Bt),V+tt*Math.sin(Bt)]);return yt.push([Y+Q*Math.cos(ot),V+tt*Math.sin(ot)]),yt.push([Y,V]),xs([yt],q)}(r,e,o,a,s,n,p));return p.stroke!==Ar&&m.push(u),this._d("arc",m,p)}curve(r,e){let o=this._o(e),a=[],s=iy(r,o);if(o.fill&&o.fill!==Ar)if(o.fillStyle==="solid"){let n=iy(r,Object.assign(Object.assign({},o),{disableMultiStroke:!0,roughness:o.roughness?o.roughness+o.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(n.ops)})}else{let n=[],c=r;if(c.length){let l=typeof c[0][0]=="number"?[c]:c;for(let p of l)p.length<3?n.push(...p):p.length===3?n.push(...Rf(hy([p[0],p[0],p[1],p[2]]),10,(1+o.roughness)/2)):n.push(...Rf(hy(p),10,(1+o.roughness)/2))}n.length&&a.push(xs([n],o))}return o.stroke!==Ar&&a.push(s),this._d("curve",a,o)}polygon(r,e){let o=this._o(e),a=[],s=Ol(r,!0,o);return o.fill&&(o.fillStyle==="solid"?a.push(Pf([r],o)):a.push(xs([r],o))),o.stroke!==Ar&&a.push(s),this._d("polygon",a,o)}path(r,e){let o=this._o(e),a=[];if(!r)return this._d("path",a,o);r=(r||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");let s=o.fill&&o.fill!=="transparent"&&o.fill!==Ar,n=o.stroke!==Ar,c=!!(o.simplification&&o.simplification<1),l=function(m,u,y){let x=yy(my(zf(m))),k=[],w=[],_=[0,0],M=[],q=()=>{M.length>=4&&w.push(...Rf(M,u)),M=[]},Y=()=>{q(),w.length&&(k.push(w),w=[])};for(let{key:Q,data:tt}of x)switch(Q){case"M":Y(),_=[tt[0],tt[1]],w.push(_);break;case"L":q(),w.push([tt[0],tt[1]]);break;case"C":if(!M.length){let at=w.length?w[w.length-1]:_;M.push([at[0],at[1]])}M.push([tt[0],tt[1]]),M.push([tt[2],tt[3]]),M.push([tt[4],tt[5]]);break;case"Z":q(),w.push([_[0],_[1]])}if(Y(),!y)return k;let V=[];for(let Q of k){let tt=Rw(Q,y);tt.length&&V.push(tt)}return V}(r,1,c?4-4*(o.simplification||1):(1+o.roughness)/2),p=sy(r,o);if(s)if(o.fillStyle==="solid")if(l.length===1){let m=sy(r,Object.assign(Object.assign({},o),{disableMultiStroke:!0,roughness:o.roughness?o.roughness+o.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(m.ops)})}else a.push(Pf(l,o));else a.push(xs(l,o));return n&&(c?l.forEach((m)=>{a.push(Ol(m,!1,o))}):a.push(p)),this._d("path",a,o)}opsToPath(r,e){let o="";for(let a of r.ops){let s=typeof e=="number"&&e>=0?a.data.map((n)=>+n.toFixed(e)):a.data;switch(a.op){case"move":o+=`M${s[0]} ${s[1]} `;break;case"bcurveTo":o+=`C${s[0]} ${s[1]}, ${s[2]} ${s[3]}, ${s[4]} ${s[5]} `;break;case"lineTo":o+=`L${s[0]} ${s[1]} `}}return o.trim()}toPaths(r){let e=r.sets||[],o=r.options||this.defaultOptions,a=[];for(let s of e){let n=null;switch(s.type){case"path":n={d:this.opsToPath(s),stroke:o.stroke,strokeWidth:o.strokeWidth,fill:Ar};break;case"fillPath":n={d:this.opsToPath(s),stroke:Ar,strokeWidth:0,fill:o.fill||Ar};break;case"fillSketch":n=this.fillSketch(s,o)}n&&a.push(n)}return a}fillSketch(r,e){let o=e.fillWeight;return o<0&&(o=e.strokeWidth/2),{d:this.opsToPath(r),stroke:e.fill||Ar,strokeWidth:o,fill:Ar}}_mergedShape(r){return r.filter((e,o)=>o===0||e.op!=="move")}}class wy{constructor(r,e){this.canvas=r,this.ctx=this.canvas.getContext("2d"),this.gen=new Ua(e)}draw(r){let e=r.sets||[],o=r.options||this.getDefaultOptions(),a=this.ctx,s=r.options.fixedDecimalPlaceDigits;for(let n of e)switch(n.type){case"path":a.save(),a.strokeStyle=o.stroke==="none"?"transparent":o.stroke,a.lineWidth=o.strokeWidth,o.strokeLineDash&&a.setLineDash(o.strokeLineDash),o.strokeLineDashOffset&&(a.lineDashOffset=o.strokeLineDashOffset),this._drawToContext(a,n,s),a.restore();break;case"fillPath":{a.save(),a.fillStyle=o.fill||"";let c=r.shape==="curve"||r.shape==="polygon"||r.shape==="path"?"evenodd":"nonzero";this._drawToContext(a,n,s,c),a.restore();break}case"fillSketch":this.fillSketch(a,n,o)}}fillSketch(r,e,o){let a=o.fillWeight;a<0&&(a=o.strokeWidth/2),r.save(),o.fillLineDash&&r.setLineDash(o.fillLineDash),o.fillLineDashOffset&&(r.lineDashOffset=o.fillLineDashOffset),r.strokeStyle=o.fill||"",r.lineWidth=a,this._drawToContext(r,e,o.fixedDecimalPlaceDigits),r.restore()}_drawToContext(r,e,o,a="nonzero"){r.beginPath();for(let s of e.ops){let n=typeof o=="number"&&o>=0?s.data.map((c)=>+c.toFixed(o)):s.data;switch(s.op){case"move":r.moveTo(n[0],n[1]);break;case"bcurveTo":r.bezierCurveTo(n[0],n[1],n[2],n[3],n[4],n[5]);break;case"lineTo":r.lineTo(n[0],n[1])}}e.type==="fillPath"?r.fill(a):r.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(r,e,o,a,s){let n=this.gen.line(r,e,o,a,s);return this.draw(n),n}rectangle(r,e,o,a,s){let n=this.gen.rectangle(r,e,o,a,s);return this.draw(n),n}ellipse(r,e,o,a,s){let n=this.gen.ellipse(r,e,o,a,s);return this.draw(n),n}circle(r,e,o,a){let s=this.gen.circle(r,e,o,a);return this.draw(s),s}linearPath(r,e){let o=this.gen.linearPath(r,e);return this.draw(o),o}polygon(r,e){let o=this.gen.polygon(r,e);return this.draw(o),o}arc(r,e,o,a,s,n,c=!1,l){let p=this.gen.arc(r,e,o,a,s,n,c,l);return this.draw(p),p}curve(r,e){let o=this.gen.curve(r,e);return this.draw(o),o}path(r,e){let o=this.gen.path(r,e);return this.draw(o),o}}var El="http://www.w3.org/2000/svg";class Sy{constructor(r,e){this.svg=r,this.gen=new Ua(e)}draw(r){let e=r.sets||[],o=r.options||this.getDefaultOptions(),a=this.svg.ownerDocument||window.document,s=a.createElementNS(El,"g"),n=r.options.fixedDecimalPlaceDigits;for(let c of e){let l=null;switch(c.type){case"path":l=a.createElementNS(El,"path"),l.setAttribute("d",this.opsToPath(c,n)),l.setAttribute("stroke",o.stroke),l.setAttribute("stroke-width",o.strokeWidth+""),l.setAttribute("fill","none"),o.strokeLineDash&&l.setAttribute("stroke-dasharray",o.strokeLineDash.join(" ").trim()),o.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${o.strokeLineDashOffset}`);break;case"fillPath":l=a.createElementNS(El,"path"),l.setAttribute("d",this.opsToPath(c,n)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",o.fill||""),r.shape!=="curve"&&r.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(a,c,o)}l&&s.appendChild(l)}return s}fillSketch(r,e,o){let a=o.fillWeight;a<0&&(a=o.strokeWidth/2);let s=r.createElementNS(El,"path");return s.setAttribute("d",this.opsToPath(e,o.fixedDecimalPlaceDigits)),s.setAttribute("stroke",o.fill||""),s.setAttribute("stroke-width",a+""),s.setAttribute("fill","none"),o.fillLineDash&&s.setAttribute("stroke-dasharray",o.fillLineDash.join(" ").trim()),o.fillLineDashOffset&&s.setAttribute("stroke-dashoffset",`${o.fillLineDashOffset}`),s}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(r,e){return this.gen.opsToPath(r,e)}line(r,e,o,a,s){let n=this.gen.line(r,e,o,a,s);return this.draw(n)}rectangle(r,e,o,a,s){let n=this.gen.rectangle(r,e,o,a,s);return this.draw(n)}ellipse(r,e,o,a,s){let n=this.gen.ellipse(r,e,o,a,s);return this.draw(n)}circle(r,e,o,a){let s=this.gen.circle(r,e,o,a);return this.draw(s)}linearPath(r,e){let o=this.gen.linearPath(r,e);return this.draw(o)}polygon(r,e){let o=this.gen.polygon(r,e);return this.draw(o)}arc(r,e,o,a,s,n,c=!1,l){let p=this.gen.arc(r,e,o,a,s,n,c,l);return this.draw(p)}curve(r,e){let o=this.gen.curve(r,e);return this.draw(o)}path(r,e){let o=this.gen.path(r,e);return this.draw(o)}}var v={canvas:(r,e)=>new wy(r,e),svg:(r,e)=>new Sy(r,e),generator:(r)=>new Ua(r),newSeed:()=>Ua.newSeed()};var qw=1,Nw=3;async function td(r){let e=r.getElementsByTagName("img");if(!e||e.length===0)return;let o=!ed(r);await Promise.all([...e].map((a)=>new Promise((s)=>{function n(){if(a.style.display="flex",a.style.flexDirection="column",o){let c=d().fontSize?d().fontSize:window.getComputedStyle(document.body).fontSize,l=5,[p=F.fontSize]=Nt(c),m=p*5+"px";a.style.minWidth=m,a.style.maxWidth=m}else a.style.width="100%";s(a)}t(n,"setupImage"),setTimeout(()=>{if(a.complete)n()}),a.addEventListener("error",n),a.addEventListener("load",n)})))}t(td,"configureLabelImages");function ed(r){if(r.nodeType===Nw)return r.textContent?.trim()!=="";if(r.nodeType!==qw)return!1;if(r.tagName.toLowerCase()==="img")return!1;return[...r.childNodes].some(ed)}t(ed,"hasTextBesidesImages");var Ty=3,Ww=32,zw=t(async(r,e,o)=>{let a=d(),s=r.insert("g").attr("class",o??"node default").attr("id",e.domId||e.id),n=s.insert("g").attr("class","label").attr("style",Me(e.labelStyle)),l=[{text:typeof e.label==="string"?e.label:e.label?.[0]??"",cssClass:"c4-name"},{text:e.stereotype,cssClass:"c4-type"},...(e.description??[]).map((q)=>({text:q,cssClass:"c4-descr"}))].filter((q)=>q.text),p=e.width?Math.max(e.width-2*(e.padding??0),Ww):d().flowchart?.wrappingWidth??200,u=a.c4?.wrap??!0?p:Number.POSITIVE_INFINITY,y=await Promise.all(l.map(async(q)=>{let Y=n.append("g").attr("class",q.cssClass),V=await ct(Y,j(Fn(q.text??""),a),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:u,style:e.labelStyle},a);return g(V).selectAll("tspan.text-outer-tspan").attr("text-anchor","middle"),g(V).selectAll("tspan.text-inner-tspan").attr("font-weight",null).attr("font-style",null),{el:Y,box:Y.node().getBBox()}})),x=Math.max(...y.map(({box:q})=>q.width),0),k=0;for(let{el:q,box:Y}of y)q.attr("transform",`translate(${x/2-Y.x-Y.width/2}, ${k-Y.y})`),k+=Y.height+Ty;let w=y.length>0?k-Ty:0;n.insert("rect",":first-child"),n.attr("transform",`translate(${-x/2}, ${-w/2})`);let _=n.node().getBBox(),M=(e.padding??0)/2;return{shapeSvg:s,bbox:_,halfPadding:M,label:n}},"c4LabelHelper"),_y=t((r,e)=>{let{x:o,y:a,width:s,height:n}=r;if(s>=e)return r;if(!("left"in r))return{x:o-(e-s)/2,y:a,width:e,height:n};return{x:o,y:a,width:e,height:n,top:a,left:o,bottom:a+n,right:o+e,toJSON:t(()=>({}),"toJSON")}},"withMinWidth"),U=t(async(r,e,o,{ignoreMinWidth:a=!1}={})=>{if(e.stereotype!==void 0)return zw(r,e,o);let s,n=e.useHtmlLabels||ln(d()?.htmlLabels);if(!o)s="node default";else s=o;let c=r.insert("g").attr("class",s).attr("id",e.domId||e.id),l=c.insert("g").attr("class","label").attr("style",Me(e.labelStyle)),p;if(e.label===void 0)p="";else p=typeof e.label==="string"?e.label:e.label[0];let m=!!e.icon||!!e.img,u=e.labelType==="markdown",y=p&&!e.width&&!a?e.minWidth??0:0,x=await ct(l,j(Fn(p),d()),{useHtmlLabels:n,width:e.width||e.wrappingWidth||d().flowchart?.wrappingWidth,minWidth:y,classes:u?"markdown-node-label":"",style:e.labelStyle,addSvgBackground:m,markdown:u},d()),k=(e?.padding??0)/2,w;if(n){let _=x.children[0],M=g(x);await td(_),w=await Bi.measure(()=>_.getBoundingClientRect()),w=_y(w,y),M.attr("width",w.width),M.attr("height",w.height)}else w=await Bi.measure(()=>x.getBBox()),w=_y(w,y);if(n)l.attr("transform","translate("+-w.width/2+", "+-w.height/2+")");else l.attr("transform","translate(0, "+-w.height/2+")");if(e.centerLabel)l.attr("transform","translate("+-w.width/2+", "+-w.height/2+")");return l.insert("rect",":first-child"),{shapeSvg:c,bbox:w,halfPadding:k,label:l}},"labelHelper"),uo=t(async(r,e,o)=>{let a=o.useHtmlLabels??Xe(d()),s=r.insert("g").attr("class","label").attr("style",o.labelStyle||""),n=await ct(s,j(Fn(e),d()),{useHtmlLabels:a,width:o.width||d()?.flowchart?.wrappingWidth,style:o.labelStyle,addSvgBackground:!!o.icon||!!o.img}),c=o.padding/2,l;if(Xe(d())){let p=n.children[0],m=g(n);l=await Bi.measure(()=>p.getBoundingClientRect()),m.attr("width",l.width),m.attr("height",l.height)}else l=await Bi.measure(()=>n.getBBox());if(a)s.attr("transform","translate("+-l.width/2+", "+-l.height/2+")");else s.attr("transform","translate(0, "+-l.height/2+")");if(o.centerLabel)s.attr("transform","translate("+-l.width/2+", "+-l.height/2+")");return s.insert("rect",":first-child"),{shapeSvg:r,bbox:l,halfPadding:c,label:s}},"insertLabel"),B=t((r,e,o)=>{if(o){r.width=o.width,r.height=o.height;return}let a=e.node().getBBox();r.width=a.width,r.height=a.height},"updateNodeBounds"),te=t((r,e)=>(r.look==="handDrawn"?"rough-node":"node")+" "+r.cssClasses+" "+(e||""),"getNodeClasses");function ye(r){let e=r.map((o,a)=>`${a===0?"M":"L"}${o.x},${o.y}`);return e.push("Z"),e.join(" ")}t(ye,"createPathFromPoints");function Ji(r,e,o,a,s,n){let c=[],l=50,p=o-r,m=a-e,u=p/n,y=2*Math.PI/u,x=e+m/2;for(let k=0;k<=50;k++){let w=k/50,_=r+w*p,M=x+s*Math.sin(y*(_-r));c.push({x:_,y:M})}return c}t(Ji,"generateFullSineWavePoints");function ci(r,e,o,a,s,n){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(ci,"generateCirclePoints");function Kf(r){let e=Array.from(r.childNodes).filter((p)=>p.tagName==="path"),o=document.createElementNS("http://www.w3.org/2000/svg","path"),a=e.map((p)=>p.getAttribute("d")).filter((p)=>p!==null).join(" ");o.setAttribute("d",a);let s=e.find((p)=>p.getAttribute("fill")!=="none"),n=e.find((p)=>p.getAttribute("stroke")!=="none"),c=t((p,m)=>p?.getAttribute(m)??void 0,"getAttr");if(s){let p={fill:c(s,"fill"),"fill-opacity":c(s,"fill-opacity")??"1"};Object.entries(p).forEach(([m,u])=>{if(u)o.setAttribute(m,u)})}if(n){let p={stroke:c(n,"stroke"),"stroke-width":c(n,"stroke-width")??"1","stroke-opacity":c(n,"stroke-opacity")??"1"};Object.entries(p).forEach(([m,u])=>{if(u)o.setAttribute(m,u)})}let l=document.createElementNS("http://www.w3.org/2000/svg","g");return l.appendChild(o),l}t(Kf,"mergePaths");var Hw=t((r,e)=>{var{x:o,y:a}=r,s=e.x-o,n=e.y-a,c=r.width/2,l=r.height/2,p,m;if(Math.abs(n)*c>Math.abs(s)*l){if(n<0)l=-l;p=n===0?0:l*s/n,m=l}else{if(s<0)c=-c;p=c,m=s===0?0:c*n/s}return{x:o+p,y:a+m}},"intersectRect"),ui=Hw;function Gy(r,e){return r.intersect(e)}t(Gy,"intersectNode");var Yw=Gy;function Xy(r,e,o,a){var{x:s,y:n}=r,c=s-a.x,l=n-a.y,p=Math.sqrt(e*e*l*l+o*o*c*c),m=Math.abs(e*o*c/p);if(a.x<s)m=-m;var u=Math.abs(e*o*l/p);if(a.y<n)u=-u;return{x:s+m,y:n+u}}t(Xy,"intersectEllipse");var Vy=Xy;function Ky(r,e,o){return Vy(r,e,e,o)}t(Ky,"intersectCircle");var Uw=Ky;function Zy(r,e,o,a){{let s=e.y-r.y,n=r.x-e.x,c=e.x*r.y-r.x*e.y,l=s*o.x+n*o.y+c,p=s*a.x+n*a.y+c,m=0.000001;if(l!==0&&p!==0&&Zf(l,p))return;let u=a.y-o.y,y=o.x-a.x,x=a.x*o.y-o.x*a.y,k=u*r.x+y*r.y+x,w=u*e.x+y*e.y+x;if(Math.abs(k)<0.000001&&Math.abs(w)<0.000001&&Zf(k,w))return;let _=s*y-u*n;if(_===0)return;let M=(n*x-y*c)/_,q=(u*c-s*x)/_;return{x:M,y:q}}}t(Zy,"intersectLine");function Zf(r,e){return r*e>0}t(Zf,"sameSign");var jw=Zy;function Qy(r,e,o){let{x:a,y:s}=r,n=[],{POSITIVE_INFINITY:c,POSITIVE_INFINITY:l}=Number;if(typeof e.forEach==="function")e.forEach(function(u){c=Math.min(c,u.x),l=Math.min(l,u.y)});else c=Math.min(c,e.x),l=Math.min(l,e.y);let p=a-r.width/2-c,m=s-r.height/2-l;for(let u=0;u<e.length;u++){let y=e[u],x=e[u<e.length-1?u+1:0],k=jw(r,o,{x:p+y.x,y:m+y.y},{x:p+x.x,y:m+x.y});if(k)n.push(k)}if(!n.length)return r;if(n.length>1)n.sort(function(u,y){let x=u.x-o.x,k=u.y-o.y,w=Math.sqrt(x*x+k*k),_=y.x-o.x,M=y.y-o.y,q=Math.sqrt(_*_+M*M);return w<q?-1:w===q?0:1});return n[0]}t(Qy,"intersectPolygon");var Gw=Qy,T={node:Yw,circle:Uw,ellipse:Vy,polygon:Gw,rect:ui},Tr=t((r,e,o,a,s)=>["M",r+s,e,"H",r+o-s,"A",s,s,0,0,1,r+o,e+s,"V",e+a-s,"A",s,s,0,0,1,r+o-s,e+a,"H",r+s,"A",s,s,0,0,1,r,e+a-s,"V",e+s,"A",s,s,0,0,1,r+s,e,"Z"].join(" "),"createRoundedRectPathD"),Xw=t(async(r,e,o,a=!1,s=!1)=>{let n=e||"";if(typeof n==="object")n=n[0];let c=d(),l=Xe(c);return await ct(r,n,{style:o,isTitle:a,useHtmlLabels:l,markdown:!1,isNode:s,width:Number.POSITIVE_INFINITY},c)},"createLabel"),Gr=Xw;function Jy(r,e){let{labelStyles:o}=E(e);e.labelStyle=o;let a=te(e),s=a;if(!a)s="anchor";let n=r.insert("g").attr("class",s).attr("id",e.domId||e.id),c=1,{cssStyles:l}=e,p=v.svg(n),m=Kt(e,{fill:"black",stroke:"none",fillStyle:"solid"});if(e.look!=="handDrawn")m.roughness=0;let u=p.circle(0,0,c*2,m),y=n.insert(()=>u,":first-child");return y.attr("class","anchor").attr("style",Me(l)),B(e,y),e.intersect=function(x){return i.info("Circle intersect",e,c,x),T.circle(e,c,x)},n}t(Jy,"anchor");function Qf(r,e,o,a,s,n,c){let p=(r+o)/2,m=(e+a)/2,u=Math.atan2(a-e,o-r),y=(o-r)/2,x=(a-e)/2,k=y/s,w=x/n,_=Math.sqrt(k**2+w**2);if(_>1)throw Error("The given radii are too small to create an arc between the points.");let M=Math.sqrt(1-_**2),q=p+M*n*Math.sin(u)*(c?-1:1),Y=m-M*s*Math.cos(u)*(c?-1:1),V=Math.atan2((e-Y)/n,(r-q)/s),tt=Math.atan2((a-Y)/n,(o-q)/s)-V;if(c&&tt<0)tt+=2*Math.PI;if(!c&&tt>0)tt-=2*Math.PI;let at=[];for(let ot=0;ot<20;ot++){let ht=ot/19,yt=V+ht*tt,Bt=q+s*Math.cos(yt),kt=Y+n*Math.sin(yt);at.push({x:Bt,y:kt})}return at}t(Qf,"generateArcPoints");function tx(r,e,o){let[a,s]=[e,o].sort((n,c)=>c-n);return s*(1-Math.sqrt(1-(r/a/2)**2))}t(tx,"calculateArcSagitta");async function ex(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=t((yt)=>yt+c,"calcTotalHeight"),p=t((yt)=>{let Bt=yt/2;return[Bt/(2.5+yt/50),Bt]},"calcEllipseRadius"),{shapeSvg:m,bbox:u}=await U(r,e,te(e)),y=l(e?.height?e?.height:u.height),[x,k]=p(y),w=tx(y,x,k),M=(e?.width?e?.width:u.width)+n*2+w-w,q=y,{cssStyles:Y}=e,V=[{x:M/2,y:-q/2},{x:-M/2,y:-q/2},...Qf(-M/2,-q/2,-M/2,q/2,x,k,!1),{x:M/2,y:q/2},...Qf(M/2,q/2,M/2,-q/2,x,k,!0)],Q=v.svg(m),tt=Kt(e,{});if(e.look!=="handDrawn")tt.roughness=0,tt.fillStyle="solid";let at=ye(V),ot=Q.path(at,tt),ht=m.insert(()=>ot,":first-child");if(ht.attr("class","basic label-container outer-path"),Y&&e.look!=="handDrawn")ht.selectAll("path").attr("style",Y);if(a&&e.look!=="handDrawn")ht.selectAll("path").attr("style",a);return ht.attr("transform",`translate(${x/2}, 0)`),B(e,ht),e.intersect=function(yt){return T.polygon(e,V,yt)},m}t(ex,"bowTieRect");async function rx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await U(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=Math.max(c.width+m*2,e.width??0,80),y=Math.max(Math.min(u*0.08,12),5),x=Math.max(c.height+m*2+y,e.height??0),k=-x/2+y,w=x/2,_=u*0.72,M=[`M${-u/2},${k}`,`L${-_/2},${w}`,`A${_/2},${y} 0 0 0 ${_/2},${w}`,`L${u/2},${k}`,`A${u/2},${y} 0 0 0 ${-u/2},${k}`,"Z"].join(" "),{cssStyles:q}=e,Y=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let ht=v.svg(n).path(M,Kt(e,{}));if(Y.node()?.appendChild(ht),q)Y.attr("style",q)}else Y.append("path").attr("d",M).attr("style",s);Y.append("ellipse").attr("cx",0).attr("cy",k).attr("rx",u/2).attr("ry",y).attr("style",`fill:none;stroke:${p};stroke-width:1px`),B(e,Y);let V=k+(w-k)/2;l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${V-c.height/2-(c.y-(c.top??0))})`);let Q=12,tt=t((ot,ht,yt)=>Array.from({length:Q+1},(Bt,kt)=>{let Ct=Math.PI-kt*Math.PI/Q;return{x:ot*Math.cos(Ct),y:ht+yt*y*Math.sin(Ct)}}),"arc"),at=[...tt(u/2,k,-1),...tt(_/2,w,1).reverse()];return e.intersect=function(ot){return T.polygon(e,at,ot)},n}t(rx,"bucket");var Hf=20,Yf=8,Vw=80,Kw=8;function ix(r){let{themeVariables:e}=d(),{clusterBkg:o,clusterBorder:a}=e;switch(r){case"flow":return{rx:10,fill:"none",stroke:e.flowContainerStroke||e.secondaryBorderColor,strokeWidth:0.75,cssClass:"flow-collapsed"};default:return{rx:Kw,fill:o,stroke:a,cssClass:"collapsed-group"}}}t(ix,"getCollapsedStyle");async function ox(r,e){let o=ix(e.metadata?.containerType),{fill:a,stroke:s}=o,{nodeStyles:n}=E(e),{shapeSvg:c,bbox:l}=await U(r,e,te(e)),{theme:p,themeVariables:m}=d();It(c,e.colorIndex,p,m.borderColorArray);let u=e.padding??8,y=l.height,x=Math.max(l.width+u*2,Vw,e?.width??0),k=Math.max(y+Yf+Hf+u*2,e?.height??0),w=-x/2,_=-k/2,M=-(Yf+Hf)/2,q=c.select(".label");if(q)if(e.useHtmlLabels??Xe(d()))q.attr("transform",`translate(${-l.width/2}, ${-l.height/2+M})`);else q.attr("transform",`translate(0, ${-l.height/2+M})`);let Y;if(e.look==="handDrawn"){let ot=v.svg(c),ht=Kt(e,{fill:a,stroke:s,...o.strokeWidth===void 0?{}:{strokeWidth:o.strokeWidth},...a==="none"?{fillWeight:0}:{fillStyle:"solid"}}),yt=ot.path(Tr(w,_,x,k,o.rx),ht);Y=c.insert(()=>yt,":first-child"),Y.attr("class","basic label-container "+o.cssClass).attr("style",Me(e.cssStyles))}else if(Y=c.insert("rect",":first-child"),Y.attr("class","basic label-container "+o.cssClass).attr("style",n).attr("rx",o.rx).attr("ry",o.rx).attr("x",w).attr("y",_).attr("width",x).attr("height",k).attr("fill",a).attr("stroke",s),o.strokeWidth!==void 0)Y.attr("stroke-width",o.strokeWidth+"px");let V=_+u+y+Yf;c.append("line").attr("class","collapsed-separator").attr("x1",w+8).attr("y1",V).attr("x2",w+x-8).attr("y2",V).attr("stroke",s).attr("stroke-dasharray","3, 3");let Q=V+Hf/2,tt=2.5,at=10;for(let ot=-1;ot<=1;ot++)c.append("circle").attr("class","collapsed-indicator").attr("cx",ot*at).attr("cy",Q).attr("r",tt).attr("fill",s);return B(e,Y),e.calcIntersect=function(ot,ht){return T.rect(ot,ht)},e.intersect=function(ot){return T.rect(e,ot)},c}t(ox,"collapsedGroup");function fi(r,e,o,a){return r.insert("polygon",":first-child").attr("points",a.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+o/2+")")}t(fi,"insertPolygonShape");var Zw=["right","left","up","down"],rd="point",Qw=t((r)=>{let e=new Set;for(let o of r)switch(o){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(o);break}return e},"expandAndDeduplicateDirections"),Jw=t((r)=>Zw.filter((e)=>r.has(e)).join("|")||rd,"getDirectionKey"),By={"right|left|up|down":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:0,y:0},{x:e,y:0},{x:a/2,y:2*o},{x:a-e,y:0},{x:a,y:0},{x:a,y:-r/3},{x:a+2*o,y:-r/2},{x:a,y:-2*r/3},{x:a,y:-r},{x:a-e,y:-r},{x:a/2,y:-r-2*o},{x:e,y:-r},{x:0,y:-r},{x:0,y:-2*r/3},{x:-2*o,y:-r/2},{x:0,y:-r/3}],"right|left|up|down"),"right|left|up":t(({height:r,midpoint:e,width:o})=>[{x:e,y:0},{x:o-e,y:0},{x:o,y:-r/2},{x:o-e,y:-r},{x:e,y:-r},{x:0,y:-r/2}],"right|left|up"),"right|left|down":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:e,y:-r},{x:o-e,y:-r},{x:o,y:0}],"right|left|down"),"right|up|down":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:o,y:-e},{x:o,y:-r+e},{x:0,y:-r}],"right|up|down"),"left|up|down":t(({height:r,midpoint:e,width:o})=>[{x:o,y:0},{x:0,y:-e},{x:0,y:-r+e},{x:o,y:-r}],"left|up|down"),"right|left":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:0},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:0},{x:a,y:-r/2},{x:a-e,y:-r},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r},{x:0,y:-r/2}],"right|left"),"up|down":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:a/2,y:0},{x:0,y:-o},{x:e,y:-o},{x:e,y:-r+o},{x:0,y:-r+o},{x:a/2,y:-r},{x:a,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o},{x:a,y:-o}],"up|down"),"right|up":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:o,y:-e},{x:0,y:-r}],"right|up"),"right|down":t(({height:r,width:e})=>[{x:0,y:0},{x:e,y:0},{x:0,y:-r}],"right|down"),"left|up":t(({height:r,midpoint:e,width:o})=>[{x:o,y:0},{x:0,y:-e},{x:o,y:-r}],"left|up"),"left|down":t(({height:r,width:e})=>[{x:e,y:0},{x:0,y:0},{x:e,y:-r}],"left|down"),right:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:-o},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:0},{x:a,y:-r/2},{x:a-e,y:-r},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r+o}],"right"),left:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:0},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r},{x:0,y:-r/2}],"left"),up:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:-o},{x:e,y:-r+o},{x:0,y:-r+o},{x:a/2,y:-r},{x:a,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o}],"up"),down:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:a/2,y:0},{x:0,y:-o},{x:e,y:-o},{x:e,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o},{x:a,y:-o}],"down"),[rd]:()=>[{x:0,y:0}]},tS=t((r,e,o,a)=>{let s=Qw(r),n=(o.padding??0)/2,c=e.height+4*n,l=c/2,p=a??e.width+2*l+2*n,m=Jw(s);return(By[m]??By[rd])({height:c,midpoint:l,padding:n,width:p})},"getArrowPoints");async function sx(r,e){let o=e,{shapeSvg:a,bbox:s}=await U(r,o,te(o)),n=o.padding??0,c=s.height+2*n,l=c/2,p=s.width+2*l+n,m=o.width??0,y=o.positioned&&(o.widthInColumns??1)>1&&m>p?m:p,x=tS(o.directions??[],s,o,y),k=fi(a,y,c,x);return k.attr("style",o.style??null),B(o,k),o.intersect=function(w){return T.polygon(o,x,w)},a}t(sx,"block_arrow");async function ax(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await U(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=18,y=12,x=Math.max(c.width+m*2,e.width??0,90),k=Math.max(c.height+m*2+u,e.height??0),w=-k/2,{cssStyles:_}=e,M=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let V=v.svg(n).path(Tr(-x/2,w,x,k,y),Kt(e,{}));if(M.node()?.appendChild(V),_)M.attr("style",_)}else M.append("rect").attr("x",-x/2).attr("y",w).attr("width",x).attr("height",k).attr("rx",y).attr("ry",y).attr("style",s);M.append("line").attr("x1",-x/2).attr("y1",w+u).attr("x2",x/2).attr("y2",w+u).attr("style",`stroke:${p};stroke-width:1px`);for(let Y=0;Y<3;Y++)M.append("circle").attr("cx",-x/2+12+Y*9).attr("cy",w+u/2).attr("r",2.5).attr("style",`fill:${p};stroke:none`);M.append("rect").attr("class","browser-address-bar").attr("x",-x/2+44).attr("y",w+4).attr("width",Math.max(x-56,10)).attr("height",u-8).attr("rx",3).attr("ry",3).attr("style",`fill:none;stroke:${p};stroke-width:1px;opacity:0.6`),B(e,M);let q=w+u+(k-u)/2;return l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${q-c.height/2-(c.y-(c.top??0))})`),e.intersect=function(Y){return T.rect(e,Y)},n}t(ax,"browser");var Nl=12;async function nx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?28:s,c=e.look==="neo"?24:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=(e?.width??p.width)+(e.look==="neo"?n*2:n+Nl),u=(e?.height??p.height)+(e.look==="neo"?c*2:c),y=0,x=m,k=-u,w=0,_=[{x:y+Nl,y:k},{x,y:k},{x,y:w},{x:y,y:w},{x:y,y:k+Nl},{x:y+Nl,y:k}],M,{cssStyles:q}=e;if(e.look==="handDrawn"){let Y=v.svg(l),V=Kt(e,{}),Q=ye(_),tt=Y.path(Q,V);if(M=l.insert(()=>tt,":first-child").attr("transform",`translate(${-m/2}, ${u/2})`),q)M.attr("style",q)}else M=fi(l,m,u,_);if(a)M.attr("style",a);return B(e,M),e.intersect=function(Y){return T.polygon(e,_,Y)},l}t(nx,"card");function lx(r,e){let{nodeStyles:o}=E(e);e.label="";let a=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:s}=e,n=Math.max(28,e.width??0),c=[{x:0,y:n/2},{x:n/2,y:0},{x:0,y:-n/2},{x:-n/2,y:0}],l=v.svg(a),p=Kt(e,{});if(e.look!=="handDrawn")p.roughness=0,p.fillStyle="solid";let m=ye(c),u=l.path(m,p),y=a.insert(()=>u,":first-child");if(s&&e.look!=="handDrawn")y.selectAll("path").attr("style",s);if(o&&e.look!=="handDrawn")y.selectAll("path").attr("style",o);return e.width=28,e.height=28,e.intersect=function(x){return T.polygon(e,c,x)},a}t(lx,"choice");async function id(r,e,o){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,halfPadding:l}=await U(r,e,te(e),{ignoreMinWidth:!0}),p=16,m=o?.padding??l,u=Math.sqrt(c.width**2+c.height**2)/2,y=e.look==="neo"?u+p:u+m,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(n),_=Kt(e,{}),M=w.circle(0,0,y*2,_);x=n.insert(()=>M,":first-child"),x.attr("class","basic label-container").attr("style",Me(k))}else x=n.insert("circle",":first-child").attr("class","basic label-container").attr("style",s).attr("r",y).attr("cx",0).attr("cy",0);return B(e,x),e.calcIntersect=function(w,_){let M=w.width/2;return T.circle(w,M,_)},e.intersect=function(w){return i.info("Circle intersect",e,y,w),T.circle(e,y,w)},n}t(id,"circle");async function hx(r,e){let o=e,a=["node",o.cssClasses,o.class].filter(Boolean).join(" "),{shapeSvg:s,bbox:n,halfPadding:c}=await U(r,o,a),l=s.insert("rect",":first-child"),p=o.padding??0,m=o.positioned?o.width??0:n.width+p,u=o.positioned?o.height??0:n.height+p,y=o.positioned?-m/2:-n.width/2-c,x=o.positioned?-u/2:-n.height/2-c;return l.attr("class","basic cluster composite label-container").attr("style",o.style??null).attr("rx",o.rx??null).attr("ry",o.ry??null).attr("x",y).attr("y",x).attr("width",m).attr("height",u),B(o,l),o.intersect=function(k){return T.rect(o,k)},s}t(hx,"composite");async function cx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await U(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=20,y=12,x=Math.max(c.width+m*2,e.width??0,90),k=Math.max(c.height+m*2+u,e.height??0),w=-k/2,{cssStyles:_}=e,M=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let V=v.svg(n).path(Tr(-x/2,w,x,k,y),Kt(e,{}));if(M.node()?.appendChild(V),_)M.attr("style",_)}else M.append("rect").attr("x",-x/2).attr("y",w).attr("width",x).attr("height",k).attr("rx",y).attr("ry",y).attr("style",s);M.append("text").attr("x",-x/2+12).attr("y",w+16).attr("class","console-glyph").attr("style",`font-family:monospace;font-weight:bold;font-size:14px;fill:${p}`).text(">_"),B(e,M);let q=w+u+(k-u)/2;return l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${q-c.height/2-(c.y-(c.top??0))})`),e.intersect=function(Y){return T.rect(e,Y)},n}t(cx,"consoleWindow");function ux(r){let e=Math.cos(Math.PI/4),o=Math.sin(Math.PI/4),a=r*2,s={x:a/2*e,y:a/2*o},n={x:-(a/2)*e,y:a/2*o},c={x:-(a/2)*e,y:-(a/2)*o},l={x:a/2*e,y:-(a/2)*o};return`M ${n.x},${n.y} L ${l.x},${l.y}
|
|
233
|
-
M ${s.x},${s.y} L ${c.x},${c.y}`}t(ux,"createLine");function fx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o,e.label="";let s=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),n=Math.max(30,e?.width??0),{cssStyles:c}=e,l=v.svg(s),p=Kt(e,{});if(e.look!=="handDrawn")p.roughness=0,p.fillStyle="solid";let m=l.circle(0,0,n*2,p),u=ux(n),y=l.path(u,p),x=s.insert(()=>m,":first-child");if(x.insert(()=>y),x.attr("class","outer-path"),c&&e.look!=="handDrawn")x.selectAll("path").attr("style",c);if(a&&e.look!=="handDrawn")x.selectAll("path").attr("style",a);return B(e,x),e.intersect=function(k){return i.info("crossedCircle intersect",e,{radius:n,point:k}),T.circle(e,n,k)},s}t(fx,"crossedCircle");function vi(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(vi,"generateCirclePoints");async function dx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+l,u=n.height+p,y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...vi(m/2,-u/2,y,30,-90,0),{x:-m/2-y,y},...vi(m/2+y*2,-y,y,20,-180,-270),...vi(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:-u/2},...vi(m/2,u/2,y,20,0,90)],w=[{x:m/2,y:-u/2-y},{x:-m/2,y:-u/2-y},...vi(m/2,-u/2,y,20,-90,0),{x:-m/2-y,y:-y},...vi(m/2+m*0.1,-y,y,20,-180,-270),...vi(m/2+m*0.1,y,y,20,-90,-180),{x:-m/2-y,y:u/2},...vi(m/2,u/2,y,20,0,90),{x:-m/2,y:u/2+y},{x:m/2,y:u/2+y}],_=v.svg(s),M=Kt(e,{fill:"none"});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let Y=ye(k).replace("Z",""),V=_.path(Y,M),Q=ye(w),tt=_.path(Q,{...M}),at=s.insert("g",":first-child");if(at.insert(()=>tt,":first-child").attr("stroke-opacity",0),at.insert(()=>V,":first-child"),at.attr("class","text"),x&&e.look!=="handDrawn")at.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")at.selectAll("path").attr("style",a);return at.attr("transform",`translate(${y}, 0)`),c.attr("transform",`translate(${-m/2+y-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,w,ot)},s}t(dx,"curlyBraceLeft");function Fi(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:k,y:w})}return c}t(Fi,"generateCirclePoints");async function px(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+(e.look==="neo"?l*2:l),u=n.height+(e.look==="neo"?p*2:p),y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...Fi(m/2,-u/2,y,20,-90,0),{x:m/2+y,y:-y},...Fi(m/2+y*2,-y,y,20,-180,-270),...Fi(m/2+y*2,y,y,20,-90,-180),{x:m/2+y,y:u/2},...Fi(m/2,u/2,y,20,0,90)],w=[{x:-m/2,y:-u/2-y},{x:m/2,y:-u/2-y},...Fi(m/2,-u/2,y,20,-90,0),{x:m/2+y,y:-y},...Fi(m/2+y*2,-y,y,20,-180,-270),...Fi(m/2+y*2,y,y,20,-90,-180),{x:m/2+y,y:u/2},...Fi(m/2,u/2,y,20,0,90),{x:m/2,y:u/2+y},{x:-m/2,y:u/2+y}],_=v.svg(s),M=Kt(e,{fill:"none"});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let Y=ye(k).replace("Z",""),V=_.path(Y,M),Q=ye(w),tt=_.path(Q,{...M}),at=s.insert("g",":first-child");if(at.insert(()=>tt,":first-child").attr("stroke-opacity",0),at.insert(()=>V,":first-child"),at.attr("class","text"),x&&e.look!=="handDrawn")at.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")at.selectAll("path").attr("style",a);return at.attr("transform",`translate(${-y}, 0)`),c.attr("transform",`translate(${-m/2+(e.padding??0)/2-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,w,ot)},s}t(px,"curlyBraceRight");function sr(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(sr,"generateCirclePoints");async function gx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+(e.look==="neo"?l*2:l),u=n.height+(e.look==="neo"?p*2:p),y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...sr(m/2,-u/2,y,30,-90,0),{x:-m/2-y,y},...sr(m/2+y*2,-y,y,20,-180,-270),...sr(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:-u/2},...sr(m/2,u/2,y,20,0,90)],w=[...sr(-m/2+y+y/2,-u/2,y,20,-90,-180),{x:m/2-y/2,y},...sr(-m/2-y/2,-y,y,20,0,90),...sr(-m/2-y/2,y,y,20,-90,0),{x:m/2-y/2,y:-y},...sr(-m/2+y+y/2,u/2,y,30,-180,-270)],_=[{x:m/2,y:-u/2-y},{x:-m/2,y:-u/2-y},...sr(m/2,-u/2,y,20,-90,0),{x:-m/2-y,y:-y},...sr(m/2+y*2,-y,y,20,-180,-270),...sr(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:u/2},...sr(m/2,u/2,y,20,0,90),{x:-m/2,y:u/2+y},{x:m/2-y-y/2,y:u/2+y},...sr(-m/2+y+y/2,-u/2,y,20,-90,-180),{x:m/2-y/2,y},...sr(-m/2-y/2,-y,y,20,0,90),...sr(-m/2-y/2,y,y,20,-90,0),{x:m/2-y/2,y:-y},...sr(-m/2+y+y/2,u/2,y,30,-180,-270)],M=v.svg(s),q=Kt(e,{fill:"none"});if(e.look!=="handDrawn")q.roughness=0,q.fillStyle="solid";let V=ye(k).replace("Z",""),Q=M.path(V,q),at=ye(w).replace("Z",""),ot=M.path(at,q),ht=ye(_),yt=M.path(ht,{...q}),Bt=s.insert("g",":first-child");if(Bt.insert(()=>yt,":first-child").attr("stroke-opacity",0),Bt.insert(()=>Q,":first-child"),Bt.insert(()=>ot,":first-child"),Bt.attr("class","text"),x&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return Bt.attr("transform",`translate(${y-y/4}, 0)`),c.attr("transform",`translate(${-m/2+(e.padding??0)/2-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,_,kt)},s}t(gx,"curlyBraces");async function mx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=20,p=5,{shapeSvg:m,bbox:u}=await U(r,e,te(e)),y=Math.max(p,u.height+c*2,e?.height??0),x=y/2,k=x-Math.sqrt(Math.max(0,x**2-(u.height/2)**2)),w=Math.max(y/4,k),_=Math.max(l,u.width+n*2+w*2,(u.width+n*2)*1.25,e?.width??0),{cssStyles:M}=e,q=v.svg(m),Y=Kt(e,{});if(e.look!=="handDrawn")Y.roughness=0,Y.fillStyle="solid";let V=_,Q=y,tt=V-x,at=Q/4,ot=[{x:tt,y:0},{x:at,y:0},{x:0,y:Q/2},{x:at,y:Q},{x:tt,y:Q},...ci(-tt,-Q/2,x,50,270,90)],ht=ye(ot),yt=q.path(ht,Y),Bt=m.insert(()=>yt,":first-child");if(Bt.attr("class","basic label-container outer-path"),M&&e.look!=="handDrawn")Bt.selectChildren("path").attr("style",M);if(a&&e.look!=="handDrawn")Bt.selectChildren("path").attr("style",a);return Bt.attr("transform",`translate(${-_/2}, ${-y/2})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,ot,kt)},m}t(mx,"curvedTrapezoid");async function yx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.padding??20,p=Math.max(n.width+l*2,e.width??0,100),m=Math.min(Math.max(p*0.23,16),56),u=m*0.27,y=Math.max(n.height+l*2,e.height?e.height-(2*m-u):0),x=Math.min(p*0.177,y*0.45),k=y+2*m-u,w=-k/2,_=w+2*m-u,M=s.insert("g",":first-child").attr("class","basic label-container"),{cssStyles:q}=e;if(e.look==="handDrawn"){let ht=v.svg(s),yt=Kt(e,{}),Bt=ht.path(Tr(-p/2,_,p,y,x),yt),kt=ht.circle(0,w+m,m*2,yt);if(M.insert(()=>kt,":first-child"),M.insert(()=>Bt,":first-child"),q)M.attr("style",q)}else M.append("rect").attr("x",-p/2).attr("y",_).attr("width",p).attr("height",y).attr("rx",x).attr("ry",x).attr("style",a),M.append("circle").attr("cx",0).attr("cy",w+m).attr("r",m).attr("style",a);B(e,M);let Y=_+y/2;c.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${Y-n.height/2-(n.y-(n.top??0))})`);let V=w+m,Q=Math.asin(Math.min(1,(_-V)/m))*180/Math.PI,tt=24,ot=[...ci(0,-V,m,tt,180+Q,-Q),...ci(-(-p/2+x),-(_+x),x,12,90,0),...ci(-(-p/2+x),-(k/2-x),x,12,360,270),...ci(-(p/2-x),-(k/2-x),x,12,270,180),...ci(-(p/2-x),-(_+x),x,12,180,90)];return e.intersect=function(ht){return T.polygon(e,ot,ht)},s}t(yx,"person");var eS=t((r,e,o,a,s,n)=>[`M${r},${e+n}`,`a${s},${n} 0,0,0 ${o},0`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`].join(" "),"createCylinderPathD"),rS=t((r,e,o,a,s,n)=>[`M${r},${e+n}`,`M${r+o},${e+n}`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`].join(" "),"createOuterCylinderPathD"),iS=t((r,e,o,a,s,n)=>[`M${r-o/2},${-a/2}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD"),vy=8,Ly=8;async function xx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?24:s,c=e.look==="neo"?24:s,l=e.width??0;if(e.width){if(e.width=e.width-c,e.width<Ly)e.width=Ly}if(e.height){let Y=l/2/(2.5+l/50);if(e.height=e.height-n-Y*3,e.height<vy)e.height=vy}let{shapeSvg:p,bbox:m,label:u}=await U(r,e,te(e)),y=Math.max(e.width??0,m.width)+c,x=y/2,k=x/(2.5+y/50),w=Math.max(e.height??0,m.height)+n+k,_,{cssStyles:M}=e;if(e.look==="handDrawn"){let q=v.svg(p),Y=rS(0,0,y,w,x,k),V=iS(0,k,y,w,x,k),Q=Kt(e,{}),tt=q.path(Y,Q),at=q.path(V,Kt(e,{fill:"none"}));if(_=p.insert(()=>at,":first-child"),_=p.insert(()=>tt,":first-child"),_.attr("class","basic label-container"),M)_.attr("style",M)}else{let q=eS(0,0,y,w,x,k);_=p.insert("path",":first-child").attr("d",q).attr("class","basic label-container outer-path").attr("style",Me(M)).attr("style",a)}return _.attr("label-offset-y",k),_.attr("transform",`translate(${-y/2}, ${-(w/2+k)})`),B(e,_),u.attr("transform",`translate(${-(m.width/2)-(m.x-(m.left??0))}, ${-(m.height/2)+(e.padding??0)/1.5-(m.y-(m.top??0))})`),e.intersect=function(q){let Y=T.rect(e,q),V=Y.x-(e.x??0);if(x!=0&&(Math.abs(V)<(e.width??0)/2||Math.abs(V)==(e.width??0)/2&&Math.abs(Y.y-(e.y??0))>(e.height??0)/2-k)){let Q=k*k*(1-V*V/(x*x));if(Q>0)Q=Math.sqrt(Q);if(Q=k-Q,q.y-(e.y??0)>0)Q=-Q;Y.y+=Q}return Y},p}t(xx,"cylinder");async function Ss(r,e,o){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c}=await U(r,e,te(e)),l=Math.max(c.width+o.labelPaddingX*2,e?.width||0),p=Math.max(c.height+o.labelPaddingY*2,e?.height||0),m=-l/2,u=-p/2,y,{rx:x,ry:k}=e,{cssStyles:w}=e;if(o?.rx&&o.ry)x=o.rx,k=o.ry;if(e.look==="handDrawn"){let _=v.svg(n),M=Kt(e,{}),q=x||k?_.path(Tr(m,u,l,p,x||0),M):_.rectangle(m,u,l,p,M);y=n.insert(()=>q,":first-child"),y.attr("class","basic label-container").attr("style",Me(w))}else y=n.insert("rect",":first-child"),y.attr("class","basic label-container").attr("style",s).attr("rx",Me(x)).attr("ry",Me(k)).attr("x",m).attr("y",u).attr("width",l).attr("height",p);return B(e,y,e.look==="handDrawn"?void 0:{width:l,height:p}),e.calcIntersect=function(_,M){return T.rect(_,M)},e.intersect=function(_){return T.rect(e,_)},n}t(Ss,"drawRect");async function Cx(r,e){let{cssClasses:o,labelPaddingX:a,labelPaddingY:s,padding:n,width:c,height:l}=e,p={rx:0,ry:0,classes:o??"",labelPaddingX:a??(n??0)*2,labelPaddingY:s??n??0},m=await Ss(r,e,p);if(e.look==="handDrawn"){let k=v.svg(m),w=Kt(e,{}),_=m.select(".basic.label-container > path:nth-child(2)"),M=_.node();if(!M)return m;let q=null;if(M instanceof SVGGraphicsElement)q=M.getBBox();else return m;return m.insert(()=>k.line(q.x,q.y,q.x+q.width,q.y,w),".basic.label-container g.label"),m.insert(()=>k.line(q.x,q.y+q.height,q.x+q.width,q.y+q.height,w),".basic.label-container g.label"),_.remove(),m}let u=m.select(".basic.label-container"),y=(Number(u.attr("width"))||c)??0,x=(Number(u.attr("height"))||l)??0;if(y>0&&x>0)u.attr("stroke-dasharray",`${y} ${x}`);return m}t(Cx,"datastore");async function bx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.look==="neo"?16:e.padding??0,n=e.look==="neo"?16:e.padding??0,{shapeSvg:c,bbox:l,label:p}=await U(r,e,te(e)),m=l.width+s,u=l.height+n,y=u*0.2,x=-m/2,k=-u/2-y/2,{cssStyles:w}=e,_=v.svg(c),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let q=[{x,y:k+y},{x:-x,y:k+y},{x:-x,y:-k},{x,y:-k},{x,y:k},{x:-x,y:k},{x:-x,y:k+y}],Y=_.polygon(q.map((Q)=>[Q.x,Q.y]),M),V=c.insert(()=>Y,":first-child");if(V.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")V.selectAll("path").attr("style",w);if(a&&e.look!=="handDrawn")V.selectAll("path").attr("style",a);return p.attr("transform",`translate(${x+(e.padding??0)/2-(l.x-(l.left??0))}, ${k+y+(e.padding??0)/2-(l.y-(l.top??0))})`),B(e,V),e.intersect=function(Q){return T.rect(e,Q)},c}t(bx,"dividedRectangle");async function kx(r,e){let{labelStyles:o,nodeStyles:a}=E(e),s=e.look==="neo"?12:5;e.labelStyle=o;let n=e.padding??0,c=e.look==="neo"?16:n,{shapeSvg:l,bbox:p}=await U(r,e,te(e),{ignoreMinWidth:!0}),m=Math.sqrt(p.width**2+p.height**2)/2,u=(e?.width?e?.width/2:m)+(c??0),y=u+s,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{roughness:0.2,strokeWidth:2.5}),M=Kt(e,{roughness:0.2,strokeWidth:1.5}),q=w.circle(0,0,y*2,_),Y=w.circle(0,0,u*2,M);x=l.insert("g",":first-child"),x.attr("class",Me(e.cssClasses)).attr("style",Me(k)),x.node()?.appendChild(q),x.node()?.appendChild(Y)}else{x=l.insert("g",":first-child");let w=x.insert("circle",":first-child"),_=x.insert("circle");x.attr("class","basic label-container").attr("style",a),w.attr("class","outer-circle").attr("style",a).attr("r",y).attr("cx",0).attr("cy",0),_.attr("class","inner-circle").attr("style",a).attr("r",u).attr("cx",0).attr("cy",0)}return B(e,x),e.intersect=function(w){return i.info("DoubleCircle intersect",e,y,w),T.circle(e,y,w)},l}t(kx,"doublecircle");async function wx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c}=await U(r,e,te(e)),{theme:l,themeVariables:p}=d();It(s,e.colorIndex,l,p.borderColorArray);let m=c??10,u=n.width/2+m*2,y=n.height/2+m*2,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(s),_=Kt(e,{}),M=w.ellipse(0,0,u*2,y*2,_);if(x=s.insert(()=>M,":first-child"),x.attr("class","basic label-container"),k)x.attr("style",k)}else x=s.insert("ellipse",":first-child").attr("class","basic label-container").attr("style",a).attr("rx",u).attr("ry",y).attr("cx",0).attr("cy",0);return e.width=u*2,e.height=y*2,B(e,x),e.calcIntersect=function(w,_){let M=w.width/2,q=w.height/2;return T.ellipse(w,M,q,_)},e.intersect=function(w){return T.ellipse(e,u,y,w)},s}t(wx,"usecaseEllipse");function Sx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.label="",e.labelStyle=a;let n=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),c=7,{cssStyles:l}=e,p=v.svg(n),{nodeBorder:m}=o,u=Kt(e,{fillStyle:"solid"});if(e.look!=="handDrawn")u.roughness=0;let y=p.circle(0,0,c*2,u),x=n.insert(()=>y,":first-child");if(x.selectAll("path").attr("style",`fill: ${m} !important;`),l&&l.length>0&&e.look!=="handDrawn")x.selectAll("path").attr("style",l);if(s&&e.look!=="handDrawn")x.selectAll("path").attr("style",s);return B(e,x),e.intersect=function(k){return i.info("filledCircle intersect",e,{radius:c,point:k}),T.circle(e,c,k)},n}t(Sx,"filledCircle");var Fy=10,Ay=10;async function Tx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?s*2:s;if(e.width||e.height){if(e.height=e?.height??0,e.height<Fy)e.height=Fy;if(e.width=(e?.width??0)-n-n/2,e.width<Ay)e.width=Ay}let{shapeSvg:c,bbox:l,label:p}=await U(r,e,te(e)),m=(e?.width?e?.width:l.width)+(n??0),u=e?.height?e?.height:m+l.height,y=u,x=[{x:0,y:-u},{x:y,y:-u},{x:y/2,y:0}],{cssStyles:k}=e,w=v.svg(c),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=ye(x),q=w.path(M,_),Y=c.insert(()=>q,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`).attr("class","outer-path");if(k&&e.look!=="handDrawn")Y.selectChildren("path").attr("style",k);if(a&&e.look!=="handDrawn")Y.selectChildren("path").attr("style",a);return e.width=m,e.height=u,B(e,Y),p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))}, ${-u/2+(e.padding??0)/2+(l.y-(l.top??0))})`),e.intersect=function(V){return i.info("Triangle intersect",e,x,V),T.polygon(e,x,V)},c}t(Tx,"flippedTriangle");async function _x(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.padding??12,p=Math.max(n.width+l*2,e.width??0,90),m=n.height+l*2,u=Math.max(Math.min(m*0.16,14),8),y=Math.max(m+u,e.height??0),x=y-u,k=Math.max(p*0.38,28),w=-y/2,_=[{x:-p/2,y:w},{x:-p/2+k,y:w},{x:-p/2+k,y:w+u},{x:p/2,y:w+u},{x:p/2,y:y/2},{x:-p/2,y:y/2}],M=[`M${_[0].x},${_[0].y}`,..._.slice(1).map((Q)=>`L${Q.x},${Q.y}`),"Z"].join(" "),{cssStyles:q}=e,Y;if(e.look==="handDrawn"){let tt=v.svg(s).path(M,Kt(e,{}));if(Y=s.insert(()=>tt,":first-child").attr("class","basic label-container"),q)Y.attr("style",q)}else Y=s.insert("path",":first-child").attr("d",M).attr("class","basic label-container").attr("style",a);if(e.look==="handDrawn")B(e,Y);else B(e,Y,{width:p,height:y});let V=w+u+x/2;return c.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${V-n.height/2-(n.y-(n.top??0))})`),e.intersect=function(Q){return T.polygon(e,_,Q)},s}t(_x,"folder");function Bx(r,e,{dir:o,config:{state:a,themeVariables:s}}){let{nodeStyles:n}=E(e);e.label="";let c=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:l}=e,p=Math.max(70,e?.width??0),m=Math.max(10,e?.height??0);if(o==="LR"||o==="RL")p=Math.max(10,e?.width??0),m=Math.max(70,e?.height??0);let u=-1*p/2,y=-1*m/2,x=v.svg(c),k=Kt(e,{stroke:s.lineColor,fill:s.lineColor});if(e.look!=="handDrawn")k.roughness=0,k.fillStyle="solid";let w=x.rectangle(u,y,p,m,k),_=c.insert(()=>w,":first-child");if(l&&e.look!=="handDrawn")_.selectAll("path").attr("style",l);if(n&&e.look!=="handDrawn")_.selectAll("path").attr("style",n);B(e,_);let M=a?.padding??0;if(e.width&&e.height)e.width+=M/2||0,e.height+=M/2||0;return e.intersect=function(q){return T.rect(e,q)},c}t(Bx,"forkJoin");async function vx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=15,n=10,c=e.look==="neo"?16:e.padding??0,l=e.look==="neo"?12:e.padding??0;if(e.width||e.height){if(e.height=(e?.height??0)-l*2,e.height<n)e.height=n;if(e.width=(e?.width??0)-c*2,e.width<s)e.width=s}let{shapeSvg:p,bbox:m}=await U(r,e,te(e)),u=(e?.height?e?.height:Math.max(n,m.height))+l*2,y=u/2,x=y-Math.sqrt(Math.max(0,y**2-(m.height/2)**2)),k=(e?.width?e?.width:Math.max(s,m.width)+x*2)+c*2,{cssStyles:w}=e,_=v.svg(p),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let q=[{x:-k/2,y:-u/2},{x:k/2-y,y:-u/2},...ci(-k/2+y,0,y,50,90,270),{x:k/2-y,y:u/2},{x:-k/2,y:u/2}],Y=ye(q),V=_.path(Y,M),Q=p.insert(()=>V,":first-child");if(Q.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")Q.selectChildren("path").attr("style",w);if(a&&e.look!=="handDrawn")Q.selectChildren("path").attr("style",a);return B(e,Q),e.intersect=function(tt){return i.info("Pill intersect",e,{radius:y,point:tt}),T.polygon(e,q,tt)},p}t(vx,"halfRoundedRectangle");var oS=t((r,e,o,a,s)=>[`M${r+s},${e}`,`L${r+o-s},${e}`,`L${r+o},${e-a/2}`,`L${r+o-s},${e-a}`,`L${r+s},${e-a}`,`L${r},${e-a/2}`,"Z"].join(" "),"createHexagonPathD");async function Lx(r,e){let{labelStyles:o,nodeStyles:a}=E(e),s=e.look==="neo"?3.5:4;e.labelStyle=o;let n=e.padding??0,c=70,l=32,p=e.look==="neo"?c:n,m=e.look==="neo"?l:n;if(e.width||e.height){let V=(e.height??0)/s;e.width=(e?.width??0)-2*V-m,e.height=(e.height??0)-p}let{shapeSvg:u,bbox:y}=await U(r,e,te(e)),x=(e?.height?e?.height:y.height)+p,k=x/s,w=(e?.width?e?.width:y.width)+2*k+m,_=[{x:k,y:0},{x:w-k,y:0},{x:w,y:-x/2},{x:w-k,y:-x},{x:k,y:-x},{x:0,y:-x/2}],M,{cssStyles:q}=e;if(e.look==="handDrawn"){let Y=v.svg(u),V=Kt(e,{}),Q=oS(0,0,w,x,k),tt=Y.path(Q,V);if(M=u.insert(()=>tt,":first-child").attr("transform",`translate(${-w/2}, ${x/2})`),q)M.attr("style",q)}else M=fi(u,w,x,_);if(a)M.attr("style",a);return e.width=w,e.height=x,B(e,M),e.intersect=function(Y){return T.polygon(e,_,Y)},u}t(Lx,"hexagon");async function Fx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.label="",e.labelStyle=o;let{shapeSvg:s}=await U(r,e,te(e)),n=Math.max(30,e?.width??0),c=Math.max(30,e?.height??0),{cssStyles:l}=e,p=v.svg(s),m=Kt(e,{});if(e.look!=="handDrawn")m.roughness=0,m.fillStyle="solid";let u=[{x:0,y:0},{x:n,y:0},{x:0,y:c},{x:n,y:c}],y=ye(u),x=p.path(y,m),k=s.insert(()=>x,":first-child");if(k.attr("class","basic label-container outer-path"),l&&e.look!=="handDrawn")k.selectChildren("path").attr("style",l);if(a&&e.look!=="handDrawn")k.selectChildren("path").attr("style",a);return k.attr("transform",`translate(${-n/2}, ${-c/2})`),B(e,k),e.intersect=function(w){return i.info("Pill intersect",e,{points:u}),T.polygon(e,u,w)},s}t(Fx,"hourglass");async function Ax(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,label:y}=await U(r,e,"icon-shape default"),x=e.pos==="t",k=l,w=l,{nodeBorder:_}=o,{stylesMap:M}=ai(e),q=-w/2,Y=-k/2,V=e.label?8:0,Q=v.svg(m),tt=Kt(e,{stroke:"none",fill:"none"});if(e.look!=="handDrawn")tt.roughness=0,tt.fillStyle="solid";let at=Q.rectangle(q,Y,w,k,tt),ot=Math.max(w,u.width),ht=k+u.height+V,yt=Q.rectangle(-ot/2,-ht/2,ot,ht,{...tt,fill:"transparent",stroke:"none"}),Bt=m.insert(()=>at,":first-child"),kt=m.insert(()=>yt);if(e.icon){let Ct=m.append("g");Ct.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let rt=Ct.node().getBBox(),{width:it,height:gt,x:et,y:wt}=rt;Ct.attr("transform",`translate(${-it/2-et},${x?u.height/2+V/2-gt/2-wt:-u.height/2-V/2-gt/2-wt})`),Ct.attr("style",`color: ${M.get("stroke")??_};`)}return y.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${x?-ht/2:ht/2-u.height})`),Bt.attr("transform",`translate(0,${x?u.height/2+V/2:-u.height/2-V/2})`),B(e,kt),e.intersect=function(Ct){if(i.info("iconSquare intersect",e,Ct),!e.label)return T.rect(e,Ct);let rt=e.x??0,it=e.y??0,gt=e.height??0,et=[];if(x)et=[{x:rt-u.width/2,y:it-gt/2},{x:rt+u.width/2,y:it-gt/2},{x:rt+u.width/2,y:it-gt/2+u.height+V},{x:rt+w/2,y:it-gt/2+u.height+V},{x:rt+w/2,y:it+gt/2},{x:rt-w/2,y:it+gt/2},{x:rt-w/2,y:it-gt/2+u.height+V},{x:rt-u.width/2,y:it-gt/2+u.height+V}];else et=[{x:rt-w/2,y:it-gt/2},{x:rt+w/2,y:it-gt/2},{x:rt+w/2,y:it-gt/2+k},{x:rt+u.width/2,y:it-gt/2+k},{x:rt+u.width/2/2,y:it+gt/2},{x:rt-u.width/2,y:it+gt/2},{x:rt-u.width/2,y:it-gt/2+k},{x:rt-w/2,y:it-gt/2+k}];return T.polygon(e,et,Ct)},m}t(Ax,"icon");async function Mx(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,label:y}=await U(r,e,"icon-shape default"),x=20,k=e.label?8:0,w=e.pos==="t",{nodeBorder:_,mainBkg:M}=o,{stylesMap:q}=ai(e),Y=v.svg(m),V=Kt(e,{});if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let Q=q.get("fill");V.stroke=Q??M;let tt=m.append("g");if(e.icon)tt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let at=tt.node().getBBox(),{width:ot,height:ht,x:yt,y:Bt}=at,kt=Math.max(ot,ht)*Math.SQRT2+x*2,Ct=Y.circle(0,0,kt,V),rt=Math.max(kt,u.width),it=kt+u.height+k,gt=Y.rectangle(-rt/2,-it/2,rt,it,{...V,fill:"transparent",stroke:"none"}),et=m.insert(()=>Ct,":first-child"),wt=m.insert(()=>gt);return tt.attr("transform",`translate(${-ot/2-yt},${w?u.height/2+k/2-ht/2-Bt:-u.height/2-k/2-ht/2-Bt})`),tt.attr("style",`color: ${q.get("stroke")??_};`),y.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${w?-it/2:it/2-u.height})`),et.attr("transform",`translate(0,${w?u.height/2+k/2:-u.height/2-k/2})`),B(e,wt),e.intersect=function(vt){return i.info("iconSquare intersect",e,vt),T.rect(e,vt)},m}t(Mx,"iconCircle");async function Ex(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,halfPadding:y,label:x}=await U(r,e,"icon-shape default"),k=e.pos==="t",w=l+y*2,_=l+y*2,{nodeBorder:M,mainBkg:q}=o,{stylesMap:Y}=ai(e),V=-_/2,Q=-w/2,tt=e.label?8:0,at=v.svg(m),ot=Kt(e,{});if(e.look!=="handDrawn")ot.roughness=0,ot.fillStyle="solid";let ht=Y.get("fill");ot.stroke=ht??q;let yt=at.path(Tr(V,Q,_,w,5),ot),Bt=Math.max(_,u.width),kt=w+u.height+tt,Ct=at.rectangle(-Bt/2,-kt/2,Bt,kt,{...ot,fill:"transparent",stroke:"none"}),rt=m.insert(()=>yt,":first-child").attr("class","icon-shape2"),it=m.insert(()=>Ct);if(e.icon){let gt=m.append("g");gt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let et=gt.node().getBBox(),{width:wt,height:vt,x:Xt,y:jt}=et;gt.attr("transform",`translate(${-wt/2-Xt},${k?u.height/2+tt/2-vt/2-jt:-u.height/2-tt/2-vt/2-jt})`),gt.attr("style",`color: ${Y.get("stroke")??M};`)}return x.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${k?-kt/2:kt/2-u.height})`),rt.attr("transform",`translate(0,${k?u.height/2+tt/2:-u.height/2-tt/2})`),B(e,it),e.intersect=function(gt){if(i.info("iconSquare intersect",e,gt),!e.label)return T.rect(e,gt);let et=e.x??0,wt=e.y??0,vt=e.height??0,Xt=[];if(k)Xt=[{x:et-u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt+vt/2},{x:et-_/2,y:wt+vt/2},{x:et-_/2,y:wt-vt/2+u.height+tt},{x:et-u.width/2,y:wt-vt/2+u.height+tt}];else Xt=[{x:et-_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2+w},{x:et+u.width/2,y:wt-vt/2+w},{x:et+u.width/2/2,y:wt+vt/2},{x:et-u.width/2,y:wt+vt/2},{x:et-u.width/2,y:wt-vt/2+w},{x:et-_/2,y:wt-vt/2+w}];return T.polygon(e,Xt,gt)},m}t(Ex,"iconRounded");async function Ox(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,halfPadding:y,label:x}=await U(r,e,"icon-shape default"),k=e.pos==="t",w=l+y*2,_=l+y*2,{nodeBorder:M,mainBkg:q}=o,{stylesMap:Y}=ai(e),V=-_/2,Q=-w/2,tt=e.label?8:0,at=v.svg(m),ot=Kt(e,{});if(e.look!=="handDrawn")ot.roughness=0,ot.fillStyle="solid";let ht=Y.get("fill");ot.stroke=ht??q;let yt=at.path(Tr(V,Q,_,w,0.1),ot),Bt=Math.max(_,u.width),kt=w+u.height+tt,Ct=at.rectangle(-Bt/2,-kt/2,Bt,kt,{...ot,fill:"transparent",stroke:"none"}),rt=m.insert(()=>yt,":first-child"),it=m.insert(()=>Ct);if(e.icon){let gt=m.append("g");gt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let et=gt.node().getBBox(),{width:wt,height:vt,x:Xt,y:jt}=et;gt.attr("transform",`translate(${-wt/2-Xt},${k?u.height/2+tt/2-vt/2-jt:-u.height/2-tt/2-vt/2-jt})`),gt.attr("style",`color: ${Y.get("stroke")??M};`)}return x.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${k?-kt/2:kt/2-u.height})`),rt.attr("transform",`translate(0,${k?u.height/2+tt/2:-u.height/2-tt/2})`),B(e,it),e.intersect=function(gt){if(i.info("iconSquare intersect",e,gt),!e.label)return T.rect(e,gt);let et=e.x??0,wt=e.y??0,vt=e.height??0,Xt=[];if(k)Xt=[{x:et-u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt+vt/2},{x:et-_/2,y:wt+vt/2},{x:et-_/2,y:wt-vt/2+u.height+tt},{x:et-u.width/2,y:wt-vt/2+u.height+tt}];else Xt=[{x:et-_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2+w},{x:et+u.width/2,y:wt-vt/2+w},{x:et+u.width/2/2,y:wt+vt/2},{x:et-u.width/2,y:wt+vt/2},{x:et-u.width/2,y:wt-vt/2+w},{x:et-_/2,y:wt-vt/2+w}];return T.polygon(e,Xt,gt)},m}t(Ox,"iconSquare");async function Ix(r,e,{config:{flowchart:o}}){let a=new Image;a.src=e?.img??"",await a.decode();let s=Number(a.naturalWidth.toString().replace("px","")),n=Number(a.naturalHeight.toString().replace("px",""));e.imageAspectRatio=s/n;let{labelStyles:c}=E(e);e.labelStyle=c;let l=o?.wrappingWidth;e.defaultWidth=o?.wrappingWidth;let p=Math.max(e.label?l??0:0,e?.assetWidth??s),m=e.constraint==="on"?e?.assetHeight?e.assetHeight*e.imageAspectRatio:p:p,u=e.constraint==="on"?m/e.imageAspectRatio:e?.assetHeight??n;e.width=Math.max(m,l??0);let{shapeSvg:y,bbox:x,label:k}=await U(r,e,"image-shape default"),w=e.pos==="t",_=-m/2,M=-u/2,q=e.label?8:0,Y=v.svg(y),V=Kt(e,{});if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let Q=Y.rectangle(_,M,m,u,V),tt=Math.max(m,x.width),at=u+x.height+q,ot=Y.rectangle(-tt/2,-at/2,tt,at,{...V,fill:"none",stroke:"none"}),ht=y.insert(()=>Q,":first-child"),yt=y.insert(()=>ot);if(e.img){let Bt=y.append("image");Bt.attr("href",e.img),Bt.attr("width",m),Bt.attr("height",u),Bt.attr("preserveAspectRatio","none"),Bt.attr("transform",`translate(${-m/2},${w?at/2-u:-at/2})`)}return k.attr("transform",`translate(${-x.width/2-(x.x-(x.left??0))},${w?-u/2-x.height/2-q/2:u/2-x.height/2+q/2})`),ht.attr("transform",`translate(0,${w?x.height/2+q/2:-x.height/2-q/2})`),B(e,yt),e.intersect=function(Bt){if(i.info("iconSquare intersect",e,Bt),!e.label)return T.rect(e,Bt);let kt=e.x??0,Ct=e.y??0,rt=e.height??0,it=[];if(w)it=[{x:kt-x.width/2,y:Ct-rt/2},{x:kt+x.width/2,y:Ct-rt/2},{x:kt+x.width/2,y:Ct-rt/2+x.height+q},{x:kt+m/2,y:Ct-rt/2+x.height+q},{x:kt+m/2,y:Ct+rt/2},{x:kt-m/2,y:Ct+rt/2},{x:kt-m/2,y:Ct-rt/2+x.height+q},{x:kt-x.width/2,y:Ct-rt/2+x.height+q}];else it=[{x:kt-m/2,y:Ct-rt/2},{x:kt+m/2,y:Ct-rt/2},{x:kt+m/2,y:Ct-rt/2+u},{x:kt+x.width/2,y:Ct-rt/2+u},{x:kt+x.width/2/2,y:Ct+rt/2},{x:kt-x.width/2,y:Ct+rt/2},{x:kt-x.width/2,y:Ct-rt/2+u},{x:kt-m/2,y:Ct-rt/2+u}];return T.polygon(e,it,Bt)},y}t(Ix,"imageSquare");async function $x(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=Math.max(p.height+n*2,e.height??0),u=Math.max(p.width+c*2,(e.width??0)-m),y=[{x:0,y:0},{x:u,y:0},{x:u+3*m/6,y:-m},{x:-3*m/6,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),q=w.path(M,_);if(x=l.insert(()=>q,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t($x,"inv_trapezoid");async function Dx(r,e){let{shapeSvg:o,bbox:a,label:s}=await U(r,e,"label"),n=o.insert("rect",":first-child"),c=0.1,l=0.1;return n.attr("width",0.1).attr("height",0.1),o.attr("class","label edgeLabel"),s.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),B(e,n),e.intersect=function(p){return T.rect(e,p)},o}t(Dx,"labelRect");async function Px(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=Math.max(p.height+n,e.height??0),u=Math.max(p.width+c,(e.width??0)-m),y=[{x:0,y:0},{x:u+3*m/6,y:0},{x:u,y:-m},{x:-(3*m)/6,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),q=w.path(M,_);if(x=l.insert(()=>q,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t(Px,"lean_left");async function Rx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=Math.max(p.height+n,e.height??0),u=Math.max(p.width+c,(e.width??0)-m),y=[{x:-3*m/6,y:0},{x:u,y:0},{x:u+3*m/6,y:-m},{x:0,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),q=w.path(M,_);if(x=l.insert(()=>q,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t(Rx,"lean_right");function qx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.label="",e.labelStyle=o;let s=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:n}=e,c=Math.max(35,e?.width??0),l=Math.max(35,e?.height??0),p=7,m=[{x:c,y:0},{x:0,y:l+p/2},{x:c-2*p,y:l+p/2},{x:0,y:2*l},{x:c,y:l-p/2},{x:2*p,y:l-p/2}],u=v.svg(s),y=Kt(e,{});if(e.look!=="handDrawn")y.roughness=0,y.fillStyle="solid";let x=ye(m),k=u.path(x,y),w=s.insert(()=>k,":first-child");if(w.attr("class","outer-path"),n&&e.look!=="handDrawn")w.selectAll("path").attr("style",n);if(a&&e.look!=="handDrawn")w.selectAll("path").attr("style",a);return w.attr("transform",`translate(-${c/2},${-l})`),B(e,w),e.intersect=function(_){return i.info("lightningBolt intersect",e,_),T.polygon(e,m,_)},s}t(qx,"lightningBolt");var sS=t((r,e,o,a,s,n,c)=>[`M${r},${e+n}`,`a${s},${n} 0,0,0 ${o},0`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`,`M${r},${e+n+c}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createCylinderPathD"),aS=t((r,e,o,a,s,n,c)=>[`M${r},${e+n}`,`M${r+o},${e+n}`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`,`M${r},${e+n+c}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createOuterCylinderPathD"),nS=t((r,e,o,a,s,n)=>[`M${r-o/2},${-a/2}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD"),My=10,Ey=10;async function Nx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?24:s;if(e.width||e.height){let q=e.width??0;if(e.width=(e.width??0)-n,e.width<Ey)e.width=Ey;let V=q/2/(2.5+q/50);if(e.height=(e.height??0)-c-V*3,e.height<My)e.height=My}let{shapeSvg:l,bbox:p,label:m}=await U(r,e,te(e)),u=(e?.width?e?.width:p.width)+n*2,y=u/2,x=y/(2.5+u/50),k=(e?.height?e?.height:p.height)+x+c*2,w=k*0.1,_,{cssStyles:M}=e;if(e.look==="handDrawn"){let q=v.svg(l),Y=aS(0,0,u,k,y,x,w),V=nS(0,x,u,k,y,x),Q=Kt(e,{}),tt=q.path(Y,Q),at=q.path(V,Q);if(l.insert(()=>at,":first-child").attr("class","line"),_=l.insert(()=>tt,":first-child"),_.attr("class","basic label-container"),M)_.attr("style",M)}else{let q=sS(0,0,u,k,y,x,w);_=l.insert("path",":first-child").attr("d",q).attr("class","basic label-container outer-path").attr("style",Me(M)).attr("style",a)}return _.attr("label-offset-y",x),_.attr("transform",`translate(${-u/2}, ${-(k/2+x)})`),B(e,_),m.attr("transform",`translate(${-(p.width/2)-(p.x-(p.left??0))}, ${-(p.height/2)+x-(p.y-(p.top??0))})`),e.intersect=function(q){let Y=T.rect(e,q),V=Y.x-(e.x??0);if(y!=0&&(Math.abs(V)<(e.width??0)/2||Math.abs(V)==(e.width??0)/2&&Math.abs(Y.y-(e.y??0))>(e.height??0)/2-x)){let Q=x*x*(1-V*V/(y*y));if(Q>0)Q=Math.sqrt(Q);if(Q=x-Q,q.y-(e.y??0)>0)Q=-Q;Y.y+=Q}return Y},l}t(Nx,"linedCylinder");async function Wx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height){let Q=e.width;if(e.width=(Q??0)*10/11-n*2,e.width<10)e.width=10;if(e.height=(e?.height??0)-c*2,e.height<10)e.height=10}let{shapeSvg:l,bbox:p,label:m}=await U(r,e,te(e)),u=(e?.width?e?.width:p.width)+(n??0)*2,y=(e?.height?e?.height:p.height)+(c??0)*2,x=e.look==="neo"?y/4:y/8,k=y+x,{cssStyles:w}=e,_=v.svg(l),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let q=[{x:-u/2-u/2*0.1,y:-k/2},{x:-u/2-u/2*0.1,y:k/2},...Ji(-u/2-u/2*0.1,k/2,u/2+u/2*0.1,k/2,x,0.8),{x:u/2+u/2*0.1,y:-k/2},{x:-u/2-u/2*0.1,y:-k/2},{x:-u/2,y:-k/2},{x:-u/2,y:k/2*1.1},{x:-u/2,y:-k/2}],Y=_.polygon(q.map((Q)=>[Q.x,Q.y]),M),V=l.insert(()=>Y,":first-child");if(V.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")V.selectAll("path").attr("style",w);if(a&&e.look!=="handDrawn")V.selectAll("path").attr("style",a);return V.attr("transform",`translate(0,${-x/2})`),m.attr("transform",`translate(${-u/2+(e.padding??0)+u/2*0.1/2-(p.x-(p.left??0))},${-y/2+(e.padding??0)-x-(p.y-(p.top??0))})`),B(e,V),e.intersect=function(Q){return T.polygon(e,q,Q)},l}t(Wx,"linedWaveEdgedRect");var lS=56,Uf=72,Oy=8,Iy=2,hS=8,cS={normal:"usecase-actor-shape usecase-actor-normal",hollow:"usecase-actor-hollow",awesome:"usecase-actor-awesome",icon:"usecase-actor-icon"},$y=Math.PI/3,Dy=0.6,jf=t((r,e)=>{let o=e*Dy,a=e*Math.sqrt(1-Dy**2),s=Math.cos($y),n=-Math.sin($y),c=o*-n,l=r+o*s,p=a*s,m=a*n;return`M ${c-p} ${l-m} L ${c+p} ${l+m}`},"businessMarkerPathForCircle"),uS={normal:jf(-24,12),hollow:jf(-23,9),awesome:jf(-21,13),icon:"M 12 -8 L 26 -26"},Py=t((r,e,o)=>{let a=(e.x??0)-(e.left??0),s=(e.y??0)-(e.top??0);r.attr("transform",`translate(${-e.width/2-a},${o-e.height/2-s})`)},"positionLabel"),od=t((r,e,o,a,s=!1)=>{if(e.look==="handDrawn"){let l=v.svg(r).path(o,Kt(e,s?{fill:"none"}:{}));return r.insert(()=>l,":first-child").attr("class",a)}let n=r.append("path").attr("class",a).attr("d",o);if(s)n.attr("fill","none");return n},"appendActorPath"),fS=t((r,e,o,a,s,n,c=!1)=>{if(e.look==="handDrawn"){let m=v.svg(r).circle(o,a,s*2,Kt(e,c?{fill:"none"}:{}));return r.insert(()=>m,":first-child").attr("class",n)}let l=r.append("circle").attr("class",n).attr("cx",o).attr("cy",a).attr("r",s);if(c)l.attr("fill","none");return l},"appendActorCircle");var dS=t((r,e,o)=>{if(!e.business)return;r.append("path").attr("class","usecase-business-marker usecase-actor-business-marker").attr("d",uS[o]).attr("fill","none").attr("style","stroke: inherit !important; stroke-width: inherit !important")},"appendBusinessActorMarker");async function rn(r,e,o,a){let{labelStyles:s,nodeStyles:n}=E(e);e.labelStyle=s;let c=o==="icon"||e.stereotype!==void 0?{...e,icon:o==="icon"?void 0:e.icon,stereotype:void 0}:e,{shapeSvg:l,bbox:p,label:m}=await U(r,c,te(e,`usecase-actor-variant usecase-actor-${o}`)),u=e.accessibleName??e.label;if(u)l.attr("role","img").attr("aria-label",u);m.attr("class","label actor-label usecase-actor-label");let{theme:y,themeVariables:x}=d();It(l,e.colorIndex,y,x.borderColorArray);let k,w;if(e.stereotype){let ht=await uo(l,`«${e.stereotype}»`,{labelStyle:s,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0,width:e.wrappingWidth});k=ht.label.attr("class","label usecase-stereotype"),w=ht.bbox}let _=l.append("g").attr("class",`usecase-actor-glyph ${cS[o]}`).attr("style",n||null);await a(_,e),dS(_,e,o);let M=e.padding??hS,q=w?.height??0,Y=Uf+Oy+p.height+(w?q+Iy:0),V=Math.max(lS,p.width,w?.width??0)+M*2,Q=Y+M*2,tt=-Y/2;_.attr("transform",`translate(0,${tt+Uf/2})`);let at=tt+Uf+Oy;if(k&&w)at+=q/2,Py(k,w,at),at+=q/2+Iy;Py(m,p,at+p.height/2);let ot=l.insert("rect",":first-child").attr("class","usecase-actor-outline").attr("x",-V/2).attr("y",-Q/2).attr("width",V).attr("height",Q).attr("opacity",0).attr("aria-hidden","true");return B(e,ot),e.intersect=(ht)=>T.rect(e,ht),l}t(rn,"renderUsecaseActor");var pS=["M 0 -12","C 6.627 -12 12 -17.373 12 -24","C 12 -30.627 6.627 -36 0 -36","C -6.627 -36 -12 -30.627 -12 -24","C -12 -17.373 -6.627 -12 0 -12 Z","M 0 -12 V 8","M -17 -5 H 17","M 0 8 L -15 28","M 0 8 L 15 28"].join(" ");async function zx(r,e){return rn(r,e,"normal",(o,a)=>{od(o,a,pS,"usecase-actor-stick")})}t(zx,"usecaseActor");var gS=["M 0 -34","C 7.18 -34 13 -28.18 13 -21","C 13 -13.82 7.18 -8 0 -8","C -7.18 -8 -13 -13.82 -13 -21","C -13 -28.18 -7.18 -34 0 -34 Z","M -24 25","C -24 7 -14 -3 0 -3","C 14 -3 24 7 24 25","C 24 28 21 30 18 30","H -18","C -21 30 -24 28 -24 25 Z"].join(" ");async function Hx(r,e){return rn(r,e,"awesome",(o,a)=>{od(o,a,gS,"usecase-actor-awesome-silhouette")})}t(Hx,"usecaseActorAwesome");var mS=["M -22 -10","H 22","V 0","H 6","L 22 17","L 13 28","L 0 13","L -13 28","L -22 17","L -6 0","H -22","Z"].join(" ");async function Yx(r,e){return rn(r,e,"hollow",(o,a)=>{fS(o,a,0,-23,9,"usecase-actor-hollow-head",!0),od(o,a,mS,"usecase-actor-hollow-body",!0)})}t(Yx,"usecaseActorHollow");var Cs=52,Ry=42,qy=-2,yS=t(async(r,e)=>{let o=-Cs/2,a=qy-Cs/2;if(e.look==="handDrawn"){let u=v.svg(r).rectangle(o,a,Cs,Cs,Kt(e,{}));r.insert(()=>u,":first-child").attr("class","usecase-actor-icon-frame")}else r.append("rect").attr("class","usecase-actor-icon-frame").attr("x",o).attr("y",a).attr("width",Cs).attr("height",Cs).attr("rx",4).attr("ry",4);let s=e.icon??"",n=await gl(s.includes(":")?s:`fa:${s}`),c=await Gt(s,{height:Ry,width:Ry,fallbackPrefix:"fa"}),l=r.append("g").attr("class",`usecase-actor-icon-symbol${n?"":" usecase-actor-icon-fallback"}`).attr("aria-hidden","true").html(`<g>${c}</g>`),p=l.node()?.getBBox();if(p)l.attr("transform",`translate(${-p.width/2-p.x},${qy-p.height/2-p.y})`)},"drawIconActor");async function Ux(r,e){return rn(r,e,"icon",yS)}t(Ux,"usecaseActorIcon");var Ny=t((r,e,o)=>{let a=(e.x??0)-(e.left??0),s=(e.y??0)-(e.top??0);r.attr("transform",`translate(${-e.width/2-a},${o-e.height/2-s})`)},"positionLabel");async function jx(r,e){let o=e,{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let n=o.stereotype?{...e,stereotype:void 0}:e,{shapeSvg:c,bbox:l,halfPadding:p,label:m}=await U(r,n,te(e,"usecase-business-shape"));m.attr("class","label usecase-label");let{theme:u,themeVariables:y}=d();It(c,e.colorIndex,u,y.borderColorArray);let x,k;if(o.stereotype){let rt=await uo(c,`«${o.stereotype}»`,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0,width:e.wrappingWidth});x=rt.label.attr("class","label usecase-stereotype"),k=rt.bbox}let w=k?2:0,_=l.height+(k?.height??0)+w,M=Math.max(l.width,k?.width??0),q=p??10,Y=M/2+q*2,V=_/2+q*2,Q=Math.min(Math.max(q/5,1),q/2),tt=M/2+Q,at=Y-Q,ot=tt/Y,ht=at/Y,yt=V*Math.sqrt(Math.max(0,1-ot*ot)),Bt=-V*Math.sqrt(Math.max(0,1-ht*ht));if(x&&k)Ny(x,k,-_/2+k.height/2);Ny(m,l,_/2-l.height/2);let kt;if(e.look==="handDrawn"){let it=v.svg(c).ellipse(0,0,Y*2,V*2,Kt(e,{}));kt=c.insert(()=>it,":first-child").attr("class","basic label-container usecase-business-ellipse")}else kt=c.insert("ellipse",":first-child").attr("class","basic label-container usecase-business-ellipse").attr("style",s).attr("rx",Y).attr("ry",V).attr("cx",0).attr("cy",0);c.append("path").attr("class","usecase-business-marker").attr("d",`M ${tt} ${yt} L ${at} ${Bt}`).attr("fill","none").attr("style",s||null);let Ct=o.accessibleName??o.label;if(Ct)c.attr("role","img").attr("aria-label",Ct);return B(e,kt),e.calcIntersect=(rt,it)=>T.ellipse(rt,rt.width/2,rt.height/2,it),e.intersect=(rt)=>T.ellipse(e,Y,V,rt),c}t(jx,"usecaseBusiness");var Gf=8,Wy=4,xS=1,Xf=t((r,e,o,a)=>{let s=(e.x??0)-(e.left??0),n=(e.y??0)-(e.top??0);r.attr("transform",`translate(${o-e.width/2-s},${a-e.height/2-n})`)},"positionLabel"),CS=t((r)=>{let e=Number.parseFloat(r??"");return Number.isFinite(e)&&e>=0?e:xS},"numericStrokeWidth");async function Gx(r,e){let o=e,{labelStyles:a,nodeStyles:s}=E(e),{stylesMap:n}=ai(e);e.labelStyle=a;let{shapeSvg:c,bbox:l,label:p}=await U(r,e,te(e,"usecase-json-table"));if(c.attr("role","img"),o.accessibleName)c.attr("aria-label",o.accessibleName);p.attr("class","label usecase-json-title");let m=c.append("g").attr("class","usecase-json-table-grid"),u=[];for(let rt of o.jsonRows??[]){let it=await uo(m,rt.key,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0}),gt=await uo(m,rt.value,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0});u.push({key:{label:it.label.attr("class","label usecase-json-key"),bbox:it.bbox},value:{label:gt.label.attr("class","label usecase-json-value"),bbox:gt.bbox}})}let y=Math.max(0,...u.map(({key:rt})=>rt.bbox.width))+Gf*2,x=Math.max(0,...u.map(({value:rt})=>rt.bbox.width))+Gf*2,k=l.width+Gf*2,w=Math.max(k,y+x),_=x+Math.max(0,w-y-x),M=l.height+Wy*2,q=u.map(({key:rt,value:it})=>Math.max(rt.bbox.height,it.bbox.height)+Wy*2),Y=M+q.reduce((rt,it)=>rt+it,0),V=CS(n.get("stroke-width")),Q=w+V*2,tt=Y+V*2,at=-w/2,ot=-Y/2,ht=e.look==="handDrawn"?v.svg(c):void 0,yt=ht?Kt(e,{}):void 0,Bt=t((rt,it,gt,et,wt,vt)=>{if(ht&&yt){let Xt=ht.rectangle(gt,et,wt,vt,yt);return rt.insert(()=>Xt,":first-child").attr("class",it)}return rt.insert("rect",":first-child").attr("class",it).attr("x",gt).attr("y",et).attr("width",wt).attr("height",vt).attr("style",s)},"insertCell"),kt=Bt(c,"label-container usecase-json-border",-Q/2,-tt/2,Q,tt);Bt(m,"usecase-json-cell usecase-json-title-cell",at,ot,w,M),m.node()?.append(p.node()),Xf(p,l,0,ot+M/2);let Ct=ot+M;return u.forEach(({key:rt,value:it},gt)=>{let et=q[gt],wt=m.append("g").attr("class","usecase-json-row").attr("data-row-index",gt).attr("transform",`translate(0,${Ct})`);Bt(wt,"usecase-json-cell usecase-json-key-cell",at,0,y,et),Bt(wt,"usecase-json-cell usecase-json-value-cell",at+y,0,_,et),wt.node()?.append(rt.label.node(),it.label.node()),Xf(rt.label,rt.bbox,at+y/2,et/2),Xf(it.label,it.bbox,at+y+_/2,et/2),Ct+=et}),B(e,kt),e.intersect=(rt)=>T.rect(e,rt),c}t(Gx,"usecaseJsonTable");async function Xx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=e.look==="neo"?10:5;if(e.width||e.height)e.width=Math.max((e?.width??0)-n*2-2*l,10),e.height=Math.max((e?.height??0)-c*2-2*l,10);let{shapeSvg:p,bbox:m,label:u}=await U(r,e,te(e)),y=(e?.width?e?.width:m.width)+n*2+2*l,x=(e?.height?e?.height:m.height)+c*2+2*l,k=y-2*l,w=x-2*l,_=-k/2,M=-w/2,{cssStyles:q}=e,Y=v.svg(p),V=Kt(e,{}),Q=[{x:_-l,y:M+l},{x:_-l,y:M+w+l},{x:_+k-l,y:M+w+l},{x:_+k-l,y:M+w},{x:_+k,y:M+w},{x:_+k,y:M+w-l},{x:_+k+l,y:M+w-l},{x:_+k+l,y:M-l},{x:_+l,y:M-l},{x:_+l,y:M},{x:_,y:M},{x:_,y:M+l}],tt=[{x:_,y:M+l},{x:_+k-l,y:M+l},{x:_+k-l,y:M+w},{x:_+k,y:M+w},{x:_+k,y:M},{x:_,y:M}];if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let at=ye(Q),ot=Y.path(at,V),ht=ye(tt),yt=Y.path(ht,V);if(e.look!=="handDrawn")ot=Kf(ot),yt=Kf(yt);let Bt=p.insert("g",":first-child");if(Bt.insert(()=>ot),Bt.insert(()=>yt),Bt.attr("class","basic label-container outer-path"),q&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",q);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return u.attr("transform",`translate(${-(m.width/2)-l-(m.x-(m.left??0))}, ${-(m.height/2)+l-(m.y-(m.top??0))})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,Q,kt)},p}t(Xx,"multiRect");async function Vx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=e.padding??0,p=e.look==="neo"?16:l,m=e.look==="neo"?12:l,u=!0;if(e.width||e.height)u=!1,e.width=(e?.width??0)-p*2,e.height=(e?.height??0)-m*3;let y=Math.max(n.width,e?.width??0)+p*2,x=Math.max(n.height,e?.height??0)+m*3,k=e.look==="neo"?x/4:x/8,w=x+(u?k/2:-k/2),_=-y/2,M=-w/2,q=10,{cssStyles:Y}=e,V=Ji(_-q,M+w+q,_+y-q,M+w+q,k,0.8),Q=V?.[V.length-1],tt=[{x:_-q,y:M+q},{x:_-q,y:M+w+q},...V,{x:_+y-q,y:Q.y-q},{x:_+y,y:Q.y-q},{x:_+y,y:Q.y-2*q},{x:_+y+q,y:Q.y-2*q},{x:_+y+q,y:M-q},{x:_+q,y:M-q},{x:_+q,y:M},{x:_,y:M},{x:_,y:M+q}],at=[{x:_,y:M+q},{x:_+y-q,y:M+q},{x:_+y-q,y:Q.y-q},{x:_+y,y:Q.y-q},{x:_+y,y:M},{x:_,y:M}],ot=v.svg(s),ht=Kt(e,{});if(e.look!=="handDrawn")ht.roughness=0,ht.fillStyle="solid";let yt=ye(tt),Bt=ot.path(yt,ht),kt=ye(at),Ct=ot.path(kt,ht),rt=s.insert(()=>Bt,":first-child");if(rt.insert(()=>Ct),rt.attr("class","basic label-container outer-path"),Y&&e.look!=="handDrawn")rt.selectAll("path").attr("style",Y);if(a&&e.look!=="handDrawn")rt.selectAll("path").attr("style",a);return rt.attr("transform",`translate(0,${-k/2})`),c.attr("transform",`translate(${-(n.width/2)-q-(n.x-(n.left??0))}, ${-(n.height/2)+q-k-(n.y-(n.top??0))})`),B(e,rt),e.intersect=function(it){return T.polygon(e,tt,it)},s}t(Vx,"multiWaveEdgedRectangle");async function Kx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);if(e.labelStyle=a,!(e.useHtmlLabels||Xe(A())))e.centerLabel=!0;let{shapeSvg:c,bbox:l,label:p}=await U(r,e,te(e)),m=Math.max(l.width+(e.padding??0)*2,e?.width??0),u=Math.max(l.height+(e.padding??0)*2,e?.height??0),y=-m/2,x=-u/2,{cssStyles:k}=e,w=v.svg(c),_=Kt(e,{fill:o.noteBkgColor,stroke:o.noteBorderColor});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=w.rectangle(y,x,m,u,_),q=c.insert(()=>M,":first-child");if(q.attr("class","basic label-container outer-path"),p.attr("class","label noteLabel"),k&&e.look!=="handDrawn")q.selectAll("path").attr("style",k);if(s&&e.look!=="handDrawn")q.selectAll("path").attr("style",s);return p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),B(e,q),e.intersect=function(Y){return T.rect(e,Y)},c}t(Kx,"note");var bS=t((r,e,o)=>[`M${r+o/2},${e}`,`L${r+o},${e-o/2}`,`L${r+o/2},${e-o}`,`L${r},${e-o/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function Zx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n}=await U(r,e,te(e)),c=n.width+(e.padding??0),l=n.height+(e.padding??0),p=c+l,m=0.5,u=[{x:p/2,y:0},{x:p,y:-p/2},{x:p/2,y:-p},{x:0,y:-p/2}],y,{cssStyles:x}=e;if(e.look==="handDrawn"){let k=v.svg(s),w=Kt(e,{}),_=bS(0,0,p),M=k.path(_,w);if(y=s.insert(()=>M,":first-child").attr("transform",`translate(${-p/2+m}, ${p/2})`),x)y.attr("style",x)}else y=fi(s,p,p,u),y.attr("transform",`translate(${-p/2+m}, ${p/2})`);if(a)y.attr("style",a);return B(e,y),e.calcIntersect=function(k,w){let _=k.width,M=[{x:_/2,y:0},{x:_,y:-_/2},{x:_/2,y:-_},{x:0,y:-_/2}];return T.polygon(k,M,w)},e.intersect=function(k){return this.calcIntersect(e,k)},s}t(Zx,"question");async function Qx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?21:s??0,c=e.look==="neo"?12:s??0,{shapeSvg:l,bbox:p,label:m}=await U(r,e,te(e)),u=p.width+(e.look==="neo"?n*2:n),y=Math.max(p.height+(e.look==="neo"?c*2:c),e.height??0),x=y/4,w=-Math.max(u,(e.width??0)-x)/2,_=-y/2,M=_/2,q=[{x:w+M,y:_},{x:w,y:0},{x:w+M,y:-_},{x:-w,y:-_},{x:-w,y:_}],{cssStyles:Y}=e,V=v.svg(l),Q=Kt(e,{});if(e.look!=="handDrawn")Q.roughness=0,Q.fillStyle="solid";let tt=ye(q),at=V.path(tt,Q),ot=l.insert(()=>at,":first-child");if(ot.attr("class","basic label-container outer-path"),Y&&e.look!=="handDrawn")ot.selectAll("path").attr("style",Y);if(a&&e.look!=="handDrawn")ot.selectAll("path").attr("style",a);return ot.attr("transform",`translate(${-M/2},0)`),m.attr("transform",`translate(${-M/2-p.width/2-(p.x-(p.left??0))}, ${-(p.height/2)-(p.y-(p.top??0))})`),B(e,ot),e.intersect=function(ht){return T.polygon(e,q,ht)},l}t(Qx,"rect_left_inv_arrow");async function Jx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s;if(!e.cssClasses)s="node default";else s="node "+e.cssClasses;let n=r.insert("g").attr("class",s).attr("id",e.domId||e.id),c=n.insert("g"),l=n.insert("g").attr("class","label").attr("style",a),{description:p,label:m}=e,u=await Gr(l,m,e.labelStyle,!0,!0),y={width:0,height:0};if(Xe(d())){let ht=u.children[0],yt=g(u);y=ht.getBoundingClientRect(),yt.attr("width",y.width),yt.attr("height",y.height)}i.info("Text 2",p);let x=p||[],k=u.getBBox(),w=await Gr(l,Array.isArray(x)?x.join("<br/>"):x,e.labelStyle,!0,!0),_=w.children[0],M=g(w);y=_.getBoundingClientRect(),M.attr("width",y.width),M.attr("height",y.height);let q=(e.padding||0)/2;g(w).attr("transform","translate( "+(y.width>k.width?0:(k.width-y.width)/2)+", "+(k.height+q+5)+")"),g(u).attr("transform","translate( "+(y.width<k.width?0:-(k.width-y.width)/2)+", 0)"),y=l.node().getBBox(),l.attr("transform","translate("+-y.width/2+", "+(-y.height/2-q+3)+")");let Y=y.width+(e.padding||0),V=y.height+(e.padding||0),Q=-y.width/2-q,tt=-y.height/2-q,at,ot;if(e.look==="handDrawn"){let ht=v.svg(n),yt=Kt(e,{}),Bt=ht.path(Tr(Q,tt,Y,V,e.rx||0),yt),kt=ht.line(-y.width/2-q,-y.height/2-q+k.height+q,y.width/2+q,-y.height/2-q+k.height+q,yt);ot=n.insert(()=>(i.debug("Rough node insert CXC",Bt),kt),":first-child"),at=n.insert(()=>(i.debug("Rough node insert CXC",Bt),Bt),":first-child")}else at=c.insert("rect",":first-child"),ot=c.insert("line"),at.attr("class","outer title-state").attr("style",a).attr("x",-y.width/2-q).attr("y",-y.height/2-q).attr("width",y.width+(e.padding||0)).attr("height",y.height+(e.padding||0)),ot.attr("class","divider").attr("x1",-y.width/2-q).attr("x2",y.width/2+q).attr("y1",-y.height/2-q+k.height+q).attr("y2",-y.height/2-q+k.height+q);return B(e,at),e.intersect=function(ht){return T.rect(e,ht)},n}t(Jx,"rectWithTitle");async function t0(r,e,{config:{themeVariables:o}}){let a=o?.radius??5,s={rx:a,ry:a,classes:"",labelPaddingX:(e?.padding??0)*1,labelPaddingY:(e?.padding??0)*1};return Ss(r,e,s)}t(t0,"roundedRect");var co=8;async function e0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.look==="neo"?16:e.padding??0,n=e.look==="neo"?12:e.padding??0,{shapeSvg:c,bbox:l,label:p}=await U(r,e,te(e)),m=(e?.width??l.width)+s*2+(e.look==="neo"?co:co*2),u=(e?.height??l.height)+n*2,y=m-co,x=u,k=co-m/2,w=-u/2,{cssStyles:_}=e,M=v.svg(c),q=Kt(e,{});if(e.look!=="handDrawn")q.roughness=0,q.fillStyle="solid";let Y=[{x:k,y:w},{x:k+y,y:w},{x:k+y,y:w+x},{x:k-co,y:w+x},{x:k-co,y:w},{x:k,y:w},{x:k,y:w+x}],V=M.polygon(Y.map((tt)=>[tt.x,tt.y]),q),Q=c.insert(()=>V,":first-child");if(Q.attr("class","basic label-container outer-path").attr("style",Me(_)),a&&e.look!=="handDrawn")Q.selectAll("path").attr("style",a);if(_&&e.look!=="handDrawn")Q.selectAll("path").attr("style",a);return p.attr("transform",`translate(${co/2-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),B(e,Q),e.intersect=function(tt){return T.rect(e,tt)},c}t(e0,"shadedProcess");async function r0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height)e.width=Math.max((e?.width??0)-n*2,10),e.height=Math.max((e?.height??0)/1.5-c*2,10);let{shapeSvg:l,bbox:p,label:m}=await U(r,e,te(e)),u=(e?.width?e?.width:p.width)+n*2,y=((e?.height?e?.height:p.height)+c*2)*1.5,x=u,k=y/1.5,w=-x/2,_=-k/2,{cssStyles:M}=e,q=v.svg(l),Y=Kt(e,{});if(e.look!=="handDrawn")Y.roughness=0,Y.fillStyle="solid";let V=[{x:w,y:_},{x:w,y:_+k},{x:w+x,y:_+k},{x:w+x,y:_-k/2}],Q=ye(V),tt=q.path(Q,Y),at=l.insert(()=>tt,":first-child");if(at.attr("class","basic label-container outer-path"),M&&e.look!=="handDrawn")at.selectChildren("path").attr("style",M);if(a&&e.look!=="handDrawn")at.selectChildren("path").attr("style",a);return at.attr("transform",`translate(0, ${k/4})`),m.attr("transform",`translate(${-x/2+(e.padding??0)-(p.x-(p.left??0))}, ${-k/4+(e.padding??0)-(p.y-(p.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,V,ot)},l}t(r0,"slopedRect");async function i0(r,e){let o=e.padding??0,a=e.look==="neo"?16:o*2,s=e.look==="neo"?12:o,n={rx:0,ry:0,classes:"",labelPaddingX:e.labelPaddingX??a,labelPaddingY:s},c=await Ss(r,e,n);if(e.colorIndex!==void 0){let{theme:l,themeVariables:p}=d();It(c,e.colorIndex,l,p.borderColorArray)}return c}t(i0,"squareRect");var Jf=50,kS=t((r,e,o)=>{let a=r.height+o,s=a*Math.cos(Math.PI/(2*(Jf-1))),n=Math.sqrt(Math.max(0,s**2-r.height**2));return{w:Math.max(r.width+a/4+e,1.5*a+(a-s),r.width+e+a-n),h:a}},"stadiumDimensions");async function o0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?40:s,c=e.look==="neo"?24:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),{w:m,h:u}=kS(p,n,c),y=u/2,{cssStyles:x}=e,k=v.svg(l),w=Kt(e,{});if(e.look!=="handDrawn")w.roughness=0,w.fillStyle="solid";let _=[{x:-m/2+y,y:-u/2},{x:m/2-y,y:-u/2},...ci(-m/2+y,0,y,Jf,90,270),{x:m/2-y,y:u/2},...ci(m/2-y,0,y,Jf,270,450)],M=ye(_),q=k.path(M,w),Y=l.insert(()=>q,":first-child");if(Y.attr("class","basic label-container outer-path"),x&&e.look!=="handDrawn")Y.selectChildren("path").attr("style",x);if(a&&e.look!=="handDrawn")Y.selectChildren("path").attr("style",a);return B(e,Y),e.intersect=function(V){return T.polygon(e,_,V)},l}t(o0,"stadium");async function s0(r,e){let o={rx:e.look==="neo"?3:5,ry:e.look==="neo"?3:5,classes:"flowchart-node"};return Ss(r,e,o)}t(s0,"state");function a0(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{cssStyles:n}=e,{lineColor:c,stateBorder:l,nodeBorder:p,nodeShadow:m}=o;if(e.width||e.height){if((e.width??0)<14)e.width=14;if((e.height??0)<14)e.height=14}if(!e.width)e.width=14;if(!e.height)e.height=14;let u=r.insert("g").attr("class","node default").attr("id",e.domId??e.id),y=v.svg(u),x=Kt(e,{});if(e.look!=="handDrawn")x.roughness=0,x.fillStyle="solid";let k=y.circle(0,0,e.width,{...x,stroke:c,strokeWidth:2}),w=l??p,_=(e.width??0)*5/14,M=y.circle(0,0,_,{...x,fill:w,stroke:w,strokeWidth:2,fillStyle:"solid"}),q=u.insert(()=>k,":first-child");if(q.insert(()=>M),e.look!=="handDrawn")q.attr("class","outer-path");if(n)q.selectAll("path").attr("style",n);if(s)q.selectAll("path").attr("style",s);if(e.width<25&&m&&e.look!=="handDrawn"){let Y=r.node()?.ownerSVGElement?.id??"",V=Y?`${Y}-drop-shadow-small`:"drop-shadow-small";q.attr("style",`filter:url(#${V})`)}return B(e,q),e.intersect=function(Y){return T.circle(e,(e.width??0)/2,Y)},u}t(a0,"stateEnd");function n0(r,e,{config:{themeVariables:o}}){let{lineColor:a,nodeShadow:s}=o;if(e.width||e.height){if((e.width??0)<14)e.width=14;if((e.height??0)<14)e.height=14}if(!e.width)e.width=14;if(!e.height)e.height=14;let n=r.insert("g").attr("class","node default").attr("id",e.domId||e.id),c;if(e.look==="handDrawn"){let p=v.svg(n).circle(0,0,e.width,Gg(a));c=n.insert(()=>p),c.attr("class","state-start").attr("r",(e.width??7)/2).attr("width",e.width??14).attr("height",e.height??14)}else c=n.insert("circle",":first-child"),c.attr("class","state-start").attr("r",(e.width??7)/2).attr("width",e.width??14).attr("height",e.height??14);if(e.width<25&&s&&e.look!=="handDrawn"){let l=r.node()?.ownerSVGElement?.id??"",p=l?`${l}-drop-shadow-small`:"drop-shadow-small";c.attr("style",`filter:url(#${p})`)}return B(e,c),e.intersect=function(l){return T.circle(e,(e.width??7)/2,l)},n}t(n0,"stateStart");var bs=8;async function l0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e?.padding??8,n=e.look==="neo"?28:s,c=e.look==="neo"?12:s,{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=Math.max(p.width+2*bs+n,e.width??0),u=Math.max(p.height+c,e.height??0),y=m-2*bs,x=u,k=-m/2,w=-u/2,_=[{x:0,y:0},{x:y,y:0},{x:y,y:-x},{x:0,y:-x},{x:0,y:0},{x:-8,y:0},{x:y+8,y:0},{x:y+8,y:-x},{x:-8,y:-x},{x:-8,y:0}];if(e.look==="handDrawn"){let M=v.svg(l),q=Kt(e,{}),Y=M.rectangle(k,w,y+16,x,q),V=M.line(k+bs,w,k+bs,w+x,q),Q=M.line(k+bs+y,w,k+bs+y,w+x,q);l.insert(()=>V,":first-child"),l.insert(()=>Q,":first-child");let tt=l.insert(()=>Y,":first-child"),{cssStyles:at}=e;tt.attr("class","basic label-container").attr("style",Me(at)),B(e,tt)}else{let M=fi(l,y,x,_);if(a)M.attr("style",a);B(e,M)}return e.intersect=function(M){return T.polygon(e,_,M)},l}t(l0,"subroutine");var Vf=0.2;async function h0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height)e.height=Math.max((e?.height??0)-c*2,10),e.width=Math.max((e?.width??0)-n*2-Vf*(e.height+c*2),10);let{shapeSvg:l,bbox:p}=await U(r,e,te(e)),m=(e?.height?e?.height:p.height)+c*2,u=Vf*m,y=Vf*m,k=(e?.width?e?.width:p.width)+n*2+u-u,w=m,_=-k/2,M=-w/2,{cssStyles:q}=e,Y=v.svg(l),V=Kt(e,{}),Q=[{x:_-u/2,y:M},{x:_+k+u/2,y:M},{x:_+k+u/2,y:M+w},{x:_-u/2,y:M+w}],tt=[{x:_+k-u/2,y:M+w},{x:_+k+u/2,y:M+w},{x:_+k+u/2,y:M+w-y}];if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let at=ye(Q),ot=Y.path(at,V),ht=ye(tt),yt=Y.path(ht,{...V,fillStyle:"solid"}),Bt=l.insert(()=>yt,":first-child");if(Bt.insert(()=>ot,":first-child"),Bt.attr("class","basic label-container outer-path"),q&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",q);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return B(e,Bt),e.intersect=function(kt){return T.polygon(e,Q,kt)},l}t(h0,"taggedRect");async function c0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await U(r,e,te(e)),l=Math.max(n.width+(e.padding??0)*2,e?.width??0),p=Math.max(n.height+(e.padding??0)*2,e?.height??0),m=p/8,u=0.2*l,y=0.2*p,x=p+m,{cssStyles:k}=e,w=v.svg(s),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=[{x:-l/2-l/2*0.1,y:x/2},...Ji(-l/2-l/2*0.1,x/2,l/2+l/2*0.1,x/2,m,0.8),{x:l/2+l/2*0.1,y:-x/2},{x:-l/2-l/2*0.1,y:-x/2}],q=-l/2+l/2*0.1,Y=-x/2-y*0.4,V=[{x:q+l-u,y:(Y+p)*1.3},{x:q+l,y:Y+p-y},{x:q+l,y:(Y+p)*0.9},...Ji(q+l,(Y+p)*1.25,q+l-u,(Y+p)*1.3,-p*0.02,0.5)],Q=ye(M),tt=w.path(Q,_),at=ye(V),ot=w.path(at,{..._,fillStyle:"solid"}),ht=s.insert(()=>ot,":first-child");if(ht.insert(()=>tt,":first-child"),ht.attr("class","basic label-container outer-path"),k&&e.look!=="handDrawn")ht.selectAll("path").attr("style",k);if(a&&e.look!=="handDrawn")ht.selectAll("path").attr("style",a);return ht.attr("transform",`translate(0,${-m/2})`),c.attr("transform",`translate(${-l/2+(e.padding??0)-(n.x-(n.left??0))},${-p/2+(e.padding??0)-m/2-(n.y-(n.top??0))})`),B(e,ht),e.intersect=function(yt){return T.polygon(e,M,yt)},s}t(c0,"taggedWaveEdgedRectangle");async function u0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n}=await U(r,e,te(e)),c=Math.max(n.width+(e.padding??0),e?.width||0),l=Math.max(n.height+(e.padding??0),e?.height||0),p=-c/2,m=-l/2,u=s.insert("rect",":first-child");return u.attr("class","text").attr("style",a).attr("rx",0).attr("ry",0).attr("x",p).attr("y",m).attr("width",c).attr("height",l),B(e,u),e.intersect=function(y){return T.rect(e,y)},s}t(u0,"text");var wS=t((r,e,o,a,s,n)=>`M${r},${e}
|
|
232
|
+
`),n):q(e.label,n),u=e.isNode?"nodeLabel":"edgeLabel",y=p.append("span");if(y.html(m),Mf(y,e.labelStyle),y.attr("class",`${u} ${a}`),Mf(p,e.labelStyle),p.style("display","table-cell"),p.style("white-space","nowrap"),p.style("line-height","1.5"),o!==Number.POSITIVE_INFINITY)p.style("max-width",o+"px"),p.style("text-align","center");if(p.attr("xmlns","http://www.w3.org/1999/xhtml"),s)p.attr("class","labelBkg");let x=await Bi.measure(()=>p.node().getBoundingClientRect());if(x.width===o)p.style("display","table"),p.style("white-space","break-spaces"),p.style("width",o+"px");else if(x.width<c)p.style("display","table"),p.style("width",c+"px"),p.style("text-align","center");return l.node()}t(Qm,"addHtmlSpan");function Ll(r,e,o,a=!1){let s=r.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*o-0.1+"em").attr("dy",o+"em");if(a)s.attr("text-anchor","middle");return s}t(Ll,"createTspan");function Jm(r,e,o){let a=r.append("text"),s=Ll(a,1,e);Fl(s,o);let n=s.node().getComputedTextLength();return a.remove(),n}t(Jm,"computeWidthOfText");function ec(r,e,o){let a=r.append("text"),s=Ll(a,1,e);Fl(s,[{content:o,type:"normal"}]);let n=s.node()?.getBoundingClientRect();if(n)a.remove();return n}t(ec,"computeDimensionOfText");function ty(r,e,o,a=!1,s=!1){let c=e.append("g"),l=c.insert("rect").attr("class","background").attr("style","stroke: none"),p=c.append("text").attr("y","-10.1");if(s)p.attr("text-anchor","middle");let m=0;for(let u of o){let y=t((k)=>Jm(c,1.1,k)<=r,"checkWidth"),x=y(u)?[u]:Zm(u,y);for(let k of x){let w=Ll(p,m,1.1,s);Fl(w,k),m++}}if(a){let u=p.node().getBBox(),y=2;return l.attr("x",u.x-2).attr("y",u.y-2).attr("width",u.width+4).attr("height",u.height+4),c.node()}else return p.node()}t(ty,"createFormattedText");function Ef(r){let e=/&(amp|lt|gt);/g;return r.replace(e,(o,a)=>{switch(a){case"amp":return"&";case"lt":return"<";case"gt":return">";default:return o}})}t(Ef,"decodeHTMLEntities");function Fl(r,e){r.text(""),e.forEach((o,a)=>{let s=r.append("tspan").attr("font-style",o.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",o.type==="strong"?"bold":"normal");if(a===0)s.text(Ef(o.content));else s.text(" "+Ef(o.content))})}t(Fl,"updateTextContentAndStyles");async function ey(r,e={}){let o=[];r.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(s,n,c)=>(o.push((async()=>{let l=`${n}:${c}`;if(await gl(l))return await Gt(l,void 0,{class:"label-icon"});else return`<i class='${q(s,e).replace(":"," ")}'></i>`})()),s));let a=await Promise.all(o);return r.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>a.shift()??"")}t(ey,"replaceIconSubstring");var ct=t(async(r,e="",{style:o="",isTitle:a=!1,classes:s="",useHtmlLabels:n=!0,markdown:c=!0,isNode:l=!0,width:p=200,minWidth:m=0,addSvgBackground:u=!1}={},y)=>{if(i.debug("XYZ createText",e,o,a,s,n,l,"addSvgBackground: ",u),n){let x=c?Gm(e,y):jm(e),k=await ey(Fn(x),y),w=e.replace(/\\\\/g,"\\"),_={isNode:l,label:$e(e)?w:k,labelStyle:o.replace("fill:","color:")};return await Qm(r,_,p,s,u,y,m)}else{let x=Fn(e.replace(/<br\s*\/?>/g,"<br/>")),k=c?Zo(x.replace("<br>","<br/>"),y):Um(x),w=ty(p,r,k,e?u:!1,!l);if(l){if(/stroke:/.exec(o))o=o.replace("stroke:","lineColor:");let _=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");g(w).attr("style",_)}else{let _=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");g(w).select("rect").attr("style",_.replace(/background:/g,"fill:"));let M=o.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");g(w).select("text").attr("style",M)}if(a)g(w).selectAll("tspan.text-outer-tspan").classed("title-row",!0);else g(w).selectAll("tspan.text-outer-tspan").classed("row",!0);return w}},"createText");var Oi=new Set(["redux-color","redux-dark-color"]),Lw=12,Fw=64,De=t((r)=>Array.isArray(r)&&r.length>0,"hasPalette"),Ne=t((r,e)=>r!=null&&Oi.has(r)&&De(e),"isColorTheme"),Aw=/^[\w-]+$/,Me=t((r)=>{let e=typeof r==="string"||typeof r==="number"?String(r):"";return Aw.test(e)?e:"classic"},"safeLook"),un=t((r)=>De(r)?r.length:0,"paletteSlotCount"),Rt=t((r,e)=>{if(De(e))return un(e);return typeof r==="number"&&Number.isInteger(r)&&r>0&&r<=Fw?r:Lw},"colorSlotCount"),It=t((r,e,o,a)=>{if(e===void 0||!Ne(o,a))return;let s=e%un(a);r.attr("data-color-id",`color-${s}`)},"stampColorSlot");function If(r,e,o){if(r&&r.length){let[a,s]=e,n=Math.PI/180*o,c=Math.cos(n),l=Math.sin(n);for(let p of r){let[m,u]=p;p[0]=(m-a)*c-(u-s)*l+a,p[1]=(m-a)*l+(u-s)*c+s}}}function Mw(r,e){return r[0]===e[0]&&r[1]===e[1]}function Ew(r,e,o,a=1){let s=o,n=Math.max(e,0.1),c=r[0]&&r[0][0]&&typeof r[0][0]=="number"?[r]:r,l=[0,0];if(s)for(let m of c)If(m,l,s);let p=function(m,u,y){let x=[];for(let U of m){let V=[...U];Mw(V[0],V[V.length-1])||V.push([V[0][0],V[0][1]]),V.length>2&&x.push(V)}let k=[];u=Math.max(u,0.1);let w=[];for(let U of x)for(let V=0;V<U.length-1;V++){let Z=U[V],tt=U[V+1];if(Z[1]!==tt[1]){let at=Math.min(Z[1],tt[1]);w.push({ymin:at,ymax:Math.max(Z[1],tt[1]),x:at===Z[1]?Z[0]:tt[0],islope:(tt[0]-Z[0])/(tt[1]-Z[1])})}}if(w.sort((U,V)=>U.ymin<V.ymin?-1:U.ymin>V.ymin?1:U.x<V.x?-1:U.x>V.x?1:U.ymax===V.ymax?0:(U.ymax-V.ymax)/Math.abs(U.ymax-V.ymax)),!w.length)return k;let _=[],M=w[0].ymin,W=0;for(;_.length||w.length;){if(w.length){let U=-1;for(let V=0;V<w.length&&!(w[V].ymin>M);V++)U=V;w.splice(0,U+1).forEach((V)=>{_.push({s:M,edge:V})})}if(_=_.filter((U)=>!(U.edge.ymax<=M)),_.sort((U,V)=>U.edge.x===V.edge.x?0:(U.edge.x-V.edge.x)/Math.abs(U.edge.x-V.edge.x)),(y!==1||W%u==0)&&_.length>1)for(let U=0;U<_.length;U+=2){let V=U+1;if(V>=_.length)break;let Z=_[U].edge,tt=_[V].edge;k.push([[Math.round(Z.x),M],[Math.round(tt.x),M]])}M+=y,_.forEach((U)=>{U.edge.x=U.edge.x+y*U.edge.islope}),W++}return k}(c,n,a);if(s){for(let m of c)If(m,l,-s);(function(m,u,y){let x=[];m.forEach((k)=>x.push(...k)),If(x,u,y)})(p,l,-s)}return p}function tn(r,e){var o;let a=e.hachureAngle+90,s=e.hachureGap;s<0&&(s=4*e.strokeWidth),s=Math.round(Math.max(s,0.1));let n=1;return e.roughness>=1&&(((o=e.randomizer)===null||o===void 0?void 0:o.next())||Math.random())>0.7&&(n=s),Ew(r,s,a,n||1)}class Rl{constructor(r){this.helper=r}fillPolygons(r,e){return this._fillPolygons(r,e)}_fillPolygons(r,e){let o=tn(r,e);return{type:"fillSketch",ops:this.renderLines(o,e)}}renderLines(r,e){let o=[];for(let a of r)o.push(...this.helper.doubleLineOps(a[0][0],a[0][1],a[1][0],a[1][1],e));return o}}function ql(r){let e=r[0],o=r[1];return Math.sqrt(Math.pow(e[0]-o[0],2)+Math.pow(e[1]-o[1],2))}class cy extends Rl{fillPolygons(r,e){let o=e.hachureGap;o<0&&(o=4*e.strokeWidth),o=Math.max(o,0.1);let a=tn(r,Object.assign({},e,{hachureGap:o})),s=Math.PI/180*e.hachureAngle,n=[],c=0.5*o*Math.cos(s),l=0.5*o*Math.sin(s);for(let[p,m]of a)ql([p,m])&&n.push([[p[0]-c,p[1]+l],[...m]],[[p[0]+c,p[1]-l],[...m]]);return{type:"fillSketch",ops:this.renderLines(n,e)}}}class uy extends Rl{fillPolygons(r,e){let o=this._fillPolygons(r,e),a=Object.assign({},e,{hachureAngle:e.hachureAngle+90}),s=this._fillPolygons(r,a);return o.ops=o.ops.concat(s.ops),o}}class fy{constructor(r){this.helper=r}fillPolygons(r,e){let o=tn(r,e=Object.assign({},e,{hachureAngle:0}));return this.dotsOnLines(o,e)}dotsOnLines(r,e){let o=[],a=e.hachureGap;a<0&&(a=4*e.strokeWidth),a=Math.max(a,0.1);let s=e.fillWeight;s<0&&(s=e.strokeWidth/2);let n=a/4;for(let c of r){let l=ql(c),p=l/a,m=Math.ceil(p)-1,u=l-m*a,y=(c[0][0]+c[1][0])/2-a/4,x=Math.min(c[0][1],c[1][1]);for(let k=0;k<m;k++){let w=x+u+k*a,_=y-n+2*Math.random()*n,M=w-n+2*Math.random()*n,W=this.helper.ellipse(_,M,s,s,e);o.push(...W.ops)}}return{type:"fillSketch",ops:o}}}class dy{constructor(r){this.helper=r}fillPolygons(r,e){let o=tn(r,e);return{type:"fillSketch",ops:this.dashedLine(o,e)}}dashedLine(r,e){let o=e.dashOffset<0?e.hachureGap<0?4*e.strokeWidth:e.hachureGap:e.dashOffset,a=e.dashGap<0?e.hachureGap<0?4*e.strokeWidth:e.hachureGap:e.dashGap,s=[];return r.forEach((n)=>{let c=ql(n),l=Math.floor(c/(o+a)),p=(c+a-l*(o+a))/2,m=n[0],u=n[1];m[0]>u[0]&&(m=n[1],u=n[0]);let y=Math.atan((u[1]-m[1])/(u[0]-m[0]));for(let x=0;x<l;x++){let k=x*(o+a),w=k+o,_=[m[0]+k*Math.cos(y)+p*Math.cos(y),m[1]+k*Math.sin(y)+p*Math.sin(y)],M=[m[0]+w*Math.cos(y)+p*Math.cos(y),m[1]+w*Math.sin(y)+p*Math.sin(y)];s.push(...this.helper.doubleLineOps(_[0],_[1],M[0],M[1],e))}}),s}}class py{constructor(r){this.helper=r}fillPolygons(r,e){let o=e.hachureGap<0?4*e.strokeWidth:e.hachureGap,a=e.zigzagOffset<0?o:e.zigzagOffset,s=tn(r,e=Object.assign({},e,{hachureGap:o+a}));return{type:"fillSketch",ops:this.zigzagLines(s,a,e)}}zigzagLines(r,e,o){let a=[];return r.forEach((s)=>{let n=ql(s),c=Math.round(n/(2*e)),l=s[0],p=s[1];l[0]>p[0]&&(l=s[1],p=s[0]);let m=Math.atan((p[1]-l[1])/(p[0]-l[0]));for(let u=0;u<c;u++){let y=2*u*e,x=2*(u+1)*e,k=Math.sqrt(2*Math.pow(e,2)),w=[l[0]+y*Math.cos(m),l[1]+y*Math.sin(m)],_=[l[0]+x*Math.cos(m),l[1]+x*Math.sin(m)],M=[w[0]+k*Math.cos(m+Math.PI/4),w[1]+k*Math.sin(m+Math.PI/4)];a.push(...this.helper.doubleLineOps(w[0],w[1],M[0],M[1],o),...this.helper.doubleLineOps(M[0],M[1],_[0],_[1],o))}}),a}}var Sr={};class gy{constructor(r){this.seed=r}next(){return this.seed?(2147483647&(this.seed=Math.imul(48271,this.seed)))/2147483648:Math.random()}}var Ow=0,$f=1,ry=2,Al={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Df(r,e){return r.type===e}function zf(r){let e=[],o=function(c){let l=[];for(;c!=="";)if(c.match(/^([ \t\r\n,]+)/))c=c.substr(RegExp.$1.length);else if(c.match(/^([aAcChHlLmMqQsStTvVzZ])/))l[l.length]={type:Ow,text:RegExp.$1},c=c.substr(RegExp.$1.length);else{if(!c.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];l[l.length]={type:$f,text:`${parseFloat(RegExp.$1)}`},c=c.substr(RegExp.$1.length)}return l[l.length]={type:ry,text:""},l}(r),a="BOD",s=0,n=o[s];for(;!Df(n,ry);){let c=0,l=[];if(a==="BOD"){if(n.text!=="M"&&n.text!=="m")return zf("M0,0"+r);s++,c=Al[n.text],a=n.text}else Df(n,$f)?c=Al[a]:(s++,c=Al[n.text],a=n.text);if(!(s+c<o.length))throw Error("Path data ended short");for(let p=s;p<s+c;p++){let m=o[p];if(!Df(m,$f))throw Error("Param not a number: "+a+","+m.text);l[l.length]=+m.text}if(typeof Al[a]!="number")throw Error("Bad segment: "+a);{let p={key:a,data:l};e.push(p),s+=c,n=o[s],a==="M"&&(a="L"),a==="m"&&(a="l")}}return e}function my(r){let e=0,o=0,a=0,s=0,n=[];for(let{key:c,data:l}of r)switch(c){case"M":n.push({key:"M",data:[...l]}),[e,o]=l,[a,s]=l;break;case"m":e+=l[0],o+=l[1],n.push({key:"M",data:[e,o]}),a=e,s=o;break;case"L":n.push({key:"L",data:[...l]}),[e,o]=l;break;case"l":e+=l[0],o+=l[1],n.push({key:"L",data:[e,o]});break;case"C":n.push({key:"C",data:[...l]}),e=l[4],o=l[5];break;case"c":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"C",data:p}),e=p[4],o=p[5];break}case"Q":n.push({key:"Q",data:[...l]}),e=l[2],o=l[3];break;case"q":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"Q",data:p}),e=p[2],o=p[3];break}case"A":n.push({key:"A",data:[...l]}),e=l[5],o=l[6];break;case"a":e+=l[5],o+=l[6],n.push({key:"A",data:[l[0],l[1],l[2],l[3],l[4],e,o]});break;case"H":n.push({key:"H",data:[...l]}),e=l[0];break;case"h":e+=l[0],n.push({key:"H",data:[e]});break;case"V":n.push({key:"V",data:[...l]}),o=l[0];break;case"v":o+=l[0],n.push({key:"V",data:[o]});break;case"S":n.push({key:"S",data:[...l]}),e=l[2],o=l[3];break;case"s":{let p=l.map((m,u)=>u%2?m+o:m+e);n.push({key:"S",data:p}),e=p[2],o=p[3];break}case"T":n.push({key:"T",data:[...l]}),e=l[0],o=l[1];break;case"t":e+=l[0],o+=l[1],n.push({key:"T",data:[e,o]});break;case"Z":case"z":n.push({key:"Z",data:[]}),e=a,o=s}return n}function yy(r){let e=[],o="",a=0,s=0,n=0,c=0,l=0,p=0;for(let{key:m,data:u}of r){switch(m){case"M":e.push({key:"M",data:[...u]}),[a,s]=u,[n,c]=u;break;case"C":e.push({key:"C",data:[...u]}),a=u[4],s=u[5],l=u[2],p=u[3];break;case"L":e.push({key:"L",data:[...u]}),[a,s]=u;break;case"H":a=u[0],e.push({key:"L",data:[a,s]});break;case"V":s=u[0],e.push({key:"L",data:[a,s]});break;case"S":{let y=0,x=0;o==="C"||o==="S"?(y=a+(a-l),x=s+(s-p)):(y=a,x=s),e.push({key:"C",data:[y,x,...u]}),l=u[0],p=u[1],a=u[2],s=u[3];break}case"T":{let[y,x]=u,k=0,w=0;o==="Q"||o==="T"?(k=a+(a-l),w=s+(s-p)):(k=a,w=s);let _=a+2*(k-a)/3,M=s+2*(w-s)/3,W=y+2*(k-y)/3,U=x+2*(w-x)/3;e.push({key:"C",data:[_,M,W,U,y,x]}),l=k,p=w,a=y,s=x;break}case"Q":{let[y,x,k,w]=u,_=a+2*(y-a)/3,M=s+2*(x-s)/3,W=k+2*(y-k)/3,U=w+2*(x-w)/3;e.push({key:"C",data:[_,M,W,U,k,w]}),l=y,p=x,a=k,s=w;break}case"A":{let y=Math.abs(u[0]),x=Math.abs(u[1]),k=u[2],w=u[3],_=u[4],M=u[5],W=u[6];if(y===0||x===0)e.push({key:"C",data:[a,s,M,W,M,W]}),a=M,s=W;else if(a!==M||s!==W)xy(a,s,M,W,y,x,k,w,_).forEach(function(U){e.push({key:"C",data:U})}),a=M,s=W;break}case"Z":e.push({key:"Z",data:[]}),a=n,s=c}o=m}return e}function za(r,e,o){return[r*Math.cos(o)-e*Math.sin(o),r*Math.sin(o)+e*Math.cos(o)]}function xy(r,e,o,a,s,n,c,l,p,m){let u=(y=c,Math.PI*y/180);var y;let x=[],k=0,w=0,_=0,M=0;if(m)[k,w,_,M]=m;else{[r,e]=za(r,e,-u),[o,a]=za(o,a,-u);let rt=(r-o)/2,it=(e-a)/2,gt=rt*rt/(s*s)+it*it/(n*n);gt>1&&(gt=Math.sqrt(gt),s*=gt,n*=gt);let et=s*s,wt=n*n,vt=et*wt-et*it*it-wt*rt*rt,Xt=et*it*it+wt*rt*rt,jt=(l===p?-1:1)*Math.sqrt(Math.abs(vt/Xt));_=jt*s*it/n+(r+o)/2,M=jt*-n*rt/s+(e+a)/2,k=Math.asin(parseFloat(((e-M)/n).toFixed(9))),w=Math.asin(parseFloat(((a-M)/n).toFixed(9))),r<_&&(k=Math.PI-k),o<_&&(w=Math.PI-w),k<0&&(k=2*Math.PI+k),w<0&&(w=2*Math.PI+w),p&&k>w&&(k-=2*Math.PI),!p&&w>k&&(w-=2*Math.PI)}let W=w-k;if(Math.abs(W)>120*Math.PI/180){let rt=w,it=o,gt=a;w=p&&w>k?k+120*Math.PI/180*1:k+120*Math.PI/180*-1,x=xy(o=_+s*Math.cos(w),a=M+n*Math.sin(w),it,gt,s,n,c,0,p,[w,rt,_,M])}W=w-k;let U=Math.cos(k),V=Math.sin(k),Z=Math.cos(w),tt=Math.sin(w),at=Math.tan(W/4),ot=1.3333333333333333*s*at,ht=1.3333333333333333*n*at,yt=[r,e],Bt=[r+ot*V,e-ht*U],kt=[o+ot*tt,a-ht*Z],Ct=[o,a];if(Bt[0]=2*yt[0]-Bt[0],Bt[1]=2*yt[1]-Bt[1],m)return[Bt,kt,Ct].concat(x);{x=[Bt,kt,Ct].concat(x);let rt=[];for(let it=0;it<x.length;it+=3){let gt=za(x[it][0],x[it][1],u),et=za(x[it+1][0],x[it+1][1],u),wt=za(x[it+2][0],x[it+2][1],u);rt.push([gt[0],gt[1],et[0],et[1],wt[0],wt[1]])}return rt}}var Iw={randOffset:function(r,e){return le(r,e)},randOffsetWithRange:function(r,e,o){return $l(r,e,o)},ellipse:function(r,e,o,a,s){let n=by(o,a,s);return qf(r,e,s,n).opset},doubleLineOps:function(r,e,o,a,s){return Qi(r,e,o,a,s,!0)}};function Cy(r,e,o,a,s){return{type:"path",ops:Qi(r,e,o,a,s)}}function Ol(r,e,o){let a=(r||[]).length;if(a>2){let s=[];for(let n=0;n<a-1;n++)s.push(...Qi(r[n][0],r[n][1],r[n+1][0],r[n+1][1],o));return e&&s.push(...Qi(r[a-1][0],r[a-1][1],r[0][0],r[0][1],o)),{type:"path",ops:s}}return a===2?Cy(r[0][0],r[0][1],r[1][0],r[1][1],o):{type:"path",ops:[]}}function $w(r,e,o,a,s){return function(n,c){return Ol(n,!0,c)}([[r,e],[r+o,e],[r+o,e+a],[r,e+a]],s)}function iy(r,e){if(r.length){let o=typeof r[0][0]=="number"?[r]:r,a=Ml(o[0],1*(1+0.2*e.roughness),e),s=e.disableMultiStroke?[]:Ml(o[0],1.5*(1+0.22*e.roughness),ay(e));for(let n=1;n<o.length;n++){let c=o[n];if(c.length){let l=Ml(c,1*(1+0.2*e.roughness),e),p=e.disableMultiStroke?[]:Ml(c,1.5*(1+0.22*e.roughness),ay(e));for(let m of l)m.op!=="move"&&a.push(m);for(let m of p)m.op!=="move"&&s.push(m)}}return{type:"path",ops:a.concat(s)}}return{type:"path",ops:[]}}function by(r,e,o){let a=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(r/2,2)+Math.pow(e/2,2))/2)),s=Math.ceil(Math.max(o.curveStepCount,o.curveStepCount/Math.sqrt(200)*a)),n=2*Math.PI/s,c=Math.abs(r/2),l=Math.abs(e/2),p=1-o.curveFitting;return c+=le(c*p,o),l+=le(l*p,o),{increment:n,rx:c,ry:l}}function qf(r,e,o,a){let[s,n]=ny(a.increment,r,e,a.rx,a.ry,1,a.increment*$l(0.1,$l(0.4,1,o),o),o),c=Dl(s,null,o);if(!o.disableMultiStroke&&o.roughness!==0){let[l]=ny(a.increment,r,e,a.rx,a.ry,1.5,0,o),p=Dl(l,null,o);c=c.concat(p)}return{estimatedPoints:n,opset:{type:"path",ops:c}}}function oy(r,e,o,a,s,n,c,l,p){let m=r,u=e,y=Math.abs(o/2),x=Math.abs(a/2);y+=le(0.01*y,p),x+=le(0.01*x,p);let k=s,w=n;for(;k<0;)k+=2*Math.PI,w+=2*Math.PI;w-k>2*Math.PI&&(k=0,w=2*Math.PI);let _=2*Math.PI/p.curveStepCount,M=Math.min(_/2,(w-k)/2),W=ly(M,m,u,y,x,k,w,1,p);if(!p.disableMultiStroke){let U=ly(M,m,u,y,x,k,w,1.5,p);W.push(...U)}return c&&(l?W.push(...Qi(m,u,m+y*Math.cos(k),u+x*Math.sin(k),p),...Qi(m,u,m+y*Math.cos(w),u+x*Math.sin(w),p)):W.push({op:"lineTo",data:[m,u]},{op:"lineTo",data:[m+y*Math.cos(k),u+x*Math.sin(k)]})),{type:"path",ops:W}}function sy(r,e){let o=yy(my(zf(r))),a=[],s=[0,0],n=[0,0];for(let{key:c,data:l}of o)switch(c){case"M":n=[l[0],l[1]],s=[l[0],l[1]];break;case"L":a.push(...Qi(n[0],n[1],l[0],l[1],e)),n=[l[0],l[1]];break;case"C":{let[p,m,u,y,x,k]=l;a.push(...Dw(p,m,u,y,x,k,n,e)),n=[x,k];break}case"Z":a.push(...Qi(n[0],n[1],s[0],s[1],e)),n=[s[0],s[1]]}return{type:"path",ops:a}}function Pf(r,e){let o=[];for(let a of r)if(a.length){let s=e.maxRandomnessOffset||0,n=a.length;if(n>2){o.push({op:"move",data:[a[0][0]+le(s,e),a[0][1]+le(s,e)]});for(let c=1;c<n;c++)o.push({op:"lineTo",data:[a[c][0]+le(s,e),a[c][1]+le(s,e)]})}}return{type:"fillPath",ops:o}}function xs(r,e){return function(o,a){let s=o.fillStyle||"hachure";if(!Sr[s])switch(s){case"zigzag":Sr[s]||(Sr[s]=new cy(a));break;case"cross-hatch":Sr[s]||(Sr[s]=new uy(a));break;case"dots":Sr[s]||(Sr[s]=new fy(a));break;case"dashed":Sr[s]||(Sr[s]=new dy(a));break;case"zigzag-line":Sr[s]||(Sr[s]=new py(a));break;default:s="hachure",Sr[s]||(Sr[s]=new Rl(a))}return Sr[s]}(e,Iw).fillPolygons(r,e)}function ay(r){let e=Object.assign({},r);return e.randomizer=void 0,r.seed&&(e.seed=r.seed+1),e}function ky(r){return r.randomizer||(r.randomizer=new gy(r.seed||0)),r.randomizer.next()}function $l(r,e,o,a=1){return o.roughness*a*(ky(o)*(e-r)+r)}function le(r,e,o=1){return $l(-r,r,e,o)}function Qi(r,e,o,a,s,n=!1){let c=n?s.disableMultiStrokeFill:s.disableMultiStroke,l=Nf(r,e,o,a,s,!0,!1);if(c)return l;let p=Nf(r,e,o,a,s,!0,!0);return l.concat(p)}function Nf(r,e,o,a,s,n,c){let l=Math.pow(r-o,2)+Math.pow(e-a,2),p=Math.sqrt(l),m=1;m=p<200?1:p>500?0.4:-0.0016668*p+1.233334;let u=s.maxRandomnessOffset||0;u*u*100>l&&(u=p/10);let y=u/2,x=0.2+0.2*ky(s),k=s.bowing*s.maxRandomnessOffset*(a-e)/200,w=s.bowing*s.maxRandomnessOffset*(r-o)/200;k=le(k,s,m),w=le(w,s,m);let _=[],M=()=>le(y,s,m),W=()=>le(u,s,m),U=s.preserveVertices;return n&&(c?_.push({op:"move",data:[r+(U?0:M()),e+(U?0:M())]}):_.push({op:"move",data:[r+(U?0:le(u,s,m)),e+(U?0:le(u,s,m))]})),c?_.push({op:"bcurveTo",data:[k+r+(o-r)*x+M(),w+e+(a-e)*x+M(),k+r+2*(o-r)*x+M(),w+e+2*(a-e)*x+M(),o+(U?0:M()),a+(U?0:M())]}):_.push({op:"bcurveTo",data:[k+r+(o-r)*x+W(),w+e+(a-e)*x+W(),k+r+2*(o-r)*x+W(),w+e+2*(a-e)*x+W(),o+(U?0:W()),a+(U?0:W())]}),_}function Ml(r,e,o){if(!r.length)return[];let a=[];a.push([r[0][0]+le(e,o),r[0][1]+le(e,o)]),a.push([r[0][0]+le(e,o),r[0][1]+le(e,o)]);for(let s=1;s<r.length;s++)a.push([r[s][0]+le(e,o),r[s][1]+le(e,o)]),s===r.length-1&&a.push([r[s][0]+le(e,o),r[s][1]+le(e,o)]);return Dl(a,null,o)}function Dl(r,e,o){let a=r.length,s=[];if(a>3){let n=[],c=1-o.curveTightness;s.push({op:"move",data:[r[1][0],r[1][1]]});for(let l=1;l+2<a;l++){let p=r[l];n[0]=[p[0],p[1]],n[1]=[p[0]+(c*r[l+1][0]-c*r[l-1][0])/6,p[1]+(c*r[l+1][1]-c*r[l-1][1])/6],n[2]=[r[l+1][0]+(c*r[l][0]-c*r[l+2][0])/6,r[l+1][1]+(c*r[l][1]-c*r[l+2][1])/6],n[3]=[r[l+1][0],r[l+1][1]],s.push({op:"bcurveTo",data:[n[1][0],n[1][1],n[2][0],n[2][1],n[3][0],n[3][1]]})}if(e&&e.length===2){let l=o.maxRandomnessOffset;s.push({op:"lineTo",data:[e[0]+le(l,o),e[1]+le(l,o)]})}}else a===3?(s.push({op:"move",data:[r[1][0],r[1][1]]}),s.push({op:"bcurveTo",data:[r[1][0],r[1][1],r[2][0],r[2][1],r[2][0],r[2][1]]})):a===2&&s.push(...Nf(r[0][0],r[0][1],r[1][0],r[1][1],o,!0,!0));return s}function ny(r,e,o,a,s,n,c,l){let p=[],m=[];if(l.roughness===0){r/=4,m.push([e+a*Math.cos(-r),o+s*Math.sin(-r)]);for(let u=0;u<=2*Math.PI;u+=r){let y=[e+a*Math.cos(u),o+s*Math.sin(u)];p.push(y),m.push(y)}m.push([e+a*Math.cos(0),o+s*Math.sin(0)]),m.push([e+a*Math.cos(r),o+s*Math.sin(r)])}else{let u=le(0.5,l)-Math.PI/2;m.push([le(n,l)+e+0.9*a*Math.cos(u-r),le(n,l)+o+0.9*s*Math.sin(u-r)]);let y=2*Math.PI+u-0.01;for(let x=u;x<y;x+=r){let k=[le(n,l)+e+a*Math.cos(x),le(n,l)+o+s*Math.sin(x)];p.push(k),m.push(k)}m.push([le(n,l)+e+a*Math.cos(u+2*Math.PI+0.5*c),le(n,l)+o+s*Math.sin(u+2*Math.PI+0.5*c)]),m.push([le(n,l)+e+0.98*a*Math.cos(u+c),le(n,l)+o+0.98*s*Math.sin(u+c)]),m.push([le(n,l)+e+0.9*a*Math.cos(u+0.5*c),le(n,l)+o+0.9*s*Math.sin(u+0.5*c)])}return[m,p]}function ly(r,e,o,a,s,n,c,l,p){let m=n+le(0.1,p),u=[];u.push([le(l,p)+e+0.9*a*Math.cos(m-r),le(l,p)+o+0.9*s*Math.sin(m-r)]);for(let y=m;y<=c;y+=r)u.push([le(l,p)+e+a*Math.cos(y),le(l,p)+o+s*Math.sin(y)]);return u.push([e+a*Math.cos(c),o+s*Math.sin(c)]),u.push([e+a*Math.cos(c),o+s*Math.sin(c)]),Dl(u,null,p)}function Dw(r,e,o,a,s,n,c,l){let p=[],m=[l.maxRandomnessOffset||1,(l.maxRandomnessOffset||1)+0.3],u=[0,0],y=l.disableMultiStroke?1:2,x=l.preserveVertices;for(let k=0;k<y;k++)k===0?p.push({op:"move",data:[c[0],c[1]]}):p.push({op:"move",data:[c[0]+(x?0:le(m[0],l)),c[1]+(x?0:le(m[0],l))]}),u=x?[s,n]:[s+le(m[k],l),n+le(m[k],l)],p.push({op:"bcurveTo",data:[r+le(m[k],l),e+le(m[k],l),o+le(m[k],l),a+le(m[k],l),u[0],u[1]]});return p}function Ha(r){return[...r]}function hy(r,e=0){let o=r.length;if(o<3)throw Error("A curve must have at least three points.");let a=[];if(o===3)a.push(Ha(r[0]),Ha(r[1]),Ha(r[2]),Ha(r[2]));else{let s=[];s.push(r[0],r[0]);for(let l=1;l<r.length;l++)s.push(r[l]),l===r.length-1&&s.push(r[l]);let n=[],c=1-e;a.push(Ha(s[0]));for(let l=1;l+2<s.length;l++){let p=s[l];n[0]=[p[0],p[1]],n[1]=[p[0]+(c*s[l+1][0]-c*s[l-1][0])/6,p[1]+(c*s[l+1][1]-c*s[l-1][1])/6],n[2]=[s[l+1][0]+(c*s[l][0]-c*s[l+2][0])/6,s[l+1][1]+(c*s[l][1]-c*s[l+2][1])/6],n[3]=[s[l+1][0],s[l+1][1]],a.push(n[1],n[2],n[3])}}return a}function Il(r,e){return Math.pow(r[0]-e[0],2)+Math.pow(r[1]-e[1],2)}function Pw(r,e,o){let a=Il(e,o);if(a===0)return Il(r,e);let s=((r[0]-e[0])*(o[0]-e[0])+(r[1]-e[1])*(o[1]-e[1]))/a;return s=Math.max(0,Math.min(1,s)),Il(r,ho(e,o,s))}function ho(r,e,o){return[r[0]+(e[0]-r[0])*o,r[1]+(e[1]-r[1])*o]}function Wf(r,e,o,a){let s=a||[];if(function(l,p){let m=l[p+0],u=l[p+1],y=l[p+2],x=l[p+3],k=3*u[0]-2*m[0]-x[0];k*=k;let w=3*u[1]-2*m[1]-x[1];w*=w;let _=3*y[0]-2*x[0]-m[0];_*=_;let M=3*y[1]-2*x[1]-m[1];return M*=M,k<_&&(k=_),w<M&&(w=M),k+w}(r,e)<o){let l=r[e+0];if(s.length)(n=s[s.length-1],c=l,Math.sqrt(Il(n,c)))>1&&s.push(l);else s.push(l);s.push(r[e+3])}else{let p=r[e+0],m=r[e+1],u=r[e+2],y=r[e+3],x=ho(p,m,0.5),k=ho(m,u,0.5),w=ho(u,y,0.5),_=ho(x,k,0.5),M=ho(k,w,0.5),W=ho(_,M,0.5);Wf([p,x,_,W],0,o,s),Wf([W,M,w,y],0,o,s)}var n,c;return s}function Rw(r,e){return Pl(r,0,r.length,e)}function Pl(r,e,o,a,s){let n=s||[],c=r[e],l=r[o-1],p=0,m=1;for(let u=e+1;u<o-1;++u){let y=Pw(r[u],c,l);y>p&&(p=y,m=u)}return Math.sqrt(p)>a?(Pl(r,e,m+1,a,n),Pl(r,m,o,a,n)):(n.length||n.push(c),n.push(l)),n}function Rf(r,e=0.15,o){let a=[],s=(r.length-1)/3;for(let n=0;n<s;n++)Wf(r,3*n,e,a);return o&&o>0?Pl(a,0,a.length,o):a}var Ar="none";class Ua{constructor(r){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:0.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:0.8},this.config=r||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2147483648)}_o(r){return r?Object.assign({},this.defaultOptions,r):this.defaultOptions}_d(r,e,o){return{shape:r,sets:e||[],options:o||this.defaultOptions}}line(r,e,o,a,s){let n=this._o(s);return this._d("line",[Cy(r,e,o,a,n)],n)}rectangle(r,e,o,a,s){let n=this._o(s),c=[],l=$w(r,e,o,a,n);if(n.fill){let p=[[r,e],[r+o,e],[r+o,e+a],[r,e+a]];n.fillStyle==="solid"?c.push(Pf([p],n)):c.push(xs([p],n))}return n.stroke!==Ar&&c.push(l),this._d("rectangle",c,n)}ellipse(r,e,o,a,s){let n=this._o(s),c=[],l=by(o,a,n),p=qf(r,e,n,l);if(n.fill)if(n.fillStyle==="solid"){let m=qf(r,e,n,l).opset;m.type="fillPath",c.push(m)}else c.push(xs([p.estimatedPoints],n));return n.stroke!==Ar&&c.push(p.opset),this._d("ellipse",c,n)}circle(r,e,o,a){let s=this.ellipse(r,e,o,o,a);return s.shape="circle",s}linearPath(r,e){let o=this._o(e);return this._d("linearPath",[Ol(r,!1,o)],o)}arc(r,e,o,a,s,n,c=!1,l){let p=this._o(l),m=[],u=oy(r,e,o,a,s,n,c,!0,p);if(c&&p.fill)if(p.fillStyle==="solid"){let y=Object.assign({},p);y.disableMultiStroke=!0;let x=oy(r,e,o,a,s,n,!0,!1,y);x.type="fillPath",m.push(x)}else m.push(function(y,x,k,w,_,M,W){let U=y,V=x,Z=Math.abs(k/2),tt=Math.abs(w/2);Z+=le(0.01*Z,W),tt+=le(0.01*tt,W);let at=_,ot=M;for(;at<0;)at+=2*Math.PI,ot+=2*Math.PI;ot-at>2*Math.PI&&(at=0,ot=2*Math.PI);let ht=(ot-at)/W.curveStepCount,yt=[];for(let Bt=at;Bt<=ot;Bt+=ht)yt.push([U+Z*Math.cos(Bt),V+tt*Math.sin(Bt)]);return yt.push([U+Z*Math.cos(ot),V+tt*Math.sin(ot)]),yt.push([U,V]),xs([yt],W)}(r,e,o,a,s,n,p));return p.stroke!==Ar&&m.push(u),this._d("arc",m,p)}curve(r,e){let o=this._o(e),a=[],s=iy(r,o);if(o.fill&&o.fill!==Ar)if(o.fillStyle==="solid"){let n=iy(r,Object.assign(Object.assign({},o),{disableMultiStroke:!0,roughness:o.roughness?o.roughness+o.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(n.ops)})}else{let n=[],c=r;if(c.length){let l=typeof c[0][0]=="number"?[c]:c;for(let p of l)p.length<3?n.push(...p):p.length===3?n.push(...Rf(hy([p[0],p[0],p[1],p[2]]),10,(1+o.roughness)/2)):n.push(...Rf(hy(p),10,(1+o.roughness)/2))}n.length&&a.push(xs([n],o))}return o.stroke!==Ar&&a.push(s),this._d("curve",a,o)}polygon(r,e){let o=this._o(e),a=[],s=Ol(r,!0,o);return o.fill&&(o.fillStyle==="solid"?a.push(Pf([r],o)):a.push(xs([r],o))),o.stroke!==Ar&&a.push(s),this._d("polygon",a,o)}path(r,e){let o=this._o(e),a=[];if(!r)return this._d("path",a,o);r=(r||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");let s=o.fill&&o.fill!=="transparent"&&o.fill!==Ar,n=o.stroke!==Ar,c=!!(o.simplification&&o.simplification<1),l=function(m,u,y){let x=yy(my(zf(m))),k=[],w=[],_=[0,0],M=[],W=()=>{M.length>=4&&w.push(...Rf(M,u)),M=[]},U=()=>{W(),w.length&&(k.push(w),w=[])};for(let{key:Z,data:tt}of x)switch(Z){case"M":U(),_=[tt[0],tt[1]],w.push(_);break;case"L":W(),w.push([tt[0],tt[1]]);break;case"C":if(!M.length){let at=w.length?w[w.length-1]:_;M.push([at[0],at[1]])}M.push([tt[0],tt[1]]),M.push([tt[2],tt[3]]),M.push([tt[4],tt[5]]);break;case"Z":W(),w.push([_[0],_[1]])}if(U(),!y)return k;let V=[];for(let Z of k){let tt=Rw(Z,y);tt.length&&V.push(tt)}return V}(r,1,c?4-4*(o.simplification||1):(1+o.roughness)/2),p=sy(r,o);if(s)if(o.fillStyle==="solid")if(l.length===1){let m=sy(r,Object.assign(Object.assign({},o),{disableMultiStroke:!0,roughness:o.roughness?o.roughness+o.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(m.ops)})}else a.push(Pf(l,o));else a.push(xs(l,o));return n&&(c?l.forEach((m)=>{a.push(Ol(m,!1,o))}):a.push(p)),this._d("path",a,o)}opsToPath(r,e){let o="";for(let a of r.ops){let s=typeof e=="number"&&e>=0?a.data.map((n)=>+n.toFixed(e)):a.data;switch(a.op){case"move":o+=`M${s[0]} ${s[1]} `;break;case"bcurveTo":o+=`C${s[0]} ${s[1]}, ${s[2]} ${s[3]}, ${s[4]} ${s[5]} `;break;case"lineTo":o+=`L${s[0]} ${s[1]} `}}return o.trim()}toPaths(r){let e=r.sets||[],o=r.options||this.defaultOptions,a=[];for(let s of e){let n=null;switch(s.type){case"path":n={d:this.opsToPath(s),stroke:o.stroke,strokeWidth:o.strokeWidth,fill:Ar};break;case"fillPath":n={d:this.opsToPath(s),stroke:Ar,strokeWidth:0,fill:o.fill||Ar};break;case"fillSketch":n=this.fillSketch(s,o)}n&&a.push(n)}return a}fillSketch(r,e){let o=e.fillWeight;return o<0&&(o=e.strokeWidth/2),{d:this.opsToPath(r),stroke:e.fill||Ar,strokeWidth:o,fill:Ar}}_mergedShape(r){return r.filter((e,o)=>o===0||e.op!=="move")}}class wy{constructor(r,e){this.canvas=r,this.ctx=this.canvas.getContext("2d"),this.gen=new Ua(e)}draw(r){let e=r.sets||[],o=r.options||this.getDefaultOptions(),a=this.ctx,s=r.options.fixedDecimalPlaceDigits;for(let n of e)switch(n.type){case"path":a.save(),a.strokeStyle=o.stroke==="none"?"transparent":o.stroke,a.lineWidth=o.strokeWidth,o.strokeLineDash&&a.setLineDash(o.strokeLineDash),o.strokeLineDashOffset&&(a.lineDashOffset=o.strokeLineDashOffset),this._drawToContext(a,n,s),a.restore();break;case"fillPath":{a.save(),a.fillStyle=o.fill||"";let c=r.shape==="curve"||r.shape==="polygon"||r.shape==="path"?"evenodd":"nonzero";this._drawToContext(a,n,s,c),a.restore();break}case"fillSketch":this.fillSketch(a,n,o)}}fillSketch(r,e,o){let a=o.fillWeight;a<0&&(a=o.strokeWidth/2),r.save(),o.fillLineDash&&r.setLineDash(o.fillLineDash),o.fillLineDashOffset&&(r.lineDashOffset=o.fillLineDashOffset),r.strokeStyle=o.fill||"",r.lineWidth=a,this._drawToContext(r,e,o.fixedDecimalPlaceDigits),r.restore()}_drawToContext(r,e,o,a="nonzero"){r.beginPath();for(let s of e.ops){let n=typeof o=="number"&&o>=0?s.data.map((c)=>+c.toFixed(o)):s.data;switch(s.op){case"move":r.moveTo(n[0],n[1]);break;case"bcurveTo":r.bezierCurveTo(n[0],n[1],n[2],n[3],n[4],n[5]);break;case"lineTo":r.lineTo(n[0],n[1])}}e.type==="fillPath"?r.fill(a):r.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(r,e,o,a,s){let n=this.gen.line(r,e,o,a,s);return this.draw(n),n}rectangle(r,e,o,a,s){let n=this.gen.rectangle(r,e,o,a,s);return this.draw(n),n}ellipse(r,e,o,a,s){let n=this.gen.ellipse(r,e,o,a,s);return this.draw(n),n}circle(r,e,o,a){let s=this.gen.circle(r,e,o,a);return this.draw(s),s}linearPath(r,e){let o=this.gen.linearPath(r,e);return this.draw(o),o}polygon(r,e){let o=this.gen.polygon(r,e);return this.draw(o),o}arc(r,e,o,a,s,n,c=!1,l){let p=this.gen.arc(r,e,o,a,s,n,c,l);return this.draw(p),p}curve(r,e){let o=this.gen.curve(r,e);return this.draw(o),o}path(r,e){let o=this.gen.path(r,e);return this.draw(o),o}}var El="http://www.w3.org/2000/svg";class Sy{constructor(r,e){this.svg=r,this.gen=new Ua(e)}draw(r){let e=r.sets||[],o=r.options||this.getDefaultOptions(),a=this.svg.ownerDocument||window.document,s=a.createElementNS(El,"g"),n=r.options.fixedDecimalPlaceDigits;for(let c of e){let l=null;switch(c.type){case"path":l=a.createElementNS(El,"path"),l.setAttribute("d",this.opsToPath(c,n)),l.setAttribute("stroke",o.stroke),l.setAttribute("stroke-width",o.strokeWidth+""),l.setAttribute("fill","none"),o.strokeLineDash&&l.setAttribute("stroke-dasharray",o.strokeLineDash.join(" ").trim()),o.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${o.strokeLineDashOffset}`);break;case"fillPath":l=a.createElementNS(El,"path"),l.setAttribute("d",this.opsToPath(c,n)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",o.fill||""),r.shape!=="curve"&&r.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(a,c,o)}l&&s.appendChild(l)}return s}fillSketch(r,e,o){let a=o.fillWeight;a<0&&(a=o.strokeWidth/2);let s=r.createElementNS(El,"path");return s.setAttribute("d",this.opsToPath(e,o.fixedDecimalPlaceDigits)),s.setAttribute("stroke",o.fill||""),s.setAttribute("stroke-width",a+""),s.setAttribute("fill","none"),o.fillLineDash&&s.setAttribute("stroke-dasharray",o.fillLineDash.join(" ").trim()),o.fillLineDashOffset&&s.setAttribute("stroke-dashoffset",`${o.fillLineDashOffset}`),s}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(r,e){return this.gen.opsToPath(r,e)}line(r,e,o,a,s){let n=this.gen.line(r,e,o,a,s);return this.draw(n)}rectangle(r,e,o,a,s){let n=this.gen.rectangle(r,e,o,a,s);return this.draw(n)}ellipse(r,e,o,a,s){let n=this.gen.ellipse(r,e,o,a,s);return this.draw(n)}circle(r,e,o,a){let s=this.gen.circle(r,e,o,a);return this.draw(s)}linearPath(r,e){let o=this.gen.linearPath(r,e);return this.draw(o)}polygon(r,e){let o=this.gen.polygon(r,e);return this.draw(o)}arc(r,e,o,a,s,n,c=!1,l){let p=this.gen.arc(r,e,o,a,s,n,c,l);return this.draw(p)}curve(r,e){let o=this.gen.curve(r,e);return this.draw(o)}path(r,e){let o=this.gen.path(r,e);return this.draw(o)}}var v={canvas:(r,e)=>new wy(r,e),svg:(r,e)=>new Sy(r,e),generator:(r)=>new Ua(r),newSeed:()=>Ua.newSeed()};var qw=1,Nw=3;async function td(r){let e=r.getElementsByTagName("img");if(!e||e.length===0)return;let o=!ed(r);await Promise.all([...e].map((a)=>new Promise((s)=>{function n(){if(a.style.display="flex",a.style.flexDirection="column",o){let c=d().fontSize?d().fontSize:window.getComputedStyle(document.body).fontSize,l=5,[p=F.fontSize]=Nt(c),m=p*5+"px";a.style.minWidth=m,a.style.maxWidth=m}else a.style.width="100%";s(a)}t(n,"setupImage"),setTimeout(()=>{if(a.complete)n()}),a.addEventListener("error",n),a.addEventListener("load",n)})))}t(td,"configureLabelImages");function ed(r){if(r.nodeType===Nw)return r.textContent?.trim()!=="";if(r.nodeType!==qw)return!1;if(r.tagName.toLowerCase()==="img")return!1;return[...r.childNodes].some(ed)}t(ed,"hasTextBesidesImages");var Ty=3,Ww=32,zw=t(async(r,e,o)=>{let a=d(),s=r.insert("g").attr("class",o??"node default").attr("id",e.domId||e.id),n=s.insert("g").attr("class","label").attr("style",Fe(e.labelStyle)),l=[{text:typeof e.label==="string"?e.label:e.label?.[0]??"",cssClass:"c4-name"},{text:e.stereotype,cssClass:"c4-type"},...(e.description??[]).map((W)=>({text:W,cssClass:"c4-descr"}))].filter((W)=>W.text),p=e.width?Math.max(e.width-2*(e.padding??0),Ww):d().flowchart?.wrappingWidth??200,u=a.c4?.wrap??!0?p:Number.POSITIVE_INFINITY,y=await Promise.all(l.map(async(W)=>{let U=n.append("g").attr("class",W.cssClass),V=await ct(U,q(Fn(W.text??""),a),{useHtmlLabels:!1,markdown:!1,isNode:!0,width:u,style:e.labelStyle},a);return g(V).selectAll("tspan.text-outer-tspan").attr("text-anchor","middle"),g(V).selectAll("tspan.text-inner-tspan").attr("font-weight",null).attr("font-style",null),{el:U,box:U.node().getBBox()}})),x=Math.max(...y.map(({box:W})=>W.width),0),k=0;for(let{el:W,box:U}of y)W.attr("transform",`translate(${x/2-U.x-U.width/2}, ${k-U.y})`),k+=U.height+Ty;let w=y.length>0?k-Ty:0;n.insert("rect",":first-child"),n.attr("transform",`translate(${-x/2}, ${-w/2})`);let _=n.node().getBBox(),M=(e.padding??0)/2;return{shapeSvg:s,bbox:_,halfPadding:M,label:n}},"c4LabelHelper"),_y=t((r,e)=>{let{x:o,y:a,width:s,height:n}=r;if(s>=e)return r;if(!("left"in r))return{x:o-(e-s)/2,y:a,width:e,height:n};return{x:o,y:a,width:e,height:n,top:a,left:o,bottom:a+n,right:o+e,toJSON:t(()=>({}),"toJSON")}},"withMinWidth"),j=t(async(r,e,o,{ignoreMinWidth:a=!1}={})=>{if(e.stereotype!==void 0)return zw(r,e,o);let s,n=e.useHtmlLabels||ln(d()?.htmlLabels);if(!o)s="node default";else s=o;let c=r.insert("g").attr("class",s).attr("id",e.domId||e.id),l=c.insert("g").attr("class","label").attr("style",Fe(e.labelStyle)),p;if(e.label===void 0)p="";else p=typeof e.label==="string"?e.label:e.label[0];let m=!!e.icon||!!e.img,u=e.labelType==="markdown",y=p&&!e.width&&!a?e.minWidth??0:0,x=await ct(l,q(Fn(p),d()),{useHtmlLabels:n,width:e.width||e.wrappingWidth||d().flowchart?.wrappingWidth,minWidth:y,classes:u?"markdown-node-label":"",style:e.labelStyle,addSvgBackground:m,markdown:u},d()),k=(e?.padding??0)/2,w;if(n){let _=x.children[0],M=g(x);await td(_),w=await Bi.measure(()=>_.getBoundingClientRect()),w=_y(w,y),M.attr("width",w.width),M.attr("height",w.height)}else w=await Bi.measure(()=>x.getBBox()),w=_y(w,y);if(n)l.attr("transform","translate("+-w.width/2+", "+-w.height/2+")");else l.attr("transform","translate(0, "+-w.height/2+")");if(e.centerLabel)l.attr("transform","translate("+-w.width/2+", "+-w.height/2+")");return l.insert("rect",":first-child"),{shapeSvg:c,bbox:w,halfPadding:k,label:l}},"labelHelper"),uo=t(async(r,e,o)=>{let a=o.useHtmlLabels??Xe(d()),s=r.insert("g").attr("class","label").attr("style",o.labelStyle||""),n=await ct(s,q(Fn(e),d()),{useHtmlLabels:a,width:o.width||d()?.flowchart?.wrappingWidth,style:o.labelStyle,addSvgBackground:!!o.icon||!!o.img}),c=o.padding/2,l;if(Xe(d())){let p=n.children[0],m=g(n);l=await Bi.measure(()=>p.getBoundingClientRect()),m.attr("width",l.width),m.attr("height",l.height)}else l=await Bi.measure(()=>n.getBBox());if(a)s.attr("transform","translate("+-l.width/2+", "+-l.height/2+")");else s.attr("transform","translate(0, "+-l.height/2+")");if(o.centerLabel)s.attr("transform","translate("+-l.width/2+", "+-l.height/2+")");return s.insert("rect",":first-child"),{shapeSvg:r,bbox:l,halfPadding:c,label:s}},"insertLabel"),B=t((r,e,o)=>{if(o){r.width=o.width,r.height=o.height;return}let a=e.node().getBBox();r.width=a.width,r.height=a.height},"updateNodeBounds"),te=t((r,e)=>(r.look==="handDrawn"?"rough-node":"node")+" "+r.cssClasses+" "+(e||""),"getNodeClasses");function ye(r){let e=r.map((o,a)=>`${a===0?"M":"L"}${o.x},${o.y}`);return e.push("Z"),e.join(" ")}t(ye,"createPathFromPoints");function Ji(r,e,o,a,s,n){let c=[],l=50,p=o-r,m=a-e,u=p/n,y=2*Math.PI/u,x=e+m/2;for(let k=0;k<=50;k++){let w=k/50,_=r+w*p,M=x+s*Math.sin(y*(_-r));c.push({x:_,y:M})}return c}t(Ji,"generateFullSineWavePoints");function ci(r,e,o,a,s,n){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(ci,"generateCirclePoints");function Kf(r){let e=Array.from(r.childNodes).filter((p)=>p.tagName==="path"),o=document.createElementNS("http://www.w3.org/2000/svg","path"),a=e.map((p)=>p.getAttribute("d")).filter((p)=>p!==null).join(" ");o.setAttribute("d",a);let s=e.find((p)=>p.getAttribute("fill")!=="none"),n=e.find((p)=>p.getAttribute("stroke")!=="none"),c=t((p,m)=>p?.getAttribute(m)??void 0,"getAttr");if(s){let p={fill:c(s,"fill"),"fill-opacity":c(s,"fill-opacity")??"1"};Object.entries(p).forEach(([m,u])=>{if(u)o.setAttribute(m,u)})}if(n){let p={stroke:c(n,"stroke"),"stroke-width":c(n,"stroke-width")??"1","stroke-opacity":c(n,"stroke-opacity")??"1"};Object.entries(p).forEach(([m,u])=>{if(u)o.setAttribute(m,u)})}let l=document.createElementNS("http://www.w3.org/2000/svg","g");return l.appendChild(o),l}t(Kf,"mergePaths");var Hw=t((r,e)=>{var{x:o,y:a}=r,s=e.x-o,n=e.y-a,c=r.width/2,l=r.height/2,p,m;if(Math.abs(n)*c>Math.abs(s)*l){if(n<0)l=-l;p=n===0?0:l*s/n,m=l}else{if(s<0)c=-c;p=c,m=s===0?0:c*n/s}return{x:o+p,y:a+m}},"intersectRect"),ui=Hw;function Gy(r,e){return r.intersect(e)}t(Gy,"intersectNode");var Yw=Gy;function Xy(r,e,o,a){var{x:s,y:n}=r,c=s-a.x,l=n-a.y,p=Math.sqrt(e*e*l*l+o*o*c*c),m=Math.abs(e*o*c/p);if(a.x<s)m=-m;var u=Math.abs(e*o*l/p);if(a.y<n)u=-u;return{x:s+m,y:n+u}}t(Xy,"intersectEllipse");var Vy=Xy;function Ky(r,e,o){return Vy(r,e,e,o)}t(Ky,"intersectCircle");var Uw=Ky;function Zy(r,e,o,a){{let s=e.y-r.y,n=r.x-e.x,c=e.x*r.y-r.x*e.y,l=s*o.x+n*o.y+c,p=s*a.x+n*a.y+c,m=0.000001;if(l!==0&&p!==0&&Zf(l,p))return;let u=a.y-o.y,y=o.x-a.x,x=a.x*o.y-o.x*a.y,k=u*r.x+y*r.y+x,w=u*e.x+y*e.y+x;if(Math.abs(k)<0.000001&&Math.abs(w)<0.000001&&Zf(k,w))return;let _=s*y-u*n;if(_===0)return;let M=(n*x-y*c)/_,W=(u*c-s*x)/_;return{x:M,y:W}}}t(Zy,"intersectLine");function Zf(r,e){return r*e>0}t(Zf,"sameSign");var jw=Zy;function Qy(r,e,o){let{x:a,y:s}=r,n=[],{POSITIVE_INFINITY:c,POSITIVE_INFINITY:l}=Number;if(typeof e.forEach==="function")e.forEach(function(u){c=Math.min(c,u.x),l=Math.min(l,u.y)});else c=Math.min(c,e.x),l=Math.min(l,e.y);let p=a-r.width/2-c,m=s-r.height/2-l;for(let u=0;u<e.length;u++){let y=e[u],x=e[u<e.length-1?u+1:0],k=jw(r,o,{x:p+y.x,y:m+y.y},{x:p+x.x,y:m+x.y});if(k)n.push(k)}if(!n.length)return r;if(n.length>1)n.sort(function(u,y){let x=u.x-o.x,k=u.y-o.y,w=Math.sqrt(x*x+k*k),_=y.x-o.x,M=y.y-o.y,W=Math.sqrt(_*_+M*M);return w<W?-1:w===W?0:1});return n[0]}t(Qy,"intersectPolygon");var Gw=Qy,T={node:Yw,circle:Uw,ellipse:Vy,polygon:Gw,rect:ui},Tr=t((r,e,o,a,s)=>["M",r+s,e,"H",r+o-s,"A",s,s,0,0,1,r+o,e+s,"V",e+a-s,"A",s,s,0,0,1,r+o-s,e+a,"H",r+s,"A",s,s,0,0,1,r,e+a-s,"V",e+s,"A",s,s,0,0,1,r+s,e,"Z"].join(" "),"createRoundedRectPathD"),Xw=t(async(r,e,o,a=!1,s=!1)=>{let n=e||"";if(typeof n==="object")n=n[0];let c=d(),l=Xe(c);return await ct(r,n,{style:o,isTitle:a,useHtmlLabels:l,markdown:!1,isNode:s,width:Number.POSITIVE_INFINITY},c)},"createLabel"),Gr=Xw;function Jy(r,e){let{labelStyles:o}=E(e);e.labelStyle=o;let a=te(e),s=a;if(!a)s="anchor";let n=r.insert("g").attr("class",s).attr("id",e.domId||e.id),c=1,{cssStyles:l}=e,p=v.svg(n),m=Kt(e,{fill:"black",stroke:"none",fillStyle:"solid"});if(e.look!=="handDrawn")m.roughness=0;let u=p.circle(0,0,c*2,m),y=n.insert(()=>u,":first-child");return y.attr("class","anchor").attr("style",Fe(l)),B(e,y),e.intersect=function(x){return i.info("Circle intersect",e,c,x),T.circle(e,c,x)},n}t(Jy,"anchor");function Qf(r,e,o,a,s,n,c){let p=(r+o)/2,m=(e+a)/2,u=Math.atan2(a-e,o-r),y=(o-r)/2,x=(a-e)/2,k=y/s,w=x/n,_=Math.sqrt(k**2+w**2);if(_>1)throw Error("The given radii are too small to create an arc between the points.");let M=Math.sqrt(1-_**2),W=p+M*n*Math.sin(u)*(c?-1:1),U=m-M*s*Math.cos(u)*(c?-1:1),V=Math.atan2((e-U)/n,(r-W)/s),tt=Math.atan2((a-U)/n,(o-W)/s)-V;if(c&&tt<0)tt+=2*Math.PI;if(!c&&tt>0)tt-=2*Math.PI;let at=[];for(let ot=0;ot<20;ot++){let ht=ot/19,yt=V+ht*tt,Bt=W+s*Math.cos(yt),kt=U+n*Math.sin(yt);at.push({x:Bt,y:kt})}return at}t(Qf,"generateArcPoints");function tx(r,e,o){let[a,s]=[e,o].sort((n,c)=>c-n);return s*(1-Math.sqrt(1-(r/a/2)**2))}t(tx,"calculateArcSagitta");async function ex(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=t((yt)=>yt+c,"calcTotalHeight"),p=t((yt)=>{let Bt=yt/2;return[Bt/(2.5+yt/50),Bt]},"calcEllipseRadius"),{shapeSvg:m,bbox:u}=await j(r,e,te(e)),y=l(e?.height?e?.height:u.height),[x,k]=p(y),w=tx(y,x,k),M=(e?.width?e?.width:u.width)+n*2+w-w,W=y,{cssStyles:U}=e,V=[{x:M/2,y:-W/2},{x:-M/2,y:-W/2},...Qf(-M/2,-W/2,-M/2,W/2,x,k,!1),{x:M/2,y:W/2},...Qf(M/2,W/2,M/2,-W/2,x,k,!0)],Z=v.svg(m),tt=Kt(e,{});if(e.look!=="handDrawn")tt.roughness=0,tt.fillStyle="solid";let at=ye(V),ot=Z.path(at,tt),ht=m.insert(()=>ot,":first-child");if(ht.attr("class","basic label-container outer-path"),U&&e.look!=="handDrawn")ht.selectAll("path").attr("style",U);if(a&&e.look!=="handDrawn")ht.selectAll("path").attr("style",a);return ht.attr("transform",`translate(${x/2}, 0)`),B(e,ht),e.intersect=function(yt){return T.polygon(e,V,yt)},m}t(ex,"bowTieRect");async function rx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await j(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=Math.max(c.width+m*2,e.width??0,80),y=Math.max(Math.min(u*0.08,12),5),x=Math.max(c.height+m*2+y,e.height??0),k=-x/2+y,w=x/2,_=u*0.72,M=[`M${-u/2},${k}`,`L${-_/2},${w}`,`A${_/2},${y} 0 0 0 ${_/2},${w}`,`L${u/2},${k}`,`A${u/2},${y} 0 0 0 ${-u/2},${k}`,"Z"].join(" "),{cssStyles:W}=e,U=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let ht=v.svg(n).path(M,Kt(e,{}));if(U.node()?.appendChild(ht),W)U.attr("style",W)}else U.append("path").attr("d",M).attr("style",s);U.append("ellipse").attr("cx",0).attr("cy",k).attr("rx",u/2).attr("ry",y).attr("style",`fill:none;stroke:${p};stroke-width:1px`),B(e,U);let V=k+(w-k)/2;l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${V-c.height/2-(c.y-(c.top??0))})`);let Z=12,tt=t((ot,ht,yt)=>Array.from({length:Z+1},(Bt,kt)=>{let Ct=Math.PI-kt*Math.PI/Z;return{x:ot*Math.cos(Ct),y:ht+yt*y*Math.sin(Ct)}}),"arc"),at=[...tt(u/2,k,-1),...tt(_/2,w,1).reverse()];return e.intersect=function(ot){return T.polygon(e,at,ot)},n}t(rx,"bucket");var Hf=20,Yf=8,Vw=80,Kw=8;function ix(r){let{themeVariables:e}=d(),{clusterBkg:o,clusterBorder:a}=e;switch(r){case"flow":return{rx:10,fill:"none",stroke:e.flowContainerStroke||e.secondaryBorderColor,strokeWidth:0.75,cssClass:"flow-collapsed"};default:return{rx:Kw,fill:o,stroke:a,cssClass:"collapsed-group"}}}t(ix,"getCollapsedStyle");async function ox(r,e){let o=ix(e.metadata?.containerType),{fill:a,stroke:s}=o,{nodeStyles:n}=E(e),{shapeSvg:c,bbox:l}=await j(r,e,te(e)),{theme:p,themeVariables:m}=d();It(c,e.colorIndex,p,m.borderColorArray);let u=e.padding??8,y=l.height,x=Math.max(l.width+u*2,Vw,e?.width??0),k=Math.max(y+Yf+Hf+u*2,e?.height??0),w=-x/2,_=-k/2,M=-(Yf+Hf)/2,W=c.select(".label");if(W)if(e.useHtmlLabels??Xe(d()))W.attr("transform",`translate(${-l.width/2}, ${-l.height/2+M})`);else W.attr("transform",`translate(0, ${-l.height/2+M})`);let U;if(e.look==="handDrawn"){let ot=v.svg(c),ht=Kt(e,{fill:a,stroke:s,...o.strokeWidth===void 0?{}:{strokeWidth:o.strokeWidth},...a==="none"?{fillWeight:0}:{fillStyle:"solid"}}),yt=ot.path(Tr(w,_,x,k,o.rx),ht);U=c.insert(()=>yt,":first-child"),U.attr("class","basic label-container "+o.cssClass).attr("style",Fe(e.cssStyles))}else if(U=c.insert("rect",":first-child"),U.attr("class","basic label-container "+o.cssClass).attr("style",n).attr("rx",o.rx).attr("ry",o.rx).attr("x",w).attr("y",_).attr("width",x).attr("height",k).attr("fill",a).attr("stroke",s),o.strokeWidth!==void 0)U.attr("stroke-width",o.strokeWidth+"px");let V=_+u+y+Yf;c.append("line").attr("class","collapsed-separator").attr("x1",w+8).attr("y1",V).attr("x2",w+x-8).attr("y2",V).attr("stroke",s).attr("stroke-dasharray","3, 3");let Z=V+Hf/2,tt=2.5,at=10;for(let ot=-1;ot<=1;ot++)c.append("circle").attr("class","collapsed-indicator").attr("cx",ot*at).attr("cy",Z).attr("r",tt).attr("fill",s);return B(e,U),e.calcIntersect=function(ot,ht){return T.rect(ot,ht)},e.intersect=function(ot){return T.rect(e,ot)},c}t(ox,"collapsedGroup");function fi(r,e,o,a){return r.insert("polygon",":first-child").attr("points",a.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+o/2+")")}t(fi,"insertPolygonShape");var Zw=["right","left","up","down"],rd="point",Qw=t((r)=>{let e=new Set;for(let o of r)switch(o){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(o);break}return e},"expandAndDeduplicateDirections"),Jw=t((r)=>Zw.filter((e)=>r.has(e)).join("|")||rd,"getDirectionKey"),By={"right|left|up|down":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:0,y:0},{x:e,y:0},{x:a/2,y:2*o},{x:a-e,y:0},{x:a,y:0},{x:a,y:-r/3},{x:a+2*o,y:-r/2},{x:a,y:-2*r/3},{x:a,y:-r},{x:a-e,y:-r},{x:a/2,y:-r-2*o},{x:e,y:-r},{x:0,y:-r},{x:0,y:-2*r/3},{x:-2*o,y:-r/2},{x:0,y:-r/3}],"right|left|up|down"),"right|left|up":t(({height:r,midpoint:e,width:o})=>[{x:e,y:0},{x:o-e,y:0},{x:o,y:-r/2},{x:o-e,y:-r},{x:e,y:-r},{x:0,y:-r/2}],"right|left|up"),"right|left|down":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:e,y:-r},{x:o-e,y:-r},{x:o,y:0}],"right|left|down"),"right|up|down":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:o,y:-e},{x:o,y:-r+e},{x:0,y:-r}],"right|up|down"),"left|up|down":t(({height:r,midpoint:e,width:o})=>[{x:o,y:0},{x:0,y:-e},{x:0,y:-r+e},{x:o,y:-r}],"left|up|down"),"right|left":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:0},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:0},{x:a,y:-r/2},{x:a-e,y:-r},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r},{x:0,y:-r/2}],"right|left"),"up|down":t(({height:r,midpoint:e,padding:o,width:a})=>[{x:a/2,y:0},{x:0,y:-o},{x:e,y:-o},{x:e,y:-r+o},{x:0,y:-r+o},{x:a/2,y:-r},{x:a,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o},{x:a,y:-o}],"up|down"),"right|up":t(({height:r,midpoint:e,width:o})=>[{x:0,y:0},{x:o,y:-e},{x:0,y:-r}],"right|up"),"right|down":t(({height:r,width:e})=>[{x:0,y:0},{x:e,y:0},{x:0,y:-r}],"right|down"),"left|up":t(({height:r,midpoint:e,width:o})=>[{x:o,y:0},{x:0,y:-e},{x:o,y:-r}],"left|up"),"left|down":t(({height:r,width:e})=>[{x:e,y:0},{x:0,y:0},{x:e,y:-r}],"left|down"),right:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:-o},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:0},{x:a,y:-r/2},{x:a-e,y:-r},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r+o}],"right"),left:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:0},{x:e,y:-o},{x:a-e,y:-o},{x:a-e,y:-r+o},{x:e,y:-r+o},{x:e,y:-r},{x:0,y:-r/2}],"left"),up:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:e,y:-o},{x:e,y:-r+o},{x:0,y:-r+o},{x:a/2,y:-r},{x:a,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o}],"up"),down:t(({height:r,midpoint:e,padding:o,width:a})=>[{x:a/2,y:0},{x:0,y:-o},{x:e,y:-o},{x:e,y:-r+o},{x:a-e,y:-r+o},{x:a-e,y:-o},{x:a,y:-o}],"down"),[rd]:()=>[{x:0,y:0}]},tS=t((r,e,o,a)=>{let s=Qw(r),n=(o.padding??0)/2,c=e.height+4*n,l=c/2,p=a??e.width+2*l+2*n,m=Jw(s);return(By[m]??By[rd])({height:c,midpoint:l,padding:n,width:p})},"getArrowPoints");async function sx(r,e){let o=e,{shapeSvg:a,bbox:s}=await j(r,o,te(o)),n=o.padding??0,c=s.height+2*n,l=c/2,p=s.width+2*l+n,m=o.width??0,y=o.positioned&&(o.widthInColumns??1)>1&&m>p?m:p,x=tS(o.directions??[],s,o,y),k=fi(a,y,c,x);return k.attr("style",o.style??null),B(o,k),o.intersect=function(w){return T.polygon(o,x,w)},a}t(sx,"block_arrow");async function ax(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await j(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=18,y=12,x=Math.max(c.width+m*2,e.width??0,90),k=Math.max(c.height+m*2+u,e.height??0),w=-k/2,{cssStyles:_}=e,M=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let V=v.svg(n).path(Tr(-x/2,w,x,k,y),Kt(e,{}));if(M.node()?.appendChild(V),_)M.attr("style",_)}else M.append("rect").attr("x",-x/2).attr("y",w).attr("width",x).attr("height",k).attr("rx",y).attr("ry",y).attr("style",s);M.append("line").attr("x1",-x/2).attr("y1",w+u).attr("x2",x/2).attr("y2",w+u).attr("style",`stroke:${p};stroke-width:1px`);for(let U=0;U<3;U++)M.append("circle").attr("cx",-x/2+12+U*9).attr("cy",w+u/2).attr("r",2.5).attr("style",`fill:${p};stroke:none`);M.append("rect").attr("class","browser-address-bar").attr("x",-x/2+44).attr("y",w+4).attr("width",Math.max(x-56,10)).attr("height",u-8).attr("rx",3).attr("ry",3).attr("style",`fill:none;stroke:${p};stroke-width:1px;opacity:0.6`),B(e,M);let W=w+u+(k-u)/2;return l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${W-c.height/2-(c.y-(c.top??0))})`),e.intersect=function(U){return T.rect(e,U)},n}t(ax,"browser");var Nl=12;async function nx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?28:s,c=e.look==="neo"?24:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=(e?.width??p.width)+(e.look==="neo"?n*2:n+Nl),u=(e?.height??p.height)+(e.look==="neo"?c*2:c),y=0,x=m,k=-u,w=0,_=[{x:y+Nl,y:k},{x,y:k},{x,y:w},{x:y,y:w},{x:y,y:k+Nl},{x:y+Nl,y:k}],M,{cssStyles:W}=e;if(e.look==="handDrawn"){let U=v.svg(l),V=Kt(e,{}),Z=ye(_),tt=U.path(Z,V);if(M=l.insert(()=>tt,":first-child").attr("transform",`translate(${-m/2}, ${u/2})`),W)M.attr("style",W)}else M=fi(l,m,u,_);if(a)M.attr("style",a);return B(e,M),e.intersect=function(U){return T.polygon(e,_,U)},l}t(nx,"card");function lx(r,e){let{nodeStyles:o}=E(e);e.label="";let a=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:s}=e,n=Math.max(28,e.width??0),c=[{x:0,y:n/2},{x:n/2,y:0},{x:0,y:-n/2},{x:-n/2,y:0}],l=v.svg(a),p=Kt(e,{});if(e.look!=="handDrawn")p.roughness=0,p.fillStyle="solid";let m=ye(c),u=l.path(m,p),y=a.insert(()=>u,":first-child");if(s&&e.look!=="handDrawn")y.selectAll("path").attr("style",s);if(o&&e.look!=="handDrawn")y.selectAll("path").attr("style",o);return e.width=28,e.height=28,e.intersect=function(x){return T.polygon(e,c,x)},a}t(lx,"choice");async function id(r,e,o){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,halfPadding:l}=await j(r,e,te(e),{ignoreMinWidth:!0}),p=16,m=o?.padding??l,u=Math.sqrt(c.width**2+c.height**2)/2,y=e.look==="neo"?u+p:u+m,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(n),_=Kt(e,{}),M=w.circle(0,0,y*2,_);x=n.insert(()=>M,":first-child"),x.attr("class","basic label-container").attr("style",Fe(k))}else x=n.insert("circle",":first-child").attr("class","basic label-container").attr("style",s).attr("r",y).attr("cx",0).attr("cy",0);return B(e,x),e.calcIntersect=function(w,_){let M=w.width/2;return T.circle(w,M,_)},e.intersect=function(w){return i.info("Circle intersect",e,y,w),T.circle(e,y,w)},n}t(id,"circle");async function hx(r,e){let o=e,a=["node",o.cssClasses,o.class].filter(Boolean).join(" "),{shapeSvg:s,bbox:n,halfPadding:c}=await j(r,o,a),l=s.insert("rect",":first-child"),p=o.padding??0,m=o.positioned?o.width??0:n.width+p,u=o.positioned?o.height??0:n.height+p,y=o.positioned?-m/2:-n.width/2-c,x=o.positioned?-u/2:-n.height/2-c;return l.attr("class","basic cluster composite label-container").attr("style",o.style??null).attr("rx",o.rx??null).attr("ry",o.ry??null).attr("x",y).attr("y",x).attr("width",m).attr("height",u),B(o,l),o.intersect=function(k){return T.rect(o,k)},s}t(hx,"composite");async function cx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c,label:l}=await j(r,e,te(e)),p=o?.nodeBorder??o?.lineColor??"currentColor",m=e.padding??12,u=20,y=12,x=Math.max(c.width+m*2,e.width??0,90),k=Math.max(c.height+m*2+u,e.height??0),w=-k/2,{cssStyles:_}=e,M=n.insert("g",":first-child").attr("class","basic label-container");if(e.look==="handDrawn"){let V=v.svg(n).path(Tr(-x/2,w,x,k,y),Kt(e,{}));if(M.node()?.appendChild(V),_)M.attr("style",_)}else M.append("rect").attr("x",-x/2).attr("y",w).attr("width",x).attr("height",k).attr("rx",y).attr("ry",y).attr("style",s);M.append("text").attr("x",-x/2+12).attr("y",w+16).attr("class","console-glyph").attr("style",`font-family:monospace;font-weight:bold;font-size:14px;fill:${p}`).text(">_"),B(e,M);let W=w+u+(k-u)/2;return l.attr("transform",`translate(${-(c.width/2)-(c.x-(c.left??0))}, ${W-c.height/2-(c.y-(c.top??0))})`),e.intersect=function(U){return T.rect(e,U)},n}t(cx,"consoleWindow");function ux(r){let e=Math.cos(Math.PI/4),o=Math.sin(Math.PI/4),a=r*2,s={x:a/2*e,y:a/2*o},n={x:-(a/2)*e,y:a/2*o},c={x:-(a/2)*e,y:-(a/2)*o},l={x:a/2*e,y:-(a/2)*o};return`M ${n.x},${n.y} L ${l.x},${l.y}
|
|
233
|
+
M ${s.x},${s.y} L ${c.x},${c.y}`}t(ux,"createLine");function fx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o,e.label="";let s=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),n=Math.max(30,e?.width??0),{cssStyles:c}=e,l=v.svg(s),p=Kt(e,{});if(e.look!=="handDrawn")p.roughness=0,p.fillStyle="solid";let m=l.circle(0,0,n*2,p),u=ux(n),y=l.path(u,p),x=s.insert(()=>m,":first-child");if(x.insert(()=>y),x.attr("class","outer-path"),c&&e.look!=="handDrawn")x.selectAll("path").attr("style",c);if(a&&e.look!=="handDrawn")x.selectAll("path").attr("style",a);return B(e,x),e.intersect=function(k){return i.info("crossedCircle intersect",e,{radius:n,point:k}),T.circle(e,n,k)},s}t(fx,"crossedCircle");function vi(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(vi,"generateCirclePoints");async function dx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+l,u=n.height+p,y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...vi(m/2,-u/2,y,30,-90,0),{x:-m/2-y,y},...vi(m/2+y*2,-y,y,20,-180,-270),...vi(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:-u/2},...vi(m/2,u/2,y,20,0,90)],w=[{x:m/2,y:-u/2-y},{x:-m/2,y:-u/2-y},...vi(m/2,-u/2,y,20,-90,0),{x:-m/2-y,y:-y},...vi(m/2+m*0.1,-y,y,20,-180,-270),...vi(m/2+m*0.1,y,y,20,-90,-180),{x:-m/2-y,y:u/2},...vi(m/2,u/2,y,20,0,90),{x:-m/2,y:u/2+y},{x:m/2,y:u/2+y}],_=v.svg(s),M=Kt(e,{fill:"none"});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let U=ye(k).replace("Z",""),V=_.path(U,M),Z=ye(w),tt=_.path(Z,{...M}),at=s.insert("g",":first-child");if(at.insert(()=>tt,":first-child").attr("stroke-opacity",0),at.insert(()=>V,":first-child"),at.attr("class","text"),x&&e.look!=="handDrawn")at.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")at.selectAll("path").attr("style",a);return at.attr("transform",`translate(${y}, 0)`),c.attr("transform",`translate(${-m/2+y-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,w,ot)},s}t(dx,"curlyBraceLeft");function Fi(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:k,y:w})}return c}t(Fi,"generateCirclePoints");async function px(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+(e.look==="neo"?l*2:l),u=n.height+(e.look==="neo"?p*2:p),y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...Fi(m/2,-u/2,y,20,-90,0),{x:m/2+y,y:-y},...Fi(m/2+y*2,-y,y,20,-180,-270),...Fi(m/2+y*2,y,y,20,-90,-180),{x:m/2+y,y:u/2},...Fi(m/2,u/2,y,20,0,90)],w=[{x:-m/2,y:-u/2-y},{x:m/2,y:-u/2-y},...Fi(m/2,-u/2,y,20,-90,0),{x:m/2+y,y:-y},...Fi(m/2+y*2,-y,y,20,-180,-270),...Fi(m/2+y*2,y,y,20,-90,-180),{x:m/2+y,y:u/2},...Fi(m/2,u/2,y,20,0,90),{x:m/2,y:u/2+y},{x:-m/2,y:u/2+y}],_=v.svg(s),M=Kt(e,{fill:"none"});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let U=ye(k).replace("Z",""),V=_.path(U,M),Z=ye(w),tt=_.path(Z,{...M}),at=s.insert("g",":first-child");if(at.insert(()=>tt,":first-child").attr("stroke-opacity",0),at.insert(()=>V,":first-child"),at.attr("class","text"),x&&e.look!=="handDrawn")at.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")at.selectAll("path").attr("style",a);return at.attr("transform",`translate(${-y}, 0)`),c.attr("transform",`translate(${-m/2+(e.padding??0)/2-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,w,ot)},s}t(px,"curlyBraceRight");function sr(r,e,o,a=100,s=0,n=180){let c=[],l=s*Math.PI/180,u=(n*Math.PI/180-l)/(a-1);for(let y=0;y<a;y++){let x=l+y*u,k=r+o*Math.cos(x),w=e+o*Math.sin(x);c.push({x:-k,y:-w})}return c}t(sr,"generateCirclePoints");async function gx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.look==="neo"?18:e.padding??0,p=e.look==="neo"?12:e.padding??0,m=n.width+(e.look==="neo"?l*2:l),u=n.height+(e.look==="neo"?p*2:p),y=Math.max(5,u*0.1),{cssStyles:x}=e,k=[...sr(m/2,-u/2,y,30,-90,0),{x:-m/2-y,y},...sr(m/2+y*2,-y,y,20,-180,-270),...sr(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:-u/2},...sr(m/2,u/2,y,20,0,90)],w=[...sr(-m/2+y+y/2,-u/2,y,20,-90,-180),{x:m/2-y/2,y},...sr(-m/2-y/2,-y,y,20,0,90),...sr(-m/2-y/2,y,y,20,-90,0),{x:m/2-y/2,y:-y},...sr(-m/2+y+y/2,u/2,y,30,-180,-270)],_=[{x:m/2,y:-u/2-y},{x:-m/2,y:-u/2-y},...sr(m/2,-u/2,y,20,-90,0),{x:-m/2-y,y:-y},...sr(m/2+y*2,-y,y,20,-180,-270),...sr(m/2+y*2,y,y,20,-90,-180),{x:-m/2-y,y:u/2},...sr(m/2,u/2,y,20,0,90),{x:-m/2,y:u/2+y},{x:m/2-y-y/2,y:u/2+y},...sr(-m/2+y+y/2,-u/2,y,20,-90,-180),{x:m/2-y/2,y},...sr(-m/2-y/2,-y,y,20,0,90),...sr(-m/2-y/2,y,y,20,-90,0),{x:m/2-y/2,y:-y},...sr(-m/2+y+y/2,u/2,y,30,-180,-270)],M=v.svg(s),W=Kt(e,{fill:"none"});if(e.look!=="handDrawn")W.roughness=0,W.fillStyle="solid";let V=ye(k).replace("Z",""),Z=M.path(V,W),at=ye(w).replace("Z",""),ot=M.path(at,W),ht=ye(_),yt=M.path(ht,{...W}),Bt=s.insert("g",":first-child");if(Bt.insert(()=>yt,":first-child").attr("stroke-opacity",0),Bt.insert(()=>Z,":first-child"),Bt.insert(()=>ot,":first-child"),Bt.attr("class","text"),x&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",x);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return Bt.attr("transform",`translate(${y-y/4}, 0)`),c.attr("transform",`translate(${-m/2+(e.padding??0)/2-(n.x-(n.left??0))},${-u/2+(e.padding??0)/2-(n.y-(n.top??0))})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,_,kt)},s}t(gx,"curlyBraces");async function mx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=20,p=5,{shapeSvg:m,bbox:u}=await j(r,e,te(e)),y=Math.max(p,u.height+c*2,e?.height??0),x=y/2,k=x-Math.sqrt(Math.max(0,x**2-(u.height/2)**2)),w=Math.max(y/4,k),_=Math.max(l,u.width+n*2+w*2,(u.width+n*2)*1.25,e?.width??0),{cssStyles:M}=e,W=v.svg(m),U=Kt(e,{});if(e.look!=="handDrawn")U.roughness=0,U.fillStyle="solid";let V=_,Z=y,tt=V-x,at=Z/4,ot=[{x:tt,y:0},{x:at,y:0},{x:0,y:Z/2},{x:at,y:Z},{x:tt,y:Z},...ci(-tt,-Z/2,x,50,270,90)],ht=ye(ot),yt=W.path(ht,U),Bt=m.insert(()=>yt,":first-child");if(Bt.attr("class","basic label-container outer-path"),M&&e.look!=="handDrawn")Bt.selectChildren("path").attr("style",M);if(a&&e.look!=="handDrawn")Bt.selectChildren("path").attr("style",a);return Bt.attr("transform",`translate(${-_/2}, ${-y/2})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,ot,kt)},m}t(mx,"curvedTrapezoid");async function yx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.padding??20,p=Math.max(n.width+l*2,e.width??0,100),m=Math.min(Math.max(p*0.23,16),56),u=m*0.27,y=Math.max(n.height+l*2,e.height?e.height-(2*m-u):0),x=Math.min(p*0.177,y*0.45),k=y+2*m-u,w=-k/2,_=w+2*m-u,M=s.insert("g",":first-child").attr("class","basic label-container"),{cssStyles:W}=e;if(e.look==="handDrawn"){let ht=v.svg(s),yt=Kt(e,{}),Bt=ht.path(Tr(-p/2,_,p,y,x),yt),kt=ht.circle(0,w+m,m*2,yt);if(M.insert(()=>kt,":first-child"),M.insert(()=>Bt,":first-child"),W)M.attr("style",W)}else M.append("rect").attr("x",-p/2).attr("y",_).attr("width",p).attr("height",y).attr("rx",x).attr("ry",x).attr("style",a),M.append("circle").attr("cx",0).attr("cy",w+m).attr("r",m).attr("style",a);B(e,M);let U=_+y/2;c.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${U-n.height/2-(n.y-(n.top??0))})`);let V=w+m,Z=Math.asin(Math.min(1,(_-V)/m))*180/Math.PI,tt=24,ot=[...ci(0,-V,m,tt,180+Z,-Z),...ci(-(-p/2+x),-(_+x),x,12,90,0),...ci(-(-p/2+x),-(k/2-x),x,12,360,270),...ci(-(p/2-x),-(k/2-x),x,12,270,180),...ci(-(p/2-x),-(_+x),x,12,180,90)];return e.intersect=function(ht){return T.polygon(e,ot,ht)},s}t(yx,"person");var eS=t((r,e,o,a,s,n)=>[`M${r},${e+n}`,`a${s},${n} 0,0,0 ${o},0`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`].join(" "),"createCylinderPathD"),rS=t((r,e,o,a,s,n)=>[`M${r},${e+n}`,`M${r+o},${e+n}`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`].join(" "),"createOuterCylinderPathD"),iS=t((r,e,o,a,s,n)=>[`M${r-o/2},${-a/2}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD"),vy=8,Ly=8;async function xx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?24:s,c=e.look==="neo"?24:s,l=e.width??0;if(e.width){if(e.width=e.width-c,e.width<Ly)e.width=Ly}if(e.height){let U=l/2/(2.5+l/50);if(e.height=e.height-n-U*3,e.height<vy)e.height=vy}let{shapeSvg:p,bbox:m,label:u}=await j(r,e,te(e)),y=Math.max(e.width??0,m.width)+c,x=y/2,k=x/(2.5+y/50),w=Math.max(e.height??0,m.height)+n+k,_,{cssStyles:M}=e;if(e.look==="handDrawn"){let W=v.svg(p),U=rS(0,0,y,w,x,k),V=iS(0,k,y,w,x,k),Z=Kt(e,{}),tt=W.path(U,Z),at=W.path(V,Kt(e,{fill:"none"}));if(_=p.insert(()=>at,":first-child"),_=p.insert(()=>tt,":first-child"),_.attr("class","basic label-container"),M)_.attr("style",M)}else{let W=eS(0,0,y,w,x,k);_=p.insert("path",":first-child").attr("d",W).attr("class","basic label-container outer-path").attr("style",Fe(M)).attr("style",a)}return _.attr("label-offset-y",k),_.attr("transform",`translate(${-y/2}, ${-(w/2+k)})`),B(e,_),u.attr("transform",`translate(${-(m.width/2)-(m.x-(m.left??0))}, ${-(m.height/2)+(e.padding??0)/1.5-(m.y-(m.top??0))})`),e.intersect=function(W){let U=T.rect(e,W),V=U.x-(e.x??0);if(x!=0&&(Math.abs(V)<(e.width??0)/2||Math.abs(V)==(e.width??0)/2&&Math.abs(U.y-(e.y??0))>(e.height??0)/2-k)){let Z=k*k*(1-V*V/(x*x));if(Z>0)Z=Math.sqrt(Z);if(Z=k-Z,W.y-(e.y??0)>0)Z=-Z;U.y+=Z}return U},p}t(xx,"cylinder");async function Ss(r,e,o){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{shapeSvg:n,bbox:c}=await j(r,e,te(e)),l=Math.max(c.width+o.labelPaddingX*2,e?.width||0),p=Math.max(c.height+o.labelPaddingY*2,e?.height||0),m=-l/2,u=-p/2,y,{rx:x,ry:k}=e,{cssStyles:w}=e;if(o?.rx&&o.ry)x=o.rx,k=o.ry;if(e.look==="handDrawn"){let _=v.svg(n),M=Kt(e,{}),W=x||k?_.path(Tr(m,u,l,p,x||0),M):_.rectangle(m,u,l,p,M);y=n.insert(()=>W,":first-child"),y.attr("class","basic label-container").attr("style",Fe(w))}else y=n.insert("rect",":first-child"),y.attr("class","basic label-container").attr("style",s).attr("rx",Fe(x)).attr("ry",Fe(k)).attr("x",m).attr("y",u).attr("width",l).attr("height",p);return B(e,y,e.look==="handDrawn"?void 0:{width:l,height:p}),e.calcIntersect=function(_,M){return T.rect(_,M)},e.intersect=function(_){return T.rect(e,_)},n}t(Ss,"drawRect");async function Cx(r,e){let{cssClasses:o,labelPaddingX:a,labelPaddingY:s,padding:n,width:c,height:l}=e,p={rx:0,ry:0,classes:o??"",labelPaddingX:a??(n??0)*2,labelPaddingY:s??n??0},m=await Ss(r,e,p);if(e.look==="handDrawn"){let k=v.svg(m),w=Kt(e,{}),_=m.select(".basic.label-container > path:nth-child(2)"),M=_.node();if(!M)return m;let W=null;if(M instanceof SVGGraphicsElement)W=M.getBBox();else return m;return m.insert(()=>k.line(W.x,W.y,W.x+W.width,W.y,w),".basic.label-container g.label"),m.insert(()=>k.line(W.x,W.y+W.height,W.x+W.width,W.y+W.height,w),".basic.label-container g.label"),_.remove(),m}let u=m.select(".basic.label-container"),y=(Number(u.attr("width"))||c)??0,x=(Number(u.attr("height"))||l)??0;if(y>0&&x>0)u.attr("stroke-dasharray",`${y} ${x}`);return m}t(Cx,"datastore");async function bx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.look==="neo"?16:e.padding??0,n=e.look==="neo"?16:e.padding??0,{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=l.width+s,u=l.height+n,y=u*0.2,x=-m/2,k=-u/2-y/2,{cssStyles:w}=e,_=v.svg(c),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let W=[{x,y:k+y},{x:-x,y:k+y},{x:-x,y:-k},{x,y:-k},{x,y:k},{x:-x,y:k},{x:-x,y:k+y}],U=_.polygon(W.map((Z)=>[Z.x,Z.y]),M),V=c.insert(()=>U,":first-child");if(V.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")V.selectAll("path").attr("style",w);if(a&&e.look!=="handDrawn")V.selectAll("path").attr("style",a);return p.attr("transform",`translate(${x+(e.padding??0)/2-(l.x-(l.left??0))}, ${k+y+(e.padding??0)/2-(l.y-(l.top??0))})`),B(e,V),e.intersect=function(Z){return T.rect(e,Z)},c}t(bx,"dividedRectangle");async function kx(r,e){let{labelStyles:o,nodeStyles:a}=E(e),s=e.look==="neo"?12:5;e.labelStyle=o;let n=e.padding??0,c=e.look==="neo"?16:n,{shapeSvg:l,bbox:p}=await j(r,e,te(e),{ignoreMinWidth:!0}),m=Math.sqrt(p.width**2+p.height**2)/2,u=(e?.width?e?.width/2:m)+(c??0),y=u+s,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{roughness:0.2,strokeWidth:2.5}),M=Kt(e,{roughness:0.2,strokeWidth:1.5}),W=w.circle(0,0,y*2,_),U=w.circle(0,0,u*2,M);x=l.insert("g",":first-child"),x.attr("class",Fe(e.cssClasses)).attr("style",Fe(k)),x.node()?.appendChild(W),x.node()?.appendChild(U)}else{x=l.insert("g",":first-child");let w=x.insert("circle",":first-child"),_=x.insert("circle");x.attr("class","basic label-container").attr("style",a),w.attr("class","outer-circle").attr("style",a).attr("r",y).attr("cx",0).attr("cy",0),_.attr("class","inner-circle").attr("style",a).attr("r",u).attr("cx",0).attr("cy",0)}return B(e,x),e.intersect=function(w){return i.info("DoubleCircle intersect",e,y,w),T.circle(e,y,w)},l}t(kx,"doublecircle");async function wx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c}=await j(r,e,te(e)),{theme:l,themeVariables:p}=d();It(s,e.colorIndex,l,p.borderColorArray);let m=c??10,u=n.width/2+m*2,y=n.height/2+m*2,x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(s),_=Kt(e,{}),M=w.ellipse(0,0,u*2,y*2,_);if(x=s.insert(()=>M,":first-child"),x.attr("class","basic label-container"),k)x.attr("style",k)}else x=s.insert("ellipse",":first-child").attr("class","basic label-container").attr("style",a).attr("rx",u).attr("ry",y).attr("cx",0).attr("cy",0);return e.width=u*2,e.height=y*2,B(e,x),e.calcIntersect=function(w,_){let M=w.width/2,W=w.height/2;return T.ellipse(w,M,W,_)},e.intersect=function(w){return T.ellipse(e,u,y,w)},s}t(wx,"usecaseEllipse");function Sx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.label="",e.labelStyle=a;let n=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),c=7,{cssStyles:l}=e,p=v.svg(n),{nodeBorder:m}=o,u=Kt(e,{fillStyle:"solid"});if(e.look!=="handDrawn")u.roughness=0;let y=p.circle(0,0,c*2,u),x=n.insert(()=>y,":first-child");if(x.selectAll("path").attr("style",`fill: ${m} !important;`),l&&l.length>0&&e.look!=="handDrawn")x.selectAll("path").attr("style",l);if(s&&e.look!=="handDrawn")x.selectAll("path").attr("style",s);return B(e,x),e.intersect=function(k){return i.info("filledCircle intersect",e,{radius:c,point:k}),T.circle(e,c,k)},n}t(Sx,"filledCircle");var Fy=10,Ay=10;async function Tx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?s*2:s;if(e.width||e.height){if(e.height=e?.height??0,e.height<Fy)e.height=Fy;if(e.width=(e?.width??0)-n-n/2,e.width<Ay)e.width=Ay}let{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=(e?.width?e?.width:l.width)+(n??0),u=e?.height?e?.height:m+l.height,y=u,x=[{x:0,y:-u},{x:y,y:-u},{x:y/2,y:0}],{cssStyles:k}=e,w=v.svg(c),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=ye(x),W=w.path(M,_),U=c.insert(()=>W,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`).attr("class","outer-path");if(k&&e.look!=="handDrawn")U.selectChildren("path").attr("style",k);if(a&&e.look!=="handDrawn")U.selectChildren("path").attr("style",a);return e.width=m,e.height=u,B(e,U),p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))}, ${-u/2+(e.padding??0)/2+(l.y-(l.top??0))})`),e.intersect=function(V){return i.info("Triangle intersect",e,x,V),T.polygon(e,x,V)},c}t(Tx,"flippedTriangle");async function _x(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.padding??12,p=Math.max(n.width+l*2,e.width??0,90),m=n.height+l*2,u=Math.max(Math.min(m*0.16,14),8),y=Math.max(m+u,e.height??0),x=y-u,k=Math.max(p*0.38,28),w=-y/2,_=[{x:-p/2,y:w},{x:-p/2+k,y:w},{x:-p/2+k,y:w+u},{x:p/2,y:w+u},{x:p/2,y:y/2},{x:-p/2,y:y/2}],M=[`M${_[0].x},${_[0].y}`,..._.slice(1).map((Z)=>`L${Z.x},${Z.y}`),"Z"].join(" "),{cssStyles:W}=e,U;if(e.look==="handDrawn"){let tt=v.svg(s).path(M,Kt(e,{}));if(U=s.insert(()=>tt,":first-child").attr("class","basic label-container"),W)U.attr("style",W)}else U=s.insert("path",":first-child").attr("d",M).attr("class","basic label-container").attr("style",a);if(e.look==="handDrawn")B(e,U);else B(e,U,{width:p,height:y});let V=w+u+x/2;return c.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${V-n.height/2-(n.y-(n.top??0))})`),e.intersect=function(Z){return T.polygon(e,_,Z)},s}t(_x,"folder");function Bx(r,e,{dir:o,config:{state:a,themeVariables:s}}){let{nodeStyles:n}=E(e);e.label="";let c=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:l}=e,p=Math.max(70,e?.width??0),m=Math.max(10,e?.height??0);if(o==="LR"||o==="RL")p=Math.max(10,e?.width??0),m=Math.max(70,e?.height??0);let u=-1*p/2,y=-1*m/2,x=v.svg(c),k=Kt(e,{stroke:s.lineColor,fill:s.lineColor});if(e.look!=="handDrawn")k.roughness=0,k.fillStyle="solid";let w=x.rectangle(u,y,p,m,k),_=c.insert(()=>w,":first-child");if(l&&e.look!=="handDrawn")_.selectAll("path").attr("style",l);if(n&&e.look!=="handDrawn")_.selectAll("path").attr("style",n);B(e,_);let M=a?.padding??0;if(e.width&&e.height)e.width+=M/2||0,e.height+=M/2||0;return e.intersect=function(W){return T.rect(e,W)},c}t(Bx,"forkJoin");async function vx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=15,n=10,c=e.look==="neo"?16:e.padding??0,l=e.look==="neo"?12:e.padding??0;if(e.width||e.height){if(e.height=(e?.height??0)-l*2,e.height<n)e.height=n;if(e.width=(e?.width??0)-c*2,e.width<s)e.width=s}let{shapeSvg:p,bbox:m}=await j(r,e,te(e)),u=(e?.height?e?.height:Math.max(n,m.height))+l*2,y=u/2,x=y-Math.sqrt(Math.max(0,y**2-(m.height/2)**2)),k=(e?.width?e?.width:Math.max(s,m.width)+x*2)+c*2,{cssStyles:w}=e,_=v.svg(p),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let W=[{x:-k/2,y:-u/2},{x:k/2-y,y:-u/2},...ci(-k/2+y,0,y,50,90,270),{x:k/2-y,y:u/2},{x:-k/2,y:u/2}],U=ye(W),V=_.path(U,M),Z=p.insert(()=>V,":first-child");if(Z.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")Z.selectChildren("path").attr("style",w);if(a&&e.look!=="handDrawn")Z.selectChildren("path").attr("style",a);return B(e,Z),e.intersect=function(tt){return i.info("Pill intersect",e,{radius:y,point:tt}),T.polygon(e,W,tt)},p}t(vx,"halfRoundedRectangle");var oS=t((r,e,o,a,s)=>[`M${r+s},${e}`,`L${r+o-s},${e}`,`L${r+o},${e-a/2}`,`L${r+o-s},${e-a}`,`L${r+s},${e-a}`,`L${r},${e-a/2}`,"Z"].join(" "),"createHexagonPathD");async function Lx(r,e){let{labelStyles:o,nodeStyles:a}=E(e),s=e.look==="neo"?3.5:4;e.labelStyle=o;let n=e.padding??0,c=70,l=32,p=e.look==="neo"?c:n,m=e.look==="neo"?l:n;if(e.width||e.height){let V=(e.height??0)/s;e.width=(e?.width??0)-2*V-m,e.height=(e.height??0)-p}let{shapeSvg:u,bbox:y}=await j(r,e,te(e)),x=(e?.height?e?.height:y.height)+p,k=x/s,w=(e?.width?e?.width:y.width)+2*k+m,_=[{x:k,y:0},{x:w-k,y:0},{x:w,y:-x/2},{x:w-k,y:-x},{x:k,y:-x},{x:0,y:-x/2}],M,{cssStyles:W}=e;if(e.look==="handDrawn"){let U=v.svg(u),V=Kt(e,{}),Z=oS(0,0,w,x,k),tt=U.path(Z,V);if(M=u.insert(()=>tt,":first-child").attr("transform",`translate(${-w/2}, ${x/2})`),W)M.attr("style",W)}else M=fi(u,w,x,_);if(a)M.attr("style",a);return e.width=w,e.height=x,B(e,M),e.intersect=function(U){return T.polygon(e,_,U)},u}t(Lx,"hexagon");async function Fx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.label="",e.labelStyle=o;let{shapeSvg:s}=await j(r,e,te(e)),n=Math.max(30,e?.width??0),c=Math.max(30,e?.height??0),{cssStyles:l}=e,p=v.svg(s),m=Kt(e,{});if(e.look!=="handDrawn")m.roughness=0,m.fillStyle="solid";let u=[{x:0,y:0},{x:n,y:0},{x:0,y:c},{x:n,y:c}],y=ye(u),x=p.path(y,m),k=s.insert(()=>x,":first-child");if(k.attr("class","basic label-container outer-path"),l&&e.look!=="handDrawn")k.selectChildren("path").attr("style",l);if(a&&e.look!=="handDrawn")k.selectChildren("path").attr("style",a);return k.attr("transform",`translate(${-n/2}, ${-c/2})`),B(e,k),e.intersect=function(w){return i.info("Pill intersect",e,{points:u}),T.polygon(e,u,w)},s}t(Fx,"hourglass");async function Ax(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,label:y}=await j(r,e,"icon-shape default"),x=e.pos==="t",k=l,w=l,{nodeBorder:_}=o,{stylesMap:M}=ai(e),W=-w/2,U=-k/2,V=e.label?8:0,Z=v.svg(m),tt=Kt(e,{stroke:"none",fill:"none"});if(e.look!=="handDrawn")tt.roughness=0,tt.fillStyle="solid";let at=Z.rectangle(W,U,w,k,tt),ot=Math.max(w,u.width),ht=k+u.height+V,yt=Z.rectangle(-ot/2,-ht/2,ot,ht,{...tt,fill:"transparent",stroke:"none"}),Bt=m.insert(()=>at,":first-child"),kt=m.insert(()=>yt);if(e.icon){let Ct=m.append("g");Ct.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let rt=Ct.node().getBBox(),{width:it,height:gt,x:et,y:wt}=rt;Ct.attr("transform",`translate(${-it/2-et},${x?u.height/2+V/2-gt/2-wt:-u.height/2-V/2-gt/2-wt})`),Ct.attr("style",`color: ${M.get("stroke")??_};`)}return y.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${x?-ht/2:ht/2-u.height})`),Bt.attr("transform",`translate(0,${x?u.height/2+V/2:-u.height/2-V/2})`),B(e,kt),e.intersect=function(Ct){if(i.info("iconSquare intersect",e,Ct),!e.label)return T.rect(e,Ct);let rt=e.x??0,it=e.y??0,gt=e.height??0,et=[];if(x)et=[{x:rt-u.width/2,y:it-gt/2},{x:rt+u.width/2,y:it-gt/2},{x:rt+u.width/2,y:it-gt/2+u.height+V},{x:rt+w/2,y:it-gt/2+u.height+V},{x:rt+w/2,y:it+gt/2},{x:rt-w/2,y:it+gt/2},{x:rt-w/2,y:it-gt/2+u.height+V},{x:rt-u.width/2,y:it-gt/2+u.height+V}];else et=[{x:rt-w/2,y:it-gt/2},{x:rt+w/2,y:it-gt/2},{x:rt+w/2,y:it-gt/2+k},{x:rt+u.width/2,y:it-gt/2+k},{x:rt+u.width/2/2,y:it+gt/2},{x:rt-u.width/2,y:it+gt/2},{x:rt-u.width/2,y:it-gt/2+k},{x:rt-w/2,y:it-gt/2+k}];return T.polygon(e,et,Ct)},m}t(Ax,"icon");async function Mx(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,label:y}=await j(r,e,"icon-shape default"),x=20,k=e.label?8:0,w=e.pos==="t",{nodeBorder:_,mainBkg:M}=o,{stylesMap:W}=ai(e),U=v.svg(m),V=Kt(e,{});if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let Z=W.get("fill");V.stroke=Z??M;let tt=m.append("g");if(e.icon)tt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let at=tt.node().getBBox(),{width:ot,height:ht,x:yt,y:Bt}=at,kt=Math.max(ot,ht)*Math.SQRT2+x*2,Ct=U.circle(0,0,kt,V),rt=Math.max(kt,u.width),it=kt+u.height+k,gt=U.rectangle(-rt/2,-it/2,rt,it,{...V,fill:"transparent",stroke:"none"}),et=m.insert(()=>Ct,":first-child"),wt=m.insert(()=>gt);return tt.attr("transform",`translate(${-ot/2-yt},${w?u.height/2+k/2-ht/2-Bt:-u.height/2-k/2-ht/2-Bt})`),tt.attr("style",`color: ${W.get("stroke")??_};`),y.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${w?-it/2:it/2-u.height})`),et.attr("transform",`translate(0,${w?u.height/2+k/2:-u.height/2-k/2})`),B(e,wt),e.intersect=function(vt){return i.info("iconSquare intersect",e,vt),T.rect(e,vt)},m}t(Mx,"iconCircle");async function Ex(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,halfPadding:y,label:x}=await j(r,e,"icon-shape default"),k=e.pos==="t",w=l+y*2,_=l+y*2,{nodeBorder:M,mainBkg:W}=o,{stylesMap:U}=ai(e),V=-_/2,Z=-w/2,tt=e.label?8:0,at=v.svg(m),ot=Kt(e,{});if(e.look!=="handDrawn")ot.roughness=0,ot.fillStyle="solid";let ht=U.get("fill");ot.stroke=ht??W;let yt=at.path(Tr(V,Z,_,w,5),ot),Bt=Math.max(_,u.width),kt=w+u.height+tt,Ct=at.rectangle(-Bt/2,-kt/2,Bt,kt,{...ot,fill:"transparent",stroke:"none"}),rt=m.insert(()=>yt,":first-child").attr("class","icon-shape2"),it=m.insert(()=>Ct);if(e.icon){let gt=m.append("g");gt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let et=gt.node().getBBox(),{width:wt,height:vt,x:Xt,y:jt}=et;gt.attr("transform",`translate(${-wt/2-Xt},${k?u.height/2+tt/2-vt/2-jt:-u.height/2-tt/2-vt/2-jt})`),gt.attr("style",`color: ${U.get("stroke")??M};`)}return x.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${k?-kt/2:kt/2-u.height})`),rt.attr("transform",`translate(0,${k?u.height/2+tt/2:-u.height/2-tt/2})`),B(e,it),e.intersect=function(gt){if(i.info("iconSquare intersect",e,gt),!e.label)return T.rect(e,gt);let et=e.x??0,wt=e.y??0,vt=e.height??0,Xt=[];if(k)Xt=[{x:et-u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt+vt/2},{x:et-_/2,y:wt+vt/2},{x:et-_/2,y:wt-vt/2+u.height+tt},{x:et-u.width/2,y:wt-vt/2+u.height+tt}];else Xt=[{x:et-_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2+w},{x:et+u.width/2,y:wt-vt/2+w},{x:et+u.width/2/2,y:wt+vt/2},{x:et-u.width/2,y:wt+vt/2},{x:et-u.width/2,y:wt-vt/2+w},{x:et-_/2,y:wt-vt/2+w}];return T.polygon(e,Xt,gt)},m}t(Ex,"iconRounded");async function Ox(r,e,{config:{themeVariables:o,flowchart:a}}){let{labelStyles:s}=E(e);e.labelStyle=s;let n=e.assetHeight??48,c=e.assetWidth??48,l=Math.max(n,c),p=a?.wrappingWidth;e.width=Math.max(l,p??0);let{shapeSvg:m,bbox:u,halfPadding:y,label:x}=await j(r,e,"icon-shape default"),k=e.pos==="t",w=l+y*2,_=l+y*2,{nodeBorder:M,mainBkg:W}=o,{stylesMap:U}=ai(e),V=-_/2,Z=-w/2,tt=e.label?8:0,at=v.svg(m),ot=Kt(e,{});if(e.look!=="handDrawn")ot.roughness=0,ot.fillStyle="solid";let ht=U.get("fill");ot.stroke=ht??W;let yt=at.path(Tr(V,Z,_,w,0.1),ot),Bt=Math.max(_,u.width),kt=w+u.height+tt,Ct=at.rectangle(-Bt/2,-kt/2,Bt,kt,{...ot,fill:"transparent",stroke:"none"}),rt=m.insert(()=>yt,":first-child"),it=m.insert(()=>Ct);if(e.icon){let gt=m.append("g");gt.html(`<g>${await Gt(e.icon,{height:l,width:l,fallbackPrefix:""})}</g>`);let et=gt.node().getBBox(),{width:wt,height:vt,x:Xt,y:jt}=et;gt.attr("transform",`translate(${-wt/2-Xt},${k?u.height/2+tt/2-vt/2-jt:-u.height/2-tt/2-vt/2-jt})`),gt.attr("style",`color: ${U.get("stroke")??M};`)}return x.attr("transform",`translate(${-u.width/2-(u.x-(u.left??0))},${k?-kt/2:kt/2-u.height})`),rt.attr("transform",`translate(0,${k?u.height/2+tt/2:-u.height/2-tt/2})`),B(e,it),e.intersect=function(gt){if(i.info("iconSquare intersect",e,gt),!e.label)return T.rect(e,gt);let et=e.x??0,wt=e.y??0,vt=e.height??0,Xt=[];if(k)Xt=[{x:et-u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2},{x:et+u.width/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt-vt/2+u.height+tt},{x:et+_/2,y:wt+vt/2},{x:et-_/2,y:wt+vt/2},{x:et-_/2,y:wt-vt/2+u.height+tt},{x:et-u.width/2,y:wt-vt/2+u.height+tt}];else Xt=[{x:et-_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2},{x:et+_/2,y:wt-vt/2+w},{x:et+u.width/2,y:wt-vt/2+w},{x:et+u.width/2/2,y:wt+vt/2},{x:et-u.width/2,y:wt+vt/2},{x:et-u.width/2,y:wt-vt/2+w},{x:et-_/2,y:wt-vt/2+w}];return T.polygon(e,Xt,gt)},m}t(Ox,"iconSquare");async function Ix(r,e,{config:{flowchart:o}}){let a=new Image;a.src=e?.img??"",await a.decode();let s=Number(a.naturalWidth.toString().replace("px","")),n=Number(a.naturalHeight.toString().replace("px",""));e.imageAspectRatio=s/n;let{labelStyles:c}=E(e);e.labelStyle=c;let l=o?.wrappingWidth;e.defaultWidth=o?.wrappingWidth;let p=Math.max(e.label?l??0:0,e?.assetWidth??s),m=e.constraint==="on"?e?.assetHeight?e.assetHeight*e.imageAspectRatio:p:p,u=e.constraint==="on"?m/e.imageAspectRatio:e?.assetHeight??n;e.width=Math.max(m,l??0);let{shapeSvg:y,bbox:x,label:k}=await j(r,e,"image-shape default"),w=e.pos==="t",_=-m/2,M=-u/2,W=e.label?8:0,U=v.svg(y),V=Kt(e,{});if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let Z=U.rectangle(_,M,m,u,V),tt=Math.max(m,x.width),at=u+x.height+W,ot=U.rectangle(-tt/2,-at/2,tt,at,{...V,fill:"none",stroke:"none"}),ht=y.insert(()=>Z,":first-child"),yt=y.insert(()=>ot);if(e.img){let Bt=y.append("image");Bt.attr("href",e.img),Bt.attr("width",m),Bt.attr("height",u),Bt.attr("preserveAspectRatio","none"),Bt.attr("transform",`translate(${-m/2},${w?at/2-u:-at/2})`)}return k.attr("transform",`translate(${-x.width/2-(x.x-(x.left??0))},${w?-u/2-x.height/2-W/2:u/2-x.height/2+W/2})`),ht.attr("transform",`translate(0,${w?x.height/2+W/2:-x.height/2-W/2})`),B(e,yt),e.intersect=function(Bt){if(i.info("iconSquare intersect",e,Bt),!e.label)return T.rect(e,Bt);let kt=e.x??0,Ct=e.y??0,rt=e.height??0,it=[];if(w)it=[{x:kt-x.width/2,y:Ct-rt/2},{x:kt+x.width/2,y:Ct-rt/2},{x:kt+x.width/2,y:Ct-rt/2+x.height+W},{x:kt+m/2,y:Ct-rt/2+x.height+W},{x:kt+m/2,y:Ct+rt/2},{x:kt-m/2,y:Ct+rt/2},{x:kt-m/2,y:Ct-rt/2+x.height+W},{x:kt-x.width/2,y:Ct-rt/2+x.height+W}];else it=[{x:kt-m/2,y:Ct-rt/2},{x:kt+m/2,y:Ct-rt/2},{x:kt+m/2,y:Ct-rt/2+u},{x:kt+x.width/2,y:Ct-rt/2+u},{x:kt+x.width/2/2,y:Ct+rt/2},{x:kt-x.width/2,y:Ct+rt/2},{x:kt-x.width/2,y:Ct-rt/2+u},{x:kt-m/2,y:Ct-rt/2+u}];return T.polygon(e,it,Bt)},y}t(Ix,"imageSquare");async function $x(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=Math.max(p.height+n*2,e.height??0),u=Math.max(p.width+c*2,(e.width??0)-m),y=[{x:0,y:0},{x:u,y:0},{x:u+3*m/6,y:-m},{x:-3*m/6,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),W=w.path(M,_);if(x=l.insert(()=>W,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t($x,"inv_trapezoid");async function Dx(r,e){let{shapeSvg:o,bbox:a,label:s}=await j(r,e,"label"),n=o.insert("rect",":first-child"),c=0.1,l=0.1;return n.attr("width",0.1).attr("height",0.1),o.attr("class","label edgeLabel"),s.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),B(e,n),e.intersect=function(p){return T.rect(e,p)},o}t(Dx,"labelRect");async function Px(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=Math.max(p.height+n,e.height??0),u=Math.max(p.width+c,(e.width??0)-m),y=[{x:0,y:0},{x:u+3*m/6,y:0},{x:u,y:-m},{x:-(3*m)/6,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),W=w.path(M,_);if(x=l.insert(()=>W,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t(Px,"lean_left");async function Rx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=Math.max(p.height+n,e.height??0),u=Math.max(p.width+c,(e.width??0)-m),y=[{x:-3*m/6,y:0},{x:u,y:0},{x:u+3*m/6,y:-m},{x:0,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),W=w.path(M,_);if(x=l.insert(()=>W,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t(Rx,"lean_right");function qx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.label="",e.labelStyle=o;let s=r.insert("g").attr("class",te(e)).attr("id",e.domId??e.id),{cssStyles:n}=e,c=Math.max(35,e?.width??0),l=Math.max(35,e?.height??0),p=7,m=[{x:c,y:0},{x:0,y:l+p/2},{x:c-2*p,y:l+p/2},{x:0,y:2*l},{x:c,y:l-p/2},{x:2*p,y:l-p/2}],u=v.svg(s),y=Kt(e,{});if(e.look!=="handDrawn")y.roughness=0,y.fillStyle="solid";let x=ye(m),k=u.path(x,y),w=s.insert(()=>k,":first-child");if(w.attr("class","outer-path"),n&&e.look!=="handDrawn")w.selectAll("path").attr("style",n);if(a&&e.look!=="handDrawn")w.selectAll("path").attr("style",a);return w.attr("transform",`translate(-${c/2},${-l})`),B(e,w),e.intersect=function(_){return i.info("lightningBolt intersect",e,_),T.polygon(e,m,_)},s}t(qx,"lightningBolt");var sS=t((r,e,o,a,s,n,c)=>[`M${r},${e+n}`,`a${s},${n} 0,0,0 ${o},0`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`,`M${r},${e+n+c}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createCylinderPathD"),aS=t((r,e,o,a,s,n,c)=>[`M${r},${e+n}`,`M${r+o},${e+n}`,`a${s},${n} 0,0,0 ${-o},0`,`l0,${a}`,`a${s},${n} 0,0,0 ${o},0`,`l0,${-a}`,`M${r},${e+n+c}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createOuterCylinderPathD"),nS=t((r,e,o,a,s,n)=>[`M${r-o/2},${-a/2}`,`a${s},${n} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD"),My=10,Ey=10;async function Nx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?24:s;if(e.width||e.height){let W=e.width??0;if(e.width=(e.width??0)-n,e.width<Ey)e.width=Ey;let V=W/2/(2.5+W/50);if(e.height=(e.height??0)-c-V*3,e.height<My)e.height=My}let{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=(e?.width?e?.width:p.width)+n*2,y=u/2,x=y/(2.5+u/50),k=(e?.height?e?.height:p.height)+x+c*2,w=k*0.1,_,{cssStyles:M}=e;if(e.look==="handDrawn"){let W=v.svg(l),U=aS(0,0,u,k,y,x,w),V=nS(0,x,u,k,y,x),Z=Kt(e,{}),tt=W.path(U,Z),at=W.path(V,Z);if(l.insert(()=>at,":first-child").attr("class","line"),_=l.insert(()=>tt,":first-child"),_.attr("class","basic label-container"),M)_.attr("style",M)}else{let W=sS(0,0,u,k,y,x,w);_=l.insert("path",":first-child").attr("d",W).attr("class","basic label-container outer-path").attr("style",Fe(M)).attr("style",a)}return _.attr("label-offset-y",x),_.attr("transform",`translate(${-u/2}, ${-(k/2+x)})`),B(e,_),m.attr("transform",`translate(${-(p.width/2)-(p.x-(p.left??0))}, ${-(p.height/2)+x-(p.y-(p.top??0))})`),e.intersect=function(W){let U=T.rect(e,W),V=U.x-(e.x??0);if(y!=0&&(Math.abs(V)<(e.width??0)/2||Math.abs(V)==(e.width??0)/2&&Math.abs(U.y-(e.y??0))>(e.height??0)/2-x)){let Z=x*x*(1-V*V/(y*y));if(Z>0)Z=Math.sqrt(Z);if(Z=x-Z,W.y-(e.y??0)>0)Z=-Z;U.y+=Z}return U},l}t(Nx,"linedCylinder");async function Wx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height){let Z=e.width;if(e.width=(Z??0)*10/11-n*2,e.width<10)e.width=10;if(e.height=(e?.height??0)-c*2,e.height<10)e.height=10}let{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=(e?.width?e?.width:p.width)+(n??0)*2,y=(e?.height?e?.height:p.height)+(c??0)*2,x=e.look==="neo"?y/4:y/8,k=y+x,{cssStyles:w}=e,_=v.svg(l),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let W=[{x:-u/2-u/2*0.1,y:-k/2},{x:-u/2-u/2*0.1,y:k/2},...Ji(-u/2-u/2*0.1,k/2,u/2+u/2*0.1,k/2,x,0.8),{x:u/2+u/2*0.1,y:-k/2},{x:-u/2-u/2*0.1,y:-k/2},{x:-u/2,y:-k/2},{x:-u/2,y:k/2*1.1},{x:-u/2,y:-k/2}],U=_.polygon(W.map((Z)=>[Z.x,Z.y]),M),V=l.insert(()=>U,":first-child");if(V.attr("class","basic label-container outer-path"),w&&e.look!=="handDrawn")V.selectAll("path").attr("style",w);if(a&&e.look!=="handDrawn")V.selectAll("path").attr("style",a);return V.attr("transform",`translate(0,${-x/2})`),m.attr("transform",`translate(${-u/2+(e.padding??0)+u/2*0.1/2-(p.x-(p.left??0))},${-y/2+(e.padding??0)-x-(p.y-(p.top??0))})`),B(e,V),e.intersect=function(Z){return T.polygon(e,W,Z)},l}t(Wx,"linedWaveEdgedRect");var lS=56,Uf=72,Oy=8,Iy=2,hS=8,cS={normal:"usecase-actor-shape usecase-actor-normal",hollow:"usecase-actor-hollow",awesome:"usecase-actor-awesome",icon:"usecase-actor-icon"},$y=Math.PI/3,Dy=0.6,jf=t((r,e)=>{let o=e*Dy,a=e*Math.sqrt(1-Dy**2),s=Math.cos($y),n=-Math.sin($y),c=o*-n,l=r+o*s,p=a*s,m=a*n;return`M ${c-p} ${l-m} L ${c+p} ${l+m}`},"businessMarkerPathForCircle"),uS={normal:jf(-24,12),hollow:jf(-23,9),awesome:jf(-21,13),icon:"M 12 -8 L 26 -26"},Py=t((r,e,o)=>{let a=(e.x??0)-(e.left??0),s=(e.y??0)-(e.top??0);r.attr("transform",`translate(${-e.width/2-a},${o-e.height/2-s})`)},"positionLabel"),od=t((r,e,o,a,s=!1)=>{if(e.look==="handDrawn"){let l=v.svg(r).path(o,Kt(e,s?{fill:"none"}:{}));return r.insert(()=>l,":first-child").attr("class",a)}let n=r.append("path").attr("class",a).attr("d",o);if(s)n.attr("fill","none");return n},"appendActorPath"),fS=t((r,e,o,a,s,n,c=!1)=>{if(e.look==="handDrawn"){let m=v.svg(r).circle(o,a,s*2,Kt(e,c?{fill:"none"}:{}));return r.insert(()=>m,":first-child").attr("class",n)}let l=r.append("circle").attr("class",n).attr("cx",o).attr("cy",a).attr("r",s);if(c)l.attr("fill","none");return l},"appendActorCircle");var dS=t((r,e,o)=>{if(!e.business)return;r.append("path").attr("class","usecase-business-marker usecase-actor-business-marker").attr("d",uS[o]).attr("fill","none").attr("style","stroke: inherit !important; stroke-width: inherit !important")},"appendBusinessActorMarker");async function rn(r,e,o,a){let{labelStyles:s,nodeStyles:n}=E(e);e.labelStyle=s;let c=o==="icon"||e.stereotype!==void 0?{...e,icon:o==="icon"?void 0:e.icon,stereotype:void 0}:e,{shapeSvg:l,bbox:p,label:m}=await j(r,c,te(e,`usecase-actor-variant usecase-actor-${o}`)),u=e.accessibleName??e.label;if(u)l.attr("role","img").attr("aria-label",u);m.attr("class","label actor-label usecase-actor-label");let{theme:y,themeVariables:x}=d();It(l,e.colorIndex,y,x.borderColorArray);let k,w;if(e.stereotype){let ht=await uo(l,`«${e.stereotype}»`,{labelStyle:s,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0,width:e.wrappingWidth});k=ht.label.attr("class","label usecase-stereotype"),w=ht.bbox}let _=l.append("g").attr("class",`usecase-actor-glyph ${cS[o]}`).attr("style",n||null);await a(_,e),dS(_,e,o);let M=e.padding??hS,W=w?.height??0,U=Uf+Oy+p.height+(w?W+Iy:0),V=Math.max(lS,p.width,w?.width??0)+M*2,Z=U+M*2,tt=-U/2;_.attr("transform",`translate(0,${tt+Uf/2})`);let at=tt+Uf+Oy;if(k&&w)at+=W/2,Py(k,w,at),at+=W/2+Iy;Py(m,p,at+p.height/2);let ot=l.insert("rect",":first-child").attr("class","usecase-actor-outline").attr("x",-V/2).attr("y",-Z/2).attr("width",V).attr("height",Z).attr("opacity",0).attr("aria-hidden","true");return B(e,ot),e.intersect=(ht)=>T.rect(e,ht),l}t(rn,"renderUsecaseActor");var pS=["M 0 -12","C 6.627 -12 12 -17.373 12 -24","C 12 -30.627 6.627 -36 0 -36","C -6.627 -36 -12 -30.627 -12 -24","C -12 -17.373 -6.627 -12 0 -12 Z","M 0 -12 V 8","M -17 -5 H 17","M 0 8 L -15 28","M 0 8 L 15 28"].join(" ");async function zx(r,e){return rn(r,e,"normal",(o,a)=>{od(o,a,pS,"usecase-actor-stick")})}t(zx,"usecaseActor");var gS=["M 0 -34","C 7.18 -34 13 -28.18 13 -21","C 13 -13.82 7.18 -8 0 -8","C -7.18 -8 -13 -13.82 -13 -21","C -13 -28.18 -7.18 -34 0 -34 Z","M -24 25","C -24 7 -14 -3 0 -3","C 14 -3 24 7 24 25","C 24 28 21 30 18 30","H -18","C -21 30 -24 28 -24 25 Z"].join(" ");async function Hx(r,e){return rn(r,e,"awesome",(o,a)=>{od(o,a,gS,"usecase-actor-awesome-silhouette")})}t(Hx,"usecaseActorAwesome");var mS=["M -22 -10","H 22","V 0","H 6","L 22 17","L 13 28","L 0 13","L -13 28","L -22 17","L -6 0","H -22","Z"].join(" ");async function Yx(r,e){return rn(r,e,"hollow",(o,a)=>{fS(o,a,0,-23,9,"usecase-actor-hollow-head",!0),od(o,a,mS,"usecase-actor-hollow-body",!0)})}t(Yx,"usecaseActorHollow");var Cs=52,Ry=42,qy=-2,yS=t(async(r,e)=>{let o=-Cs/2,a=qy-Cs/2;if(e.look==="handDrawn"){let u=v.svg(r).rectangle(o,a,Cs,Cs,Kt(e,{}));r.insert(()=>u,":first-child").attr("class","usecase-actor-icon-frame")}else r.append("rect").attr("class","usecase-actor-icon-frame").attr("x",o).attr("y",a).attr("width",Cs).attr("height",Cs).attr("rx",4).attr("ry",4);let s=e.icon??"",n=await gl(s.includes(":")?s:`fa:${s}`),c=await Gt(s,{height:Ry,width:Ry,fallbackPrefix:"fa"}),l=r.append("g").attr("class",`usecase-actor-icon-symbol${n?"":" usecase-actor-icon-fallback"}`).attr("aria-hidden","true").html(`<g>${c}</g>`),p=l.node()?.getBBox();if(p)l.attr("transform",`translate(${-p.width/2-p.x},${qy-p.height/2-p.y})`)},"drawIconActor");async function Ux(r,e){return rn(r,e,"icon",yS)}t(Ux,"usecaseActorIcon");var Ny=t((r,e,o)=>{let a=(e.x??0)-(e.left??0),s=(e.y??0)-(e.top??0);r.attr("transform",`translate(${-e.width/2-a},${o-e.height/2-s})`)},"positionLabel");async function jx(r,e){let o=e,{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let n=o.stereotype?{...e,stereotype:void 0}:e,{shapeSvg:c,bbox:l,halfPadding:p,label:m}=await j(r,n,te(e,"usecase-business-shape"));m.attr("class","label usecase-label");let{theme:u,themeVariables:y}=d();It(c,e.colorIndex,u,y.borderColorArray);let x,k;if(o.stereotype){let rt=await uo(c,`«${o.stereotype}»`,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0,width:e.wrappingWidth});x=rt.label.attr("class","label usecase-stereotype"),k=rt.bbox}let w=k?2:0,_=l.height+(k?.height??0)+w,M=Math.max(l.width,k?.width??0),W=p??10,U=M/2+W*2,V=_/2+W*2,Z=Math.min(Math.max(W/5,1),W/2),tt=M/2+Z,at=U-Z,ot=tt/U,ht=at/U,yt=V*Math.sqrt(Math.max(0,1-ot*ot)),Bt=-V*Math.sqrt(Math.max(0,1-ht*ht));if(x&&k)Ny(x,k,-_/2+k.height/2);Ny(m,l,_/2-l.height/2);let kt;if(e.look==="handDrawn"){let it=v.svg(c).ellipse(0,0,U*2,V*2,Kt(e,{}));kt=c.insert(()=>it,":first-child").attr("class","basic label-container usecase-business-ellipse")}else kt=c.insert("ellipse",":first-child").attr("class","basic label-container usecase-business-ellipse").attr("style",s).attr("rx",U).attr("ry",V).attr("cx",0).attr("cy",0);c.append("path").attr("class","usecase-business-marker").attr("d",`M ${tt} ${yt} L ${at} ${Bt}`).attr("fill","none").attr("style",s||null);let Ct=o.accessibleName??o.label;if(Ct)c.attr("role","img").attr("aria-label",Ct);return B(e,kt),e.calcIntersect=(rt,it)=>T.ellipse(rt,rt.width/2,rt.height/2,it),e.intersect=(rt)=>T.ellipse(e,U,V,rt),c}t(jx,"usecaseBusiness");var Gf=8,Wy=4,xS=1,Xf=t((r,e,o,a)=>{let s=(e.x??0)-(e.left??0),n=(e.y??0)-(e.top??0);r.attr("transform",`translate(${o-e.width/2-s},${a-e.height/2-n})`)},"positionLabel"),CS=t((r)=>{let e=Number.parseFloat(r??"");return Number.isFinite(e)&&e>=0?e:xS},"numericStrokeWidth");async function Gx(r,e){let o=e,{labelStyles:a,nodeStyles:s}=E(e),{stylesMap:n}=ai(e);e.labelStyle=a;let{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e,"usecase-json-table"));if(c.attr("role","img"),o.accessibleName)c.attr("aria-label",o.accessibleName);p.attr("class","label usecase-json-title");let m=c.append("g").attr("class","usecase-json-table-grid"),u=[];for(let rt of o.jsonRows??[]){let it=await uo(m,rt.key,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0}),gt=await uo(m,rt.value,{labelStyle:a,useHtmlLabels:e.useHtmlLabels,padding:0,centerLabel:!0});u.push({key:{label:it.label.attr("class","label usecase-json-key"),bbox:it.bbox},value:{label:gt.label.attr("class","label usecase-json-value"),bbox:gt.bbox}})}let y=Math.max(0,...u.map(({key:rt})=>rt.bbox.width))+Gf*2,x=Math.max(0,...u.map(({value:rt})=>rt.bbox.width))+Gf*2,k=l.width+Gf*2,w=Math.max(k,y+x),_=x+Math.max(0,w-y-x),M=l.height+Wy*2,W=u.map(({key:rt,value:it})=>Math.max(rt.bbox.height,it.bbox.height)+Wy*2),U=M+W.reduce((rt,it)=>rt+it,0),V=CS(n.get("stroke-width")),Z=w+V*2,tt=U+V*2,at=-w/2,ot=-U/2,ht=e.look==="handDrawn"?v.svg(c):void 0,yt=ht?Kt(e,{}):void 0,Bt=t((rt,it,gt,et,wt,vt)=>{if(ht&&yt){let Xt=ht.rectangle(gt,et,wt,vt,yt);return rt.insert(()=>Xt,":first-child").attr("class",it)}return rt.insert("rect",":first-child").attr("class",it).attr("x",gt).attr("y",et).attr("width",wt).attr("height",vt).attr("style",s)},"insertCell"),kt=Bt(c,"label-container usecase-json-border",-Z/2,-tt/2,Z,tt);Bt(m,"usecase-json-cell usecase-json-title-cell",at,ot,w,M),m.node()?.append(p.node()),Xf(p,l,0,ot+M/2);let Ct=ot+M;return u.forEach(({key:rt,value:it},gt)=>{let et=W[gt],wt=m.append("g").attr("class","usecase-json-row").attr("data-row-index",gt).attr("transform",`translate(0,${Ct})`);Bt(wt,"usecase-json-cell usecase-json-key-cell",at,0,y,et),Bt(wt,"usecase-json-cell usecase-json-value-cell",at+y,0,_,et),wt.node()?.append(rt.label.node(),it.label.node()),Xf(rt.label,rt.bbox,at+y/2,et/2),Xf(it.label,it.bbox,at+y+_/2,et/2),Ct+=et}),B(e,kt),e.intersect=(rt)=>T.rect(e,rt),c}t(Gx,"usecaseJsonTable");async function Xx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=e.look==="neo"?10:5;if(e.width||e.height)e.width=Math.max((e?.width??0)-n*2-2*l,10),e.height=Math.max((e?.height??0)-c*2-2*l,10);let{shapeSvg:p,bbox:m,label:u}=await j(r,e,te(e)),y=(e?.width?e?.width:m.width)+n*2+2*l,x=(e?.height?e?.height:m.height)+c*2+2*l,k=y-2*l,w=x-2*l,_=-k/2,M=-w/2,{cssStyles:W}=e,U=v.svg(p),V=Kt(e,{}),Z=[{x:_-l,y:M+l},{x:_-l,y:M+w+l},{x:_+k-l,y:M+w+l},{x:_+k-l,y:M+w},{x:_+k,y:M+w},{x:_+k,y:M+w-l},{x:_+k+l,y:M+w-l},{x:_+k+l,y:M-l},{x:_+l,y:M-l},{x:_+l,y:M},{x:_,y:M},{x:_,y:M+l}],tt=[{x:_,y:M+l},{x:_+k-l,y:M+l},{x:_+k-l,y:M+w},{x:_+k,y:M+w},{x:_+k,y:M},{x:_,y:M}];if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let at=ye(Z),ot=U.path(at,V),ht=ye(tt),yt=U.path(ht,V);if(e.look!=="handDrawn")ot=Kf(ot),yt=Kf(yt);let Bt=p.insert("g",":first-child");if(Bt.insert(()=>ot),Bt.insert(()=>yt),Bt.attr("class","basic label-container outer-path"),W&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",W);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return u.attr("transform",`translate(${-(m.width/2)-l-(m.x-(m.left??0))}, ${-(m.height/2)+l-(m.y-(m.top??0))})`),B(e,Bt),e.intersect=function(kt){return T.polygon(e,Z,kt)},p}t(Xx,"multiRect");async function Vx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=e.padding??0,p=e.look==="neo"?16:l,m=e.look==="neo"?12:l,u=!0;if(e.width||e.height)u=!1,e.width=(e?.width??0)-p*2,e.height=(e?.height??0)-m*3;let y=Math.max(n.width,e?.width??0)+p*2,x=Math.max(n.height,e?.height??0)+m*3,k=e.look==="neo"?x/4:x/8,w=x+(u?k/2:-k/2),_=-y/2,M=-w/2,W=10,{cssStyles:U}=e,V=Ji(_-W,M+w+W,_+y-W,M+w+W,k,0.8),Z=V?.[V.length-1],tt=[{x:_-W,y:M+W},{x:_-W,y:M+w+W},...V,{x:_+y-W,y:Z.y-W},{x:_+y,y:Z.y-W},{x:_+y,y:Z.y-2*W},{x:_+y+W,y:Z.y-2*W},{x:_+y+W,y:M-W},{x:_+W,y:M-W},{x:_+W,y:M},{x:_,y:M},{x:_,y:M+W}],at=[{x:_,y:M+W},{x:_+y-W,y:M+W},{x:_+y-W,y:Z.y-W},{x:_+y,y:Z.y-W},{x:_+y,y:M},{x:_,y:M}],ot=v.svg(s),ht=Kt(e,{});if(e.look!=="handDrawn")ht.roughness=0,ht.fillStyle="solid";let yt=ye(tt),Bt=ot.path(yt,ht),kt=ye(at),Ct=ot.path(kt,ht),rt=s.insert(()=>Bt,":first-child");if(rt.insert(()=>Ct),rt.attr("class","basic label-container outer-path"),U&&e.look!=="handDrawn")rt.selectAll("path").attr("style",U);if(a&&e.look!=="handDrawn")rt.selectAll("path").attr("style",a);return rt.attr("transform",`translate(0,${-k/2})`),c.attr("transform",`translate(${-(n.width/2)-W-(n.x-(n.left??0))}, ${-(n.height/2)+W-k-(n.y-(n.top??0))})`),B(e,rt),e.intersect=function(it){return T.polygon(e,tt,it)},s}t(Vx,"multiWaveEdgedRectangle");async function Kx(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);if(e.labelStyle=a,!(e.useHtmlLabels||Xe(A())))e.centerLabel=!0;let{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=Math.max(l.width+(e.padding??0)*2,e?.width??0),u=Math.max(l.height+(e.padding??0)*2,e?.height??0),y=-m/2,x=-u/2,{cssStyles:k}=e,w=v.svg(c),_=Kt(e,{fill:o.noteBkgColor,stroke:o.noteBorderColor});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=w.rectangle(y,x,m,u,_),W=c.insert(()=>M,":first-child");if(W.attr("class","basic label-container outer-path"),p.attr("class","label noteLabel"),k&&e.look!=="handDrawn")W.selectAll("path").attr("style",k);if(s&&e.look!=="handDrawn")W.selectAll("path").attr("style",s);return p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),B(e,W),e.intersect=function(U){return T.rect(e,U)},c}t(Kx,"note");var bS=t((r,e,o)=>[`M${r+o/2},${e}`,`L${r+o},${e-o/2}`,`L${r+o/2},${e-o}`,`L${r},${e-o/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function Zx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n}=await j(r,e,te(e)),c=n.width+(e.padding??0),l=n.height+(e.padding??0),p=c+l,m=0.5,u=[{x:p/2,y:0},{x:p,y:-p/2},{x:p/2,y:-p},{x:0,y:-p/2}],y,{cssStyles:x}=e;if(e.look==="handDrawn"){let k=v.svg(s),w=Kt(e,{}),_=bS(0,0,p),M=k.path(_,w);if(y=s.insert(()=>M,":first-child").attr("transform",`translate(${-p/2+m}, ${p/2})`),x)y.attr("style",x)}else y=fi(s,p,p,u),y.attr("transform",`translate(${-p/2+m}, ${p/2})`);if(a)y.attr("style",a);return B(e,y),e.calcIntersect=function(k,w){let _=k.width,M=[{x:_/2,y:0},{x:_,y:-_/2},{x:_/2,y:-_},{x:0,y:-_/2}];return T.polygon(k,M,w)},e.intersect=function(k){return this.calcIntersect(e,k)},s}t(Zx,"question");async function Qx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?21:s??0,c=e.look==="neo"?12:s??0,{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=p.width+(e.look==="neo"?n*2:n),y=Math.max(p.height+(e.look==="neo"?c*2:c),e.height??0),x=y/4,w=-Math.max(u,(e.width??0)-x)/2,_=-y/2,M=_/2,W=[{x:w+M,y:_},{x:w,y:0},{x:w+M,y:-_},{x:-w,y:-_},{x:-w,y:_}],{cssStyles:U}=e,V=v.svg(l),Z=Kt(e,{});if(e.look!=="handDrawn")Z.roughness=0,Z.fillStyle="solid";let tt=ye(W),at=V.path(tt,Z),ot=l.insert(()=>at,":first-child");if(ot.attr("class","basic label-container outer-path"),U&&e.look!=="handDrawn")ot.selectAll("path").attr("style",U);if(a&&e.look!=="handDrawn")ot.selectAll("path").attr("style",a);return ot.attr("transform",`translate(${-M/2},0)`),m.attr("transform",`translate(${-M/2-p.width/2-(p.x-(p.left??0))}, ${-(p.height/2)-(p.y-(p.top??0))})`),B(e,ot),e.intersect=function(ht){return T.polygon(e,W,ht)},l}t(Qx,"rect_left_inv_arrow");async function Jx(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s;if(!e.cssClasses)s="node default";else s="node "+e.cssClasses;let n=r.insert("g").attr("class",s).attr("id",e.domId||e.id),c=n.insert("g"),l=n.insert("g").attr("class","label").attr("style",a),{description:p,label:m}=e,u=await Gr(l,m,e.labelStyle,!0,!0),y={width:0,height:0};if(Xe(d())){let ht=u.children[0],yt=g(u);y=ht.getBoundingClientRect(),yt.attr("width",y.width),yt.attr("height",y.height)}i.info("Text 2",p);let x=p||[],k=u.getBBox(),w=await Gr(l,Array.isArray(x)?x.join("<br/>"):x,e.labelStyle,!0,!0),_=w.children[0],M=g(w);y=_.getBoundingClientRect(),M.attr("width",y.width),M.attr("height",y.height);let W=(e.padding||0)/2;g(w).attr("transform","translate( "+(y.width>k.width?0:(k.width-y.width)/2)+", "+(k.height+W+5)+")"),g(u).attr("transform","translate( "+(y.width<k.width?0:-(k.width-y.width)/2)+", 0)"),y=l.node().getBBox(),l.attr("transform","translate("+-y.width/2+", "+(-y.height/2-W+3)+")");let U=y.width+(e.padding||0),V=y.height+(e.padding||0),Z=-y.width/2-W,tt=-y.height/2-W,at,ot;if(e.look==="handDrawn"){let ht=v.svg(n),yt=Kt(e,{}),Bt=ht.path(Tr(Z,tt,U,V,e.rx||0),yt),kt=ht.line(-y.width/2-W,-y.height/2-W+k.height+W,y.width/2+W,-y.height/2-W+k.height+W,yt);ot=n.insert(()=>(i.debug("Rough node insert CXC",Bt),kt),":first-child"),at=n.insert(()=>(i.debug("Rough node insert CXC",Bt),Bt),":first-child")}else at=c.insert("rect",":first-child"),ot=c.insert("line"),at.attr("class","outer title-state").attr("style",a).attr("x",-y.width/2-W).attr("y",-y.height/2-W).attr("width",y.width+(e.padding||0)).attr("height",y.height+(e.padding||0)),ot.attr("class","divider").attr("x1",-y.width/2-W).attr("x2",y.width/2+W).attr("y1",-y.height/2-W+k.height+W).attr("y2",-y.height/2-W+k.height+W);return B(e,at),e.intersect=function(ht){return T.rect(e,ht)},n}t(Jx,"rectWithTitle");async function t0(r,e,{config:{themeVariables:o}}){let a=o?.radius??5,s={rx:a,ry:a,classes:"",labelPaddingX:(e?.padding??0)*1,labelPaddingY:(e?.padding??0)*1};return Ss(r,e,s)}t(t0,"roundedRect");var co=8;async function e0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.look==="neo"?16:e.padding??0,n=e.look==="neo"?12:e.padding??0,{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=(e?.width??l.width)+s*2+(e.look==="neo"?co:co*2),u=(e?.height??l.height)+n*2,y=m-co,x=u,k=co-m/2,w=-u/2,{cssStyles:_}=e,M=v.svg(c),W=Kt(e,{});if(e.look!=="handDrawn")W.roughness=0,W.fillStyle="solid";let U=[{x:k,y:w},{x:k+y,y:w},{x:k+y,y:w+x},{x:k-co,y:w+x},{x:k-co,y:w},{x:k,y:w},{x:k,y:w+x}],V=M.polygon(U.map((tt)=>[tt.x,tt.y]),W),Z=c.insert(()=>V,":first-child");if(Z.attr("class","basic label-container outer-path").attr("style",Fe(_)),a&&e.look!=="handDrawn")Z.selectAll("path").attr("style",a);if(_&&e.look!=="handDrawn")Z.selectAll("path").attr("style",a);return p.attr("transform",`translate(${co/2-l.width/2-(l.x-(l.left??0))}, ${-(l.height/2)-(l.y-(l.top??0))})`),B(e,Z),e.intersect=function(tt){return T.rect(e,tt)},c}t(e0,"shadedProcess");async function r0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height)e.width=Math.max((e?.width??0)-n*2,10),e.height=Math.max((e?.height??0)/1.5-c*2,10);let{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=(e?.width?e?.width:p.width)+n*2,y=((e?.height?e?.height:p.height)+c*2)*1.5,x=u,k=y/1.5,w=-x/2,_=-k/2,{cssStyles:M}=e,W=v.svg(l),U=Kt(e,{});if(e.look!=="handDrawn")U.roughness=0,U.fillStyle="solid";let V=[{x:w,y:_},{x:w,y:_+k},{x:w+x,y:_+k},{x:w+x,y:_-k/2}],Z=ye(V),tt=W.path(Z,U),at=l.insert(()=>tt,":first-child");if(at.attr("class","basic label-container outer-path"),M&&e.look!=="handDrawn")at.selectChildren("path").attr("style",M);if(a&&e.look!=="handDrawn")at.selectChildren("path").attr("style",a);return at.attr("transform",`translate(0, ${k/4})`),m.attr("transform",`translate(${-x/2+(e.padding??0)-(p.x-(p.left??0))}, ${-k/4+(e.padding??0)-(p.y-(p.top??0))})`),B(e,at),e.intersect=function(ot){return T.polygon(e,V,ot)},l}t(r0,"slopedRect");async function i0(r,e){let o=e.padding??0,a=e.look==="neo"?16:o*2,s=e.look==="neo"?12:o,n={rx:0,ry:0,classes:"",labelPaddingX:e.labelPaddingX??a,labelPaddingY:s},c=await Ss(r,e,n);if(e.colorIndex!==void 0){let{theme:l,themeVariables:p}=d();It(c,e.colorIndex,l,p.borderColorArray)}return c}t(i0,"squareRect");var Jf=50,kS=t((r,e,o)=>{let a=r.height+o,s=a*Math.cos(Math.PI/(2*(Jf-1))),n=Math.sqrt(Math.max(0,s**2-r.height**2));return{w:Math.max(r.width+a/4+e,1.5*a+(a-s),r.width+e+a-n),h:a}},"stadiumDimensions");async function o0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?40:s,c=e.look==="neo"?24:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),{w:m,h:u}=kS(p,n,c),y=u/2,{cssStyles:x}=e,k=v.svg(l),w=Kt(e,{});if(e.look!=="handDrawn")w.roughness=0,w.fillStyle="solid";let _=[{x:-m/2+y,y:-u/2},{x:m/2-y,y:-u/2},...ci(-m/2+y,0,y,Jf,90,270),{x:m/2-y,y:u/2},...ci(m/2-y,0,y,Jf,270,450)],M=ye(_),W=k.path(M,w),U=l.insert(()=>W,":first-child");if(U.attr("class","basic label-container outer-path"),x&&e.look!=="handDrawn")U.selectChildren("path").attr("style",x);if(a&&e.look!=="handDrawn")U.selectChildren("path").attr("style",a);return B(e,U),e.intersect=function(V){return T.polygon(e,_,V)},l}t(o0,"stadium");async function s0(r,e){let o={rx:e.look==="neo"?3:5,ry:e.look==="neo"?3:5,classes:"flowchart-node"};return Ss(r,e,o)}t(s0,"state");function a0(r,e,{config:{themeVariables:o}}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a;let{cssStyles:n}=e,{lineColor:c,stateBorder:l,nodeBorder:p,nodeShadow:m}=o;if(e.width||e.height){if((e.width??0)<14)e.width=14;if((e.height??0)<14)e.height=14}if(!e.width)e.width=14;if(!e.height)e.height=14;let u=r.insert("g").attr("class","node default").attr("id",e.domId??e.id),y=v.svg(u),x=Kt(e,{});if(e.look!=="handDrawn")x.roughness=0,x.fillStyle="solid";let k=y.circle(0,0,e.width,{...x,stroke:c,strokeWidth:2}),w=l??p,_=(e.width??0)*5/14,M=y.circle(0,0,_,{...x,fill:w,stroke:w,strokeWidth:2,fillStyle:"solid"}),W=u.insert(()=>k,":first-child");if(W.insert(()=>M),e.look!=="handDrawn")W.attr("class","outer-path");if(n)W.selectAll("path").attr("style",n);if(s)W.selectAll("path").attr("style",s);if(e.width<25&&m&&e.look!=="handDrawn"){let U=r.node()?.ownerSVGElement?.id??"",V=U?`${U}-drop-shadow-small`:"drop-shadow-small";W.attr("style",`filter:url(#${V})`)}return B(e,W),e.intersect=function(U){return T.circle(e,(e.width??0)/2,U)},u}t(a0,"stateEnd");function n0(r,e,{config:{themeVariables:o}}){let{lineColor:a,nodeShadow:s}=o;if(e.width||e.height){if((e.width??0)<14)e.width=14;if((e.height??0)<14)e.height=14}if(!e.width)e.width=14;if(!e.height)e.height=14;let n=r.insert("g").attr("class","node default").attr("id",e.domId||e.id),c;if(e.look==="handDrawn"){let p=v.svg(n).circle(0,0,e.width,Gg(a));c=n.insert(()=>p),c.attr("class","state-start").attr("r",(e.width??7)/2).attr("width",e.width??14).attr("height",e.height??14)}else c=n.insert("circle",":first-child"),c.attr("class","state-start").attr("r",(e.width??7)/2).attr("width",e.width??14).attr("height",e.height??14);if(e.width<25&&s&&e.look!=="handDrawn"){let l=r.node()?.ownerSVGElement?.id??"",p=l?`${l}-drop-shadow-small`:"drop-shadow-small";c.attr("style",`filter:url(#${p})`)}return B(e,c),e.intersect=function(l){return T.circle(e,(e.width??7)/2,l)},n}t(n0,"stateStart");var bs=8;async function l0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e?.padding??8,n=e.look==="neo"?28:s,c=e.look==="neo"?12:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=Math.max(p.width+2*bs+n,e.width??0),u=Math.max(p.height+c,e.height??0),y=m-2*bs,x=u,k=-m/2,w=-u/2,_=[{x:0,y:0},{x:y,y:0},{x:y,y:-x},{x:0,y:-x},{x:0,y:0},{x:-8,y:0},{x:y+8,y:0},{x:y+8,y:-x},{x:-8,y:-x},{x:-8,y:0}];if(e.look==="handDrawn"){let M=v.svg(l),W=Kt(e,{}),U=M.rectangle(k,w,y+16,x,W),V=M.line(k+bs,w,k+bs,w+x,W),Z=M.line(k+bs+y,w,k+bs+y,w+x,W);l.insert(()=>V,":first-child"),l.insert(()=>Z,":first-child");let tt=l.insert(()=>U,":first-child"),{cssStyles:at}=e;tt.attr("class","basic label-container").attr("style",Fe(at)),B(e,tt)}else{let M=fi(l,y,x,_);if(a)M.attr("style",a);B(e,M)}return e.intersect=function(M){return T.polygon(e,_,M)},l}t(l0,"subroutine");var Vf=0.2;async function h0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s;if(e.width||e.height)e.height=Math.max((e?.height??0)-c*2,10),e.width=Math.max((e?.width??0)-n*2-Vf*(e.height+c*2),10);let{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=(e?.height?e?.height:p.height)+c*2,u=Vf*m,y=Vf*m,k=(e?.width?e?.width:p.width)+n*2+u-u,w=m,_=-k/2,M=-w/2,{cssStyles:W}=e,U=v.svg(l),V=Kt(e,{}),Z=[{x:_-u/2,y:M},{x:_+k+u/2,y:M},{x:_+k+u/2,y:M+w},{x:_-u/2,y:M+w}],tt=[{x:_+k-u/2,y:M+w},{x:_+k+u/2,y:M+w},{x:_+k+u/2,y:M+w-y}];if(e.look!=="handDrawn")V.roughness=0,V.fillStyle="solid";let at=ye(Z),ot=U.path(at,V),ht=ye(tt),yt=U.path(ht,{...V,fillStyle:"solid"}),Bt=l.insert(()=>yt,":first-child");if(Bt.insert(()=>ot,":first-child"),Bt.attr("class","basic label-container outer-path"),W&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",W);if(a&&e.look!=="handDrawn")Bt.selectAll("path").attr("style",a);return B(e,Bt),e.intersect=function(kt){return T.polygon(e,Z,kt)},l}t(h0,"taggedRect");async function c0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,label:c}=await j(r,e,te(e)),l=Math.max(n.width+(e.padding??0)*2,e?.width??0),p=Math.max(n.height+(e.padding??0)*2,e?.height??0),m=p/8,u=0.2*l,y=0.2*p,x=p+m,{cssStyles:k}=e,w=v.svg(s),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=[{x:-l/2-l/2*0.1,y:x/2},...Ji(-l/2-l/2*0.1,x/2,l/2+l/2*0.1,x/2,m,0.8),{x:l/2+l/2*0.1,y:-x/2},{x:-l/2-l/2*0.1,y:-x/2}],W=-l/2+l/2*0.1,U=-x/2-y*0.4,V=[{x:W+l-u,y:(U+p)*1.3},{x:W+l,y:U+p-y},{x:W+l,y:(U+p)*0.9},...Ji(W+l,(U+p)*1.25,W+l-u,(U+p)*1.3,-p*0.02,0.5)],Z=ye(M),tt=w.path(Z,_),at=ye(V),ot=w.path(at,{..._,fillStyle:"solid"}),ht=s.insert(()=>ot,":first-child");if(ht.insert(()=>tt,":first-child"),ht.attr("class","basic label-container outer-path"),k&&e.look!=="handDrawn")ht.selectAll("path").attr("style",k);if(a&&e.look!=="handDrawn")ht.selectAll("path").attr("style",a);return ht.attr("transform",`translate(0,${-m/2})`),c.attr("transform",`translate(${-l/2+(e.padding??0)-(n.x-(n.left??0))},${-p/2+(e.padding??0)-m/2-(n.y-(n.top??0))})`),B(e,ht),e.intersect=function(yt){return T.polygon(e,M,yt)},s}t(c0,"taggedWaveEdgedRectangle");async function u0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n}=await j(r,e,te(e)),c=Math.max(n.width+(e.padding??0),e?.width||0),l=Math.max(n.height+(e.padding??0),e?.height||0),p=-c/2,m=-l/2,u=s.insert("rect",":first-child");return u.attr("class","text").attr("style",a).attr("rx",0).attr("ry",0).attr("x",p).attr("y",m).attr("width",c).attr("height",l),B(e,u),e.intersect=function(y){return T.rect(e,y)},s}t(u0,"text");var wS=t((r,e,o,a,s,n)=>`M${r},${e}
|
|
234
234
|
a${s},${n} 0,0,1 0,${-a}
|
|
235
235
|
l${o},0
|
|
236
236
|
a${s},${n} 0,0,1 0,${a}
|
|
237
237
|
M${o},${-a}
|
|
238
238
|
a${s},${n} 0,0,0 0,${a}
|
|
239
|
-
l${-o},0`,"createCylinderPathD"),SS=t((r,e,o,a,s,n)=>[`M${r},${e}`,`M${r+o},${e}`,`a${s},${n} 0,0,0 0,${-a}`,`l${-o},0`,`a${s},${n} 0,0,0 0,${a}`,`l${o},0`].join(" "),"createOuterCylinderPathD"),TS=t((r,e,o,a,s,n)=>[`M${r+o/2},${-a/2}`,`a${s},${n} 0,0,0 0,${a}`].join(" "),"createInnerCylinderPathD"),zy=5,Hy=10;async function f0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?12:s/2,c=e.height??0;if(e.height){if(e.height=e.height-n,e.height<zy)e.height=zy}if(e.width){let
|
|
240
|
-
M${k-
|
|
241
|
-
M${k},${w-Ie} L${k},${w+x}`;if(e.look!=="handDrawn")q.roughness=0,q.fillStyle="solid";let Q=M.path(V,q),tt=c.insert(()=>Q,":first-child");if(tt.attr("transform",`translate(${Ie/2}, ${Ie/2})`),tt.attr("class","basic label-container outer-path"),_&&e.look!=="handDrawn")tt.selectAll("path").attr("style",_);if(a&&e.look!=="handDrawn")tt.selectAll("path").attr("style",a);return p.attr("transform",`translate(${-(l.width/2)+Ie/2-(l.x-(l.left??0))}, ${-(l.height/2)+Ie/2-(l.y-(l.top??0))})`),B(e,tt),e.intersect=function(at){return T.polygon(e,Y,at)},c}t(x0,"windowPane");var jy=new Set(["redux-color","redux-dark-color"]),_S=new Set(["redux","redux-dark","redux-color","redux-dark-color"]);async function sd(r,e){let o=e;if(o.alias)e.label=o.alias;let{theme:a,themeVariables:s}=A(),{rowEven:n,rowOdd:c,nodeBorder:l,borderColorArray:p}=s;if(e.look==="handDrawn"){let{themeVariables:Ut}=A(),{background:re}=Ut,ae={...e,id:e.id+"-background",domId:(e.domId||e.id)+"-background",look:"default",cssStyles:["stroke: none",`fill: ${re}`]};await sd(r,ae)}let m=A();e.useHtmlLabels=m.htmlLabels;let u=m.er?.diagramPadding??10,y=m.er?.entityPadding??6,{cssStyles:x}=e,{labelStyles:k,nodeStyles:w}=E(e);if(o.attributes.length===0&&e.label){let Ut={rx:0,ry:0,labelPaddingX:u,labelPaddingY:u*1.5,classes:""};if(Pt(e.label,m)+Ut.labelPaddingX*2<m.er.minEntityWidth)e.width=m.er.minEntityWidth;let re=await Ss(r,e,Ut);if(a!=null&&jy.has(a)){let ae=o.colorIndex??0;re.attr("data-color-id",`color-${ae%p.length}`)}if(!ln(m.htmlLabels)){let ae=re.select("text"),ne=ae.node()?.getBBox();ae.attr("transform",`translate(${-ne.width/2}, 0)`)}return re}if(!m.htmlLabels)u*=1.25,y*=1.25;let _=te(e);if(!_)_="node default";let M=r.insert("g").attr("class",_).attr("id",e.domId||e.id),q=await ks(M,e.label??"",m,0,0,["name"],k);q.height+=y;let Y=0,V=[],Q=[],tt=0,at=0,ot=0,ht=0,yt=!0,Bt=!0;for(let Ut of o.attributes){let re=await ks(M,Ut.type,m,0,Y,["attribute-type"],k);tt=Math.max(tt,re.width+u);let ae=await ks(M,Ut.name,m,0,Y,["attribute-name"],k);at=Math.max(at,ae.width+u);let ne=await ks(M,Ut.keys.join(),m,0,Y,["attribute-keys"],k);ot=Math.max(ot,ne.width+u);let Le=await ks(M,Ut.comment,m,0,Y,["attribute-comment"],k);ht=Math.max(ht,Le.width+u);let ve=Math.max(re.height,ae.height,ne.height,Le.height)+y;Q.push({yOffset:Y,rowHeight:ve}),Y+=ve}let kt=4;if(ot<=u)yt=!1,ot=0,kt--;if(ht<=u)Bt=!1,ht=0,kt--;let Ct=M.node().getBBox();if(q.width+u*2-(tt+at+ot+ht)>0){let Ut=q.width+u*2-(tt+at+ot+ht);if(tt+=Ut/kt,at+=Ut/kt,ot>0)ot+=Ut/kt;if(ht>0)ht+=Ut/kt}let rt=tt+at+ot+ht,it=v.svg(M),gt=Kt(e,{});if(e.look!=="handDrawn")gt.roughness=0,gt.fillStyle="solid";let et=0;if(Q.length>0)et=Q.reduce((Ut,re)=>Ut+(re?.rowHeight??0),0);let wt=Math.max(Ct.width+u*2,e?.width||0,rt),vt=Math.max((et??0)+q.height,e?.height||0),Xt=-wt/2,jt=-vt/2;if(M.selectAll("g:not(:first-child)").each((Ut,re,ae)=>{let ne=g(ae[re]),Le=ne.attr("transform"),ve=0,Dr=0;if(Le){let Mr=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(Le);if(Mr){if(ve=parseFloat(Mr[1]),Dr=parseFloat(Mr[2]),ne.attr("class").includes("attribute-name"))ve+=tt;else if(ne.attr("class").includes("attribute-keys"))ve+=tt+at;else if(ne.attr("class").includes("attribute-comment"))ve+=tt+at+ot}}ne.attr("transform",`translate(${Xt+u/2+ve}, ${Dr+jt+q.height+y/2})`)}),M.select(".name").attr("transform","translate("+-q.width/2+", "+(jt+y/2)+")"),a!=null&&jy.has(a)){let Ut=o.colorIndex??0;M.attr("data-color-id",`color-${Ut%p.length}`)}let se=it.rectangle(Xt,jt,wt,vt,gt),oe=M.insert(()=>se,":first-child").attr("class","outer-path").attr("style",x.join(""));V.push(0);for(let[Ut,re]of Q.entries()){let ne=(Ut+1)%2===0&&re.yOffset!==0,Le=it.rectangle(Xt,q.height+jt+re?.yOffset,wt,re?.rowHeight,{...gt,fill:ne?n:c,stroke:l});M.insert(()=>Le,"g.label").attr("style",x.join("")).attr("class",`row-rect-${ne?"even":"odd"}`)}let fe=0.0001,ge=ws(Xt,q.height+jt,wt+Xt,q.height+jt,fe),he=it.polygon(ge.map((Ut)=>[Ut.x,Ut.y]),gt);if(M.insert(()=>he).attr("class","divider"),ge=ws(tt+Xt,q.height+jt,tt+Xt,vt+jt,fe),he=it.polygon(ge.map((Ut)=>[Ut.x,Ut.y]),gt),M.insert(()=>he).attr("class","divider"),yt){let Ut=tt+at+Xt;ge=ws(Ut,q.height+jt,Ut,vt+jt,fe),he=it.polygon(ge.map((re)=>[re.x,re.y]),gt),M.insert(()=>he).attr("class","divider")}if(Bt){let Ut=tt+at+ot+Xt;ge=ws(Ut,q.height+jt,Ut,vt+jt,fe),he=it.polygon(ge.map((re)=>[re.x,re.y]),gt),M.insert(()=>he).attr("class","divider")}for(let Ut of V){let re=q.height+jt+Ut;ge=ws(Xt,re,wt+Xt,re,fe),he=it.polygon(ge.map((ae)=>[ae.x,ae.y]),gt),M.insert(()=>he).attr("class","divider")}if(B(e,oe),w&&e.look!=="handDrawn")if(a!=null&&_S.has(a))M.selectAll("path").attr("style",w);else{let re=w.split(";")?.filter((ae)=>ae.includes("stroke"))?.map((ae)=>`${ae}`).join("; ");M.selectAll("path").attr("style",re??""),M.selectAll(".row-rect-even path").attr("style",w)}return e.intersect=function(Ut){return T.rect(e,Ut)},M}t(sd,"erBox");async function ks(r,e,o,a=0,s=0,n=[],c=""){let l=r.insert("g").attr("class",`label ${n.join(" ")}`).attr("transform",`translate(${a}, ${s})`).attr("style",c);if(e!==nr(e))e=nr(e),e=e.replaceAll("<","<").replaceAll(">",">");let p=l.node().appendChild(await ct(l,e,{width:Pt(e,o)+100,style:c,useHtmlLabels:o.htmlLabels},o));if(e.includes("<")||e.includes(">")){let u=p.children[0];u.textContent=u.textContent.replaceAll("<","<").replaceAll(">",">");while(u.childNodes[0])u=u.childNodes[0],u.textContent=u.textContent.replaceAll("<","<").replaceAll(">",">")}let m=p.getBBox();if(ln(o.htmlLabels)){let u=p.children[0];u.style.textAlign="start";let y=g(p);m=u.getBoundingClientRect(),y.attr("width",m.width),y.attr("height",m.height)}return m}t(ks,"addText");function ws(r,e,o,a,s){if(r===o)return[{x:r-s/2,y:e},{x:r+s/2,y:e},{x:o+s/2,y:a},{x:o-s/2,y:a}];return[{x:r,y:e-s/2},{x:r,y:e+s/2},{x:o,y:a+s/2},{x:o,y:a-s/2}]}t(ws,"lineToPolygon");async function C0(r,e,o,a,s=o.class.padding??12){let n=!a?3:0,c=r.insert("g").attr("class",te(e)).attr("id",e.domId||e.id),l=null,p=null,m=null,u=null,y=0,x=0,k=0;if(l=c.insert("g").attr("class","annotation-group text"),e.annotations.length>0){let Y=e.annotations[0];await en(l,{text:`«${Y}»`},0),y=l.node().getBBox().height}p=c.insert("g").attr("class","label-group text"),await en(p,e,0,["font-weight: bolder"]);let w=p.node().getBBox();x=w.height,m=c.insert("g").attr("class","members-group text");let _=0;for(let Y of e.members){let V=await en(m,Y,_,[Y.parseClassifier()]);_+=V+n}if(k=m.node().getBBox().height,k<=0)k=s/2;u=c.insert("g").attr("class","methods-group text");let M=0;for(let Y of e.methods){let V=await en(u,Y,M,[Y.parseClassifier()]);M+=V+n}let q=c.node().getBBox();if(l!==null){let Y=l.node().getBBox();l.attr("transform",`translate(${-Y.width/2})`)}return p.attr("transform",`translate(${-w.width/2}, ${y})`),q=c.node().getBBox(),m.attr("transform",`translate(0, ${y+x+s*2})`),q=c.node().getBBox(),u.attr("transform",`translate(0, ${y+x+(k?k+s*4:s*2)})`),q=c.node().getBBox(),{shapeSvg:c,bbox:q}}t(C0,"textHelper");async function en(r,e,o,a=[]){let s=r.insert("g").attr("class","label").attr("style",a.join("; ")),n=A(),c="useHtmlLabels"in e?e.useHtmlLabels:ln(n.htmlLabels)??!0,l="";if("text"in e)l=e.text;else l=e.label;if(!c&&l.startsWith("\\"))l=l.substring(1);if($e(l))c=!0;let p=await ct(s,Rn(Fn(l)),{width:Pt(l,n)+50,classes:"markdown-node-label",useHtmlLabels:c},n),m,u=1;if(!c){if(a.includes("font-weight: bolder"))g(p).selectAll("tspan").attr("font-weight","");u=p.children.length;let y=p.children[0];if(p.textContent===""||p.textContent.includes(">")){if(y.textContent=l[0]+l.substring(1).replaceAll(">",">").replaceAll("<","<").trim(),l[1]===" ")y.textContent=y.textContent[0]+" "+y.textContent.substring(1)}if(y.textContent==="undefined")y.textContent="";m=p.getBBox()}else{let y=p.children[0],x=g(p);if(u=y.innerHTML.split("<br>").length,y.innerHTML.includes("</math>"))u+=y.innerHTML.split("<mrow>").length-1;await td(y),m=y.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}return s.attr("transform","translate(0,"+(-m.height/(2*u)+o)+")"),m.height}t(en,"addText");async function b0(r,e){let o=d(),{theme:a,themeVariables:s}=o,{useGradient:n,borderColorArray:c}=s,l=o.class.padding??12,p=l,m=e.useHtmlLabels??ln(o.htmlLabels)??!0,u=e;u.annotations=u.annotations??[],u.members=u.members??[],u.methods=u.methods??[];let{shapeSvg:y,bbox:x}=await C0(r,e,o,m,p);It(y,e.colorIndex,a,c);let{labelStyles:k,nodeStyles:w}=E(e);e.labelStyle=k,e.cssStyles=u.styles||"";let _=u.styles?.join(";")||w||"";if(!e.cssStyles)e.cssStyles=_.replaceAll("!important","").split(";");let M=u.members.length===0&&u.methods.length===0&&!o.class?.hideEmptyMembersBox,q=v.svg(y),Y=Kt(e,{});if(e.look!=="handDrawn")Y.roughness=0,Y.fillStyle="solid";let V=Math.max(e.width??0,x.width),Q=Math.max(e.height??0,x.height),tt=(e.height??0)>x.height;if(u.members.length===0&&u.methods.length===0)Q+=p;else if(u.members.length>0&&u.methods.length===0)Q+=p*2;let at=-V/2,ot=-Q/2,ht=M?l*2:u.members.length===0&&u.methods.length===0?-l:0;if(tt)ht=l*2;let yt=q.rectangle(at-l,ot-l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0),V+2*l,Q+2*l+ht,Y),Bt=y.insert(()=>yt,":first-child");Bt.attr("class","basic label-container outer-path");let kt=Bt.node().getBBox(),Ct=y.select(".annotation-group").node().getBBox().height-(M?l/2:0)||0,rt=y.select(".label-group").node().getBBox().height-(M?l/2:0)||0,it=y.select(".members-group").node().getBBox().height-(M?l/2:0)||0,gt=(Ct+rt+ot+l-(ot-l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0)))/2;if(y.selectAll(".text").each((et,wt,vt)=>{let Xt=g(vt[wt]),jt=Xt.attr("transform"),se=0;if(jt){let he=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(jt);if(he)se=parseFloat(he[2])}let oe=se+ot+l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0);if(Xt.attr("class").includes("methods-group")){let ge=Math.max(it,p/2);if(tt)oe=Math.max(gt,Ct+rt+ge+ot+p*2+l)+p*2;else oe=Ct+rt+ge+ot+p*4+l}if(u.members.length===0&&u.methods.length===0&&o.class?.hideEmptyMembersBox)if(u.annotations.length>0)oe=se-p;else oe=se;if(!m)oe-=4;let fe=at;if(Xt.attr("class").includes("label-group")||Xt.attr("class").includes("annotation-group"))fe=-Xt.node()?.getBBox().width/2||0,y.selectAll("text").each(function(ge,he,Ut){if(window.getComputedStyle(Ut[he]).textAnchor==="middle")fe=0});Xt.attr("transform",`translate(${fe}, ${oe})`)}),u.members.length>0||u.methods.length>0||M){let et=Ct+rt+ot+l,wt=q.line(kt.x,et,kt.x+kt.width,et+0.001,Y);y.insert(()=>wt).attr("class",`divider${e.look==="neo"&&!n?" neo-line":""}`).attr("style",_)}if(M||u.members.length>0||u.methods.length>0){let et=Ct+rt+it+ot+p*2+l,wt=q.line(kt.x,tt?Math.max(gt,et):et,kt.x+kt.width,(tt?Math.max(gt,et):et)+0.001,Y);y.insert(()=>wt).attr("class",`divider${e.look==="neo"&&!n?" neo-line":""}`).attr("style",_)}if(u.look!=="handDrawn")y.selectAll("path").attr("style",_);if(Bt.select(":nth-child(2)").attr("style",_),y.selectAll(".divider").select("path").attr("style",_),e.labelStyle)y.selectAll("span").attr("style",e.labelStyle);else y.selectAll("span").attr("style",_);if(!m){let et=RegExp(/color\s*:\s*([^;]*)/),wt=et.exec(_);if(wt){let vt=wt[0].replace("color","fill");y.selectAll("tspan").attr("style",vt)}else if(k){let vt=et.exec(k);if(vt){let Xt=vt[0].replace("color","fill");y.selectAll("tspan").attr("style",Xt)}}}return B(e,Bt),e.intersect=function(et){return T.rect(e,et)},y}t(b0,"classBox");async function k0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e,n=e,c=20,l=20,p="verifyMethod"in e,m=te(e),u=d(),{themeVariables:y}=u,{borderColorArray:x,requirementEdgeLabelBackground:k}=y,w=u.layout==="elk"?"start":"center",_=r.insert("g").attr("class",m).attr("id",e.domId??e.id),M;if(p)M=await hi(_,`<<${s.type}>>`,0,e.labelStyle);else M=await hi(_,"<<Element>>",0,e.labelStyle);let q=M,Y=await hi(_,s.name,q,e.labelStyle+"; font-weight: bold;");if(q+=Y+l,p){let kt=await hi(_,`${s.requirementId?`ID: ${s.requirementId}`:""}`,q,e.labelStyle,w);q+=kt;let Ct=await hi(_,`${s.text?`Text: ${s.text}`:""}`,q,e.labelStyle,w);q+=Ct;let rt=await hi(_,`${s.risk?`Risk: ${s.risk}`:""}`,q,e.labelStyle,w);q+=rt,await hi(_,`${s.verifyMethod?`Verification: ${s.verifyMethod}`:""}`,q,e.labelStyle,w)}else{let kt=await hi(_,`${n.type?`Type: ${n.type}`:""}`,q,e.labelStyle,w);q+=kt,await hi(_,`${n.docRef?`Doc Ref: ${n.docRef}`:""}`,q,e.labelStyle,w)}let V=(_.node()?.getBBox().width??200)+c,Q=(_.node()?.getBBox().height??200)+c,tt=-V/2,at=-Q/2,ot=v.svg(_),ht=Kt(e,{});if(e.look!=="handDrawn")ht.roughness=0,ht.fillStyle="solid";let yt=ot.rectangle(tt,at,V,Q,ht),Bt=_.insert(()=>yt,":first-child");if(Bt.attr("class","basic label-container outer-path").attr("style",a),x?.length){let kt=e.colorIndex??0;_.attr("data-color-id",`color-${kt%x.length}`)}if(_.selectAll(".label").each((kt,Ct,rt)=>{let it=g(rt[Ct]),gt=it.attr("transform"),et=0,wt=0;if(gt){let se=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(gt);if(se)et=parseFloat(se[1]),wt=parseFloat(se[2])}let vt=wt-Q/2,Xt=tt+c/2;if(Ct===0||Ct===1)Xt=et;it.attr("transform",`translate(${Xt}, ${vt+c})`)}),q>M+Y+l){let kt=at+M+Y+l,Ct;if(e.look==="neo"){let gt=[[tt,kt],[tt+V,kt],[tt+V,kt+0.001],[tt,kt+0.001]];Ct=ot.polygon(gt,ht)}else Ct=ot.line(tt,kt,tt+V,kt,ht);_.insert(()=>Ct).attr("class","divider")}if(B(e,Bt),e.intersect=function(kt){return T.rect(e,kt)},a&&e.look!=="handDrawn"&&(k||x?.length))_.selectAll("path").attr("style",a);return _}t(k0,"requirementBox");async function hi(r,e,o,a="",s="center"){if(e==="")return 0;let n=r.insert("g").attr("class","label").attr("style",a),c=d(),l=c.htmlLabels??!0,p=await ct(n,Rn(Fn(e)),{width:Pt(e,c)+50,classes:"markdown-node-label",useHtmlLabels:l,style:a},c),m;if(!l){let u=p.children[0];for(let y of u.children)if(a)y.setAttribute("style",a);if(s==="start"){u.setAttribute("text-anchor","start");for(let y of u.children)y.setAttribute("text-anchor","start")}m=p.getBBox(),m.height+=6}else{let u=p.children[0],y=g(p);if(s==="start")g(u).style("text-align","left");m=u.getBoundingClientRect(),y.attr("width",m.width),y.attr("height",m.height)}return n.attr("transform",`translate(${-m.width/2},${-m.height/2+o})`),m.height}t(hi,"addText");var BS=t((r)=>{switch(r){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function w0(r,e,{config:o}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a||"";let n=10,c=e.width;e.width=(e.width??200)-10;let{shapeSvg:l,bbox:p,label:m}=await U(r,e,te(e)),u=e.padding||10,y="",x;if("ticket"in e&&e.ticket&&o?.kanban?.ticketBaseUrl)y=o?.kanban?.ticketBaseUrl.replace("#TICKET#",e.ticket),x=l.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",y).attr("target","_blank");let k={useHtmlLabels:e.useHtmlLabels,labelStyle:e.labelStyle||"",width:e.width,img:e.img,padding:e.padding||8,centerLabel:!1},w,_;if(x)({label:w,bbox:_}=await uo(x,"ticket"in e&&e.ticket||"",k));else({label:w,bbox:_}=await uo(l,"ticket"in e&&e.ticket||"",k));let{label:M,bbox:q}=await uo(l,"assigned"in e&&e.assigned||"",k);e.width=c;let Y=10,V=e?.width||0,Q=Math.max(_.height,q.height)/2,tt=Math.max(p.height+Y*2,e?.height||0)+Q,at=-V/2,ot=-tt/2;m.attr("transform","translate("+(u-V/2)+", "+(-Q-p.height/2)+")"),w.attr("transform","translate("+(u-V/2)+", "+(-Q+p.height/2)+")"),M.attr("transform","translate("+(u+V/2-q.width-2*n)+", "+(-Q+p.height/2)+")");let ht,{rx:yt,ry:Bt}=e,{cssStyles:kt}=e;if(e.look==="handDrawn"){let Ct=v.svg(l),rt=Kt(e,{}),it=yt||Bt?Ct.path(Tr(at,ot,V,tt,yt||0),rt):Ct.rectangle(at,ot,V,tt,rt);ht=l.insert(()=>it,":first-child"),ht.attr("class","basic label-container").attr("style",kt?kt:null)}else{ht=l.insert("rect",":first-child"),ht.attr("class","basic label-container __APA__").attr("style",s).attr("rx",yt??5).attr("ry",Bt??5).attr("x",at).attr("y",ot).attr("width",V).attr("height",tt);let Ct="priority"in e&&e.priority;if(Ct){let rt=l.append("line"),it=at+2,gt=ot+Math.floor((yt??0)/2),et=ot+tt-Math.floor((yt??0)/2);rt.attr("x1",it).attr("y1",gt).attr("x2",it).attr("y2",et).attr("stroke-width","4").attr("stroke",BS(Ct))}}return B(e,ht),e.height=tt,e.intersect=function(Ct){return T.rect(e,Ct)},l}t(w0,"kanbanItem");async function S0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c,label:l}=await U(r,e,te(e)),p=n.width+10*c,m=n.height+8*c,u=0.15*p,{cssStyles:y}=e,x=n.width+20,k=n.height+20,w=Math.max(p,x),_=Math.max(m,k);l.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`);let M,q=`M0 0
|
|
239
|
+
l${-o},0`,"createCylinderPathD"),SS=t((r,e,o,a,s,n)=>[`M${r},${e}`,`M${r+o},${e}`,`a${s},${n} 0,0,0 0,${-a}`,`l${-o},0`,`a${s},${n} 0,0,0 0,${a}`,`l${o},0`].join(" "),"createOuterCylinderPathD"),TS=t((r,e,o,a,s,n)=>[`M${r+o/2},${-a/2}`,`a${s},${n} 0,0,0 0,${a}`].join(" "),"createInnerCylinderPathD"),zy=5,Hy=10;async function f0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?12:s/2,c=e.height??0;if(e.height){if(e.height=e.height-n,e.height<zy)e.height=zy}if(e.width){let W=c/2/(2.5+c/50);if(e.width=e.width-n-W*3,e.width<Hy)e.width=Hy}let{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=Math.max(e.height??0,p.height)+n,y=u/2,x=y/(2.5+u/50),k=Math.max(e.width??0,p.width)+x+n,{cssStyles:w}=e,_;if(e.look==="handDrawn"){let M=v.svg(l),W=SS(0,0,k,u,x,y),U=TS(0,0,k,u,x,y),V=M.path(W,Kt(e,{})),Z=M.path(U,Kt(e,{fill:"none"}));if(_=l.insert(()=>Z,":first-child"),_=l.insert(()=>V,":first-child"),_.attr("class","basic label-container"),w)_.attr("style",w)}else{let M=wS(0,0,k,u,x,y);if(_=l.insert("path",":first-child").attr("d",M).attr("class","basic label-container").attr("style",Fe(w)).attr("style",a),_.attr("class","basic label-container outer-path"),w)_.selectAll("path").attr("style",w);if(a)_.selectAll("path").attr("style",a)}return _.attr("label-offset-x",x),_.attr("transform",`translate(${-k/2}, ${u/2} )`),m.attr("transform",`translate(${-(p.width/2)-x-(p.x-(p.left??0))}, ${-(p.height/2)-(p.y-(p.top??0))})`),B(e,_),e.intersect=function(M){let W=T.rect(e,M),U=W.y-(e.y??0);if(y!=0&&(Math.abs(U)<(e.height??0)/2||Math.abs(U)==(e.height??0)/2&&Math.abs(W.x-(e.x??0))>(e.width??0)/2-x)){let V=x*x*(1-U*U/(y*y));if(V!=0)V=Math.sqrt(Math.abs(V));if(V=x-V,M.x-(e.x??0)>0)V=-V;W.x+=V}return W},l}t(f0,"tiltedCylinder");async function d0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?s:s,c=e.look==="neo"?s*2:s,{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=Math.max(p.height+n,e.height??0),u=Math.max(p.width+c,(e.width??0)-m),y=[{x:-3*m/6,y:0},{x:u+3*m/6,y:0},{x:u,y:-m},{x:0,y:-m}],x,{cssStyles:k}=e;if(e.look==="handDrawn"){let w=v.svg(l),_=Kt(e,{}),M=ye(y),W=w.path(M,_);if(x=l.insert(()=>W,":first-child").attr("transform",`translate(${-u/2}, ${m/2})`),k)x.attr("style",k)}else x=fi(l,u,m,y);if(a)x.attr("style",a);return e.width=u,e.height=m,B(e,x),e.intersect=function(w){return T.polygon(e,y,w)},l}t(d0,"trapezoid");async function p0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=15,p=5;if(e.width||e.height){if(e.height=(e.height??0)-c*2,e.height<p)e.height=p;if(e.width=(e.width??0)-n*2,e.width<l)e.width=l}let{shapeSvg:m,bbox:u}=await j(r,e,te(e)),y=(e?.width?e?.width:u.width)+n*2,x=(e?.height?e?.height:u.height)+c*2,{cssStyles:k}=e,w=v.svg(m),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=[{x:-y/2*0.8,y:-x/2},{x:y/2*0.8,y:-x/2},{x:y/2,y:-x/2*0.6},{x:y/2,y:x/2},{x:-y/2,y:x/2},{x:-y/2,y:-x/2*0.6}],W=ye(M),U=w.path(W,_),V=m.insert(()=>U,":first-child");if(V.attr("class","basic label-container outer-path"),k&&e.look!=="handDrawn")V.selectChildren("path").attr("style",k);if(a&&e.look!=="handDrawn")V.selectChildren("path").attr("style",a);return B(e,V),e.intersect=function(Z){return T.polygon(e,M,Z)},m}t(p0,"trapezoidalPentagon");var Yy=10,Uy=10;async function g0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?s*2:s;if(e.width||e.height){if(e.width=((e?.width??0)-n)/2,e.width<Uy)e.width=Uy;if(e.height=e?.height??0,e.height<Yy)e.height=Yy}let{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=ln(d().flowchart?.htmlLabels),u=(e?.width?e?.width:l.width)+n,y=e?.height?e?.height:u+l.height,x=y,k=[{x:0,y:0},{x,y:0},{x:x/2,y:-y}],{cssStyles:w}=e,_=v.svg(c),M=Kt(e,{});if(e.look!=="handDrawn")M.roughness=0,M.fillStyle="solid";let W=ye(k),U=_.path(W,M),V=c.insert(()=>U,":first-child").attr("transform",`translate(${-y/2}, ${y/2})`).attr("class","outer-path");if(w&&e.look!=="handDrawn")V.selectChildren("path").attr("style",w);if(a&&e.look!=="handDrawn")V.selectChildren("path").attr("style",a);return e.width=u,e.height=y,B(e,V),p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))}, ${y/2-(l.height+(e.padding??0)/(m?2:1)-(l.y-(l.top??0)))})`),e.intersect=function(Z){return i.info("Triangle intersect",e,k,Z),T.polygon(e,k,Z)},c}t(g0,"triangle");async function m0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?12:s,l=!0;if(e.width||e.height){if(l=!1,e.width=(e?.width??0)-n*2,e.width<10)e.width=10;if(e.height=(e?.height??0)-c*2,e.height<10)e.height=10}let{shapeSvg:p,bbox:m,label:u}=await j(r,e,te(e)),y=(e?.width?e?.width:m.width)+(n??0)*2,x=(e?.height?e?.height:m.height)+(c??0)*2,k=e.look==="neo"?x/4:x/8,w=x+(l?k:-k),{cssStyles:_}=e,W=14-y,U=W>0?W/2:0,V=v.svg(p),Z=Kt(e,{});if(e.look!=="handDrawn")Z.roughness=0,Z.fillStyle="solid";let tt=[{x:-y/2-U,y:w/2},...Ji(-y/2-U,w/2,y/2+U,w/2,k,0.8),{x:y/2+U,y:-w/2},{x:-y/2-U,y:-w/2}],at=ye(tt),ot=V.path(at,Z),ht=p.insert(()=>ot,":first-child");if(ht.attr("class","basic label-container outer-path"),_&&e.look!=="handDrawn")ht.selectAll("path").attr("style",_);if(a&&e.look!=="handDrawn")ht.selectAll("path").attr("style",a);return ht.attr("transform",`translate(0,${-k/2})`),u.attr("transform",`translate(${-y/2+(e.padding??0)-(m.x-(m.left??0))},${-x/2+(e.padding??0)-k-(m.y-(m.top??0))})`),B(e,ht),e.intersect=function(yt){return T.polygon(e,tt,yt)},p}t(m0,"waveEdgedRectangle");async function y0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.padding??0,n=e.look==="neo"?16:s,c=e.look==="neo"?20:s;if(e.width||e.height){if(e.width=e?.width??0,e.width<20)e.width=20;if(e.height=e?.height??0,e.height<10)e.height=10;let Z=Math.min(e.height*0.2,e.height/4);e.height=Math.ceil(e.height-c-Z*2.2222222222222223),e.width=e.width-n*2}let{shapeSvg:l,bbox:p}=await j(r,e,te(e)),m=(e?.width?e?.width:p.width)+n*2,u=(e?.height?e?.height:p.height)+c,y=u/8,x=u+y*2,{cssStyles:k}=e,w=v.svg(l),_=Kt(e,{});if(e.look!=="handDrawn")_.roughness=0,_.fillStyle="solid";let M=[{x:-m/2,y:x/2},...Ji(-m/2,x/2,m/2,x/2,y,1),{x:m/2,y:-x/2},...Ji(m/2,-x/2,-m/2,-x/2,y,-1)],W=ye(M),U=w.path(W,_),V=l.insert(()=>U,":first-child");if(V.attr("class","basic label-container"),k&&e.look!=="handDrawn")V.selectAll("path").attr("style",k);if(a&&e.look!=="handDrawn")V.selectAll("path").attr("style",a);return B(e,V),e.intersect=function(Z){return T.polygon(e,M,Z)},l}t(y0,"waveRectangle");var Oe=10;async function x0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e.look==="neo"?16:e.padding??0,n=e.look==="neo"?12:e.padding??0;if(e.width||e.height)e.width=Math.max((e?.width??0)-s*2-Oe,10),e.height=Math.max((e?.height??0)-n*2-Oe,10);let{shapeSvg:c,bbox:l,label:p}=await j(r,e,te(e)),m=(e?.width?e?.width:l.width)+s*2+Oe,u=(e?.height?e?.height:l.height)+n*2+Oe,y=m-Oe,x=u-Oe,k=-y/2,w=-x/2,{cssStyles:_}=e,M=v.svg(c),W=Kt(e,{}),U=[{x:k-Oe,y:w-Oe},{x:k-Oe,y:w+x},{x:k+y,y:w+x},{x:k+y,y:w-Oe}],V=`M${k-Oe},${w-Oe} L${k+y},${w-Oe} L${k+y},${w+x} L${k-Oe},${w+x} L${k-Oe},${w-Oe}
|
|
240
|
+
M${k-Oe},${w} L${k+y},${w}
|
|
241
|
+
M${k},${w-Oe} L${k},${w+x}`;if(e.look!=="handDrawn")W.roughness=0,W.fillStyle="solid";let Z=M.path(V,W),tt=c.insert(()=>Z,":first-child");if(tt.attr("transform",`translate(${Oe/2}, ${Oe/2})`),tt.attr("class","basic label-container outer-path"),_&&e.look!=="handDrawn")tt.selectAll("path").attr("style",_);if(a&&e.look!=="handDrawn")tt.selectAll("path").attr("style",a);return p.attr("transform",`translate(${-(l.width/2)+Oe/2-(l.x-(l.left??0))}, ${-(l.height/2)+Oe/2-(l.y-(l.top??0))})`),B(e,tt),e.intersect=function(at){return T.polygon(e,U,at)},c}t(x0,"windowPane");var jy=new Set(["redux-color","redux-dark-color"]),_S=new Set(["redux","redux-dark","redux-color","redux-dark-color"]);async function sd(r,e){let o=e;if(o.alias)e.label=o.alias;let{theme:a,themeVariables:s}=A(),{rowEven:n,rowOdd:c,nodeBorder:l,borderColorArray:p}=s;if(e.look==="handDrawn"){let{themeVariables:Ut}=A(),{background:re}=Ut,ae={...e,id:e.id+"-background",domId:(e.domId||e.id)+"-background",look:"default",cssStyles:["stroke: none",`fill: ${re}`]};await sd(r,ae)}let m=A();e.useHtmlLabels=m.htmlLabels;let u=m.er?.diagramPadding??10,y=m.er?.entityPadding??6,{cssStyles:x}=e,{labelStyles:k,nodeStyles:w}=E(e);if(o.attributes.length===0&&e.label){let Ut={rx:0,ry:0,labelPaddingX:u,labelPaddingY:u*1.5,classes:""};if(Pt(e.label,m)+Ut.labelPaddingX*2<m.er.minEntityWidth)e.width=m.er.minEntityWidth;let re=await Ss(r,e,Ut);if(a!=null&&jy.has(a)){let ae=o.colorIndex??0;re.attr("data-color-id",`color-${ae%p.length}`)}if(!ln(m.htmlLabels)){let ae=re.select("text"),ne=ae.node()?.getBBox();ae.attr("transform",`translate(${-ne.width/2}, 0)`)}return re}if(!m.htmlLabels)u*=1.25,y*=1.25;let _=te(e);if(!_)_="node default";let M=r.insert("g").attr("class",_).attr("id",e.domId||e.id),W=await ks(M,e.label??"",m,0,0,["name"],k);W.height+=y;let U=0,V=[],Z=[],tt=0,at=0,ot=0,ht=0,yt=!0,Bt=!0;for(let Ut of o.attributes){let re=await ks(M,Ut.type,m,0,U,["attribute-type"],k);tt=Math.max(tt,re.width+u);let ae=await ks(M,Ut.name,m,0,U,["attribute-name"],k);at=Math.max(at,ae.width+u);let ne=await ks(M,Ut.keys.join(),m,0,U,["attribute-keys"],k);ot=Math.max(ot,ne.width+u);let Be=await ks(M,Ut.comment,m,0,U,["attribute-comment"],k);ht=Math.max(ht,Be.width+u);let _e=Math.max(re.height,ae.height,ne.height,Be.height)+y;Z.push({yOffset:U,rowHeight:_e}),U+=_e}let kt=4;if(ot<=u)yt=!1,ot=0,kt--;if(ht<=u)Bt=!1,ht=0,kt--;let Ct=M.node().getBBox();if(W.width+u*2-(tt+at+ot+ht)>0){let Ut=W.width+u*2-(tt+at+ot+ht);if(tt+=Ut/kt,at+=Ut/kt,ot>0)ot+=Ut/kt;if(ht>0)ht+=Ut/kt}let rt=tt+at+ot+ht,it=v.svg(M),gt=Kt(e,{});if(e.look!=="handDrawn")gt.roughness=0,gt.fillStyle="solid";let et=0;if(Z.length>0)et=Z.reduce((Ut,re)=>Ut+(re?.rowHeight??0),0);let wt=Math.max(Ct.width+u*2,e?.width||0,rt),vt=Math.max((et??0)+W.height,e?.height||0),Xt=-wt/2,jt=-vt/2;if(M.selectAll("g:not(:first-child)").each((Ut,re,ae)=>{let ne=g(ae[re]),Be=ne.attr("transform"),_e=0,Dr=0;if(Be){let Mr=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(Be);if(Mr){if(_e=parseFloat(Mr[1]),Dr=parseFloat(Mr[2]),ne.attr("class").includes("attribute-name"))_e+=tt;else if(ne.attr("class").includes("attribute-keys"))_e+=tt+at;else if(ne.attr("class").includes("attribute-comment"))_e+=tt+at+ot}}ne.attr("transform",`translate(${Xt+u/2+_e}, ${Dr+jt+W.height+y/2})`)}),M.select(".name").attr("transform","translate("+-W.width/2+", "+(jt+y/2)+")"),a!=null&&jy.has(a)){let Ut=o.colorIndex??0;M.attr("data-color-id",`color-${Ut%p.length}`)}let se=it.rectangle(Xt,jt,wt,vt,gt),oe=M.insert(()=>se,":first-child").attr("class","outer-path").attr("style",x.join(""));V.push(0);for(let[Ut,re]of Z.entries()){let ne=(Ut+1)%2===0&&re.yOffset!==0,Be=it.rectangle(Xt,W.height+jt+re?.yOffset,wt,re?.rowHeight,{...gt,fill:ne?n:c,stroke:l});M.insert(()=>Be,"g.label").attr("style",x.join("")).attr("class",`row-rect-${ne?"even":"odd"}`)}let de=0.0001,ge=ws(Xt,W.height+jt,wt+Xt,W.height+jt,de),he=it.polygon(ge.map((Ut)=>[Ut.x,Ut.y]),gt);if(M.insert(()=>he).attr("class","divider"),ge=ws(tt+Xt,W.height+jt,tt+Xt,vt+jt,de),he=it.polygon(ge.map((Ut)=>[Ut.x,Ut.y]),gt),M.insert(()=>he).attr("class","divider"),yt){let Ut=tt+at+Xt;ge=ws(Ut,W.height+jt,Ut,vt+jt,de),he=it.polygon(ge.map((re)=>[re.x,re.y]),gt),M.insert(()=>he).attr("class","divider")}if(Bt){let Ut=tt+at+ot+Xt;ge=ws(Ut,W.height+jt,Ut,vt+jt,de),he=it.polygon(ge.map((re)=>[re.x,re.y]),gt),M.insert(()=>he).attr("class","divider")}for(let Ut of V){let re=W.height+jt+Ut;ge=ws(Xt,re,wt+Xt,re,de),he=it.polygon(ge.map((ae)=>[ae.x,ae.y]),gt),M.insert(()=>he).attr("class","divider")}if(B(e,oe),w&&e.look!=="handDrawn")if(a!=null&&_S.has(a))M.selectAll("path").attr("style",w);else{let re=w.split(";")?.filter((ae)=>ae.includes("stroke"))?.map((ae)=>`${ae}`).join("; ");M.selectAll("path").attr("style",re??""),M.selectAll(".row-rect-even path").attr("style",w)}return e.intersect=function(Ut){return T.rect(e,Ut)},M}t(sd,"erBox");async function ks(r,e,o,a=0,s=0,n=[],c=""){let l=r.insert("g").attr("class",`label ${n.join(" ")}`).attr("transform",`translate(${a}, ${s})`).attr("style",c);if(e!==nr(e))e=nr(e),e=e.replaceAll("<","<").replaceAll(">",">");let p=l.node().appendChild(await ct(l,e,{width:Pt(e,o)+100,style:c,useHtmlLabels:o.htmlLabels},o));if(e.includes("<")||e.includes(">")){let u=p.children[0];u.textContent=u.textContent.replaceAll("<","<").replaceAll(">",">");while(u.childNodes[0])u=u.childNodes[0],u.textContent=u.textContent.replaceAll("<","<").replaceAll(">",">")}let m=p.getBBox();if(ln(o.htmlLabels)){let u=p.children[0];u.style.textAlign="start";let y=g(p);m=u.getBoundingClientRect(),y.attr("width",m.width),y.attr("height",m.height)}return m}t(ks,"addText");function ws(r,e,o,a,s){if(r===o)return[{x:r-s/2,y:e},{x:r+s/2,y:e},{x:o+s/2,y:a},{x:o-s/2,y:a}];return[{x:r,y:e-s/2},{x:r,y:e+s/2},{x:o,y:a+s/2},{x:o,y:a-s/2}]}t(ws,"lineToPolygon");async function C0(r,e,o,a,s=o.class.padding??12){let n=!a?3:0,c=r.insert("g").attr("class",te(e)).attr("id",e.domId||e.id),l=null,p=null,m=null,u=null,y=0,x=0,k=0;if(l=c.insert("g").attr("class","annotation-group text"),e.annotations.length>0){let U=e.annotations[0];await en(l,{text:`«${U}»`},0),y=l.node().getBBox().height}p=c.insert("g").attr("class","label-group text"),await en(p,e,0,["font-weight: bolder"]);let w=p.node().getBBox();x=w.height,m=c.insert("g").attr("class","members-group text");let _=0;for(let U of e.members){let V=await en(m,U,_,[U.parseClassifier()]);_+=V+n}if(k=m.node().getBBox().height,k<=0)k=s/2;u=c.insert("g").attr("class","methods-group text");let M=0;for(let U of e.methods){let V=await en(u,U,M,[U.parseClassifier()]);M+=V+n}let W=c.node().getBBox();if(l!==null){let U=l.node().getBBox();l.attr("transform",`translate(${-U.width/2})`)}return p.attr("transform",`translate(${-w.width/2}, ${y})`),W=c.node().getBBox(),m.attr("transform",`translate(0, ${y+x+s*2})`),W=c.node().getBBox(),u.attr("transform",`translate(0, ${y+x+(k?k+s*4:s*2)})`),W=c.node().getBBox(),{shapeSvg:c,bbox:W}}t(C0,"textHelper");async function en(r,e,o,a=[]){let s=r.insert("g").attr("class","label").attr("style",a.join("; ")),n=A(),c="useHtmlLabels"in e?e.useHtmlLabels:ln(n.htmlLabels)??!0,l="";if("text"in e)l=e.text;else l=e.label;if(!c&&l.startsWith("\\"))l=l.substring(1);if($e(l))c=!0;let p=await ct(s,Rn(Fn(l)),{width:Pt(l,n)+50,classes:"markdown-node-label",useHtmlLabels:c},n),m,u=1;if(!c){if(a.includes("font-weight: bolder"))g(p).selectAll("tspan").attr("font-weight","");u=p.children.length;let y=p.children[0];if(p.textContent===""||p.textContent.includes(">")){if(y.textContent=l[0]+l.substring(1).replaceAll(">",">").replaceAll("<","<").trim(),l[1]===" ")y.textContent=y.textContent[0]+" "+y.textContent.substring(1)}if(y.textContent==="undefined")y.textContent="";m=p.getBBox()}else{let y=p.children[0],x=g(p);if(u=y.innerHTML.split("<br>").length,y.innerHTML.includes("</math>"))u+=y.innerHTML.split("<mrow>").length-1;await td(y),m=y.getBoundingClientRect(),x.attr("width",m.width),x.attr("height",m.height)}return s.attr("transform","translate(0,"+(-m.height/(2*u)+o)+")"),m.height}t(en,"addText");async function b0(r,e){let o=d(),{theme:a,themeVariables:s}=o,{useGradient:n,borderColorArray:c}=s,l=o.class.padding??12,p=l,m=e.useHtmlLabels??ln(o.htmlLabels)??!0,u=e;u.annotations=u.annotations??[],u.members=u.members??[],u.methods=u.methods??[];let{shapeSvg:y,bbox:x}=await C0(r,e,o,m,p);It(y,e.colorIndex,a,c);let{labelStyles:k,nodeStyles:w}=E(e);e.labelStyle=k,e.cssStyles=u.styles||"";let _=u.styles?.join(";")||w||"";if(!e.cssStyles)e.cssStyles=_.replaceAll("!important","").split(";");let M=u.members.length===0&&u.methods.length===0&&!o.class?.hideEmptyMembersBox,W=v.svg(y),U=Kt(e,{});if(e.look!=="handDrawn")U.roughness=0,U.fillStyle="solid";let V=Math.max(e.width??0,x.width),Z=Math.max(e.height??0,x.height),tt=(e.height??0)>x.height;if(u.members.length===0&&u.methods.length===0)Z+=p;else if(u.members.length>0&&u.methods.length===0)Z+=p*2;let at=-V/2,ot=-Z/2,ht=M?l*2:u.members.length===0&&u.methods.length===0?-l:0;if(tt)ht=l*2;let yt=W.rectangle(at-l,ot-l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0),V+2*l,Z+2*l+ht,U),Bt=y.insert(()=>yt,":first-child");Bt.attr("class","basic label-container outer-path");let kt=Bt.node().getBBox(),Ct=y.select(".annotation-group").node().getBBox().height-(M?l/2:0)||0,rt=y.select(".label-group").node().getBBox().height-(M?l/2:0)||0,it=y.select(".members-group").node().getBBox().height-(M?l/2:0)||0,gt=(Ct+rt+ot+l-(ot-l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0)))/2;if(y.selectAll(".text").each((et,wt,vt)=>{let Xt=g(vt[wt]),jt=Xt.attr("transform"),se=0;if(jt){let he=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(jt);if(he)se=parseFloat(he[2])}let oe=se+ot+l-(M?l:u.members.length===0&&u.methods.length===0?-l/2:0);if(Xt.attr("class").includes("methods-group")){let ge=Math.max(it,p/2);if(tt)oe=Math.max(gt,Ct+rt+ge+ot+p*2+l)+p*2;else oe=Ct+rt+ge+ot+p*4+l}if(u.members.length===0&&u.methods.length===0&&o.class?.hideEmptyMembersBox)if(u.annotations.length>0)oe=se-p;else oe=se;if(!m)oe-=4;let de=at;if(Xt.attr("class").includes("label-group")||Xt.attr("class").includes("annotation-group"))de=-Xt.node()?.getBBox().width/2||0,y.selectAll("text").each(function(ge,he,Ut){if(window.getComputedStyle(Ut[he]).textAnchor==="middle")de=0});Xt.attr("transform",`translate(${de}, ${oe})`)}),u.members.length>0||u.methods.length>0||M){let et=Ct+rt+ot+l,wt=W.line(kt.x,et,kt.x+kt.width,et+0.001,U);y.insert(()=>wt).attr("class",`divider${e.look==="neo"&&!n?" neo-line":""}`).attr("style",_)}if(M||u.members.length>0||u.methods.length>0){let et=Ct+rt+it+ot+p*2+l,wt=W.line(kt.x,tt?Math.max(gt,et):et,kt.x+kt.width,(tt?Math.max(gt,et):et)+0.001,U);y.insert(()=>wt).attr("class",`divider${e.look==="neo"&&!n?" neo-line":""}`).attr("style",_)}if(u.look!=="handDrawn")y.selectAll("path").attr("style",_);if(Bt.select(":nth-child(2)").attr("style",_),y.selectAll(".divider").select("path").attr("style",_),e.labelStyle)y.selectAll("span").attr("style",e.labelStyle);else y.selectAll("span").attr("style",_);if(!m){let et=RegExp(/color\s*:\s*([^;]*)/),wt=et.exec(_);if(wt){let vt=wt[0].replace("color","fill");y.selectAll("tspan").attr("style",vt)}else if(k){let vt=et.exec(k);if(vt){let Xt=vt[0].replace("color","fill");y.selectAll("tspan").attr("style",Xt)}}}return B(e,Bt),e.intersect=function(et){return T.rect(e,et)},y}t(b0,"classBox");async function k0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let s=e,n=e,c=20,l=20,p="verifyMethod"in e,m=te(e),u=d(),{themeVariables:y}=u,{borderColorArray:x,requirementEdgeLabelBackground:k}=y,w=u.layout==="elk"?"start":"center",_=r.insert("g").attr("class",m).attr("id",e.domId??e.id),M;if(p)M=await hi(_,`<<${s.type}>>`,0,e.labelStyle);else M=await hi(_,"<<Element>>",0,e.labelStyle);let W=M,U=await hi(_,s.name,W,e.labelStyle+"; font-weight: bold;");if(W+=U+l,p){let kt=await hi(_,`${s.requirementId?`ID: ${s.requirementId}`:""}`,W,e.labelStyle,w);W+=kt;let Ct=await hi(_,`${s.text?`Text: ${s.text}`:""}`,W,e.labelStyle,w);W+=Ct;let rt=await hi(_,`${s.risk?`Risk: ${s.risk}`:""}`,W,e.labelStyle,w);W+=rt,await hi(_,`${s.verifyMethod?`Verification: ${s.verifyMethod}`:""}`,W,e.labelStyle,w)}else{let kt=await hi(_,`${n.type?`Type: ${n.type}`:""}`,W,e.labelStyle,w);W+=kt,await hi(_,`${n.docRef?`Doc Ref: ${n.docRef}`:""}`,W,e.labelStyle,w)}let V=(_.node()?.getBBox().width??200)+c,Z=(_.node()?.getBBox().height??200)+c,tt=-V/2,at=-Z/2,ot=v.svg(_),ht=Kt(e,{});if(e.look!=="handDrawn")ht.roughness=0,ht.fillStyle="solid";let yt=ot.rectangle(tt,at,V,Z,ht),Bt=_.insert(()=>yt,":first-child");if(Bt.attr("class","basic label-container outer-path").attr("style",a),x?.length){let kt=e.colorIndex??0;_.attr("data-color-id",`color-${kt%x.length}`)}if(_.selectAll(".label").each((kt,Ct,rt)=>{let it=g(rt[Ct]),gt=it.attr("transform"),et=0,wt=0;if(gt){let se=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(gt);if(se)et=parseFloat(se[1]),wt=parseFloat(se[2])}let vt=wt-Z/2,Xt=tt+c/2;if(Ct===0||Ct===1)Xt=et;it.attr("transform",`translate(${Xt}, ${vt+c})`)}),W>M+U+l){let kt=at+M+U+l,Ct;if(e.look==="neo"){let gt=[[tt,kt],[tt+V,kt],[tt+V,kt+0.001],[tt,kt+0.001]];Ct=ot.polygon(gt,ht)}else Ct=ot.line(tt,kt,tt+V,kt,ht);_.insert(()=>Ct).attr("class","divider")}if(B(e,Bt),e.intersect=function(kt){return T.rect(e,kt)},a&&e.look!=="handDrawn"&&(k||x?.length))_.selectAll("path").attr("style",a);return _}t(k0,"requirementBox");async function hi(r,e,o,a="",s="center"){if(e==="")return 0;let n=r.insert("g").attr("class","label").attr("style",a),c=d(),l=c.htmlLabels??!0,p=await ct(n,Rn(Fn(e)),{width:Pt(e,c)+50,classes:"markdown-node-label",useHtmlLabels:l,style:a},c),m;if(!l){let u=p.children[0];for(let y of u.children)if(a)y.setAttribute("style",a);if(s==="start"){u.setAttribute("text-anchor","start");for(let y of u.children)y.setAttribute("text-anchor","start")}m=p.getBBox(),m.height+=6}else{let u=p.children[0],y=g(p);if(s==="start")g(u).style("text-align","left");m=u.getBoundingClientRect(),y.attr("width",m.width),y.attr("height",m.height)}return n.attr("transform",`translate(${-m.width/2},${-m.height/2+o})`),m.height}t(hi,"addText");var BS=t((r)=>{switch(r){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function w0(r,e,{config:o}){let{labelStyles:a,nodeStyles:s}=E(e);e.labelStyle=a||"";let n=10,c=e.width;e.width=(e.width??200)-10;let{shapeSvg:l,bbox:p,label:m}=await j(r,e,te(e)),u=e.padding||10,y="",x;if("ticket"in e&&e.ticket&&o?.kanban?.ticketBaseUrl)y=o?.kanban?.ticketBaseUrl.replace("#TICKET#",e.ticket),x=l.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",y).attr("target","_blank");let k={useHtmlLabels:e.useHtmlLabels,labelStyle:e.labelStyle||"",width:e.width,img:e.img,padding:e.padding||8,centerLabel:!1},w,_;if(x)({label:w,bbox:_}=await uo(x,"ticket"in e&&e.ticket||"",k));else({label:w,bbox:_}=await uo(l,"ticket"in e&&e.ticket||"",k));let{label:M,bbox:W}=await uo(l,"assigned"in e&&e.assigned||"",k);e.width=c;let U=10,V=e?.width||0,Z=Math.max(_.height,W.height)/2,tt=Math.max(p.height+U*2,e?.height||0)+Z,at=-V/2,ot=-tt/2;m.attr("transform","translate("+(u-V/2)+", "+(-Z-p.height/2)+")"),w.attr("transform","translate("+(u-V/2)+", "+(-Z+p.height/2)+")"),M.attr("transform","translate("+(u+V/2-W.width-2*n)+", "+(-Z+p.height/2)+")");let ht,{rx:yt,ry:Bt}=e,{cssStyles:kt}=e;if(e.look==="handDrawn"){let Ct=v.svg(l),rt=Kt(e,{}),it=yt||Bt?Ct.path(Tr(at,ot,V,tt,yt||0),rt):Ct.rectangle(at,ot,V,tt,rt);ht=l.insert(()=>it,":first-child"),ht.attr("class","basic label-container").attr("style",kt?kt:null)}else{ht=l.insert("rect",":first-child"),ht.attr("class","basic label-container __APA__").attr("style",s).attr("rx",yt??5).attr("ry",Bt??5).attr("x",at).attr("y",ot).attr("width",V).attr("height",tt);let Ct="priority"in e&&e.priority;if(Ct){let rt=l.append("line"),it=at+2,gt=ot+Math.floor((yt??0)/2),et=ot+tt-Math.floor((yt??0)/2);rt.attr("x1",it).attr("y1",gt).attr("x2",it).attr("y2",et).attr("stroke-width","4").attr("stroke",BS(Ct))}}return B(e,ht),e.height=tt,e.intersect=function(Ct){return T.rect(e,Ct)},l}t(w0,"kanbanItem");async function S0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c,label:l}=await j(r,e,te(e)),p=n.width+10*c,m=n.height+8*c,u=0.15*p,{cssStyles:y}=e,x=n.width+20,k=n.height+20,w=Math.max(p,x),_=Math.max(m,k);l.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`);let M,W=`M0 0
|
|
242
242
|
a${u},${u} 1 0,0 ${w*0.25},${-1*_*0.1}
|
|
243
243
|
a${u},${u} 1 0,0 ${w*0.25},0
|
|
244
244
|
a${u},${u} 1 0,0 ${w*0.25},0
|
|
@@ -256,7 +256,7 @@ ${s.join(`
|
|
|
256
256
|
a${u},${u} 1 0,0 ${-1*w*0.1},${-1*_*0.33}
|
|
257
257
|
a${u*0.8},${u*0.8} 1 0,0 0,${-1*_*0.34}
|
|
258
258
|
a${u},${u} 1 0,0 ${w*0.1},${-1*_*0.33}
|
|
259
|
-
H0 V0 Z`;if(e.look==="handDrawn"){let
|
|
259
|
+
H0 V0 Z`;if(e.look==="handDrawn"){let U=v.svg(s),V=Kt(e,{}),Z=U.path(W,V);M=s.insert(()=>Z,":first-child"),M.attr("class","basic label-container").attr("style",Fe(y))}else M=s.insert("path",":first-child").attr("class","basic label-container").attr("style",a).attr("d",W);return M.attr("transform",`translate(${-w/2}, ${-_/2})`),B(e,M),e.calcIntersect=function(U,V){return T.rect(U,V)},e.intersect=function(U){return i.info("Bang intersect",e,U),T.rect(e,U)},s}t(S0,"bang");async function T0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c,label:l}=await j(r,e,te(e)),p=n.width+2*c,m=n.height+2*c,u=0.15*p,y=0.25*p,x=0.35*p,k=0.2*p,{cssStyles:w}=e,_,M=`M0 0
|
|
260
260
|
a${u},${u} 0 0,1 ${p*0.25},${-1*p*0.1}
|
|
261
261
|
a${x},${x} 1 0,1 ${p*0.4},${-1*p*0.1}
|
|
262
262
|
a${y},${y} 1 0,1 ${p*0.35},${p*0.2}
|
|
@@ -270,7 +270,7 @@ ${s.join(`
|
|
|
270
270
|
|
|
271
271
|
a${u},${u} 1 0,1 ${-1*p*0.1},${-1*m*0.35}
|
|
272
272
|
a${k},${k} 1 0,1 ${p*0.1},${-1*m*0.65}
|
|
273
|
-
H0 V0 Z`;if(e.look==="handDrawn"){let
|
|
273
|
+
H0 V0 Z`;if(e.look==="handDrawn"){let W=v.svg(s),U=Kt(e,{}),V=W.path(M,U);_=s.insert(()=>V,":first-child"),_.attr("class","basic label-container").attr("style",Fe(w))}else _=s.insert("path",":first-child").attr("class","basic label-container").attr("style",a).attr("d",M);return l.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`),_.attr("transform",`translate(${-p/2}, ${-m/2})`),B(e,_),e.calcIntersect=function(W,U){return T.rect(W,U)},e.intersect=function(W){return i.info("Cloud intersect",e,W),T.rect(e,W)},s}t(T0,"cloud");async function _0(r,e){let{labelStyles:o,nodeStyles:a}=E(e);e.labelStyle=o;let{shapeSvg:s,bbox:n,halfPadding:c,label:l}=await j(r,e,te(e)),p=n.width+8*c,m=n.height+2*c,u=5,y=e.look==="neo"?`
|
|
274
274
|
M${-p/2} ${m/2-u}
|
|
275
275
|
v${-m+2*u}
|
|
276
276
|
q0,-${u} ${u},-${u}
|
|
@@ -290,14 +290,14 @@ ${s.join(`
|
|
|
290
290
|
h${-(p-2*u)}
|
|
291
291
|
q${-u},0 ${-u},${-u}
|
|
292
292
|
Z
|
|
293
|
-
`;if(!e.domId)throw Error(`defaultMindmapNode: node "${e.id}" is missing a domId — was render.ts domId prefixing skipped?`);let x=s.append("path").attr("id",e.domId).attr("class","node-bkg node-"+e.type).attr("style",a).attr("d",y);return s.append("line").attr("class","node-line-").attr("x1",-p/2).attr("y1",m/2).attr("x2",p/2).attr("y2",m/2),l.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`),s.append(()=>l.node()),B(e,x),e.calcIntersect=function(k,w){return T.rect(k,w)},e.intersect=function(k){return T.rect(e,k)},s}t(_0,"defaultMindmapNode");async function B0(r,e){let o={padding:e.padding??0};return id(r,e,o)}t(B0,"mindmapCircle");var vS=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:i0},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:t0},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:o0},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:l0},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:xx},{semanticName:"Data Store",name:"Data Store",shortName:"datastore",description:"Data flow diagram data store",aliases:["data-store"],handler:Cx},{semanticName:"Folder",name:"Folder",shortName:"folder",description:"Folder or directory",aliases:["directory"],handler:_x},{semanticName:"Bucket",name:"Bucket",shortName:"bucket",description:"Object storage bucket",handler:rx},{semanticName:"Console",name:"Console (terminal window)",shortName:"console",description:"Terminal or console window",handler:cx},{semanticName:"Browser",name:"Browser",shortName:"browser",description:"Browser window",handler:ax},{semanticName:"Person",name:"Person",shortName:"person",description:"Person (circular head above a rounded body)",handler:yx},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:id},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:S0},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:T0},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Zx},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:Lx},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:Rx},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:Px},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:d0},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:$x},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:kx},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:u0},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:nx},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:e0},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:n0},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:a0},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:Bx},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:Fx},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:dx},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:px},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:gx},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:qx},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:m0},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:vx},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:f0},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:Nx},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:mx},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:bx},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:g0},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:x0},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:Sx},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:p0},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:Tx},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:r0},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:Vx},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:Xx},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:ex},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:fx},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:c0},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:h0},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:y0},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:Qx},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:Wx}],LS=t(()=>{let e=[...Object.entries({state:s0,choice:lx,note:Kx,composite:hx,rectWithTitle:Jx,labelRect:Dx,block_arrow:sx,collapsedGroup:ox,iconSquare:Ox,iconCircle:Mx,icon:Ax,iconRounded:Ex,imageSquare:Ix,anchor:Jy,kanbanItem:w0,mindmapCircle:B0,defaultMindmapNode:_0,classBox:b0,erBox:sd,requirementBox:k0,usecaseActor:zx,usecaseActorHollow:Yx,usecaseActorAwesome:Hx,usecaseActorIcon:Ux,usecaseBusiness:jx,usecaseEllipse:wx,usecaseJsonTable:Gx}),...vS.flatMap((o)=>[o.shortName,..."aliases"in o?o.aliases:[],..."internalAliases"in o?o.internalAliases:[]].map((s)=>[s,o.handler]))];return Object.fromEntries(e)},"generateShapeMap"),$i=LS();function ri(r){return r in $i}t(ri,"isValidShape");var _n=t(({flowchart:r})=>{let e=r?.subGraphTitleMargin?.top??0,o=r?.subGraphTitleMargin?.bottom??0,a=e+o;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:o,subGraphTitleTotalMargin:a}},"getSubGraphTitleMargins"),Wl=new Map;async function wn(r,e,o){let a,s;if(e.shape==="rect")if(e.rx&&e.ry)e.shape="roundedRect";else e.shape="squareRect";let n=e.shape?$i[e.shape]:void 0;if(!n)throw Error(`No such shape: ${e.shape}. Please check your syntax.`);if(e.link){let c;if(o.config.securityLevel==="sandbox")c="_top";else if(e.linkTarget)c=e.linkTarget||"_blank";a=r.insert("svg:a").attr("xlink:href",e.link).attr("target",c??null),s=await n(a,e,o)}else s=await n(r,e,o),a=s;if(a.attr("data-look",Me(e.look)),e.tooltip)s.attr("title",e.tooltip);if(Wl.set(e.id,a),e.haveCallback)a.attr("class",a.attr("class")+" clickable");return a}t(wn,"insertNode");var Lc=t((r,e)=>{Wl.set(e.id,r)},"setNodeElem"),Nc=t(()=>{Wl.clear()},"clear"),dn=t((r)=>{let e=Wl.get(r.id);i.trace("Transforming node",r.diff,r,"translate("+(r.x-r.width/2-5)+", "+r.width/2+")");let o=8,a=r.diff||0;if(r.clusterNode)e.attr("transform","translate("+(r.x+a-r.width/2)+", "+(r.y-r.height/2-o)+")");else e.attr("transform","translate("+r.x+", "+r.y+")");return a},"positionNode");var FS=t(async(r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,m=l,{labelStyles:u,nodeStyles:y,borderStyles:x,backgroundStyles:k}=E(e),w=r.insert("g").attr("class","cluster swimlane "+(e.cssClasses||"")).attr("id",e.domId??e.id).attr("data-id",e.id).attr("data-et","cluster").attr("data-look",e.look);It(w,e.colorIndex,a,p);let _=ln(o.flowchart.htmlLabels),M=e.direction==="LR",q=w.insert("g").attr("class","cluster-label swimlane-label"),Y=await ct(q,e.label,{style:e.labelStyle,useHtmlLabels:_,isNode:!0,width:e.width}),V=Y.getBBox();if(_){let gt=Y.children[0],et=g(Y);V=gt.getBoundingClientRect(),et.attr("width",V.width),et.attr("height",V.height)}let Q=e.padding??0,tt=e.width<=V.width+Q?V.width+Q:e.width;if(e.width<=V.width+Q)e.diff=(tt-e.width)/2-Q;else e.diff=-Q;let at=e.height,ot=e.y-at/2,ht=e.y+at/2,yt=e.x-tt/2,Bt=e.swimlaneContentTop!==void 0?e.swimlaneContentTop:ot+at/3,kt=M?4:0,Ct=V.height+2*kt,rt,it;if(M){let gt=Math.max(Ct,V.height+2*kt),et=yt+gt,wt=Math.max(0,tt-gt);if(e.look==="handDrawn"){let jt=v.svg(w),se=Kt(e,{roughness:0.7,fill:c,stroke:m,seed:n}),oe=Kt(e,{roughness:0.7,fill:"none",stroke:m,seed:n}),fe=jt.rectangle(yt,ot,gt,at,se);rt=w.insert(()=>fe,":first-child").attr("class","swimlane-title");let ge=jt.rectangle(et,ot,wt,at,oe);it=w.insert(()=>ge,":first-child").attr("class","swimlane-body"),rt.select("path:nth-child(2)").attr("style",x.join(";")),rt.select("path").attr("style",k.join(";").replace("fill","stroke"))}else rt=w.insert("rect",":first-child"),it=w.insert("rect",":first-child"),rt.attr("class","swimlane-title").attr("style",y).attr("x",yt).attr("y",ot).attr("width",gt).attr("height",at).attr("fill",c).attr("stroke",m),it.attr("class","swimlane-body").attr("style",y).attr("x",et).attr("y",ot).attr("width",wt).attr("height",at).attr("fill","none").attr("stroke",m);let vt=yt+gt/2,Xt=e.y;q.attr("transform",`translate(${vt}, ${Xt}) rotate(-90) translate(${-V.width/2}, ${-V.height/2})`)}else{let gt=Math.max(0,Bt-ot),et=Math.min(Ct,gt),wt=ot+et,vt=Math.max(0,ht-wt),Xt=e.x-tt/2;if(e.look==="handDrawn"){let oe=v.svg(w),fe=Kt(e,{roughness:0.7,fill:c,stroke:m,fillWeight:3,seed:n}),ge=Kt(e,{roughness:0.7,fill:"none",stroke:m,seed:n}),he=oe.rectangle(Xt,ot,tt,et,fe);rt=w.insert(()=>he,":first-child").attr("class","swimlane-title");let Ut=oe.rectangle(Xt,wt,tt,vt,ge);it=w.insert(()=>Ut,":first-child").attr("class","swimlane-body"),rt.select("path:nth-child(2)").attr("style",x.join(";")),rt.select("path").attr("style",k.join(";").replace("fill","stroke"))}else rt=w.insert("rect",":first-child"),it=w.insert("rect",":first-child"),rt.attr("class","swimlane-title").attr("style",y).attr("x",Xt).attr("y",ot).attr("width",tt).attr("height",et).attr("fill",c).attr("stroke",m),it.attr("class","swimlane-body").attr("style",y).attr("x",Xt).attr("y",wt).attr("width",tt).attr("height",vt).attr("fill","none").attr("stroke",m);let jt=e.x-V.width/2,se=ot+(et-V.height)/2;q.attr("transform",`translate(${jt}, ${se})`)}if(i.trace("Swimlane data ",e,JSON.stringify(e)),u){let gt=q.select("span");if(gt)gt.attr("style",u)}return e.offsetX=0,e.width=tt,e.height=at,e.offsetY=V.height-Q/2,e.intersect=function(gt){return ui(e,gt)},{cluster:w,labelBBox:V}},"swimlane"),v0=t(async(r,e)=>{i.info("Creating subgraph rect for ",e.id,e);let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,{labelStyles:m,nodeStyles:u,borderStyles:y,backgroundStyles:x}=E(e),k=r.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.domId).attr("data-look",e.look);It(k,e.colorIndex,a,p);let w=Xe(o),_=k.insert("g").attr("class","cluster-label "),M;if(e.labelType==="markdown")M=await ct(_,e.label,{style:e.labelStyle,useHtmlLabels:w,isNode:!0,width:e.width});else M=await Gr(_,e.label,e.labelStyle||"",!1,!0);let q=M.getBBox();if(Xe(o)){let yt=M.children[0],Bt=g(M);q=yt.getBoundingClientRect(),Bt.attr("width",q.width),Bt.attr("height",q.height)}let Y=e.width<=q.width+e.padding?q.width+e.padding:e.width;if(e.width<=q.width+e.padding)e.diff=(Y-e.width)/2-e.padding;else e.diff=-e.padding;let V=e.height,Q=e.x-Y/2,tt=e.y-V/2;i.trace("Data ",e,JSON.stringify(e));let at;if(e.look==="handDrawn"){let yt=v.svg(k),Bt=Kt(e,{roughness:0.7,fill:c,stroke:l,fillWeight:3,seed:n}),kt=yt.path(Tr(Q,tt,Y,V,0),Bt);at=k.insert(()=>(i.debug("Rough node insert CXC",kt),kt),":first-child"),at.select("path:nth-child(2)").attr("style",y.join(";")),at.select("path").attr("style",x.join(";").replace("fill","stroke"))}else at=k.insert("rect",":first-child"),at.attr("style",u).attr("rx",e.rx).attr("ry",e.ry).attr("x",Q).attr("y",tt).attr("width",Y).attr("height",V);let{subGraphTitleTopMargin:ot}=_n(o);if(_.attr("transform",`translate(${e.x-q.width/2}, ${e.y-e.height/2+ot})`),m){let yt=_.select("span");if(yt)yt.attr("style",m)}let ht=at.node().getBBox();return e.offsetX=0,e.width=ht.width,e.height=ht.height,e.offsetY=q.height-e.padding/2,e.intersect=function(yt){return ui(e,yt)},{cluster:k,labelBBox:q}},"rect"),AS=t((r,e)=>{let o=r.insert("g").attr("class","note-cluster").attr("id",e.domId),a=o.insert("rect",":first-child"),s=0*e.padding,n=s/2;a.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-n).attr("y",e.y-e.height/2-n).attr("width",e.width+s).attr("height",e.height+s).attr("fill","none");let c=a.node().getBBox();return e.width=c.width,e.height=c.height,e.intersect=function(l){return ui(e,l)},{cluster:o,labelBBox:{width:0,height:0}}},"noteGroup"),MS=t(async(r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{altBackground:c,borderColorArray:l,compositeBackground:p,compositeTitleBackground:m,nodeBorder:u}=s,y=r.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-id",e.id).attr("data-look",e.look);It(y,e.colorIndex,a,l);let x=y.insert("g",":first-child"),k=y.insert("g").attr("class","cluster-label"),w=y.append("rect"),_=await Gr(k,e.label,e.labelStyle,void 0,!0),M=_.getBBox();if(Xe(o)){let kt=_.children[0],Ct=g(_);M=kt.getBoundingClientRect(),Ct.attr("width",M.width),Ct.attr("height",M.height)}let q=0*e.padding,Y=q/2,V=(e.width<=M.width+e.padding?M.width+e.padding:e.width)+q;if(e.width<=M.width+e.padding)e.diff=(V-e.width)/2-e.padding;else e.diff=-e.padding;let Q=e.height+q,tt=e.height+q-M.height-6,at=e.x-V/2,ot=e.y-Q/2;e.width=V;let ht=e.y-e.height/2-Y+M.height+2,yt;if(e.look==="handDrawn"){let kt=e.cssClasses.includes("statediagram-cluster-alt"),Ct=v.svg(y),rt=e.rx||e.ry?Ct.path(Tr(at,ot,V,Q,10),{roughness:0.7,fill:m,fillStyle:"solid",stroke:u,seed:n}):Ct.rectangle(at,ot,V,Q,{seed:n});yt=y.insert(()=>rt,":first-child");let it=Ct.rectangle(at,ht,V,tt,{fill:kt?c:p,fillStyle:kt?"hachure":"solid",stroke:u,seed:n});yt=y.insert(()=>rt,":first-child"),w=y.insert(()=>it),yt.attr("class","outer"),w.attr("class","inner")}else{yt=x.insert("rect",":first-child");let kt="outer";yt.attr("class",kt).attr("x",at).attr("y",ot).attr("width",V).attr("height",Q).attr("data-look",e.look),w.attr("class","inner").attr("x",at).attr("y",ht).attr("width",V).attr("height",tt)}k.attr("transform",`translate(${e.x-M.width/2}, ${ot+1-(Xe(o)?0:3)})`);let Bt=yt.node().getBBox();return e.height=Bt.height,e.offsetX=0,e.offsetY=M.height-e.padding/2,e.labelBBox=M,e.intersect=function(kt){return ui(e,kt)},{cluster:y,labelBBox:M}},"roundedWithTitle"),ES=t(async(r,e)=>{i.info("Creating subgraph rect for ",e.id,e);let o=d(),{themeVariables:a,handDrawnSeed:s}=o,{clusterBkg:n,clusterBorder:c}=a,{labelStyles:l,nodeStyles:p,borderStyles:m,backgroundStyles:u}=E(e),y=r.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.domId).attr("data-look",e.look),x=Xe(o),k=y.insert("g").attr("class","cluster-label "),w=await ct(k,e.label,{style:e.labelStyle,useHtmlLabels:x,isNode:!0,width:e.width}),_=w.getBBox();if(Xe(o)){let ot=w.children[0],ht=g(w);_=ot.getBoundingClientRect(),ht.attr("width",_.width),ht.attr("height",_.height)}let M=e.width<=_.width+e.padding?_.width+e.padding:e.width;if(e.width<=_.width+e.padding)e.diff=(M-e.width)/2-e.padding;else e.diff=-e.padding;let q=e.height,Y=e.x-M/2,V=e.y-q/2;i.trace("Data ",e,JSON.stringify(e));let Q;if(e.look==="handDrawn"){let ot=v.svg(y),ht=Kt(e,{roughness:0.7,fill:n,stroke:c,fillWeight:4,seed:s}),yt=ot.path(Tr(Y,V,M,q,e.rx),ht);Q=y.insert(()=>(i.debug("Rough node insert CXC",yt),yt),":first-child"),Q.select("path:nth-child(2)").attr("style",m.join(";")),Q.select("path").attr("style",u.join(";").replace("fill","stroke"))}else Q=y.insert("rect",":first-child"),Q.attr("style",p).attr("rx",e.rx).attr("ry",e.ry).attr("x",Y).attr("y",V).attr("width",M).attr("height",q);let{subGraphTitleTopMargin:tt}=_n(o);if(k.attr("transform",`translate(${e.x-_.width/2}, ${e.y-e.height/2+tt})`),l){let ot=k.select("span");if(ot)ot.attr("style",l)}let at=Q.node().getBBox();return e.offsetX=0,e.width=at.width,e.height=at.height,e.offsetY=_.height-e.padding/2,e.intersect=function(ot){return ui(e,ot)},{cluster:y,labelBBox:_}},"kanbanSection"),OS=t((r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{altBackground:c,nodeBorder:l,borderColorArray:p}=s,m=r.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-look",e.look);It(m,e.colorIndex,a,p);let u=m.insert("g",":first-child"),y=0*e.padding,x=e.width+y;e.diff=-e.padding;let k=e.height+y,w=e.x-x/2,_=e.y-k/2;e.width=x;let M;if(e.look==="handDrawn"){let V=v.svg(m).rectangle(w,_,x,k,{fill:c??"#efefef",fillStyle:"solid",roughness:0.5,strokeLineDash:[5],stroke:l,seed:n});M=m.insert(()=>V,":first-child").attr("class","divider")}else{M=u.insert("rect",":first-child");let Y="outer";if(e.look==="neo")Y="divider";else Y="divider";M.attr("class",Y).attr("x",w).attr("y",_).attr("width",x).attr("height",k).attr("data-look",e.look)}let q=M.node().getBBox();return e.height=q.height,e.offsetX=0,e.offsetY=0,e.intersect=function(Y){return ui(e,Y)},{cluster:m,labelBBox:{}}},"divider"),IS=t(async(r,e,o)=>{i.info(`Creating ${o.cssClass} for `,e.id,e);let a=d(),{theme:s,themeVariables:n,handDrawnSeed:c}=a,{borderColorArray:l}=n,{labelStyles:p,borderStyles:m}=E(e),u=r.insert("g").attr("class","cluster "+o.cssClass+" "+e.cssClasses).attr("id",e.domId??e.id).attr("data-look",e.look);It(u,e.colorIndex,s,l);let y=Xe(a),x=u.insert("g").attr("class","cluster-label"),k={width:0,height:0},w=e.label?.trim();if(w){let tt;if(e.labelType==="markdown")tt=await ct(x,e.label,{style:e.labelStyle,useHtmlLabels:y,isNode:!0,width:e.width});else tt=await Gr(x,e.label,e.labelStyle||"",!1,!0);if(k=tt.getBBox(),y){let at=tt.children[0],ot=g(tt);k=at.getBoundingClientRect(),ot.attr("width",k.width),ot.attr("height",k.height)}}let _=e.width<=k.width+e.padding?k.width+e.padding:e.width;if(e.width<=k.width+e.padding)e.diff=(_-e.width)/2-e.padding;else e.diff=-e.padding;let M=e.height,q=e.x-_/2,Y=e.y-M/2,V;if(e.look==="handDrawn"){let tt=v.svg(u),at=Kt(e,{roughness:o.roughness,fill:o.fill,stroke:o.stroke,strokeWidth:o.strokeWidth,seed:c,...o.fill==="none"?{fillWeight:0}:{fillStyle:"solid"},...o.strokeDash?{strokeLineDash:o.strokeDash}:{}}),ot=tt.path(Tr(q,Y,_,M,o.rx),at);V=u.insert(()=>ot,":first-child"),V.select("path:nth-child(2)").attr("style",m.join(";"))}else if(V=u.insert("rect",":first-child"),V.attr("rx",o.rx).attr("ry",o.rx).attr("x",q).attr("y",Y).attr("width",_).attr("height",M).attr("fill",o.fill).attr("stroke",o.stroke).attr("stroke-width",o.strokeWidth+"px"),o.strokeDash)V.attr("stroke-dasharray",o.strokeDash.join(", "));if(w){let{subGraphTitleTopMargin:tt}=_n(a);if(x.attr("transform",`translate(${e.x-k.width/2}, ${e.y-e.height/2+tt})`),p){let at=x.select("span");if(at)at.attr("style",p)}}let Q=V.node().getBBox();return e.offsetX=0,e.width=Q.width,e.height=Q.height,e.offsetY=k.height-e.padding/2,e.intersect=function(tt){return ui(e,tt)},{cluster:u,labelBBox:k}},"createContainerGroup"),$S=t(async(r,e)=>{let{themeVariables:o}=d(),a=o.flowContainerStroke||o.secondaryBorderColor;return IS(r,e,{cssClass:"flow-cluster",rx:10,fill:"none",stroke:a,strokeWidth:0.75,roughness:0.7})},"flowGroup"),DS=t((r,e)=>{let o=r.boundaryType||"rect",a=o==="package"?20:r.padding,s=o==="package"?e.height+10:0,n=Math.max(r.width,e.width+a),c=o==="package"?Math.max(r.height,s+r.padding*2):r.height,l=r.x-n/2,p=r.y-c/2;return{boundaryType:o,width:n,height:c,x:l,y:p,bodyY:p+s,bodyHeight:c-s,tabHeight:s,tabWidth:o==="package"?Math.min(n,Math.max(80,e.width+20)):0}},"getUsecaseSystemBoundaryGeometry"),PS=t(async(r,e)=>{i.info("Creating usecase system boundary for ",e.id,e);let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,{labelStyles:m,nodeStyles:u}=E(e),{stylesMap:y}=ai(e),x=e.boundaryType||"rect",k=r.insert("g").attr("class",`cluster usecase-system-boundary usecase-system-boundary-${x} ${e.cssClasses}`).attr("id",typeof e.domId==="string"?e.domId:e.id).attr("data-boundary-type",x).attr("data-look",e.look);It(k,e.colorIndex,a,p);let w=Xe(o),_=k.insert("g").attr("class","cluster-label system-boundary-title"),M=await ct(_,e.label,{style:m,useHtmlLabels:w,isNode:!0}),q=M.getBBox();if(w){let rt=M.children[0],it=g(M);q=rt.getBoundingClientRect(),it.attr("width",q.width),it.attr("height",q.height)}let Y=DS(e,q),{width:V,height:Q,x:tt,y:at,bodyY:ot,bodyHeight:ht,tabHeight:yt,tabWidth:Bt}=Y;e.diff=e.width<=q.width+e.padding?(V-e.width)/2-e.padding:-e.padding;let kt=Kt(e,{fill:y.get("fill")||c,stroke:y.get("stroke")||l,strokeWidth:y.get("stroke-width")?.replace("px","")||1,seed:n});if(e.look==="handDrawn"){let rt=v.svg(k),it=rt.rectangle(tt,ot,V,ht,kt);if(k.insert(()=>it,":first-child").attr("class","boundary-body label-container"),x==="package"){let gt=rt.rectangle(tt,at,Bt,yt,kt);k.insert(()=>gt,":first-child").attr("class","boundary-tab system-boundary-package-tab label-container")}}else if(k.insert("rect",":first-child").attr("class","boundary-body label-container").attr("style",u).attr("x",tt).attr("y",ot).attr("width",V).attr("height",ht),x==="package")k.insert("rect",":first-child").attr("class","boundary-tab system-boundary-package-tab label-container").attr("style",u).attr("x",tt).attr("y",at).attr("width",Bt).attr("height",yt);let{subGraphTitleTopMargin:Ct}=_n(o);if(x==="package")_.attr("transform",`translate(${tt+(Bt-q.width)/2}, ${at+(yt-q.height)/2})`);else _.attr("transform",`translate(${e.x-q.width/2}, ${at+Ct})`);if(m)_.attr("style",m),_.select("span").attr("style",m);return e.offsetX=0,e.width=V,e.height=Q,e.offsetY=q.height-e.padding/2,e.labelBBox=q,e.intersect=function(rt){return ui(e,rt)},{cluster:k,labelBBox:q}},"usecaseSystemBoundary"),RS=v0,qS={rect:v0,squareRect:RS,roundedWithTitle:MS,noteGroup:AS,divider:OS,kanbanSection:ES,flowGroup:$S,usecaseSystemBoundary:PS,swimlane:FS};var L0=new Map,rr=t(async(r,e)=>{let o=e.shape||"rect",a=await qS[o](r,e);return L0.set(e.id,a),a},"insertCluster"),Mc=t(()=>{L0=new Map},"clear");var on=t((r,e)=>{if(e)return"translate("+-r.width/2+", "+-r.height/2+")";let o=r.x??0,a=r.y??0;return"translate("+-(o+r.width/2)+", "+-(a+r.height/2)+")"},"computeLabelTransform"),ut={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},F0={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function an(r,e){if(r===void 0||e===void 0)return{angle:0,deltaX:0,deltaY:0};r=Ae(r),e=Ae(e);let[o,a]=[r.x,r.y],[s,n]=[e.x,e.y],c=s-o,l=n-a;return{angle:Math.atan(l/c),deltaX:c,deltaY:l}}t(an,"calculateDeltaAndAngle");var Ae=t((r)=>{if(Array.isArray(r))return{x:r[0],y:r[1]};return r},"pointTransformer"),NS=t((r)=>({x:t(function(e,o,a){let s=0,n=Ae(a[0]).x<Ae(a[a.length-1]).x?"left":"right";if(o===0&&Object.hasOwn(ut,r.arrowTypeStart)){let{angle:k,deltaX:w}=an(a[0],a[1]);s=ut[r.arrowTypeStart]*Math.cos(k)*(w>=0?1:-1)}else if(o===a.length-1&&Object.hasOwn(ut,r.arrowTypeEnd)){let{angle:k,deltaX:w}=an(a[a.length-1],a[a.length-2]);s=ut[r.arrowTypeEnd]*Math.cos(k)*(w>=0?1:-1)}let c=Math.abs(Ae(e).x-Ae(a[a.length-1]).x),l=Math.abs(Ae(e).y-Ae(a[a.length-1]).y),p=Math.abs(Ae(e).x-Ae(a[0]).x),m=Math.abs(Ae(e).y-Ae(a[0]).y),u=ut[r.arrowTypeStart],y=ut[r.arrowTypeEnd],x=1;if(c<y&&c>0&&l<y){let k=y+x-c;k*=n==="right"?-1:1,s-=k}if(p<u&&p>0&&m<u){let k=u+x-p;k*=n==="right"?-1:1,s+=k}return Ae(e).x+s},"x"),y:t(function(e,o,a){let s=0,n=Ae(a[0]).y<Ae(a[a.length-1]).y?"down":"up";if(o===0&&Object.hasOwn(ut,r.arrowTypeStart)){let{angle:k,deltaY:w}=an(a[0],a[1]);s=ut[r.arrowTypeStart]*Math.abs(Math.sin(k))*(w>=0?1:-1)}else if(o===a.length-1&&Object.hasOwn(ut,r.arrowTypeEnd)){let{angle:k,deltaY:w}=an(a[a.length-1],a[a.length-2]);s=ut[r.arrowTypeEnd]*Math.abs(Math.sin(k))*(w>=0?1:-1)}let c=Math.abs(Ae(e).y-Ae(a[a.length-1]).y),l=Math.abs(Ae(e).x-Ae(a[a.length-1]).x),p=Math.abs(Ae(e).y-Ae(a[0]).y),m=Math.abs(Ae(e).x-Ae(a[0]).x),u=ut[r.arrowTypeStart],y=ut[r.arrowTypeEnd],x=1;if(c<y&&c>0&&l<y){let k=y+x-c;k*=n==="up"?-1:1,s-=k}if(p<u&&p>0&&m<u){let k=u+x-p;k*=n==="up"?-1:1,s+=k}return Ae(e).y+s},"y")}),"getLineFunctionsWithOffset"),WS=t((r,e,o,a,s,n=!1,c)=>{if(e.arrowTypeStart)A0(r,"start",e.arrowTypeStart,o,a,s,n,c);if(e.arrowTypeEnd)A0(r,"end",e.arrowTypeEnd,o,a,s,n,c)},"addEdgeMarkers"),zS={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_barb_neo:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},arrow_hierarchy:{type:"hierarchy",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},HS=["cross","point","circle","lollipop","aggregation","extension","composition","dependency","barb"],A0=t((r,e,o,a,s,n,c=!1,l)=>{if(!o||o==="none")return;let p=zS[o],m=p&&HS.includes(p.type);if(!p){i.warn(`Unknown arrow type: ${o}`);return}let u=p.type,k=`${s}_${n}-${u}${e==="start"?"Start":"End"}${c&&m?"-margin":""}`;if(l&&l.trim()!==""){let w=l.replace(/[^\dA-Za-z]/g,"_"),_=`${k}_${w}`;if(!document.getElementById(_)){let M=document.getElementById(k);if(M){let q=M.cloneNode(!0);q.id=_,q.querySelectorAll("path, circle, line").forEach((V)=>{if(V.setAttribute("stroke",l),p.fill)V.setAttribute("fill",l)}),M.parentNode?.appendChild(q)}}r.attr(`marker-${e}`,`url(${a}#${_})`)}else r.attr(`marker-${e}`,`url(${a}#${k})`)},"addEdgeMarker"),YS=t((r)=>typeof r==="string"?r:d()?.flowchart?.curve,"resolveEdgeCurveType"),pa=new Map,dt=new Map,Pc=t(()=>{pa.clear(),dt.clear()},"clear"),tc=t((r)=>Boolean(r.label||r.startLabelLeft||r.startLabelRight||r.endLabelLeft||r.endLabelRight),"hasEdgeLabel"),sn=t((r)=>{if(!r)return"";if(typeof r==="string")return r;return r.reduce((e,o)=>e+";"+o,"")},"getLabelStyles"),kn=t(async(r,e)=>{let o=d(),a=Xe(o),{labelStyles:s}=E(e);e.labelStyle=s;let n=r.insert("g").attr("class","edgeLabel"),c=n.insert("g").attr("class","label").attr("data-id",e.id),l=e.labelType==="markdown",p=void 0,m=await ct(r,e.label,{style:sn(e.labelStyle),useHtmlLabels:a,addSvgBackground:!0,isNode:!1,markdown:l,width:l?p:void 0},o);c.node().appendChild(m),i.info("abc82",e,e.labelType);let u,y;if(a){let k=m.children[0],w=g(m);u=await Bi.measure(()=>k.getBoundingClientRect()),y=u,w.attr("width",u.width),w.attr("height",u.height)}else{let k=g(m).select("text").node();await Bi.measure(()=>{if(u=m.getBBox(),k&&typeof k.getBBox==="function")y=k.getBBox();else y=u})}c.attr("transform",on(y,a)),pa.set(e.id,n),e.width=u.width,e.height=u.height;let x;if(e.startLabelLeft){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.startLabelLeft,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let q=_.children[0],Y=g(_);M=q.getBoundingClientRect(),Y.attr("width",M.width),Y.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).startLeft=k,hn(x,e.startLabelLeft,M),nn(e,"startLeft",M)}if(e.startLabelRight){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.startLabelRight,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let q=_.children[0],Y=g(_);M=q.getBoundingClientRect(),Y.attr("width",M.width),Y.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).startRight=k,hn(x,e.startLabelRight,M),nn(e,"startRight",M)}if(e.endLabelLeft){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.endLabelLeft,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let q=_.children[0],Y=g(_);M=q.getBoundingClientRect(),Y.attr("width",M.width),Y.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).endLeft=k,hn(x,e.endLabelLeft,M),nn(e,"endLeft",M)}if(e.endLabelRight){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.endLabelRight,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let q=_.children[0],Y=g(_);M=q.getBoundingClientRect(),Y.attr("width",M.width),Y.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).endRight=k,hn(x,e.endLabelRight,M),nn(e,"endRight",M)}return m},"insertEdgeLabel");function nn(r,e,o){r.terminalLabelSizes??={},r.terminalLabelSizes[e]={width:o.width,height:o.height}}t(nn,"recordTerminalLabelSize");function hn(r,e,o){if(Xe(d())&&r)r.style.width=Math.max(e.length*9,o.width)+"px",r.style.height=o.height+"px"}t(hn,"setTerminalWidth");var nc=t((r,e)=>{let{x:o,y:a}=r;if(e?.updatedPath){let s=H.calcLabelPosition(e.updatedPath);if(e.originalPath){let n=H.calcLabelPosition(e.originalPath);o=r.x+(s.x-n.x),a=r.y+(s.y-n.y)}else o=s.x,a=s.y}return{x:o,y:a}},"resolveEdgeLabelPosition"),ua=t((r,e)=>{i.debug("Moving label abc88 ",r.id,r.label,pa.get(r.id),e);let o=d(),{subGraphTitleTotalMargin:a}=_n(o);if(r.label){let n=pa.get(r.id),{x:c,y:l}=nc(r,e);i.debug("Moving label "+r.label+" from (",r.x,",",r.y,") to (",c,",",l,") abc88"),n.attr("transform",`translate(${c}, ${l+a/2})`)}let s=e.updatedPath?e.updatedPath:e.originalPath;if(r.startLabelLeft){let n=dt.get(r.id).startLeft,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_left",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.startLabelRight){let n=dt.get(r.id).startRight,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_right",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.endLabelLeft){let n=dt.get(r.id).endLeft,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_left",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.endLabelRight){let n=dt.get(r.id).endRight,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_right",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}},"positionEdgeLabel"),US=t((r,e)=>{if(!r?.isLabelEdge||!r?.id?.endsWith("-to-label")||!Array.isArray(e))return e;if(e.length!==2)return e;let[o,a]=e,s=Math.abs(a.x-o.x),n=Math.abs(a.y-o.y);if(s<0.001||n<0.001)return e;if(n>=s)return[o,{x:o.x,y:a.y},a];return[o,{x:a.x,y:o.y},a]},"orthogonalizeToLabelClippedPoints"),jS=t((r,e)=>{let{x:o,y:a}=r,s=Math.abs(e.x-o),n=Math.abs(e.y-a),c=r.width/2,l=r.height/2;return s>=c||n>=l},"outsideNode"),GS=t((r,e,o)=>{i.debug(`intersection calc abc89:
|
|
293
|
+
`;if(!e.domId)throw Error(`defaultMindmapNode: node "${e.id}" is missing a domId — was render.ts domId prefixing skipped?`);let x=s.append("path").attr("id",e.domId).attr("class","node-bkg node-"+e.type).attr("style",a).attr("d",y);return s.append("line").attr("class","node-line-").attr("x1",-p/2).attr("y1",m/2).attr("x2",p/2).attr("y2",m/2),l.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`),s.append(()=>l.node()),B(e,x),e.calcIntersect=function(k,w){return T.rect(k,w)},e.intersect=function(k){return T.rect(e,k)},s}t(_0,"defaultMindmapNode");async function B0(r,e){let o={padding:e.padding??0};return id(r,e,o)}t(B0,"mindmapCircle");var vS=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:i0},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:t0},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:o0},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:l0},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:xx},{semanticName:"Data Store",name:"Data Store",shortName:"datastore",description:"Data flow diagram data store",aliases:["data-store"],handler:Cx},{semanticName:"Folder",name:"Folder",shortName:"folder",description:"Folder or directory",aliases:["directory"],handler:_x},{semanticName:"Bucket",name:"Bucket",shortName:"bucket",description:"Object storage bucket",handler:rx},{semanticName:"Console",name:"Console (terminal window)",shortName:"console",description:"Terminal or console window",handler:cx},{semanticName:"Browser",name:"Browser",shortName:"browser",description:"Browser window",handler:ax},{semanticName:"Person",name:"Person",shortName:"person",description:"Person (circular head above a rounded body)",handler:yx},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:id},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:S0},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:T0},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Zx},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:Lx},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:Rx},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:Px},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:d0},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:$x},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:kx},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:u0},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:nx},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:e0},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:n0},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:a0},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:Bx},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:Fx},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:dx},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:px},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:gx},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:qx},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:m0},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:vx},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:f0},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:Nx},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:mx},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:bx},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:g0},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:x0},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:Sx},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:p0},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:Tx},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:r0},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:Vx},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:Xx},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:ex},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:fx},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:c0},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:h0},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:y0},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:Qx},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:Wx}],LS=t(()=>{let e=[...Object.entries({state:s0,choice:lx,note:Kx,composite:hx,rectWithTitle:Jx,labelRect:Dx,block_arrow:sx,collapsedGroup:ox,iconSquare:Ox,iconCircle:Mx,icon:Ax,iconRounded:Ex,imageSquare:Ix,anchor:Jy,kanbanItem:w0,mindmapCircle:B0,defaultMindmapNode:_0,classBox:b0,erBox:sd,requirementBox:k0,usecaseActor:zx,usecaseActorHollow:Yx,usecaseActorAwesome:Hx,usecaseActorIcon:Ux,usecaseBusiness:jx,usecaseEllipse:wx,usecaseJsonTable:Gx}),...vS.flatMap((o)=>[o.shortName,..."aliases"in o?o.aliases:[],..."internalAliases"in o?o.internalAliases:[]].map((s)=>[s,o.handler]))];return Object.fromEntries(e)},"generateShapeMap"),$i=LS();function ri(r){return r in $i}t(ri,"isValidShape");var _n=t(({flowchart:r})=>{let e=r?.subGraphTitleMargin?.top??0,o=r?.subGraphTitleMargin?.bottom??0,a=e+o;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:o,subGraphTitleTotalMargin:a}},"getSubGraphTitleMargins"),Wl=new Map;async function wn(r,e,o){let a,s;if(e.shape==="rect")if(e.rx&&e.ry)e.shape="roundedRect";else e.shape="squareRect";let n=e.shape?$i[e.shape]:void 0;if(!n)throw Error(`No such shape: ${e.shape}. Please check your syntax.`);if(e.link){let c;if(o.config.securityLevel==="sandbox")c="_top";else if(e.linkTarget)c=e.linkTarget||"_blank";a=r.insert("svg:a").attr("xlink:href",e.link).attr("target",c??null),s=await n(a,e,o)}else s=await n(r,e,o),a=s;if(a.attr("data-look",Fe(e.look)),e.tooltip)s.attr("title",e.tooltip);if(Wl.set(e.id,a),e.haveCallback)a.attr("class",a.attr("class")+" clickable");return a}t(wn,"insertNode");var Lc=t((r,e)=>{Wl.set(e.id,r)},"setNodeElem"),Nc=t(()=>{Wl.clear()},"clear"),dn=t((r)=>{let e=Wl.get(r.id);i.trace("Transforming node",r.diff,r,"translate("+(r.x-r.width/2-5)+", "+r.width/2+")");let o=8,a=r.diff||0;if(r.clusterNode)e.attr("transform","translate("+(r.x+a-r.width/2)+", "+(r.y-r.height/2-o)+")");else e.attr("transform","translate("+r.x+", "+r.y+")");return a},"positionNode");var FS=t(async(r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,m=l,{labelStyles:u,nodeStyles:y,borderStyles:x,backgroundStyles:k}=E(e),w=r.insert("g").attr("class","cluster swimlane "+(e.cssClasses||"")).attr("id",e.domId??e.id).attr("data-id",e.id).attr("data-et","cluster").attr("data-look",e.look);It(w,e.colorIndex,a,p);let _=ln(o.flowchart.htmlLabels),M=e.direction==="LR",W=w.insert("g").attr("class","cluster-label swimlane-label"),U=await ct(W,e.label,{style:e.labelStyle,useHtmlLabels:_,isNode:!0,width:e.width}),V=U.getBBox();if(_){let gt=U.children[0],et=g(U);V=gt.getBoundingClientRect(),et.attr("width",V.width),et.attr("height",V.height)}let Z=e.padding??0,tt=e.width<=V.width+Z?V.width+Z:e.width;if(e.width<=V.width+Z)e.diff=(tt-e.width)/2-Z;else e.diff=-Z;let at=e.height,ot=e.y-at/2,ht=e.y+at/2,yt=e.x-tt/2,Bt=e.swimlaneContentTop!==void 0?e.swimlaneContentTop:ot+at/3,kt=M?4:0,Ct=V.height+2*kt,rt,it;if(M){let gt=Math.max(Ct,V.height+2*kt),et=yt+gt,wt=Math.max(0,tt-gt);if(e.look==="handDrawn"){let jt=v.svg(w),se=Kt(e,{roughness:0.7,fill:c,stroke:m,seed:n}),oe=Kt(e,{roughness:0.7,fill:"none",stroke:m,seed:n}),de=jt.rectangle(yt,ot,gt,at,se);rt=w.insert(()=>de,":first-child").attr("class","swimlane-title");let ge=jt.rectangle(et,ot,wt,at,oe);it=w.insert(()=>ge,":first-child").attr("class","swimlane-body"),rt.select("path:nth-child(2)").attr("style",x.join(";")),rt.select("path").attr("style",k.join(";").replace("fill","stroke"))}else rt=w.insert("rect",":first-child"),it=w.insert("rect",":first-child"),rt.attr("class","swimlane-title").attr("style",y).attr("x",yt).attr("y",ot).attr("width",gt).attr("height",at).attr("fill",c).attr("stroke",m),it.attr("class","swimlane-body").attr("style",y).attr("x",et).attr("y",ot).attr("width",wt).attr("height",at).attr("fill","none").attr("stroke",m);let vt=yt+gt/2,Xt=e.y;W.attr("transform",`translate(${vt}, ${Xt}) rotate(-90) translate(${-V.width/2}, ${-V.height/2})`)}else{let gt=Math.max(0,Bt-ot),et=Math.min(Ct,gt),wt=ot+et,vt=Math.max(0,ht-wt),Xt=e.x-tt/2;if(e.look==="handDrawn"){let oe=v.svg(w),de=Kt(e,{roughness:0.7,fill:c,stroke:m,fillWeight:3,seed:n}),ge=Kt(e,{roughness:0.7,fill:"none",stroke:m,seed:n}),he=oe.rectangle(Xt,ot,tt,et,de);rt=w.insert(()=>he,":first-child").attr("class","swimlane-title");let Ut=oe.rectangle(Xt,wt,tt,vt,ge);it=w.insert(()=>Ut,":first-child").attr("class","swimlane-body"),rt.select("path:nth-child(2)").attr("style",x.join(";")),rt.select("path").attr("style",k.join(";").replace("fill","stroke"))}else rt=w.insert("rect",":first-child"),it=w.insert("rect",":first-child"),rt.attr("class","swimlane-title").attr("style",y).attr("x",Xt).attr("y",ot).attr("width",tt).attr("height",et).attr("fill",c).attr("stroke",m),it.attr("class","swimlane-body").attr("style",y).attr("x",Xt).attr("y",wt).attr("width",tt).attr("height",vt).attr("fill","none").attr("stroke",m);let jt=e.x-V.width/2,se=ot+(et-V.height)/2;W.attr("transform",`translate(${jt}, ${se})`)}if(i.trace("Swimlane data ",e,JSON.stringify(e)),u){let gt=W.select("span");if(gt)gt.attr("style",u)}return e.offsetX=0,e.width=tt,e.height=at,e.offsetY=V.height-Z/2,e.intersect=function(gt){return ui(e,gt)},{cluster:w,labelBBox:V}},"swimlane"),v0=t(async(r,e)=>{i.info("Creating subgraph rect for ",e.id,e);let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,{labelStyles:m,nodeStyles:u,borderStyles:y,backgroundStyles:x}=E(e),k=r.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.domId).attr("data-look",e.look);It(k,e.colorIndex,a,p);let w=Xe(o),_=k.insert("g").attr("class","cluster-label "),M;if(e.labelType==="markdown")M=await ct(_,e.label,{style:e.labelStyle,useHtmlLabels:w,isNode:!0,width:e.width});else M=await Gr(_,e.label,e.labelStyle||"",!1,!0);let W=M.getBBox();if(Xe(o)){let yt=M.children[0],Bt=g(M);W=yt.getBoundingClientRect(),Bt.attr("width",W.width),Bt.attr("height",W.height)}let U=e.width<=W.width+e.padding?W.width+e.padding:e.width;if(e.width<=W.width+e.padding)e.diff=(U-e.width)/2-e.padding;else e.diff=-e.padding;let V=e.height,Z=e.x-U/2,tt=e.y-V/2;i.trace("Data ",e,JSON.stringify(e));let at;if(e.look==="handDrawn"){let yt=v.svg(k),Bt=Kt(e,{roughness:0.7,fill:c,stroke:l,fillWeight:3,seed:n}),kt=yt.path(Tr(Z,tt,U,V,0),Bt);at=k.insert(()=>(i.debug("Rough node insert CXC",kt),kt),":first-child"),at.select("path:nth-child(2)").attr("style",y.join(";")),at.select("path").attr("style",x.join(";").replace("fill","stroke"))}else at=k.insert("rect",":first-child"),at.attr("style",u).attr("rx",e.rx).attr("ry",e.ry).attr("x",Z).attr("y",tt).attr("width",U).attr("height",V);let{subGraphTitleTopMargin:ot}=_n(o);if(_.attr("transform",`translate(${e.x-W.width/2}, ${e.y-e.height/2+ot})`),m){let yt=_.select("span");if(yt)yt.attr("style",m)}let ht=at.node().getBBox();return e.offsetX=0,e.width=ht.width,e.height=ht.height,e.offsetY=W.height-e.padding/2,e.intersect=function(yt){return ui(e,yt)},{cluster:k,labelBBox:W}},"rect"),AS=t((r,e)=>{let o=r.insert("g").attr("class","note-cluster").attr("id",e.domId),a=o.insert("rect",":first-child"),s=0*e.padding,n=s/2;a.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-n).attr("y",e.y-e.height/2-n).attr("width",e.width+s).attr("height",e.height+s).attr("fill","none");let c=a.node().getBBox();return e.width=c.width,e.height=c.height,e.intersect=function(l){return ui(e,l)},{cluster:o,labelBBox:{width:0,height:0}}},"noteGroup"),MS=t(async(r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{altBackground:c,borderColorArray:l,compositeBackground:p,compositeTitleBackground:m,nodeBorder:u}=s,y=r.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-id",e.id).attr("data-look",e.look);It(y,e.colorIndex,a,l);let x=y.insert("g",":first-child"),k=y.insert("g").attr("class","cluster-label"),w=y.append("rect"),_=await Gr(k,e.label,e.labelStyle,void 0,!0),M=_.getBBox();if(Xe(o)){let kt=_.children[0],Ct=g(_);M=kt.getBoundingClientRect(),Ct.attr("width",M.width),Ct.attr("height",M.height)}let W=0*e.padding,U=W/2,V=(e.width<=M.width+e.padding?M.width+e.padding:e.width)+W;if(e.width<=M.width+e.padding)e.diff=(V-e.width)/2-e.padding;else e.diff=-e.padding;let Z=e.height+W,tt=e.height+W-M.height-6,at=e.x-V/2,ot=e.y-Z/2;e.width=V;let ht=e.y-e.height/2-U+M.height+2,yt;if(e.look==="handDrawn"){let kt=e.cssClasses.includes("statediagram-cluster-alt"),Ct=v.svg(y),rt=e.rx||e.ry?Ct.path(Tr(at,ot,V,Z,10),{roughness:0.7,fill:m,fillStyle:"solid",stroke:u,seed:n}):Ct.rectangle(at,ot,V,Z,{seed:n});yt=y.insert(()=>rt,":first-child");let it=Ct.rectangle(at,ht,V,tt,{fill:kt?c:p,fillStyle:kt?"hachure":"solid",stroke:u,seed:n});yt=y.insert(()=>rt,":first-child"),w=y.insert(()=>it),yt.attr("class","outer"),w.attr("class","inner")}else{yt=x.insert("rect",":first-child");let kt="outer";yt.attr("class",kt).attr("x",at).attr("y",ot).attr("width",V).attr("height",Z).attr("data-look",e.look),w.attr("class","inner").attr("x",at).attr("y",ht).attr("width",V).attr("height",tt)}k.attr("transform",`translate(${e.x-M.width/2}, ${ot+1-(Xe(o)?0:3)})`);let Bt=yt.node().getBBox();return e.height=Bt.height,e.offsetX=0,e.offsetY=M.height-e.padding/2,e.labelBBox=M,e.intersect=function(kt){return ui(e,kt)},{cluster:y,labelBBox:M}},"roundedWithTitle"),ES=t(async(r,e)=>{i.info("Creating subgraph rect for ",e.id,e);let o=d(),{themeVariables:a,handDrawnSeed:s}=o,{clusterBkg:n,clusterBorder:c}=a,{labelStyles:l,nodeStyles:p,borderStyles:m,backgroundStyles:u}=E(e),y=r.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.domId).attr("data-look",e.look),x=Xe(o),k=y.insert("g").attr("class","cluster-label "),w=await ct(k,e.label,{style:e.labelStyle,useHtmlLabels:x,isNode:!0,width:e.width}),_=w.getBBox();if(Xe(o)){let ot=w.children[0],ht=g(w);_=ot.getBoundingClientRect(),ht.attr("width",_.width),ht.attr("height",_.height)}let M=e.width<=_.width+e.padding?_.width+e.padding:e.width;if(e.width<=_.width+e.padding)e.diff=(M-e.width)/2-e.padding;else e.diff=-e.padding;let W=e.height,U=e.x-M/2,V=e.y-W/2;i.trace("Data ",e,JSON.stringify(e));let Z;if(e.look==="handDrawn"){let ot=v.svg(y),ht=Kt(e,{roughness:0.7,fill:n,stroke:c,fillWeight:4,seed:s}),yt=ot.path(Tr(U,V,M,W,e.rx),ht);Z=y.insert(()=>(i.debug("Rough node insert CXC",yt),yt),":first-child"),Z.select("path:nth-child(2)").attr("style",m.join(";")),Z.select("path").attr("style",u.join(";").replace("fill","stroke"))}else Z=y.insert("rect",":first-child"),Z.attr("style",p).attr("rx",e.rx).attr("ry",e.ry).attr("x",U).attr("y",V).attr("width",M).attr("height",W);let{subGraphTitleTopMargin:tt}=_n(o);if(k.attr("transform",`translate(${e.x-_.width/2}, ${e.y-e.height/2+tt})`),l){let ot=k.select("span");if(ot)ot.attr("style",l)}let at=Z.node().getBBox();return e.offsetX=0,e.width=at.width,e.height=at.height,e.offsetY=_.height-e.padding/2,e.intersect=function(ot){return ui(e,ot)},{cluster:y,labelBBox:_}},"kanbanSection"),OS=t((r,e)=>{let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{altBackground:c,nodeBorder:l,borderColorArray:p}=s,m=r.insert("g").attr("class",e.cssClasses).attr("id",e.domId).attr("data-look",e.look);It(m,e.colorIndex,a,p);let u=m.insert("g",":first-child"),y=0*e.padding,x=e.width+y;e.diff=-e.padding;let k=e.height+y,w=e.x-x/2,_=e.y-k/2;e.width=x;let M;if(e.look==="handDrawn"){let V=v.svg(m).rectangle(w,_,x,k,{fill:c??"#efefef",fillStyle:"solid",roughness:0.5,strokeLineDash:[5],stroke:l,seed:n});M=m.insert(()=>V,":first-child").attr("class","divider")}else{M=u.insert("rect",":first-child");let U="outer";if(e.look==="neo")U="divider";else U="divider";M.attr("class",U).attr("x",w).attr("y",_).attr("width",x).attr("height",k).attr("data-look",e.look)}let W=M.node().getBBox();return e.height=W.height,e.offsetX=0,e.offsetY=0,e.intersect=function(U){return ui(e,U)},{cluster:m,labelBBox:{}}},"divider"),IS=t(async(r,e,o)=>{i.info(`Creating ${o.cssClass} for `,e.id,e);let a=d(),{theme:s,themeVariables:n,handDrawnSeed:c}=a,{borderColorArray:l}=n,{labelStyles:p,borderStyles:m}=E(e),u=r.insert("g").attr("class","cluster "+o.cssClass+" "+e.cssClasses).attr("id",e.domId??e.id).attr("data-look",e.look);It(u,e.colorIndex,s,l);let y=Xe(a),x=u.insert("g").attr("class","cluster-label"),k={width:0,height:0},w=e.label?.trim();if(w){let tt;if(e.labelType==="markdown")tt=await ct(x,e.label,{style:e.labelStyle,useHtmlLabels:y,isNode:!0,width:e.width});else tt=await Gr(x,e.label,e.labelStyle||"",!1,!0);if(k=tt.getBBox(),y){let at=tt.children[0],ot=g(tt);k=at.getBoundingClientRect(),ot.attr("width",k.width),ot.attr("height",k.height)}}let _=e.width<=k.width+e.padding?k.width+e.padding:e.width;if(e.width<=k.width+e.padding)e.diff=(_-e.width)/2-e.padding;else e.diff=-e.padding;let M=e.height,W=e.x-_/2,U=e.y-M/2,V;if(e.look==="handDrawn"){let tt=v.svg(u),at=Kt(e,{roughness:o.roughness,fill:o.fill,stroke:o.stroke,strokeWidth:o.strokeWidth,seed:c,...o.fill==="none"?{fillWeight:0}:{fillStyle:"solid"},...o.strokeDash?{strokeLineDash:o.strokeDash}:{}}),ot=tt.path(Tr(W,U,_,M,o.rx),at);V=u.insert(()=>ot,":first-child"),V.select("path:nth-child(2)").attr("style",m.join(";"))}else if(V=u.insert("rect",":first-child"),V.attr("rx",o.rx).attr("ry",o.rx).attr("x",W).attr("y",U).attr("width",_).attr("height",M).attr("fill",o.fill).attr("stroke",o.stroke).attr("stroke-width",o.strokeWidth+"px"),o.strokeDash)V.attr("stroke-dasharray",o.strokeDash.join(", "));if(w){let{subGraphTitleTopMargin:tt}=_n(a);if(x.attr("transform",`translate(${e.x-k.width/2}, ${e.y-e.height/2+tt})`),p){let at=x.select("span");if(at)at.attr("style",p)}}let Z=V.node().getBBox();return e.offsetX=0,e.width=Z.width,e.height=Z.height,e.offsetY=k.height-e.padding/2,e.intersect=function(tt){return ui(e,tt)},{cluster:u,labelBBox:k}},"createContainerGroup"),$S=t(async(r,e)=>{let{themeVariables:o}=d(),a=o.flowContainerStroke||o.secondaryBorderColor;return IS(r,e,{cssClass:"flow-cluster",rx:10,fill:"none",stroke:a,strokeWidth:0.75,roughness:0.7})},"flowGroup"),DS=t((r,e)=>{let o=r.boundaryType||"rect",a=o==="package"?20:r.padding,s=o==="package"?e.height+10:0,n=Math.max(r.width,e.width+a),c=o==="package"?Math.max(r.height,s+r.padding*2):r.height,l=r.x-n/2,p=r.y-c/2;return{boundaryType:o,width:n,height:c,x:l,y:p,bodyY:p+s,bodyHeight:c-s,tabHeight:s,tabWidth:o==="package"?Math.min(n,Math.max(80,e.width+20)):0}},"getUsecaseSystemBoundaryGeometry"),PS=t(async(r,e)=>{i.info("Creating usecase system boundary for ",e.id,e);let o=d(),{theme:a,themeVariables:s,handDrawnSeed:n}=o,{clusterBkg:c,clusterBorder:l,borderColorArray:p}=s,{labelStyles:m,nodeStyles:u}=E(e),{stylesMap:y}=ai(e),x=e.boundaryType||"rect",k=r.insert("g").attr("class",`cluster usecase-system-boundary usecase-system-boundary-${x} ${e.cssClasses}`).attr("id",typeof e.domId==="string"?e.domId:e.id).attr("data-boundary-type",x).attr("data-look",e.look);It(k,e.colorIndex,a,p);let w=Xe(o),_=k.insert("g").attr("class","cluster-label system-boundary-title"),M=await ct(_,e.label,{style:m,useHtmlLabels:w,isNode:!0}),W=M.getBBox();if(w){let rt=M.children[0],it=g(M);W=rt.getBoundingClientRect(),it.attr("width",W.width),it.attr("height",W.height)}let U=DS(e,W),{width:V,height:Z,x:tt,y:at,bodyY:ot,bodyHeight:ht,tabHeight:yt,tabWidth:Bt}=U;e.diff=e.width<=W.width+e.padding?(V-e.width)/2-e.padding:-e.padding;let kt=Kt(e,{fill:y.get("fill")||c,stroke:y.get("stroke")||l,strokeWidth:y.get("stroke-width")?.replace("px","")||1,seed:n});if(e.look==="handDrawn"){let rt=v.svg(k),it=rt.rectangle(tt,ot,V,ht,kt);if(k.insert(()=>it,":first-child").attr("class","boundary-body label-container"),x==="package"){let gt=rt.rectangle(tt,at,Bt,yt,kt);k.insert(()=>gt,":first-child").attr("class","boundary-tab system-boundary-package-tab label-container")}}else if(k.insert("rect",":first-child").attr("class","boundary-body label-container").attr("style",u).attr("x",tt).attr("y",ot).attr("width",V).attr("height",ht),x==="package")k.insert("rect",":first-child").attr("class","boundary-tab system-boundary-package-tab label-container").attr("style",u).attr("x",tt).attr("y",at).attr("width",Bt).attr("height",yt);let{subGraphTitleTopMargin:Ct}=_n(o);if(x==="package")_.attr("transform",`translate(${tt+(Bt-W.width)/2}, ${at+(yt-W.height)/2})`);else _.attr("transform",`translate(${e.x-W.width/2}, ${at+Ct})`);if(m)_.attr("style",m),_.select("span").attr("style",m);return e.offsetX=0,e.width=V,e.height=Z,e.offsetY=W.height-e.padding/2,e.labelBBox=W,e.intersect=function(rt){return ui(e,rt)},{cluster:k,labelBBox:W}},"usecaseSystemBoundary"),RS=v0,qS={rect:v0,squareRect:RS,roundedWithTitle:MS,noteGroup:AS,divider:OS,kanbanSection:ES,flowGroup:$S,usecaseSystemBoundary:PS,swimlane:FS};var L0=new Map,rr=t(async(r,e)=>{let o=e.shape||"rect",a=await qS[o](r,e);return L0.set(e.id,a),a},"insertCluster"),Mc=t(()=>{L0=new Map},"clear");var on=t((r,e)=>{if(e)return"translate("+-r.width/2+", "+-r.height/2+")";let o=r.x??0,a=r.y??0;return"translate("+-(o+r.width/2)+", "+-(a+r.height/2)+")"},"computeLabelTransform"),ut={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4,arrow_barb:0,arrow_barb_neo:5.5},F0={arrow_point:4,arrow_cross:12.5,arrow_circle:12.5};function an(r,e){if(r===void 0||e===void 0)return{angle:0,deltaX:0,deltaY:0};r=Le(r),e=Le(e);let[o,a]=[r.x,r.y],[s,n]=[e.x,e.y],c=s-o,l=n-a;return{angle:Math.atan(l/c),deltaX:c,deltaY:l}}t(an,"calculateDeltaAndAngle");var Le=t((r)=>{if(Array.isArray(r))return{x:r[0],y:r[1]};return r},"pointTransformer"),NS=t((r)=>({x:t(function(e,o,a){let s=0,n=Le(a[0]).x<Le(a[a.length-1]).x?"left":"right";if(o===0&&Object.hasOwn(ut,r.arrowTypeStart)){let{angle:k,deltaX:w}=an(a[0],a[1]);s=ut[r.arrowTypeStart]*Math.cos(k)*(w>=0?1:-1)}else if(o===a.length-1&&Object.hasOwn(ut,r.arrowTypeEnd)){let{angle:k,deltaX:w}=an(a[a.length-1],a[a.length-2]);s=ut[r.arrowTypeEnd]*Math.cos(k)*(w>=0?1:-1)}let c=Math.abs(Le(e).x-Le(a[a.length-1]).x),l=Math.abs(Le(e).y-Le(a[a.length-1]).y),p=Math.abs(Le(e).x-Le(a[0]).x),m=Math.abs(Le(e).y-Le(a[0]).y),u=ut[r.arrowTypeStart],y=ut[r.arrowTypeEnd],x=1;if(c<y&&c>0&&l<y){let k=y+x-c;k*=n==="right"?-1:1,s-=k}if(p<u&&p>0&&m<u){let k=u+x-p;k*=n==="right"?-1:1,s+=k}return Le(e).x+s},"x"),y:t(function(e,o,a){let s=0,n=Le(a[0]).y<Le(a[a.length-1]).y?"down":"up";if(o===0&&Object.hasOwn(ut,r.arrowTypeStart)){let{angle:k,deltaY:w}=an(a[0],a[1]);s=ut[r.arrowTypeStart]*Math.abs(Math.sin(k))*(w>=0?1:-1)}else if(o===a.length-1&&Object.hasOwn(ut,r.arrowTypeEnd)){let{angle:k,deltaY:w}=an(a[a.length-1],a[a.length-2]);s=ut[r.arrowTypeEnd]*Math.abs(Math.sin(k))*(w>=0?1:-1)}let c=Math.abs(Le(e).y-Le(a[a.length-1]).y),l=Math.abs(Le(e).x-Le(a[a.length-1]).x),p=Math.abs(Le(e).y-Le(a[0]).y),m=Math.abs(Le(e).x-Le(a[0]).x),u=ut[r.arrowTypeStart],y=ut[r.arrowTypeEnd],x=1;if(c<y&&c>0&&l<y){let k=y+x-c;k*=n==="up"?-1:1,s-=k}if(p<u&&p>0&&m<u){let k=u+x-p;k*=n==="up"?-1:1,s+=k}return Le(e).y+s},"y")}),"getLineFunctionsWithOffset"),WS=t((r,e,o,a,s,n=!1,c)=>{if(e.arrowTypeStart)A0(r,"start",e.arrowTypeStart,o,a,s,n,c);if(e.arrowTypeEnd)A0(r,"end",e.arrowTypeEnd,o,a,s,n,c)},"addEdgeMarkers"),zS={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_barb_neo:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},arrow_hierarchy:{type:"hierarchy",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},HS=["cross","point","circle","lollipop","aggregation","extension","composition","dependency","barb"],A0=t((r,e,o,a,s,n,c=!1,l)=>{if(!o||o==="none")return;let p=zS[o],m=p&&HS.includes(p.type);if(!p){i.warn(`Unknown arrow type: ${o}`);return}let u=p.type,k=`${s}_${n}-${u}${e==="start"?"Start":"End"}${c&&m?"-margin":""}`;if(l&&l.trim()!==""){let w=l.replace(/[^\dA-Za-z]/g,"_"),_=`${k}_${w}`;if(!document.getElementById(_)){let M=document.getElementById(k);if(M){let W=M.cloneNode(!0);W.id=_,W.querySelectorAll("path, circle, line").forEach((V)=>{if(V.setAttribute("stroke",l),p.fill)V.setAttribute("fill",l)}),M.parentNode?.appendChild(W)}}r.attr(`marker-${e}`,`url(${a}#${_})`)}else r.attr(`marker-${e}`,`url(${a}#${k})`)},"addEdgeMarker"),YS=t((r)=>typeof r==="string"?r:d()?.flowchart?.curve,"resolveEdgeCurveType"),pa=new Map,dt=new Map,Pc=t(()=>{pa.clear(),dt.clear()},"clear"),tc=t((r)=>Boolean(r.label||r.startLabelLeft||r.startLabelRight||r.endLabelLeft||r.endLabelRight),"hasEdgeLabel"),sn=t((r)=>{if(!r)return"";if(typeof r==="string")return r;return r.reduce((e,o)=>e+";"+o,"")},"getLabelStyles"),kn=t(async(r,e)=>{let o=d(),a=Xe(o),{labelStyles:s}=E(e);e.labelStyle=s;let n=r.insert("g").attr("class","edgeLabel"),c=n.insert("g").attr("class","label").attr("data-id",e.id),l=e.labelType==="markdown",p=void 0,m=await ct(r,e.label,{style:sn(e.labelStyle),useHtmlLabels:a,addSvgBackground:!0,isNode:!1,markdown:l,width:l?p:void 0},o);c.node().appendChild(m),i.info("abc82",e,e.labelType);let u,y;if(a){let k=m.children[0],w=g(m);u=await Bi.measure(()=>k.getBoundingClientRect()),y=u,w.attr("width",u.width),w.attr("height",u.height)}else{let k=g(m).select("text").node();await Bi.measure(()=>{if(u=m.getBBox(),k&&typeof k.getBBox==="function")y=k.getBBox();else y=u})}c.attr("transform",on(y,a)),pa.set(e.id,n),e.width=u.width,e.height=u.height;let x;if(e.startLabelLeft){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.startLabelLeft,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let W=_.children[0],U=g(_);M=W.getBoundingClientRect(),U.attr("width",M.width),U.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).startLeft=k,hn(x,e.startLabelLeft,M),nn(e,"startLeft",M)}if(e.startLabelRight){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.startLabelRight,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let W=_.children[0],U=g(_);M=W.getBoundingClientRect(),U.attr("width",M.width),U.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).startRight=k,hn(x,e.startLabelRight,M),nn(e,"startRight",M)}if(e.endLabelLeft){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.endLabelLeft,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let W=_.children[0],U=g(_);M=W.getBoundingClientRect(),U.attr("width",M.width),U.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).endLeft=k,hn(x,e.endLabelLeft,M),nn(e,"endLeft",M)}if(e.endLabelRight){let k=r.insert("g").attr("class","edgeTerminals"),w=k.insert("g").attr("class","inner"),_=await Gr(w,e.endLabelRight,sn(e.labelStyle)||"",!1,!1);x=_;let M=_.getBBox();if(a){let W=_.children[0],U=g(_);M=W.getBoundingClientRect(),U.attr("width",M.width),U.attr("height",M.height)}if(w.attr("transform",on(M,a)),!dt.get(e.id))dt.set(e.id,{});dt.get(e.id).endRight=k,hn(x,e.endLabelRight,M),nn(e,"endRight",M)}return m},"insertEdgeLabel");function nn(r,e,o){r.terminalLabelSizes??={},r.terminalLabelSizes[e]={width:o.width,height:o.height}}t(nn,"recordTerminalLabelSize");function hn(r,e,o){if(Xe(d())&&r)r.style.width=Math.max(e.length*9,o.width)+"px",r.style.height=o.height+"px"}t(hn,"setTerminalWidth");var nc=t((r,e)=>{let{x:o,y:a}=r;if(e?.updatedPath){let s=H.calcLabelPosition(e.updatedPath);if(e.originalPath){let n=H.calcLabelPosition(e.originalPath);o=r.x+(s.x-n.x),a=r.y+(s.y-n.y)}else o=s.x,a=s.y}return{x:o,y:a}},"resolveEdgeLabelPosition"),ua=t((r,e)=>{i.debug("Moving label abc88 ",r.id,r.label,pa.get(r.id),e);let o=d(),{subGraphTitleTotalMargin:a}=_n(o);if(r.label){let n=pa.get(r.id),{x:c,y:l}=nc(r,e);i.debug("Moving label "+r.label+" from (",r.x,",",r.y,") to (",c,",",l,") abc88"),n.attr("transform",`translate(${c}, ${l+a/2})`)}let s=e.updatedPath?e.updatedPath:e.originalPath;if(r.startLabelLeft){let n=dt.get(r.id).startLeft,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_left",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.startLabelRight){let n=dt.get(r.id).startRight,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_right",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.endLabelLeft){let n=dt.get(r.id).endLeft,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_left",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}if(r.endLabelRight){let n=dt.get(r.id).endRight,{x:c,y:l}=r;if(s){let p=H.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_right",s);c=p.x,l=p.y}n.attr("transform",`translate(${c}, ${l})`)}},"positionEdgeLabel"),US=t((r,e)=>{if(!r?.isLabelEdge||!r?.id?.endsWith("-to-label")||!Array.isArray(e))return e;if(e.length!==2)return e;let[o,a]=e,s=Math.abs(a.x-o.x),n=Math.abs(a.y-o.y);if(s<0.001||n<0.001)return e;if(n>=s)return[o,{x:o.x,y:a.y},a];return[o,{x:a.x,y:o.y},a]},"orthogonalizeToLabelClippedPoints"),jS=t((r,e)=>{let{x:o,y:a}=r,s=Math.abs(e.x-o),n=Math.abs(e.y-a),c=r.width/2,l=r.height/2;return s>=c||n>=l},"outsideNode"),GS=t((r,e,o)=>{i.debug(`intersection calc abc89:
|
|
294
294
|
outsidePoint: ${JSON.stringify(e)}
|
|
295
295
|
insidePoint : ${JSON.stringify(o)}
|
|
296
|
-
node : x:${r.x} y:${r.y} w:${r.width} h:${r.height}`);let{x:a,y:s}=r,n=Math.abs(a-o.x),c=r.width/2,l=o.x<e.x?c-n:c+n,p=r.height/2,m=Math.abs(e.y-o.y),u=Math.abs(e.x-o.x);if(Math.abs(s-e.y)*c>Math.abs(a-e.x)*p){let y=o.y<e.y?e.y-p-s:s-p-e.y;l=u*y/m;let x={x:o.x<e.x?o.x+l:o.x-u+l,y:o.y<e.y?o.y+m-y:o.y-m+y};if(l===0)x.x=e.x,x.y=e.y;if(u===0)x.x=e.x;if(m===0)x.y=e.y;return i.debug(`abc89 top/bottom calc, Q ${m}, q ${y}, R ${u}, r ${l}`,x),x}else{if(o.x<e.x)l=e.x-c-a;else l=a-c-e.x;let y=m*l/u,x=o.x<e.x?o.x+u-l:o.x-u+l,k=o.y<e.y?o.y+y:o.y-y;if(i.debug(`sides calc abc89, Q ${m}, q ${y}, R ${u}, r ${l}`,{_x:x,_y:k}),l===0)x=e.x,k=e.y;if(u===0)x=e.x;if(m===0)k=e.y;return{x,y:k}}},"intersection"),M0=t((r,e)=>{i.warn("abc88 cutPathAtIntersect",r,e);let o=[],a=r[0],s=!1;return r.forEach((n)=>{if(i.info("abc88 checking point",n,e),!jS(e,n)&&!s){let c=GS(e,a,n);i.debug("abc88 inside",n,a,c),i.debug("abc88 intersection",c,e);let l=!1;if(o.forEach((p)=>{l=l||p.x===c.x&&p.y===c.y}),!o.some((p)=>p.x===c.x&&p.y===c.y))o.push(c);else i.warn("abc88 no intersect",c,o);s=!0}else if(i.warn("abc88 outside",n,a),a=n,!s)o.push(n)}),i.debug("returning points",o),o},"cutPathAtIntersect");function O0(r){let e=[],o=[];for(let a=1;a<r.length-1;a++){let s=r[a-1],n=r[a],c=r[a+1];if(s.x===n.x&&n.y===c.y&&Math.abs(n.x-c.x)>5&&Math.abs(n.y-s.y)>5)e.push(n),o.push(a);else if(s.y===n.y&&n.x===c.x&&Math.abs(n.x-s.x)>5&&Math.abs(n.y-c.y)>5)e.push(n),o.push(a)}return{cornerPoints:e,cornerPointPositions:o}}t(O0,"extractCornerPoints");var E0=t(function(r,e,o){let a=e.x-r.x,s=e.y-r.y,n=Math.sqrt(a*a+s*s),c=o/n;return{x:e.x-c*a,y:e.y-c*s}},"findAdjacentPoint"),XS=t(function(r){let{cornerPointPositions:e}=O0(r),o=[];for(let a=0;a<r.length;a++)if(e.includes(a)){let s=r[a-1],n=r[a+1],c=r[a],l=E0(s,c,5),p=E0(n,c,5),m=p.x-l.x,u=p.y-l.y;o.push(l);let y=Math.sqrt(2)*2,x={x:c.x,y:c.y};if(Math.abs(n.x-s.x)>10&&Math.abs(n.y-s.y)>=10){i.debug("Corner point fixing",Math.abs(n.x-s.x),Math.abs(n.y-s.y));let k=5;if(c.x===l.x)x={x:m<0?l.x-k+y:l.x+k-y,y:u<0?l.y-y:l.y+y};else x={x:m<0?l.x-y:l.x+y,y:u<0?l.y-k+y:l.y+k-y}}else i.debug("Corner point skipping fixing",Math.abs(n.x-s.x),Math.abs(n.y-s.y));o.push(x,p)}else o.push(r[a]);return o},"fixCorners"),VS=t((r,e,o)=>{let a=r-e-o,s=2,n=2,c=4,l=Math.floor(a/4),p=Number.isFinite(l)?Math.max(0,l):0,m=Array(p).fill("2 2").join(" ");return`0 ${e} ${m} ${o}`},"generateDashArray"),ar=t(function(r,e,o,a,s,n,c,l=!1,p=void 0){if(!c)throw Error(`insertEdge: missing diagramId for edge "${e.id}" — edge IDs require a diagram prefix for uniqueness`);let{handDrawnSeed:m,layout:u}=d(),y=p??u,x=e.points,k=!1,w=s;var _=n;let M=[];for(let jt in e.cssCompiledStyles){if(Pi(jt))continue;M.push(e.cssCompiledStyles[jt])}if(y==="swimlane"){if(!l&&_.intersect&&w.intersect&&Array.isArray(x)&&x.length>=2)if(x.length===2)x=[w.intersect(x[0]),_.intersect(x[1])];else{let jt=x.slice(1,-1),se=jt[0],oe=jt[jt.length-1],fe=0.5,ge=Math.abs(x[x.length-1].x-oe.x)<0.5&&Math.abs(x[x.length-1].y-oe.y)<0.5,he=w.intersect(se),Ut=ge?oe:_.intersect(oe),re=Math.abs(Ut.x-oe.x)<0.5&&Math.abs(Ut.y-oe.y)<0.5,ne=Math.abs(he.x-se.x)<0.5&&Math.abs(he.y-se.y)<0.5?[]:[he],Le=re?[]:[Ut];x=[...ne,...jt,...Le]}x=US(e,x)}else if(_.intersect&&w.intersect&&!l)x=x.slice(1,e.points.length-1),x.unshift(w.intersect(x[0])),x.push(_.intersect(x[x.length-1]));let q=btoa(JSON.stringify(x));if(e.toCluster)i.info("to cluster abc88",o.get(e.toCluster)),x=M0(e.points,o.get(e.toCluster).node),k=!0;if(e.fromCluster)i.debug("from cluster abc88",o.get(e.fromCluster),JSON.stringify(x,null,2)),x=M0(x.reverse(),o.get(e.fromCluster).node).reverse(),k=!0;let Y=x.filter((jt)=>!Number.isNaN(jt.y)),V=YS(e.curve);if(V!=="rounded")Y=XS(Y);let Q=si;switch(V){case"linear":Q=si;break;case"basis":Q=so;break;case"cardinal":Q=va;break;case"bumpX":Q=ca;break;case"bumpY":Q=_a;break;case"catmullRom":Q=Fa;break;case"monotoneX":Q=Aa;break;case"monotoneY":Q=Ma;break;case"natural":Q=cs;break;case"step":Q=us;break;case"stepAfter":Q=Oa;break;case"stepBefore":Q=Ea;break;case"rounded":Q=si;break;default:Q=so}let{x:tt,y:at}=NS(e),ot=sa().x(tt).y(at).curve(Q),ht;switch(e.thickness){case"normal":ht="edge-thickness-normal";break;case"thick":ht="edge-thickness-thick";break;case"invisible":ht="edge-thickness-invisible";break;default:ht="edge-thickness-normal"}switch(e.pattern){case"solid":ht+=" edge-pattern-solid";break;case"dotted":ht+=" edge-pattern-dotted";break;case"dashed":ht+=" edge-pattern-dashed";break;default:ht+=" edge-pattern-solid"}let yt,Bt=V==="rounded"?I0($0(Y,e),5):ot(Y),kt=Array.isArray(e.style)?e.style:[e.style],Ct=kt.find((jt)=>jt?.startsWith("stroke:")),rt="";if(e.animate)rt="edge-animation-fast";if(e.animation)rt="edge-animation-"+e.animation;let it=!1;if(e.look==="handDrawn"){let jt=v.svg(r);Object.assign([],Y);let se=jt.path(Bt,{roughness:0.3,seed:m});ht+=" transition",yt=g(se).select("path").attr("id",`${c}-${e.id}`).attr("class"," "+ht+(e.classes?" "+e.classes:"")+(rt?" "+rt:"")).attr("style",kt?kt.reduce((fe,ge)=>fe+";"+ge,""):"");let oe=yt.attr("d");yt.attr("d",oe),r.node().appendChild(yt.node())}else{let jt=M.join(";"),se=kt?kt.reduce((re,ae)=>re+ae+";",""):"",oe=(jt?jt+";"+se+";":se)+";"+(kt?kt.reduce((re,ae)=>re+";"+ae,""):"");yt=r.append("path").attr("d",Bt).attr("id",`${c}-${e.id}`).attr("class"," "+ht+(e.classes?" "+e.classes:"")+(rt?" "+rt:"")).attr("style",oe),Ct=oe.match(/stroke:([^;]+)/)?.[1],it=e.animate===!0||!!e.animation||jt.includes("animation");let fe=yt.node(),ge=typeof fe.getTotalLength==="function"?fe.getTotalLength():0,he=F0[e.arrowTypeStart]||0,Ut=F0[e.arrowTypeEnd]||0;if(e.look==="neo"&&!it){let ae=`stroke-dasharray: ${e.pattern==="dotted"||e.pattern==="dashed"?VS(ge,he,Ut):`0 ${he} ${ge-he-Ut} ${Ut}`}; stroke-dashoffset: 0;`;yt.attr("style",ae+yt.attr("style"))}}if(yt.attr("data-edge",!0),yt.attr("data-et","edge"),yt.attr("data-id",e.id),yt.attr("data-points",q),yt.attr("data-look",Me(e.look)),e.showPoints)Y.forEach((jt)=>{r.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",jt.x).attr("cy",jt.y)});let gt="";if(d().flowchart.arrowMarkerAbsolute||d().state.arrowMarkerAbsolute)gt=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,gt=gt.replace(/\(/g,"\\(").replace(/\)/g,"\\)");i.info("arrowTypeStart",e.arrowTypeStart),i.info("arrowTypeEnd",e.arrowTypeEnd);let et=!it&&e?.look==="neo";WS(yt,e,gt,c,a,et,Ct);let wt=Math.floor(x.length/2),vt=x[wt];if(!H.isLabelCoordinateInPath(vt,yt.attr("d")))k=!0;let Xt={};if(k)Xt.updatedPath=x;return Xt.originalPath=e.points,Xt},"insertEdge");function I0(r,e){if(r.length<2)return"";let o="",a=r.length,s=0.00001;for(let n=0;n<a;n++){let c=r[n],l=r[n-1],p=r[n+1];if(n===0)o+=`M${c.x},${c.y}`;else if(n===a-1)o+=`L${c.x},${c.y}`;else{let m=c.x-l.x,u=c.y-l.y,y=p.x-c.x,x=p.y-c.y,k=Math.hypot(m,u),w=Math.hypot(y,x);if(k<s||w<s){o+=`L${c.x},${c.y}`;continue}let _=m/k,M=u/k,q=y/w,Y=x/w,V=_*q+M*Y,Q=Math.max(-1,Math.min(1,V)),tt=Math.acos(Q);if(tt<s||Math.abs(Math.PI-tt)<s){o+=`L${c.x},${c.y}`;continue}let at=Math.min(e/Math.sin(tt/2),k/2,w/2),ot=c.x-_*at,ht=c.y-M*at,yt=c.x+q*at,Bt=c.y+Y*at;o+=`L${ot},${ht}`,o+=`Q${c.x},${c.y} ${yt},${Bt}`}}return o}t(I0,"generateRoundedPath");function ad(r,e){if(!r||!e)return{angle:0,deltaX:0,deltaY:0};let o=e.x-r.x,a=e.y-r.y;return{angle:Math.atan2(a,o),deltaX:o,deltaY:a}}t(ad,"calculateDeltaAndAngle");function $0(r,e){let o=r.map((s)=>({...s}));if(r.length>=2&&ut[e.arrowTypeStart]){let s=ut[e.arrowTypeStart],n=r[0],c=r[1],{angle:l}=ad(n,c),p=s*Math.cos(l),m=s*Math.sin(l);o[0].x=n.x+p,o[0].y=n.y+m}let a=r.length;if(a>=2&&ut[e.arrowTypeEnd]){let s=ut[e.arrowTypeEnd],n=r[a-1],c=r[a-2],{angle:l}=ad(c,n),p=s*Math.cos(l),m=s*Math.sin(l);o[a-1].x=n.x-p,o[a-1].y=n.y-m}return o}t($0,"applyMarkerOffsetsToPoints");var KS=t((r,e,o,a)=>{e.forEach((s)=>{bT[s](r,o,a)})},"insertMarkers"),ZS=t((r,e,o)=>{i.trace("Making markers for ",o),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,7 L18,13 V 1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,1 V 13 L18,7 Z"),r.append("marker").attr("id",o+"_"+e+"-extensionStart-margin").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,7 18,13 18,1").style("stroke-width",2).style("stroke-dasharray","0"),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionEnd-margin").attr("class","marker extension "+e).attr("refX",9).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,1 10,13 18,7").style("stroke-width",2).style("stroke-dasharray","0")},"extension"),QS=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionStart-margin").attr("class","marker composition "+e).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("viewBox","0 0 15 15").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionEnd-margin").attr("class","marker composition "+e).attr("refX",3.5).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),JS=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationStart-margin").attr("class","marker aggregation "+e).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationEnd-margin").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),tT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyStart-margin").attr("class","marker dependency "+e).attr("refX",4).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyEnd-margin").attr("class","marker dependency "+e).attr("refX",16).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),eT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopStart-margin").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopEnd-margin").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2)},"lollipop"),rT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointEnd-margin").attr("class","marker "+e).attr("viewBox","0 0 11.5 14").attr("refX",11.5).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",10.5).attr("markerHeight",14).attr("orient","auto").append("path").attr("d","M 0 0 L 11.5 7 L 0 14 z").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointStart-margin").attr("class","marker "+e).attr("viewBox","0 0 11.5 14").attr("refX",1).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11.5).attr("markerHeight",14).attr("orient","auto").append("polygon").attr("points","0,7 11.5,14 11.5,0").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"point"),iT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleEnd-margin").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refY",5).attr("refX",12.25).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleStart-margin").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"circle"),oT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-crossEnd-margin").attr("class","marker cross "+e).attr("viewBox","0 0 15 15").attr("refX",17.7).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5),r.append("marker").attr("id",o+"_"+e+"-crossStart-margin").attr("class","marker cross "+e).attr("viewBox","0 0 15 15").attr("refX",-3.5).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5).style("stroke-dasharray","1,0")},"cross"),sT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),aT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{transitionColor:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd-margin").attr("refX",17).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z").attr("fill",`${n}`)},"barbNeo"),nT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),lT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),a.append("path").attr("d","M9,0 L9,18");let s=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),s.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),hT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),cT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),a.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");let s=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),s.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),uT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M9,0 L9,18 M15,0 L15,18").attr("stroke-width",`${n}`),r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M3,0 L3,18 M9,0 L9,18").attr("stroke-width",`${n}`)},"only_one_neo"),fT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n,mainBkg:c}=s,l=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse");l.append("circle").attr("fill",c??"white").attr("cx",21).attr("cy",9).attr("stroke-width",`${n}`).attr("r",6),l.append("path").attr("d","M9,0 L9,18").attr("stroke-width",`${n}`);let p=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("markerUnits","userSpaceOnUse").attr("orient","auto");p.append("circle").attr("fill",c??"white").attr("cx",9).attr("cy",9).attr("stroke-width",`${n}`).attr("r",6),p.append("path").attr("d","M21,0 L21,18").attr("stroke-width",`${n}`)},"zero_or_one_neo"),dT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27").attr("stroke-width",`${n}`),r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18").attr("stroke-width",`${n}`)},"one_or_more_neo"),pT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n,mainBkg:c}=s,l=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto");l.append("circle").attr("fill",c??"white").attr("cx",45.5).attr("cy",18).attr("r",6).attr("stroke-width",`${n}`),l.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18").attr("stroke-width",`${n}`);let p=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse");p.append("circle").attr("fill",c??"white").attr("cx",11).attr("cy",18).attr("r",6).attr("stroke-width",`${n}`),p.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18").attr("stroke-width",`${n}`)},"zero_or_more_neo"),gT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0
|
|
296
|
+
node : x:${r.x} y:${r.y} w:${r.width} h:${r.height}`);let{x:a,y:s}=r,n=Math.abs(a-o.x),c=r.width/2,l=o.x<e.x?c-n:c+n,p=r.height/2,m=Math.abs(e.y-o.y),u=Math.abs(e.x-o.x);if(Math.abs(s-e.y)*c>Math.abs(a-e.x)*p){let y=o.y<e.y?e.y-p-s:s-p-e.y;l=u*y/m;let x={x:o.x<e.x?o.x+l:o.x-u+l,y:o.y<e.y?o.y+m-y:o.y-m+y};if(l===0)x.x=e.x,x.y=e.y;if(u===0)x.x=e.x;if(m===0)x.y=e.y;return i.debug(`abc89 top/bottom calc, Q ${m}, q ${y}, R ${u}, r ${l}`,x),x}else{if(o.x<e.x)l=e.x-c-a;else l=a-c-e.x;let y=m*l/u,x=o.x<e.x?o.x+u-l:o.x-u+l,k=o.y<e.y?o.y+y:o.y-y;if(i.debug(`sides calc abc89, Q ${m}, q ${y}, R ${u}, r ${l}`,{_x:x,_y:k}),l===0)x=e.x,k=e.y;if(u===0)x=e.x;if(m===0)k=e.y;return{x,y:k}}},"intersection"),M0=t((r,e)=>{i.warn("abc88 cutPathAtIntersect",r,e);let o=[],a=r[0],s=!1;return r.forEach((n)=>{if(i.info("abc88 checking point",n,e),!jS(e,n)&&!s){let c=GS(e,a,n);i.debug("abc88 inside",n,a,c),i.debug("abc88 intersection",c,e);let l=!1;if(o.forEach((p)=>{l=l||p.x===c.x&&p.y===c.y}),!o.some((p)=>p.x===c.x&&p.y===c.y))o.push(c);else i.warn("abc88 no intersect",c,o);s=!0}else if(i.warn("abc88 outside",n,a),a=n,!s)o.push(n)}),i.debug("returning points",o),o},"cutPathAtIntersect");function O0(r){let e=[],o=[];for(let a=1;a<r.length-1;a++){let s=r[a-1],n=r[a],c=r[a+1];if(s.x===n.x&&n.y===c.y&&Math.abs(n.x-c.x)>5&&Math.abs(n.y-s.y)>5)e.push(n),o.push(a);else if(s.y===n.y&&n.x===c.x&&Math.abs(n.x-s.x)>5&&Math.abs(n.y-c.y)>5)e.push(n),o.push(a)}return{cornerPoints:e,cornerPointPositions:o}}t(O0,"extractCornerPoints");var E0=t(function(r,e,o){let a=e.x-r.x,s=e.y-r.y,n=Math.sqrt(a*a+s*s),c=o/n;return{x:e.x-c*a,y:e.y-c*s}},"findAdjacentPoint"),XS=t(function(r){let{cornerPointPositions:e}=O0(r),o=[];for(let a=0;a<r.length;a++)if(e.includes(a)){let s=r[a-1],n=r[a+1],c=r[a],l=E0(s,c,5),p=E0(n,c,5),m=p.x-l.x,u=p.y-l.y;o.push(l);let y=Math.sqrt(2)*2,x={x:c.x,y:c.y};if(Math.abs(n.x-s.x)>10&&Math.abs(n.y-s.y)>=10){i.debug("Corner point fixing",Math.abs(n.x-s.x),Math.abs(n.y-s.y));let k=5;if(c.x===l.x)x={x:m<0?l.x-k+y:l.x+k-y,y:u<0?l.y-y:l.y+y};else x={x:m<0?l.x-y:l.x+y,y:u<0?l.y-k+y:l.y+k-y}}else i.debug("Corner point skipping fixing",Math.abs(n.x-s.x),Math.abs(n.y-s.y));o.push(x,p)}else o.push(r[a]);return o},"fixCorners"),VS=t((r,e,o)=>{let a=r-e-o,s=2,n=2,c=4,l=Math.floor(a/4),p=Number.isFinite(l)?Math.max(0,l):0,m=Array(p).fill("2 2").join(" ");return`0 ${e} ${m} ${o}`},"generateDashArray"),ar=t(function(r,e,o,a,s,n,c,l=!1,p=void 0){if(!c)throw Error(`insertEdge: missing diagramId for edge "${e.id}" — edge IDs require a diagram prefix for uniqueness`);let{handDrawnSeed:m,layout:u}=d(),y=p??u,x=e.points,k=!1,w=s;var _=n;let M=[];for(let jt in e.cssCompiledStyles){if(Pi(jt))continue;M.push(e.cssCompiledStyles[jt])}if(y==="swimlane"){if(!l&&_.intersect&&w.intersect&&Array.isArray(x)&&x.length>=2)if(x.length===2)x=[w.intersect(x[0]),_.intersect(x[1])];else{let jt=x.slice(1,-1),se=jt[0],oe=jt[jt.length-1],de=0.5,ge=Math.abs(x[x.length-1].x-oe.x)<0.5&&Math.abs(x[x.length-1].y-oe.y)<0.5,he=w.intersect(se),Ut=ge?oe:_.intersect(oe),re=Math.abs(Ut.x-oe.x)<0.5&&Math.abs(Ut.y-oe.y)<0.5,ne=Math.abs(he.x-se.x)<0.5&&Math.abs(he.y-se.y)<0.5?[]:[he],Be=re?[]:[Ut];x=[...ne,...jt,...Be]}x=US(e,x)}else if(_.intersect&&w.intersect&&!l)x=x.slice(1,e.points.length-1),x.unshift(w.intersect(x[0])),x.push(_.intersect(x[x.length-1]));let W=btoa(JSON.stringify(x));if(e.toCluster)i.info("to cluster abc88",o.get(e.toCluster)),x=M0(e.points,o.get(e.toCluster).node),k=!0;if(e.fromCluster)i.debug("from cluster abc88",o.get(e.fromCluster),JSON.stringify(x,null,2)),x=M0(x.reverse(),o.get(e.fromCluster).node).reverse(),k=!0;let U=x.filter((jt)=>!Number.isNaN(jt.y)),V=YS(e.curve);if(V!=="rounded")U=XS(U);let Z=si;switch(V){case"linear":Z=si;break;case"basis":Z=so;break;case"cardinal":Z=va;break;case"bumpX":Z=ca;break;case"bumpY":Z=_a;break;case"catmullRom":Z=Fa;break;case"monotoneX":Z=Aa;break;case"monotoneY":Z=Ma;break;case"natural":Z=cs;break;case"step":Z=us;break;case"stepAfter":Z=Oa;break;case"stepBefore":Z=Ea;break;case"rounded":Z=si;break;default:Z=so}let{x:tt,y:at}=NS(e),ot=sa().x(tt).y(at).curve(Z),ht;switch(e.thickness){case"normal":ht="edge-thickness-normal";break;case"thick":ht="edge-thickness-thick";break;case"invisible":ht="edge-thickness-invisible";break;default:ht="edge-thickness-normal"}switch(e.pattern){case"solid":ht+=" edge-pattern-solid";break;case"dotted":ht+=" edge-pattern-dotted";break;case"dashed":ht+=" edge-pattern-dashed";break;default:ht+=" edge-pattern-solid"}let yt,Bt=V==="rounded"?I0($0(U,e),5):ot(U),kt=Array.isArray(e.style)?e.style:[e.style],Ct=kt.find((jt)=>jt?.startsWith("stroke:")),rt="";if(e.animate)rt="edge-animation-fast";if(e.animation)rt="edge-animation-"+e.animation;let it=!1;if(e.look==="handDrawn"){let jt=v.svg(r);Object.assign([],U);let se=jt.path(Bt,{roughness:0.3,seed:m});ht+=" transition",yt=g(se).select("path").attr("id",`${c}-${e.id}`).attr("class"," "+ht+(e.classes?" "+e.classes:"")+(rt?" "+rt:"")).attr("style",kt?kt.reduce((de,ge)=>de+";"+ge,""):"");let oe=yt.attr("d");yt.attr("d",oe),r.node().appendChild(yt.node())}else{let jt=M.join(";"),se=kt?kt.reduce((re,ae)=>re+ae+";",""):"",oe=(jt?jt+";"+se+";":se)+";"+(kt?kt.reduce((re,ae)=>re+";"+ae,""):"");yt=r.append("path").attr("d",Bt).attr("id",`${c}-${e.id}`).attr("class"," "+ht+(e.classes?" "+e.classes:"")+(rt?" "+rt:"")).attr("style",oe),Ct=oe.match(/stroke:([^;]+)/)?.[1],it=e.animate===!0||!!e.animation||jt.includes("animation");let de=yt.node(),ge=typeof de.getTotalLength==="function"?de.getTotalLength():0,he=F0[e.arrowTypeStart]||0,Ut=F0[e.arrowTypeEnd]||0;if(e.look==="neo"&&!it){let ae=`stroke-dasharray: ${e.pattern==="dotted"||e.pattern==="dashed"?VS(ge,he,Ut):`0 ${he} ${ge-he-Ut} ${Ut}`}; stroke-dashoffset: 0;`;yt.attr("style",ae+yt.attr("style"))}}if(yt.attr("data-edge",!0),yt.attr("data-et","edge"),yt.attr("data-id",e.id),yt.attr("data-points",W),yt.attr("data-look",Fe(e.look)),e.showPoints)U.forEach((jt)=>{r.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",jt.x).attr("cy",jt.y)});let gt="";if(d().flowchart.arrowMarkerAbsolute||d().state.arrowMarkerAbsolute)gt=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,gt=gt.replace(/\(/g,"\\(").replace(/\)/g,"\\)");i.info("arrowTypeStart",e.arrowTypeStart),i.info("arrowTypeEnd",e.arrowTypeEnd);let et=!it&&e?.look==="neo";WS(yt,e,gt,c,a,et,Ct);let wt=Math.floor(x.length/2),vt=x[wt];if(!H.isLabelCoordinateInPath(vt,yt.attr("d")))k=!0;let Xt={};if(k)Xt.updatedPath=x;return Xt.originalPath=e.points,Xt},"insertEdge");function I0(r,e){if(r.length<2)return"";let o="",a=r.length,s=0.00001;for(let n=0;n<a;n++){let c=r[n],l=r[n-1],p=r[n+1];if(n===0)o+=`M${c.x},${c.y}`;else if(n===a-1)o+=`L${c.x},${c.y}`;else{let m=c.x-l.x,u=c.y-l.y,y=p.x-c.x,x=p.y-c.y,k=Math.hypot(m,u),w=Math.hypot(y,x);if(k<s||w<s){o+=`L${c.x},${c.y}`;continue}let _=m/k,M=u/k,W=y/w,U=x/w,V=_*W+M*U,Z=Math.max(-1,Math.min(1,V)),tt=Math.acos(Z);if(tt<s||Math.abs(Math.PI-tt)<s){o+=`L${c.x},${c.y}`;continue}let at=Math.min(e/Math.sin(tt/2),k/2,w/2),ot=c.x-_*at,ht=c.y-M*at,yt=c.x+W*at,Bt=c.y+U*at;o+=`L${ot},${ht}`,o+=`Q${c.x},${c.y} ${yt},${Bt}`}}return o}t(I0,"generateRoundedPath");function ad(r,e){if(!r||!e)return{angle:0,deltaX:0,deltaY:0};let o=e.x-r.x,a=e.y-r.y;return{angle:Math.atan2(a,o),deltaX:o,deltaY:a}}t(ad,"calculateDeltaAndAngle");function $0(r,e){let o=r.map((s)=>({...s}));if(r.length>=2&&ut[e.arrowTypeStart]){let s=ut[e.arrowTypeStart],n=r[0],c=r[1],{angle:l}=ad(n,c),p=s*Math.cos(l),m=s*Math.sin(l);o[0].x=n.x+p,o[0].y=n.y+m}let a=r.length;if(a>=2&&ut[e.arrowTypeEnd]){let s=ut[e.arrowTypeEnd],n=r[a-1],c=r[a-2],{angle:l}=ad(c,n),p=s*Math.cos(l),m=s*Math.sin(l);o[a-1].x=n.x-p,o[a-1].y=n.y-m}return o}t($0,"applyMarkerOffsetsToPoints");var KS=t((r,e,o,a)=>{e.forEach((s)=>{bT[s](r,o,a)})},"insertMarkers"),ZS=t((r,e,o)=>{i.trace("Making markers for ",o),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,7 L18,13 V 1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 1,1 V 13 L18,7 Z"),r.append("marker").attr("id",o+"_"+e+"-extensionStart-margin").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,7 18,13 18,1").style("stroke-width",2).style("stroke-dasharray","0"),r.append("defs").append("marker").attr("id",o+"_"+e+"-extensionEnd-margin").attr("class","marker extension "+e).attr("refX",9).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("viewBox","0 0 20 14").append("polygon").attr("points","10,1 10,13 18,7").style("stroke-width",2).style("stroke-dasharray","0")},"extension"),QS=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionStart-margin").attr("class","marker composition "+e).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("viewBox","0 0 15 15").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-compositionEnd-margin").attr("class","marker composition "+e).attr("refX",3.5).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),JS=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationStart-margin").attr("class","marker aggregation "+e).attr("refX",15).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-aggregationEnd-margin").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",2).attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),tT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyStart-margin").attr("class","marker dependency "+e).attr("refX",4).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-dependencyEnd-margin").attr("class","marker dependency "+e).attr("refX",16).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").style("stroke-width",0).attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),eT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopStart-margin").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2),r.append("defs").append("marker").attr("id",o+"_"+e+"-lollipopEnd-margin").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("circle").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6).attr("stroke-width",2)},"lollipop"),rT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointEnd-margin").attr("class","marker "+e).attr("viewBox","0 0 11.5 14").attr("refX",11.5).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",10.5).attr("markerHeight",14).attr("orient","auto").append("path").attr("d","M 0 0 L 11.5 7 L 0 14 z").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-pointStart-margin").attr("class","marker "+e).attr("viewBox","0 0 11.5 14").attr("refX",1).attr("refY",7).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11.5).attr("markerHeight",14).attr("orient","auto").append("polygon").attr("points","0,7 11.5,14 11.5,0").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"point"),iT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleEnd-margin").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refY",5).attr("refX",12.25).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-circleStart-margin").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",14).attr("markerHeight",14).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",0).style("stroke-dasharray","1,0")},"circle"),oT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),r.append("marker").attr("id",o+"_"+e+"-crossEnd-margin").attr("class","marker cross "+e).attr("viewBox","0 0 15 15").attr("refX",17.7).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5),r.append("marker").attr("id",o+"_"+e+"-crossStart-margin").attr("class","marker cross "+e).attr("viewBox","0 0 15 15").attr("refX",-3.5).attr("refY",7.5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 1,1 L 14,14 M 1,14 L 14,1").attr("class","arrowMarkerPath").style("stroke-width",2.5).style("stroke-dasharray","1,0")},"cross"),sT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),aT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{transitionColor:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z"),r.append("defs").append("marker").attr("id",o+"_"+e+"-barbEnd-margin").attr("refX",17).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L11,14 L13,7 L11,0 Z").attr("fill",`${n}`)},"barbNeo"),nT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),lT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),a.append("path").attr("d","M9,0 L9,18");let s=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),s.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),hT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),cT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),a.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");let s=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");s.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),s.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),uT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M9,0 L9,18 M15,0 L15,18").attr("stroke-width",`${n}`),r.append("defs").append("marker").attr("id",o+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M3,0 L3,18 M9,0 L9,18").attr("stroke-width",`${n}`)},"only_one_neo"),fT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n,mainBkg:c}=s,l=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto").attr("markerUnits","userSpaceOnUse");l.append("circle").attr("fill",c??"white").attr("cx",21).attr("cy",9).attr("stroke-width",`${n}`).attr("r",6),l.append("path").attr("d","M9,0 L9,18").attr("stroke-width",`${n}`);let p=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("markerUnits","userSpaceOnUse").attr("orient","auto");p.append("circle").attr("fill",c??"white").attr("cx",9).attr("cy",9).attr("stroke-width",`${n}`).attr("r",6),p.append("path").attr("d","M21,0 L21,18").attr("stroke-width",`${n}`)},"zero_or_one_neo"),dT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27").attr("stroke-width",`${n}`),r.append("defs").append("marker").attr("id",o+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18").attr("stroke-width",`${n}`)},"one_or_more_neo"),pT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n,mainBkg:c}=s,l=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("markerUnits","userSpaceOnUse").attr("orient","auto");l.append("circle").attr("fill",c??"white").attr("cx",45.5).attr("cy",18).attr("r",6).attr("stroke-width",`${n}`),l.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18").attr("stroke-width",`${n}`);let p=r.append("defs").append("marker").attr("id",o+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto").attr("markerUnits","userSpaceOnUse");p.append("circle").attr("fill",c??"white").attr("cx",11).attr("cy",18).attr("r",6).attr("stroke-width",`${n}`),p.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18").attr("stroke-width",`${n}`)},"zero_or_more_neo"),gT=t((r,e,o)=>{r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0
|
|
297
297
|
L20,10
|
|
298
298
|
M20,10
|
|
299
299
|
L0,20`)},"requirement_arrow"),mT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s;r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").attr("stroke-width",`${n}`).attr("viewBox","0 0 25 20").append("path").attr("d",`M0,0
|
|
300
300
|
L20,10
|
|
301
301
|
M20,10
|
|
302
|
-
L0,20`).attr("stroke-linejoin","miter")},"requirement_arrow_neo"),yT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");a.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),a.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),a.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),xT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s,c=r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("g");c.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),c.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),c.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10),c.selectAll("*").attr("stroke-width",`${n}`)},"requirement_contains_neo"),CT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-hierarchyEnd").attr("class","marker hierarchy "+e).attr("viewBox","0 0 12 10").attr("refX",10).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",10).attr("orient","auto").append("path").attr("d","M 0 0 L 6 5 L 0 10 M 4 0 L 10 5 L 4 10").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0").style("fill","none"),r.append("marker").attr("id",o+"_"+e+"-hierarchyStart").attr("class","marker hierarchy "+e).attr("viewBox","0 0 12 10").attr("refX",2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",10).attr("orient","auto").append("path").attr("d","M 12 0 L 6 5 L 12 10 M 8 0 L 2 5 L 8 10").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0").style("fill","none")},"hierarchy"),bT={extension:ZS,composition:QS,aggregation:JS,dependency:tT,lollipop:eT,point:rT,circle:iT,cross:oT,barb:sT,barbNeo:aT,hierarchy:CT,only_one:nT,zero_or_one:lT,one_or_more:hT,zero_or_more:cT,only_one_neo:uT,zero_or_one_neo:fT,one_or_more_neo:dT,zero_or_more_neo:pT,requirement_arrow:gT,requirement_contains:yT,requirement_arrow_neo:mT,requirement_contains_neo:xT},da=KS;var kT={common:C,getConfig:A,insertCluster:rr,insertEdge:ar,insertEdgeLabel:kn,insertMarkers:da,insertNode:wn,interpolateToCurve:bl,labelHelper:
|
|
303
|
-
export{t,er,bo,i,Ti,X,pt,
|
|
302
|
+
L0,20`).attr("stroke-linejoin","miter")},"requirement_arrow_neo"),yT=t((r,e,o)=>{let a=r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");a.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),a.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),a.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),xT=t((r,e,o)=>{let a=A(),{themeVariables:s}=a,{strokeWidth:n}=s,c=r.append("defs").append("marker").attr("id",o+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").attr("markerUnits","userSpaceOnUse").append("g");c.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),c.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),c.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10),c.selectAll("*").attr("stroke-width",`${n}`)},"requirement_contains_neo"),CT=t((r,e,o)=>{r.append("marker").attr("id",o+"_"+e+"-hierarchyEnd").attr("class","marker hierarchy "+e).attr("viewBox","0 0 12 10").attr("refX",10).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",10).attr("orient","auto").append("path").attr("d","M 0 0 L 6 5 L 0 10 M 4 0 L 10 5 L 4 10").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0").style("fill","none"),r.append("marker").attr("id",o+"_"+e+"-hierarchyStart").attr("class","marker hierarchy "+e).attr("viewBox","0 0 12 10").attr("refX",2).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",10).attr("orient","auto").append("path").attr("d","M 12 0 L 6 5 L 12 10 M 8 0 L 2 5 L 8 10").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0").style("fill","none")},"hierarchy"),bT={extension:ZS,composition:QS,aggregation:JS,dependency:tT,lollipop:eT,point:rT,circle:iT,cross:oT,barb:sT,barbNeo:aT,hierarchy:CT,only_one:nT,zero_or_one:lT,one_or_more:hT,zero_or_more:cT,only_one_neo:uT,zero_or_one_neo:fT,one_or_more_neo:dT,zero_or_more_neo:pT,requirement_arrow:gT,requirement_contains:yT,requirement_arrow_neo:mT,requirement_contains_neo:xT},da=KS;var kT={common:C,getConfig:A,insertCluster:rr,insertEdge:ar,insertEdgeLabel:kn,insertMarkers:da,insertNode:wn,interpolateToCurve:bl,labelHelper:j,log:i,positionEdgeLabel:ua},wT=["elk.stress","elk.force","elk.mrtree","elk.sporeOverlap","elk.box","elk.rectpacking"],cn=Object.create(null),rc=t((r)=>{for(let e of r)cn[e.name]=e},"registerLayoutLoaders"),ST=t(()=>{let r=t(async()=>await (S("64k06g43"),import("./chunk-64k06g43.js")),"loader");return[{name:"elk",loader:r,algorithm:"elk.layered"},...wT.map((e)=>({name:e,loader:r,algorithm:e}))]},"elkLayoutLoaders"),TT=t(()=>{rc([{name:"dagre",loader:t(async()=>await (S("e3b2krd7"),import("./chunk-e3b2krd7.js")),"loader")},{name:"swimlane",loader:t(async()=>await (S("zj9s9w76"),import("./chunk-zj9s9w76.js")),"loader")},{name:"cose-bilkent",loader:t(async()=>await (S("4ytc5sth"),import("./chunk-4ytc5sth.js")),"loader")},...ST()])},"registerDefaultLayoutLoaders");TT();var He=t(async(r,e)=>{if(!Object.hasOwn(cn,r.layoutAlgorithm))throw Error(`Unknown layout algorithm: ${r.layoutAlgorithm}`);if(r.diagramId)for(let s of r.nodes){let n=s.domId||s.id;s.domId=`${r.diagramId}-${n}`}let o=cn[r.layoutAlgorithm],a=await o.loader();return Eo(e,r.config),a.render(r,e,kT,{algorithm:o.algorithm})},"render"),nd="dagre",Ue=t((r="",{fallback:e=nd}={})=>{if(Object.hasOwn(cn,r))return r;for(let o of[e,nd])if(Object.hasOwn(cn,o))return i.warn(`Layout algorithm ${r} is not registered. Using ${o} as fallback.`),o;throw Error(`Neither layout algorithm ${r}, ${e}, nor ${nd} is registered.`)},"getRegisteredLayoutAlgorithm");
|
|
303
|
+
export{t,er,bo,i,Ti,X,pt,Ie,ue,ja,f,h,st,zs,Hs,Br,qa,xo,gc,Ae,Ye,tr,F,Us,mr,ln,_o,vc,yc,bc,js,qs,A,xc,Ei,_c,Xe,na,q,Vs,nr,$e,Va,Ga,C,Y,pn,wo,wc,ko,L,N,R,P,I,O,D,d,fr,Fr,Wa,Li,Co,g,zr,Ya,Hr,$n,Gs,Et,Xa,kc,hr,ra,bt,Ka,we,Ws,Lt,Ur,Cc,So,Bn,aa,xt,Za,Ni,ia,Sc,Ys,oa,Ac,Mi,Ao,To,sa,ca,J,qt,Vt,Eo,Pi,E,Xs,jr,Gt,la,qr,gr,Lo,Qa,Ja,ei,ti,No,Mo,Po,Ro,Io,Do,Oo,$o,Bo,Fo,zo,Ho,Uo,jo,qo,Vo,Go,vr,ni,Ri,Wo,Ks,Tc,Yo,Zs,Qs,Vr,Ii,Pt,Di,Xo,Js,Nt,Q,H,Ec,Fn,_t,Ko,Zo,ec,ct,Oi,De,Ne,Me,un,Rt,It,v,j,B,T,$i,ri,_n,wn,Lc,Nc,dn,rr,Mc,ut,pa,dt,Pc,tc,kn,nc,ua,ar,da,rc,He,Ue};
|