@kabmo-labs/kabmo 0.31.0 → 0.32.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/index.html +1 -1
- package/dist/client/index.js +464 -445
- package/dist/client/static/js/CsvGrid-amafmq3z.js +2 -0
- package/dist/client/static/js/DocxView-851ps9t0.js +58 -0
- package/dist/client/static/js/DrawioView-kw1vy3r2.js +5 -0
- package/dist/client/static/js/ImageView-ksx9bbct.js +1 -0
- package/dist/client/static/js/LayoutWrapper-9ftz050x.js +2 -0
- package/dist/client/static/js/Modal-f8x3j3be.js +38 -0
- package/dist/client/static/js/PdfView-f5jkm0rs.js +1 -0
- package/dist/client/static/js/SessionsView-wzdf1cp6.js +1 -0
- package/dist/client/static/js/SheetView-23zxy30b.js +140 -0
- package/dist/client/static/js/SvgPreview-c341y50e.js +1 -0
- package/dist/client/static/js/__vite-browser-external-2447137e-mq6vaetg.js +0 -0
- package/dist/client/static/js/abnfDiagram-O67JEVCF-2dc3mpk6.js +1 -0
- package/dist/client/static/js/andromeeda-17pn42cc.js +1 -0
- package/dist/client/static/js/architecture-7GRP2DOG-4wsd6vk0.js +1 -0
- package/dist/client/static/js/architectureDiagram-NJMV4G6O-7jmrr5ja.js +36 -0
- package/dist/client/static/js/astro-sjtf954j.js +1 -0
- package/dist/client/static/js/aurora-x-hxy97145.js +1 -0
- package/dist/client/static/js/ayu-dark-x0jd4baz.js +1 -0
- package/dist/client/static/js/ayu-light-12fg03q0.js +1 -0
- package/dist/client/static/js/ayu-mirage-52h7xjbv.js +1 -0
- package/dist/client/static/js/bash-h6pkqvth.js +1 -0
- package/dist/client/static/js/blockDiagram-BEXU5L5S-jrk2m0ea.js +140 -0
- package/dist/client/static/js/c-thbdzmwv.js +1 -0
- package/dist/client/static/js/c4Diagram-YGBWAQC7-48cyncjd.js +38 -0
- package/dist/client/static/js/catppuccin-frappe-fqgpn512.js +1 -0
- package/dist/client/static/js/catppuccin-latte-tr2x6gmz.js +1 -0
- package/dist/client/static/js/catppuccin-macchiato-rm7kh084.js +1 -0
- package/dist/client/static/js/catppuccin-mocha-hw0dzp99.js +1 -0
- package/dist/client/static/js/classDiagram-v2-NBCMYWYE-gm7jt1cd.js +217 -0
- package/dist/client/static/js/clike-h8p24dc6.js +1 -0
- package/dist/client/static/js/clojure-tf457n84.js +1 -0
- package/dist/client/static/js/clojure-w19rx1x5.js +1 -0
- package/dist/client/static/js/cmake-qpejsvqg.js +1 -0
- package/dist/client/static/js/cose-bilkent-JH36ORCC-g0g3z0xp.js +1 -0
- package/dist/client/static/js/cpp-r1za1kke.js +1 -0
- package/dist/client/static/js/csharp-dap1ppts.js +1 -0
- package/dist/client/static/js/css-qsv4vvke.js +1 -0
- package/dist/client/static/js/css-tf1s0nb7.js +1 -0
- package/dist/client/static/js/cynefin-OW5HDTMX-eycwde8c.js +1 -0
- package/dist/client/static/js/cynefinDiagram-VND7K2PF-6vjde6am.js +62 -0
- package/dist/client/static/js/dagre-6A5THRUB-q6k8bx1j.js +4 -0
- package/dist/client/static/js/dark-plus-weqfnwnf.js +1 -0
- package/dist/client/static/js/dart-dxn88tw0.js +1 -0
- package/dist/client/static/js/diagram-22UHCM2B-87cmze2n.js +200 -0
- package/dist/client/static/js/diagram-3UASUU5V-1ejbr2p4.js +24 -0
- package/dist/client/static/js/diagram-ATOU4E4O-vaw1r6k2.js +3 -0
- package/dist/client/static/js/diagram-CDSNMT55-gxm9zv7d.js +30 -0
- package/dist/client/static/js/diagram-MLGK6HIB-x010xswm.js +24 -0
- package/dist/client/static/js/diagram-MPIPVDR6-qtcq7e6c.js +41 -0
- package/dist/client/static/js/diff-r1sqd2db.js +1 -0
- package/dist/client/static/js/dockerfile-d43jt8fq.js +1 -0
- package/dist/client/static/js/dockerfile-k5xbramm.js +1 -0
- package/dist/client/static/js/dracula-k5pe1hsy.js +1 -0
- package/dist/client/static/js/dracula-soft-xqzm7g02.js +1 -0
- package/dist/client/static/js/ebnfDiagram-ZINNZB2B-nwwbasfh.js +1 -0
- package/dist/client/static/js/elixir-rpa1g4gy.js +1 -0
- package/dist/client/static/js/elk-276RUBZZ-xcp7thax.js +2 -0
- package/dist/client/static/js/erDiagram-OPXOYQCR-xj1tp716.js +99 -0
- package/dist/client/static/js/erlang-1ch2hjv9.js +1 -0
- package/dist/client/static/js/erlang-rz1g9mxy.js +1 -0
- package/dist/client/static/js/eventmodeling-NTZA5JFV-srqbnmey.js +1 -0
- package/dist/client/static/js/everforest-dark-v44f35e9.js +1 -0
- package/dist/client/static/js/everforest-light-c7m7g4z4.js +1 -0
- package/dist/client/static/js/flowDiagram-KWPJA3E3-yj98317w.js +1 -0
- package/dist/client/static/js/ganttDiagram-FUAMR5RP-f7q96bea.js +292 -0
- package/dist/client/static/js/ghostty-web-2gt2tp72.js +13 -0
- package/dist/client/static/js/gitGraph-4MIJSDKK-5jcrvn94.js +1 -0
- package/dist/client/static/js/gitGraphDiagram-X574FWY7-1rydkyq9.js +106 -0
- package/dist/client/static/js/github-dark-default-1000qs8y.js +1 -0
- package/dist/client/static/js/github-dark-dimmed-vfghfgh1.js +1 -0
- package/dist/client/static/js/github-dark-fvd3e45k.js +1 -0
- package/dist/client/static/js/github-dark-high-contrast-2j07czxg.js +1 -0
- package/dist/client/static/js/github-light-9r4ahj0m.js +1 -0
- package/dist/client/static/js/github-light-default-6d4nszch.js +1 -0
- package/dist/client/static/js/github-light-high-contrast-qwzscwzg.js +1 -0
- package/dist/client/static/js/go-nfrqbjpq.js +1 -0
- package/dist/client/static/js/go-rtqh5zp3.js +1 -0
- package/dist/client/static/js/graphql-275pg7ya.js +1 -0
- package/dist/client/static/js/groovy-63s5pygd.js +1 -0
- package/dist/client/static/js/groovy-s992001c.js +1 -0
- package/dist/client/static/js/gruvbox-dark-hard-ctttkbm1.js +1 -0
- package/dist/client/static/js/gruvbox-dark-medium-vh8mkpgj.js +1 -0
- package/dist/client/static/js/gruvbox-dark-soft-9f1ph8sj.js +1 -0
- package/dist/client/static/js/gruvbox-light-hard-n3ma2f5b.js +1 -0
- package/dist/client/static/js/gruvbox-light-medium-hkamn7bg.js +1 -0
- package/dist/client/static/js/gruvbox-light-soft-r39t4g97.js +1 -0
- package/dist/client/static/js/haskell-ev7ynt8z.js +1 -0
- package/dist/client/static/js/haskell-phxh4hcg.js +1 -0
- package/dist/client/static/js/hcl-wndsmevr.js +1 -0
- package/dist/client/static/js/horizon-bright-wz5mjtp4.js +1 -0
- package/dist/client/static/js/horizon-pr13gmaz.js +1 -0
- package/dist/client/static/js/houston-mrdq0gj4.js +1 -0
- package/dist/client/static/js/html-pv88ny12.js +1 -0
- package/dist/client/static/js/index-0a1ekhqf.js +2 -0
- package/dist/client/static/js/index-0g25yrc0.js +1 -0
- package/dist/client/static/js/index-0j518hqm.js +2 -0
- package/dist/client/static/js/index-0n9c85ke.js +2 -0
- package/dist/client/static/js/index-123e8tqq.js +2 -0
- package/dist/client/static/js/index-14wppnkx.js +2 -0
- package/dist/client/static/js/index-22jaxtz1.js +2 -0
- package/dist/client/static/js/index-2n5wy1sh.js +1 -0
- package/dist/client/static/js/index-2t2tnc3x.js +1 -0
- package/dist/client/static/js/index-31jrebvn.js +214 -0
- package/dist/client/static/js/index-3anc30zh.js +2 -0
- package/dist/client/static/js/index-52bgxh6f.js +1 -0
- package/dist/client/static/js/index-5zd1jx9r.js +2 -0
- package/dist/client/static/js/index-6sdctwv2.js +2 -0
- package/dist/client/static/js/index-73xfkyea.js +2 -0
- package/dist/client/static/js/index-8a3tmm1h.js +332 -0
- package/dist/client/static/js/index-8m3q2zpb.js +1 -0
- package/dist/client/static/js/index-9nbxb421.js +2 -0
- package/dist/client/static/js/index-a293pdg7.js +2 -0
- package/dist/client/static/js/index-b08zd4eq.js +1 -0
- package/dist/client/static/js/index-c20a46ww.js +2 -0
- package/dist/client/static/js/index-c8jzx6b0.js +2 -0
- package/dist/client/static/js/index-cwaz6geq.js +2 -0
- package/dist/client/static/js/index-deex10rz.js +9 -0
- package/dist/client/static/js/index-e26rd868.js +2 -0
- package/dist/client/static/js/index-e6rar25v.js +2 -0
- package/dist/client/static/js/index-e7a3fkvv.js +1 -0
- package/dist/client/static/js/index-e94a1en0.css +1 -0
- package/dist/client/static/js/index-f519m6s3.js +1 -0
- package/dist/client/static/js/index-f63y3mjj.js +7 -0
- package/dist/client/static/js/index-fc2j6bq2.js +2 -0
- package/dist/client/static/js/index-fmxn1rzs.js +3 -0
- package/dist/client/static/js/index-g0pkzanm.js +2 -0
- package/dist/client/static/js/index-ga2xdef3.js +2 -0
- package/dist/client/static/js/index-ggaqh9rt.js +2 -0
- package/dist/client/static/js/index-gvwqjpcr.js +2 -0
- package/dist/client/static/js/index-h6jxmkxk.js +129 -0
- package/dist/client/static/js/index-hhm62nfj.js +2 -0
- package/dist/client/static/js/index-hkq0y3pn.js +2 -0
- package/dist/client/static/js/index-hyry1n8x.js +2 -0
- package/dist/client/static/js/index-m6wwc5h6.js +2 -0
- package/dist/client/static/js/index-nsrnyqcm.js +2 -0
- package/dist/client/static/js/index-pe9j88d4.js +2 -0
- package/dist/client/static/js/index-pkyrkkbt.js +2 -0
- package/dist/client/static/js/index-qmh0h87h.js +314 -0
- package/dist/client/static/js/index-r416e9dt.js +12 -0
- package/dist/client/static/js/index-s9vp6p70.js +2 -0
- package/dist/client/static/js/index-tr8754r0.js +179 -0
- package/dist/client/static/js/index-vmvcse63.js +1 -0
- package/dist/client/static/js/index-vnvrzwht.js +240 -0
- package/dist/client/static/js/index-vrbcj11n.js +2 -0
- package/dist/client/static/js/index-w4re5r8w.js +2 -0
- package/dist/client/static/js/index-w5131mtt.js +2 -0
- package/dist/client/static/js/index-w7xbfv44.js +2 -0
- package/dist/client/static/js/index-x64kqgen.js +2 -0
- package/dist/client/static/js/index-xa7nrnda.js +2 -0
- package/dist/client/static/js/index-xpf2ra60.js +1 -0
- package/dist/client/static/js/index-xzfsaqyz.js +4 -0
- package/dist/client/static/js/index-y139vc12.js +474 -0
- package/dist/client/static/js/index-ynqnbvn2.js +3 -0
- package/dist/client/static/js/index-yvcpdk5f.js +89 -0
- package/dist/client/static/js/index-zca66d5d.js +3 -0
- package/dist/client/static/js/info-A6RAGUB7-mbt0ryx5.js +1 -0
- package/dist/client/static/js/infoDiagram-VRGFBTTK-ptg07tp2.js +2 -0
- package/dist/client/static/js/ini-jqdrx98c.js +1 -0
- package/dist/client/static/js/ishikawaDiagram-OU5B5YK6-bdk2dkf5.js +70 -0
- package/dist/client/static/js/java-70zqqrkr.js +1 -0
- package/dist/client/static/js/javascript-18thb3jp.js +1 -0
- package/dist/client/static/js/javascript-4kw2j9t3.js +1 -0
- package/dist/client/static/js/journeyDiagram-ZHPQQLJL-kez0ha4c.js +139 -0
- package/dist/client/static/js/json-kxk8gfet.js +1 -0
- package/dist/client/static/js/json5-hmb38a78.js +1 -0
- package/dist/client/static/js/jsx-h1035eqk.js +1 -0
- package/dist/client/static/js/julia-ft9kd90a.js +1 -0
- package/dist/client/static/js/julia-nmr85k8z.js +1 -0
- package/dist/client/static/js/kanagawa-dragon-nya1w1ke.js +1 -0
- package/dist/client/static/js/kanagawa-lotus-hwn4nbn5.js +1 -0
- package/dist/client/static/js/kanagawa-wave-7rsxqd8r.js +1 -0
- package/dist/client/static/js/kanban-definition-PNTS6WVX-dhzp3qg5.js +89 -0
- package/dist/client/static/js/katex-eh1m1m1d.js +257 -0
- package/dist/client/static/js/kotlin-bw3n4j1v.js +1 -0
- package/dist/client/static/js/laserwave-37chepry.js +1 -0
- package/dist/client/static/js/less-w8v48sx0.js +1 -0
- package/dist/client/static/js/light-plus-mcbbmtzj.js +1 -0
- package/dist/client/static/js/lua-6at2ddf6.js +1 -0
- package/dist/client/static/js/lua-j2356waf.js +1 -0
- package/dist/client/static/js/main-rx9grv92.js +7 -0
- package/dist/client/static/js/makefile-22weg265.js +1 -0
- package/dist/client/static/js/markdown-ffw6rgk6.js +1 -0
- package/dist/client/static/js/material-theme-darker-pcm1tb69.js +1 -0
- package/dist/client/static/js/material-theme-lighter-cbdrfj3g.js +1 -0
- package/dist/client/static/js/material-theme-ocean-3rs19bm6.js +1 -0
- package/dist/client/static/js/material-theme-palenight-rxhkgd4c.js +1 -0
- package/dist/client/static/js/material-theme-x46yf0tm.js +1 -0
- package/dist/client/static/js/mermaid.core-h7wttbss.js +12 -0
- package/dist/client/static/js/min-dark-f279fhzv.js +1 -0
- package/dist/client/static/js/min-light-s53yjy4e.js +1 -0
- package/dist/client/static/js/mindmap-definition-NLK3R4M7-tq5dd1em.js +96 -0
- package/dist/client/static/js/mllike-cnahv8ak.js +1 -0
- package/dist/client/static/js/monokai-yr7h8283.js +1 -0
- package/dist/client/static/js/night-owl-8d01zsx4.js +1 -0
- package/dist/client/static/js/night-owl-light-7jbd0p3j.js +1 -0
- package/dist/client/static/js/nix-7e31jz1m.js +1 -0
- package/dist/client/static/js/nord-h1bak1eb.js +1 -0
- package/dist/client/static/js/objective-c-8r3dxert.js +1 -0
- package/dist/client/static/js/ocaml-bpjgcgwa.js +1 -0
- package/dist/client/static/js/one-dark-pro-8acf6cn2.js +1 -0
- package/dist/client/static/js/one-light-ysc1knem.js +1 -0
- package/dist/client/static/js/packet-AYTQ26CC-a5yw789s.js +1 -0
- package/dist/client/static/js/pegDiagram-GJSIUBJH-e5hrdfzv.js +1 -0
- package/dist/client/static/js/perl-3t5fm1te.js +1 -0
- package/dist/client/static/js/perl-prxcva8r.js +1 -0
- package/dist/client/static/js/php-m9kcctzs.js +1 -0
- package/dist/client/static/js/pie-WAS4IAKB-x0y4v4r2.js +1 -0
- package/dist/client/static/js/pieDiagram-5QR66LMP-axvbvnz8.js +39 -0
- package/dist/client/static/js/plastic-8kfqgcmr.js +1 -0
- package/dist/client/static/js/poimandres-rjcckfek.js +1 -0
- package/dist/client/static/js/powershell-m5qb6mjj.js +1 -0
- package/dist/client/static/js/powershell-rrzhqtmb.js +1 -0
- package/dist/client/static/js/properties-55mrarxr.js +1 -0
- package/dist/client/static/js/properties-qq2pcfyk.js +1 -0
- package/dist/client/static/js/protobuf-578974t5.js +1 -0
- package/dist/client/static/js/protobuf-ggczeare.js +1 -0
- package/dist/client/static/js/python-dhypc3j4.js +1 -0
- package/dist/client/static/js/python-wbdfs2gc.js +1 -0
- package/dist/client/static/js/quadrantDiagram-O4NWA36T-wtn28cfm.js +7 -0
- package/dist/client/static/js/r-6b8dt1wp.js +1 -0
- package/dist/client/static/js/r-z4m38eb1.js +1 -0
- package/dist/client/static/js/racket-dhm8rebp.js +1 -0
- package/dist/client/static/js/radar-RG4KPBEZ-trrc3ta1.js +1 -0
- package/dist/client/static/js/railroad-74A4TZTK-dxgvx21w.js +1 -0
- package/dist/client/static/js/railroad-abnf-HS5TGJTU-rbgkd8sk.js +1 -0
- package/dist/client/static/js/railroad-ebnf-LZEXJU2U-exgw7j47.js +1 -0
- package/dist/client/static/js/railroad-peg-WCYAUIDC-28tpamzk.js +1 -0
- package/dist/client/static/js/railroadDiagram-XR7U4H2S-avjkq945.js +1 -0
- package/dist/client/static/js/red-zgbwyj31.js +1 -0
- package/dist/client/static/js/requirementDiagram-PLB6GJNP-bntx7r6q.js +84 -0
- package/dist/client/static/js/rose-pine-azwmazxg.js +1 -0
- package/dist/client/static/js/rose-pine-dawn-3t3j9bnk.js +1 -0
- package/dist/client/static/js/rose-pine-moon-35ecvxkf.js +1 -0
- package/dist/client/static/js/ruby-nq98w40a.js +1 -0
- package/dist/client/static/js/ruby-t06c0e7g.js +1 -0
- package/dist/client/static/js/rust-6gqjxyf0.js +1 -0
- package/dist/client/static/js/rust-psncxtga.js +1 -0
- package/dist/client/static/js/sankeyDiagram-IPEJSGJF-ps8nkdm2.js +40 -0
- package/dist/client/static/js/sass-gsbyn3wh.js +1 -0
- package/dist/client/static/js/sass-k1jjq4y7.js +1 -0
- package/dist/client/static/js/scala-atdk263v.js +1 -0
- package/dist/client/static/js/scheme-181kqjff.js +1 -0
- package/dist/client/static/js/scheme-jvs3e9c8.js +1 -0
- package/dist/client/static/js/scss-zphrqp25.js +1 -0
- package/dist/client/static/js/sequenceDiagram-PO4LG4MO-3ckf1q6z.js +169 -0
- package/dist/client/static/js/shell-5rhwzbr3.js +1 -0
- package/dist/client/static/js/sizeCapture-INFHLROL-akvcr1x7.js +1 -0
- package/dist/client/static/js/slack-dark-j9p83tbc.js +1 -0
- package/dist/client/static/js/slack-ochin-fe90gs3m.js +1 -0
- package/dist/client/static/js/snazzy-light-pj44bwcm.js +1 -0
- package/dist/client/static/js/solarized-dark-54jyr51c.js +1 -0
- package/dist/client/static/js/solarized-light-ca8r58m6.js +1 -0
- package/dist/client/static/js/solidity-bx92jb30.js +1 -0
- package/dist/client/static/js/sql-9dq913c8.js +1 -0
- package/dist/client/static/js/sql-wsvbkyd1.js +1 -0
- package/dist/client/static/js/stateDiagram-v2-GCMORJYK-c82914fz.js +291 -0
- package/dist/client/static/js/stylus-fht9fjbw.js +1 -0
- package/dist/client/static/js/stylus-xh0f7m9m.js +1 -0
- package/dist/client/static/js/svelte-j54gfrvq.js +1 -0
- package/dist/client/static/js/swift-0rtnm3tm.js +1 -0
- package/dist/client/static/js/swift-rr9wc5y7.js +1 -0
- package/dist/client/static/js/swimlanes-2SLR337P-scgdefh4.js +1 -0
- package/dist/client/static/js/swimlanesDiagram-TC7HE7FX-0x2ashav.js +8 -0
- package/dist/client/static/js/synthwave-84-yq047vcq.js +1 -0
- package/dist/client/static/js/timeline-definition-EJHVYXUP-z2ha1rhq.js +120 -0
- package/dist/client/static/js/tokyo-night-jfy87bj1.js +1 -0
- package/dist/client/static/js/toml-b5g7qp6k.js +1 -0
- package/dist/client/static/js/toml-prjdc335.js +1 -0
- package/dist/client/static/js/treeView-Q6P3EWNA-1a00b6kc.js +1 -0
- package/dist/client/static/js/treemap-WGGIJYW6-2q4f2f7m.js +1 -0
- package/dist/client/static/js/tsx-wh5xgm7f.js +1 -0
- package/dist/client/static/js/typescript-ge85req5.js +1 -0
- package/dist/client/static/js/usecaseDiagram-POWQR4AR-3wdmrfmk.js +370 -0
- package/dist/client/static/js/vennDiagram-UO4OBE2U-7m5tatzv.js +34 -0
- package/dist/client/static/js/vesper-0e7jx631.js +1 -0
- package/dist/client/static/js/vitesse-black-avx6j9e8.js +1 -0
- package/dist/client/static/js/vitesse-dark-5ypr9e1f.js +1 -0
- package/dist/client/static/js/vitesse-light-sze15mny.js +1 -0
- package/dist/client/static/js/vue-y8bb5f3h.js +1 -0
- package/dist/client/static/js/wardley-WFR3VGLG-x9v91the.js +1 -0
- package/dist/client/static/js/wardleyDiagram-VNRHLVJA-55ps9s4z.js +78 -0
- package/dist/client/static/js/xml-7bgz40qa.js +1 -0
- package/dist/client/static/js/xml-f6syr877.js +1 -0
- package/dist/client/static/js/xychartDiagram-PMCCYNJV-8bsjtm4t.js +7 -0
- package/dist/client/static/js/yaml-4ht9416k.js +1 -0
- package/dist/client/static/js/yaml-qwwswzvs.js +1 -0
- package/dist/client/static/js/zig-yf26r6vn.js +1 -0
- package/package.json +5 -2
- package/src/client/App.tsx +16 -0
- package/src/client/components/common/anchored-menu/index.test.tsx +3 -3
- package/src/client/components/common/anchored-menu/index.tsx +10 -16
- package/src/client/components/common/command-palette/ChordHint.tsx +36 -0
- package/src/client/components/common/command-palette/index.test.tsx +126 -0
- package/src/client/components/common/command-palette/index.tsx +216 -0
- package/src/client/components/common/context-usage-button/index.tsx +26 -17
- package/src/client/components/common/key-binding-cheatsheet/index.tsx +147 -0
- package/src/client/components/common/server-control/Panel.tsx +8 -9
- package/src/client/components/common/session-actions-menu/index.test.tsx +26 -0
- package/src/client/components/common/session-actions-menu/index.tsx +19 -15
- package/src/client/components/common/session-row/RunElapsed.tsx +50 -0
- package/src/client/components/common/session-row/TimeCell.tsx +38 -0
- package/src/client/components/common/session-row/TrailingSlot.tsx +26 -12
- package/src/client/components/common/session-row/index.tsx +5 -0
- package/src/client/components/common/session-row/session-row.test.tsx +26 -1
- package/src/client/components/layout/desktop-layout/LeftColumn.tsx +2 -0
- package/src/client/components/layout/desktop-layout/index.tsx +2 -2
- package/src/client/components/layout/session-sidebar/CategoryItem.tsx +2 -1
- package/src/client/components/layout/session-sidebar/Footer.tsx +13 -2
- package/src/client/components/layout/session-sidebar/SessionItem.test.ts +17 -0
- package/src/client/components/layout/session-sidebar/SessionItem.tsx +13 -7
- package/src/client/components/layout/session-sidebar/modern/WorkspaceSection.tsx +2 -1
- package/src/client/components/mobile/SessionSidebar.tsx +2 -0
- package/src/client/components/mobile/mobile-main-view/Header.test.tsx +122 -0
- package/src/client/components/mobile/mobile-main-view/Header.tsx +25 -26
- package/src/client/components/mobile/mobile-session-sidebar/Footer.tsx +11 -1
- package/src/client/components/mobile/mobile-session-sidebar/Item.tsx +2 -1
- package/src/client/components/mobile/mobile-session-sidebar/SessionRow.tsx +10 -5
- package/src/client/components/settings/Modal.tsx +3 -0
- package/src/client/components/settings/Sidebar.tsx +3 -2
- package/src/client/components/settings/categories/ChatSettings.test.tsx +2 -2
- package/src/client/components/settings/categories/ChatSettings.tsx +0 -2
- package/src/client/components/settings/categories/KeyboardSettings.tsx +31 -0
- package/src/client/components/settings/categories/NotificationSettings.tsx +9 -0
- package/src/client/components/settings/categories/SkillCatalogSettings.tsx +34 -16
- package/src/client/components/settings/categories/SkillSettings.tsx +22 -1
- package/src/client/components/settings/categories/chat-settings/groups.ts +2 -11
- package/src/client/components/settings/categories/{chat-settings/KeybindingsSection.tsx → keyboard-settings/ComposerKeys.tsx} +2 -2
- package/src/client/components/settings/categories/keyboard-settings/KeyRecorder.tsx +106 -0
- package/src/client/components/settings/categories/keyboard-settings/ShortcutTable.tsx +137 -0
- package/src/client/components/settings/categories/skill-catalog/GitImportPanel.tsx +13 -41
- package/src/client/components/settings/categories/skill-catalog/SkillCard.tsx +1 -1
- package/src/client/components/settings/categories/skill-catalog/catalog-ui.test.tsx +3 -6
- package/src/client/components/settings/categories/skill-settings/DetailHeader.tsx +43 -2
- package/src/client/components/settings/categories/skill-settings/DetailPane.tsx +9 -0
- package/src/client/components/settings/categories/skill-settings/pane.test.tsx +28 -0
- package/src/client/components/settings/categories/skill-settings/row-meta.ts +3 -0
- package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.tsx +38 -5
- package/src/client/components/workspace/chat-timeline/chat-input/AttachmentToolbar.wait.test.tsx +158 -0
- package/src/client/components/workspace/chat-timeline/chat-input/ComposerRows.tsx +1 -1
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.test.ts +28 -33
- package/src/client/components/workspace/chat-timeline/chat-input/Toolbar.tsx +24 -67
- package/src/client/components/workspace/chat-timeline/chat-input/WaitingDependencyPicker.search.test.tsx +4 -2
- package/src/client/components/workspace/chat-timeline/chat-input/WaitingDependencyPicker.tsx +101 -78
- package/src/client/components/workspace/chat-timeline/chat-input/props.ts +3 -3
- package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Eval.test.tsx +20 -0
- package/src/client/components/workspace/chat-timeline/tool-renderers/panels/Eval.tsx +5 -0
- package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolScreenshots.test.tsx +113 -0
- package/src/client/components/workspace/chat-timeline/tool-renderers/shared/ToolScreenshots.tsx +198 -0
- package/src/client/components/workspace/editor/Body.tsx +0 -15
- package/src/client/components/workspace/editor/FileDocument.tsx +0 -26
- package/src/client/components/workspace/editor/FilePane.tsx +0 -15
- package/src/client/components/workspace/editor/Pane.tsx +4 -1
- package/src/client/components/workspace/editor/index.tsx +5 -8
- package/src/client/hooks/chat/omp/session-list.test.ts +13 -0
- package/src/client/hooks/chat/omp/session-list.tsx +33 -8
- package/src/client/hooks/chat/waiting/composer-wait.ts +2 -2
- package/src/client/hooks/commands/use-command-catalog.ts +52 -0
- package/src/client/hooks/commands/use-command-context.ts +21 -0
- package/src/client/hooks/commands/use-command-runtime.test.ts +117 -0
- package/src/client/hooks/commands/use-command-runtime.ts +62 -0
- package/src/client/hooks/commands/use-overlays.ts +35 -0
- package/src/client/hooks/commands/use-palette-items.ts +156 -0
- package/src/client/hooks/commands/use-plugin-commands.ts +69 -0
- package/src/client/hooks/editor/find-harness.test-util.ts +20 -3
- package/src/client/hooks/editor/use-editor-command-target.ts +46 -0
- package/src/client/hooks/editor/use-editor-find.test.ts +4 -9
- package/src/client/hooks/editor/use-editor-panel-keys.ts +24 -93
- package/src/client/hooks/editor/use-editor-panel-ui.ts +0 -10
- package/src/client/hooks/settings/skill-catalog.ts +3 -3
- package/src/client/hooks/settings/skill-git-import.ts +3 -11
- package/src/client/hooks/ui/icon-style.ts +10 -5
- package/src/client/hooks/ui/notification-events.test.ts +126 -0
- package/src/client/hooks/ui/notification-events.ts +61 -0
- package/src/client/hooks/ui/second-tick.ts +55 -0
- package/src/client/hooks/ui/theme.ts +9 -5
- package/src/client/hooks/workspace/commands.ts +51 -0
- package/src/client/lib/commands/context.ts +51 -0
- package/src/client/lib/commands/dispatcher.ts +101 -0
- package/src/client/lib/commands/editor-target.ts +36 -0
- package/src/client/lib/commands/keymap.test.ts +68 -0
- package/src/client/lib/commands/keymap.ts +151 -0
- package/src/client/lib/commands/overlays.ts +87 -0
- package/src/client/lib/commands/registry.ts +69 -0
- package/src/client/lib/notifications/os.test.ts +24 -0
- package/src/client/lib/notifications/os.ts +16 -0
- package/src/client/lib/notifications/watch.ts +48 -0
- package/src/client/lib/plugins/slots.ts +1 -0
- package/src/client/main.tsx +7 -0
- package/src/client/tailwind.css +5 -38
- package/src/server/db.server.test.ts +10 -4
- package/src/server/index.ts +12 -8
- package/src/server/lib/assets/theme-css.server.test.ts +58 -0
- package/src/server/lib/assets/theme-css.server.ts +52 -0
- package/src/server/lib/auth/guard.ts +6 -1
- package/src/server/lib/browser/runtime.test.ts +21 -16
- package/src/server/lib/db/client.test.ts +89 -0
- package/src/server/lib/db/client.ts +31 -0
- package/src/server/lib/db/compact-chat-overlay.ts +7 -1
- package/src/server/lib/db/schema.ts +4 -0
- package/src/server/lib/db/workspace-sync.ts +7 -7
- package/src/server/lib/harness/acp/session-permissions.ts +4 -0
- package/src/server/lib/lifecycle/fd-pressure.test.ts +43 -0
- package/src/server/lib/lifecycle/fd-pressure.ts +38 -0
- package/src/server/lib/lifecycle/listener.ts +4 -4
- package/src/server/lib/lifecycle/shell-entry.server.ts +29 -0
- package/src/server/lib/lifecycle/shell-route.ts +5 -4
- package/src/server/lib/notifications/feed.server.test.ts +127 -0
- package/src/server/lib/notifications/feed.server.ts +195 -0
- package/src/server/lib/notifications/schema.server.ts +47 -0
- package/src/server/lib/notifications/store.server.test.ts +118 -0
- package/src/server/lib/notifications/store.server.ts +103 -0
- package/src/server/lib/observer-ws.test.ts +49 -0
- package/src/server/lib/observer-ws.ts +2 -1
- package/src/server/lib/omp/config/definitions.test.ts +17 -18
- package/src/server/lib/omp/config/skills-catalog.ts +109 -73
- package/src/server/lib/omp/config/skills-git-repo.ts +10 -12
- package/src/server/lib/omp/rpc/frame-fold-frames.test.ts +2 -0
- package/src/server/lib/omp/rpc/manager.ts +4 -1
- package/src/server/lib/omp/rpc/run-model.test.ts +2 -0
- package/src/server/lib/omp/session/sidebar-data.server.ts +1 -0
- package/src/server/lib/realtime/hub.server.test.ts +27 -1
- package/src/server/lib/realtime/hub.server.ts +6 -2
- package/src/server/lib/realtime/hub.types.ts +9 -1
- package/src/server/lib/realtime/topics/catalog.server.ts +5 -0
- package/src/server/lib/realtime/topics/peer-relay.server.test.ts +27 -14
- package/src/server/lib/realtime/topics.server.test.ts +2 -1
- package/src/server/plugins/shell.server.test.ts +4 -4
- package/src/server/plugins/shell.server.ts +83 -22
- package/src/server/plugins/ssr.ts +13 -11
- package/src/server/plugins/static.ts +5 -7
- package/src/server/routes/health/probe.ts +7 -8
- package/src/server/routes/index.ts +2 -0
- package/src/server/routes/notifications/index.ts +6 -0
- package/src/server/routes/notifications/stream.test.ts +116 -0
- package/src/server/routes/notifications/stream.ts +88 -0
- package/src/server/routes/settings/skills-catalog-actions.ts +11 -31
- package/src/server/routes/settings/skills.test.ts +14 -0
- package/src/server/routes/settings/skills.ts +29 -21
- package/src/shared/lib/code/highlight-cache.test.ts +19 -8
- package/src/shared/lib/commands/catalog.ts +114 -0
- package/src/shared/lib/commands/chord.test.ts +66 -0
- package/src/shared/lib/commands/chord.ts +193 -0
- package/src/shared/lib/commands/conflicts.test.ts +43 -0
- package/src/shared/lib/commands/conflicts.ts +53 -0
- package/src/shared/lib/commands/record.test.ts +24 -0
- package/src/shared/lib/commands/record.ts +44 -0
- package/src/shared/lib/commands/resolve.test.ts +54 -0
- package/src/shared/lib/commands/resolve.ts +45 -0
- package/src/shared/lib/commands/score.test.ts +41 -0
- package/src/shared/lib/commands/score.ts +53 -0
- package/src/shared/lib/commands/types.ts +60 -0
- package/src/shared/lib/commands/user-keybindings.test.ts +33 -0
- package/src/shared/lib/commands/user-keybindings.ts +64 -0
- package/src/shared/lib/commands/when.test.ts +46 -0
- package/src/shared/lib/commands/when.ts +221 -0
- package/src/shared/lib/icons/icon-paint-authority.test.ts +9 -0
- package/src/shared/lib/icons/icon-paint-authority.ts +25 -8
- package/src/shared/lib/notifications/events.test.ts +77 -0
- package/src/shared/lib/notifications/events.ts +104 -0
- package/src/shared/lib/omp/session/prewarm-misc.test.ts +3 -2
- package/src/shared/lib/omp/session/schema-migrations.ts +4 -0
- package/src/shared/lib/omp/session/stream-state.server.test.ts +37 -1
- package/src/shared/lib/omp/session/stream-state.server.ts +42 -5
- package/src/shared/lib/omp/skill-source.test.ts +24 -0
- package/src/shared/lib/omp/skill-source.ts +20 -0
- package/src/shared/lib/panels/slot-labels.ts +6 -1
- package/src/shared/lib/realtime/protocol.ts +11 -0
- package/src/shared/lib/theme/css.ts +11 -0
- package/src/shared/lib/ui/menu-anchor.test.ts +17 -5
- package/src/shared/lib/ui/menu-anchor.ts +22 -5
- package/src/shared/lib/workspace/refresh-cadence.test.ts +34 -1
- package/src/shared/lib/workspace/relative-time.ts +22 -0
- package/src/shared/types/realtime.ts +10 -0
- package/src/shared/types/settings/skill.ts +1 -9
- package/src/shared/types/settings/state.ts +1 -0
- package/src/shared/types/workspace.ts +5 -0
- package/src/test-support/peer-harness.ts +32 -6
- package/dist/client/static/js/index-naa91727.css +0 -1
- package/dist/client/static/js/index-r3bhgvkt.js +0 -5696
- package/src/client/components/workspace/editor/CommandPalette.test.ts +0 -242
- package/src/client/components/workspace/editor/CommandPalette.tsx +0 -138
- package/src/client/components/workspace/editor/QuickOpenModal.tsx +0 -146
- package/src/client/hooks/ui/input-required-alert.ts +0 -50
- package/src/client/hooks/ui/notifications.ts +0 -54
- package/src/client/hooks/ui/run-outcome-alert.ts +0 -48
- package/src/client/hooks/ui/ui-alert.test.ts +0 -235
- package/src/client/hooks/workspace/keybindings.ts +0 -44
- package/src/shared/lib/notifications/outcomes.test.ts +0 -96
- package/src/shared/lib/notifications/outcomes.ts +0 -64
- package/src/shared/lib/ui/mobile-overlay.ts +0 -61
|
@@ -0,0 +1,200 @@
|
|
|
1
|
+
import{t,l,ot,ra,x,R,M,O,P,z,j,G,p,aa,Eo,h,tr,nr,H,fn,st,Ye,Je,zn,Pl,It,_t,xn,St,lt}from"./index-qmh0h87h.js";import{Qt}from"./index-y139vc12.js";import{Na}from"./index-pe9j88d4.js";var bt={SHAPE_UNSUPPORTED:"SHAPE_UNSUPPORTED",SHAPE_REMOVED:"SHAPE_REMOVED",EDGE_OPERATOR_UNSUPPORTED:"EDGE_OPERATOR_UNSUPPORTED",REFERENCE_EDGE_LABEL_REJECTED:"REFERENCE_EDGE_LABEL_REJECTED",CONNECTOR_REF_UNRESOLVED:"CONNECTOR_REF_UNRESOLVED",CONNECTOR_REF_NOT_A_CONNECTOR:"CONNECTOR_REF_NOT_A_CONNECTOR",METADATA_KEY_MISAPPLIED:"METADATA_KEY_MISAPPLIED",DUPLICATE_ID_NODE:"DUPLICATE_ID_NODE",RESERVED_SYNTHETIC_ID:"RESERVED_SYNTHETIC_ID",CONTAINMENT_VIOLATION:"CONTAINMENT_VIOLATION",EDGE_SEMANTIC_CONTRADICTION:"EDGE_SEMANTIC_CONTRADICTION",FLOW_NO_INPUT:"FLOW_NO_INPUT"},y1=new Set([bt.SHAPE_UNSUPPORTED,bt.SHAPE_REMOVED,bt.CONTAINMENT_VIOLATION]),ms=new Set(Object.values(bt).filter((e)=>!y1.has(e))),w1=new Map([["task","roundedRect"],["tool","subroutine"],["input","lean-right"],["decision","diamond"],["refdoc","lin-doc"],["action","hexagon"],["round","rect"]]),N1=new Set(["doc","stadium","terminal","circle","trapezoid","inv_trapezoid","inv-trapezoid","doublecircle","double-circle","typeDeclaration","procs","lean_left","lean-left","in-out","cylinder","ellipse","odd","tag-rect","tagged-rectangle","delay","half-rounded-rectangle","lin-rect","lined-rectangle","win-pane","window-pane","curv-trap","curved-trapezoid"]),R1=new Set(["roundedRect","subroutine","subprocess","subproc","framed-rectangle","lean-right","diamond","lin-doc","lined-document","hexagon","hex","connector","collapsedGroup"]),ft="roundedRect";function gt(e){if(!e)return e;return w1.get(e)??e}t(gt,"resolveShapeAlias");function E1(e,r){for(let n of e){if(n.isGroup)continue;if(!n.shape||n.shape==="squareRect"||n.shape==="rect")n.shape=ft;if(N1.has(n.shape)){let a=`shape "${n.shape}" was removed in v0.8.1, using "${ft}"`;if(r?.emitError)r.emitError("SHAPE_REMOVED",a,{nodeId:n.id});else l.warn(`agentflow: ${a}`);n.shape=ft;continue}if(!R1.has(n.shape)){let a=`shape "${n.shape}" is not supported, using "${ft}"`;if(r?.emitWarning)r.emitWarning("SHAPE_UNSUPPORTED",a,{nodeId:n.id});else l.warn(`agentflow: ${a}`);n.shape=ft}}}t(E1,"normaliseNodeShapes");var Xt=new Map([["tool",0],["task",1],["decision",2],["input",3],["refdoc",4],["connector",5],["action",6]]),C1=Xt.size,S1=t((e)=>`af-kind-${e}`,"kindClass"),O1=[...Xt.keys()],x1=t((e)=>Math.max(1,e-C1),"containerSlotCount"),T1=t((e,r)=>{let n=C1+e%x1(r);return r>0?n%r:n},"containerSlot");function D1(e,r,n){let a=p().themeVariables?.borderColorArray,c=Array.isArray(a)?a.length:0,d=n.size;for(let o of e??[]){if(o.isGroup||o.shape==="collapsedGroup"){let m=n.get(String(o.id))??d++;o.colorIndex=T1(m,c);continue}let f=r(String(o.id));if(f&&Xt.has(f))o.cssClasses=`${o.cssClasses??""} ${S1(f)}`.replace(/\s+/g," ").trim()}}t(D1,"assignColorSlots");var A1="agentflow-",i1=new Set(["shape","view","icon","img","form","pos","w","h","class","style","labelType"]),P1=new Set(["subroutine","subprocess","subproc","framed-rectangle","tool"]),G1={flow:"flowGroup"};function qt(e){if(Array.isArray(e))return e.map((n)=>qt(n));if(e===null||typeof e!=="object")return e;let r={};for(let n of Object.keys(e)){if(n==="__proto__"||n==="constructor"||n==="prototype")continue;r[n]=qt(e[n])}return r}t(qt,"stripPrototypeKeys");function _1(e){let r=!1,n=!1,a=0,c,d=[];for(let o of e.split(`
|
|
2
|
+
`)){if(c!==void 0){let A=o.length-o.trimStart().length;if(o.trim()===""||A>c){d.push(o);continue}c=void 0}let f=-1;for(let A=0;A<o.length;A++){let C=o[A];if(n){if(C==="\\")A++;else if(C==='"')n=!1}else if(r){if(C==="'")r=!1}else if(C==='"')n=!0;else if(C==="'")r=!0;else if(C==="#"&&(A===0||o[A-1]===" "||o[A-1]==="\t")){f=A;break}else if(C==="["||C==="{")a++;else if(C==="]"||C==="}")a=Math.max(0,a-1)}if(r||n||a>0){d.push(o);continue}let m=f>=0?o.slice(0,f):o,k=f>=0?o.slice(f):"";if(/:\s*[>|][\d+-]*\s*$/.test(m)){c=o.length-o.trimStart().length,d.push(o);continue}d.push(m.replace(/,([\t ]*)$/,"$1")+k)}return d.join(`
|
|
3
|
+
`)}t(_1,"stripLineTrailingCommas");var U1=class{constructor(){this.vertexCounter=0,this.config=p(),this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.diagramId="",this.preserveCommentsWhenParsing=!0,this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,this.funs=[],this.setAccTitle=M,this.setAccDescription=P,this.setDiagramTitle=j,this.getAccTitle=O,this.getAccDescription=z,this.getDiagramTitle=G,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addGlobal=this.addGlobal.bind(this),this.addConnector=this.addConnector.bind(this),this.addConnectorMapping=this.addConnectorMapping.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.setFrontmatterLineOffset=this.setFrontmatterLineOffset.bind(this),this.addVertexMapping=this.addVertexMapping.bind(this),this.extendVertexMapping=this.extendVertexMapping.bind(this),this.addEdgeMapping=this.addEdgeMapping.bind(this),this.addSubgraphMapping=this.addSubgraphMapping.bind(this),this.emitWarning=this.emitWarning.bind(this),this.emitError=this.emitError.bind(this),this.getDiagnostics=this.getDiagnostics.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}static{t(this,"AgentFlowDB")}sanitizeText(e){return x.sanitizeText(e,this.config)}sanitizeNodeLabelType(e){switch(e){case"markdown":case"string":case"text":return e;default:return"markdown"}}setDiagramId(e){this.diagramId=e}lookUpDomId(e){for(let r of this.vertices.values())if(r.id===e)return this.diagramId?`${this.diagramId}-${r.domId}`:r.domId;return this.diagramId?`${this.diagramId}-${e}`:e}addVertex(e,r,n,a,c,d,o={},f,m){if(!e||e.trim().length===0)return;let k;if(f!==void 0){let E;if(!f.includes(`
|
|
4
|
+
`))E=`{
|
|
5
|
+
`+f+`
|
|
6
|
+
}`;else E=f+`
|
|
7
|
+
`;try{k=nr(E,{schema:tr})??{}}catch(g){let b=f.includes(`
|
|
8
|
+
`)?_1(f):f;if(b!==f)try{k=nr(b+`
|
|
9
|
+
`,{schema:tr})??{}}catch{this.rethrowMetadataYamlError(g,f,m)}else this.rethrowMetadataYamlError(g,f,m)}k=qt(k)}let A;if(k&&typeof k.shape==="string"){let E=k;A=E.shape;let g=gt(A);if(g&&g!==A)E.shape=g}let C=this.subGraphLookup.get(e);if(C&&k){C.metadata={...C.metadata,...k};return}let L=this.connectors.get(e);if(L&&k){L.metadata={...L.metadata,...k};return}if(e==="connectors")return;let _=this.edges.find((E)=>E.id===e);if(_){let E=k;if(E?.animate!==void 0)_.animate=E.animate;if(E?.animation!==void 0)_.animation=E.animation;if(E?.curve!==void 0)_.interpolate=E.curve;if(k)_.metadata={..._.metadata,...k};return}let U,F=this.vertices.get(e);if(F===void 0)F={id:e,labelType:"text",domId:A1+e+"-"+this.vertexCounter,styles:[],classes:[]},this.vertices.set(e,F);if(this.vertexCounter++,r!==void 0){if(this.config=p(),U=this.sanitizeText(r.text.trim()),F.labelType=r.type,U.startsWith('"')&&U.endsWith('"'))U=U.substring(1,U.length-1);F.text=U}else if(F.text===void 0)F.text=e;if(n!==void 0)F.type=n;if(a!==void 0&&a!==null)a.forEach((E)=>{F.styles.push(E)});if(c!==void 0&&c!==null)c.forEach((E)=>{F.classes.push(E)});if(d!==void 0)F.dir=d;if(F.props===void 0)F.props=o;else if(o!==void 0)Object.assign(F.props,o);if(k){if(F.metadata={...F.metadata,...k},k.shape){let E=A??k.shape;if(typeof E!=="string")throw this.positionedShapeError(`No such shape: ${JSON.stringify(E)}.`,m);if(E!==E.toLowerCase()||E.includes("_"))throw this.positionedShapeError(`No such shape: ${E}. Shape names should be lowercase.`,m);else if(!Pl(k.shape))throw this.positionedShapeError(`No such shape: ${k.shape}.`,m);F.type=k?.shape}if(k?.label)F.text=this.sanitizeText(k.label),F.labelType=this.sanitizeNodeLabelType(k?.labelType)}}positionedShapeError(e,r){let n=Error(e);if(!r)return n;let a=r.first_line+this.frontmatterLineOffset;return Object.assign(n,{hash:{text:"",token:null,line:a-1,loc:{first_line:a,last_line:r.last_line+this.frontmatterLineOffset,first_column:r.first_column,last_column:r.last_column},expected:[]}}),n}rethrowMetadataYamlError(e,r,n){let a=e;if(!a||a.name!=="YAMLException"||!a.mark||!n)throw e;let c;try{let d=!r.includes(`
|
|
10
|
+
`),o=d?`{
|
|
11
|
+
`+r+`
|
|
12
|
+
}`:r+`
|
|
13
|
+
`,f=n.first_line+this.frontmatterLineOffset,m=n.first_column+2,k=t((E,g)=>{if(d)return{line:f,column:m+(E===1?g:0)};return{line:f+E,column:E===0?m+g:g}},"toSource"),A=k(a.mark.line,a.mark.column),C=a.reason??(a.message??"").split(`
|
|
14
|
+
`)[0].replace(/\s*\(\d+:\d+\)\s*$/,""),L=o.split(`
|
|
15
|
+
`),_=[];if(d)_.push(1);else for(let E=a.mark.line-1;E<=a.mark.line+1;E++){if(E<0||E>=L.length)continue;if(E===L.length-1&&L[E]===""&&E!==a.mark.line)continue;_.push(E)}let U=Math.max(..._.map((E)=>String(k(E,0).line).length)),F=[];for(let E of _){let g=k(E,0).line,b=` ${String(g).padStart(U)} | `;if(F.push(b+L[E].replace(/\t/g,"→")),E===a.mark.line)F.push("-".repeat(b.length+a.mark.column)+"^")}c={message:`${C} (${A.line}:${A.column+1})
|
|
16
|
+
|
|
17
|
+
${F.join(`
|
|
18
|
+
`)}`,markLine:A.line-1,markColumn:A.column,hash:{text:"",token:null,line:A.line-1,loc:{first_line:A.line,last_line:A.line,first_column:A.column,last_column:A.column+1},expected:[]}}}catch{}if(c)a.message=c.message,a.mark.line=c.markLine,a.mark.column=c.markColumn,a.hash=c.hash;throw a}addSingleLink(e,r,n,a){let o={start:e,end:r,type:void 0,text:"",labelType:"text",classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};l.info("abc78 Got edge...",o);let f=n.text;if(f!==void 0){if(o.text=this.sanitizeText(f.text.trim()),o.text.startsWith('"')&&o.text.endsWith('"'))o.text=o.text.substring(1,o.text.length-1);o.labelType=this.sanitizeNodeLabelType(f.type)}if(n!==void 0){if(o.type=n.type,o.stroke=n.stroke,o.length=n.length>10?10:n.length,n.edgeSemantic)o.edgeSemantic=n.edgeSemantic}if(a&&!this.edges.some((m)=>m.id===a))o.id=a,o.isUserDefinedId=!0;else{let m=this.edges.filter((k)=>k.start===o.start&&k.end===o.end);if(m.length===0)o.id=fn(o.start,o.end,{counter:0,prefix:"L"});else o.id=fn(o.start,o.end,{counter:m.length+1,prefix:"L"})}if(this.edges.length<(this.config.maxEdges??500))l.info("Pushing edge..."),this.edges.push(o);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}.
|
|
19
|
+
|
|
20
|
+
Initialize mermaid with maxEdges set to a higher number to allow more edges.
|
|
21
|
+
You cannot set this config via configuration inside the diagram as it is a secure config.
|
|
22
|
+
You have to call mermaid.initialize.`)}isLinkData(e){return e!==null&&typeof e==="object"&&"id"in e&&typeof e.id==="string"}addLink(e,r,n){let a=this.isLinkData(n)?n.id.replace("@",""):void 0;l.info("addLink",e,r,a);for(let c of e)for(let d of r){let o=c===e[e.length-1],f=d===r[0];if(o&&f)this.addSingleLink(c,d,n,a);else this.addSingleLink(c,d,n,void 0)}}updateLinkInterpolate(e,r){e.forEach((n)=>{if(n==="default"){this.edges.defaultInterpolate=r;return}if(typeof n==="number"&&n>=this.edges.length)throw Error(`The index ${n} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);this.edges[n].interpolate=r})}updateLink(e,r){e.forEach((n)=>{if(typeof n==="number"&&n>=this.edges.length)throw Error(`The index ${n} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);if(n==="default")this.edges.defaultStyle=r;else if(this.edges[n].style=r,(this.edges[n]?.style?.length??0)>0&&!this.edges[n]?.style?.some((a)=>a?.startsWith("fill")))this.edges[n]?.style?.push("fill:none")})}addClass(e,r){let n=r.join().replace(/\\,/g,"§§§").replace(/,/g,";").replace(/§§§/g,",").split(";");e.split(",").forEach((a)=>{let c=this.classes.get(a);if(c===void 0)c={id:a,styles:[],textStyles:[]},this.classes.set(a,c);if(n!==void 0&&n!==null)n.forEach((d)=>{if(/color/.exec(d)){let o=d.replace("fill","bgFill");c.textStyles.push(o)}c.styles.push(d)})})}setDirection(e){if(this.direction=e.trim(),/.*</.exec(this.direction))this.direction="RL";if(/.*\^/.exec(this.direction))this.direction="BT";if(/.*>/.exec(this.direction))this.direction="LR";if(/.*v/.exec(this.direction))this.direction="TB";if(this.direction==="TD")this.direction="TB"}setClass(e,r){for(let n of e.split(",")){let a=this.vertices.get(n);if(a)a.classes.push(r);let c=this.edges.find((o)=>o.id===n);if(c)c.classes.push(r);let d=this.subGraphLookup.get(n);if(d)d.classes.push(r)}}setTooltip(e,r){if(r===void 0)return;r=this.sanitizeText(r);for(let n of e.split(","))this.tooltips.set(this.version==="gen-1"?this.lookUpDomId(n):n,r)}setClickFun(e,r,n){if(p().securityLevel!=="loose")return;if(r===void 0)return;let a=[];if(typeof n==="string"){a=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let d=0;d<a.length;d++){let o=a[d].trim();if(o.startsWith('"')&&o.endsWith('"'))o=o.substr(1,o.length-2);a[d]=o}}if(a.length===0)a.push(e);let c=this.vertices.get(e);if(c)c.haveCallback=!0,this.funs.push(()=>{let d=this.lookUpDomId(e),o=document.querySelector(`[id="${d}"]`);if(o!==null)o.addEventListener("click",()=>{H.runFunc(r,...a)},!1)})}setLink(e,r,n){e.split(",").forEach((a)=>{let c=this.vertices.get(a);if(c!==void 0)c.link=H.formatUrl(r,this.config),c.linkTarget=n}),this.setClass(e,"clickable")}getTooltip(e){return this.tooltips.get(e)}setClickEvent(e,r,n){e.split(",").forEach((a)=>{this.setClickFun(a,r,n)}),this.setClass(e,"clickable")}bindFunctions(e){this.funs.forEach((r)=>{r(e)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}isToolDefinition(e){return P1.has(e.type)}getTools(){let e=[];for(let r of this.vertices.values())if(this.isToolDefinition(r))e.push(r);return e}getClasses(){return this.classes}setupToolTips(e){let r=Na();h(e).select("svg").selectAll("g.node").on("mouseover",(c)=>{let d=h(c.currentTarget),o=d.attr("title");if(o===null)return;let f=c.currentTarget?.getBoundingClientRect();r.transition().duration(200).style("opacity",".9"),r.text(d.attr("title")).style("left",window.scrollX+f.left+(f.right-f.left)/2+"px").style("top",window.scrollY+f.bottom+"px"),r.html(Qt.sanitize(o)),d.classed("hover",!0)}).on("mouseout",(c)=>{r.transition().duration(500).style("opacity",0),h(c.currentTarget).classed("hover",!1)})}clear(e="gen-2"){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.subGraphs=[],this.subGraphLookup=new Map,this.globalNodes=new Set,this.connectors=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=e,this.config=p(),this.diagramId="",this.vertexCounter=0,this.direction=void 0,this.secCount=-1,this.posCrossRef=[],this.frontmatterLineOffset=0,this.elementMappings=[],this.bareVertexMappings=new WeakSet,this.diagnostics=[],this.postParseValidationRun=!1,R()}setGen(e){this.version=e||"gen-2"}defaultStyle(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"}addSubGraph(e,r,n,a){let c=e?.text?.trim(),d=n?.text;if(e===n&&n?.text&&/\s/.exec(n.text))c=void 0;let f=t((_)=>{let U={boolean:{},number:{},string:{}},F=[],E;return{nodeList:_.filter(function(b){let v=typeof b;if(b.stmt&&b.stmt==="dir")return E=b.value,!1;if(b.trim()==="")return!1;if(v in U)return U[v].hasOwnProperty(b)?!1:U[v][b]=!0;else return F.includes(b)?!1:F.push(b)}),dir:E}},"uniq")(r.flat()),{nodeList:m,dir:k}=f,A=p().flowchart??{};if(k=k??(A.inheritDir?this.getDirection()??p().direction??void 0:void 0),this.version==="gen-1")for(let _=0;_<m.length;_++)m[_]=this.lookUpDomId(m[_]);c=c??"subGraph"+this.subCount,d=d||"",d=this.sanitizeText(d),this.subCount=this.subCount+1;let C={id:c,nodes:m.filter((_)=>_!==c&&!this.globalNodes.has(_)),title:d.trim(),classes:[],dir:k,labelType:this.sanitizeNodeLabelType(n?.type),type:a??"flow"};l.info("Adding",C.id,C.nodes,C.dir),C.nodes=this.makeUniq(C,this.subGraphs).nodes;let L=this.getPosForId(c);if(L!==-1){let _=this.subGraphs[L];for(let U of C.nodes)if(!_.nodes.includes(U))_.nodes.push(U);if(C.title)_.title=C.title;if(C.dir)_.dir=C.dir;if(C.type)_.type=C.type;this.subGraphLookup.set(c,_)}else this.subGraphs.push(C),this.subGraphLookup.set(c,C);return c}addGlobal(e){for(let r of e.flat()){if(typeof r!=="string")continue;let n=r.trim();if(n!=="")this.globalNodes.add(n)}for(let r of this.subGraphs)r.nodes=r.nodes.filter((n)=>!this.globalNodes.has(n))}getPosForId(e){for(let[r,n]of this.subGraphs.entries())if(n.id===e)return r;return-1}indexNodes2(e,r){let n=this.subGraphs[r].nodes;if(this.secCount=this.secCount+1,this.secCount>2000)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=r,this.subGraphs[r].id===e)return{result:!0,count:0};let a=0,c=1;while(a<n.length){let d=this.getPosForId(n[a]);if(d>=0){let o=this.indexNodes2(e,d);if(o.result)return{result:!0,count:c+o.count};else c=c+o.count}a=a+1}return{result:!1,count:c}}getDepthFirstPos(e){return this.posCrossRef[e]}indexNodes(){if(this.secCount=-1,this.subGraphs.length>0)this.indexNodes2("none",this.subGraphs.length-1)}addConnector(e,r){let n=e?.text?.trim();if(!n)return"";let a=r?.text?.trim()??"",c=a.length>0?this.sanitizeText(a):n,d=this.connectors.get(n);if(!d)d={id:n,labelType:"text",domId:A1+n+"-"+this.vertexCounter,styles:[],classes:[],isConnector:!0,text:c},this.connectors.set(n,d),this.vertices.set(n,d),this.vertexCounter++;else if(a.length>0)d.text=c;return n}getSubGraphs(){return this.subGraphs}getConnectors(){return[...this.connectors.values()]}firstGraph(){if(this.firstGraphFlag)return this.firstGraphFlag=!1,!0;return!1}computeEdgeSemantic(e,r){if(e==="arrow_point"&&r==="normal")return"sequence";if(e==="arrow_cross"&&r==="normal")return"failure";if(e==="arrow_open"&&r==="dotted")return"reference";return}destructStartLink(e){let r=e.trim(),n="arrow_open",a="normal";if(r.includes("."))a="dotted";return{type:"arrow_open",stroke:a}}countChar(e,r){let n=r.length,a=0;for(let c=0;c<n;++c)if(r[c]===e)++a;return a}destructEndLink(e){let r=e.trim(),n=r.slice(0,-1),a="arrow_open";switch(r.slice(-1)){case"x":a="arrow_cross";break;case">":a="arrow_point";break;case"-":case".":a="arrow_open",n=r;break}let c="normal",d=n.length-1,o=this.countChar(".",n);if(o>0)c="dotted",d=o;return{type:a,stroke:c,length:d}}destructLink(e,r){let n=this.destructEndLink(e),a;if(r){if(a=this.destructStartLink(r),a.stroke!==n.stroke)return{type:"INVALID",stroke:"INVALID"};return a.type=n.type,a.length=n.length,{...a,edgeSemantic:this.computeEdgeSemantic(a.type,a.stroke)}}return{...n,edgeSemantic:this.computeEdgeSemantic(n.type,n.stroke)}}exists(e,r){for(let n of e)if(n.nodes.includes(r))return!0;return!1}makeUniq(e,r){let n=[];return e.nodes.forEach((a,c)=>{if(!this.exists(r,a))n.push(e.nodes[c])}),{nodes:n}}getTypeFromVertex(e){let r=typeof e.type==="string"?gt(e.type):e.type;switch(r){case"square":case void 0:return"squareRect";case"round":return"roundedRect";case"ellipse":return"ellipse";default:return r}}findNode(e,r){return e.find((n)=>n.id===r)}destructEdgeType(e){let r="none",n="arrow_point";switch(e){case"arrow_point":case"arrow_circle":case"arrow_cross":case"arrow_hierarchy":n=e;break;case"double_arrow_point":case"double_arrow_circle":case"double_arrow_cross":r=e.replace("double_",""),n=r;break}return{arrowTypeStart:r,arrowTypeEnd:n}}addNodeFromVertex(e,r,n,a,c,d){let o=n.get(e.id),f=a.get(e.id)??!1,m=this.findNode(r,e.id);if(m)m.cssStyles=e.styles,m.cssCompiledStyles=this.getCompiledStyles(e.classes),m.cssClasses=e.classes.join(" ");else{let k={id:e.id,label:e.text,labelType:e.labelType,labelStyle:"",parentId:o,padding:c.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:this.getCompiledStyles(["default","node",...e.classes]),cssClasses:"default "+e.classes.join(" "),dir:e.dir,domId:e.domId,look:d,link:e.link,linkTarget:e.linkTarget,tooltip:this.getTooltip(e.id),metadata:e.metadata};if(f)r.push({...k,isGroup:!0,shape:"rect"});else r.push({...k,isGroup:!1,shape:this.getTypeFromVertex(e),wrappingWidth:c.agentflow?.wrappingWidth,minWidth:c.agentflow?.minNodeWidth})}}getCompiledStyles(e){let r=[];for(let n of e){let a=this.classes.get(n);if(a?.styles)r=[...r,...a.styles??[]].map((c)=>c.trim());if(a?.textStyles)r=[...r,...a.textStyles??[]].map((c)=>c.trim())}return r}runPostParseValidators(){if(this.postParseValidationRun)return;this.postParseValidationRun=!0}getData(){this.runPostParseValidators();let e=p(),r=[],n=[],a=this.getSubGraphs(),c=new Map,d=new Map,o=new Set,f=new Map,m=t((g,b,v=new Set)=>{if(v.has(g))return;v.add(g);let q=this.subGraphLookup.get(g);if(!q)return;for(let fe of q.nodes){if(fe===b||v.has(fe))continue;o.add(fe),f.set(fe,b),m(fe,b,v)}},"collectDescendants");for(let g of a)if(g.metadata?.view==="collapsed"&&!o.has(g.id))m(g.id,g.id);let k=t((g,b)=>{let v=new Set,q=b;while(q!==void 0&&!v.has(q)){if(q===g)return!0;v.add(q),q=c.get(q)}return!1},"wouldCloseContainmentCycle");for(let g=a.length-1;g>=0;g--){let b=a[g];if(o.has(b.id))continue;if(b.nodes.length>0)d.set(b.id,!0);for(let v of b.nodes){if(k(v,b.id)){this.emitWarning(bt.CONTAINMENT_VIOLATION,`Container "${b.id}" cannot contain "${v}" because "${v}" already contains it. The nesting that would close the loop is dropped.`,{nodeId:v});continue}c.set(v,b.id)}}for(let g=a.length-1;g>=0;g--){let b=a[g];if(o.has(b.id))continue;if(b.metadata?.view==="collapsed"){let q={...b.metadata,containerType:b.type};r.push({id:b.id,label:b.title,labelStyle:"",labelType:b.labelType,parentId:c.get(b.id),padding:8,cssCompiledStyles:this.getCompiledStyles(b.classes),cssClasses:b.classes.join(" "),shape:"collapsedGroup",dir:b.dir,isGroup:!1,look:e.look,metadata:q})}else r.push({id:b.id,label:b.title,labelStyle:"",labelType:b.labelType,parentId:c.get(b.id),padding:8,cssCompiledStyles:this.getCompiledStyles(b.classes),cssClasses:b.classes.join(" "),shape:G1[b.type??"flow"],dir:b.dir,isGroup:!0,look:e.look,metadata:b.metadata})}this.getVertices().forEach((g)=>{if(o.has(g.id))return;this.addNodeFromVertex(g,r,c,d,e,e.look||"classic")});let C=this.getEdges();C.forEach((g,b)=>{let v=f.get(g.start)??g.start,q=f.get(g.end)??g.end;if(v===q&&g.start!==g.end)return;let{arrowTypeStart:fe,arrowTypeEnd:Se}=this.destructEdgeType(g.type),Ee=[...C.defaultStyle??[]];if(g.style)Ee.push(...g.style);let xe={id:fn(v,q,{counter:b,prefix:"L"},g.id),isUserDefinedId:g.isUserDefinedId,start:v,end:q,type:g.type??"normal",label:g.text,labelType:g.labelType,labelpos:"c",thickness:g.stroke,minlen:g.length,classes:g?.stroke==="invisible"?"":"edge-thickness-normal edge-pattern-solid flowchart-link",arrowTypeStart:g?.stroke==="invisible"||g?.type==="arrow_open"?"none":fe,arrowTypeEnd:g?.stroke==="invisible"||g?.type==="arrow_open"?"none":Se,arrowheadStyle:"fill: #333",cssCompiledStyles:this.getCompiledStyles(g.classes),labelStyle:Ee,style:Ee,pattern:g.stroke,look:e.look,animate:g.animate,animation:g.animation,curve:g.interpolate||this.edges.defaultInterpolate||e.flowchart?.curve,metadata:g.metadata};n.push(xe)}),E1(r,this);let L=new Map,_=new Map;for(let g of a){let b=c.get(g.id);if(b!==void 0)_.set(b,[..._.get(b)??[],g.id])}let U=0,F=t((g)=>{if(L.has(g))return;L.set(g,U++);for(let b of _.get(g)??[])F(b)},"walkContainers");for(let g of a)if(c.get(g.id)===void 0)F(g.id);let E=new Set(this.getConnectors().map((g)=>g.id));return D1(r,(g)=>{if(E.has(g))return"connector";let b=this.vertices.get(g);return b?this.deriveVertexKind(b,gt(b.type)):void 0},L),{nodes:r,edges:n,other:{},config:e,connectors:this.getConnectors()}}defaultConfig(){return Eo.flowchart}deriveVertexKind(e,r){if(this.isToolDefinition(e))return"tool";if(r==="hexagon"||r==="hex")return"action";if(r==="lean-right"||r==="lean_right")return"input";if(r==="lin-doc"||r==="lined-document")return"refdoc";if(r==="diamond")return"decision";return"task"}getSemanticModel(){this.runPostParseValidators();let e=new Set(this.subGraphs.map((o)=>o.id)),r=[],n=[];for(let[o,f]of this.vertices){if(e.has(o))continue;if(f.isConnector){let A={id:o};if(f.text!==void 0&&f.text!==o)A.title=f.text;if(f.metadata&&Object.keys(f.metadata).length>0){let C={};for(let[L,_]of Object.entries(f.metadata)){if(i1.has(L))continue;C[L]=_}if(Object.keys(C).length>0)A.metadata=C}n.push(A);continue}let m={id:o};if(f.text!==void 0)m.label=f.text;let k=typeof f.type==="string"?gt(f.type):f.type;if(k!==void 0)m.shape=k;if(m.vertexKind=this.deriveVertexKind(f,k),f.metadata&&Object.keys(f.metadata).length>0){let A={};for(let[C,L]of Object.entries(f.metadata)){if(i1.has(C))continue;A[C]=L}if(Object.keys(A).length>0)m.metadata=A}r.push(m)}let a=this.edges.map((o)=>{let f={start:o.start,end:o.end};if(o.id!==void 0)f.id=o.id;if(typeof o.text==="string"&&o.text.length>0)f.label=o.text;if(o.type!==void 0)f.type=o.type;if(o.stroke!==void 0)f.stroke=o.stroke;if(o.edgeSemantic!==void 0)f.edgeSemantic=o.edgeSemantic;if(o.length!==void 0)f.length=o.length;if(o.metadata&&Object.keys(o.metadata).length>0)f.metadata={...o.metadata};return f}),c=this.subGraphs.map((o)=>{let f={id:o.id,nodes:[...o.nodes]};if(o.type!==void 0)f.type=o.type;if(o.title!==void 0)f.title=o.title;if(o.dir!==void 0)f.direction=o.dir;if(o.metadata&&Object.keys(o.metadata).length>0){let m={};for(let[k,A]of Object.entries(o.metadata)){if(i1.has(k))continue;m[k]=A}if(Object.keys(m).length>0)f.metadata=m}return f}),d={vertices:r,edges:a,subGraphs:c,connectors:n,diagnostics:this.diagnostics};if(this.direction!==void 0)d.direction=this.direction;return d}setFrontmatterLineOffset(e){this.frontmatterLineOffset=e??0}toElementPosition(e){let r=e?.first_line??0,n=e?.first_column??0,a=e?.last_line??r,c=e?.last_column??n,[d,o]=e?.range??[0,0];return{startLine:r+this.frontmatterLineOffset,startColumn:n,endLine:a+this.frontmatterLineOffset,endColumn:c,startIndex:d,endIndex:o}}pushMapping(e,r,n){if(!e)return;let a={id:e,type:r,position:this.toElementPosition(n)};return this.elementMappings.push(a),a}addVertexMapping(e,r,n,a){let c=this.pushMapping(e,"vertex",a);if(c&&n==null)this.bareVertexMappings.add(c)}extendVertexMapping(e,r){if(!e||!r)return;let n=this.toElementPosition(r);for(let a=this.elementMappings.length-1;a>=0;a--){let c=this.elementMappings[a];if(c.type==="vertex"&&c.id===e){if(this.bareVertexMappings.has(c))c.type="attachment",this.bareVertexMappings.delete(c);if(n.endLine>c.position.endLine||n.endLine===c.position.endLine&&n.endColumn>c.position.endColumn)c.position.endLine=n.endLine,c.position.endColumn=n.endColumn,c.position.endIndex=n.endIndex;return}}this.pushMapping(e,"attachment",r)}addEdgeMapping(e,r,n,a){let c=Array.isArray(r)?r.map((o)=>typeof o==="string"?o:o?.id??"").filter(Boolean):[],d=c.length>0?c.join(">"):"edge";this.pushMapping(d,"edge",a)}addSubgraphMapping(e,r,n,a){let c=(typeof e==="string"?e:e?.text)??"",d=this.toElementPosition(n),o=a?this.toElementPosition(a):d;if(!c)return;this.elementMappings.push({id:c,type:"subgraph",position:{startLine:d.startLine,startColumn:d.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:d.startIndex,endIndex:o.endIndex}})}addConnectorMapping(e,r,n,a){let c=e?.text?.trim()??"";if(!c)return;let d=this.toElementPosition(n),o=a?this.toElementPosition(a):d;this.elementMappings.push({id:c,type:"connector",position:{startLine:d.startLine,startColumn:d.startColumn,endLine:o.endLine,endColumn:o.endColumn,startIndex:d.startIndex,endIndex:o.endIndex}})}getElementMappings(){return[...this.elementMappings]}getElementById(e){return this.elementMappings.find((r)=>r.id===e)}getElementsOnLine(e){return this.elementMappings.filter((r)=>e>=r.position.startLine&&e<=r.position.endLine)}getElementAtPosition(e,r){let n=this.elementMappings.filter((c)=>{let{startLine:d,startColumn:o,endLine:f,endColumn:m}=c.position;if(e<d||e>f)return!1;if(e===d&&r<o)return!1;if(e===f&&r>m)return!1;return!0});if(n.length===0)return;let a=t(({position:c})=>[c.endLine-c.startLine,c.endColumn-c.startColumn],"span");return n.reduce((c,d)=>{let[o,f]=a(c),[m,k]=a(d);if(m!==o)return m<o?d:c;return k<f?d:c})}getMappingStats(){let e=0,r=0,n=0,a=0,c=0;for(let d of this.elementMappings)if(d.type==="vertex")e++;else if(d.type==="edge")r++;else if(d.type==="subgraph")n++;else if(d.type==="connector")a++;else if(d.type==="attachment")c++;return{vertices:e,edges:r,subgraphs:n,connectors:a,attachments:c,totalElements:this.elementMappings.length}}emitDiagnostic(e,r,n,a){let c=a?.nodeId??a?.edgeId,d=c?this.getElementById(c):void 0,o={id:e,severity:r,message:n,...a?.nodeId?{nodeId:a.nodeId}:{},...a?.edgeId&&!a?.nodeId?{edgeId:a.edgeId}:{},...d?{position:d.position}:{}};if(this.diagnostics.some((k)=>k.id===o.id&&k.severity===o.severity&&k.message===o.message&&k.nodeId===o.nodeId&&k.edgeId===o.edgeId))return;this.diagnostics.push(o);let m=`agentflow[${e}]: ${n}`;if(r==="error")l.error(m);else l.warn(m)}emitWarning(e,r,n){this.emitDiagnostic(e,"warning",r,n)}emitError(e,r,n){this.emitDiagnostic(e,"error",r,n)}getDiagnostics(){return[...this.diagnostics]}},j1=t(function(e,r){return r.db.getClasses()},"getClasses"),z1=t(async function(e,r,n,a){l.debug("Drawing agentflow diagram",r);let{securityLevel:c,agentflow:d,layout:o}=p();a.db.setDiagramId(r),l.debug("Before getData: ");let f=a.db.getData();l.debug("Data: ",f);let m=St(r,c),k=a.db.getDirection();if(f.type=a.type,f.layoutAlgorithm=_t(o),f.layoutAlgorithm==="dagre"&&o==="elk")l.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback.");f.direction=k,f.nodeSpacing=d?.nodeSpacing||50,f.rankSpacing=d?.rankSpacing||50,f.markers=["point","circle","cross","hierarchy"],f.diagramId=r,l.debug("REF1:",f),await It(f,m);let A=d?.diagramPadding??8;H.insertTitle(m,"agentflowTitleText",d?.titleTopMargin??0,a.db.getDiagramTitle()),lt(m,A,"agentflow",d?.useMaxWidth??!0)},"draw"),W1={getClasses:j1,draw:z1},r1=function(){var e=t(function(we,S,T,D){for(T=T||{},D=we.length;D--;T[we[D]]=S);return T},"o"),r=[1,5],n=[1,4],a=[1,3],c=[1,6],d=[1,8,9,10,11,12,28,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],o=[2,2],f=[1,15],m=[1,16],k=[1,17],A=[1,18],C=[1,19],L=[1,26],_=[1,27],U=[1,28],F=[1,30],E=[1,31],g=[1,32],b=[1,55],v=[1,54],q=[1,34],fe=[1,35],Se=[1,36],Ee=[1,37],xe=[1,38],Q=[1,50],J=[1,52],Z=[1,48],ee=[1,53],te=[1,49],se=[1,56],ie=[1,51],re=[1,57],ne=[1,58],Ne=[1,39],Re=[1,40],Oe=[1,41],Pe=[1,42],Ge=[1,43],Me=[1,64],V=[1,8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],ce=[1,70],de=[1,68],he=[1,67],pe=[1,69],We=[8,9,10,12,78,80,81],Ke=[1,88],He=[1,101],qe=[1,106],Xe=[1,105],Qe=[1,102],Ze=[1,98],$e=[1,104],et=[1,100],tt=[1,107],it=[1,103],rt=[1,108],nt=[1,99],Ue=[8,9,10,11,12,43,78,80,81],oe=[8,9,10,11,12,43,49,78,80,81],be=[8,9,10,11,12,30,43,47,49,51,53,55,57,59,61,63,66,68,70,71,73,78,80,81,92,105,108,109,112,114,117,118,119],n1=[8,9,10,12,47,63,78,80,81,92,105,108,109,112,114,117,118,119],at=[47,63,92,105,108,109,112,114,117,118,119],a1=[1,131],o1=[1,132],kt=[1,134],mt=[1,133],u1=[47,63,65,77,92,105,108,109,112,114,117,118,119],At=[1,143],Et=[1,157],Ct=[1,158],xt=[1,159],Tt=[1,162],Dt=[1,161],vt=[1,160],Ft=[1,145],Vt=[1,147],Lt=[1,151],l1=[1,139],c1=[1,140],Bt=[1,152],Mt=[1,153],yt=[1,154],wt=[1,155],Nt=[1,156],Rt=[1,163],Ot=[1,164],Pt=[1,141],Gt=[1,142],Ut=[1,149],jt=[1,144],zt=[1,148],Wt=[1,146],ut=[8,9,10,11,12,28,33,35,36,38,40,42,47,63,87,88,89,90,91,92,105,108,109,112,114,117,118,119,124,125,126,127,128],d1=[1,168],ct=[1,170],X=[8,9,10,12],ke=[8,9,10,11,12,15,47,63,92,108,109,112,114,117,118,119],B=[1,190],ue=[1,186],le=[1,187],y=[1,191],w=[1,188],N=[1,189],dt=[80,119,122],W=[8,9,10,11,12,13,15,28,30,33,35,36,43,47,63,78,87,88,89,90,91,92,93,108,112,114,117,118,119],h1=[11,109],ye=[32,52,54,56,58,60,65,67,69,70,72,74,119,120,121],Te=[1,269],De=[1,267],_e=[1,271],ve=[1,265],Fe=[1,266],Ve=[1,268],Ie=[1,270],Le=[1,272],ht=[1,292],p1=[8,9,10,12,109],Ce=[8,9,10,11,12,63,87,108,109,112,113,114,115],Jt={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,COMMENT:8,SEMI:9,NEWLINE:10,SPACE:11,EOF:12,GRAPH:13,NODIR:14,DIR:15,FirstStmtSeparator:16,ending:17,endToken:18,spaceList:19,spaceListNewline:20,vertexStatement:21,separator:22,styleStatement:23,linkStyleStatement:24,classDefStatement:25,classStatement:26,clickStatement:27,flow:28,textNoTags:29,SQS:30,text:31,SQE:32,end:33,shapeData:34,global:35,connector:36,direction:37,acc_title:38,acc_title_value:39,acc_descr:40,acc_descr_value:41,acc_descr_multiline_value:42,SHAPE_DATA:43,link:44,node:45,styledVertex:46,AMP:47,vertex:48,STYLE_SEPARATOR:49,idString:50,DOUBLECIRCLESTART:51,DOUBLECIRCLEEND:52,PS:53,PE:54,"(-":55,"-)":56,STADIUMSTART:57,STADIUMEND:58,SUBROUTINESTART:59,SUBROUTINEEND:60,VERTEX_WITH_PROPS_START:61,"NODE_STRING[field]":62,COLON:63,"NODE_STRING[value]":64,PIPE:65,CYLINDERSTART:66,CYLINDEREND:67,DIAMOND_START:68,DIAMOND_STOP:69,TAGEND:70,TRAPSTART:71,TRAPEND:72,INVTRAPSTART:73,INVTRAPEND:74,linkStatement:75,arrowText:76,TESTSTR:77,START_LINK:78,edgeText:79,LINK:80,LINK_ID:81,edgeTextToken:82,STR:83,MD_STR:84,textToken:85,keywords:86,STYLE:87,LINKSTYLE:88,CLASSDEF:89,CLASS:90,CLICK:91,DOWN:92,UP:93,textNoTagsToken:94,stylesOpt:95,"idString[vertex]":96,"idString[class]":97,CALLBACKNAME:98,CALLBACKARGS:99,HREF:100,LINK_TARGET:101,"STR[link]":102,"STR[tooltip]":103,alphaNum:104,DEFAULT:105,numList:106,INTERPOLATE:107,NUM:108,COMMA:109,style:110,styleComponent:111,NODE_STRING:112,UNIT:113,BRKT:114,PCT:115,idStringToken:116,MINUS:117,MULT:118,UNICODE_TEXT:119,TEXT:120,TAGSTART:121,EDGE_TEXT:122,alphaNumToken:123,direction_tb:124,direction_bt:125,direction_rl:126,direction_lr:127,direction_td:128,$accept:0,$end:1},terminals_:{2:"error",8:"COMMENT",9:"SEMI",10:"NEWLINE",11:"SPACE",12:"EOF",13:"GRAPH",14:"NODIR",15:"DIR",28:"flow",30:"SQS",32:"SQE",33:"end",35:"global",36:"connector",38:"acc_title",39:"acc_title_value",40:"acc_descr",41:"acc_descr_value",42:"acc_descr_multiline_value",43:"SHAPE_DATA",47:"AMP",49:"STYLE_SEPARATOR",51:"DOUBLECIRCLESTART",52:"DOUBLECIRCLEEND",53:"PS",54:"PE",55:"(-",56:"-)",57:"STADIUMSTART",58:"STADIUMEND",59:"SUBROUTINESTART",60:"SUBROUTINEEND",61:"VERTEX_WITH_PROPS_START",62:"NODE_STRING[field]",63:"COLON",64:"NODE_STRING[value]",65:"PIPE",66:"CYLINDERSTART",67:"CYLINDEREND",68:"DIAMOND_START",69:"DIAMOND_STOP",70:"TAGEND",71:"TRAPSTART",72:"TRAPEND",73:"INVTRAPSTART",74:"INVTRAPEND",77:"TESTSTR",78:"START_LINK",80:"LINK",81:"LINK_ID",83:"STR",84:"MD_STR",87:"STYLE",88:"LINKSTYLE",89:"CLASSDEF",90:"CLASS",91:"CLICK",92:"DOWN",93:"UP",96:"idString[vertex]",97:"idString[class]",98:"CALLBACKNAME",99:"CALLBACKARGS",100:"HREF",101:"LINK_TARGET",102:"STR[link]",103:"STR[tooltip]",105:"DEFAULT",107:"INTERPOLATE",108:"NUM",109:"COMMA",112:"NODE_STRING",113:"UNIT",114:"BRKT",115:"PCT",117:"MINUS",118:"MULT",119:"UNICODE_TEXT",120:"TEXT",121:"TAGSTART",122:"EDGE_TEXT",124:"direction_tb",125:"direction_bt",126:"direction_rl",127:"direction_lr",128:"direction_td"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,2],[4,3],[17,2],[17,1],[18,1],[18,1],[18,1],[16,1],[16,1],[16,2],[16,1],[20,2],[20,2],[20,2],[20,1],[20,1],[20,1],[19,2],[19,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,10],[7,6],[7,7],[7,4],[7,4],[7,7],[7,8],[7,4],[7,5],[7,1],[7,2],[7,2],[7,1],[22,1],[22,1],[22,1],[22,1],[34,2],[34,1],[21,4],[21,3],[21,4],[21,2],[21,2],[21,1],[45,1],[45,6],[45,5],[46,1],[46,3],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,8],[48,4],[48,4],[48,4],[48,6],[48,4],[48,4],[48,4],[48,4],[48,4],[48,1],[44,2],[44,3],[44,3],[44,1],[44,3],[44,4],[79,1],[79,2],[79,1],[79,1],[75,1],[75,2],[76,3],[31,1],[31,2],[31,1],[31,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[86,1],[29,1],[29,2],[29,1],[29,1],[25,5],[26,5],[27,2],[27,4],[27,3],[27,5],[27,3],[27,5],[27,5],[27,7],[27,2],[27,4],[27,2],[27,4],[27,4],[27,6],[23,5],[24,5],[24,5],[24,9],[24,9],[24,7],[24,7],[106,1],[106,3],[95,1],[95,3],[110,1],[110,2],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[111,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[116,1],[85,1],[85,1],[85,1],[85,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[94,1],[82,1],[82,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[123,1],[50,1],[50,2],[104,1],[104,2],[37,1],[37,1],[37,1],[37,1],[37,1]],performAction:t(function(S,T,D,u,K,s,I){var i=s.length-1;switch(K){case 2:this.$=[];break;case 3:if(!Array.isArray(s[i])||s[i].length>0)s[i-1].push(s[i]);this.$=s[i-1];break;case 4:case 198:this.$=s[i];break;case 5:case 33:case 34:case 35:case 36:case 37:this.$=[];break;case 13:u.setDirection("TB"),this.$="TB";break;case 14:u.setDirection(s[i-1]),this.$=s[i-1];break;case 32:this.$=s[i-1].nodes;break;case 38:if(this.$=u.addSubGraph(s[i-6],s[i-1],s[i-4],"flow"),u.addSubgraphMapping)u.addSubgraphMapping(s[i-6],s[i-4],I[i-8],I[i]);break;case 39:if(this.$=u.addSubGraph(s[i-7],s[i-1],s[i-5],"flow"),u.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,s[i-3],I[i-3]),u.addSubgraphMapping)u.addSubgraphMapping(s[i-7],s[i-5],I[i-9],I[i]);break;case 40:if(this.$=u.addSubGraph(s[i-3],s[i-1],{text:"",type:"text"},"flow"),u.addSubgraphMapping)u.addSubgraphMapping(s[i-3],{text:"",type:"text"},I[i-5],I[i]);break;case 41:if(this.$=u.addSubGraph(s[i-4],s[i-1],{text:"",type:"text"},"flow"),u.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,s[i-3],I[i-3]),u.addSubgraphMapping)u.addSubgraphMapping(s[i-4],{text:"",type:"text"},I[i-6],I[i]);break;case 42:if(this.$=u.addSubGraph(void 0,s[i-1],void 0,"flow"),u.addSubgraphMapping)u.addSubgraphMapping(void 0,void 0,I[i-3],I[i]);break;case 43:u.addGlobal(s[i-1]),this.$=[];break;case 44:if(this.$=u.addConnector(s[i-4],s[i-2]),u.addConnectorMapping)u.addConnectorMapping(s[i-4],s[i-2],I[i-6],I[i]);break;case 45:if(this.$=u.addConnector(s[i-5],s[i-3]),u.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,s[i-1],I[i-1]),u.addConnectorMapping)u.addConnectorMapping(s[i-5],s[i-3],I[i-7],I[i]);break;case 46:if(this.$=u.addConnector(s[i-1],{text:"",type:"text"}),u.addConnectorMapping)u.addConnectorMapping(s[i-1],{text:"",type:"text"},I[i-3],I[i]);break;case 47:if(this.$=u.addConnector(s[i-2],{text:"",type:"text"}),u.addVertex(this.$,void 0,void 0,void 0,void 0,void 0,void 0,s[i-1],I[i-1]),u.addConnectorMapping)u.addConnectorMapping(s[i-2],{text:"",type:"text"},I[i-4],I[i]);break;case 49:this.$=s[i].trim(),u.setAccTitle(this.$);break;case 50:case 51:this.$=s[i].trim(),u.setAccDescription(this.$);break;case 56:this.$=s[i-1]+s[i];break;case 57:this.$=s[i];break;case 58:if(u.addVertex(s[i-1][s[i-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,s[i],I[i]),u.extendVertexMapping)u.extendVertexMapping(s[i-1][s[i-1].length-1],I[i]);if(u.addLink(s[i-3].stmt,s[i-1],s[i-2]),u.addEdgeMapping)u.addEdgeMapping(s[i-3].stmt,s[i-1],s[i-2],this._$);this.$={stmt:s[i-1],nodes:s[i-1].concat(s[i-3].nodes)};break;case 59:if(u.addLink(s[i-2].stmt,s[i],s[i-1]),u.addEdgeMapping)u.addEdgeMapping(s[i-2].stmt,s[i],s[i-1],this._$);this.$={stmt:s[i],nodes:s[i].concat(s[i-2].nodes)};break;case 60:if(u.addLink(s[i-3].stmt,s[i-1],s[i-2]),u.addEdgeMapping)u.addEdgeMapping(s[i-3].stmt,s[i-1],s[i-2],this._$);this.$={stmt:s[i-1],nodes:s[i-1].concat(s[i-3].nodes)};break;case 61:this.$={stmt:s[i-1],nodes:s[i-1]};break;case 62:if(u.addVertex(s[i-1][s[i-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,s[i],I[i]),u.extendVertexMapping)u.extendVertexMapping(s[i-1][s[i-1].length-1],I[i]);this.$={stmt:s[i-1],nodes:s[i-1],shapeData:s[i]};break;case 63:this.$={stmt:s[i],nodes:s[i]};break;case 64:this.$=[s[i]];break;case 65:if(u.addVertex(s[i-5][s[i-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,s[i-4],I[i-4]),u.extendVertexMapping)u.extendVertexMapping(s[i-5][s[i-5].length-1],I[i-4]);this.$=s[i-5].concat(s[i]);break;case 66:this.$=s[i-4].concat(s[i]);break;case 67:this.$=s[i];break;case 68:this.$=s[i-2],u.setClass(s[i-2],s[i]);break;case 69:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"square"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"square",this._$);break;case 70:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"doublecircle"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"doublecircle",this._$);break;case 71:if(this.$=s[i-5],u.addVertex(s[i-5],s[i-2],"circle"),u.addVertexMapping)u.addVertexMapping(s[i-5],s[i-2],"circle",this._$);break;case 72:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"ellipse"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"ellipse",this._$);break;case 73:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"stadium"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"stadium",this._$);break;case 74:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"subroutine"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"subroutine",this._$);break;case 75:if(this.$=s[i-7],u.addVertex(s[i-7],s[i-1],"rect",void 0,void 0,void 0,Object.fromEntries([[s[i-5],s[i-3]]])),u.addVertexMapping)u.addVertexMapping(s[i-7],s[i-1],"rect",this._$);break;case 76:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"cylinder"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"cylinder",this._$);break;case 77:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"round"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"round",this._$);break;case 78:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"diamond"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"diamond",this._$);break;case 79:if(this.$=s[i-5],u.addVertex(s[i-5],s[i-2],"hexagon"),u.addVertexMapping)u.addVertexMapping(s[i-5],s[i-2],"hexagon",this._$);break;case 80:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"odd"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"odd",this._$);break;case 81:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"trapezoid"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"trapezoid",this._$);break;case 82:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"inv_trapezoid"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"inv_trapezoid",this._$);break;case 83:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"lean_right"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"lean_right",this._$);break;case 84:if(this.$=s[i-3],u.addVertex(s[i-3],s[i-1],"lean_left"),u.addVertexMapping)u.addVertexMapping(s[i-3],s[i-1],"lean_left",this._$);break;case 85:if(this.$=s[i],u.addVertex(s[i]),u.addVertexMapping)u.addVertexMapping(s[i],void 0,void 0,this._$);break;case 86:s[i-1].text=s[i],this.$=s[i-1];break;case 87:case 88:s[i-2].text=s[i-1],this.$=s[i-2];break;case 89:this.$=s[i];break;case 90:var Y=u.destructLink(s[i],s[i-2]);this.$={type:Y.type,stroke:Y.stroke,length:Y.length,edgeSemantic:Y.edgeSemantic,text:s[i-1]};break;case 91:var Y=u.destructLink(s[i],s[i-2]);this.$={type:Y.type,stroke:Y.stroke,length:Y.length,edgeSemantic:Y.edgeSemantic,text:s[i-1],id:s[i-3]};break;case 92:this.$={text:s[i],type:"text"};break;case 93:this.$={text:s[i-1].text+""+s[i],type:s[i-1].type};break;case 94:this.$={text:s[i],type:"string"};break;case 95:this.$={text:s[i],type:"markdown"};break;case 96:var Y=u.destructLink(s[i]);this.$={type:Y.type,stroke:Y.stroke,length:Y.length,edgeSemantic:Y.edgeSemantic};break;case 97:var Y=u.destructLink(s[i]);this.$={type:Y.type,stroke:Y.stroke,length:Y.length,edgeSemantic:Y.edgeSemantic,id:s[i-1]};break;case 98:this.$=s[i-1];break;case 99:this.$={text:s[i],type:"text"};break;case 100:this.$={text:s[i-1].text+""+s[i],type:s[i-1].type};break;case 101:this.$={text:s[i],type:"string"};break;case 102:case 119:this.$={text:s[i],type:"markdown"};break;case 116:this.$={text:s[i],type:"text"};break;case 117:this.$={text:s[i-1].text+""+s[i],type:s[i-1].type};break;case 118:this.$={text:s[i],type:"text"};break;case 120:this.$=s[i-4],u.addClass(s[i-2],s[i]);break;case 121:this.$=s[i-4],u.setClass(s[i-2],s[i]);break;case 122:case 130:this.$=s[i-1],u.setClickEvent(s[i-1],s[i]);break;case 123:case 131:this.$=s[i-3],u.setClickEvent(s[i-3],s[i-2]),u.setTooltip(s[i-3],s[i]);break;case 124:this.$=s[i-2],u.setClickEvent(s[i-2],s[i-1],s[i]);break;case 125:this.$=s[i-4],u.setClickEvent(s[i-4],s[i-3],s[i-2]),u.setTooltip(s[i-4],s[i]);break;case 126:this.$=s[i-2],u.setLink(s[i-2],s[i]);break;case 127:this.$=s[i-4],u.setLink(s[i-4],s[i-2]),u.setTooltip(s[i-4],s[i]);break;case 128:this.$=s[i-4],u.setLink(s[i-4],s[i-2],s[i]);break;case 129:this.$=s[i-6],u.setLink(s[i-6],s[i-4],s[i]),u.setTooltip(s[i-6],s[i-2]);break;case 132:this.$=s[i-1],u.setLink(s[i-1],s[i]);break;case 133:this.$=s[i-3],u.setLink(s[i-3],s[i-2]),u.setTooltip(s[i-3],s[i]);break;case 134:this.$=s[i-3],u.setLink(s[i-3],s[i-2],s[i]);break;case 135:this.$=s[i-5],u.setLink(s[i-5],s[i-4],s[i]),u.setTooltip(s[i-5],s[i-2]);break;case 136:this.$=s[i-4],u.addVertex(s[i-2],void 0,void 0,s[i]);break;case 137:this.$=s[i-4],u.updateLink([s[i-2]],s[i]);break;case 138:this.$=s[i-4],u.updateLink(s[i-2],s[i]);break;case 139:this.$=s[i-8],u.updateLinkInterpolate([s[i-6]],s[i-2]),u.updateLink([s[i-6]],s[i]);break;case 140:this.$=s[i-8],u.updateLinkInterpolate(s[i-6],s[i-2]),u.updateLink(s[i-6],s[i]);break;case 141:this.$=s[i-6],u.updateLinkInterpolate([s[i-4]],s[i]);break;case 142:this.$=s[i-6],u.updateLinkInterpolate(s[i-4],s[i]);break;case 143:case 145:this.$=[s[i]];break;case 144:case 146:s[i-2].push(s[i]),this.$=s[i-2];break;case 148:this.$=s[i-1]+s[i];break;case 196:this.$=s[i];break;case 197:this.$=s[i-1]+""+s[i];break;case 199:this.$=s[i-1]+""+s[i];break;case 200:this.$={stmt:"dir",value:"TB"};break;case 201:this.$={stmt:"dir",value:"BT"};break;case 202:this.$={stmt:"dir",value:"RL"};break;case 203:this.$={stmt:"dir",value:"LR"};break;case 204:this.$={stmt:"dir",value:"TD"};break}},"anonymous"),table:[{3:1,4:2,8:r,10:n,11:a,13:c},{1:[3]},e(d,o,{5:7}),{4:8,8:r,10:n,11:a,13:c},{4:9,8:r,10:n,11:a,13:c},{4:10,8:r,10:n,11:a,13:c},{14:[1,11],15:[1,12]},{1:[2,1],6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},e(d,[2,10]),e(d,[2,11]),e(d,[2,12]),e(d,[2,13]),{8:[1,63],9:[1,60],10:[1,61],11:Me,16:59,19:62},e(V,[2,3]),e(V,[2,4]),e(V,[2,5]),e(V,[2,6]),e(V,[2,7]),e(V,[2,8]),e(V,[2,9]),{8:ce,9:de,10:he,12:pe,22:65,44:66,75:71,78:[1,72],80:[1,74],81:[1,73]},{8:ce,9:de,10:he,12:pe,22:75},{8:ce,9:de,10:he,12:pe,22:76},{8:ce,9:de,10:he,12:pe,22:77},{8:ce,9:de,10:he,12:pe,22:78},{8:ce,9:de,10:he,12:pe,22:79},{8:ce,9:de,10:he,11:[1,80],12:pe,22:81},{8:ce,9:de,10:he,12:pe,22:82},{11:[1,83]},e(V,[2,48]),{39:[1,84]},{41:[1,85]},e(V,[2,51]),e(We,[2,63],{19:86,34:87,11:Me,43:Ke}),{11:[1,89]},{11:[1,90]},{11:[1,91]},{11:[1,92]},{15:He,47:qe,63:Xe,83:[1,96],92:Qe,98:[1,93],100:[1,94],104:95,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt,123:97},e(V,[2,200]),e(V,[2,201]),e(V,[2,202]),e(V,[2,203]),e(V,[2,204]),e(Ue,[2,64]),e(Ue,[2,67],{49:[1,109]}),e(oe,[2,85],{116:122,30:[1,110],47:b,51:[1,111],53:[1,112],55:[1,113],57:[1,114],59:[1,115],61:[1,116],63:v,66:[1,117],68:[1,118],70:[1,119],71:[1,120],73:[1,121],92:Q,105:J,108:Z,109:ee,112:te,114:se,117:ie,118:re,119:ne}),e(be,[2,196]),e(be,[2,157]),e(be,[2,158]),e(be,[2,159]),e(be,[2,160]),e(be,[2,161]),e(be,[2,162]),e(be,[2,163]),e(be,[2,164]),e(be,[2,165]),e(be,[2,166]),e(be,[2,167]),e(d,[2,14]),e(d,[2,20]),e(d,[2,21]),{10:[1,123]},e(d,[2,23]),e(n1,[2,31],{19:124,11:Me}),e(V,[2,32]),{45:125,46:44,47:b,48:45,50:46,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},e(V,[2,52]),e(V,[2,53]),e(V,[2,54]),e(V,[2,55]),e(at,[2,89],{76:126,65:[1,128],77:[1,127]}),{79:129,82:130,83:a1,84:o1,119:kt,122:mt},{78:[1,135],80:[1,136]},e(u1,[2,96]),e(V,[2,33]),e(V,[2,34]),e(V,[2,35]),e(V,[2,36]),e(V,[2,37]),{11:At,13:Et,15:Ct,28:xt,29:137,33:Tt,35:Dt,36:vt,47:Ft,63:Vt,78:Lt,83:l1,84:c1,86:150,87:Bt,88:Mt,89:yt,90:wt,91:Nt,92:Rt,93:Ot,94:138,108:Pt,112:Gt,114:Ut,117:jt,118:zt,119:Wt},e(ut,o,{5:165}),e(ut,o,{5:166}),{11:At,13:Et,15:Ct,28:xt,29:167,33:Tt,35:Dt,36:vt,47:Ft,63:Vt,78:Lt,83:l1,84:c1,86:150,87:Bt,88:Mt,89:yt,90:wt,91:Nt,92:Rt,93:Ot,94:138,108:Pt,112:Gt,114:Ut,117:jt,118:zt,119:Wt},e(V,[2,49]),e(V,[2,50]),e(We,[2,61],{47:d1}),e(We,[2,62],{19:169,11:Me,43:ct}),e(Ue,[2,57]),{47:b,50:171,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},{105:[1,172],106:173,108:[1,174]},{47:b,50:175,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},{47:b,50:176,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},e(X,[2,122],{11:[1,177],99:[1,178]}),{83:[1,179]},e(X,[2,130],{123:181,11:[1,180],15:He,47:qe,63:Xe,92:Qe,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt}),e(X,[2,132],{11:[1,182]}),e(ke,[2,198]),e(ke,[2,185]),e(ke,[2,186]),e(ke,[2,187]),e(ke,[2,188]),e(ke,[2,189]),e(ke,[2,190]),e(ke,[2,191]),e(ke,[2,192]),e(ke,[2,193]),e(ke,[2,194]),e(ke,[2,195]),{47:b,50:183,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},{31:184,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:192,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:194,53:[1,193],70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:195,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:196,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:197,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{112:[1,198]},{31:199,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:200,68:[1,201],70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:202,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:203,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{31:204,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},e(be,[2,197]),e(d,[2,22]),e(n1,[2,30]),e(We,[2,59],{34:205,19:206,11:Me,43:Ke}),e(at,[2,86],{11:[1,207]}),{11:[1,208]},{31:209,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{80:[1,210],82:211,119:kt,122:mt},e(dt,[2,92]),e(dt,[2,94]),e(dt,[2,95]),e(dt,[2,183]),e(dt,[2,184]),{79:212,82:130,83:a1,84:o1,119:kt,122:mt},e(u1,[2,97]),{8:ce,9:de,10:he,11:At,12:pe,13:Et,15:Ct,22:214,28:xt,30:[1,213],33:Tt,34:215,35:Dt,36:vt,43:Ke,47:Ft,63:Vt,78:Lt,86:150,87:Bt,88:Mt,89:yt,90:wt,91:Nt,92:Rt,93:Ot,94:216,108:Pt,112:Gt,114:Ut,117:jt,118:zt,119:Wt},e(W,[2,116]),e(W,[2,118]),e(W,[2,119]),e(W,[2,172]),e(W,[2,173]),e(W,[2,174]),e(W,[2,175]),e(W,[2,176]),e(W,[2,177]),e(W,[2,178]),e(W,[2,179]),e(W,[2,180]),e(W,[2,181]),e(W,[2,182]),e(W,[2,103]),e(W,[2,104]),e(W,[2,105]),e(W,[2,106]),e(W,[2,107]),e(W,[2,108]),e(W,[2,109]),e(W,[2,110]),e(W,[2,111]),e(W,[2,112]),e(W,[2,113]),e(W,[2,114]),e(W,[2,115]),{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,217],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,218],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},{8:ce,9:de,10:he,11:At,12:pe,13:Et,15:Ct,22:220,28:xt,30:[1,219],33:Tt,34:221,35:Dt,36:vt,43:Ke,47:Ft,63:Vt,78:Lt,86:150,87:Bt,88:Mt,89:yt,90:wt,91:Nt,92:Rt,93:Ot,94:216,108:Pt,112:Gt,114:Ut,117:jt,118:zt,119:Wt},{11:Me,19:222},{47:[1,223]},e(Ue,[2,56]),{11:[1,224],47:b,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:122,117:ie,118:re,119:ne},{11:[1,225]},{11:[1,226],109:[1,227]},e(h1,[2,143]),{11:[1,228],47:b,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:122,117:ie,118:re,119:ne},{11:[1,229],47:b,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:122,117:ie,118:re,119:ne},{83:[1,230]},e(X,[2,124],{11:[1,231]}),e(X,[2,126],{11:[1,232]}),{83:[1,233]},e(ke,[2,199]),{83:[1,234],101:[1,235]},e(Ue,[2,68],{116:122,47:b,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,117:ie,118:re,119:ne}),{32:[1,236],70:B,85:237,119:y,120:w,121:N},e(ye,[2,99]),e(ye,[2,101]),e(ye,[2,102]),e(ye,[2,168]),e(ye,[2,169]),e(ye,[2,170]),e(ye,[2,171]),{52:[1,238],70:B,85:237,119:y,120:w,121:N},{31:239,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{54:[1,240],70:B,85:237,119:y,120:w,121:N},{56:[1,241],70:B,85:237,119:y,120:w,121:N},{58:[1,242],70:B,85:237,119:y,120:w,121:N},{60:[1,243],70:B,85:237,119:y,120:w,121:N},{63:[1,244]},{67:[1,245],70:B,85:237,119:y,120:w,121:N},{69:[1,246],70:B,85:237,119:y,120:w,121:N},{31:247,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},{32:[1,248],70:B,85:237,119:y,120:w,121:N},{70:B,72:[1,249],74:[1,250],85:237,119:y,120:w,121:N},{70:B,72:[1,252],74:[1,251],85:237,119:y,120:w,121:N},e(We,[2,58],{19:169,11:Me,43:ct}),e(We,[2,60],{47:d1}),e(at,[2,88]),e(at,[2,87]),{65:[1,253],70:B,85:237,119:y,120:w,121:N},e(at,[2,90]),e(dt,[2,93]),{80:[1,254],82:211,119:kt,122:mt},{31:255,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},e(ut,o,{5:256}),{8:ce,9:de,10:he,12:pe,22:257,43:ct},e(W,[2,117]),e(V,[2,42]),e(V,[2,43]),{31:258,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},e(V,[2,46]),{8:ce,9:de,10:he,12:pe,22:259,43:ct},{46:260,47:b,48:45,50:46,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},{11:Me,19:261},{11:Te,63:De,87:_e,95:262,108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},{11:Te,63:De,87:_e,95:273,107:[1,274],108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},{11:Te,63:De,87:_e,95:275,107:[1,276],108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},{108:[1,277]},{11:Te,63:De,87:_e,95:278,108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},{47:b,50:279,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},e(X,[2,123]),{83:[1,280]},{83:[1,281],101:[1,282]},e(X,[2,131]),e(X,[2,133],{11:[1,283]}),e(X,[2,134]),e(oe,[2,69]),e(ye,[2,100]),e(oe,[2,70]),{54:[1,284],70:B,85:237,119:y,120:w,121:N},e(oe,[2,77]),e(oe,[2,72]),e(oe,[2,73]),e(oe,[2,74]),{112:[1,285]},e(oe,[2,76]),e(oe,[2,78]),{69:[1,286],70:B,85:237,119:y,120:w,121:N},e(oe,[2,80]),e(oe,[2,81]),e(oe,[2,83]),e(oe,[2,82]),e(oe,[2,84]),e([11,47,63,92,105,108,109,112,114,117,118,119],[2,98]),e(at,[2,91]),{32:[1,287],70:B,85:237,119:y,120:w,121:N},{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,288],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},e(ut,o,{5:289}),{32:[1,290],70:B,85:237,119:y,120:w,121:N},e(V,[2,47]),e(Ue,[2,66]),{46:291,47:b,48:45,50:46,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne},e(X,[2,136],{109:ht}),e(p1,[2,145],{111:293,11:Te,63:De,87:_e,108:ve,112:Fe,113:Ve,114:Ie,115:Le}),e(Ce,[2,147]),e(Ce,[2,149]),e(Ce,[2,150]),e(Ce,[2,151]),e(Ce,[2,152]),e(Ce,[2,153]),e(Ce,[2,154]),e(Ce,[2,155]),e(Ce,[2,156]),e(X,[2,137],{109:ht}),{11:[1,294]},e(X,[2,138],{109:ht}),{11:[1,295]},e(h1,[2,144]),e(X,[2,120],{109:ht}),e(X,[2,121],{116:122,47:b,63:v,92:Q,105:J,108:Z,109:ee,112:te,114:se,117:ie,118:re,119:ne}),e(X,[2,125]),e(X,[2,127],{11:[1,296]}),e(X,[2,128]),{101:[1,297]},{54:[1,298]},{65:[1,299]},{69:[1,300]},{8:ce,9:de,10:he,12:pe,22:301,34:302,43:Ke},e(V,[2,40]),{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,303],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},{8:ce,9:de,10:he,12:pe,22:304,34:305,43:Ke},e(Ue,[2,65]),{11:Te,63:De,87:_e,108:ve,110:306,111:264,112:Fe,113:Ve,114:Ie,115:Le},e(Ce,[2,148]),{15:He,47:qe,63:Xe,92:Qe,104:307,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt,123:97},{15:He,47:qe,63:Xe,92:Qe,104:308,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt,123:97},{101:[1,309]},e(X,[2,135]),e(oe,[2,71]),{31:310,70:B,83:ue,84:le,85:185,119:y,120:w,121:N},e(oe,[2,79]),e(ut,o,{5:311}),{8:ce,9:de,10:he,12:pe,22:312,43:ct},e(V,[2,41]),e(V,[2,44]),{8:ce,9:de,10:he,12:pe,22:313,43:ct},e(p1,[2,146],{111:293,11:Te,63:De,87:_e,108:ve,112:Fe,113:Ve,114:Ie,115:Le}),e(X,[2,141],{123:181,11:[1,314],15:He,47:qe,63:Xe,92:Qe,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt}),e(X,[2,142],{123:181,11:[1,315],15:He,47:qe,63:Xe,92:Qe,108:Ze,109:$e,112:et,114:tt,117:it,118:rt,119:nt}),e(X,[2,129]),{32:[1,316],70:B,85:237,119:y,120:w,121:N},{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,317],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},e(ut,o,{5:318}),e(V,[2,45]),{11:Te,63:De,87:_e,95:319,108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},{11:Te,63:De,87:_e,95:320,108:ve,110:263,111:264,112:Fe,113:Ve,114:Ie,115:Le},e(oe,[2,75]),e(V,[2,38]),{6:13,7:14,8:f,9:m,10:k,11:A,12:C,21:20,23:21,24:22,25:23,26:24,27:25,28:L,33:[1,321],35:_,36:U,37:29,38:F,40:E,42:g,45:33,46:44,47:b,48:45,50:46,63:v,87:q,88:fe,89:Se,90:Ee,91:xe,92:Q,105:J,108:Z,109:ee,112:te,114:se,116:47,117:ie,118:re,119:ne,124:Ne,125:Re,126:Oe,127:Pe,128:Ge},e(X,[2,139],{109:ht}),e(X,[2,140],{109:ht}),e(V,[2,39])],defaultActions:{},parseError:t(function(S,T){if(T.recoverable)this.trace(S);else{var D=Error(S);throw D.hash=T,D}},"parseError"),parse:t(function(S){var T=this,D=[0],u=[],K=[null],s=[],I=this.table,i="",Y=0,f1=0,g1=0,I1=2,b1=1,L1=s.slice.call(arguments,1),ae=Object.create(this.lexer),je={yy:{}};for(var Zt in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,Zt))je.yy[Zt]=this.yy[Zt];if(ae.setInput(S,je.yy),je.yy.lexer=ae,je.yy.parser=this,typeof ae.yylloc>"u")ae.yylloc={};var $t=ae.yylloc;s.push($t);var B1=ae.options&&ae.options.ranges;if(typeof je.yy.parseError==="function")this.parseError=je.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function M1(Ae){D.length=D.length-2*Ae,K.length=K.length-Ae,s.length=s.length-Ae}t(M1,"popStack");function k1(){var Ae=u.pop()||ae.lex()||b1;if(typeof Ae!=="number"){if(Ae instanceof Array)u=Ae,Ae=u.pop();Ae=T.symbols_[Ae]||Ae}return Ae}t(k1,"lex");var ge,e1,ze,me,Q1,t1,pt={},Ht,Be,m1,Yt;while(!0){if(ze=D[D.length-1],this.defaultActions[ze])me=this.defaultActions[ze];else{if(ge===null||typeof ge>"u")ge=k1();me=I[ze]&&I[ze][ge]}if(typeof me>"u"||!me.length||!me[0]){var s1="";Yt=[];for(Ht in I[ze])if(this.terminals_[Ht]&&Ht>I1)Yt.push("'"+this.terminals_[Ht]+"'");if(ae.showPosition)s1="Parse error on line "+(Y+1)+`:
|
|
23
|
+
`+ae.showPosition()+`
|
|
24
|
+
Expecting `+Yt.join(", ")+", got '"+(this.terminals_[ge]||ge)+"'";else s1="Parse error on line "+(Y+1)+": Unexpected "+(ge==b1?"end of input":"'"+(this.terminals_[ge]||ge)+"'");this.parseError(s1,{text:ae.match,token:this.terminals_[ge]||ge,line:ae.yylineno,loc:$t,expected:Yt})}if(me[0]instanceof Array&&me.length>1)throw Error("Parse Error: multiple actions possible at state: "+ze+", token: "+ge);switch(me[0]){case 1:if(D.push(ge),K.push(ae.yytext),s.push(ae.yylloc),D.push(me[1]),ge=null,!e1){if(f1=ae.yyleng,i=ae.yytext,Y=ae.yylineno,$t=ae.yylloc,g1>0)g1--}else ge=e1,e1=null;break;case 2:if(Be=this.productions_[me[1]][1],pt.$=K[K.length-Be],pt._$={first_line:s[s.length-(Be||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(Be||1)].first_column,last_column:s[s.length-1].last_column},B1)pt._$.range=[s[s.length-(Be||1)].range[0],s[s.length-1].range[1]];if(t1=this.performAction.apply(pt,[i,f1,Y,je.yy,me[1],K,s].concat(L1)),typeof t1<"u")return t1;if(Be)D=D.slice(0,-1*Be*2),K=K.slice(0,-1*Be),s=s.slice(0,-1*Be);D.push(this.productions_[me[1]][0]),K.push(pt.$),s.push(pt._$),m1=I[D[D.length-2]][D[D.length-1]],D.push(m1);break;case 3:return!0}}return!0},"parse")},V1=function(){var we={EOF:1,parseError:t(function(T,D){if(this.yy.parser)this.yy.parser.parseError(T,D);else throw Error(T)},"parseError"),setInput:t(function(S,T){if(this.yy=T||this.yy||{},this._input=S,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:t(function(){var S=this._input[0];this.yytext+=S,this.yyleng++,this.offset++,this.match+=S,this.matched+=S;var T=S.match(/(?:\r\n?|\n).*/g);if(T)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),S},"input"),unput:t(function(S){var T=S.length,D=S.split(/(?:\r\n?|\n)/g);this._input=S+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-T),this.offset-=T;var u=this.match.split(/(?:\r\n?|\n)/g);if(this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),D.length-1)this.yylineno-=D.length-1;var K=this.yylloc.range;if(this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:D?(D.length===u.length?this.yylloc.first_column:0)+u[u.length-D.length].length-D[0].length:this.yylloc.first_column-T},this.options.ranges)this.yylloc.range=[K[0],K[0]+this.yyleng-T];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
25
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:t(function(S){this.unput(this.match.slice(S))},"less"),pastInput:t(function(){var S=this.matched.substr(0,this.matched.length-this.match.length);return(S.length>20?"...":"")+S.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:t(function(){var S=this.match;if(S.length<20)S+=this._input.substr(0,20-S.length);return(S.substr(0,20)+(S.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:t(function(){var S=this.pastInput(),T=Array(S.length+1).join("-");return S+this.upcomingInput()+`
|
|
26
|
+
`+T+"^"},"showPosition"),test_match:t(function(S,T){var D,u,K;if(this.options.backtrack_lexer){if(K={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges)K.yylloc.range=this.yylloc.range.slice(0)}if(u=S[0].match(/(?:\r\n?|\n).*/g),u)this.yylineno+=u.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:u?u[u.length-1].length-u[u.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+S[0].length},this.yytext+=S[0],this.match+=S[0],this.matches=S,this.yyleng=this.yytext.length,this.options.ranges)this.yylloc.range=[this.offset,this.offset+=this.yyleng];if(this._more=!1,this._backtrack=!1,this._input=this._input.slice(S[0].length),this.matched+=S[0],D=this.performAction.call(this,this.yy,this,T,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(D)return D;else if(this._backtrack){for(var s in K)this[s]=K[s];return!1}return!1},"test_match"),next:t(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var S,T,D,u;if(!this._more)this.yytext="",this.match="";var K=this._currentRules();for(var s=0;s<K.length;s++)if(D=this._input.match(this.rules[K[s]]),D&&(!T||D[0].length>T[0].length)){if(T=D,u=s,this.options.backtrack_lexer)if(S=this.test_match(D,K[s]),S!==!1)return S;else if(this._backtrack){T=!1;continue}else return!1;else if(!this.options.flex)break}if(T){if(S=this.test_match(T,K[u]),S!==!1)return S;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
27
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:t(function(){var T=this.next();if(T)return T;else return this.lex()},"lex"),begin:t(function(T){this.conditionStack.push(T)},"begin"),popState:t(function(){var T=this.conditionStack.length-1;if(T>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:t(function(T){if(T=this.conditionStack.length-1-Math.abs(T||0),T>=0)return this.conditionStack[T];else return"INITIAL"},"topState"),pushState:t(function(T){this.begin(T)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:t(function(T,D,u,K){var s=K;switch(u){case 0:return this.begin("acc_title"),38;break;case 1:return this.popState(),"acc_title_value";break;case 2:return this.begin("acc_descr"),40;break;case 3:return this.popState(),"acc_descr_value";break;case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return this.pushState("shapeData"),D.yytext="",43;break;case 8:return this.pushState("shapeDataStr"),43;break;case 9:return this.popState(),43;break;case 10:let I=/\n\s*/g;return D.yytext=D.yytext.replace(I,"<br/>"),43;break;case 11:return 43;case 12:this.popState();break;case 13:this.begin("callbackname");break;case 14:this.popState();break;case 15:this.popState(),this.begin("callbackargs");break;case 16:return 98;case 17:this.popState();break;case 18:return 99;case 19:return"MD_STR";case 20:this.popState();break;case 21:this.begin("md_string");break;case 22:return"STR";case 23:this.popState();break;case 24:this.pushState("string");break;case 25:return 87;case 26:return 105;case 27:return 88;case 28:return 107;case 29:return 89;case 30:return 90;case 31:return 100;case 32:this.begin("click");break;case 33:this.popState();break;case 34:return 91;case 35:if(T.lex.firstGraph())this.begin("dir");return 13;case 36:return 28;case 37:return 36;case 38:return 35;case 39:return 33;case 40:return 101;case 41:return 101;case 42:return 101;case 43:return 101;case 44:return this.popState(),14;break;case 45:return this.popState(),15;break;case 46:return this.popState(),15;break;case 47:return this.popState(),15;break;case 48:return this.popState(),15;break;case 49:return this.popState(),15;break;case 50:return this.popState(),15;break;case 51:return this.popState(),15;break;case 52:return this.popState(),15;break;case 53:return this.popState(),15;break;case 54:return this.popState(),15;break;case 55:return 124;case 56:return 125;case 57:return 126;case 58:return 127;case 59:return 128;case 60:return 81;case 61:return 108;case 62:return 114;case 63:return 49;case 64:return 63;case 65:return 47;case 66:return 9;case 67:return 109;case 68:return 118;case 69:return this.popState(),80;break;case 70:return this.pushState("edgeText"),78;break;case 71:return 122;case 72:return 80;case 73:break;case 74:return this.popState(),56;break;case 75:return"TEXT";case 76:return this.pushState("ellipseText"),55;break;case 77:return this.popState(),58;break;case 78:return this.pushState("text"),57;break;case 79:return this.popState(),60;break;case 80:return this.pushState("text"),59;break;case 81:return 61;case 82:return this.pushState("text"),70;break;case 83:return this.popState(),67;break;case 84:return this.pushState("text"),66;break;case 85:return this.popState(),52;break;case 86:return this.pushState("text"),51;break;case 87:break;case 88:return this.popState(),72;break;case 89:return this.popState(),74;break;case 90:return 120;case 91:return this.pushState("trapText"),71;break;case 92:return this.pushState("trapText"),73;break;case 93:return 121;case 94:return 70;case 95:return 93;case 96:return"SEP";case 97:return 92;case 98:return 118;case 99:return 114;case 100:return 47;case 101:return 8;case 102:return 112;case 103:return 117;case 104:return 119;case 105:return this.popState(),65;break;case 106:return this.pushState("text"),65;break;case 107:return this.popState(),54;break;case 108:return this.pushState("text"),53;break;case 109:return this.popState(),32;break;case 110:return this.pushState("text"),30;break;case 111:return this.popState(),69;break;case 112:return this.pushState("text"),68;break;case 113:break;case 114:return"TEXT";case 115:return"QUOTE";case 116:return 10;case 117:return 11;case 118:return 12}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:agentflow-beta\b)/,/^(?:flow\b)/,/^(?:connector\b)/,/^(?:global\b[ \t]*)/,/^(?:end\b[ \t]*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*--+[x>]\s*)/,/^(?:\s*--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*-\.+-\s*)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|(?:[^\\\[\]\(\)\{\}\/%]+|(?!))+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:[ \t]*%%(?!\{)[^\n]*)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:%%(?!\{)[^\n]*)/,/^(?:(?:[^\[\]\(\)\{\}\|\"%]+|(?!))+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},shapeData:{rules:[8,11,12,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackargs:{rules:[17,18,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},callbackname:{rules:[14,15,16,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},href:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},click:{rules:[21,24,33,34,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},edgeText:{rules:[21,24,69,71,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},trapText:{rules:[21,24,76,78,80,84,86,87,88,89,90,91,92,106,108,110,112],inclusive:!1},ellipseText:{rules:[21,24,73,74,75,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},text:{rules:[21,24,76,77,78,79,80,83,84,85,86,91,92,105,106,107,108,109,110,111,112,113,114],inclusive:!1},vertex:{rules:[21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_descr:{rules:[3,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},acc_title:{rules:[1,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},md_string:{rules:[19,20,21,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},string:{rules:[21,22,23,24,76,78,80,84,86,91,92,106,108,110,112],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,72,76,78,80,81,82,84,86,91,92,93,94,95,96,97,98,99,100,101,102,103,104,106,108,110,112,115,116,117,118],inclusive:!0}}};return we}();Jt.lexer=V1;function Kt(){this.yy={}}return t(Kt,"Parser"),Kt.prototype=Jt,Jt.Parser=Kt,new Kt}();r1.parser=r1;var v1=r1,F1=Object.assign({},v1);F1.parse=(e)=>{let r=e.replace(/}[^\S\n]*\n/g,`}
|
|
28
|
+
`);return v1.parse(r)};var K1=F1,H1=t((e)=>{let{theme:r,bkgColorArray:n,borderColorArray:a}=e;if(!Ye(r,a))return"";let c=Je(e.look),d=st(n),o=zn(e.THEME_COLOR_LIMIT,a),f=t((A)=>a[A%a.length],"border"),m=t((A)=>d?`fill: ${n[A%n.length]};`:"","fill"),k="";for(let A of O1){let C=Xt.get(A),L=`[data-look="${c}"].node.${S1(A)}`;k+=`
|
|
29
|
+
|
|
30
|
+
${L} rect,
|
|
31
|
+
${L} path,
|
|
32
|
+
${L} polygon {
|
|
33
|
+
stroke: ${f(C)};
|
|
34
|
+
${m(C)}
|
|
35
|
+
}
|
|
36
|
+
`}for(let A=0;A<x1(o);A++){let C=T1(A,o),L=`[data-look="${c}"][data-color-id="color-${C}"].cluster`,_=`[data-look="${c}"][data-color-id="color-${C}"].node`,U=t((F)=>`${L} ${F}, ${_} ${F}`,"rule");k+=`
|
|
37
|
+
|
|
38
|
+
${U("rect")},
|
|
39
|
+
${U("path")} {
|
|
40
|
+
stroke: ${f(C)};
|
|
41
|
+
${m(C)}
|
|
42
|
+
}
|
|
43
|
+
`}return k},"genColor"),Y1=t((e,r)=>{let n=ra,a=n(e,"r"),c=n(e,"g"),d=n(e,"b");return ot(a,c,d,r)},"fade"),q1=t((e)=>`${H1(e)}
|
|
44
|
+
.label {
|
|
45
|
+
font-family: ${e.fontFamily};
|
|
46
|
+
color: ${e.nodeTextColor||e.textColor};
|
|
47
|
+
}
|
|
48
|
+
.cluster-label text {
|
|
49
|
+
fill: ${e.titleColor};
|
|
50
|
+
}
|
|
51
|
+
.cluster-label span {
|
|
52
|
+
color: ${e.titleColor};
|
|
53
|
+
}
|
|
54
|
+
.cluster-label span p {
|
|
55
|
+
background-color: transparent;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.label text,span {
|
|
59
|
+
fill: ${e.nodeTextColor||e.textColor};
|
|
60
|
+
color: ${e.nodeTextColor||e.textColor};
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.node rect,
|
|
64
|
+
.node circle,
|
|
65
|
+
.node ellipse,
|
|
66
|
+
.node polygon,
|
|
67
|
+
.node path {
|
|
68
|
+
fill: ${e.mainBkg};
|
|
69
|
+
stroke: ${e.nodeBorder};
|
|
70
|
+
stroke-width: ${e.strokeWidth??1}px;
|
|
71
|
+
}
|
|
72
|
+
.rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label {
|
|
73
|
+
text-anchor: middle;
|
|
74
|
+
}
|
|
75
|
+
.node .katex path {
|
|
76
|
+
fill: ${e.nodeTextColor||e.textColor};
|
|
77
|
+
stroke: ${e.nodeTextColor||e.textColor};
|
|
78
|
+
stroke-width: 1px;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.rough-node .label,.node .label, .image-shape .label, .icon-shape .label {
|
|
82
|
+
text-align: center;
|
|
83
|
+
}
|
|
84
|
+
.node.clickable {
|
|
85
|
+
cursor: pointer;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
.root .anchor path {
|
|
90
|
+
fill: ${e.lineColor} !important;
|
|
91
|
+
stroke-width: 0;
|
|
92
|
+
stroke: ${e.lineColor};
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.arrowheadPath {
|
|
96
|
+
fill: ${e.arrowheadColor};
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.edgePaths .path {
|
|
100
|
+
stroke: ${e.lineColor};
|
|
101
|
+
stroke-width: ${e.strokeWidth??2}px;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.flowchart-link {
|
|
105
|
+
stroke: ${e.lineColor};
|
|
106
|
+
fill: none;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.edgeLabel {
|
|
110
|
+
background-color: ${e.edgeLabelBackground};
|
|
111
|
+
p {
|
|
112
|
+
background-color: ${e.edgeLabelBackground};
|
|
113
|
+
}
|
|
114
|
+
rect {
|
|
115
|
+
opacity: 0.5;
|
|
116
|
+
background-color: ${e.edgeLabelBackground};
|
|
117
|
+
fill: ${e.edgeLabelBackground};
|
|
118
|
+
}
|
|
119
|
+
text-align: center;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/* For html labels only */
|
|
123
|
+
.labelBkg {
|
|
124
|
+
background-color: ${Y1(e.edgeLabelBackground,0.5)};
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.cluster rect {
|
|
128
|
+
fill: ${e.clusterBkg};
|
|
129
|
+
stroke: ${e.clusterBorder};
|
|
130
|
+
stroke-width: 1px;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.flow-cluster rect {
|
|
134
|
+
fill: none;
|
|
135
|
+
stroke: ${e.clusterBorder};
|
|
136
|
+
stroke-width: 0.75px;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.node .collapsed-indicator {
|
|
140
|
+
fill: ${e.nodeBorder};
|
|
141
|
+
stroke: none;
|
|
142
|
+
stroke-width: 0;
|
|
143
|
+
opacity: 0.5;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.node .collapsed-separator {
|
|
147
|
+
stroke-width: 0.75px;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.cluster text {
|
|
151
|
+
fill: ${e.titleColor};
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.cluster span {
|
|
155
|
+
color: ${e.titleColor};
|
|
156
|
+
}
|
|
157
|
+
/* .cluster div {
|
|
158
|
+
color: ${e.titleColor};
|
|
159
|
+
} */
|
|
160
|
+
|
|
161
|
+
div.mermaidTooltip {
|
|
162
|
+
position: absolute;
|
|
163
|
+
text-align: center;
|
|
164
|
+
max-width: 200px;
|
|
165
|
+
padding: 2px;
|
|
166
|
+
font-family: ${e.fontFamily};
|
|
167
|
+
font-size: 12px;
|
|
168
|
+
background: ${e.tertiaryColor};
|
|
169
|
+
border: 1px solid ${e.border2};
|
|
170
|
+
border-radius: 2px;
|
|
171
|
+
pointer-events: none;
|
|
172
|
+
z-index: 100;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
.agentflowTitleText {
|
|
176
|
+
text-anchor: middle;
|
|
177
|
+
font-size: 18px;
|
|
178
|
+
fill: ${e.textColor};
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
rect.text {
|
|
182
|
+
fill: none;
|
|
183
|
+
stroke-width: 0;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.icon-shape, .image-shape {
|
|
187
|
+
background-color: ${e.edgeLabelBackground};
|
|
188
|
+
p {
|
|
189
|
+
background-color: ${e.edgeLabelBackground};
|
|
190
|
+
padding: 2px;
|
|
191
|
+
}
|
|
192
|
+
.label rect {
|
|
193
|
+
opacity: 0.5;
|
|
194
|
+
background-color: ${e.edgeLabelBackground};
|
|
195
|
+
fill: ${e.edgeLabelBackground};
|
|
196
|
+
}
|
|
197
|
+
text-align: center;
|
|
198
|
+
}
|
|
199
|
+
${xn()}
|
|
200
|
+
`,"getStyles"),X1=q1,Es={parser:K1,get db(){return new U1},renderer:W1,styles:X1,init:t((e)=>{if(e.agentflow??={},e.layout)aa({layout:e.layout});e.flowchart??={},e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,aa({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}})},"init")};export{Es as diagram};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import{be}from"./index-123e8tqq.js";import{t,l,Mt,K,E,te,R,M,O,P,z,j,G,h,On,ue,gu,N,ae,lt}from"./index-qmh0h87h.js";import{Wa}from"./index-e6rar25v.js";import{Te}from"./index-tr8754r0.js";function Ge(e){var r=0,n=e.children,o=n&&n.length;if(!o)r=1;else while(--o>=0)r+=n[o].value;e.value=r}function fe(){return this.eachAfter(Ge)}function he(e,r){let n=-1;for(let o of this)e.call(r,o,++n,this);return this}function me(e,r){var n=this,o=[n],s,p,u=-1;while(n=o.pop())if(e.call(r,n,++u,this),s=n.children)for(p=s.length-1;p>=0;--p)o.push(s[p]);return this}function ge(e,r){var n=this,o=[n],s=[],p,u,f,S=-1;while(n=o.pop())if(s.push(n),p=n.children)for(u=0,f=p.length;u<f;++u)o.push(p[u]);while(n=s.pop())e.call(r,n,++S,this);return this}function ye(e,r){let n=-1;for(let o of this)if(e.call(r,o,++n,this))return o}function xe(e){return this.eachAfter(function(r){var n=+e(r.data)||0,o=r.children,s=o&&o.length;while(--s>=0)n+=o[s].value;r.value=n})}function Se(e){return this.eachBefore(function(r){if(r.children)r.children.sort(e)})}function ve(e){var r=this,n=Xe(r,e),o=[r];while(r!==n)r=r.parent,o.push(r);var s=o.length;while(e!==n)o.splice(s,0,e),e=e.parent;return o}function Xe(e,r){if(e===r)return e;var n=e.ancestors(),o=r.ancestors(),s=null;e=n.pop(),r=o.pop();while(e===r)s=e,e=n.pop(),r=o.pop();return s}function we(){var e=this,r=[e];while(e=e.parent)r.push(e);return r}function Ce(){return Array.from(this)}function Le(){var e=[];return this.eachBefore(function(r){if(!r.children)e.push(r)}),e}function $e(){var e=this,r=[];return e.each(function(n){if(n!==e)r.push({source:n.parent,target:n})}),r}function*Ae(){var e=this,r,n=[e],o,s,p;do{r=n.reverse(),n=[];while(e=r.pop())if(yield e,o=e.children)for(s=0,p=o.length;s<p;++s)n.push(o[s])}while(n.length)}function J(e,r){if(e instanceof Map){if(e=[void 0,e],r===void 0)r=Ze}else if(r===void 0)r=je;var n=new le(e),o,s=[n],p,u,f,S;while(o=s.pop())if((u=r(o.data))&&(S=(u=Array.from(u)).length)){o.children=u;for(f=S-1;f>=0;--f)s.push(p=u[f]=new le(u[f])),p.parent=o,p.depth=o.depth+1}return n.eachBefore(Je)}function Ye(){return J(this).eachBefore(Ue)}function je(e){return e.children}function Ze(e){return Array.isArray(e)?e[1]:null}function Ue(e){if(e.data.value!==void 0)e.value=e.data.value;e.data=e.data.data}function Je(e){var r=0;do e.height=r;while((e=e.parent)&&e.height<++r)}function le(e){this.data=e,this.depth=this.height=0,this.parent=null}le.prototype=J.prototype={constructor:le,count:fe,each:he,eachAfter:ge,eachBefore:me,find:ye,sum:xe,sort:Se,path:ve,ancestors:we,descendants:Ce,leaves:Le,links:$e,copy:Ye,[Symbol.iterator]:Ae};function Ve(e){if(typeof e!=="function")throw Error();return e}function Q(){return 0}function X(e){return function(){return e}}function Fe(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function Ne(e,r,n,o,s){var p=e.children,u,f=-1,S=p.length,d=e.value&&(o-r)/e.value;while(++f<S)u=p[f],u.y0=n,u.y1=s,u.x0=r,u.x1=r+=u.value*d}function ke(e,r,n,o,s){var p=e.children,u,f=-1,S=p.length,d=e.value&&(s-n)/e.value;while(++f<S)u=p[f],u.x0=r,u.x1=o,u.y0=n,u.y1=n+=u.value*d}var Ke=(1+Math.sqrt(5))/2;function Qe(e,r,n,o,s,p){var u=[],f=r.children,S,d,m=0,T=0,i=f.length,C,b,w=r.value,g,v,B,D,Y,re,W;while(m<i){C=s-n,b=p-o;do g=f[T++].value;while(!g&&T<i);v=B=g,re=Math.max(b/C,C/b)/(w*e),W=g*g*re,Y=Math.max(B/W,W/v);for(;T<i;++T){if(g+=d=f[T].value,d<v)v=d;if(d>B)B=d;if(W=g*g*re,D=Math.max(B/W,W/v),D>Y){g-=d;break}Y=D}if(u.push(S={value:g,dice:C<b,children:f.slice(m,T)}),S.dice)Ne(S,n,o,s,w?o+=b*g/w:p);else ke(S,n,o,w?n+=C*g/w:s,p);w-=g,m=T}return u}var Pe=function e(r){function n(o,s,p,u,f){Qe(r,o,s,p,u,f)}return n.ratio=function(o){return e((o=+o)>1?o:1)},n}(Ke);function ce(){var e=Pe,r=!1,n=1,o=1,s=[0],p=Q,u=Q,f=Q,S=Q,d=Q;function m(i){if(i.x0=i.y0=0,i.x1=n,i.y1=o,i.eachBefore(T),s=[0],r)i.eachBefore(Fe);return i}function T(i){var C=s[i.depth],b=i.x0+C,w=i.y0+C,g=i.x1-C,v=i.y1-C;if(g<b)b=g=(b+g)/2;if(v<w)w=v=(w+v)/2;if(i.x0=b,i.y0=w,i.x1=g,i.y1=v,i.children){if(C=s[i.depth+1]=p(i)/2,b+=d(i)-C,w+=u(i)-C,g-=f(i)-C,v-=S(i)-C,g<b)b=g=(b+g)/2;if(v<w)w=v=(w+v)/2;e(i,b,w,g,v)}}return m.round=function(i){return arguments.length?(r=!!i,m):r},m.size=function(i){return arguments.length?(n=+i[0],o=+i[1],m):[n,o]},m.tile=function(i){return arguments.length?(e=Ve(i),m):e},m.padding=function(i){return arguments.length?m.paddingInner(i).paddingOuter(i):m.paddingInner()},m.paddingInner=function(i){return arguments.length?(p=typeof i==="function"?i:X(+i),m):p},m.paddingOuter=function(i){return arguments.length?m.paddingTop(i).paddingRight(i).paddingBottom(i).paddingLeft(i):m.paddingTop()},m.paddingTop=function(i){return arguments.length?(u=typeof i==="function"?i:X(+i),m):u},m.paddingRight=function(i){return arguments.length?(f=typeof i==="function"?i:X(+i),m):f},m.paddingBottom=function(i){return arguments.length?(S=typeof i==="function"?i:X(+i),m):S},m.paddingLeft=function(i){return arguments.length?(d=typeof i==="function"?i:X(+i),m):d},m}var Be=class{constructor(){this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.setAccTitle=M,this.getAccTitle=O,this.setDiagramTitle=j,this.getDiagramTitle=G,this.getAccDescription=z,this.setAccDescription=P}static{t(this,"TreeMapDB")}getNodes(){return this.nodes}getConfig(){let e=K,r=E();return ae({...e.treemap,...r.treemap??{}})}addNode(e,r){if(this.nodes.push(e),this.levels.set(e,r),r===0)this.outerNodes.push(e),this.root??=e}getRoot(){return{name:"",children:this.outerNodes}}addClass(e,r){let n=this.classes.get(e)??{id:e,styles:[],textStyles:[]},o=r.replace(/\\,/g,"§§§").replace(/,/g,";").replace(/§§§/g,",").split(";");if(o)o.forEach((s)=>{if(gu(s))if(n?.textStyles)n.textStyles.push(s);else n.textStyles=[s];if(n?.styles)n.styles.push(s);else n.styles=[s]});this.classes.set(e,n)}getClasses(){return this.classes}getStylesForClass(e){return this.classes.get(e)?.styles??[]}clear(){R(),this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.root=void 0}};function Ee(e){if(!e.length)return[];let r=[],n=[];return e.forEach((o)=>{let s={name:o.name,children:o.type==="Leaf"?void 0:[]};if(s.classSelector=o?.classSelector,o?.cssCompiledStyles)s.cssCompiledStyles=o.cssCompiledStyles;if(o.type==="Leaf"&&o.value!==void 0)s.value=o.value;while(n.length>0&&n[n.length-1].level>=o.level)n.pop();if(n.length===0)r.push(s);else{let p=n[n.length-1].node;if(p.children)p.children.push(s);else p.children=[s]}if(o.type!=="Leaf")n.push({node:s,level:o.level})}),r}t(Ee,"buildHierarchy");var et=t((e,r)=>{be(e,r);let n=[];for(let p of e.TreemapRows??[])if(p.$type==="ClassDefStatement")r.addClass(p.className??"",p.styleText??"");for(let p of e.TreemapRows??[]){let u=p.item;if(!u)continue;let f=p.indent?parseInt(p.indent):0,S=tt(u),d=u.classSelector?r.getStylesForClass(u.classSelector):[],m=d.length>0?d:void 0,T={level:f,name:S,type:u.$type,value:u.value,classSelector:u.classSelector,cssCompiledStyles:m};n.push(T)}let o=Ee(n),s=t((p,u)=>{for(let f of p)if(r.addNode(f,u),f.children&&f.children.length>0)s(f.children,u+1)},"addNodesRecursively");s(o,0)},"populate"),tt=t((e)=>e.name?String(e.name):"","getItemName"),Re={parser:{yy:void 0},parse:t(async(e)=>{try{let n=await Te("treemap",e);l.debug("Treemap AST:",n);let o=Re.parser?.yy;if(!(o instanceof Be))throw Error("parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");et(n,o)}catch(r){throw l.error("Error parsing treemap:",r),r}},"parse")},at=10,ee=10,oe=25,rt=t((e,r,n,o)=>{let s=o.db,p=s.getConfig(),u=p.padding??at,f=s.getDiagramTitle(),S=s.getRoot(),{themeVariables:d}=E();if(!S)return;let m=f?30:0,T=ue(r),i=p.nodeWidth?p.nodeWidth*ee:960,C=p.nodeHeight?p.nodeHeight*ee:500,b=i,w=C+m;T.attr("viewBox",`0 0 ${b} ${w}`),te(T,w,b,p.useMaxWidth);let g;try{let a=p.valueFormat||",";if(a==="$0,0")g=t((c)=>"$"+Wa(",")(c),"valueFormat");else if(a.startsWith("$")&&a.includes(",")){let c=/\.\d+/.exec(a),y=c?c[0]:"";g=t((L)=>"$"+Wa(","+y)(L),"valueFormat")}else if(a.startsWith("$")){let c=a.substring(1);g=t((y)=>"$"+Wa(c||"")(y),"valueFormat")}else g=Wa(a)}catch(a){l.error("Error creating format function:",a),g=Wa(",")}let v=On().range(["transparent",d.cScale0,d.cScale1,d.cScale2,d.cScale3,d.cScale4,d.cScale5,d.cScale6,d.cScale7,d.cScale8,d.cScale9,d.cScale10,d.cScale11]),B=On().range(["transparent",d.cScalePeer0,d.cScalePeer1,d.cScalePeer2,d.cScalePeer3,d.cScalePeer4,d.cScalePeer5,d.cScalePeer6,d.cScalePeer7,d.cScalePeer8,d.cScalePeer9,d.cScalePeer10,d.cScalePeer11]),D=On().range([d.cScaleLabel0,d.cScaleLabel1,d.cScaleLabel2,d.cScaleLabel3,d.cScaleLabel4,d.cScaleLabel5,d.cScaleLabel6,d.cScaleLabel7,d.cScaleLabel8,d.cScaleLabel9,d.cScaleLabel10,d.cScaleLabel11]);if(f)T.append("text").attr("x",b/2).attr("y",m/2).attr("class","treemapTitle").attr("text-anchor","middle").attr("dominant-baseline","middle").text(f);let Y=T.append("g").attr("transform",`translate(0, ${m})`).attr("class","treemapContainer"),re=J(S).sum((a)=>a.value??0).sort((a,c)=>(c.value??0)-(a.value??0)),Me=ce().size([i,C]).paddingTop((a)=>a.children&&a.children.length>0?oe+ee:0).paddingInner(u).paddingLeft((a)=>a.children&&a.children.length>0?ee:0).paddingRight((a)=>a.children&&a.children.length>0?ee:0).paddingBottom((a)=>a.children&&a.children.length>0?ee:0).round(!0)(re),We=Me.descendants().filter((a)=>a.children&&a.children.length>0),ne=Y.selectAll(".treemapSection").data(We).enter().append("g").attr("class","treemapSection").attr("transform",(a)=>`translate(${a.x0},${a.y0})`);if(ne.append("rect").attr("width",(a)=>a.x1-a.x0).attr("height",oe).attr("class","treemapSectionHeader").attr("fill","none").attr("fill-opacity",0.6).attr("stroke-width",0.6).attr("style",(a)=>{if(a.depth===0)return"display: none;";return""}),ne.append("clipPath").attr("id",(a,c)=>`clip-section-${r}-${c}`).append("rect").attr("width",(a)=>Math.max(0,a.x1-a.x0-12)).attr("height",oe),ne.append("rect").attr("width",(a)=>a.x1-a.x0).attr("height",(a)=>a.y1-a.y0).attr("class",(a,c)=>`treemapSection section${c}`).attr("fill",(a)=>v(a.data.name)).attr("fill-opacity",0.6).attr("stroke",(a)=>B(a.data.name)).attr("stroke-width",2).attr("stroke-opacity",0.4).attr("style",(a)=>{if(a.depth===0)return"display: none;";let c=N({cssCompiledStyles:a.data.cssCompiledStyles});return c.nodeStyles+";"+c.borderStyles.join(";")}),ne.append("text").attr("class","treemapSectionLabel").attr("x",6).attr("y",oe/2).attr("dominant-baseline","middle").text((a)=>a.depth===0?"":a.data.name).attr("font-weight","bold").attr("clip-path",(a,c)=>`url(#clip-section-${r}-${c})`).attr("style",(a)=>{if(a.depth===0)return"display: none;";let c="dominant-baseline: middle; font-size: 12px; fill:"+D(a.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;",y=N({cssCompiledStyles:a.data.cssCompiledStyles});return c+y.labelStyles.replace("color:","fill:")}).each(function(a){if(a.depth===0)return;let c=h(this),y=a.data.name;c.text(y);let L=a.x1-a.x0,F=6,A;if(p.showValues!==!1&&a.value){let _=L-10,q=30,Oe=10;A=_-30-10-F}else A=L-F-6;let x=Math.max(15,A),I=c.node();if(I.getComputedTextLength()>x){let q=y;while(q.length>0){if(q=y.substring(0,q.length-1),q.length===0){if(c.text("..."),I.getComputedTextLength()>x)c.text("");break}if(c.text(q+"..."),I.getComputedTextLength()<=x)break}}}),p.showValues!==!1)ne.append("text").attr("class","treemapSectionValue").attr("x",(a)=>a.x1-a.x0-10).attr("y",oe/2).attr("text-anchor","end").attr("dominant-baseline","middle").text((a)=>a.value?g(a.value):"").attr("font-style","italic").attr("style",(a)=>{if(a.depth===0)return"display: none;";let c="text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:"+D(a.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;",y=N({cssCompiledStyles:a.data.cssCompiledStyles});return c+y.labelStyles.replace("color:","fill:")});let _e=Me.leaves(),V=_e.length>20,He=V?16:38,se=V?14:28,Z=V?4:8,U=V?4:6,pe=V?2:4,ze=V?8:10,de=V?1:2,ie=Y.selectAll(".treemapLeafGroup").data(_e).enter().append("g").attr("class",(a,c)=>`treemapNode treemapLeafGroup leaf${c}${a.data.classSelector?` ${a.data.classSelector}`:""}x`).attr("transform",(a)=>`translate(${a.x0},${a.y0})`);if(ie.append("rect").attr("width",(a)=>a.x1-a.x0).attr("height",(a)=>a.y1-a.y0).attr("class","treemapLeaf").attr("fill",(a)=>a.parent?v(a.parent.data.name):v(a.data.name)).attr("style",(a)=>N({cssCompiledStyles:a.data.cssCompiledStyles}).nodeStyles).attr("fill-opacity",0.3).attr("stroke",(a)=>a.parent?v(a.parent.data.name):v(a.data.name)).attr("stroke-width",3),ie.append("clipPath").attr("id",(a,c)=>`clip-${r}-${c}`).append("rect").attr("width",(a)=>Math.max(0,a.x1-a.x0-4)).attr("height",(a)=>Math.max(0,a.y1-a.y0-4)),ie.append("text").attr("class","treemapLabel").attr("x",(a)=>(a.x1-a.x0)/2).attr("y",(a)=>(a.y1-a.y0)/2).attr("style",(a)=>{let c=`text-anchor: middle; dominant-baseline: middle; font-size: ${He}px;fill:`+D(a.data.name)+";",y=N({cssCompiledStyles:a.data.cssCompiledStyles});return c+y.labelStyles.replace("color:","fill:")}).attr("clip-path",(a,c)=>`url(#clip-${r}-${c})`).text((a)=>a.data.name).each(function(a){let c=h(this),y=a.x1-a.x0,L=a.y1-a.y0,F=c.node(),A=y-2*pe,H=L-2*pe;if(A<ze||H<ze){c.style("display","none");return}let x=parseInt(c.style("font-size"),10),I=0.6;while(F.getComputedTextLength()>A&&x>Z)x--,c.style("font-size",`${x}px`);let k=Math.max(U,Math.min(se,Math.round(x*I))),_=x+de+k;while(_>H&&x>Z){if(x--,k=Math.max(U,Math.min(se,Math.round(x*I))),k<U&&x===Z)break;if(c.style("font-size",`${x}px`),_=x+de+k,k<=U&&_>H);}if(c.style("font-size",`${x}px`),V){if(x<Z||H<Z)c.style("display","none")}else if(F.getComputedTextLength()>A||x<Z||H<x)c.style("display","none")}),p.showValues!==!1)ie.append("text").attr("class","treemapValue").attr("x",(c)=>(c.x1-c.x0)/2).attr("y",function(c){return(c.y1-c.y0)/2}).attr("style",(c)=>{let y=`text-anchor: middle; dominant-baseline: hanging; font-size: ${se}px;fill:`+D(c.data.name)+";",L=N({cssCompiledStyles:c.data.cssCompiledStyles});return y+L.labelStyles.replace("color:","fill:")}).attr("clip-path",(c,y)=>`url(#clip-${r}-${y})`).text((c)=>c.value?g(c.value):"").each(function(c){let y=h(this),L=this.parentNode;if(!L){y.style("display","none");return}let F=h(L).select(".treemapLabel");if(F.empty()||F.style("display")==="none"){y.style("display","none");return}let A=parseFloat(F.style("font-size")),x=Math.max(U,Math.min(se,Math.round(A*0.6)));y.style("font-size",`${x}px`);let k=(c.y1-c.y0)/2+A/2+de;y.attr("y",k);let _=c.x1-c.x0,De=c.y1-c.y0-4,qe=_-2*pe;if(y.node().getComputedTextLength()>qe||k+x>De||x<U)y.style("display","none");else y.style("display",null)});let Ie=p.diagramPadding??8;lt(T,Ie,"flowchart",p?.useMaxWidth||!1)},"draw"),nt=t(function(e,r){return r.db.getClasses()},"getClasses"),ot={draw:rt,getClasses:nt},st={sectionStrokeColor:"black",sectionStrokeWidth:"1",sectionFillColor:"#efefef",leafStrokeColor:"black",leafStrokeWidth:"1",leafFillColor:"#efefef",labelFontSize:"12px",valueFontSize:"10px",titleFontSize:"14px"},it=t(({treemap:e}={})=>{let r=Mt(),n=E(),o=ae(r,n.themeVariables),s=ae(st,e),p=s.titleColor??o.titleColor,u=s.labelColor??o.textColor,f=s.valueColor??o.textColor;return`
|
|
2
|
+
.treemapNode.section {
|
|
3
|
+
stroke: ${s.sectionStrokeColor};
|
|
4
|
+
stroke-width: ${s.sectionStrokeWidth};
|
|
5
|
+
fill: ${s.sectionFillColor};
|
|
6
|
+
}
|
|
7
|
+
.treemapNode.leaf {
|
|
8
|
+
stroke: ${s.leafStrokeColor};
|
|
9
|
+
stroke-width: ${s.leafStrokeWidth};
|
|
10
|
+
fill: ${s.leafFillColor};
|
|
11
|
+
}
|
|
12
|
+
.treemapLabel {
|
|
13
|
+
fill: ${u};
|
|
14
|
+
font-size: ${s.labelFontSize};
|
|
15
|
+
}
|
|
16
|
+
.treemapValue {
|
|
17
|
+
fill: ${f};
|
|
18
|
+
font-size: ${s.valueFontSize};
|
|
19
|
+
}
|
|
20
|
+
.treemapTitle {
|
|
21
|
+
fill: ${p};
|
|
22
|
+
font-size: ${s.titleFontSize};
|
|
23
|
+
}
|
|
24
|
+
`},"getStyles"),ct=it,da={parser:Re,get db(){return new Be},renderer:ot,styles:ct};export{da as diagram};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{be}from"./index-123e8tqq.js";import{t,l,K,E,X,R,M,O,P,z,j,G,p,_l,h,To,yu,ae}from"./index-qmh0h87h.js";import{su,Te}from"./index-tr8754r0.js";var C="position frame",I="frame positioned",k="position relation",W="relation positioned",ge=t(function(e){l.debug("options str",e)},"setOptions"),he=t(function(){return{}},"getOptions"),pe=t(function(){H(),R()},"clear");function H(){A={}}t(H,"reset");var ve=K.eventmodeling,we=t(()=>ae({...ve,...E().eventmodeling}),"getConfig"),A={};function U(){let e=ye,{ast:i}=A,n=T();if(!i)throw Error("No data for EventModel");return i.frames.forEach((r,a)=>{let o=Q(r,i.dataEntities,n);e=y(e,{$kind:C,index:a,frame:r,textProps:o});let d=void 0;if(re(r))l.debug("source frame",r.sourceFrames),d=i.frames.filter((c)=>r.sourceFrames.some((m)=>m.$refText===c.name)),d.forEach((c)=>{e=y(e,{$kind:k,index:a,frame:r,sourceFrame:c})});else e=y(e,{$kind:k,index:a,frame:r})}),e={...e,sortedSwimlanesArray:D(e.swimlanes)},e}t(U,"getState");function _(e){A.ast=e}t(_,"setAst");var s={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:"bold",boxTextPadding:10,swimlaneTextFontWeight:"bold",labelUiAutomation:"UI/Automation",labelUiAutomationPrefix:"UI/A: ",labelCommandReadModel:"Command/Read Model",labelCommandReadModelPrefix:"C/RM: ",labelEvents:"Events",labelEventsPrefix:"Stream: "};function T(){return s}t(T,"getDiagramProps");var ye={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function L(e){let i=e.split(".");if(i.length===2)return i[0];return}t(L,"extractNamespace");function V(e){let i=e.split(".");if(i.length===2)return i[1];return e}t(V,"extractName");function Y(e,i){if(!i||i.length===0)return;return Object.values(e).find((n)=>n.namespace===i)}t(Y,"findSwimlaneByNamespace");function w(e,i,n){return Math.max(i,...Object.keys(e).filter((r)=>{let a=Number.parseInt(r);return a>i&&a<n}).map((r)=>Number.parseInt(r)))+1}t(w,"findNextAvailableIndex");function q(e,i){let n=L(e.entityIdentifier),r=Y(i,n);switch(e.modelEntityType){case"ui":case"pcr":case"processor":if(r)return{index:r.index,label:r.namespace||s.labelUiAutomation};else if(n)return{index:w(i,0,100),label:s.labelUiAutomationPrefix+n};return{index:0,label:s.labelUiAutomation};case"rmo":case"readmodel":case"cmd":case"command":if(r)return{index:r.index,label:r.namespace||s.labelCommandReadModel};else if(n)return{index:w(i,100,200),label:s.labelCommandReadModelPrefix+n};return{index:100,label:s.labelCommandReadModel};case"evt":case"event":default:if(r)return{index:r.index,label:r.namespace||s.labelEvents};else if(n)return{index:w(i,200,300),label:s.labelEventsPrefix+n};return{index:200,label:s.labelEvents}}}t(q,"calculateSwimlaneProps");function J(e){let{themeVariables:i}=E();switch(e.modelEntityType){case"ui":return{fill:i.emUiFill??"white",stroke:i.emUiStroke??"#dbdada"};case"pcr":case"processor":return{fill:i.emProcessorFill??"#edb3f6",stroke:i.emProcessorStroke??"#b88cbf"};case"rmo":case"readmodel":return{fill:i.emReadModelFill??"#d3f1a2",stroke:i.emReadModelStroke??"#a3b732"};case"cmd":case"command":return{fill:i.emCommandFill??"#bcd6fe",stroke:i.emCommandStroke??"#679ac3"};case"evt":case"event":return{fill:i.emEventFill??"#ffb778",stroke:i.emEventStroke??"#c19a0f"};default:return{fill:"red",stroke:"black"}}}t(J,"calculateEntityVisualProps");function Q(e,i,n){let r=E(),a=X(V(e.entityIdentifier)??"",r),o,d={fontSize:16,fontWeight:700,fontFamily:'"trebuchet ms", verdana, arial, sans-serif',joinWith:"<br/>"},m=`<b>${To(a,n.textMaxWidth,d)}</b>`;if(e.dataInlineValue)o=e.dataInlineValue,o=o.substring(o.indexOf("{")+1),o=o.substring(0,o.lastIndexOf("}")-1),o=X(o,r),o=To(o,n.textMaxWidth,d),o=o.replaceAll(" "," ");if(e.dataReference){let v=i.find((S)=>S.name===e.dataReference?.$refText);if(v)o=v.dataBlockValue,o=o.substring(o.indexOf(`{
|
|
2
|
+
`)+2),o=o.substring(0,o.lastIndexOf("}")-1),o=X(o,r),o=To(o,n.textMaxWidth,d),o=o.replaceAll(" "," "),o+="<br/>"}let u=o!==void 0;if(u)m+=`<br/><br/><code style="text-align: left; display: block;max-width:${n.textMaxWidth}px">${o}</code>`;let f={fontSize:d.fontSize,fontWeight:d.fontWeight,fontFamily:d.fontFamily},x=yu(m,f),b=u?x.width/3:x.width,g={content:m,width:b,height:x.height};return l.debug(`[${e.name}] ${e.entityIdentifier} text`,g),g}t(Q,"calculateTextProps");function Z(e,i){let n=i,r=J(n.frame),a={width:n.textProps.width+2*s.boxTextPadding,height:n.textProps.height+2*s.boxTextPadding};return[{$kind:I,frame:n.frame,index:n.index,visual:r,dimension:a,textProps:n.textProps}]}t(Z,"decidePositionFrame");function ee(e,i,n){if(i===void 0)return s.contentStartX;if(i.index===e.index&&e.r)return e.r+s.boxPadding;if(n===void 0)return s.contentStartX;return n.r-s.boxOverlap+s.boxPadding}t(ee,"calculateX");function te(e,i){let n=[...e.map((r)=>r.r),i];return Math.max(...n)}t(te,"calculateMaxRight");function D(e){return Object.values(e).sort((i,n)=>i.index-n.index)}t(D,"sortedSwimlanesArray");function ne(e,i){let n=i,r=q(n.frame,e.swimlanes),a;if(r.index in e.swimlanes)a=e.swimlanes[r.index];else a={index:r.index,label:r.label,r:0,y:r.index*s.swimlaneMinHeight+s.swimlaneGap,height:s.swimlaneMinHeight,maxHeight:s.swimlaneMinHeight};let o=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,d=e.previousSwimlaneNumber!==void 0?e.swimlanes[e.previousSwimlaneNumber]:void 0,c={width:Math.max(s.boxMinWidth,Math.min(s.boxMaxWidth,n.dimension.width))+2*s.boxPadding,height:Math.max(s.boxMinHeight,Math.min(s.boxMaxHeight,n.dimension.height))+2*s.boxPadding},m=ee(a,d,o),u=m+c.width+s.boxPadding,f=te(Object.values(e.swimlanes),u);a.r=m+c.width,a.maxHeight=Math.max(a.maxHeight,c.height),a.height=Math.max(s.swimlaneMinHeight,a.maxHeight)+2*s.swimlanePadding;let x={x:m,y:s.swimlanePadding+a.y,r:u,dimension:c,leftSibling:!1,swimlane:a,visual:n.visual,text:n.textProps.content,frame:n.frame,index:n.index},b={...e,boxes:[...e.boxes,x],swimlanes:{...e.swimlanes,[`${a.index}`]:a},previousSwimlaneNumber:r.index,previousFrame:n.frame,maxR:f},g=D(b.swimlanes);if(g.length>0)g[0].y=0;for(let v=1;v<g.length;v++){let S=g[v],N=g[v-1];S.y=N.y+N.height+s.swimlaneGap}return b}t(ne,"evolveFramePositioned");function ie(e,i){if(e===0&&i.sourceFrames.length===0)return!0;return!1}t(ie,"isFirstFrame");function re(e){return e.sourceFrames!==void 0&&e.sourceFrames!==null&&e.sourceFrames.length>0}t(re,"hasSourceFrame");function F(e,i){if(i===void 0||i===null)return;return e.find((n)=>n.frame.name===i.name)}t(F,"findBoxByFrame");function oe(e,i,n){if(n<0)return;for(let r=n;r>=0;r--){let a=e[r];if(a.swimlane.index!==i)return a}return}t(oe,"findBoxByLineIndex");function se(e,i){let n=i;if(su(n.frame)||ie(n.index,n.frame))return[];let r=F(e.boxes,n.frame);if(r===void 0)throw Error(`Target box not found for frame ${n.frame.name}`);let a;if(n.sourceFrame)a=F(e.boxes,n.sourceFrame);else a=oe(e.boxes,r.swimlane.index,n.index-1);if(a===void 0)return[];return[{$kind:W,frame:n.frame,index:n.index,sourceBox:a,targetBox:r}]}t(se,"decidePositionRelation");function de(e,i){let n=i,r={visual:{fill:"none",stroke:"#000"},source:{x:n.sourceBox.x,y:n.sourceBox.y},target:{x:n.targetBox.x,y:n.targetBox.y},sourceBox:n.sourceBox,targetBox:n.targetBox};return{...e,relations:[...e.relations,r]}}t(de,"evolveRelationPositioned");var Pe={[C]:Z,[k]:se},Se={[I]:ne,[W]:de};function le(e,i){let n=Pe[i.$kind];if(n===void 0||n===null)return[];let r=n(e,i);return l.debug("decided events",r),r}t(le,"decide");function ce(e,i){let n=i.reduce((r,a)=>{let o=Se[a.$kind];if(o===void 0||o===null)return r;return o(r,a)},e);return l.debug("evolve events",{state:e,newState:n,events:i}),n}t(ce,"evolve");function y(e,i){let n=le(e,i);return ce(e,n)}t(y,"dispatch");var B={getConfig:we,setOptions:ge,getOptions:he,clear:pe,setAccTitle:M,getAccTitle:O,getAccDescription:z,setAccDescription:P,setDiagramTitle:j,getDiagramTitle:G,setAst:_,getDiagramProps:T,getState:U},Me={parse:t(async(e)=>{let i=await Te("eventmodeling",e);l.debug(i),B.setAst(i),be(i,B)},"parse")},ke=p(),Fe=ke?.eventmodeling;function me(e,i){return(n)=>{let r=n.swimlane.y+i.swimlanePadding,a=e.append("g").attr("class","em-box");a.append("rect").attr("x",n.x).attr("y",r).attr("rx","3").attr("width",n.dimension.width).attr("height",n.dimension.height).attr("stroke",n.visual.stroke).attr("fill",n.visual.fill),a.append("foreignObject").attr("x",n.x+i.boxPadding).attr("y",r+10).attr("width",n.dimension.width-2*i.boxPadding).attr("height",n.dimension.height-2*i.boxPadding).append("xhtml:div").style("display","table").style("height","100%").style("width","100%").append("span").style("display","table-cell").style("text-align","center").style("vertical-align","middle").html(n.text)}}t(me,"renderD3Box");function ue(e,i){return e>i}t(ue,"dirUpwards");function xe(e,i,n,r){return(a)=>{let o=a.sourceBox.swimlane.y+i.swimlanePadding,d=a.targetBox.swimlane.y+i.swimlanePadding,c=ue(o,d),m=a.sourceBox.x+a.sourceBox.dimension.width*2/3,u=a.targetBox.x+a.targetBox.dimension.width/3,f,x;if(l.debug(`rendering relation up=${c} for `,{sourceBox:a.sourceBox,targetBox:a.targetBox}),c)f=o,x=d+a.targetBox.dimension.height;else f=o+a.sourceBox.dimension.height,x=d;let b=r.emRelationStroke??a.visual.stroke;e.append("path").attr("class","em-relation").attr("fill",a.visual.fill).attr("stroke",b).attr("stroke-width","1").attr("marker-end",`url(#${n})`).attr("d",`M${m} ${f} L${u} ${x}`)}}t(xe,"renderD3Relation");function fe(e,i,n,r){return(a)=>{let o=e.append("g").attr("class","em-swimlane"),d=r.emSwimlaneBackgroundOdd??"rgb(250,250,250)",c=r.emSwimlaneBackgroundStroke??"rgb(240,240,240)";o.append("rect").attr("x",0).attr("y",a.y).attr("rx","3").attr("width",i+n.swimlanePadding).attr("height",a.height).attr("fill",d).attr("stroke",c),o.append("text").attr("font-weight",n.swimlaneTextFontWeight).attr("x",30).attr("y",a.y+30).text(a.label)}}t(fe,"renderD3Swimlane");var Be=t(function(e,i,n,r){if(l.debug("in eventmodeling renderer",e+`
|
|
3
|
+
`,"id:",i,n),!Fe)throw Error("EventModeling config not found");let a=r.db,{themeVariables:o,eventmodeling:d}=p(),c=h(`[id="${i}"]`),m=a.getDiagramProps(),u=a.getState(),f=`em-arrowhead-${i}`,x=o.emArrowhead??"#000000";u.sortedSwimlanesArray.forEach(fe(c,u.maxR,m,o)),u.boxes.forEach(me(c,m)),u.relations.forEach(xe(c,m,f,o)),c.append("defs").append("marker").attr("id",f).attr("markerWidth","10").attr("markerHeight","7").attr("refX","10").attr("refY","3.5").attr("orient","auto").append("polygon").attr("points","0 0, 10 3.5, 0 7").attr("fill",x),_l(void 0,c,d?.padding??30,d?.useMaxWidth)},"draw"),Ee={draw:Be},Ae=t((e)=>"","getStyles"),Re=Ae,Ue={parser:Me,db:B,renderer:Ee,styles:Re};export{Ue as diagram};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import{fo}from"./index-hkq0y3pn.js";import{be}from"./index-123e8tqq.js";import{t,l,K,E,X,te,R,M,O,P,z,j,G,ue,_o,rr,ae}from"./index-qmh0h87h.js";import{Te}from"./index-tr8754r0.js";var L=/[─━│┃└┗├┣]/,D=/[└┗├┣]/,Z=/[─━]/,V=/^[\s│┃]+$/,k=/^\s*(title[\t ]|accTitle[\t ]*:|accDescr[\t ]*[:{])/,N=/^\s*%%/,q=" ";function _(n){return n.some((r)=>L.test(r))}t(_,"isBoxDrawingFormat");function S(n){for(let r of n){let e=D.exec(r);if(e?.index&&e.index>0)return e.index}return 4}t(S,"inferSegmentWidth");function H(n,r){return n.replace(/\bline\s+(\d+)\b/gi,(e,i)=>{let a=parseInt(i,10),o=r.get(a);return o?`line ${o}`:e})}t(H,"remapErrorLines");function W(n){let r=n.split(`
|
|
2
|
+
`),e=new Map,i=-1;for(let[g,d]of r.entries())if(d.trim()==="treeView-beta"){i=g;break}if(i===-1)return{text:n,lineMap:e};let a=[];for(let g=i+1;g<r.length;g++){let d=r[g];if(d.trim()===""||N.test(d)||k.test(d))continue;if(V.test(d))continue;a.push(d.replace(/\t/g," "))}if(!_(a))return{text:n,lineMap:e};let o=S(a),s=[],c=0;for(let g=0;g<=i;g++)s.push(r[g]),c++,e.set(c,g+1);for(let g=i+1;g<r.length;g++){let d=r[g],p=d.trim(),f=g+1;if(p===""){s.push(d),c++,e.set(c,f);continue}if(N.test(d)){s.push(d),c++,e.set(c,f);continue}if(k.test(d)){s.push(d),c++,e.set(c,f);continue}if(V.test(d))continue;let h=d.replace(/\t/g," "),w=D.exec(h);if(w?.index!==void 0){let u=w.index,x=Math.round(u/o)+1,m=u+1;while(m<h.length&&Z.test(h[m]))m++;while(m<h.length&&h[m]===" ")m++;let b=h.slice(m).trimEnd();if(!b)throw Error(`Line ${f}: Empty node — expected a filename or directory name after the box-drawing prefix`);let F=q.repeat(x);s.push(F+b),c++,e.set(c,f)}else if(/^[\s─━│┃└┗├┣]+$/.test(h))continue;else if(L.test(h))s.push(d),c++,e.set(c,f);else if(/^\s+/.test(h))throw Error(`Line ${f}: Unexpected indentation without box-drawing characters. In box-drawing format, use ├── or └── prefixes for indented nodes.`);else s.push(d),c++,e.set(c,f)}return{text:s.join(`
|
|
3
|
+
`),lineMap:e}}t(W,"preprocessBoxDrawing");var v=new fo(()=>({cnt:1,stack:[{id:0,level:-1,name:"/",nodeType:"directory",children:[]}]})),U=t(()=>{v.reset(),R()},"clear"),J=t(()=>v.records.stack[0],"getRoot"),Q=t(()=>v.records.cnt,"getCount"),ee=K.treeView,re=t(()=>ae(ee,E().treeView),"getConfig"),ne=t((n,r,e,i,a,o)=>{while(n<=v.records.stack[v.records.stack.length-1].level)v.records.stack.pop();let s={id:v.records.cnt++,level:n,name:r,nodeType:e,icon:a,cssClass:i,description:o,children:[]};v.records.stack[v.records.stack.length-1].children.push(s),v.records.stack.push(s)},"addNode"),ie={clear:U,addNode:ne,getRoot:J,getCount:Q,getConfig:re,getAccTitle:O,getAccDescription:z,getDiagramTitle:G,setAccDescription:P,setAccTitle:M,setDiagramTitle:j},I=ie,oe=t((n)=>{be(n,I);for(let r of n.nodes){let e=typeof r.indent==="number"?r.indent:0,i=r.name,a=i.endsWith("/");if(a)i=i.slice(0,-1);let o=a?"directory":"file",s=r.classAnnotation||void 0,c=r.iconAnnotation,g=c!==void 0?c||"none":void 0,d=r.descAnnotation||void 0,p=d?X(d,E()):void 0;I.addNode(e,i,o,s,g,p)}},"populate"),se={parse:t(async(n)=>{let{text:r,lineMap:e}=W(n);try{let i=await Te("treeView",r);l.debug(i),oe(i)}catch(i){if(e.size>0&&i instanceof Error)i.message=H(i.message,e);throw i}},"parse")},C={prefix:"mermaid-treeview",height:24,width:24,icons:{folder:{body:'<path fill="currentColor" d="M10.59 4.59A2 2 0 0 0 9.17 4H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.17z"/>'},file:{body:'<path fill="currentColor" fill-rule="evenodd" d="M6 2a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8.83a2 2 0 0 0-.59-1.42l-4.82-4.82A2 2 0 0 0 13.17 2H6Zm7.5 1.9l4.6 4.6h-3.6a1 1 0 0 1-1-1V3.9Z" clip-rule="evenodd"/>'}}};function Y(n,r){let e=r?.filenameIcons?.[n];if(e)return e;let i=n.lastIndexOf(".");if(i>0){let a=n.substring(i).toLowerCase(),o=r?.extensionIcons;return o?.[a]??o?.[a.slice(1)]}return}t(Y,"detectIcon");function y(n,r){if(n.includes(":"))return n;if(n in C.icons||!r)return`${C.prefix}:${n}`;return`${r}:${n}`}t(y,"qualifyIcon");function T(n,r){if(n.icon==="none")return;if(n.icon)return y(n.icon,r.defaultIconPack);if(!r.showIcons)return;if(n.nodeType==="file"){let e=Y(n.name,r);if(e==="none")return;if(e)return y(e,r.defaultIconPack)}return`${C.prefix}:${n.nodeType==="directory"?"folder":"file"}`}t(T,"getNodeIcon");_o([{name:C.prefix,icons:C}]);var B=14,ce=4,le=16,de=t(async(n,r)=>{let e=[],i=t((o)=>{let s=T(o,r);if(s)e.push({icon:s,node:o});o.children.forEach(i)},"collect");i(n);let a=await Promise.all(e.map(async({icon:o,node:s})=>({id:s.id,svg:await rr(o,{height:B,width:B})})));return new Map(a.map(({id:o,svg:s})=>[o,s]))},"resolveNodeIcons"),he=t((n,r,e,i,a,o)=>{let s=i.append("g"),c="treeView-node-label";if(e.nodeType==="directory")c+=" treeView-node-dir";if(e.cssClass)c+=` ${e.cssClass}`;let g=B+ce,d=T(e,a),p=d!==void 0;if(d)s.append("g").attr("class","treeView-node-icon").attr("transform",`translate(${n+a.paddingX}, ${r+a.paddingY})`).html(o.get(e.id)??"");let f=s.append("text").text(e.name).attr("dominant-baseline","middle").attr("class",c),{height:h,width:w}=f.node().getBBox(),u=h+a.paddingY*2,x=n+a.paddingX+(p?g:0);f.attr("x",x),f.attr("y",r+u/2);let m=x+w,b=w+a.paddingX*2+(p?g:0);if(e.BBox={x:n,y:r,width:b,height:u},e.cssClass?.split(/\s+/).includes("highlight"))s.insert("rect",":first-child").attr("x",n).attr("y",r+1).attr("width",0).attr("height",u-2).attr("rx",3).attr("class","treeView-highlight-bg");return{node:e,nodeGroup:s,labelRightEdge:m,centerY:r+u/2}},"positionLabel"),A=t((n,r,e,i,a,o)=>n.append("line").attr("x1",r).attr("y1",e).attr("x2",i).attr("y2",a).attr("stroke-width",o).attr("class","treeView-node-line"),"positionLine"),pe=t((n,r,e,i)=>{let a=0,o=0,s=[],c=t((p,f,h,w)=>{let u=w*(h.rowIndent+h.paddingX),x=he(u,a,f,p,h,i);s.push(x);let{height:m,width:b}=f.BBox;A(p,u-h.rowIndent,a+m/2,u,a+m/2,h.lineThickness),o=Math.max(o,u+b),a+=m},"drawNode"),g=t((p,f=0)=>{c(n,p,e,f),p.children.forEach((x)=>{g(x,f+1)});let{x:h,y:w,height:u}=p.BBox;if(p.children.length){let{y:x,height:m}=p.children[p.children.length-1].BBox;A(n,h+e.paddingX,w+u,h+e.paddingX,x+m/2+e.lineThickness/2,e.lineThickness)}},"processNode");g(r);let d=s.filter((p)=>p.node.description);if(d.length>0){let f=Math.max(...s.map((h)=>h.labelRightEdge))+le;for(let h of d){let u=h.nodeGroup.append("text").text(h.node.description).attr("dominant-baseline","middle").attr("class","treeView-node-description").attr("x",f).attr("y",h.centerY).node().getBBox();o=Math.max(o,f+u.width+e.paddingX)}}for(let p of s)if(p.node.cssClass?.split(/\s+/).includes("highlight")){let f=p.nodeGroup.select(".treeView-highlight-bg");if(!f.empty()){let h=o-p.node.BBox.x+8;f.attr("width",h),o=Math.max(o,p.node.BBox.x+h+2)}}return{totalHeight:a,totalWidth:o}},"drawTree"),fe=t(async(n,r,e,i)=>{l.debug(`Rendering treeView diagram
|
|
4
|
+
`+n);let a=i.db,o=a.getRoot(),s=a.getConfig(),c=ue(r),g=c.append("g");g.attr("class","tree-view");let d=await de(o,s),{totalHeight:p,totalWidth:f}=pe(g,o,s,d);c.attr("viewBox",`-${s.lineThickness/2} 0 ${f} ${p}`),te(c,p,f,s.useMaxWidth)},"draw"),ge={draw:fe},me=ge,we={labelFontSize:"16px",labelColor:"black",lineColor:"black",iconColor:"#546e7a",descriptionColor:"#6a9955",highlightBg:"rgba(255, 193, 7, 0.15)",highlightStroke:"#ffc107"},xe=t(({treeView:n})=>{let{labelFontSize:r,labelColor:e,lineColor:i,iconColor:a,descriptionColor:o,highlightBg:s,highlightStroke:c}=ae(we,n);return`
|
|
5
|
+
.treeView-node-label {
|
|
6
|
+
font-size: ${r};
|
|
7
|
+
fill: ${e};
|
|
8
|
+
white-space: pre;
|
|
9
|
+
}
|
|
10
|
+
.treeView-node-dir {
|
|
11
|
+
font-weight: bold;
|
|
12
|
+
}
|
|
13
|
+
.treeView-node-line {
|
|
14
|
+
stroke: ${i};
|
|
15
|
+
}
|
|
16
|
+
.treeView-node-icon {
|
|
17
|
+
color: ${a};
|
|
18
|
+
}
|
|
19
|
+
.treeView-node-description {
|
|
20
|
+
font-size: ${r};
|
|
21
|
+
fill: ${o};
|
|
22
|
+
font-style: italic;
|
|
23
|
+
white-space: pre;
|
|
24
|
+
}
|
|
25
|
+
.treeView-highlight-bg {
|
|
26
|
+
fill: ${s};
|
|
27
|
+
stroke: ${c};
|
|
28
|
+
stroke-width: 1;
|
|
29
|
+
}
|
|
30
|
+
`},"styles"),ve=xe,Ee={db:I,renderer:me,parser:se,styles:ve};export{Ee as diagram};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import{be}from"./index-123e8tqq.js";import{t,l,K,E,te,R,M,O,P,z,j,G,ue,ae}from"./index-qmh0h87h.js";import{Te}from"./index-tr8754r0.js";var y=K.packet,u=class{constructor(){this.packet=[],this.setAccTitle=M,this.getAccTitle=O,this.setDiagramTitle=j,this.getDiagramTitle=G,this.getAccDescription=z,this.setAccDescription=P}static{t(this,"PacketDB")}getConfig(){let e=ae({...y,...E().packet});if(e.showBits)e.paddingY+=10;return e}getPacket(){return this.packet}pushWord(e){if(e.length>0)this.packet.push(e)}clear(){R(),this.packet=[]}},B=1e4,C=t((e,r)=>{be(e,r);let o=-1,i=[],c=1,{bitsPerRow:d}=r.getConfig();for(let{start:a,end:n,bits:g,label:p}of e.blocks){if(a!==void 0&&n!==void 0&&n<a)throw Error(`Packet block ${a} - ${n} is invalid. End must be greater than start.`);if(a??=o+1,a!==o+1)throw Error(`Packet block ${a} - ${n??a} is not contiguous. It should start from ${o+1}.`);if(g===0)throw Error(`Packet block ${a} is invalid. Cannot have a zero bit field.`);n??=a+(g??1)-1,g??=n-a+1,o=n,l.debug(`Packet block ${a} - ${o} with label ${p}`);while(i.length<=d+1&&r.getPacket().length<B){let[h,s]=S({start:a,end:n,bits:g,label:p},c,d);if(i.push(h),h.end+1===c*d)r.pushWord(i),i=[],c++;if(!s)break;({start:a,end:n,bits:g,label:p}=s)}}r.pushWord(i)},"populate"),S=t((e,r,o)=>{if(e.start===void 0)throw Error("start should have been set during first phase");if(e.end===void 0)throw Error("end should have been set during first phase");if(e.start>e.end)throw Error(`Block start ${e.start} is greater than block end ${e.end}.`);if(e.end+1<=r*o)return[e,void 0];let i=r*o-1,c=r*o;return[{start:e.start,end:i,label:e.label,bits:i-e.start},{start:c,end:e.end,label:e.label,bits:e.end-c}]},"getNextFittingBlock"),w={parser:{yy:void 0},parse:t(async(e)=>{let r=await Te("packet",e),o=w.parser?.yy;if(!(o instanceof u))throw Error("parser.parser?.yy was not a PacketDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");l.debug(r),C(r,o)},"parse")},D=t((e,r,o,i)=>{let c=i.db,d=c.getConfig(),{rowHeight:a,paddingY:n,bitWidth:g,bitsPerRow:p}=d,h=c.getPacket(),s=c.getDiagramTitle(),k=a+n,f=k*(h.length+1)-(s?0:a),m=g*p+2,b=ue(r);b.attr("viewBox",`0 0 ${m} ${f}`),te(b,f,m,d.useMaxWidth);for(let[v,x]of h.entries())T(b,x,v,d);b.append("text").text(s).attr("x",m/2).attr("y",f-k/2).attr("dominant-baseline","middle").attr("text-anchor","middle").attr("class","packetTitle")},"draw"),T=t((e,r,o,{rowHeight:i,paddingX:c,paddingY:d,bitWidth:a,bitsPerRow:n,showBits:g})=>{let p=e.append("g"),h=o*(i+d)+d;for(let s of r){let k=s.start%n*a+1,f=(s.end-s.start+1)*a-c;if(p.append("rect").attr("x",k).attr("y",h).attr("width",f).attr("height",i).attr("class","packetBlock"),p.append("text").attr("x",k+f/2).attr("y",h+i/2).attr("class","packetLabel").attr("dominant-baseline","middle").attr("text-anchor","middle").text(s.label),!g)continue;let m=s.end===s.start,b=h-2;if(p.append("text").attr("x",k+(m?f/2:0)).attr("y",b).attr("class","packetByte start").attr("dominant-baseline","auto").attr("text-anchor",m?"middle":"start").text(s.start),!m)p.append("text").attr("x",k+f).attr("y",b).attr("class","packetByte end").attr("dominant-baseline","auto").attr("text-anchor","end").text(s.end)}},"drawWord"),F={draw:D},A={byteFontSize:"10px",startByteColor:"black",endByteColor:"black",labelColor:"black",labelFontSize:"12px",titleColor:"black",titleFontSize:"14px",blockStrokeColor:"black",blockStrokeWidth:"1",blockFillColor:"#efefef"},W=t(({packet:e}={})=>{let r=ae(A,e);return`
|
|
2
|
+
.packetByte {
|
|
3
|
+
font-size: ${r.byteFontSize};
|
|
4
|
+
}
|
|
5
|
+
.packetByte.start {
|
|
6
|
+
fill: ${r.startByteColor};
|
|
7
|
+
}
|
|
8
|
+
.packetByte.end {
|
|
9
|
+
fill: ${r.endByteColor};
|
|
10
|
+
}
|
|
11
|
+
.packetLabel {
|
|
12
|
+
fill: ${r.labelColor};
|
|
13
|
+
font-size: ${r.labelFontSize};
|
|
14
|
+
}
|
|
15
|
+
.packetTitle {
|
|
16
|
+
fill: ${r.titleColor};
|
|
17
|
+
font-size: ${r.titleFontSize};
|
|
18
|
+
}
|
|
19
|
+
.packetBlock {
|
|
20
|
+
stroke: ${r.blockStrokeColor};
|
|
21
|
+
stroke-width: ${r.blockStrokeWidth};
|
|
22
|
+
fill: ${r.blockFillColor};
|
|
23
|
+
}
|
|
24
|
+
`},"styles"),X={parser:w,get db(){return new u},renderer:F,styles:W};export{X as diagram};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import{be}from"./index-123e8tqq.js";import{t,l,Mt,K,E,te,R,M,O,P,z,j,G,ue,ae}from"./index-qmh0h87h.js";import{Te}from"./index-tr8754r0.js";var h={showLegend:!0,ticks:5,max:null,min:0,graticule:"circle"},C=32,b={axes:[],curves:[],options:h},x=structuredClone(b),F=K.radar,D=t(()=>ae({...F,...E().radar}),"getConfig"),A=t(()=>x.axes,"getAxes"),B=t(()=>x.curves,"getCurves"),W=t(()=>x.options,"getOptions"),V=t((r)=>{x.axes=r.map((e)=>({name:e.name,label:e.label??e.name}))},"setAxes"),H=t((r)=>{x.curves=r.map((e)=>({name:e.name,label:e.label??e.name,entries:U(e.entries)}))},"setCurves"),U=t((r)=>{if(r[0].axis==null)return r.map((a)=>a.value);let e=A();if(e.length===0)throw Error("Axes must be populated before curves for reference entries");return e.map((a)=>{let n=r.find((s)=>s.axis?.$refText===a.name);if(n===void 0)throw Error("Missing entry for axis "+a.label);return n.value})},"computeCurveEntries"),X=t((r)=>{let e=r.reduce((a,n)=>(a[n.name]=n,a),{});if(x.options={showLegend:e.showLegend?.value??h.showLegend,ticks:e.ticks?.value??h.ticks,max:e.max?.value??h.max,min:e.min?.value??h.min,graticule:e.graticule?.value??h.graticule},x.options.ticks>C)l.warn(`Radar diagram ticks (${x.options.ticks}) exceeds maximum allowed (${C}). Using ${C} instead.`),x.options.ticks=C},"setOptions"),N=t(()=>{R(),x=structuredClone(b)},"clear"),y={getAxes:A,getCurves:B,getOptions:W,setAxes:V,setCurves:H,setOptions:X,getConfig:D,clear:N,setAccTitle:M,getAccTitle:O,setDiagramTitle:j,getDiagramTitle:G,getAccDescription:z,setAccDescription:P},Y=t((r)=>{be(r,y);let{axes:e,curves:a,options:n}=r;y.setAxes(e),y.setCurves(a),y.setOptions(n)},"populate"),Z={parse:t(async(r)=>{let e=await Te("radar",r);l.debug(e),Y(e)},"parse")},q=t((r,e,a,n)=>{let s=n.db,c=s.getAxes(),d=s.getCurves(),o=s.getOptions(),i=s.getConfig(),u=s.getDiagramTitle(),m=ue(e),p=J(m,i),g=o.max??Math.max(...d.map((w)=>Math.max(...w.entries))),v=o.min,f=Math.min(i.width,i.height)/2;Q(p,c,f,o.ticks,o.graticule),tt(p,c,f,i),L(p,c,d,v,g,o.graticule,i),k(p,d,o.showLegend,i),p.append("text").attr("class","radarTitle").text(u).attr("x",0).attr("y",-i.height/2-i.marginTop)},"draw"),J=t((r,e)=>{let a=e.width+e.marginLeft+e.marginRight,n=e.height+e.marginTop+e.marginBottom,s={x:e.marginLeft+e.width/2,y:e.marginTop+e.height/2};return te(r,n,a,e.useMaxWidth??!0),r.attr("viewBox",`0 0 ${a} ${n}`).attr("overflow","visible"),r.append("g").attr("transform",`translate(${s.x}, ${s.y})`)},"drawFrame"),Q=t((r,e,a,n,s)=>{if(s==="circle")for(let c=0;c<n;c++){let d=a*(c+1)/n;r.append("circle").attr("r",d).attr("class","radarGraticule")}else if(s==="polygon"){let c=e.length;for(let d=0;d<n;d++){let o=a*(d+1)/n,i=e.map((u,m)=>{let p=2*m*Math.PI/c-Math.PI/2,g=o*Math.cos(p),v=o*Math.sin(p);return`${g},${v}`}).join(" ");r.append("polygon").attr("points",i).attr("class","radarGraticule")}}},"drawGraticule"),tt=t((r,e,a,n)=>{let s=e.length;for(let c=0;c<s;c++){let d=e[c].label,o=2*c*Math.PI/s-Math.PI/2,i=Math.cos(o),u=Math.sin(o);r.append("line").attr("x1",0).attr("y1",0).attr("x2",a*n.axisScaleFactor*i).attr("y2",a*n.axisScaleFactor*u).attr("class","radarAxisLine");let m=i>0.01?"start":i<-0.01?"end":"middle",p=u>0.01?"hanging":u<-0.01?"auto":"central",g=4;r.append("text").text(d).attr("x",a*n.axisLabelFactor*i+g*i).attr("y",a*n.axisLabelFactor*u+g*u).attr("text-anchor",m).attr("dominant-baseline",p).attr("class","radarAxisLabel")}},"drawAxes");function L(r,e,a,n,s,c,d){let o=e.length,i=Math.min(d.width,d.height)/2;a.forEach((u,m)=>{if(u.entries.length!==o)return;let p=u.entries.map((g,v)=>{let f=2*Math.PI*v/o-Math.PI/2,w=T(g,n,s,i),I=w*Math.cos(f),_=w*Math.sin(f);return{x:I,y:_}});if(c==="circle")r.append("path").attr("d",S(p,d.curveTension)).attr("class",`radarCurve-${m}`);else if(c==="polygon")r.append("polygon").attr("points",p.map((g)=>`${g.x},${g.y}`).join(" ")).attr("class",`radarCurve-${m}`)})}t(L,"drawCurves");function T(r,e,a,n){let s=Math.min(Math.max(r,e),a);return n*(s-e)/(a-e)}t(T,"relativeRadius");function S(r,e){let a=r.length,n=`M${r[0].x},${r[0].y}`;for(let s=0;s<a;s++){let c=r[(s-1+a)%a],d=r[s],o=r[(s+1)%a],i=r[(s+2)%a],u={x:d.x+(o.x-c.x)*e,y:d.y+(o.y-c.y)*e},m={x:o.x-(i.x-d.x)*e,y:o.y-(i.y-d.y)*e};n+=` C${u.x},${u.y} ${m.x},${m.y} ${o.x},${o.y}`}return`${n} Z`}t(S,"closedRoundCurve");function k(r,e,a,n){if(!a)return;let s=(n.width/2+n.marginRight)*3/4,c=-(n.height/2+n.marginTop)*3/4,d=20;e.forEach((o,i)=>{let u=r.append("g").attr("transform",`translate(${s}, ${c+i*d})`);u.append("rect").attr("width",12).attr("height",12).attr("class",`radarLegendBox-${i}`),u.append("text").attr("x",16).attr("y",0).attr("class","radarLegendText").text(o.label)})}t(k,"drawLegend");var et={draw:q},at=t((r,e)=>{let a="";for(let n=0;n<r.THEME_COLOR_LIMIT;n++){let s=r[`cScale${n}`];a+=`
|
|
2
|
+
.radarCurve-${n} {
|
|
3
|
+
color: ${s};
|
|
4
|
+
fill: ${s};
|
|
5
|
+
fill-opacity: ${e.curveOpacity};
|
|
6
|
+
stroke: ${s};
|
|
7
|
+
stroke-width: ${e.curveStrokeWidth};
|
|
8
|
+
}
|
|
9
|
+
.radarLegendBox-${n} {
|
|
10
|
+
fill: ${s};
|
|
11
|
+
fill-opacity: ${e.curveOpacity};
|
|
12
|
+
stroke: ${s};
|
|
13
|
+
}
|
|
14
|
+
`}return a},"genIndexStyles"),rt=t((r)=>{let e=Mt(),a=E(),n=ae(e,a.themeVariables),s=ae(n.radar,r);return{themeVariables:n,radarOptions:s}},"buildRadarStyleOptions"),nt=t(({radar:r}={})=>{let{themeVariables:e,radarOptions:a}=rt(r);return`
|
|
15
|
+
.radarTitle {
|
|
16
|
+
font-size: ${e.fontSize};
|
|
17
|
+
color: ${e.titleColor};
|
|
18
|
+
dominant-baseline: hanging;
|
|
19
|
+
text-anchor: middle;
|
|
20
|
+
}
|
|
21
|
+
.radarAxisLine {
|
|
22
|
+
stroke: ${a.axisColor};
|
|
23
|
+
stroke-width: ${a.axisStrokeWidth};
|
|
24
|
+
}
|
|
25
|
+
.radarAxisLabel {
|
|
26
|
+
font-size: ${a.axisLabelFontSize}px;
|
|
27
|
+
color: ${a.axisColor};
|
|
28
|
+
}
|
|
29
|
+
.radarGraticule {
|
|
30
|
+
fill: ${a.graticuleColor};
|
|
31
|
+
fill-opacity: ${a.graticuleOpacity};
|
|
32
|
+
stroke: ${a.graticuleColor};
|
|
33
|
+
stroke-width: ${a.graticuleStrokeWidth};
|
|
34
|
+
}
|
|
35
|
+
.radarLegendText {
|
|
36
|
+
text-anchor: start;
|
|
37
|
+
font-size: ${a.legendFontSize}px;
|
|
38
|
+
dominant-baseline: hanging;
|
|
39
|
+
}
|
|
40
|
+
${at(e,a)}
|
|
41
|
+
`},"styles"),pt={parser:Z,db:y,renderer:et,styles:nt};export{pt as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var n=Object.freeze(JSON.parse('{"displayName":"Diff","name":"diff","patterns":[{"captures":{"1":{"name":"punctuation.definition.separator.diff"}},"match":"^((\\\\*{15})|(={67})|(-{3}))$\\\\n?","name":"meta.separator.diff"},{"match":"^\\\\d+(,\\\\d+)*([acd])\\\\d+(,\\\\d+)*$\\\\n?","name":"meta.diff.range.normal"},{"captures":{"1":{"name":"punctuation.definition.range.diff"},"2":{"name":"meta.toc-list.line-number.diff"},"3":{"name":"punctuation.definition.range.diff"}},"match":"^(@@)\\\\s*(.+?)\\\\s*(@@)($\\\\n?)?","name":"meta.diff.range.unified"},{"captures":{"3":{"name":"punctuation.definition.range.diff"},"4":{"name":"punctuation.definition.range.diff"},"6":{"name":"punctuation.definition.range.diff"},"7":{"name":"punctuation.definition.range.diff"}},"match":"^(((-{3}) .+ (-{4}))|((\\\\*{3}) .+ (\\\\*{4})))$\\\\n?","name":"meta.diff.range.context"},{"match":"^diff --git a/.*$\\\\n?","name":"meta.diff.header.git"},{"match":"^diff (-|\\\\S+\\\\s+\\\\S+).*$\\\\n?","name":"meta.diff.header.command"},{"captures":{"4":{"name":"punctuation.definition.from-file.diff"},"6":{"name":"punctuation.definition.from-file.diff"},"7":{"name":"punctuation.definition.from-file.diff"}},"match":"^((((-{3}) .+)|((\\\\*{3}) .+))$\\\\n?|(={4}) .+(?= - ))","name":"meta.diff.header.from-file"},{"captures":{"2":{"name":"punctuation.definition.to-file.diff"},"3":{"name":"punctuation.definition.to-file.diff"},"4":{"name":"punctuation.definition.to-file.diff"}},"match":"(^(\\\\+{3}) .+$\\\\n?| (-) .* (={4})$\\\\n?)","name":"meta.diff.header.to-file"},{"captures":{"3":{"name":"punctuation.definition.inserted.diff"},"6":{"name":"punctuation.definition.inserted.diff"}},"match":"^(((>)( .*)?)|((\\\\+).*))$\\\\n?","name":"markup.inserted.diff"},{"captures":{"1":{"name":"punctuation.definition.changed.diff"}},"match":"^(!).*$\\\\n?","name":"markup.changed.diff"},{"captures":{"3":{"name":"punctuation.definition.deleted.diff"},"6":{"name":"punctuation.definition.deleted.diff"}},"match":"^(((<)( .*)?)|((-).*))$\\\\n?","name":"markup.deleted.diff"},{"begin":"^(#)","captures":{"1":{"name":"punctuation.definition.comment.diff"}},"end":"\\\\n","name":"comment.line.number-sign.diff"},{"match":"^index [0-9a-f]{7,40}\\\\.\\\\.[0-9a-f]{7,40}.*$\\\\n?","name":"meta.diff.index.git"},{"captures":{"1":{"name":"punctuation.separator.key-value.diff"},"2":{"name":"meta.toc-list.file-name.diff"}},"match":"^Index(:) (.+)$\\\\n?","name":"meta.diff.index"},{"match":"^Only in .*: .*$\\\\n?","name":"meta.diff.only-in"}],"scopeName":"source.diff"}')),e=[n];export{e as default};
|