db-studio 1.2.12 → 1.2.13
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/core-dist/assets/KaTeX_AMS-Regular-BQhdFMY1.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_AMS-Regular-DMm9YOAa.woff +0 -0
- package/dist/core-dist/assets/KaTeX_AMS-Regular-DRggAlZN.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Bold-ATXxdsX0.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Bold-BEiXGLvX.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Bold-Dq_IR9rO.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Regular-CTRA-rTL.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Regular-Di6jR-x-.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Caligraphic-Regular-wX97UBjC.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Bold-BdnERNNW.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Bold-BsDP51OF.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Bold-CL6g_b3V.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Regular-CB_wures.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Regular-CTYiF6lA.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Fraktur-Regular-Dxdc4cR9.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Bold-Cx986IdX.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Bold-Jm3AIy58.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Bold-waoOVXN0.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Main-BoldItalic-DxDJ3AOS.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Main-BoldItalic-DzxPMmG6.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Main-BoldItalic-SpSLRI95.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Italic-3WenGoN9.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Italic-BMLOBm91.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Italic-NWA7e6Wa.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Regular-B22Nviop.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Regular-Dr94JaBh.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Main-Regular-ypZvNtVU.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Math-BoldItalic-B3XSjfu4.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Math-BoldItalic-CZnvNsCZ.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Math-BoldItalic-iY-2wyZ7.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Math-Italic-DA0__PXp.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Math-Italic-flOr_0UB.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Math-Italic-t53AETM-.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Bold-CFMepnvq.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Bold-D1sUS0GD.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Bold-DbIhKOiC.woff +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Italic-C3H0VqGB.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Italic-DN2j7dab.woff +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Italic-YYjJ1zSn.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Regular-BNo7hRIc.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Regular-CS6fqUqJ.woff +0 -0
- package/dist/core-dist/assets/KaTeX_SansSerif-Regular-DDBCnlJ7.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Script-Regular-C5JkGWo-.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Script-Regular-D3wIWfF6.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Script-Regular-D5yQViql.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Size1-Regular-C195tn64.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Size1-Regular-Dbsnue_I.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Size1-Regular-mCD8mA8B.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Size2-Regular-B7gKUWhC.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Size2-Regular-Dy4dx90m.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Size2-Regular-oD1tc_U0.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Size3-Regular-CTq5MqoE.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Size3-Regular-DgpXs0kz.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Size4-Regular-BF-4gkZK.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Size4-Regular-DWFBv043.ttf +0 -0
- package/dist/core-dist/assets/KaTeX_Size4-Regular-Dl5lxZxV.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Typewriter-Regular-C0xS9mPB.woff +0 -0
- package/dist/core-dist/assets/KaTeX_Typewriter-Regular-CO6r4hn1.woff2 +0 -0
- package/dist/core-dist/assets/KaTeX_Typewriter-Regular-D3Ib7_Hf.ttf +0 -0
- package/dist/core-dist/assets/_baseUniq-B_K25dSy.js +1 -0
- package/dist/core-dist/assets/_queryId-BKz8FUI1.js +1 -0
- package/dist/core-dist/assets/_table-BpdGy20G.js +1 -0
- package/dist/core-dist/assets/abap-BdImnpbu.js +1 -0
- package/dist/core-dist/assets/abap-DLDM7-KI.js +1 -0
- package/dist/core-dist/assets/actionscript-3-CfeIJUat.js +1 -0
- package/dist/core-dist/assets/ada-bCR0ucgS.js +1 -0
- package/dist/core-dist/assets/andromeeda-C-Jbm3Hp.js +1 -0
- package/dist/core-dist/assets/angular-html-CU67Zn6k.js +1 -0
- package/dist/core-dist/assets/angular-ts-BwZT4LLn.js +1 -0
- package/dist/core-dist/assets/apache-Pmp26Uib.js +1 -0
- package/dist/core-dist/assets/apex-D8_7TLub.js +1 -0
- package/dist/core-dist/assets/apex-DNDY2TF8.js +1 -0
- package/dist/core-dist/assets/apl-dKokRX4l.js +1 -0
- package/dist/core-dist/assets/applescript-Co6uUVPk.js +1 -0
- package/dist/core-dist/assets/ara-BRHolxvo.js +1 -0
- package/dist/core-dist/assets/arc-CM-cekU0.js +1 -0
- package/dist/core-dist/assets/architectureDiagram-VXUJARFQ-BCmD-Gj_.js +36 -0
- package/dist/core-dist/assets/asciidoc-Dv7Oe6Be.js +1 -0
- package/dist/core-dist/assets/asm-D_Q5rh1f.js +1 -0
- package/dist/core-dist/assets/astro-CbQHKStN.js +1 -0
- package/dist/core-dist/assets/aurora-x-D-2ljcwZ.js +1 -0
- package/dist/core-dist/assets/awk-DMzUqQB5.js +1 -0
- package/dist/core-dist/assets/ayu-dark-CmMr59Fi.js +1 -0
- package/dist/core-dist/assets/azcli-Y6nb8tq_.js +1 -0
- package/dist/core-dist/assets/ballerina-BFfxhgS-.js +1 -0
- package/dist/core-dist/assets/bat-BkioyH1T.js +1 -0
- package/dist/core-dist/assets/bat-BwHxbl9M.js +1 -0
- package/dist/core-dist/assets/beancount-k_qm7-4y.js +1 -0
- package/dist/core-dist/assets/berry-uYugtg8r.js +1 -0
- package/dist/core-dist/assets/bibtex-CHM0blh-.js +1 -0
- package/dist/core-dist/assets/bicep-Bmn6On1c.js +1 -0
- package/dist/core-dist/assets/bicep-CFznDFnq.js +2 -0
- package/dist/core-dist/assets/blade-D4QpJJKB.js +1 -0
- package/dist/core-dist/assets/blockDiagram-VD42YOAC-DeY844Kv.js +122 -0
- package/dist/core-dist/assets/bsl-BO_Y6i37.js +1 -0
- package/dist/core-dist/assets/c-BIGW1oBm.js +1 -0
- package/dist/core-dist/assets/c3-VCDPK7BO.js +1 -0
- package/dist/core-dist/assets/c4Diagram-YG6GDRKO-gX9j2-0Z.js +10 -0
- package/dist/core-dist/assets/cadence-Bv_4Rxtq.js +1 -0
- package/dist/core-dist/assets/cairo-KRGpt6FW.js +1 -0
- package/dist/core-dist/assets/cameligo-Bf6VGUru.js +1 -0
- package/dist/core-dist/assets/catppuccin-frappe-DFWUc33u.js +1 -0
- package/dist/core-dist/assets/catppuccin-latte-C9dUb6Cb.js +1 -0
- package/dist/core-dist/assets/catppuccin-macchiato-DQyhUUbL.js +1 -0
- package/dist/core-dist/assets/catppuccin-mocha-D87Tk5Gz.js +1 -0
- package/dist/core-dist/assets/channel-C8qB82xE.js +1 -0
- package/dist/core-dist/assets/chunk-4BX2VUAB-C6PIA6wq.js +1 -0
- package/dist/core-dist/assets/chunk-55IACEB6-a0l2Crfx.js +1 -0
- package/dist/core-dist/assets/chunk-B4BG7PRW-CypUhkY3.js +165 -0
- package/dist/core-dist/assets/chunk-DI55MBZ5-pM3ud_GL.js +220 -0
- package/dist/core-dist/assets/chunk-FMBD7UC4-BtON21Ec.js +15 -0
- package/dist/core-dist/assets/chunk-QN33PNHL-NNHAc9s8.js +1 -0
- package/dist/core-dist/assets/chunk-QZHKN3VN-CYogV3aS.js +1 -0
- package/dist/core-dist/assets/chunk-TZMSLE5B-DCoUoEZE.js +1 -0
- package/dist/core-dist/assets/clarity-D53aC0YG.js +1 -0
- package/dist/core-dist/assets/classDiagram-2ON5EDUG-BtPJeqYQ.js +1 -0
- package/dist/core-dist/assets/classDiagram-v2-WZHVMYZB-BtPJeqYQ.js +1 -0
- package/dist/core-dist/assets/clojure-Dnu-v4kV.js +1 -0
- package/dist/core-dist/assets/clojure-P80f7IUj.js +1 -0
- package/dist/core-dist/assets/clone--nCRoznC.js +1 -0
- package/dist/core-dist/assets/cmake-D1j8_8rp.js +1 -0
- package/dist/core-dist/assets/cobol-nwyudZeR.js +1 -0
- package/dist/core-dist/assets/code-block-IT6T5CEO-Ceng2fM2.js +154 -0
- package/dist/core-dist/assets/codeowners-Bp6g37R7.js +1 -0
- package/dist/core-dist/assets/codeql-DsOJ9woJ.js +1 -0
- package/dist/core-dist/assets/codicon-ngg6Pgfi.ttf +0 -0
- package/dist/core-dist/assets/coffee-Bd8akH9Z.js +1 -0
- package/dist/core-dist/assets/coffee-Ch7k5sss.js +1 -0
- package/dist/core-dist/assets/common-lisp-Cg-RD9OK.js +1 -0
- package/dist/core-dist/assets/coq-DkFqJrB1.js +1 -0
- package/dist/core-dist/assets/cose-bilkent-S5V4N54A-DqXTIalc.js +1 -0
- package/dist/core-dist/assets/cpp-BbWJElDN.js +1 -0
- package/dist/core-dist/assets/cpp-CofmeUqb.js +1 -0
- package/dist/core-dist/assets/crystal-tKQVLTB8.js +1 -0
- package/dist/core-dist/assets/csharp-Co3qMtFm.js +1 -0
- package/dist/core-dist/assets/csharp-K5feNrxe.js +1 -0
- package/dist/core-dist/assets/csp-D-4FJmMZ.js +1 -0
- package/dist/core-dist/assets/css-DPfMkruS.js +1 -0
- package/dist/core-dist/assets/css-DdJfP1eB.js +3 -0
- package/dist/core-dist/assets/css.worker-DBVD8oXr.js +93 -0
- package/dist/core-dist/assets/cssMode-_s0s6jbb.js +1 -0
- package/dist/core-dist/assets/csv-fuZLfV_i.js +1 -0
- package/dist/core-dist/assets/cue-D82EKSYY.js +1 -0
- package/dist/core-dist/assets/cypher-COkxafJQ.js +1 -0
- package/dist/core-dist/assets/cypher-cTPe9QuQ.js +1 -0
- package/dist/core-dist/assets/cytoscape.esm-5J0xJHOV.js +321 -0
- package/dist/core-dist/assets/d-85-TOEBH.js +1 -0
- package/dist/core-dist/assets/dagre-6UL2VRFP-CLN6NsN5.js +4 -0
- package/dist/core-dist/assets/dark-plus-C3mMm8J8.js +1 -0
- package/dist/core-dist/assets/dart-BOtBlQCF.js +1 -0
- package/dist/core-dist/assets/dart-CF10PKvl.js +1 -0
- package/dist/core-dist/assets/dax-CEL-wOlO.js +1 -0
- package/dist/core-dist/assets/defaultLocale-DX6XiGOO.js +1 -0
- package/dist/core-dist/assets/desktop-BmXAJ9_W.js +1 -0
- package/dist/core-dist/assets/diagram-PSM6KHXK-ByycaI76.js +24 -0
- package/dist/core-dist/assets/diagram-QEK2KX5R-BoH7syf_.js +43 -0
- package/dist/core-dist/assets/diagram-S2PKOQOG-BqUHyr8W.js +24 -0
- package/dist/core-dist/assets/diff-D97Zzqfu.js +1 -0
- package/dist/core-dist/assets/docker-BcOcwvcX.js +1 -0
- package/dist/core-dist/assets/dockerfile-BG73LgW2.js +1 -0
- package/dist/core-dist/assets/dotenv-Da5cRb03.js +1 -0
- package/dist/core-dist/assets/dracula-BzJJZx-M.js +1 -0
- package/dist/core-dist/assets/dracula-soft-BXkSAIEj.js +1 -0
- package/dist/core-dist/assets/dream-maker-BtqSS_iP.js +1 -0
- package/dist/core-dist/assets/ecl-BEgZUVRK.js +1 -0
- package/dist/core-dist/assets/edge-BkV0erSs.js +1 -0
- package/dist/core-dist/assets/elixir-BkW5O-1t.js +1 -0
- package/dist/core-dist/assets/elixir-CDX3lj18.js +1 -0
- package/dist/core-dist/assets/elm-DbKCFpqz.js +1 -0
- package/dist/core-dist/assets/emacs-lisp-C9XAeP06.js +1 -0
- package/dist/core-dist/assets/erDiagram-Q2GNP2WA-CkGXgXvC.js +60 -0
- package/dist/core-dist/assets/erb-BOJIQeun.js +1 -0
- package/dist/core-dist/assets/erlang-DsQrWhSR.js +1 -0
- package/dist/core-dist/assets/everforest-dark-BgDCqdQA.js +1 -0
- package/dist/core-dist/assets/everforest-light-C8M2exoo.js +1 -0
- package/dist/core-dist/assets/fennel-BYunw83y.js +1 -0
- package/dist/core-dist/assets/fish-BvzEVeQv.js +1 -0
- package/dist/core-dist/assets/flow9-BeJ5waoc.js +1 -0
- package/dist/core-dist/assets/flowDiagram-NV44I4VS-DgOYOnAl.js +162 -0
- package/dist/core-dist/assets/fluent-C4IJs8-o.js +1 -0
- package/dist/core-dist/assets/format-cell-value-KjkoG7hD.js +7 -0
- package/dist/core-dist/assets/fortran-fixed-form-CkoXwp7k.js +1 -0
- package/dist/core-dist/assets/fortran-free-form-BxgE0vQu.js +1 -0
- package/dist/core-dist/assets/freemarker2-CNZbXDjD.js +3 -0
- package/dist/core-dist/assets/fsharp-CXgrBDvD.js +1 -0
- package/dist/core-dist/assets/fsharp-PahG7c26.js +1 -0
- package/dist/core-dist/assets/ganttDiagram-JELNMOA3-DRLDy2OX.js +267 -0
- package/dist/core-dist/assets/gdresource-B7Tvp0Sc.js +1 -0
- package/dist/core-dist/assets/gdscript-DTMYz4Jt.js +1 -0
- package/dist/core-dist/assets/gdshader-DkwncUOv.js +1 -0
- package/dist/core-dist/assets/genie-D0YGMca9.js +1 -0
- package/dist/core-dist/assets/gherkin-DyxjwDmM.js +1 -0
- package/dist/core-dist/assets/git-commit-F4YmCXRG.js +1 -0
- package/dist/core-dist/assets/git-rebase-r7XF79zn.js +1 -0
- package/dist/core-dist/assets/gitGraphDiagram-NY62KEGX-Bcm5bNVl.js +65 -0
- package/dist/core-dist/assets/github-dark-DHJKELXO.js +1 -0
- package/dist/core-dist/assets/github-dark-default-Cuk6v7N8.js +1 -0
- package/dist/core-dist/assets/github-dark-dimmed-DH5Ifo-i.js +1 -0
- package/dist/core-dist/assets/github-dark-high-contrast-E3gJ1_iC.js +1 -0
- package/dist/core-dist/assets/github-light-DAi9KRSo.js +1 -0
- package/dist/core-dist/assets/github-light-default-D7oLnXFd.js +1 -0
- package/dist/core-dist/assets/github-light-high-contrast-BfjtVDDH.js +1 -0
- package/dist/core-dist/assets/gleam-BspZqrRM.js +1 -0
- package/dist/core-dist/assets/glimmer-js-Rg0-pVw9.js +1 -0
- package/dist/core-dist/assets/glimmer-ts-U6CK756n.js +1 -0
- package/dist/core-dist/assets/glsl-DplSGwfg.js +1 -0
- package/dist/core-dist/assets/gn-n2N0HUVH.js +1 -0
- package/dist/core-dist/assets/gnuplot-DdkO51Og.js +1 -0
- package/dist/core-dist/assets/go-Dn2_MT6a.js +1 -0
- package/dist/core-dist/assets/go-acbASCJo.js +1 -0
- package/dist/core-dist/assets/graph-BX6qryEG.js +1 -0
- package/dist/core-dist/assets/graphql-BxJiqAUM.js +1 -0
- package/dist/core-dist/assets/graphql-ChdNCCLP.js +1 -0
- package/dist/core-dist/assets/groovy-gcz8RCvz.js +1 -0
- package/dist/core-dist/assets/gruvbox-dark-hard-CFHQjOhq.js +1 -0
- package/dist/core-dist/assets/gruvbox-dark-medium-GsRaNv29.js +1 -0
- package/dist/core-dist/assets/gruvbox-dark-soft-CVdnzihN.js +1 -0
- package/dist/core-dist/assets/gruvbox-light-hard-CH1njM8p.js +1 -0
- package/dist/core-dist/assets/gruvbox-light-medium-DRw_LuNl.js +1 -0
- package/dist/core-dist/assets/gruvbox-light-soft-hJgmCMqR.js +1 -0
- package/dist/core-dist/assets/hack-CaT9iCJl.js +1 -0
- package/dist/core-dist/assets/haml-B8DHNrY2.js +1 -0
- package/dist/core-dist/assets/handlebars-BL8al0AC.js +1 -0
- package/dist/core-dist/assets/handlebars-DmLaz1e0.js +1 -0
- package/dist/core-dist/assets/haskell-Df6bDoY_.js +1 -0
- package/dist/core-dist/assets/haxe-CzTSHFRz.js +1 -0
- package/dist/core-dist/assets/hcl-BWvSN4gD.js +1 -0
- package/dist/core-dist/assets/hcl-DtV1sZF8.js +1 -0
- package/dist/core-dist/assets/hjson-D5-asLiD.js +1 -0
- package/dist/core-dist/assets/hlsl-D3lLCCz7.js +1 -0
- package/dist/core-dist/assets/houston-DnULxvSX.js +1 -0
- package/dist/core-dist/assets/html-BFgVUJOE.js +1 -0
- package/dist/core-dist/assets/html-GMplVEZG.js +1 -0
- package/dist/core-dist/assets/html-derivative-BFtXZ54Q.js +1 -0
- package/dist/core-dist/assets/html.worker-CwpTb9lJ.js +470 -0
- package/dist/core-dist/assets/htmlMode-D5h1Vspx.js +1 -0
- package/dist/core-dist/assets/http-jrhK8wxY.js +1 -0
- package/dist/core-dist/assets/hurl-irOxFIW8.js +1 -0
- package/dist/core-dist/assets/hxml-Bvhsp5Yf.js +1 -0
- package/dist/core-dist/assets/hy-DFXneXwc.js +1 -0
- package/dist/core-dist/assets/imba-DGztddWO.js +1 -0
- package/dist/core-dist/assets/index-BdWRYMFI.js +1 -0
- package/dist/core-dist/assets/index-C1hGVAGZ.css +1 -0
- package/dist/core-dist/assets/index-CnZ1kqmX.js +93 -0
- package/dist/core-dist/assets/index-Cz5UT4Mg.js +1 -0
- package/dist/core-dist/assets/index-DF9CAmXt.js +1 -0
- package/dist/core-dist/assets/index-DdmhUnZE.js +1 -0
- package/dist/core-dist/assets/indexes-8IGGD4eh.js +1 -0
- package/dist/core-dist/assets/infoDiagram-WHAUD3N6-BtU1uKqv.js +2 -0
- package/dist/core-dist/assets/ini-BEwlwnbL.js +1 -0
- package/dist/core-dist/assets/ini-Kd9XrMLS.js +1 -0
- package/dist/core-dist/assets/init-Gi6I4Gst.js +1 -0
- package/dist/core-dist/assets/java-CXBNlu9o.js +1 -0
- package/dist/core-dist/assets/java-CylS5w8V.js +1 -0
- package/dist/core-dist/assets/javascript-D-Y2jtao.js +1 -0
- package/dist/core-dist/assets/javascript-wDzz0qaB.js +1 -0
- package/dist/core-dist/assets/jetbrains-mono-cyrillic-wght-normal-D73BlboJ.woff2 +0 -0
- package/dist/core-dist/assets/jetbrains-mono-greek-wght-normal-Bw9x6K1M.woff2 +0 -0
- package/dist/core-dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2 +0 -0
- package/dist/core-dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2 +0 -0
- package/dist/core-dist/assets/jetbrains-mono-vietnamese-wght-normal-Bt-aOZkq.woff2 +0 -0
- package/dist/core-dist/assets/jinja-4LBKfQ-Z.js +1 -0
- package/dist/core-dist/assets/jison-wvAkD_A8.js +1 -0
- package/dist/core-dist/assets/journeyDiagram-XKPGCS4Q-oDLycO4E.js +139 -0
- package/dist/core-dist/assets/json-Cp-IABpG.js +1 -0
- package/dist/core-dist/assets/json.worker-BoL8UZqY.js +58 -0
- package/dist/core-dist/assets/json5-C9tS-k6U.js +1 -0
- package/dist/core-dist/assets/jsonMode-D0CjljtE.js +7 -0
- package/dist/core-dist/assets/jsonc-Des-eS-w.js +1 -0
- package/dist/core-dist/assets/jsonl-DcaNXYhu.js +1 -0
- package/dist/core-dist/assets/jsonnet-DFQXde-d.js +1 -0
- package/dist/core-dist/assets/jssm-C2t-YnRu.js +1 -0
- package/dist/core-dist/assets/jsx-g9-lgVsj.js +1 -0
- package/dist/core-dist/assets/julia-CxzCAyBv.js +1 -0
- package/dist/core-dist/assets/julia-cl7-CwDS.js +1 -0
- package/dist/core-dist/assets/kanagawa-dragon-CkXjmgJE.js +1 -0
- package/dist/core-dist/assets/kanagawa-lotus-CfQXZHmo.js +1 -0
- package/dist/core-dist/assets/kanagawa-wave-DWedfzmr.js +1 -0
- package/dist/core-dist/assets/kanban-definition-3W4ZIXB7-DIfa4j4L.js +89 -0
- package/dist/core-dist/assets/katex-DvXFAOB1.css +1 -0
- package/dist/core-dist/assets/kdl-DV7GczEv.js +1 -0
- package/dist/core-dist/assets/kotlin-BdnUsdx6.js +1 -0
- package/dist/core-dist/assets/kotlin-s7OhZKlX.js +1 -0
- package/dist/core-dist/assets/kusto-DZf3V79B.js +1 -0
- package/dist/core-dist/assets/laserwave-DUszq2jm.js +1 -0
- package/dist/core-dist/assets/latex-B4uzh10-.js +1 -0
- package/dist/core-dist/assets/layout-CeVIy2Vr.js +1 -0
- package/dist/core-dist/assets/lean-BZvkOJ9d.js +1 -0
- package/dist/core-dist/assets/less-9HpZscsL.js +2 -0
- package/dist/core-dist/assets/less-B1dDrJ26.js +1 -0
- package/dist/core-dist/assets/lexon-OrD6JF1K.js +1 -0
- package/dist/core-dist/assets/light-plus-B7mTdjB0.js +1 -0
- package/dist/core-dist/assets/linear-b4Urttzh.js +1 -0
- package/dist/core-dist/assets/liquid-DYVedYrR.js +1 -0
- package/dist/core-dist/assets/liquid-DshRxbC8.js +1 -0
- package/dist/core-dist/assets/llvm-BtvRca6l.js +1 -0
- package/dist/core-dist/assets/log-2UxHyX5q.js +1 -0
- package/dist/core-dist/assets/logo-BtOb2qkB.js +1 -0
- package/dist/core-dist/assets/logs-CpUgu3HF.js +1 -0
- package/dist/core-dist/assets/lspLanguageFeatures-QdnlfeMg.js +4 -0
- package/dist/core-dist/assets/lua-BbnMAYS6.js +1 -0
- package/dist/core-dist/assets/lua-Cyyb5UIc.js +1 -0
- package/dist/core-dist/assets/luau-C-HG3fhB.js +1 -0
- package/dist/core-dist/assets/m3-B8OfTtLu.js +1 -0
- package/dist/core-dist/assets/make-CHLpvVh8.js +1 -0
- package/dist/core-dist/assets/markdown-BFxVWTOG.js +1 -0
- package/dist/core-dist/assets/markdown-Cvjx9yec.js +1 -0
- package/dist/core-dist/assets/marko-DZsq8hO1.js +1 -0
- package/dist/core-dist/assets/material-theme-D5KoaKCx.js +1 -0
- package/dist/core-dist/assets/material-theme-darker-BfHTSMKl.js +1 -0
- package/dist/core-dist/assets/material-theme-lighter-B0m2ddpp.js +1 -0
- package/dist/core-dist/assets/material-theme-ocean-CyktbL80.js +1 -0
- package/dist/core-dist/assets/material-theme-palenight-Csfq5Kiy.js +1 -0
- package/dist/core-dist/assets/matlab-D7o27uSR.js +1 -0
- package/dist/core-dist/assets/mdc-DUICxH0z.js +1 -0
- package/dist/core-dist/assets/mdx-Cmh6b_Ma.js +1 -0
- package/dist/core-dist/assets/mdx-DDV0dHdJ.js +1 -0
- package/dist/core-dist/assets/mermaid-VLURNSYL-l6Ov7ssW.js +385 -0
- package/dist/core-dist/assets/mermaid-mWjccvbQ.js +1 -0
- package/dist/core-dist/assets/mermaid.core-BfxuFUZC.js +191 -0
- package/dist/core-dist/assets/min-CFxwdQq0.js +1 -0
- package/dist/core-dist/assets/min-dark-CafNBF8u.js +1 -0
- package/dist/core-dist/assets/min-light-CTRr51gU.js +1 -0
- package/dist/core-dist/assets/mindmap-definition-VGOIOE7T-CipFHRae.js +68 -0
- package/dist/core-dist/assets/mips-CiqrrVzr.js +1 -0
- package/dist/core-dist/assets/mipsasm-CKIfxQSi.js +1 -0
- package/dist/core-dist/assets/mojo-B93PlW-d.js +1 -0
- package/dist/core-dist/assets/monokai-D4h5O-jR.js +1 -0
- package/dist/core-dist/assets/moonbit-Ba13S78F.js +1 -0
- package/dist/core-dist/assets/move-Bu9oaDYs.js +1 -0
- package/dist/core-dist/assets/msdax-DmeGPVcC.js +1 -0
- package/dist/core-dist/assets/mysql-C_tMU-Nz.js +1 -0
- package/dist/core-dist/assets/narrat-DRg8JJMk.js +1 -0
- package/dist/core-dist/assets/nextflow-BrzmwbiE.js +1 -0
- package/dist/core-dist/assets/nginx-DknmC5AR.js +1 -0
- package/dist/core-dist/assets/night-owl-C39BiMTA.js +1 -0
- package/dist/core-dist/assets/nim-CVrawwO9.js +1 -0
- package/dist/core-dist/assets/nix-CwoSXNpI.js +1 -0
- package/dist/core-dist/assets/nord-Ddv68eIx.js +1 -0
- package/dist/core-dist/assets/nushell-C-sUppwS.js +1 -0
- package/dist/core-dist/assets/objective-c-BDtDVThU.js +1 -0
- package/dist/core-dist/assets/objective-c-DXmwc3jG.js +1 -0
- package/dist/core-dist/assets/objective-cpp-CLxacb5B.js +1 -0
- package/dist/core-dist/assets/ocaml-C0hk2d4L.js +1 -0
- package/dist/core-dist/assets/one-dark-pro-DVMEJ2y_.js +1 -0
- package/dist/core-dist/assets/one-light-PoHY5YXO.js +1 -0
- package/dist/core-dist/assets/openscad-C4EeE6gA.js +1 -0
- package/dist/core-dist/assets/ordinal-BENe2yWM.js +1 -0
- package/dist/core-dist/assets/pascal-D93ZcfNL.js +1 -0
- package/dist/core-dist/assets/pascal-vHIfCaH5.js +1 -0
- package/dist/core-dist/assets/pascaligo-DtZ0uQbO.js +1 -0
- package/dist/core-dist/assets/perl-C0TMdlhV.js +1 -0
- package/dist/core-dist/assets/perl-Ub6l9XKa.js +1 -0
- package/dist/core-dist/assets/pgsql-BlNEE0v7.js +1 -0
- package/dist/core-dist/assets/php-BBUBE1dy.js +1 -0
- package/dist/core-dist/assets/php-CDn_0X-4.js +1 -0
- package/dist/core-dist/assets/pieDiagram-ADFJNKIX-BUiWlVgQ.js +30 -0
- package/dist/core-dist/assets/pkl-u5AG7uiY.js +1 -0
- package/dist/core-dist/assets/pla-DSh2-awV.js +1 -0
- package/dist/core-dist/assets/plastic-3e1v2bzS.js +1 -0
- package/dist/core-dist/assets/plsql-ChMvpjG-.js +1 -0
- package/dist/core-dist/assets/po-BTJTHyun.js +1 -0
- package/dist/core-dist/assets/poimandres-CS3Unz2-.js +1 -0
- package/dist/core-dist/assets/polar-C0HS_06l.js +1 -0
- package/dist/core-dist/assets/postcss-CXtECtnM.js +1 -0
- package/dist/core-dist/assets/postiats-CocnycG-.js +1 -0
- package/dist/core-dist/assets/powerquery-CEu0bR-o.js +1 -0
- package/dist/core-dist/assets/powerquery-tScXyioY.js +1 -0
- package/dist/core-dist/assets/powershell-COWaemsV.js +1 -0
- package/dist/core-dist/assets/powershell-Dpen1YoG.js +1 -0
- package/dist/core-dist/assets/prisma-Dd19v3D-.js +1 -0
- package/dist/core-dist/assets/prolog-CbFg5uaA.js +1 -0
- package/dist/core-dist/assets/proto-C7zT0LnQ.js +1 -0
- package/dist/core-dist/assets/protobuf-Brw8urJB.js +2 -0
- package/dist/core-dist/assets/pug-8SOpv6rk.js +1 -0
- package/dist/core-dist/assets/pug-CGlum2m_.js +1 -0
- package/dist/core-dist/assets/puppet-BMWR74SV.js +1 -0
- package/dist/core-dist/assets/purescript-CklMAg4u.js +1 -0
- package/dist/core-dist/assets/python-B6aJPvgy.js +1 -0
- package/dist/core-dist/assets/python-PS988bn3.js +1 -0
- package/dist/core-dist/assets/qml-3beO22l8.js +1 -0
- package/dist/core-dist/assets/qmldir-C8lEn-DE.js +1 -0
- package/dist/core-dist/assets/qsharp-Bw9ernYp.js +1 -0
- package/dist/core-dist/assets/qss-IeuSbFQv.js +1 -0
- package/dist/core-dist/assets/quadrantDiagram-AYHSOK5B-C_TyzYH5.js +7 -0
- package/dist/core-dist/assets/queries.store-C0c7hpRl.js +1 -0
- package/dist/core-dist/assets/r-Dspwwk_N.js +1 -0
- package/dist/core-dist/assets/r-j7ic8hl3.js +1 -0
- package/dist/core-dist/assets/racket-BqYA7rlc.js +1 -0
- package/dist/core-dist/assets/raku-DXvB9xmW.js +1 -0
- package/dist/core-dist/assets/razor-C1TweQQi.js +1 -0
- package/dist/core-dist/assets/razor-DwHq5O0V.js +1 -0
- package/dist/core-dist/assets/red-bN70gL4F.js +1 -0
- package/dist/core-dist/assets/redis-Bu5POkcn.js +1 -0
- package/dist/core-dist/assets/redshift-Bs9aos_-.js +1 -0
- package/dist/core-dist/assets/reg-C-SQnVFl.js +1 -0
- package/dist/core-dist/assets/regexp-CDVJQ6XC.js +1 -0
- package/dist/core-dist/assets/rel-C3B-1QV4.js +1 -0
- package/dist/core-dist/assets/requirementDiagram-UZGBJVZJ-BVMFXDeK.js +64 -0
- package/dist/core-dist/assets/restructuredtext-CqXO7rUv.js +1 -0
- package/dist/core-dist/assets/riscv-BM1_JUlF.js +1 -0
- package/dist/core-dist/assets/rose-pine-dawn-DHQR4-dF.js +1 -0
- package/dist/core-dist/assets/rose-pine-moon-D4_iv3hh.js +1 -0
- package/dist/core-dist/assets/rose-pine-qdsjHGoJ.js +1 -0
- package/dist/core-dist/assets/rosmsg-BJDFO7_C.js +1 -0
- package/dist/core-dist/assets/rst-B0xPkSld.js +1 -0
- package/dist/core-dist/assets/ruby-BvKwtOVI.js +1 -0
- package/dist/core-dist/assets/ruby-zBfavPgS.js +1 -0
- package/dist/core-dist/assets/runner-tab-C3c2d6Aw.js +915 -0
- package/dist/core-dist/assets/runner-tab-Dvl_Svmm.css +1 -0
- package/dist/core-dist/assets/rust-B1yitclQ.js +1 -0
- package/dist/core-dist/assets/rust-BzKRNQWT.js +1 -0
- package/dist/core-dist/assets/sankeyDiagram-TZEHDZUN-C3bvRR0p.js +10 -0
- package/dist/core-dist/assets/sas-cz2c8ADy.js +1 -0
- package/dist/core-dist/assets/sass-Cj5Yp3dK.js +1 -0
- package/dist/core-dist/assets/sb-BBc9UKZt.js +1 -0
- package/dist/core-dist/assets/scala-C151Ov-r.js +1 -0
- package/dist/core-dist/assets/scala-D9hQfWCl.js +1 -0
- package/dist/core-dist/assets/schema-BV8gahQJ.js +1 -0
- package/dist/core-dist/assets/scheme-BPhDTwHR.js +1 -0
- package/dist/core-dist/assets/scheme-C98Dy4si.js +1 -0
- package/dist/core-dist/assets/scss-CBJaRo0y.js +3 -0
- package/dist/core-dist/assets/scss-OYdSNvt2.js +1 -0
- package/dist/core-dist/assets/sdbl-DVxCFoDh.js +1 -0
- package/dist/core-dist/assets/sequenceDiagram-WL72ISMW-3uaEP9A9.js +145 -0
- package/dist/core-dist/assets/shaderlab-Dg9Lc6iA.js +1 -0
- package/dist/core-dist/assets/shell-DiJ1NA_G.js +1 -0
- package/dist/core-dist/assets/shellscript-Yzrsuije.js +1 -0
- package/dist/core-dist/assets/shellsession-BADoaaVG.js +1 -0
- package/dist/core-dist/assets/slack-dark-BthQWCQV.js +1 -0
- package/dist/core-dist/assets/slack-ochin-DqwNpetd.js +1 -0
- package/dist/core-dist/assets/smalltalk-BERRCDM3.js +1 -0
- package/dist/core-dist/assets/snazzy-light-Bw305WKR.js +1 -0
- package/dist/core-dist/assets/solarized-dark-DXbdFlpD.js +1 -0
- package/dist/core-dist/assets/solarized-light-L9t79GZl.js +1 -0
- package/dist/core-dist/assets/solidity-Db0IVjzk.js +1 -0
- package/dist/core-dist/assets/solidity-rGO070M0.js +1 -0
- package/dist/core-dist/assets/sophia-CnS9iZB_.js +1 -0
- package/dist/core-dist/assets/soy-Brmx7dQM.js +1 -0
- package/dist/core-dist/assets/sparql-CJmd_6j2.js +1 -0
- package/dist/core-dist/assets/sparql-rVzFXLq3.js +1 -0
- package/dist/core-dist/assets/spinner-CqDbUqU4.js +1 -0
- package/dist/core-dist/assets/splunk-BtCnVYZw.js +1 -0
- package/dist/core-dist/assets/sql-BLtJtn59.js +1 -0
- package/dist/core-dist/assets/sql-ClhHkBeG.js +1 -0
- package/dist/core-dist/assets/ssh-config-_ykCGR6B.js +1 -0
- package/dist/core-dist/assets/st-CHwy0fLd.js +1 -0
- package/dist/core-dist/assets/stata-BH5u7GGu.js +1 -0
- package/dist/core-dist/assets/stateDiagram-FKZM4ZOC-yAiNIUHs.js +1 -0
- package/dist/core-dist/assets/stateDiagram-v2-4FDKWEC3-BRP3xAkf.js +1 -0
- package/dist/core-dist/assets/stylus-BEDo0Tqx.js +1 -0
- package/dist/core-dist/assets/svelte-zxCyuUbr.js +1 -0
- package/dist/core-dist/assets/swift-CnmFD0ga.js +1 -0
- package/dist/core-dist/assets/swift-Dg5xB15N.js +1 -0
- package/dist/core-dist/assets/synthwave-84-CbfX1IO0.js +1 -0
- package/dist/core-dist/assets/system-verilog-CnnmHF94.js +1 -0
- package/dist/core-dist/assets/systemd-4A_iFExJ.js +1 -0
- package/dist/core-dist/assets/systemverilog-Bs9z6M-B.js +1 -0
- package/dist/core-dist/assets/talonscript-CkByrt1z.js +1 -0
- package/dist/core-dist/assets/tasl-QIJgUcNo.js +1 -0
- package/dist/core-dist/assets/tcl-Dm6ycUr_.js +1 -0
- package/dist/core-dist/assets/tcl-dwOrl1Do.js +1 -0
- package/dist/core-dist/assets/templ-W15q3VgB.js +1 -0
- package/dist/core-dist/assets/terraform-BETggiCN.js +1 -0
- package/dist/core-dist/assets/tex-CvyZ59Mk.js +1 -0
- package/dist/core-dist/assets/timeline-definition-IT6M3QCI-Bzobs3Yi.js +61 -0
- package/dist/core-dist/assets/tokyo-night-hegEt444.js +1 -0
- package/dist/core-dist/assets/toml-vGWfd6FD.js +1 -0
- package/dist/core-dist/assets/treemap-KMMF4GRG-Dl0T757g.js +128 -0
- package/dist/core-dist/assets/ts-tags-zn1MmPIZ.js +1 -0
- package/dist/core-dist/assets/ts.worker-BH9nVgjN.js +67718 -0
- package/dist/core-dist/assets/tsMode-Byuiqukj.js +11 -0
- package/dist/core-dist/assets/tsv-B_m7g4N7.js +1 -0
- package/dist/core-dist/assets/tsx-COt5Ahok.js +1 -0
- package/dist/core-dist/assets/turtle-BsS91CYL.js +1 -0
- package/dist/core-dist/assets/twig-CO9l9SDP.js +1 -0
- package/dist/core-dist/assets/twig-Csy3S7wG.js +1 -0
- package/dist/core-dist/assets/typescript-B08nec4G.js +1 -0
- package/dist/core-dist/assets/typescript-BPQ3VLAy.js +1 -0
- package/dist/core-dist/assets/typespec-BGHnOYBU.js +1 -0
- package/dist/core-dist/assets/typespec-Btyra-wh.js +1 -0
- package/dist/core-dist/assets/typst-DHCkPAjA.js +1 -0
- package/dist/core-dist/assets/v-BcVCzyr7.js +1 -0
- package/dist/core-dist/assets/vala-CsfeWuGM.js +1 -0
- package/dist/core-dist/assets/vb-D17OF-Vu.js +1 -0
- package/dist/core-dist/assets/vb-Db0cS2oM.js +1 -0
- package/dist/core-dist/assets/verilog-BQ8w6xss.js +1 -0
- package/dist/core-dist/assets/vesper-DU1UobuO.js +1 -0
- package/dist/core-dist/assets/vhdl-CeAyd5Ju.js +1 -0
- package/dist/core-dist/assets/viml-CJc9bBzg.js +1 -0
- package/dist/core-dist/assets/visualizer-BHvXt3Ng.js +1 -0
- package/dist/core-dist/assets/vitesse-black-Bkuqu6BP.js +1 -0
- package/dist/core-dist/assets/vitesse-dark-D0r3Knsf.js +1 -0
- package/dist/core-dist/assets/vitesse-light-CVO1_9PV.js +1 -0
- package/dist/core-dist/assets/vue-DN_0RTcg.js +1 -0
- package/dist/core-dist/assets/vue-html-AaS7Mt5G.js +1 -0
- package/dist/core-dist/assets/vue-vine-CQOfvN7w.js +1 -0
- package/dist/core-dist/assets/vyper-CDx5xZoG.js +1 -0
- package/dist/core-dist/assets/wasm-CG6Dc4jp.js +1 -0
- package/dist/core-dist/assets/wasm-MzD3tlZU.js +1 -0
- package/dist/core-dist/assets/wenyan-BV7otONQ.js +1 -0
- package/dist/core-dist/assets/wgsl-BTesnYfV.js +298 -0
- package/dist/core-dist/assets/wgsl-Dx-B1_4e.js +1 -0
- package/dist/core-dist/assets/wikitext-BhOHFoWU.js +1 -0
- package/dist/core-dist/assets/wit-5i3qLPDT.js +1 -0
- package/dist/core-dist/assets/wolfram-lXgVvXCa.js +1 -0
- package/dist/core-dist/assets/xml-CvXv2bc8.js +1 -0
- package/dist/core-dist/assets/xml-sdJ4AIDG.js +1 -0
- package/dist/core-dist/assets/xsl-CtQFsRM5.js +1 -0
- package/dist/core-dist/assets/xychartDiagram-PRI3JC2R-CnlrCSYS.js +7 -0
- package/dist/core-dist/assets/yaml-BMIQXL0J.js +1 -0
- package/dist/core-dist/assets/yaml-Buea-lGh.js +1 -0
- package/dist/core-dist/assets/zenscript-DVFEvuxE.js +1 -0
- package/dist/core-dist/assets/zig-VOosw3JB.js +1 -0
- package/dist/core-dist/image.png +0 -0
- package/dist/core-dist/index.html +14 -0
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/mermaid-VLURNSYL-l6Ov7ssW.js","assets/index-CnZ1kqmX.js","assets/index-C1hGVAGZ.css","assets/queries.store-C0c7hpRl.js","assets/index-DF9CAmXt.js","assets/spinner-CqDbUqU4.js","assets/dagre-6UL2VRFP-CLN6NsN5.js","assets/graph-BX6qryEG.js","assets/_baseUniq-B_K25dSy.js","assets/layout-CeVIy2Vr.js","assets/min-CFxwdQq0.js","assets/clone--nCRoznC.js","assets/cose-bilkent-S5V4N54A-DqXTIalc.js","assets/cytoscape.esm-5J0xJHOV.js","assets/c4Diagram-YG6GDRKO-gX9j2-0Z.js","assets/chunk-TZMSLE5B-DCoUoEZE.js","assets/flowDiagram-NV44I4VS-DgOYOnAl.js","assets/chunk-FMBD7UC4-BtON21Ec.js","assets/chunk-55IACEB6-a0l2Crfx.js","assets/chunk-QN33PNHL-NNHAc9s8.js","assets/channel-C8qB82xE.js","assets/erDiagram-Q2GNP2WA-CkGXgXvC.js","assets/gitGraphDiagram-NY62KEGX-Bcm5bNVl.js","assets/chunk-4BX2VUAB-C6PIA6wq.js","assets/chunk-QZHKN3VN-CYogV3aS.js","assets/treemap-KMMF4GRG-Dl0T757g.js","assets/ganttDiagram-JELNMOA3-DRLDy2OX.js","assets/linear-b4Urttzh.js","assets/init-Gi6I4Gst.js","assets/defaultLocale-DX6XiGOO.js","assets/infoDiagram-WHAUD3N6-BtU1uKqv.js","assets/pieDiagram-ADFJNKIX-BUiWlVgQ.js","assets/arc-CM-cekU0.js","assets/ordinal-BENe2yWM.js","assets/quadrantDiagram-AYHSOK5B-C_TyzYH5.js","assets/xychartDiagram-PRI3JC2R-CnlrCSYS.js","assets/requirementDiagram-UZGBJVZJ-BVMFXDeK.js","assets/sequenceDiagram-WL72ISMW-3uaEP9A9.js","assets/classDiagram-2ON5EDUG-BtPJeqYQ.js","assets/chunk-B4BG7PRW-CypUhkY3.js","assets/classDiagram-v2-WZHVMYZB-BtPJeqYQ.js","assets/stateDiagram-FKZM4ZOC-yAiNIUHs.js","assets/chunk-DI55MBZ5-pM3ud_GL.js","assets/stateDiagram-v2-4FDKWEC3-BRP3xAkf.js","assets/journeyDiagram-XKPGCS4Q-oDLycO4E.js","assets/timeline-definition-IT6M3QCI-Bzobs3Yi.js","assets/mindmap-definition-VGOIOE7T-CipFHRae.js","assets/kanban-definition-3W4ZIXB7-DIfa4j4L.js","assets/sankeyDiagram-TZEHDZUN-C3bvRR0p.js","assets/diagram-S2PKOQOG-BqUHyr8W.js","assets/diagram-QEK2KX5R-BoH7syf_.js","assets/blockDiagram-VD42YOAC-DeY844Kv.js","assets/architectureDiagram-VXUJARFQ-BCmD-Gj_.js","assets/diagram-PSM6KHXK-ByycaI76.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{Y as am,_ as ft}from"./index-CnZ1kqmX.js";import{k as Wc}from"./mermaid-VLURNSYL-l6Ov7ssW.js";var hl={name:"mermaid",version:"11.12.2",description:"Markdown-ish syntax for generating flowcharts, mindmaps, sequence diagrams, class diagrams, gantt charts, git graphs and more.",type:"module",module:"./dist/mermaid.core.mjs",types:"./dist/mermaid.d.ts",exports:{".":{types:"./dist/mermaid.d.ts",import:"./dist/mermaid.core.mjs",default:"./dist/mermaid.core.mjs"},"./*":"./*"},keywords:["diagram","markdown","flowchart","sequence diagram","gantt","class diagram","git graph","mindmap","packet diagram","c4 diagram","er diagram","pie chart","pie diagram","quadrant chart","requirement diagram","graph"],scripts:{clean:"rimraf dist",dev:"pnpm -w dev","docs:code":"typedoc src/defaultConfig.ts src/config.ts src/mermaid.ts && prettier --write ./src/docs/config/setup","docs:build":"rimraf ../../docs && pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts","docs:verify":"pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts --verify","docs:pre:vitepress":"pnpm --filter ./src/docs prefetch && rimraf src/vitepress && pnpm docs:code && tsx scripts/docs.cli.mts --vitepress && pnpm --filter ./src/vitepress install --no-frozen-lockfile --ignore-scripts","docs:build:vitepress":"pnpm docs:pre:vitepress && (cd src/vitepress && pnpm run build) && cpy --flat src/docs/landing/ ./src/vitepress/.vitepress/dist/landing","docs:dev":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:dev:docker":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev:docker" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:serve":"pnpm docs:build:vitepress && vitepress serve src/vitepress","docs:spellcheck":'cspell "src/docs/**/*.md"',"docs:release-version":"tsx scripts/update-release-version.mts","docs:verify-version":"tsx scripts/update-release-version.mts --verify","types:build-config":"tsx scripts/create-types-from-json-schema.mts","types:verify-config":"tsx scripts/create-types-from-json-schema.mts --verify",checkCircle:"npx madge --circular ./src",prepublishOnly:"pnpm docs:verify-version"},repository:{type:"git",url:"https://github.com/mermaid-js/mermaid"},author:"Knut Sveidqvist",license:"MIT",standard:{ignore:["**/parser/*.js","dist/**/*.js","cypress/**/*.js"],globals:["page"]},dependencies:{"@braintree/sanitize-url":"^7.1.1","@iconify/utils":"^3.0.1","@mermaid-js/parser":"workspace:^","@types/d3":"^7.4.3",cytoscape:"^3.29.3","cytoscape-cose-bilkent":"^4.1.0","cytoscape-fcose":"^2.2.0",d3:"^7.9.0","d3-sankey":"^0.12.3","dagre-d3-es":"7.0.13",dayjs:"^1.11.18",dompurify:"^3.2.5",katex:"^0.16.22",khroma:"^2.1.0","lodash-es":"^4.17.21",marked:"^16.2.1",roughjs:"^4.6.6",stylis:"^4.3.6","ts-dedent":"^2.2.0",uuid:"^11.1.0"},devDependencies:{"@adobe/jsonschema2md":"^8.0.5","@iconify/types":"^2.0.0","@types/cytoscape":"^3.21.9","@types/cytoscape-fcose":"^2.2.4","@types/d3-sankey":"^0.12.4","@types/d3-scale":"^4.0.9","@types/d3-scale-chromatic":"^3.1.0","@types/d3-selection":"^3.0.11","@types/d3-shape":"^3.1.7","@types/jsdom":"^21.1.7","@types/katex":"^0.16.7","@types/lodash-es":"^4.17.12","@types/micromatch":"^4.0.9","@types/stylis":"^4.2.7","@types/uuid":"^10.0.0",ajv:"^8.17.1",canvas:"^3.1.2",chokidar:"3.6.0",concurrently:"^9.1.2","csstree-validator":"^4.0.1",globby:"^14.1.0",jison:"^0.4.18","js-base64":"^3.7.8",jsdom:"^26.1.0","json-schema-to-typescript":"^15.0.4",micromatch:"^4.0.8","path-browserify":"^1.0.1",prettier:"^3.5.3",remark:"^15.0.1","remark-frontmatter":"^5.0.0","remark-gfm":"^4.0.1",rimraf:"^6.0.1","start-server-and-test":"^2.0.13","type-fest":"^4.35.0",typedoc:"^0.28.12","typedoc-plugin-markdown":"^4.8.1",typescript:"~5.7.3","unist-util-flatmap":"^1.0.0","unist-util-visit":"^5.0.0",vitepress:"^1.6.4","vitepress-plugin-search":"1.0.4-alpha.22"},files:["dist/","README.md"],publishConfig:{access:"public"}},oa={exports:{}},nm=oa.exports,ul;function sm(){return ul||(ul=1,(function(e,t){(function(r,i){e.exports=i()})(nm,(function(){var r=1e3,i=6e4,a=36e5,n="millisecond",o="second",s="minute",l="hour",c="day",h="week",u="month",f="quarter",d="year",g="date",m="Invalid Date",y=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,x=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,b={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(L){var A=["th","st","nd","rd"],k=L%100;return"["+L+(A[(k-20)%10]||A[k]||A[0])+"]"}},_=function(L,A,k){var $=String(L);return!$||$.length>=A?L:""+Array(A+1-$.length).join(k)+L},w={s:_,z:function(L){var A=-L.utcOffset(),k=Math.abs(A),$=Math.floor(k/60),M=k%60;return(A<=0?"+":"-")+_($,2,"0")+":"+_(M,2,"0")},m:function L(A,k){if(A.date()<k.date())return-L(k,A);var $=12*(k.year()-A.year())+(k.month()-A.month()),M=A.clone().add($,u),q=k-M<0,V=A.clone().add($+(q?-1:1),u);return+(-($+(k-M)/(q?M-V:V-M))||0)},a:function(L){return L<0?Math.ceil(L)||0:Math.floor(L)},p:function(L){return{M:u,y:d,w:h,d:c,D:g,h:l,m:s,s:o,ms:n,Q:f}[L]||String(L||"").toLowerCase().replace(/s$/,"")},u:function(L){return L===void 0}},v="en",B={};B[v]=b;var T="$isDayjsObject",O=function(L){return L instanceof N||!(!L||!L[T])},R=function L(A,k,$){var M;if(!A)return v;if(typeof A=="string"){var q=A.toLowerCase();B[q]&&(M=q),k&&(B[q]=k,M=q);var V=A.split("-");if(!M&&V.length>1)return L(V[0])}else{var Z=A.name;B[Z]=A,M=Z}return!$&&M&&(v=M),M||!$&&v},D=function(L,A){if(O(L))return L.clone();var k=typeof A=="object"?A:{};return k.date=L,k.args=arguments,new N(k)},E=w;E.l=R,E.i=O,E.w=function(L,A){return D(L,{locale:A.$L,utc:A.$u,x:A.$x,$offset:A.$offset})};var N=(function(){function L(k){this.$L=R(k.locale,null,!0),this.parse(k),this.$x=this.$x||k.x||{},this[T]=!0}var A=L.prototype;return A.parse=function(k){this.$d=(function($){var M=$.date,q=$.utc;if(M===null)return new Date(NaN);if(E.u(M))return new Date;if(M instanceof Date)return new Date(M);if(typeof M=="string"&&!/Z$/i.test(M)){var V=M.match(y);if(V){var Z=V[2]-1||0,J=(V[7]||"0").substring(0,3);return q?new Date(Date.UTC(V[1],Z,V[3]||1,V[4]||0,V[5]||0,V[6]||0,J)):new Date(V[1],Z,V[3]||1,V[4]||0,V[5]||0,V[6]||0,J)}}return new Date(M)})(k),this.init()},A.init=function(){var k=this.$d;this.$y=k.getFullYear(),this.$M=k.getMonth(),this.$D=k.getDate(),this.$W=k.getDay(),this.$H=k.getHours(),this.$m=k.getMinutes(),this.$s=k.getSeconds(),this.$ms=k.getMilliseconds()},A.$utils=function(){return E},A.isValid=function(){return this.$d.toString()!==m},A.isSame=function(k,$){var M=D(k);return this.startOf($)<=M&&M<=this.endOf($)},A.isAfter=function(k,$){return D(k)<this.startOf($)},A.isBefore=function(k,$){return this.endOf($)<D(k)},A.$g=function(k,$,M){return E.u(k)?this[$]:this.set(M,k)},A.unix=function(){return Math.floor(this.valueOf()/1e3)},A.valueOf=function(){return this.$d.getTime()},A.startOf=function(k,$){var M=this,q=!!E.u($)||$,V=E.p(k),Z=function(Xt,mt){var re=E.w(M.$u?Date.UTC(M.$y,mt,Xt):new Date(M.$y,mt,Xt),M);return q?re:re.endOf(c)},J=function(Xt,mt){return E.w(M.toDate()[Xt].apply(M.toDate("s"),(q?[0,0,0,0]:[23,59,59,999]).slice(mt)),M)},X=this.$W,ct=this.$M,nt=this.$D,xt="set"+(this.$u?"UTC":"");switch(V){case d:return q?Z(1,0):Z(31,11);case u:return q?Z(1,ct):Z(0,ct+1);case h:var bt=this.$locale().weekStart||0,ee=(X<bt?X+7:X)-bt;return Z(q?nt-ee:nt+(6-ee),ct);case c:case g:return J(xt+"Hours",0);case l:return J(xt+"Minutes",1);case s:return J(xt+"Seconds",2);case o:return J(xt+"Milliseconds",3);default:return this.clone()}},A.endOf=function(k){return this.startOf(k,!1)},A.$set=function(k,$){var M,q=E.p(k),V="set"+(this.$u?"UTC":""),Z=(M={},M[c]=V+"Date",M[g]=V+"Date",M[u]=V+"Month",M[d]=V+"FullYear",M[l]=V+"Hours",M[s]=V+"Minutes",M[o]=V+"Seconds",M[n]=V+"Milliseconds",M)[q],J=q===c?this.$D+($-this.$W):$;if(q===u||q===d){var X=this.clone().set(g,1);X.$d[Z](J),X.init(),this.$d=X.set(g,Math.min(this.$D,X.daysInMonth())).$d}else Z&&this.$d[Z](J);return this.init(),this},A.set=function(k,$){return this.clone().$set(k,$)},A.get=function(k){return this[E.p(k)]()},A.add=function(k,$){var M,q=this;k=Number(k);var V=E.p($),Z=function(ct){var nt=D(q);return E.w(nt.date(nt.date()+Math.round(ct*k)),q)};if(V===u)return this.set(u,this.$M+k);if(V===d)return this.set(d,this.$y+k);if(V===c)return Z(1);if(V===h)return Z(7);var J=(M={},M[s]=i,M[l]=a,M[o]=r,M)[V]||1,X=this.$d.getTime()+k*J;return E.w(X,this)},A.subtract=function(k,$){return this.add(-1*k,$)},A.format=function(k){var $=this,M=this.$locale();if(!this.isValid())return M.invalidDate||m;var q=k||"YYYY-MM-DDTHH:mm:ssZ",V=E.z(this),Z=this.$H,J=this.$m,X=this.$M,ct=M.weekdays,nt=M.months,xt=M.meridiem,bt=function(mt,re,Kt,xe){return mt&&(mt[re]||mt($,q))||Kt[re].slice(0,xe)},ee=function(mt){return E.s(Z%12||12,mt,"0")},Xt=xt||function(mt,re,Kt){var xe=mt<12?"AM":"PM";return Kt?xe.toLowerCase():xe};return q.replace(x,(function(mt,re){return re||(function(Kt){switch(Kt){case"YY":return String($.$y).slice(-2);case"YYYY":return E.s($.$y,4,"0");case"M":return X+1;case"MM":return E.s(X+1,2,"0");case"MMM":return bt(M.monthsShort,X,nt,3);case"MMMM":return bt(nt,X);case"D":return $.$D;case"DD":return E.s($.$D,2,"0");case"d":return String($.$W);case"dd":return bt(M.weekdaysMin,$.$W,ct,2);case"ddd":return bt(M.weekdaysShort,$.$W,ct,3);case"dddd":return ct[$.$W];case"H":return String(Z);case"HH":return E.s(Z,2,"0");case"h":return ee(1);case"hh":return ee(2);case"a":return Xt(Z,J,!0);case"A":return Xt(Z,J,!1);case"m":return String(J);case"mm":return E.s(J,2,"0");case"s":return String($.$s);case"ss":return E.s($.$s,2,"0");case"SSS":return E.s($.$ms,3,"0");case"Z":return V}return null})(mt)||V.replace(":","")}))},A.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},A.diff=function(k,$,M){var q,V=this,Z=E.p($),J=D(k),X=(J.utcOffset()-this.utcOffset())*i,ct=this-J,nt=function(){return E.m(V,J)};switch(Z){case d:q=nt()/12;break;case u:q=nt();break;case f:q=nt()/3;break;case h:q=(ct-X)/6048e5;break;case c:q=(ct-X)/864e5;break;case l:q=ct/a;break;case s:q=ct/i;break;case o:q=ct/r;break;default:q=ct}return M?q:E.a(q)},A.daysInMonth=function(){return this.endOf(u).$D},A.$locale=function(){return B[this.$L]},A.locale=function(k,$){if(!k)return this.$L;var M=this.clone(),q=R(k,$,!0);return q&&(M.$L=q),M},A.clone=function(){return E.w(this.$d,this)},A.toDate=function(){return new Date(this.valueOf())},A.toJSON=function(){return this.isValid()?this.toISOString():null},A.toISOString=function(){return this.$d.toISOString()},A.toString=function(){return this.$d.toUTCString()},L})(),I=N.prototype;return D.prototype=I,[["$ms",n],["$s",o],["$m",s],["$H",l],["$W",c],["$M",u],["$y",d],["$D",g]].forEach((function(L){I[L[1]]=function(A){return this.$g(A,L[0],L[1])}})),D.extend=function(L,A){return L.$i||(L(A,N,D),L.$i=!0),D},D.locale=R,D.isDayjs=O,D.unix=function(L){return D(1e3*L)},D.en=B[v],D.Ls=B,D.p={},D}))})(oa)),oa.exports}var om=sm();const lm=am(om);var zc=Object.defineProperty,p=(e,t)=>zc(e,"name",{value:t,configurable:!0}),cm=(e,t)=>{for(var r in t)zc(e,r,{get:t[r],enumerable:!0})},ve={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},F={trace:p((...e)=>{},"trace"),debug:p((...e)=>{},"debug"),info:p((...e)=>{},"info"),warn:p((...e)=>{},"warn"),error:p((...e)=>{},"error"),fatal:p((...e)=>{},"fatal")},Qs=p(function(e="fatal"){let t=ve.fatal;typeof e=="string"?e.toLowerCase()in ve&&(t=ve[e]):typeof e=="number"&&(t=e),F.trace=()=>{},F.debug=()=>{},F.info=()=>{},F.warn=()=>{},F.error=()=>{},F.fatal=()=>{},t<=ve.fatal&&(F.fatal=console.error?console.error.bind(console,Zt("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",Zt("FATAL"))),t<=ve.error&&(F.error=console.error?console.error.bind(console,Zt("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",Zt("ERROR"))),t<=ve.warn&&(F.warn=console.warn?console.warn.bind(console,Zt("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",Zt("WARN"))),t<=ve.info&&(F.info=console.info?console.info.bind(console,Zt("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",Zt("INFO"))),t<=ve.debug&&(F.debug=console.debug?console.debug.bind(console,Zt("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Zt("DEBUG"))),t<=ve.trace&&(F.trace=console.debug?console.debug.bind(console,Zt("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Zt("TRACE")))},"setLogLevel"),Zt=p(e=>`%c${lm().format("ss.SSS")} : ${e} : `,"format");const la={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:e=>e>=255?255:e<0?0:e,g:e=>e>=255?255:e<0?0:e,b:e=>e>=255?255:e<0?0:e,h:e=>e%360,s:e=>e>=100?100:e<0?0:e,l:e=>e>=100?100:e<0?0:e,a:e=>e>=1?1:e<0?0:e},toLinear:e=>{const t=e/255;return e>.03928?Math.pow((t+.055)/1.055,2.4):t/12.92},hue2rgb:(e,t,r)=>(r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+(t-e)*6*r:r<1/2?t:r<2/3?e+(t-e)*(2/3-r)*6:e),hsl2rgb:({h:e,s:t,l:r},i)=>{if(!t)return r*2.55;e/=360,t/=100,r/=100;const a=r<.5?r*(1+t):r+t-r*t,n=2*r-a;switch(i){case"r":return la.hue2rgb(n,a,e+1/3)*255;case"g":return la.hue2rgb(n,a,e)*255;case"b":return la.hue2rgb(n,a,e-1/3)*255}},rgb2hsl:({r:e,g:t,b:r},i)=>{e/=255,t/=255,r/=255;const a=Math.max(e,t,r),n=Math.min(e,t,r),o=(a+n)/2;if(i==="l")return o*100;if(a===n)return 0;const s=a-n,l=o>.5?s/(2-a-n):s/(a+n);if(i==="s")return l*100;switch(a){case e:return((t-r)/s+(t<r?6:0))*60;case t:return((r-e)/s+2)*60;case r:return((e-t)/s+4)*60;default:return-1}}},hm={clamp:(e,t,r)=>t>r?Math.min(t,Math.max(r,e)):Math.min(r,Math.max(t,e)),round:e=>Math.round(e*1e10)/1e10},um={dec2hex:e=>{const t=Math.round(e).toString(16);return t.length>1?t:`0${t}`}},st={channel:la,lang:hm,unit:um},Fe={};for(let e=0;e<=255;e++)Fe[e]=st.unit.dec2hex(e);const Et={ALL:0,RGB:1,HSL:2};class fm{constructor(){this.type=Et.ALL}get(){return this.type}set(t){if(this.type&&this.type!==t)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=t}reset(){this.type=Et.ALL}is(t){return this.type===t}}class dm{constructor(t,r){this.color=r,this.changed=!1,this.data=t,this.type=new fm}set(t,r){return this.color=r,this.changed=!1,this.data=t,this.type.type=Et.ALL,this}_ensureHSL(){const t=this.data,{h:r,s:i,l:a}=t;r===void 0&&(t.h=st.channel.rgb2hsl(t,"h")),i===void 0&&(t.s=st.channel.rgb2hsl(t,"s")),a===void 0&&(t.l=st.channel.rgb2hsl(t,"l"))}_ensureRGB(){const t=this.data,{r,g:i,b:a}=t;r===void 0&&(t.r=st.channel.hsl2rgb(t,"r")),i===void 0&&(t.g=st.channel.hsl2rgb(t,"g")),a===void 0&&(t.b=st.channel.hsl2rgb(t,"b"))}get r(){const t=this.data,r=t.r;return!this.type.is(Et.HSL)&&r!==void 0?r:(this._ensureHSL(),st.channel.hsl2rgb(t,"r"))}get g(){const t=this.data,r=t.g;return!this.type.is(Et.HSL)&&r!==void 0?r:(this._ensureHSL(),st.channel.hsl2rgb(t,"g"))}get b(){const t=this.data,r=t.b;return!this.type.is(Et.HSL)&&r!==void 0?r:(this._ensureHSL(),st.channel.hsl2rgb(t,"b"))}get h(){const t=this.data,r=t.h;return!this.type.is(Et.RGB)&&r!==void 0?r:(this._ensureRGB(),st.channel.rgb2hsl(t,"h"))}get s(){const t=this.data,r=t.s;return!this.type.is(Et.RGB)&&r!==void 0?r:(this._ensureRGB(),st.channel.rgb2hsl(t,"s"))}get l(){const t=this.data,r=t.l;return!this.type.is(Et.RGB)&&r!==void 0?r:(this._ensureRGB(),st.channel.rgb2hsl(t,"l"))}get a(){return this.data.a}set r(t){this.type.set(Et.RGB),this.changed=!0,this.data.r=t}set g(t){this.type.set(Et.RGB),this.changed=!0,this.data.g=t}set b(t){this.type.set(Et.RGB),this.changed=!0,this.data.b=t}set h(t){this.type.set(Et.HSL),this.changed=!0,this.data.h=t}set s(t){this.type.set(Et.HSL),this.changed=!0,this.data.s=t}set l(t){this.type.set(Et.HSL),this.changed=!0,this.data.l=t}set a(t){this.changed=!0,this.data.a=t}}const en=new dm({r:0,g:0,b:0,a:0},"transparent"),kr={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:e=>{if(e.charCodeAt(0)!==35)return;const t=e.match(kr.re);if(!t)return;const r=t[1],i=parseInt(r,16),a=r.length,n=a%4===0,o=a>4,s=o?1:17,l=o?8:4,c=n?0:-1,h=o?255:15;return en.set({r:(i>>l*(c+3)&h)*s,g:(i>>l*(c+2)&h)*s,b:(i>>l*(c+1)&h)*s,a:n?(i&h)*s/255:1},e)},stringify:e=>{const{r:t,g:r,b:i,a}=e;return a<1?`#${Fe[Math.round(t)]}${Fe[Math.round(r)]}${Fe[Math.round(i)]}${Fe[Math.round(a*255)]}`:`#${Fe[Math.round(t)]}${Fe[Math.round(r)]}${Fe[Math.round(i)]}`}},Ze={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:e=>{const t=e.match(Ze.hueRe);if(t){const[,r,i]=t;switch(i){case"grad":return st.channel.clamp.h(parseFloat(r)*.9);case"rad":return st.channel.clamp.h(parseFloat(r)*180/Math.PI);case"turn":return st.channel.clamp.h(parseFloat(r)*360)}}return st.channel.clamp.h(parseFloat(e))},parse:e=>{const t=e.charCodeAt(0);if(t!==104&&t!==72)return;const r=e.match(Ze.re);if(!r)return;const[,i,a,n,o,s]=r;return en.set({h:Ze._hue2deg(i),s:st.channel.clamp.s(parseFloat(a)),l:st.channel.clamp.l(parseFloat(n)),a:o?st.channel.clamp.a(s?parseFloat(o)/100:parseFloat(o)):1},e)},stringify:e=>{const{h:t,s:r,l:i,a}=e;return a<1?`hsla(${st.lang.round(t)}, ${st.lang.round(r)}%, ${st.lang.round(i)}%, ${a})`:`hsl(${st.lang.round(t)}, ${st.lang.round(r)}%, ${st.lang.round(i)}%)`}},yi={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:e=>{e=e.toLowerCase();const t=yi.colors[e];if(t)return kr.parse(t)},stringify:e=>{const t=kr.stringify(e);for(const r in yi.colors)if(yi.colors[r]===t)return r}},ci={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:e=>{const t=e.charCodeAt(0);if(t!==114&&t!==82)return;const r=e.match(ci.re);if(!r)return;const[,i,a,n,o,s,l,c,h]=r;return en.set({r:st.channel.clamp.r(a?parseFloat(i)*2.55:parseFloat(i)),g:st.channel.clamp.g(o?parseFloat(n)*2.55:parseFloat(n)),b:st.channel.clamp.b(l?parseFloat(s)*2.55:parseFloat(s)),a:c?st.channel.clamp.a(h?parseFloat(c)/100:parseFloat(c)):1},e)},stringify:e=>{const{r:t,g:r,b:i,a}=e;return a<1?`rgba(${st.lang.round(t)}, ${st.lang.round(r)}, ${st.lang.round(i)}, ${st.lang.round(a)})`:`rgb(${st.lang.round(t)}, ${st.lang.round(r)}, ${st.lang.round(i)})`}},pe={format:{keyword:yi,hex:kr,rgb:ci,rgba:ci,hsl:Ze,hsla:Ze},parse:e=>{if(typeof e!="string")return e;const t=kr.parse(e)||ci.parse(e)||Ze.parse(e)||yi.parse(e);if(t)return t;throw new Error(`Unsupported color format: "${e}"`)},stringify:e=>!e.changed&&e.color?e.color:e.type.is(Et.HSL)||e.data.r===void 0?Ze.stringify(e):e.a<1||!Number.isInteger(e.r)||!Number.isInteger(e.g)||!Number.isInteger(e.b)?ci.stringify(e):kr.stringify(e)},qc=(e,t)=>{const r=pe.parse(e);for(const i in t)r[i]=st.channel.clamp[i](t[i]);return pe.stringify(r)},xi=(e,t,r=0,i=1)=>{if(typeof e!="number")return qc(e,{a:t});const a=en.set({r:st.channel.clamp.r(e),g:st.channel.clamp.g(t),b:st.channel.clamp.b(r),a:st.channel.clamp.a(i)});return pe.stringify(a)},pm=e=>{const{r:t,g:r,b:i}=pe.parse(e),a=.2126*st.channel.toLinear(t)+.7152*st.channel.toLinear(r)+.0722*st.channel.toLinear(i);return st.lang.round(a)},gm=e=>pm(e)>=.5,Di=e=>!gm(e),Hc=(e,t,r)=>{const i=pe.parse(e),a=i[t],n=st.channel.clamp[t](a+r);return a!==n&&(i[t]=n),pe.stringify(i)},H=(e,t)=>Hc(e,"l",t),et=(e,t)=>Hc(e,"l",-t),S=(e,t)=>{const r=pe.parse(e),i={};for(const a in t)t[a]&&(i[a]=r[a]+t[a]);return qc(e,i)},mm=(e,t,r=50)=>{const{r:i,g:a,b:n,a:o}=pe.parse(e),{r:s,g:l,b:c,a:h}=pe.parse(t),u=r/100,f=u*2-1,d=o-h,m=((f*d===-1?f:(f+d)/(1+f*d))+1)/2,y=1-m,x=i*m+s*y,b=a*m+l*y,_=n*m+c*y,w=o*u+h*(1-u);return xi(x,b,_,w)},W=(e,t=100)=>{const r=pe.parse(e);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,mm(r,e,t)};const{entries:jc,setPrototypeOf:fl,isFrozen:ym,getPrototypeOf:xm,getOwnPropertyDescriptor:bm}=Object;let{freeze:Wt,seal:Qt,create:Yc}=Object,{apply:is,construct:as}=typeof Reflect<"u"&&Reflect;Wt||(Wt=function(t){return t});Qt||(Qt=function(t){return t});is||(is=function(t,r){for(var i=arguments.length,a=new Array(i>2?i-2:0),n=2;n<i;n++)a[n-2]=arguments[n];return t.apply(r,a)});as||(as=function(t){for(var r=arguments.length,i=new Array(r>1?r-1:0),a=1;a<r;a++)i[a-1]=arguments[a];return new t(...i)});const Ki=zt(Array.prototype.forEach),_m=zt(Array.prototype.lastIndexOf),dl=zt(Array.prototype.pop),Jr=zt(Array.prototype.push),Cm=zt(Array.prototype.splice),ca=zt(String.prototype.toLowerCase),In=zt(String.prototype.toString),Rn=zt(String.prototype.match),ti=zt(String.prototype.replace),vm=zt(String.prototype.indexOf),wm=zt(String.prototype.trim),ie=zt(Object.prototype.hasOwnProperty),Rt=zt(RegExp.prototype.test),ei=Sm(TypeError);function zt(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var r=arguments.length,i=new Array(r>1?r-1:0),a=1;a<r;a++)i[a-1]=arguments[a];return is(e,t,i)}}function Sm(e){return function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return as(e,r)}}function ot(e,t){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ca;fl&&fl(e,null);let i=t.length;for(;i--;){let a=t[i];if(typeof a=="string"){const n=r(a);n!==a&&(ym(t)||(t[i]=n),a=n)}e[a]=!0}return e}function km(e){for(let t=0;t<e.length;t++)ie(e,t)||(e[t]=null);return e}function Se(e){const t=Yc(null);for(const[r,i]of jc(e))ie(e,r)&&(Array.isArray(i)?t[r]=km(i):i&&typeof i=="object"&&i.constructor===Object?t[r]=Se(i):t[r]=i);return t}function ri(e,t){for(;e!==null;){const i=bm(e,t);if(i){if(i.get)return zt(i.get);if(typeof i.value=="function")return zt(i.value)}e=xm(e)}function r(){return null}return r}const pl=Wt(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Pn=Wt(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","slot","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Nn=Wt(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Tm=Wt(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Wn=Wt(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Lm=Wt(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),gl=Wt(["#text"]),ml=Wt(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),zn=Wt(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),yl=Wt(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Zi=Wt(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Bm=Qt(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Am=Qt(/<%[\w\W]*|[\w\W]*%>/gm),Mm=Qt(/\$\{[\w\W]*/gm),Em=Qt(/^data-[\-\w.\u00B7-\uFFFF]+$/),$m=Qt(/^aria-[\-\w]+$/),Uc=Qt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Fm=Qt(/^(?:\w+script|data):/i),Om=Qt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Gc=Qt(/^html$/i),Dm=Qt(/^[a-z][.\w]*(-[.\w]+)+$/i);var xl=Object.freeze({__proto__:null,ARIA_ATTR:$m,ATTR_WHITESPACE:Om,CUSTOM_ELEMENT:Dm,DATA_ATTR:Em,DOCTYPE_NAME:Gc,ERB_EXPR:Am,IS_ALLOWED_URI:Uc,IS_SCRIPT_OR_DATA:Fm,MUSTACHE_EXPR:Bm,TMPLIT_EXPR:Mm});const ii={element:1,text:3,progressingInstruction:7,comment:8,document:9},Im=function(){return typeof window>"u"?null:window},Rm=function(t,r){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null;const a="data-tt-policy-suffix";r&&r.hasAttribute(a)&&(i=r.getAttribute(a));const n="dompurify"+(i?"#"+i:"");try{return t.createPolicy(n,{createHTML(o){return o},createScriptURL(o){return o}})}catch{return console.warn("TrustedTypes policy "+n+" could not be created."),null}},bl=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function Vc(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Im();const t=tt=>Vc(tt);if(t.version="3.2.7",t.removed=[],!e||!e.document||e.document.nodeType!==ii.document||!e.Element)return t.isSupported=!1,t;let{document:r}=e;const i=r,a=i.currentScript,{DocumentFragment:n,HTMLTemplateElement:o,Node:s,Element:l,NodeFilter:c,NamedNodeMap:h=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:u,DOMParser:f,trustedTypes:d}=e,g=l.prototype,m=ri(g,"cloneNode"),y=ri(g,"remove"),x=ri(g,"nextSibling"),b=ri(g,"childNodes"),_=ri(g,"parentNode");if(typeof o=="function"){const tt=r.createElement("template");tt.content&&tt.content.ownerDocument&&(r=tt.content.ownerDocument)}let w,v="";const{implementation:B,createNodeIterator:T,createDocumentFragment:O,getElementsByTagName:R}=r,{importNode:D}=i;let E=bl();t.isSupported=typeof jc=="function"&&typeof _=="function"&&B&&B.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:N,ERB_EXPR:I,TMPLIT_EXPR:L,DATA_ATTR:A,ARIA_ATTR:k,IS_SCRIPT_OR_DATA:$,ATTR_WHITESPACE:M,CUSTOM_ELEMENT:q}=xl;let{IS_ALLOWED_URI:V}=xl,Z=null;const J=ot({},[...pl,...Pn,...Nn,...Wn,...gl]);let X=null;const ct=ot({},[...ml,...zn,...yl,...Zi]);let nt=Object.seal(Yc(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),xt=null,bt=null,ee=!0,Xt=!0,mt=!1,re=!0,Kt=!1,xe=!0,Ye=!1,Ln=!1,Bn=!1,pr=!1,ji=!1,Yi=!1,Uo=!0,Go=!1;const Kg="user-content-";let An=!0,Zr=!1,gr={},mr=null;const Vo=ot({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Xo=null;const Ko=ot({},["audio","video","img","source","image","track"]);let Mn=null;const Zo=ot({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Ui="http://www.w3.org/1998/Math/MathML",Gi="http://www.w3.org/2000/svg",be="http://www.w3.org/1999/xhtml";let yr=be,En=!1,$n=null;const Zg=ot({},[Ui,Gi,be],In);let Vi=ot({},["mi","mo","mn","ms","mtext"]),Xi=ot({},["annotation-xml"]);const Qg=ot({},["title","style","font","a","script"]);let Qr=null;const Jg=["application/xhtml+xml","text/html"],tm="text/html";let Tt=null,xr=null;const em=r.createElement("form"),Qo=function(C){return C instanceof RegExp||C instanceof Function},Fn=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(xr&&xr===C)){if((!C||typeof C!="object")&&(C={}),C=Se(C),Qr=Jg.indexOf(C.PARSER_MEDIA_TYPE)===-1?tm:C.PARSER_MEDIA_TYPE,Tt=Qr==="application/xhtml+xml"?In:ca,Z=ie(C,"ALLOWED_TAGS")?ot({},C.ALLOWED_TAGS,Tt):J,X=ie(C,"ALLOWED_ATTR")?ot({},C.ALLOWED_ATTR,Tt):ct,$n=ie(C,"ALLOWED_NAMESPACES")?ot({},C.ALLOWED_NAMESPACES,In):Zg,Mn=ie(C,"ADD_URI_SAFE_ATTR")?ot(Se(Zo),C.ADD_URI_SAFE_ATTR,Tt):Zo,Xo=ie(C,"ADD_DATA_URI_TAGS")?ot(Se(Ko),C.ADD_DATA_URI_TAGS,Tt):Ko,mr=ie(C,"FORBID_CONTENTS")?ot({},C.FORBID_CONTENTS,Tt):Vo,xt=ie(C,"FORBID_TAGS")?ot({},C.FORBID_TAGS,Tt):Se({}),bt=ie(C,"FORBID_ATTR")?ot({},C.FORBID_ATTR,Tt):Se({}),gr=ie(C,"USE_PROFILES")?C.USE_PROFILES:!1,ee=C.ALLOW_ARIA_ATTR!==!1,Xt=C.ALLOW_DATA_ATTR!==!1,mt=C.ALLOW_UNKNOWN_PROTOCOLS||!1,re=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Kt=C.SAFE_FOR_TEMPLATES||!1,xe=C.SAFE_FOR_XML!==!1,Ye=C.WHOLE_DOCUMENT||!1,pr=C.RETURN_DOM||!1,ji=C.RETURN_DOM_FRAGMENT||!1,Yi=C.RETURN_TRUSTED_TYPE||!1,Bn=C.FORCE_BODY||!1,Uo=C.SANITIZE_DOM!==!1,Go=C.SANITIZE_NAMED_PROPS||!1,An=C.KEEP_CONTENT!==!1,Zr=C.IN_PLACE||!1,V=C.ALLOWED_URI_REGEXP||Uc,yr=C.NAMESPACE||be,Vi=C.MATHML_TEXT_INTEGRATION_POINTS||Vi,Xi=C.HTML_INTEGRATION_POINTS||Xi,nt=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&Qo(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(nt.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&Qo(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(nt.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(nt.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Kt&&(Xt=!1),ji&&(pr=!0),gr&&(Z=ot({},gl),X=[],gr.html===!0&&(ot(Z,pl),ot(X,ml)),gr.svg===!0&&(ot(Z,Pn),ot(X,zn),ot(X,Zi)),gr.svgFilters===!0&&(ot(Z,Nn),ot(X,zn),ot(X,Zi)),gr.mathMl===!0&&(ot(Z,Wn),ot(X,yl),ot(X,Zi))),C.ADD_TAGS&&(Z===J&&(Z=Se(Z)),ot(Z,C.ADD_TAGS,Tt)),C.ADD_ATTR&&(X===ct&&(X=Se(X)),ot(X,C.ADD_ATTR,Tt)),C.ADD_URI_SAFE_ATTR&&ot(Mn,C.ADD_URI_SAFE_ATTR,Tt),C.FORBID_CONTENTS&&(mr===Vo&&(mr=Se(mr)),ot(mr,C.FORBID_CONTENTS,Tt)),An&&(Z["#text"]=!0),Ye&&ot(Z,["html","head","body"]),Z.table&&(ot(Z,["tbody"]),delete xt.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw ei('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw ei('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=C.TRUSTED_TYPES_POLICY,v=w.createHTML("")}else w===void 0&&(w=Rm(d,a)),w!==null&&typeof v=="string"&&(v=w.createHTML(""));Wt&&Wt(C),xr=C}},Jo=ot({},[...Pn,...Nn,...Tm]),tl=ot({},[...Wn,...Lm]),rm=function(C){let P=_(C);(!P||!P.tagName)&&(P={namespaceURI:yr,tagName:"template"});const K=ca(C.tagName),pt=ca(P.tagName);return $n[C.namespaceURI]?C.namespaceURI===Gi?P.namespaceURI===be?K==="svg":P.namespaceURI===Ui?K==="svg"&&(pt==="annotation-xml"||Vi[pt]):!!Jo[K]:C.namespaceURI===Ui?P.namespaceURI===be?K==="math":P.namespaceURI===Gi?K==="math"&&Xi[pt]:!!tl[K]:C.namespaceURI===be?P.namespaceURI===Gi&&!Xi[pt]||P.namespaceURI===Ui&&!Vi[pt]?!1:!tl[K]&&(Qg[K]||!Jo[K]):!!(Qr==="application/xhtml+xml"&&$n[C.namespaceURI]):!1},ce=function(C){Jr(t.removed,{element:C});try{_(C).removeChild(C)}catch{y(C)}},Ue=function(C,P){try{Jr(t.removed,{attribute:P.getAttributeNode(C),from:P})}catch{Jr(t.removed,{attribute:null,from:P})}if(P.removeAttribute(C),C==="is")if(pr||ji)try{ce(P)}catch{}else try{P.setAttribute(C,"")}catch{}},el=function(C){let P=null,K=null;if(Bn)C="<remove></remove>"+C;else{const _t=Rn(C,/^[\r\n\t ]+/);K=_t&&_t[0]}Qr==="application/xhtml+xml"&&yr===be&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const pt=w?w.createHTML(C):C;if(yr===be)try{P=new f().parseFromString(pt,Qr)}catch{}if(!P||!P.documentElement){P=B.createDocument(yr,"template",null);try{P.documentElement.innerHTML=En?v:pt}catch{}}const Mt=P.body||P.documentElement;return C&&K&&Mt.insertBefore(r.createTextNode(K),Mt.childNodes[0]||null),yr===be?R.call(P,Ye?"html":"body")[0]:Ye?P.documentElement:Mt},rl=function(C){return T.call(C.ownerDocument||C,C,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},On=function(C){return C instanceof u&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof h)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},il=function(C){return typeof s=="function"&&C instanceof s};function _e(tt,C,P){Ki(tt,K=>{K.call(t,C,P,xr)})}const al=function(C){let P=null;if(_e(E.beforeSanitizeElements,C,null),On(C))return ce(C),!0;const K=Tt(C.nodeName);if(_e(E.uponSanitizeElement,C,{tagName:K,allowedTags:Z}),xe&&C.hasChildNodes()&&!il(C.firstElementChild)&&Rt(/<[/\w!]/g,C.innerHTML)&&Rt(/<[/\w!]/g,C.textContent)||C.nodeType===ii.progressingInstruction||xe&&C.nodeType===ii.comment&&Rt(/<[/\w]/g,C.data))return ce(C),!0;if(!Z[K]||xt[K]){if(!xt[K]&&sl(K)&&(nt.tagNameCheck instanceof RegExp&&Rt(nt.tagNameCheck,K)||nt.tagNameCheck instanceof Function&&nt.tagNameCheck(K)))return!1;if(An&&!mr[K]){const pt=_(C)||C.parentNode,Mt=b(C)||C.childNodes;if(Mt&&pt){const _t=Mt.length;for(let qt=_t-1;qt>=0;--qt){const Ce=m(Mt[qt],!0);Ce.__removalCount=(C.__removalCount||0)+1,pt.insertBefore(Ce,x(C))}}}return ce(C),!0}return C instanceof l&&!rm(C)||(K==="noscript"||K==="noembed"||K==="noframes")&&Rt(/<\/no(script|embed|frames)/i,C.innerHTML)?(ce(C),!0):(Kt&&C.nodeType===ii.text&&(P=C.textContent,Ki([N,I,L],pt=>{P=ti(P,pt," ")}),C.textContent!==P&&(Jr(t.removed,{element:C.cloneNode()}),C.textContent=P)),_e(E.afterSanitizeElements,C,null),!1)},nl=function(C,P,K){if(Uo&&(P==="id"||P==="name")&&(K in r||K in em))return!1;if(!(Xt&&!bt[P]&&Rt(A,P))){if(!(ee&&Rt(k,P))){if(!X[P]||bt[P]){if(!(sl(C)&&(nt.tagNameCheck instanceof RegExp&&Rt(nt.tagNameCheck,C)||nt.tagNameCheck instanceof Function&&nt.tagNameCheck(C))&&(nt.attributeNameCheck instanceof RegExp&&Rt(nt.attributeNameCheck,P)||nt.attributeNameCheck instanceof Function&&nt.attributeNameCheck(P,C))||P==="is"&&nt.allowCustomizedBuiltInElements&&(nt.tagNameCheck instanceof RegExp&&Rt(nt.tagNameCheck,K)||nt.tagNameCheck instanceof Function&&nt.tagNameCheck(K))))return!1}else if(!Mn[P]){if(!Rt(V,ti(K,M,""))){if(!((P==="src"||P==="xlink:href"||P==="href")&&C!=="script"&&vm(K,"data:")===0&&Xo[C])){if(!(mt&&!Rt($,ti(K,M,"")))){if(K)return!1}}}}}}return!0},sl=function(C){return C!=="annotation-xml"&&Rn(C,q)},ol=function(C){_e(E.beforeSanitizeAttributes,C,null);const{attributes:P}=C;if(!P||On(C))return;const K={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:X,forceKeepAttr:void 0};let pt=P.length;for(;pt--;){const Mt=P[pt],{name:_t,namespaceURI:qt,value:Ce}=Mt,br=Tt(_t),Dn=Ce;let Lt=_t==="value"?Dn:wm(Dn);if(K.attrName=br,K.attrValue=Lt,K.keepAttr=!0,K.forceKeepAttr=void 0,_e(E.uponSanitizeAttribute,C,K),Lt=K.attrValue,Go&&(br==="id"||br==="name")&&(Ue(_t,C),Lt=Kg+Lt),xe&&Rt(/((--!?|])>)|<\/(style|title|textarea)/i,Lt)){Ue(_t,C);continue}if(br==="attributename"&&Rn(Lt,"href")){Ue(_t,C);continue}if(K.forceKeepAttr)continue;if(!K.keepAttr){Ue(_t,C);continue}if(!re&&Rt(/\/>/i,Lt)){Ue(_t,C);continue}Kt&&Ki([N,I,L],cl=>{Lt=ti(Lt,cl," ")});const ll=Tt(C.nodeName);if(!nl(ll,br,Lt)){Ue(_t,C);continue}if(w&&typeof d=="object"&&typeof d.getAttributeType=="function"&&!qt)switch(d.getAttributeType(ll,br)){case"TrustedHTML":{Lt=w.createHTML(Lt);break}case"TrustedScriptURL":{Lt=w.createScriptURL(Lt);break}}if(Lt!==Dn)try{qt?C.setAttributeNS(qt,_t,Lt):C.setAttribute(_t,Lt),On(C)?ce(C):dl(t.removed)}catch{Ue(_t,C)}}_e(E.afterSanitizeAttributes,C,null)},im=function tt(C){let P=null;const K=rl(C);for(_e(E.beforeSanitizeShadowDOM,C,null);P=K.nextNode();)_e(E.uponSanitizeShadowNode,P,null),al(P),ol(P),P.content instanceof n&&tt(P.content);_e(E.afterSanitizeShadowDOM,C,null)};return t.sanitize=function(tt){let C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},P=null,K=null,pt=null,Mt=null;if(En=!tt,En&&(tt="<!-->"),typeof tt!="string"&&!il(tt))if(typeof tt.toString=="function"){if(tt=tt.toString(),typeof tt!="string")throw ei("dirty is not a string, aborting")}else throw ei("toString is not a function");if(!t.isSupported)return tt;if(Ln||Fn(C),t.removed=[],typeof tt=="string"&&(Zr=!1),Zr){if(tt.nodeName){const Ce=Tt(tt.nodeName);if(!Z[Ce]||xt[Ce])throw ei("root node is forbidden and cannot be sanitized in-place")}}else if(tt instanceof s)P=el("<!---->"),K=P.ownerDocument.importNode(tt,!0),K.nodeType===ii.element&&K.nodeName==="BODY"||K.nodeName==="HTML"?P=K:P.appendChild(K);else{if(!pr&&!Kt&&!Ye&&tt.indexOf("<")===-1)return w&&Yi?w.createHTML(tt):tt;if(P=el(tt),!P)return pr?null:Yi?v:""}P&&Bn&&ce(P.firstChild);const _t=rl(Zr?tt:P);for(;pt=_t.nextNode();)al(pt),ol(pt),pt.content instanceof n&&im(pt.content);if(Zr)return tt;if(pr){if(ji)for(Mt=O.call(P.ownerDocument);P.firstChild;)Mt.appendChild(P.firstChild);else Mt=P;return(X.shadowroot||X.shadowrootmode)&&(Mt=D.call(i,Mt,!0)),Mt}let qt=Ye?P.outerHTML:P.innerHTML;return Ye&&Z["!doctype"]&&P.ownerDocument&&P.ownerDocument.doctype&&P.ownerDocument.doctype.name&&Rt(Gc,P.ownerDocument.doctype.name)&&(qt="<!DOCTYPE "+P.ownerDocument.doctype.name+`>
|
|
3
|
+
`+qt),Kt&&Ki([N,I,L],Ce=>{qt=ti(qt,Ce," ")}),w&&Yi?w.createHTML(qt):qt},t.setConfig=function(){let tt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Fn(tt),Ln=!0},t.clearConfig=function(){xr=null,Ln=!1},t.isValidAttribute=function(tt,C,P){xr||Fn({});const K=Tt(tt),pt=Tt(C);return nl(K,pt,P)},t.addHook=function(tt,C){typeof C=="function"&&Jr(E[tt],C)},t.removeHook=function(tt,C){if(C!==void 0){const P=_m(E[tt],C);return P===-1?void 0:Cm(E[tt],P,1)[0]}return dl(E[tt])},t.removeHooks=function(tt){E[tt]=[]},t.removeAllHooks=function(){E=bl()},t}var Ir=Vc(),Xc=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,bi=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Pm=/\s*%%.*\n/gm,Br,Kc=(Br=class extends Error{constructor(t){super(t),this.name="UnknownDiagramError"}},p(Br,"UnknownDiagramError"),Br),ar={},Js=p(function(e,t){e=e.replace(Xc,"").replace(bi,"").replace(Pm,`
|
|
4
|
+
`);for(const[r,{detector:i}]of Object.entries(ar))if(i(e,t))return r;throw new Kc(`No diagram type detected matching given configuration for text: ${e}`)},"detectType"),ns=p((...e)=>{for(const{id:t,detector:r,loader:i}of e)Zc(t,r,i)},"registerLazyLoadedDiagrams"),Zc=p((e,t,r)=>{ar[e]&&F.warn(`Detector with key ${e} already exists. Overwriting.`),ar[e]={detector:t,loader:r},F.debug(`Detector with key ${e} added${r?" with loader":""}`)},"addDetector"),Nm=p(e=>ar[e].loader,"getDiagramLoader"),ss=p((e,t,{depth:r=2,clobber:i=!1}={})=>{const a={depth:r,clobber:i};return Array.isArray(t)&&!Array.isArray(e)?(t.forEach(n=>ss(e,n,a)),e):Array.isArray(t)&&Array.isArray(e)?(t.forEach(n=>{e.includes(n)||e.push(n)}),e):e===void 0||r<=0?e!=null&&typeof e=="object"&&typeof t=="object"?Object.assign(e,t):t:(t!==void 0&&typeof e=="object"&&typeof t=="object"&&Object.keys(t).forEach(n=>{typeof t[n]=="object"&&(e[n]===void 0||typeof e[n]=="object")?(e[n]===void 0&&(e[n]=Array.isArray(t[n])?[]:{}),e[n]=ss(e[n],t[n],{depth:r-1,clobber:i})):(i||typeof e[n]!="object"&&typeof t[n]!="object")&&(e[n]=t[n])}),e)},"assignWithDepth"),wt=ss,rn="#ffffff",an="#f2f2f2",Pt=p((e,t)=>t?S(e,{s:-40,l:10}):S(e,{s:-40,l:-10}),"mkBorder"),Ar,Wm=(Ar=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||S(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||S(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Pt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Pt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Pt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Pt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||W(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||W(this.tertiaryColor),this.lineColor=this.lineColor||W(this.background),this.arrowheadColor=this.arrowheadColor||W(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?et(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||et(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||W(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||H(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||et(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||et(this.mainBkg,10)):(this.rowOdd=this.rowOdd||H(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||H(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||S(this.primaryColor,{h:30}),this.cScale4=this.cScale4||S(this.primaryColor,{h:60}),this.cScale5=this.cScale5||S(this.primaryColor,{h:90}),this.cScale6=this.cScale6||S(this.primaryColor,{h:120}),this.cScale7=this.cScale7||S(this.primaryColor,{h:150}),this.cScale8=this.cScale8||S(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||S(this.primaryColor,{h:270}),this.cScale10=this.cScale10||S(this.primaryColor,{h:300}),this.cScale11=this.cScale11||S(this.primaryColor,{h:330}),this.darkMode)for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=et(this["cScale"+r],75);else for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScale"+r]=et(this["cScale"+r],25);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleInv"+r]=this["cScaleInv"+r]||W(this["cScale"+r]);for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this.darkMode?this["cScalePeer"+r]=this["cScalePeer"+r]||H(this["cScale"+r],10):this["cScalePeer"+r]=this["cScalePeer"+r]||et(this["cScale"+r],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let r=0;r<this.THEME_COLOR_LIMIT;r++)this["cScaleLabel"+r]=this["cScaleLabel"+r]||this.scaleLabelColor;const t=this.darkMode?-4:-1;for(let r=0;r<5;r++)this["surface"+r]=this["surface"+r]||S(this.mainBkg,{h:180,s:-15,l:t*(5+r*3)}),this["surfacePeer"+r]=this["surfacePeer"+r]||S(this.mainBkg,{h:180,s:-15,l:t*(8+r*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||S(this.primaryColor,{h:64}),this.fillType3=this.fillType3||S(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||S(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||S(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||S(this.primaryColor,{h:128}),this.fillType7=this.fillType7||S(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||S(this.primaryColor,{l:-10}),this.pie5=this.pie5||S(this.secondaryColor,{l:-10}),this.pie6=this.pie6||S(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||S(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||S(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||S(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||S(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||S(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||S(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.archEdgeColor=this.archEdgeColor||"#777",this.archEdgeArrowColor=this.archEdgeArrowColor||"#777",this.archEdgeWidth=this.archEdgeWidth||"3",this.archGroupBorderColor=this.archGroupBorderColor||"#000",this.archGroupBorderWidth=this.archGroupBorderWidth||"2px",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||S(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||S(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||S(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||S(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||S(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||S(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Di(this.quadrant1Fill)?H(this.quadrant1Fill):et(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?et(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||S(this.primaryColor,{h:-30}),this.git4=this.git4||S(this.primaryColor,{h:-60}),this.git5=this.git5||S(this.primaryColor,{h:-90}),this.git6=this.git6||S(this.primaryColor,{h:60}),this.git7=this.git7||S(this.primaryColor,{h:120}),this.darkMode?(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)):(this.git0=et(this.git0,25),this.git1=et(this.git1,25),this.git2=et(this.git2,25),this.git3=et(this.git3,25),this.git4=et(this.git4,25),this.git5=et(this.git5,25),this.git6=et(this.git6,25),this.git7=et(this.git7,25)),this.gitInv0=this.gitInv0||W(this.git0),this.gitInv1=this.gitInv1||W(this.git1),this.gitInv2=this.gitInv2||W(this.git2),this.gitInv3=this.gitInv3||W(this.git3),this.gitInv4=this.gitInv4||W(this.git4),this.gitInv5=this.gitInv5||W(this.git5),this.gitInv6=this.gitInv6||W(this.git6),this.gitInv7=this.gitInv7||W(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||rn,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||an}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Ar,"Theme"),Ar),zm=p(e=>{const t=new Wm;return t.calculate(e),t},"getThemeVariables"),Mr,qm=(Mr=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=H(this.primaryColor,16),this.tertiaryColor=S(this.primaryColor,{h:-160}),this.primaryBorderColor=W(this.background),this.secondaryBorderColor=Pt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Pt(this.tertiaryColor,this.darkMode),this.primaryTextColor=W(this.primaryColor),this.secondaryTextColor=W(this.secondaryColor),this.tertiaryTextColor=W(this.tertiaryColor),this.lineColor=W(this.background),this.textColor=W(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=H(W("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=xi(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=et("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=et(this.sectionBkgColor,10),this.taskBorderColor=xi(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=xi(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||H(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||et(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){this.secondBkg=H(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=H(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=H(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=S(this.primaryColor,{h:64}),this.fillType3=S(this.secondaryColor,{h:64}),this.fillType4=S(this.primaryColor,{h:-64}),this.fillType5=S(this.secondaryColor,{h:-64}),this.fillType6=S(this.primaryColor,{h:128}),this.fillType7=S(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||S(this.primaryColor,{h:30}),this.cScale4=this.cScale4||S(this.primaryColor,{h:60}),this.cScale5=this.cScale5||S(this.primaryColor,{h:90}),this.cScale6=this.cScale6||S(this.primaryColor,{h:120}),this.cScale7=this.cScale7||S(this.primaryColor,{h:150}),this.cScale8=this.cScale8||S(this.primaryColor,{h:210}),this.cScale9=this.cScale9||S(this.primaryColor,{h:270}),this.cScale10=this.cScale10||S(this.primaryColor,{h:300}),this.cScale11=this.cScale11||S(this.primaryColor,{h:330});for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleInv"+t]=this["cScaleInv"+t]||W(this["cScale"+t]);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScalePeer"+t]=this["cScalePeer"+t]||H(this["cScale"+t],10);for(let t=0;t<5;t++)this["surface"+t]=this["surface"+t]||S(this.mainBkg,{h:30,s:-30,l:-(-10+t*4)}),this["surfacePeer"+t]=this["surfacePeer"+t]||S(this.mainBkg,{h:30,s:-30,l:-(-7+t*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleLabel"+t]=this["cScaleLabel"+t]||this.scaleLabelColor;for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["pie"+t]=this["cScale"+t];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||S(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||S(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||S(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||S(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||S(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||S(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Di(this.quadrant1Fill)?H(this.quadrant1Fill):et(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.background},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?et(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=H(this.secondaryColor,20),this.git1=H(this.pie2||this.secondaryColor,20),this.git2=H(this.pie3||this.tertiaryColor,20),this.git3=H(this.pie4||S(this.primaryColor,{h:-30}),20),this.git4=H(this.pie5||S(this.primaryColor,{h:-60}),20),this.git5=H(this.pie6||S(this.primaryColor,{h:-90}),10),this.git6=H(this.pie7||S(this.primaryColor,{h:60}),10),this.git7=H(this.pie8||S(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||W(this.git0),this.gitInv1=this.gitInv1||W(this.git1),this.gitInv2=this.gitInv2||W(this.git2),this.gitInv3=this.gitInv3||W(this.git3),this.gitInv4=this.gitInv4||W(this.git4),this.gitInv5=this.gitInv5||W(this.git5),this.gitInv6=this.gitInv6||W(this.git6),this.gitInv7=this.gitInv7||W(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||W(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||W(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||H(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||H(this.background,2),this.nodeBorder=this.nodeBorder||"#999"}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Mr,"Theme"),Mr),Hm=p(e=>{const t=new qm;return t.calculate(e),t},"getThemeVariables"),Er,jm=(Er=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=S(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=S(this.primaryColor,{h:-160}),this.primaryBorderColor=Pt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Pt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Pt(this.tertiaryColor,this.darkMode),this.primaryTextColor=W(this.primaryColor),this.secondaryTextColor=W(this.secondaryColor),this.tertiaryTextColor=W(this.tertiaryColor),this.lineColor=W(this.background),this.textColor=W(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=xi(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||S(this.primaryColor,{h:30}),this.cScale4=this.cScale4||S(this.primaryColor,{h:60}),this.cScale5=this.cScale5||S(this.primaryColor,{h:90}),this.cScale6=this.cScale6||S(this.primaryColor,{h:120}),this.cScale7=this.cScale7||S(this.primaryColor,{h:150}),this.cScale8=this.cScale8||S(this.primaryColor,{h:210}),this.cScale9=this.cScale9||S(this.primaryColor,{h:270}),this.cScale10=this.cScale10||S(this.primaryColor,{h:300}),this.cScale11=this.cScale11||S(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||et(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||et(this.tertiaryColor,40);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScale"+t]=et(this["cScale"+t],10),this["cScalePeer"+t]=this["cScalePeer"+t]||et(this["cScale"+t],25);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleInv"+t]=this["cScaleInv"+t]||S(this["cScale"+t],{h:180});for(let t=0;t<5;t++)this["surface"+t]=this["surface"+t]||S(this.mainBkg,{h:30,l:-(5+t*5)}),this["surfacePeer"+t]=this["surfacePeer"+t]||S(this.mainBkg,{h:30,l:-(7+t*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||W(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||W(this.labelTextColor);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleLabel"+t]=this["cScaleLabel"+t]||this.labelTextColor}this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=H(this.border1,23),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||H(this.primaryColor,75)||"#ffffff",this.rowEven=this.rowEven||H(this.primaryColor,1),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=S(this.primaryColor,{h:64}),this.fillType3=S(this.secondaryColor,{h:64}),this.fillType4=S(this.primaryColor,{h:-64}),this.fillType5=S(this.secondaryColor,{h:-64}),this.fillType6=S(this.primaryColor,{h:128}),this.fillType7=S(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||S(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||S(this.primaryColor,{l:-10}),this.pie5=this.pie5||S(this.secondaryColor,{l:-30}),this.pie6=this.pie6||S(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||S(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||S(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||S(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||S(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||S(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||S(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||S(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||S(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||S(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||S(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||S(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||S(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Di(this.quadrant1Fill)?H(this.quadrant1Fill):et(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||S(this.primaryColor,{h:-30}),this.git4=this.git4||S(this.primaryColor,{h:-60}),this.git5=this.git5||S(this.primaryColor,{h:-90}),this.git6=this.git6||S(this.primaryColor,{h:60}),this.git7=this.git7||S(this.primaryColor,{h:120}),this.darkMode?(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)):(this.git0=et(this.git0,25),this.git1=et(this.git1,25),this.git2=et(this.git2,25),this.git3=et(this.git3,25),this.git4=et(this.git4,25),this.git5=et(this.git5,25),this.git6=et(this.git6,25),this.git7=et(this.git7,25)),this.gitInv0=this.gitInv0||et(W(this.git0),25),this.gitInv1=this.gitInv1||W(this.git1),this.gitInv2=this.gitInv2||W(this.git2),this.gitInv3=this.gitInv3||W(this.git3),this.gitInv4=this.gitInv4||W(this.git4),this.gitInv5=this.gitInv5||W(this.git5),this.gitInv6=this.gitInv6||W(this.git6),this.gitInv7=this.gitInv7||W(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||W(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||W(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||rn,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||an}calculate(t){if(Object.keys(this).forEach(i=>{this[i]==="calculated"&&(this[i]=void 0)}),typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Er,"Theme"),Er),Ym=p(e=>{const t=new jm;return t.calculate(e),t},"getThemeVariables"),$r,Um=($r=class{constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=H("#cde498",10),this.primaryBorderColor=Pt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Pt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Pt(this.tertiaryColor,this.darkMode),this.primaryTextColor=W(this.primaryColor),this.secondaryTextColor=W(this.secondaryColor),this.tertiaryTextColor=W(this.primaryColor),this.lineColor=W(this.background),this.textColor=W(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.actorBorder=et(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||S(this.primaryColor,{h:30}),this.cScale4=this.cScale4||S(this.primaryColor,{h:60}),this.cScale5=this.cScale5||S(this.primaryColor,{h:90}),this.cScale6=this.cScale6||S(this.primaryColor,{h:120}),this.cScale7=this.cScale7||S(this.primaryColor,{h:150}),this.cScale8=this.cScale8||S(this.primaryColor,{h:210}),this.cScale9=this.cScale9||S(this.primaryColor,{h:270}),this.cScale10=this.cScale10||S(this.primaryColor,{h:300}),this.cScale11=this.cScale11||S(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||et(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||et(this.tertiaryColor,40);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScale"+t]=et(this["cScale"+t],10),this["cScalePeer"+t]=this["cScalePeer"+t]||et(this["cScale"+t],25);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleInv"+t]=this["cScaleInv"+t]||S(this["cScale"+t],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleLabel"+t]=this["cScaleLabel"+t]||this.scaleLabelColor;for(let t=0;t<5;t++)this["surface"+t]=this["surface"+t]||S(this.mainBkg,{h:30,s:-30,l:-(5+t*5)}),this["surfacePeer"+t]=this["surfacePeer"+t]||S(this.mainBkg,{h:30,s:-30,l:-(8+t*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.rowOdd=this.rowOdd||H(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||H(this.mainBkg,20),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=S(this.primaryColor,{h:64}),this.fillType3=S(this.secondaryColor,{h:64}),this.fillType4=S(this.primaryColor,{h:-64}),this.fillType5=S(this.secondaryColor,{h:-64}),this.fillType6=S(this.primaryColor,{h:128}),this.fillType7=S(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||S(this.primaryColor,{l:-30}),this.pie5=this.pie5||S(this.secondaryColor,{l:-30}),this.pie6=this.pie6||S(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||S(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||S(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||S(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||S(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||S(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||S(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||S(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||S(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||S(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||S(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||S(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||S(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Di(this.quadrant1Fill)?H(this.quadrant1Fill):et(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.packet={startByteColor:this.primaryTextColor,endByteColor:this.primaryTextColor,labelColor:this.primaryTextColor,titleColor:this.primaryTextColor,blockStrokeColor:this.primaryTextColor,blockFillColor:this.mainBkg},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||S(this.primaryColor,{h:-30}),this.git4=this.git4||S(this.primaryColor,{h:-60}),this.git5=this.git5||S(this.primaryColor,{h:-90}),this.git6=this.git6||S(this.primaryColor,{h:60}),this.git7=this.git7||S(this.primaryColor,{h:120}),this.darkMode?(this.git0=H(this.git0,25),this.git1=H(this.git1,25),this.git2=H(this.git2,25),this.git3=H(this.git3,25),this.git4=H(this.git4,25),this.git5=H(this.git5,25),this.git6=H(this.git6,25),this.git7=H(this.git7,25)):(this.git0=et(this.git0,25),this.git1=et(this.git1,25),this.git2=et(this.git2,25),this.git3=et(this.git3,25),this.git4=et(this.git4,25),this.git5=et(this.git5,25),this.git6=et(this.git6,25),this.git7=et(this.git7,25)),this.gitInv0=this.gitInv0||W(this.git0),this.gitInv1=this.gitInv1||W(this.git1),this.gitInv2=this.gitInv2||W(this.git2),this.gitInv3=this.gitInv3||W(this.git3),this.gitInv4=this.gitInv4||W(this.git4),this.gitInv5=this.gitInv5||W(this.git5),this.gitInv6=this.gitInv6||W(this.git6),this.gitInv7=this.gitInv7||W(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||W(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||W(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||rn,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||an}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p($r,"Theme"),$r),Gm=p(e=>{const t=new Um;return t.calculate(e),t},"getThemeVariables"),Fr,Vm=(Fr=class{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=H(this.contrast,55),this.background="#ffffff",this.tertiaryColor=S(this.primaryColor,{h:-160}),this.primaryBorderColor=Pt(this.primaryColor,this.darkMode),this.secondaryBorderColor=Pt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Pt(this.tertiaryColor,this.darkMode),this.primaryTextColor=W(this.primaryColor),this.secondaryTextColor=W(this.secondaryColor),this.tertiaryTextColor=W(this.tertiaryColor),this.lineColor=W(this.background),this.textColor=W(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||H(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.secondBkg=H(this.contrast,55),this.border2=this.contrast,this.actorBorder=H(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleInv"+t]=this["cScaleInv"+t]||W(this["cScale"+t]);for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this.darkMode?this["cScalePeer"+t]=this["cScalePeer"+t]||H(this["cScale"+t],10):this["cScalePeer"+t]=this["cScalePeer"+t]||et(this["cScale"+t],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["cScaleLabel"+t]=this["cScaleLabel"+t]||this.scaleLabelColor;for(let t=0;t<5;t++)this["surface"+t]=this["surface"+t]||S(this.mainBkg,{l:-(5+t*5)}),this["surfacePeer"+t]=this["surfacePeer"+t]||S(this.mainBkg,{l:-(8+t*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.sectionBkgColor=H(this.contrast,30),this.sectionBkgColor2=H(this.contrast,30),this.taskBorderColor=et(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=H(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=et(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.vertLineColor=this.critBkgColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=S(this.primaryColor,{h:64}),this.fillType3=S(this.secondaryColor,{h:64}),this.fillType4=S(this.primaryColor,{h:-64}),this.fillType5=S(this.secondaryColor,{h:-64}),this.fillType6=S(this.primaryColor,{h:128}),this.fillType7=S(this.secondaryColor,{h:128});for(let t=0;t<this.THEME_COLOR_LIMIT;t++)this["pie"+t]=this["cScale"+t];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||S(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||S(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||S(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||S(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||S(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||S(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||Di(this.quadrant1Fill)?H(this.quadrant1Fill):et(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:this.xyChart?.backgroundColor||this.background,titleColor:this.xyChart?.titleColor||this.primaryTextColor,xAxisTitleColor:this.xyChart?.xAxisTitleColor||this.primaryTextColor,xAxisLabelColor:this.xyChart?.xAxisLabelColor||this.primaryTextColor,xAxisTickColor:this.xyChart?.xAxisTickColor||this.primaryTextColor,xAxisLineColor:this.xyChart?.xAxisLineColor||this.primaryTextColor,yAxisTitleColor:this.xyChart?.yAxisTitleColor||this.primaryTextColor,yAxisLabelColor:this.xyChart?.yAxisLabelColor||this.primaryTextColor,yAxisTickColor:this.xyChart?.yAxisTickColor||this.primaryTextColor,yAxisLineColor:this.xyChart?.yAxisLineColor||this.primaryTextColor,plotColorPalette:this.xyChart?.plotColorPalette||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.radar={axisColor:this.radar?.axisColor||this.lineColor,axisStrokeWidth:this.radar?.axisStrokeWidth||2,axisLabelFontSize:this.radar?.axisLabelFontSize||12,curveOpacity:this.radar?.curveOpacity||.5,curveStrokeWidth:this.radar?.curveStrokeWidth||2,graticuleColor:this.radar?.graticuleColor||"#DEDEDE",graticuleStrokeWidth:this.radar?.graticuleStrokeWidth||1,graticuleOpacity:this.radar?.graticuleOpacity||.3,legendBoxSize:this.radar?.legendBoxSize||12,legendFontSize:this.radar?.legendFontSize||12},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=et(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||S(this.primaryColor,{h:-30}),this.git4=this.pie5||S(this.primaryColor,{h:-60}),this.git5=this.pie6||S(this.primaryColor,{h:-90}),this.git6=this.pie7||S(this.primaryColor,{h:60}),this.git7=this.pie8||S(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||W(this.git0),this.gitInv1=this.gitInv1||W(this.git1),this.gitInv2=this.gitInv2||W(this.git2),this.gitInv3=this.gitInv3||W(this.git3),this.gitInv4=this.gitInv4||W(this.git4),this.gitInv5=this.gitInv5||W(this.git5),this.gitInv6=this.gitInv6||W(this.git6),this.gitInv7=this.gitInv7||W(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||rn,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||an}calculate(t){if(typeof t!="object"){this.updateColors();return}const r=Object.keys(t);r.forEach(i=>{this[i]=t[i]}),this.updateColors(),r.forEach(i=>{this[i]=t[i]})}},p(Fr,"Theme"),Fr),Xm=p(e=>{const t=new Vm;return t.calculate(e),t},"getThemeVariables"),Le={base:{getThemeVariables:zm},dark:{getThemeVariables:Hm},default:{getThemeVariables:Ym},forest:{getThemeVariables:Gm},neutral:{getThemeVariables:Xm}},he={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200,inheritDir:!1},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},Qc={...he,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF",forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES"},themeCSS:void 0,themeVariables:Le.default.getThemeVariables(),sequence:{...he.sequence,messageFont:p(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:p(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:p(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...he.gantt,tickInterval:void 0,useWidth:void 0},c4:{...he.c4,useWidth:void 0,personFont:p(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...he.flowchart,inheritDir:!1},external_personFont:p(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:p(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:p(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:p(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:p(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:p(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:p(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:p(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:p(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:p(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:p(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:p(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:p(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:p(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:p(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:p(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:p(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:p(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:p(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:p(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:p(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...he.pie,useWidth:984},xyChart:{...he.xyChart,useWidth:void 0},requirement:{...he.requirement,useWidth:void 0},packet:{...he.packet},radar:{...he.radar},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","}},Jc=p((e,t="")=>Object.keys(e).reduce((r,i)=>Array.isArray(e[i])?r:typeof e[i]=="object"&&e[i]!==null?[...r,t+i,...Jc(e[i],"")]:[...r,t+i],[]),"keyify"),Km=new Set(Jc(Qc,"")),th=Qc,va=p(e=>{if(F.debug("sanitizeDirective called with",e),!(typeof e!="object"||e==null)){if(Array.isArray(e)){e.forEach(t=>va(t));return}for(const t of Object.keys(e)){if(F.debug("Checking key",t),t.startsWith("__")||t.includes("proto")||t.includes("constr")||!Km.has(t)||e[t]==null){F.debug("sanitize deleting key: ",t),delete e[t];continue}if(typeof e[t]=="object"){F.debug("sanitizing object",t),va(e[t]);continue}const r=["themeCSS","fontFamily","altFontFamily"];for(const i of r)t.includes(i)&&(F.debug("sanitizing css option",t),e[t]=Zm(e[t]))}if(e.themeVariables)for(const t of Object.keys(e.themeVariables)){const r=e.themeVariables[t];r?.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(e.themeVariables[t]="")}F.debug("After sanitization",e)}},"sanitizeDirective"),Zm=p(e=>{let t=0,r=0;for(const i of e){if(t<r)return"{ /* ERROR: Unbalanced CSS */ }";i==="{"?t++:i==="}"&&r++}return t!==r?"{ /* ERROR: Unbalanced CSS */ }":e},"sanitizeCss"),Rr=Object.freeze(th),jt=wt({},Rr),wa,nr=[],_i=wt({},Rr),nn=p((e,t)=>{let r=wt({},e),i={};for(const a of t)ih(a),i=wt(i,a);if(r=wt(r,i),i.theme&&i.theme in Le){const a=wt({},wa),n=wt(a.themeVariables||{},i.themeVariables);r.theme&&r.theme in Le&&(r.themeVariables=Le[r.theme].getThemeVariables(n))}return _i=r,ah(_i),_i},"updateCurrentConfig"),Qm=p(e=>(jt=wt({},Rr),jt=wt(jt,e),e.theme&&Le[e.theme]&&(jt.themeVariables=Le[e.theme].getThemeVariables(e.themeVariables)),nn(jt,nr),jt),"setSiteConfig"),Jm=p(e=>{wa=wt({},e)},"saveConfigFromInitialize"),t0=p(e=>(jt=wt(jt,e),nn(jt,nr),jt),"updateSiteConfig"),eh=p(()=>wt({},jt),"getSiteConfig"),rh=p(e=>(ah(e),wt(_i,e),Ft()),"setConfig"),Ft=p(()=>wt({},_i),"getConfig"),ih=p(e=>{e&&(["secure",...jt.secure??[]].forEach(t=>{Object.hasOwn(e,t)&&(F.debug(`Denied attempt to modify a secure key ${t}`,e[t]),delete e[t])}),Object.keys(e).forEach(t=>{t.startsWith("__")&&delete e[t]}),Object.keys(e).forEach(t=>{typeof e[t]=="string"&&(e[t].includes("<")||e[t].includes(">")||e[t].includes("url(data:"))&&delete e[t],typeof e[t]=="object"&&ih(e[t])}))},"sanitize"),e0=p(e=>{va(e),e.fontFamily&&!e.themeVariables?.fontFamily&&(e.themeVariables={...e.themeVariables,fontFamily:e.fontFamily}),nr.push(e),nn(jt,nr)},"addDirective"),Sa=p((e=jt)=>{nr=[],nn(e,nr)},"reset"),r0={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},_l={},i0=p(e=>{_l[e]||(F.warn(r0[e]),_l[e]=!0)},"issueWarning"),ah=p(e=>{e&&(e.lazyLoadedDiagrams||e.loadExternalDiagramsAtStartup)&&i0("LAZY_LOAD_DEPRECATED")},"checkConfig"),yL=p(()=>{let e={};wa&&(e=wt(e,wa));for(const t of nr)e=wt(e,t);return e},"getUserDefinedConfig"),Ii=/<br\s*\/?>/gi,a0=p(e=>e?oh(e).replace(/\\n/g,"#br#").split("#br#"):[""],"getRows"),n0=(()=>{let e=!1;return()=>{e||(nh(),e=!0)}})();function nh(){const e="data-temp-href-target";Ir.addHook("beforeSanitizeAttributes",t=>{t.tagName==="A"&&t.hasAttribute("target")&&t.setAttribute(e,t.getAttribute("target")??"")}),Ir.addHook("afterSanitizeAttributes",t=>{t.tagName==="A"&&t.hasAttribute(e)&&(t.setAttribute("target",t.getAttribute(e)??""),t.removeAttribute(e),t.getAttribute("target")==="_blank"&&t.setAttribute("rel","noopener"))})}p(nh,"setupDompurifyHooks");var sh=p(e=>(n0(),Ir.sanitize(e)),"removeScript"),Cl=p((e,t)=>{if(t.flowchart?.htmlLabels!==!1){const r=t.securityLevel;r==="antiscript"||r==="strict"?e=sh(e):r!=="loose"&&(e=oh(e),e=e.replace(/</g,"<").replace(/>/g,">"),e=e.replace(/=/g,"="),e=c0(e))}return e},"sanitizeMore"),Jt=p((e,t)=>e&&(t.dompurifyConfig?e=Ir.sanitize(Cl(e,t),t.dompurifyConfig).toString():e=Ir.sanitize(Cl(e,t),{FORBID_TAGS:["style"]}).toString(),e),"sanitizeText"),s0=p((e,t)=>typeof e=="string"?Jt(e,t):e.flat().map(r=>Jt(r,t)),"sanitizeTextOrArray"),o0=p(e=>Ii.test(e),"hasBreaks"),l0=p(e=>e.split(Ii),"splitBreaks"),c0=p(e=>e.replace(/#br#/g,"<br/>"),"placeholderToBreak"),oh=p(e=>e.replace(Ii,"#br#"),"breakToPlaceholder"),h0=p(e=>{let t="";return e&&(t=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,t=CSS.escape(t)),t},"getUrl"),kt=p(e=>!(e===!1||["false","null","0"].includes(String(e).trim().toLowerCase())),"evaluate"),u0=p(function(...e){const t=e.filter(r=>!isNaN(r));return Math.max(...t)},"getMax"),f0=p(function(...e){const t=e.filter(r=>!isNaN(r));return Math.min(...t)},"getMin"),vl=p(function(e){const t=e.split(/(,)/),r=[];for(let i=0;i<t.length;i++){let a=t[i];if(a===","&&i>0&&i+1<t.length){const n=t[i-1],o=t[i+1];d0(n,o)&&(a=n+","+o,i++,r.pop())}r.push(p0(a))}return r.join("")},"parseGenericTypes"),os=p((e,t)=>Math.max(0,e.split(t).length-1),"countOccurrence"),d0=p((e,t)=>{const r=os(e,"~"),i=os(t,"~");return r===1&&i===1},"shouldCombineSets"),p0=p(e=>{const t=os(e,"~");let r=!1;if(t<=1)return e;t%2!==0&&e.startsWith("~")&&(e=e.substring(1),r=!0);const i=[...e];let a=i.indexOf("~"),n=i.lastIndexOf("~");for(;a!==-1&&n!==-1&&a!==n;)i[a]="<",i[n]=">",a=i.indexOf("~"),n=i.lastIndexOf("~");return r&&i.unshift("~"),i.join("")},"processSet"),wl=p(()=>window.MathMLElement!==void 0,"isMathMLSupported"),ls=/\$\$(.*)\$\$/g,Pr=p(e=>(e.match(ls)?.length??0)>0,"hasKatex"),xL=p(async(e,t)=>{const r=document.createElement("div");r.innerHTML=await to(e,t),r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0",document.querySelector("body")?.insertAdjacentElement("beforeend",r);const a={width:r.clientWidth,height:r.clientHeight};return r.remove(),a},"calculateMathMLDimensions"),g0=p(async(e,t)=>{if(!Pr(e))return e;if(!(wl()||t.legacyMathML||t.forceLegacyMathML))return e.replace(ls,"MathML is unsupported in this environment.");{const{default:r}=await ft(async()=>{const{default:a}=await import("./mermaid-VLURNSYL-l6Ov7ssW.js").then(n=>n.e);return{default:a}},__vite__mapDeps([0,1,2,3,4,5])),i=t.forceLegacyMathML||!wl()&&t.legacyMathML?"htmlAndMathml":"mathml";return e.split(Ii).map(a=>Pr(a)?`<div style="display: flex; align-items: center; justify-content: center; white-space: nowrap;">${a}</div>`:`<div>${a}</div>`).join("").replace(ls,(a,n)=>r.renderToString(n,{throwOnError:!0,displayMode:!0,output:i}).replace(/\n/g," ").replace(/<annotation.*<\/annotation>/g,""))}},"renderKatexUnsanitized"),to=p(async(e,t)=>Jt(await g0(e,t),t),"renderKatexSanitized"),Yr={getRows:a0,sanitizeText:Jt,sanitizeTextOrArray:s0,hasBreaks:o0,splitBreaks:l0,lineBreakRegex:Ii,removeScript:sh,getUrl:h0,evaluate:kt,getMax:u0,getMin:f0},m0=p(function(e,t){for(let r of t)e.attr(r[0],r[1])},"d3Attrs"),y0=p(function(e,t,r){let i=new Map;return r?(i.set("width","100%"),i.set("style",`max-width: ${t}px;`)):(i.set("height",e),i.set("width",t)),i},"calculateSvgSizeAttrs"),lh=p(function(e,t,r,i){const a=y0(t,r,i);m0(e,a)},"configureSvgSize"),x0=p(function(e,t,r,i){const a=t.node().getBBox(),n=a.width,o=a.height;F.info(`SVG bounds: ${n}x${o}`,a);let s=0,l=0;F.info(`Graph bounds: ${s}x${l}`,e),s=n+r*2,l=o+r*2,F.info(`Calculated bounds: ${s}x${l}`),lh(t,l,s,i);const c=`${a.x-r} ${a.y-r} ${a.width+2*r} ${a.height+2*r}`;t.attr("viewBox",c)},"setupGraphViewbox"),ha={},b0=p((e,t,r)=>{let i="";return e in ha&&ha[e]?i=ha[e](r):F.warn(`No theme found for ${e}`),` & {
|
|
5
|
+
font-family: ${r.fontFamily};
|
|
6
|
+
font-size: ${r.fontSize};
|
|
7
|
+
fill: ${r.textColor}
|
|
8
|
+
}
|
|
9
|
+
@keyframes edge-animation-frame {
|
|
10
|
+
from {
|
|
11
|
+
stroke-dashoffset: 0;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
@keyframes dash {
|
|
15
|
+
to {
|
|
16
|
+
stroke-dashoffset: 0;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
& .edge-animation-slow {
|
|
20
|
+
stroke-dasharray: 9,5 !important;
|
|
21
|
+
stroke-dashoffset: 900;
|
|
22
|
+
animation: dash 50s linear infinite;
|
|
23
|
+
stroke-linecap: round;
|
|
24
|
+
}
|
|
25
|
+
& .edge-animation-fast {
|
|
26
|
+
stroke-dasharray: 9,5 !important;
|
|
27
|
+
stroke-dashoffset: 900;
|
|
28
|
+
animation: dash 20s linear infinite;
|
|
29
|
+
stroke-linecap: round;
|
|
30
|
+
}
|
|
31
|
+
/* Classes common for multiple diagrams */
|
|
32
|
+
|
|
33
|
+
& .error-icon {
|
|
34
|
+
fill: ${r.errorBkgColor};
|
|
35
|
+
}
|
|
36
|
+
& .error-text {
|
|
37
|
+
fill: ${r.errorTextColor};
|
|
38
|
+
stroke: ${r.errorTextColor};
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
& .edge-thickness-normal {
|
|
42
|
+
stroke-width: 1px;
|
|
43
|
+
}
|
|
44
|
+
& .edge-thickness-thick {
|
|
45
|
+
stroke-width: 3.5px
|
|
46
|
+
}
|
|
47
|
+
& .edge-pattern-solid {
|
|
48
|
+
stroke-dasharray: 0;
|
|
49
|
+
}
|
|
50
|
+
& .edge-thickness-invisible {
|
|
51
|
+
stroke-width: 0;
|
|
52
|
+
fill: none;
|
|
53
|
+
}
|
|
54
|
+
& .edge-pattern-dashed{
|
|
55
|
+
stroke-dasharray: 3;
|
|
56
|
+
}
|
|
57
|
+
.edge-pattern-dotted {
|
|
58
|
+
stroke-dasharray: 2;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
& .marker {
|
|
62
|
+
fill: ${r.lineColor};
|
|
63
|
+
stroke: ${r.lineColor};
|
|
64
|
+
}
|
|
65
|
+
& .marker.cross {
|
|
66
|
+
stroke: ${r.lineColor};
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
& svg {
|
|
70
|
+
font-family: ${r.fontFamily};
|
|
71
|
+
font-size: ${r.fontSize};
|
|
72
|
+
}
|
|
73
|
+
& p {
|
|
74
|
+
margin: 0
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
${i}
|
|
78
|
+
|
|
79
|
+
${t}
|
|
80
|
+
`},"getStyles"),_0=p((e,t)=>{t!==void 0&&(ha[e]=t)},"addStylesForDiagram"),C0=b0,ch={};cm(ch,{clear:()=>v0,getAccDescription:()=>T0,getAccTitle:()=>S0,getDiagramTitle:()=>B0,setAccDescription:()=>k0,setAccTitle:()=>w0,setDiagramTitle:()=>L0});var eo="",ro="",io="",ao=p(e=>Jt(e,Ft()),"sanitizeText"),v0=p(()=>{eo="",io="",ro=""},"clear"),w0=p(e=>{eo=ao(e).replace(/^\s+/g,"")},"setAccTitle"),S0=p(()=>eo,"getAccTitle"),k0=p(e=>{io=ao(e).replace(/\n\s+/g,`
|
|
81
|
+
`)},"setAccDescription"),T0=p(()=>io,"getAccDescription"),L0=p(e=>{ro=ao(e)},"setDiagramTitle"),B0=p(()=>ro,"getDiagramTitle"),Sl=F,A0=Qs,ut=Ft,bL=rh,_L=Rr,no=p(e=>Jt(e,ut()),"sanitizeText"),M0=x0,E0=p(()=>ch,"getCommonDb"),ka={},Ta=p((e,t,r)=>{ka[e]&&Sl.warn(`Diagram with id ${e} already registered. Overwriting.`),ka[e]=t,r&&Zc(e,r),_0(e,t.styles),t.injectUtils?.(Sl,A0,ut,no,M0,E0(),()=>{})},"registerDiagram"),cs=p(e=>{if(e in ka)return ka[e];throw new $0(e)},"getDiagram"),Or,$0=(Or=class extends Error{constructor(t){super(`Diagram ${t} not found.`)}},p(Or,"DiagramNotFoundError"),Or),F0={value:()=>{}};function hh(){for(var e=0,t=arguments.length,r={},i;e<t;++e){if(!(i=arguments[e]+"")||i in r||/[\s.]/.test(i))throw new Error("illegal type: "+i);r[i]=[]}return new ua(r)}function ua(e){this._=e}function O0(e,t){return e.trim().split(/^|\s+/).map(function(r){var i="",a=r.indexOf(".");if(a>=0&&(i=r.slice(a+1),r=r.slice(0,a)),r&&!t.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:i}})}ua.prototype=hh.prototype={constructor:ua,on:function(e,t){var r=this._,i=O0(e+"",r),a,n=-1,o=i.length;if(arguments.length<2){for(;++n<o;)if((a=(e=i[n]).type)&&(a=D0(r[a],e.name)))return a;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++n<o;)if(a=(e=i[n]).type)r[a]=kl(r[a],e.name,t);else if(t==null)for(a in r)r[a]=kl(r[a],e.name,null);return this},copy:function(){var e={},t=this._;for(var r in t)e[r]=t[r].slice();return new ua(e)},call:function(e,t){if((a=arguments.length-2)>0)for(var r=new Array(a),i=0,a,n;i<a;++i)r[i]=arguments[i+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(n=this._[e],i=0,a=n.length;i<a;++i)n[i].value.apply(t,r)},apply:function(e,t,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var i=this._[e],a=0,n=i.length;a<n;++a)i[a].value.apply(t,r)}};function D0(e,t){for(var r=0,i=e.length,a;r<i;++r)if((a=e[r]).name===t)return a.value}function kl(e,t,r){for(var i=0,a=e.length;i<a;++i)if(e[i].name===t){e[i]=F0,e=e.slice(0,i).concat(e.slice(i+1));break}return r!=null&&e.push({name:t,value:r}),e}var hs="http://www.w3.org/1999/xhtml";const Tl={svg:"http://www.w3.org/2000/svg",xhtml:hs,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function sn(e){var t=e+="",r=t.indexOf(":");return r>=0&&(t=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),Tl.hasOwnProperty(t)?{space:Tl[t],local:e}:e}function I0(e){return function(){var t=this.ownerDocument,r=this.namespaceURI;return r===hs&&t.documentElement.namespaceURI===hs?t.createElement(e):t.createElementNS(r,e)}}function R0(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function uh(e){var t=sn(e);return(t.local?R0:I0)(t)}function P0(){}function so(e){return e==null?P0:function(){return this.querySelector(e)}}function N0(e){typeof e!="function"&&(e=so(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var n=t[a],o=n.length,s=i[a]=new Array(o),l,c,h=0;h<o;++h)(l=n[h])&&(c=e.call(l,l.__data__,h,n))&&("__data__"in l&&(c.__data__=l.__data__),s[h]=c);return new Vt(i,this._parents)}function W0(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function z0(){return[]}function fh(e){return e==null?z0:function(){return this.querySelectorAll(e)}}function q0(e){return function(){return W0(e.apply(this,arguments))}}function H0(e){typeof e=="function"?e=q0(e):e=fh(e);for(var t=this._groups,r=t.length,i=[],a=[],n=0;n<r;++n)for(var o=t[n],s=o.length,l,c=0;c<s;++c)(l=o[c])&&(i.push(e.call(l,l.__data__,c,o)),a.push(l));return new Vt(i,a)}function dh(e){return function(){return this.matches(e)}}function ph(e){return function(t){return t.matches(e)}}var j0=Array.prototype.find;function Y0(e){return function(){return j0.call(this.children,e)}}function U0(){return this.firstElementChild}function G0(e){return this.select(e==null?U0:Y0(typeof e=="function"?e:ph(e)))}var V0=Array.prototype.filter;function X0(){return Array.from(this.children)}function K0(e){return function(){return V0.call(this.children,e)}}function Z0(e){return this.selectAll(e==null?X0:K0(typeof e=="function"?e:ph(e)))}function Q0(e){typeof e!="function"&&(e=dh(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var n=t[a],o=n.length,s=i[a]=[],l,c=0;c<o;++c)(l=n[c])&&e.call(l,l.__data__,c,n)&&s.push(l);return new Vt(i,this._parents)}function gh(e){return new Array(e.length)}function J0(){return new Vt(this._enter||this._groups.map(gh),this._parents)}function La(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}La.prototype={constructor:La,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function ty(e){return function(){return e}}function ey(e,t,r,i,a,n){for(var o=0,s,l=t.length,c=n.length;o<c;++o)(s=t[o])?(s.__data__=n[o],i[o]=s):r[o]=new La(e,n[o]);for(;o<l;++o)(s=t[o])&&(a[o]=s)}function ry(e,t,r,i,a,n,o){var s,l,c=new Map,h=t.length,u=n.length,f=new Array(h),d;for(s=0;s<h;++s)(l=t[s])&&(f[s]=d=o.call(l,l.__data__,s,t)+"",c.has(d)?a[s]=l:c.set(d,l));for(s=0;s<u;++s)d=o.call(e,n[s],s,n)+"",(l=c.get(d))?(i[s]=l,l.__data__=n[s],c.delete(d)):r[s]=new La(e,n[s]);for(s=0;s<h;++s)(l=t[s])&&c.get(f[s])===l&&(a[s]=l)}function iy(e){return e.__data__}function ay(e,t){if(!arguments.length)return Array.from(this,iy);var r=t?ry:ey,i=this._parents,a=this._groups;typeof e!="function"&&(e=ty(e));for(var n=a.length,o=new Array(n),s=new Array(n),l=new Array(n),c=0;c<n;++c){var h=i[c],u=a[c],f=u.length,d=ny(e.call(h,h&&h.__data__,c,i)),g=d.length,m=s[c]=new Array(g),y=o[c]=new Array(g),x=l[c]=new Array(f);r(h,u,m,y,x,d,t);for(var b=0,_=0,w,v;b<g;++b)if(w=m[b]){for(b>=_&&(_=b+1);!(v=y[_])&&++_<g;);w._next=v||null}}return o=new Vt(o,i),o._enter=s,o._exit=l,o}function ny(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function sy(){return new Vt(this._exit||this._groups.map(gh),this._parents)}function oy(e,t,r){var i=this.enter(),a=this,n=this.exit();return typeof e=="function"?(i=e(i),i&&(i=i.selection())):i=i.append(e+""),t!=null&&(a=t(a),a&&(a=a.selection())),r==null?n.remove():r(n),i&&a?i.merge(a).order():a}function ly(e){for(var t=e.selection?e.selection():e,r=this._groups,i=t._groups,a=r.length,n=i.length,o=Math.min(a,n),s=new Array(a),l=0;l<o;++l)for(var c=r[l],h=i[l],u=c.length,f=s[l]=new Array(u),d,g=0;g<u;++g)(d=c[g]||h[g])&&(f[g]=d);for(;l<a;++l)s[l]=r[l];return new Vt(s,this._parents)}function cy(){for(var e=this._groups,t=-1,r=e.length;++t<r;)for(var i=e[t],a=i.length-1,n=i[a],o;--a>=0;)(o=i[a])&&(n&&o.compareDocumentPosition(n)^4&&n.parentNode.insertBefore(o,n),n=o);return this}function hy(e){e||(e=uy);function t(u,f){return u&&f?e(u.__data__,f.__data__):!u-!f}for(var r=this._groups,i=r.length,a=new Array(i),n=0;n<i;++n){for(var o=r[n],s=o.length,l=a[n]=new Array(s),c,h=0;h<s;++h)(c=o[h])&&(l[h]=c);l.sort(t)}return new Vt(a,this._parents).order()}function uy(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function fy(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function dy(){return Array.from(this)}function py(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],a=0,n=i.length;a<n;++a){var o=i[a];if(o)return o}return null}function gy(){let e=0;for(const t of this)++e;return e}function my(){return!this.node()}function yy(e){for(var t=this._groups,r=0,i=t.length;r<i;++r)for(var a=t[r],n=0,o=a.length,s;n<o;++n)(s=a[n])&&e.call(s,s.__data__,n,a);return this}function xy(e){return function(){this.removeAttribute(e)}}function by(e){return function(){this.removeAttributeNS(e.space,e.local)}}function _y(e,t){return function(){this.setAttribute(e,t)}}function Cy(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function vy(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function wy(e,t){return function(){var r=t.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function Sy(e,t){var r=sn(e);if(arguments.length<2){var i=this.node();return r.local?i.getAttributeNS(r.space,r.local):i.getAttribute(r)}return this.each((t==null?r.local?by:xy:typeof t=="function"?r.local?wy:vy:r.local?Cy:_y)(r,t))}function mh(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function ky(e){return function(){this.style.removeProperty(e)}}function Ty(e,t,r){return function(){this.style.setProperty(e,t,r)}}function Ly(e,t,r){return function(){var i=t.apply(this,arguments);i==null?this.style.removeProperty(e):this.style.setProperty(e,i,r)}}function By(e,t,r){return arguments.length>1?this.each((t==null?ky:typeof t=="function"?Ly:Ty)(e,t,r??"")):Nr(this.node(),e)}function Nr(e,t){return e.style.getPropertyValue(t)||mh(e).getComputedStyle(e,null).getPropertyValue(t)}function Ay(e){return function(){delete this[e]}}function My(e,t){return function(){this[e]=t}}function Ey(e,t){return function(){var r=t.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function $y(e,t){return arguments.length>1?this.each((t==null?Ay:typeof t=="function"?Ey:My)(e,t)):this.node()[e]}function yh(e){return e.trim().split(/^|\s+/)}function oo(e){return e.classList||new xh(e)}function xh(e){this._node=e,this._names=yh(e.getAttribute("class")||"")}xh.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function bh(e,t){for(var r=oo(e),i=-1,a=t.length;++i<a;)r.add(t[i])}function _h(e,t){for(var r=oo(e),i=-1,a=t.length;++i<a;)r.remove(t[i])}function Fy(e){return function(){bh(this,e)}}function Oy(e){return function(){_h(this,e)}}function Dy(e,t){return function(){(t.apply(this,arguments)?bh:_h)(this,e)}}function Iy(e,t){var r=yh(e+"");if(arguments.length<2){for(var i=oo(this.node()),a=-1,n=r.length;++a<n;)if(!i.contains(r[a]))return!1;return!0}return this.each((typeof t=="function"?Dy:t?Fy:Oy)(r,t))}function Ry(){this.textContent=""}function Py(e){return function(){this.textContent=e}}function Ny(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function Wy(e){return arguments.length?this.each(e==null?Ry:(typeof e=="function"?Ny:Py)(e)):this.node().textContent}function zy(){this.innerHTML=""}function qy(e){return function(){this.innerHTML=e}}function Hy(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function jy(e){return arguments.length?this.each(e==null?zy:(typeof e=="function"?Hy:qy)(e)):this.node().innerHTML}function Yy(){this.nextSibling&&this.parentNode.appendChild(this)}function Uy(){return this.each(Yy)}function Gy(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Vy(){return this.each(Gy)}function Xy(e){var t=typeof e=="function"?e:uh(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function Ky(){return null}function Zy(e,t){var r=typeof e=="function"?e:uh(e),i=t==null?Ky:typeof t=="function"?t:so(t);return this.select(function(){return this.insertBefore(r.apply(this,arguments),i.apply(this,arguments)||null)})}function Qy(){var e=this.parentNode;e&&e.removeChild(this)}function Jy(){return this.each(Qy)}function tx(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function ex(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function rx(e){return this.select(e?ex:tx)}function ix(e){return arguments.length?this.property("__data__",e):this.node().__data__}function ax(e){return function(t){e.call(this,t,this.__data__)}}function nx(e){return e.trim().split(/^|\s+/).map(function(t){var r="",i=t.indexOf(".");return i>=0&&(r=t.slice(i+1),t=t.slice(0,i)),{type:t,name:r}})}function sx(e){return function(){var t=this.__on;if(t){for(var r=0,i=-1,a=t.length,n;r<a;++r)n=t[r],(!e.type||n.type===e.type)&&n.name===e.name?this.removeEventListener(n.type,n.listener,n.options):t[++i]=n;++i?t.length=i:delete this.__on}}}function ox(e,t,r){return function(){var i=this.__on,a,n=ax(t);if(i){for(var o=0,s=i.length;o<s;++o)if((a=i[o]).type===e.type&&a.name===e.name){this.removeEventListener(a.type,a.listener,a.options),this.addEventListener(a.type,a.listener=n,a.options=r),a.value=t;return}}this.addEventListener(e.type,n,r),a={type:e.type,name:e.name,value:t,listener:n,options:r},i?i.push(a):this.__on=[a]}}function lx(e,t,r){var i=nx(e+""),a,n=i.length,o;if(arguments.length<2){var s=this.node().__on;if(s){for(var l=0,c=s.length,h;l<c;++l)for(a=0,h=s[l];a<n;++a)if((o=i[a]).type===h.type&&o.name===h.name)return h.value}return}for(s=t?ox:sx,a=0;a<n;++a)this.each(s(i[a],t,r));return this}function Ch(e,t,r){var i=mh(e),a=i.CustomEvent;typeof a=="function"?a=new a(t,r):(a=i.document.createEvent("Event"),r?(a.initEvent(t,r.bubbles,r.cancelable),a.detail=r.detail):a.initEvent(t,!1,!1)),e.dispatchEvent(a)}function cx(e,t){return function(){return Ch(this,e,t)}}function hx(e,t){return function(){return Ch(this,e,t.apply(this,arguments))}}function ux(e,t){return this.each((typeof t=="function"?hx:cx)(e,t))}function*fx(){for(var e=this._groups,t=0,r=e.length;t<r;++t)for(var i=e[t],a=0,n=i.length,o;a<n;++a)(o=i[a])&&(yield o)}var vh=[null];function Vt(e,t){this._groups=e,this._parents=t}function Ri(){return new Vt([[document.documentElement]],vh)}function dx(){return this}Vt.prototype=Ri.prototype={constructor:Vt,select:N0,selectAll:H0,selectChild:G0,selectChildren:Z0,filter:Q0,data:ay,enter:J0,exit:sy,join:oy,merge:ly,selection:dx,order:cy,sort:hy,call:fy,nodes:dy,node:py,size:gy,empty:my,each:yy,attr:Sy,style:By,property:$y,classed:Iy,text:Wy,html:jy,raise:Uy,lower:Vy,append:Xy,insert:Zy,remove:Jy,clone:rx,datum:ix,on:lx,dispatch:ux,[Symbol.iterator]:fx};function ht(e){return typeof e=="string"?new Vt([[document.querySelector(e)]],[document.documentElement]):new Vt([[e]],vh)}function lo(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function wh(e,t){var r=Object.create(e.prototype);for(var i in t)r[i]=t[i];return r}function Pi(){}var vi=.7,Ba=1/vi,Tr="\\s*([+-]?\\d+)\\s*",wi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",de="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",px=/^#([0-9a-f]{3,8})$/,gx=new RegExp(`^rgb\\(${Tr},${Tr},${Tr}\\)$`),mx=new RegExp(`^rgb\\(${de},${de},${de}\\)$`),yx=new RegExp(`^rgba\\(${Tr},${Tr},${Tr},${wi}\\)$`),xx=new RegExp(`^rgba\\(${de},${de},${de},${wi}\\)$`),bx=new RegExp(`^hsl\\(${wi},${de},${de}\\)$`),_x=new RegExp(`^hsla\\(${wi},${de},${de},${wi}\\)$`),Ll={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};lo(Pi,Si,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Bl,formatHex:Bl,formatHex8:Cx,formatHsl:vx,formatRgb:Al,toString:Al});function Bl(){return this.rgb().formatHex()}function Cx(){return this.rgb().formatHex8()}function vx(){return Sh(this).formatHsl()}function Al(){return this.rgb().formatRgb()}function Si(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=px.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?Ml(t):r===3?new Ut(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?Qi(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?Qi(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=gx.exec(e))?new Ut(t[1],t[2],t[3],1):(t=mx.exec(e))?new Ut(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=yx.exec(e))?Qi(t[1],t[2],t[3],t[4]):(t=xx.exec(e))?Qi(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=bx.exec(e))?Fl(t[1],t[2]/100,t[3]/100,1):(t=_x.exec(e))?Fl(t[1],t[2]/100,t[3]/100,t[4]):Ll.hasOwnProperty(e)?Ml(Ll[e]):e==="transparent"?new Ut(NaN,NaN,NaN,0):null}function Ml(e){return new Ut(e>>16&255,e>>8&255,e&255,1)}function Qi(e,t,r,i){return i<=0&&(e=t=r=NaN),new Ut(e,t,r,i)}function wx(e){return e instanceof Pi||(e=Si(e)),e?(e=e.rgb(),new Ut(e.r,e.g,e.b,e.opacity)):new Ut}function us(e,t,r,i){return arguments.length===1?wx(e):new Ut(e,t,r,i??1)}function Ut(e,t,r,i){this.r=+e,this.g=+t,this.b=+r,this.opacity=+i}lo(Ut,us,wh(Pi,{brighter(e){return e=e==null?Ba:Math.pow(Ba,e),new Ut(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?vi:Math.pow(vi,e),new Ut(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Ut(rr(this.r),rr(this.g),rr(this.b),Aa(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:El,formatHex:El,formatHex8:Sx,formatRgb:$l,toString:$l}));function El(){return`#${Qe(this.r)}${Qe(this.g)}${Qe(this.b)}`}function Sx(){return`#${Qe(this.r)}${Qe(this.g)}${Qe(this.b)}${Qe((isNaN(this.opacity)?1:this.opacity)*255)}`}function $l(){const e=Aa(this.opacity);return`${e===1?"rgb(":"rgba("}${rr(this.r)}, ${rr(this.g)}, ${rr(this.b)}${e===1?")":`, ${e})`}`}function Aa(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function rr(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Qe(e){return e=rr(e),(e<16?"0":"")+e.toString(16)}function Fl(e,t,r,i){return i<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new ae(e,t,r,i)}function Sh(e){if(e instanceof ae)return new ae(e.h,e.s,e.l,e.opacity);if(e instanceof Pi||(e=Si(e)),!e)return new ae;if(e instanceof ae)return e;e=e.rgb();var t=e.r/255,r=e.g/255,i=e.b/255,a=Math.min(t,r,i),n=Math.max(t,r,i),o=NaN,s=n-a,l=(n+a)/2;return s?(t===n?o=(r-i)/s+(r<i)*6:r===n?o=(i-t)/s+2:o=(t-r)/s+4,s/=l<.5?n+a:2-n-a,o*=60):s=l>0&&l<1?0:o,new ae(o,s,l,e.opacity)}function kx(e,t,r,i){return arguments.length===1?Sh(e):new ae(e,t,r,i??1)}function ae(e,t,r,i){this.h=+e,this.s=+t,this.l=+r,this.opacity=+i}lo(ae,kx,wh(Pi,{brighter(e){return e=e==null?Ba:Math.pow(Ba,e),new ae(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?vi:Math.pow(vi,e),new ae(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,i=r+(r<.5?r:1-r)*t,a=2*r-i;return new Ut(qn(e>=240?e-240:e+120,a,i),qn(e,a,i),qn(e<120?e+240:e-120,a,i),this.opacity)},clamp(){return new ae(Ol(this.h),Ji(this.s),Ji(this.l),Aa(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Aa(this.opacity);return`${e===1?"hsl(":"hsla("}${Ol(this.h)}, ${Ji(this.s)*100}%, ${Ji(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ol(e){return e=(e||0)%360,e<0?e+360:e}function Ji(e){return Math.max(0,Math.min(1,e||0))}function qn(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const co=e=>()=>e;function kh(e,t){return function(r){return e+r*t}}function Tx(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(i){return Math.pow(e+i*t,r)}}function CL(e,t){var r=t-e;return r?kh(e,r>180||r<-180?r-360*Math.round(r/360):r):co(isNaN(e)?t:e)}function Lx(e){return(e=+e)==1?Th:function(t,r){return r-t?Tx(t,r,e):co(isNaN(t)?r:t)}}function Th(e,t){var r=t-e;return r?kh(e,r):co(isNaN(e)?t:e)}const Dl=(function e(t){var r=Lx(t);function i(a,n){var o=r((a=us(a)).r,(n=us(n)).r),s=r(a.g,n.g),l=r(a.b,n.b),c=Th(a.opacity,n.opacity);return function(h){return a.r=o(h),a.g=s(h),a.b=l(h),a.opacity=c(h),a+""}}return i.gamma=e,i})(1);function Oe(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}var fs=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Hn=new RegExp(fs.source,"g");function Bx(e){return function(){return e}}function Ax(e){return function(t){return e(t)+""}}function Mx(e,t){var r=fs.lastIndex=Hn.lastIndex=0,i,a,n,o=-1,s=[],l=[];for(e=e+"",t=t+"";(i=fs.exec(e))&&(a=Hn.exec(t));)(n=a.index)>r&&(n=t.slice(r,n),s[o]?s[o]+=n:s[++o]=n),(i=i[0])===(a=a[0])?s[o]?s[o]+=a:s[++o]=a:(s[++o]=null,l.push({i:o,x:Oe(i,a)})),r=Hn.lastIndex;return r<t.length&&(n=t.slice(r),s[o]?s[o]+=n:s[++o]=n),s.length<2?l[0]?Ax(l[0].x):Bx(t):(t=l.length,function(c){for(var h=0,u;h<t;++h)s[(u=l[h]).i]=u.x(c);return s.join("")})}var Il=180/Math.PI,ds={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function Lh(e,t,r,i,a,n){var o,s,l;return(o=Math.sqrt(e*e+t*t))&&(e/=o,t/=o),(l=e*r+t*i)&&(r-=e*l,i-=t*l),(s=Math.sqrt(r*r+i*i))&&(r/=s,i/=s,l/=s),e*i<t*r&&(e=-e,t=-t,l=-l,o=-o),{translateX:a,translateY:n,rotate:Math.atan2(t,e)*Il,skewX:Math.atan(l)*Il,scaleX:o,scaleY:s}}var ta;function Ex(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?ds:Lh(t.a,t.b,t.c,t.d,t.e,t.f)}function $x(e){return e==null||(ta||(ta=document.createElementNS("http://www.w3.org/2000/svg","g")),ta.setAttribute("transform",e),!(e=ta.transform.baseVal.consolidate()))?ds:(e=e.matrix,Lh(e.a,e.b,e.c,e.d,e.e,e.f))}function Bh(e,t,r,i){function a(c){return c.length?c.pop()+" ":""}function n(c,h,u,f,d,g){if(c!==u||h!==f){var m=d.push("translate(",null,t,null,r);g.push({i:m-4,x:Oe(c,u)},{i:m-2,x:Oe(h,f)})}else(u||f)&&d.push("translate("+u+t+f+r)}function o(c,h,u,f){c!==h?(c-h>180?h+=360:h-c>180&&(c+=360),f.push({i:u.push(a(u)+"rotate(",null,i)-2,x:Oe(c,h)})):h&&u.push(a(u)+"rotate("+h+i)}function s(c,h,u,f){c!==h?f.push({i:u.push(a(u)+"skewX(",null,i)-2,x:Oe(c,h)}):h&&u.push(a(u)+"skewX("+h+i)}function l(c,h,u,f,d,g){if(c!==u||h!==f){var m=d.push(a(d)+"scale(",null,",",null,")");g.push({i:m-4,x:Oe(c,u)},{i:m-2,x:Oe(h,f)})}else(u!==1||f!==1)&&d.push(a(d)+"scale("+u+","+f+")")}return function(c,h){var u=[],f=[];return c=e(c),h=e(h),n(c.translateX,c.translateY,h.translateX,h.translateY,u,f),o(c.rotate,h.rotate,u,f),s(c.skewX,h.skewX,u,f),l(c.scaleX,c.scaleY,h.scaleX,h.scaleY,u,f),c=h=null,function(d){for(var g=-1,m=f.length,y;++g<m;)u[(y=f[g]).i]=y.x(d);return u.join("")}}}var Fx=Bh(Ex,"px, ","px)","deg)"),Ox=Bh($x,", ",")",")"),Wr=0,hi=0,ai=0,Ah=1e3,Ma,ui,Ea=0,sr=0,on=0,ki=typeof performance=="object"&&performance.now?performance:Date,Mh=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function ho(){return sr||(Mh(Dx),sr=ki.now()+on)}function Dx(){sr=0}function $a(){this._call=this._time=this._next=null}$a.prototype=Eh.prototype={constructor:$a,restart:function(e,t,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?ho():+r)+(t==null?0:+t),!this._next&&ui!==this&&(ui?ui._next=this:Ma=this,ui=this),this._call=e,this._time=r,ps()},stop:function(){this._call&&(this._call=null,this._time=1/0,ps())}};function Eh(e,t,r){var i=new $a;return i.restart(e,t,r),i}function Ix(){ho(),++Wr;for(var e=Ma,t;e;)(t=sr-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Wr}function Rl(){sr=(Ea=ki.now())+on,Wr=hi=0;try{Ix()}finally{Wr=0,Px(),sr=0}}function Rx(){var e=ki.now(),t=e-Ea;t>Ah&&(on-=t,Ea=e)}function Px(){for(var e,t=Ma,r,i=1/0;t;)t._call?(i>t._time&&(i=t._time),e=t,t=t._next):(r=t._next,t._next=null,t=e?e._next=r:Ma=r);ui=e,ps(i)}function ps(e){if(!Wr){hi&&(hi=clearTimeout(hi));var t=e-sr;t>24?(e<1/0&&(hi=setTimeout(Rl,e-ki.now()-on)),ai&&(ai=clearInterval(ai))):(ai||(Ea=ki.now(),ai=setInterval(Rx,Ah)),Wr=1,Mh(Rl))}}function Pl(e,t,r){var i=new $a;return t=t==null?0:+t,i.restart(a=>{i.stop(),e(a+t)},t,r),i}var Nx=hh("start","end","cancel","interrupt"),Wx=[],$h=0,Nl=1,gs=2,fa=3,Wl=4,ms=5,da=6;function ln(e,t,r,i,a,n){var o=e.__transition;if(!o)e.__transition={};else if(r in o)return;zx(e,r,{name:t,index:i,group:a,on:Nx,tween:Wx,time:n.time,delay:n.delay,duration:n.duration,ease:n.ease,timer:null,state:$h})}function uo(e,t){var r=le(e,t);if(r.state>$h)throw new Error("too late; already scheduled");return r}function me(e,t){var r=le(e,t);if(r.state>fa)throw new Error("too late; already running");return r}function le(e,t){var r=e.__transition;if(!r||!(r=r[t]))throw new Error("transition not found");return r}function zx(e,t,r){var i=e.__transition,a;i[t]=r,r.timer=Eh(n,0,r.time);function n(c){r.state=Nl,r.timer.restart(o,r.delay,r.time),r.delay<=c&&o(c-r.delay)}function o(c){var h,u,f,d;if(r.state!==Nl)return l();for(h in i)if(d=i[h],d.name===r.name){if(d.state===fa)return Pl(o);d.state===Wl?(d.state=da,d.timer.stop(),d.on.call("interrupt",e,e.__data__,d.index,d.group),delete i[h]):+h<t&&(d.state=da,d.timer.stop(),d.on.call("cancel",e,e.__data__,d.index,d.group),delete i[h])}if(Pl(function(){r.state===fa&&(r.state=Wl,r.timer.restart(s,r.delay,r.time),s(c))}),r.state=gs,r.on.call("start",e,e.__data__,r.index,r.group),r.state===gs){for(r.state=fa,a=new Array(f=r.tween.length),h=0,u=-1;h<f;++h)(d=r.tween[h].value.call(e,e.__data__,r.index,r.group))&&(a[++u]=d);a.length=u+1}}function s(c){for(var h=c<r.duration?r.ease.call(null,c/r.duration):(r.timer.restart(l),r.state=ms,1),u=-1,f=a.length;++u<f;)a[u].call(e,h);r.state===ms&&(r.on.call("end",e,e.__data__,r.index,r.group),l())}function l(){r.state=da,r.timer.stop(),delete i[t];for(var c in i)return;delete e.__transition}}function qx(e,t){var r=e.__transition,i,a,n=!0,o;if(r){t=t==null?null:t+"";for(o in r){if((i=r[o]).name!==t){n=!1;continue}a=i.state>gs&&i.state<ms,i.state=da,i.timer.stop(),i.on.call(a?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete r[o]}n&&delete e.__transition}}function Hx(e){return this.each(function(){qx(this,e)})}function jx(e,t){var r,i;return function(){var a=me(this,e),n=a.tween;if(n!==r){i=r=n;for(var o=0,s=i.length;o<s;++o)if(i[o].name===t){i=i.slice(),i.splice(o,1);break}}a.tween=i}}function Yx(e,t,r){var i,a;if(typeof r!="function")throw new Error;return function(){var n=me(this,e),o=n.tween;if(o!==i){a=(i=o).slice();for(var s={name:t,value:r},l=0,c=a.length;l<c;++l)if(a[l].name===t){a[l]=s;break}l===c&&a.push(s)}n.tween=a}}function Ux(e,t){var r=this._id;if(e+="",arguments.length<2){for(var i=le(this.node(),r).tween,a=0,n=i.length,o;a<n;++a)if((o=i[a]).name===e)return o.value;return null}return this.each((t==null?jx:Yx)(r,e,t))}function fo(e,t,r){var i=e._id;return e.each(function(){var a=me(this,i);(a.value||(a.value={}))[t]=r.apply(this,arguments)}),function(a){return le(a,i).value[t]}}function Fh(e,t){var r;return(typeof t=="number"?Oe:t instanceof Si?Dl:(r=Si(t))?(t=r,Dl):Mx)(e,t)}function Gx(e){return function(){this.removeAttribute(e)}}function Vx(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Xx(e,t,r){var i,a=r+"",n;return function(){var o=this.getAttribute(e);return o===a?null:o===i?n:n=t(i=o,r)}}function Kx(e,t,r){var i,a=r+"",n;return function(){var o=this.getAttributeNS(e.space,e.local);return o===a?null:o===i?n:n=t(i=o,r)}}function Zx(e,t,r){var i,a,n;return function(){var o,s=r(this),l;return s==null?void this.removeAttribute(e):(o=this.getAttribute(e),l=s+"",o===l?null:o===i&&l===a?n:(a=l,n=t(i=o,s)))}}function Qx(e,t,r){var i,a,n;return function(){var o,s=r(this),l;return s==null?void this.removeAttributeNS(e.space,e.local):(o=this.getAttributeNS(e.space,e.local),l=s+"",o===l?null:o===i&&l===a?n:(a=l,n=t(i=o,s)))}}function Jx(e,t){var r=sn(e),i=r==="transform"?Ox:Fh;return this.attrTween(e,typeof t=="function"?(r.local?Qx:Zx)(r,i,fo(this,"attr."+e,t)):t==null?(r.local?Vx:Gx)(r):(r.local?Kx:Xx)(r,i,t))}function tb(e,t){return function(r){this.setAttribute(e,t.call(this,r))}}function eb(e,t){return function(r){this.setAttributeNS(e.space,e.local,t.call(this,r))}}function rb(e,t){var r,i;function a(){var n=t.apply(this,arguments);return n!==i&&(r=(i=n)&&eb(e,n)),r}return a._value=t,a}function ib(e,t){var r,i;function a(){var n=t.apply(this,arguments);return n!==i&&(r=(i=n)&&tb(e,n)),r}return a._value=t,a}function ab(e,t){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;var i=sn(e);return this.tween(r,(i.local?rb:ib)(i,t))}function nb(e,t){return function(){uo(this,e).delay=+t.apply(this,arguments)}}function sb(e,t){return t=+t,function(){uo(this,e).delay=t}}function ob(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?nb:sb)(t,e)):le(this.node(),t).delay}function lb(e,t){return function(){me(this,e).duration=+t.apply(this,arguments)}}function cb(e,t){return t=+t,function(){me(this,e).duration=t}}function hb(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?lb:cb)(t,e)):le(this.node(),t).duration}function ub(e,t){if(typeof t!="function")throw new Error;return function(){me(this,e).ease=t}}function fb(e){var t=this._id;return arguments.length?this.each(ub(t,e)):le(this.node(),t).ease}function db(e,t){return function(){var r=t.apply(this,arguments);if(typeof r!="function")throw new Error;me(this,e).ease=r}}function pb(e){if(typeof e!="function")throw new Error;return this.each(db(this._id,e))}function gb(e){typeof e!="function"&&(e=dh(e));for(var t=this._groups,r=t.length,i=new Array(r),a=0;a<r;++a)for(var n=t[a],o=n.length,s=i[a]=[],l,c=0;c<o;++c)(l=n[c])&&e.call(l,l.__data__,c,n)&&s.push(l);return new Ae(i,this._parents,this._name,this._id)}function mb(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,r=e._groups,i=t.length,a=r.length,n=Math.min(i,a),o=new Array(i),s=0;s<n;++s)for(var l=t[s],c=r[s],h=l.length,u=o[s]=new Array(h),f,d=0;d<h;++d)(f=l[d]||c[d])&&(u[d]=f);for(;s<i;++s)o[s]=t[s];return new Ae(o,this._parents,this._name,this._id)}function yb(e){return(e+"").trim().split(/^|\s+/).every(function(t){var r=t.indexOf(".");return r>=0&&(t=t.slice(0,r)),!t||t==="start"})}function xb(e,t,r){var i,a,n=yb(t)?uo:me;return function(){var o=n(this,e),s=o.on;s!==i&&(a=(i=s).copy()).on(t,r),o.on=a}}function bb(e,t){var r=this._id;return arguments.length<2?le(this.node(),r).on.on(e):this.each(xb(r,e,t))}function _b(e){return function(){var t=this.parentNode;for(var r in this.__transition)if(+r!==e)return;t&&t.removeChild(this)}}function Cb(){return this.on("end.remove",_b(this._id))}function vb(e){var t=this._name,r=this._id;typeof e!="function"&&(e=so(e));for(var i=this._groups,a=i.length,n=new Array(a),o=0;o<a;++o)for(var s=i[o],l=s.length,c=n[o]=new Array(l),h,u,f=0;f<l;++f)(h=s[f])&&(u=e.call(h,h.__data__,f,s))&&("__data__"in h&&(u.__data__=h.__data__),c[f]=u,ln(c[f],t,r,f,c,le(h,r)));return new Ae(n,this._parents,t,r)}function wb(e){var t=this._name,r=this._id;typeof e!="function"&&(e=fh(e));for(var i=this._groups,a=i.length,n=[],o=[],s=0;s<a;++s)for(var l=i[s],c=l.length,h,u=0;u<c;++u)if(h=l[u]){for(var f=e.call(h,h.__data__,u,l),d,g=le(h,r),m=0,y=f.length;m<y;++m)(d=f[m])&&ln(d,t,r,m,f,g);n.push(f),o.push(h)}return new Ae(n,o,t,r)}var Sb=Ri.prototype.constructor;function kb(){return new Sb(this._groups,this._parents)}function Tb(e,t){var r,i,a;return function(){var n=Nr(this,e),o=(this.style.removeProperty(e),Nr(this,e));return n===o?null:n===r&&o===i?a:a=t(r=n,i=o)}}function Oh(e){return function(){this.style.removeProperty(e)}}function Lb(e,t,r){var i,a=r+"",n;return function(){var o=Nr(this,e);return o===a?null:o===i?n:n=t(i=o,r)}}function Bb(e,t,r){var i,a,n;return function(){var o=Nr(this,e),s=r(this),l=s+"";return s==null&&(l=s=(this.style.removeProperty(e),Nr(this,e))),o===l?null:o===i&&l===a?n:(a=l,n=t(i=o,s))}}function Ab(e,t){var r,i,a,n="style."+t,o="end."+n,s;return function(){var l=me(this,e),c=l.on,h=l.value[n]==null?s||(s=Oh(t)):void 0;(c!==r||a!==h)&&(i=(r=c).copy()).on(o,a=h),l.on=i}}function Mb(e,t,r){var i=(e+="")=="transform"?Fx:Fh;return t==null?this.styleTween(e,Tb(e,i)).on("end.style."+e,Oh(e)):typeof t=="function"?this.styleTween(e,Bb(e,i,fo(this,"style."+e,t))).each(Ab(this._id,e)):this.styleTween(e,Lb(e,i,t),r).on("end.style."+e,null)}function Eb(e,t,r){return function(i){this.style.setProperty(e,t.call(this,i),r)}}function $b(e,t,r){var i,a;function n(){var o=t.apply(this,arguments);return o!==a&&(i=(a=o)&&Eb(e,o,r)),i}return n._value=t,n}function Fb(e,t,r){var i="style."+(e+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(t==null)return this.tween(i,null);if(typeof t!="function")throw new Error;return this.tween(i,$b(e,t,r??""))}function Ob(e){return function(){this.textContent=e}}function Db(e){return function(){var t=e(this);this.textContent=t??""}}function Ib(e){return this.tween("text",typeof e=="function"?Db(fo(this,"text",e)):Ob(e==null?"":e+""))}function Rb(e){return function(t){this.textContent=e.call(this,t)}}function Pb(e){var t,r;function i(){var a=e.apply(this,arguments);return a!==r&&(t=(r=a)&&Rb(a)),t}return i._value=e,i}function Nb(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,Pb(e))}function Wb(){for(var e=this._name,t=this._id,r=Dh(),i=this._groups,a=i.length,n=0;n<a;++n)for(var o=i[n],s=o.length,l,c=0;c<s;++c)if(l=o[c]){var h=le(l,t);ln(l,e,r,c,o,{time:h.time+h.delay+h.duration,delay:0,duration:h.duration,ease:h.ease})}return new Ae(i,this._parents,e,r)}function zb(){var e,t,r=this,i=r._id,a=r.size();return new Promise(function(n,o){var s={value:o},l={value:function(){--a===0&&n()}};r.each(function(){var c=me(this,i),h=c.on;h!==e&&(t=(e=h).copy(),t._.cancel.push(s),t._.interrupt.push(s),t._.end.push(l)),c.on=t}),a===0&&n()})}var qb=0;function Ae(e,t,r,i){this._groups=e,this._parents=t,this._name=r,this._id=i}function Dh(){return++qb}var we=Ri.prototype;Ae.prototype={constructor:Ae,select:vb,selectAll:wb,selectChild:we.selectChild,selectChildren:we.selectChildren,filter:gb,merge:mb,selection:kb,transition:Wb,call:we.call,nodes:we.nodes,node:we.node,size:we.size,empty:we.empty,each:we.each,on:bb,attr:Jx,attrTween:ab,style:Mb,styleTween:Fb,text:Ib,textTween:Nb,remove:Cb,tween:Ux,delay:ob,duration:hb,ease:fb,easeVarying:pb,end:zb,[Symbol.iterator]:we[Symbol.iterator]};function Hb(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var jb={time:null,delay:0,duration:250,ease:Hb};function Yb(e,t){for(var r;!(r=e.__transition)||!(r=r[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return r}function Ub(e){var t,r;e instanceof Ae?(t=e._id,e=e._name):(t=Dh(),(r=jb).time=ho(),e=e==null?null:e+"");for(var i=this._groups,a=i.length,n=0;n<a;++n)for(var o=i[n],s=o.length,l,c=0;c<s;++c)(l=o[c])&&ln(l,e,t,c,o,r||Yb(l,t));return new Ae(i,this._parents,e,t)}Ri.prototype.interrupt=Hx;Ri.prototype.transition=Ub;const ys=Math.PI,xs=2*ys,Ve=1e-6,Gb=xs-Ve;function Ih(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function Vb(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return Ih;const r=10**t;return function(i){this._+=i[0];for(let a=1,n=i.length;a<n;++a)this._+=Math.round(arguments[a]*r)/r+i[a]}}class Xb{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?Ih:Vb(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,i,a){this._append`Q${+t},${+r},${this._x1=+i},${this._y1=+a}`}bezierCurveTo(t,r,i,a,n,o){this._append`C${+t},${+r},${+i},${+a},${this._x1=+n},${this._y1=+o}`}arcTo(t,r,i,a,n){if(t=+t,r=+r,i=+i,a=+a,n=+n,n<0)throw new Error(`negative radius: ${n}`);let o=this._x1,s=this._y1,l=i-t,c=a-r,h=o-t,u=s-r,f=h*h+u*u;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(f>Ve)if(!(Math.abs(u*l-c*h)>Ve)||!n)this._append`L${this._x1=t},${this._y1=r}`;else{let d=i-o,g=a-s,m=l*l+c*c,y=d*d+g*g,x=Math.sqrt(m),b=Math.sqrt(f),_=n*Math.tan((ys-Math.acos((m+f-y)/(2*x*b)))/2),w=_/b,v=_/x;Math.abs(w-1)>Ve&&this._append`L${t+w*h},${r+w*u}`,this._append`A${n},${n},0,0,${+(u*d>h*g)},${this._x1=t+v*l},${this._y1=r+v*c}`}}arc(t,r,i,a,n,o){if(t=+t,r=+r,i=+i,o=!!o,i<0)throw new Error(`negative radius: ${i}`);let s=i*Math.cos(a),l=i*Math.sin(a),c=t+s,h=r+l,u=1^o,f=o?a-n:n-a;this._x1===null?this._append`M${c},${h}`:(Math.abs(this._x1-c)>Ve||Math.abs(this._y1-h)>Ve)&&this._append`L${c},${h}`,i&&(f<0&&(f=f%xs+xs),f>Gb?this._append`A${i},${i},0,1,${u},${t-s},${r-l}A${i},${i},0,1,${u},${this._x1=c},${this._y1=h}`:f>Ve&&this._append`A${i},${i},0,${+(f>=ys)},${u},${this._x1=t+i*Math.cos(n)},${this._y1=r+i*Math.sin(n)}`)}rect(t,r,i,a){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${i=+i}v${+a}h${-i}Z`}toString(){return this._}}function _r(e){return function(){return e}}const vL=Math.abs,wL=Math.atan2,SL=Math.cos,kL=Math.max,TL=Math.min,LL=Math.sin,BL=Math.sqrt,zl=1e-12,po=Math.PI,ql=po/2,AL=2*po;function ML(e){return e>1?0:e<-1?po:Math.acos(e)}function EL(e){return e>=1?ql:e<=-1?-ql:Math.asin(e)}function Kb(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const i=Math.floor(r);if(!(i>=0))throw new RangeError(`invalid digits: ${r}`);t=i}return e},()=>new Xb(t)}function Zb(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Rh(e){this._context=e}Rh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Fa(e){return new Rh(e)}function Qb(e){return e[0]}function Jb(e){return e[1]}function t1(e,t){var r=_r(!0),i=null,a=Fa,n=null,o=Kb(s);e=typeof e=="function"?e:e===void 0?Qb:_r(e),t=typeof t=="function"?t:t===void 0?Jb:_r(t);function s(l){var c,h=(l=Zb(l)).length,u,f=!1,d;for(i==null&&(n=a(d=o())),c=0;c<=h;++c)!(c<h&&r(u=l[c],c,l))===f&&((f=!f)?n.lineStart():n.lineEnd()),f&&n.point(+e(u,c,l),+t(u,c,l));if(d)return n=null,d+""||null}return s.x=function(l){return arguments.length?(e=typeof l=="function"?l:_r(+l),s):e},s.y=function(l){return arguments.length?(t=typeof l=="function"?l:_r(+l),s):t},s.defined=function(l){return arguments.length?(r=typeof l=="function"?l:_r(!!l),s):r},s.curve=function(l){return arguments.length?(a=l,i!=null&&(n=a(i)),s):a},s.context=function(l){return arguments.length?(l==null?i=n=null:n=a(i=l),s):i},s}class Ph{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function Nh(e){return new Ph(e,!0)}function Wh(e){return new Ph(e,!1)}function Re(){}function Oa(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function cn(e){this._context=e}cn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Oa(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Oa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function pa(e){return new cn(e)}function zh(e){this._context=e}zh.prototype={areaStart:Re,areaEnd:Re,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Oa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function e1(e){return new zh(e)}function qh(e){this._context=e}qh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,i):this._context.moveTo(r,i);break;case 3:this._point=4;default:Oa(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function r1(e){return new qh(e)}function Hh(e,t){this._basis=new cn(e),this._beta=t}Hh.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,r=e.length-1;if(r>0)for(var i=e[0],a=t[0],n=e[r]-i,o=t[r]-a,s=-1,l;++s<=r;)l=s/r,this._basis.point(this._beta*e[s]+(1-this._beta)*(i+l*n),this._beta*t[s]+(1-this._beta)*(a+l*o));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const i1=(function e(t){function r(i){return t===1?new cn(i):new Hh(i,t)}return r.beta=function(i){return e(+i)},r})(.85);function Da(e,t,r){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-r),e._x2,e._y2)}function go(e,t){this._context=e,this._k=(1-t)/6}go.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Da(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:Da(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const jh=(function e(t){function r(i){return new go(i,t)}return r.tension=function(i){return e(+i)},r})(0);function mo(e,t){this._context=e,this._k=(1-t)/6}mo.prototype={areaStart:Re,areaEnd:Re,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:Da(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const a1=(function e(t){function r(i){return new mo(i,t)}return r.tension=function(i){return e(+i)},r})(0);function yo(e,t){this._context=e,this._k=(1-t)/6}yo.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Da(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const n1=(function e(t){function r(i){return new yo(i,t)}return r.tension=function(i){return e(+i)},r})(0);function xo(e,t,r){var i=e._x1,a=e._y1,n=e._x2,o=e._y2;if(e._l01_a>zl){var s=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*s-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,a=(a*s-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>zl){var c=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,h=3*e._l23_a*(e._l23_a+e._l12_a);n=(n*c+e._x1*e._l23_2a-t*e._l12_2a)/h,o=(o*c+e._y1*e._l23_2a-r*e._l12_2a)/h}e._context.bezierCurveTo(i,a,n,o,e._x2,e._y2)}function Yh(e,t){this._context=e,this._alpha=t}Yh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:xo(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const Uh=(function e(t){function r(i){return t?new Yh(i,t):new go(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Gh(e,t){this._context=e,this._alpha=t}Gh.prototype={areaStart:Re,areaEnd:Re,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:xo(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const s1=(function e(t){function r(i){return t?new Gh(i,t):new mo(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Vh(e,t){this._context=e,this._alpha=t}Vh.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var r=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:xo(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const o1=(function e(t){function r(i){return t?new Vh(i,t):new yo(i,0)}return r.alpha=function(i){return e(+i)},r})(.5);function Xh(e){this._context=e}Xh.prototype={areaStart:Re,areaEnd:Re,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function l1(e){return new Xh(e)}function Hl(e){return e<0?-1:1}function jl(e,t,r){var i=e._x1-e._x0,a=t-e._x1,n=(e._y1-e._y0)/(i||a<0&&-0),o=(r-e._y1)/(a||i<0&&-0),s=(n*a+o*i)/(i+a);return(Hl(n)+Hl(o))*Math.min(Math.abs(n),Math.abs(o),.5*Math.abs(s))||0}function Yl(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function jn(e,t,r){var i=e._x0,a=e._y0,n=e._x1,o=e._y1,s=(n-i)/3;e._context.bezierCurveTo(i+s,a+s*t,n-s,o-s*r,n,o)}function Ia(e){this._context=e}Ia.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:jn(this,this._t0,Yl(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,jn(this,Yl(this,r=jl(this,e,t)),r);break;default:jn(this,this._t0,r=jl(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function Kh(e){this._context=new Zh(e)}(Kh.prototype=Object.create(Ia.prototype)).point=function(e,t){Ia.prototype.point.call(this,t,e)};function Zh(e){this._context=e}Zh.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,i,a,n){this._context.bezierCurveTo(t,e,i,r,n,a)}};function Qh(e){return new Ia(e)}function Jh(e){return new Kh(e)}function tu(e){this._context=e}tu.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var i=Ul(e),a=Ul(t),n=0,o=1;o<r;++n,++o)this._context.bezierCurveTo(i[0][n],a[0][n],i[1][n],a[1][n],e[o],t[o]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function Ul(e){var t,r=e.length-1,i,a=new Array(r),n=new Array(r),o=new Array(r);for(a[0]=0,n[0]=2,o[0]=e[0]+2*e[1],t=1;t<r-1;++t)a[t]=1,n[t]=4,o[t]=4*e[t]+2*e[t+1];for(a[r-1]=2,n[r-1]=7,o[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)i=a[t]/n[t-1],n[t]-=i,o[t]-=i*o[t-1];for(a[r-1]=o[r-1]/n[r-1],t=r-2;t>=0;--t)a[t]=(o[t]-a[t+1])/n[t];for(n[r-1]=(e[r]+a[r-1])/2,t=0;t<r-1;++t)n[t]=2*e[t+1]-a[t+1];return[a,n]}function eu(e){return new tu(e)}function hn(e,t){this._context=e,this._t=t}hn.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function ru(e){return new hn(e,.5)}function iu(e){return new hn(e,0)}function au(e){return new hn(e,1)}function fi(e,t,r){this.k=e,this.x=t,this.y=r}fi.prototype={constructor:fi,scale:function(e){return e===1?this:new fi(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new fi(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};fi.prototype;var c1=p(e=>{const{securityLevel:t}=ut();let r=ht("body");if(t==="sandbox"){const n=ht(`#i${e}`).node()?.contentDocument??document;r=ht(n.body)}return r.select(`#${e}`)},"selectSvgElement");function bo(e){return typeof e>"u"||e===null}p(bo,"isNothing");function nu(e){return typeof e=="object"&&e!==null}p(nu,"isObject");function su(e){return Array.isArray(e)?e:bo(e)?[]:[e]}p(su,"toArray");function ou(e,t){var r,i,a,n;if(t)for(n=Object.keys(t),r=0,i=n.length;r<i;r+=1)a=n[r],e[a]=t[a];return e}p(ou,"extend");function lu(e,t){var r="",i;for(i=0;i<t;i+=1)r+=e;return r}p(lu,"repeat");function cu(e){return e===0&&Number.NEGATIVE_INFINITY===1/e}p(cu,"isNegativeZero");var h1=bo,u1=nu,f1=su,d1=lu,p1=cu,g1=ou,St={isNothing:h1,isObject:u1,toArray:f1,repeat:d1,isNegativeZero:p1,extend:g1};function _o(e,t){var r="",i=e.reason||"(unknown reason)";return e.mark?(e.mark.name&&(r+='in "'+e.mark.name+'" '),r+="("+(e.mark.line+1)+":"+(e.mark.column+1)+")",!t&&e.mark.snippet&&(r+=`
|
|
82
|
+
|
|
83
|
+
`+e.mark.snippet),i+" "+r):i}p(_o,"formatError");function zr(e,t){Error.call(this),this.name="YAMLException",this.reason=e,this.mark=t,this.message=_o(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}p(zr,"YAMLException$1");zr.prototype=Object.create(Error.prototype);zr.prototype.constructor=zr;zr.prototype.toString=p(function(t){return this.name+": "+_o(this,t)},"toString");var Yt=zr;function ga(e,t,r,i,a){var n="",o="",s=Math.floor(a/2)-1;return i-t>s&&(n=" ... ",t=i-s+n.length),r-i>s&&(o=" ...",r=i+s-o.length),{str:n+e.slice(t,r).replace(/\t/g,"→")+o,pos:i-t+n.length}}p(ga,"getLine");function ma(e,t){return St.repeat(" ",t-e.length)+e}p(ma,"padStart");function hu(e,t){if(t=Object.create(t||null),!e.buffer)return null;t.maxLength||(t.maxLength=79),typeof t.indent!="number"&&(t.indent=1),typeof t.linesBefore!="number"&&(t.linesBefore=3),typeof t.linesAfter!="number"&&(t.linesAfter=2);for(var r=/\r?\n|\r|\0/g,i=[0],a=[],n,o=-1;n=r.exec(e.buffer);)a.push(n.index),i.push(n.index+n[0].length),e.position<=n.index&&o<0&&(o=i.length-2);o<0&&(o=i.length-1);var s="",l,c,h=Math.min(e.line+t.linesAfter,a.length).toString().length,u=t.maxLength-(t.indent+h+3);for(l=1;l<=t.linesBefore&&!(o-l<0);l++)c=ga(e.buffer,i[o-l],a[o-l],e.position-(i[o]-i[o-l]),u),s=St.repeat(" ",t.indent)+ma((e.line-l+1).toString(),h)+" | "+c.str+`
|
|
84
|
+
`+s;for(c=ga(e.buffer,i[o],a[o],e.position,u),s+=St.repeat(" ",t.indent)+ma((e.line+1).toString(),h)+" | "+c.str+`
|
|
85
|
+
`,s+=St.repeat("-",t.indent+h+3+c.pos)+`^
|
|
86
|
+
`,l=1;l<=t.linesAfter&&!(o+l>=a.length);l++)c=ga(e.buffer,i[o+l],a[o+l],e.position-(i[o]-i[o+l]),u),s+=St.repeat(" ",t.indent)+ma((e.line+l+1).toString(),h)+" | "+c.str+`
|
|
87
|
+
`;return s.replace(/\n$/,"")}p(hu,"makeSnippet");var m1=hu,y1=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],x1=["scalar","sequence","mapping"];function uu(e){var t={};return e!==null&&Object.keys(e).forEach(function(r){e[r].forEach(function(i){t[String(i)]=r})}),t}p(uu,"compileStyleAliases");function fu(e,t){if(t=t||{},Object.keys(t).forEach(function(r){if(y1.indexOf(r)===-1)throw new Yt('Unknown option "'+r+'" is met in definition of "'+e+'" YAML type.')}),this.options=t,this.tag=e,this.kind=t.kind||null,this.resolve=t.resolve||function(){return!0},this.construct=t.construct||function(r){return r},this.instanceOf=t.instanceOf||null,this.predicate=t.predicate||null,this.represent=t.represent||null,this.representName=t.representName||null,this.defaultStyle=t.defaultStyle||null,this.multi=t.multi||!1,this.styleAliases=uu(t.styleAliases||null),x1.indexOf(this.kind)===-1)throw new Yt('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}p(fu,"Type$1");var Ot=fu;function bs(e,t){var r=[];return e[t].forEach(function(i){var a=r.length;r.forEach(function(n,o){n.tag===i.tag&&n.kind===i.kind&&n.multi===i.multi&&(a=o)}),r[a]=i}),r}p(bs,"compileList");function du(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},t,r;function i(a){a.multi?(e.multi[a.kind].push(a),e.multi.fallback.push(a)):e[a.kind][a.tag]=e.fallback[a.tag]=a}for(p(i,"collectType"),t=0,r=arguments.length;t<r;t+=1)arguments[t].forEach(i);return e}p(du,"compileMap");function Ra(e){return this.extend(e)}p(Ra,"Schema$1");Ra.prototype.extend=p(function(t){var r=[],i=[];if(t instanceof Ot)i.push(t);else if(Array.isArray(t))i=i.concat(t);else if(t&&(Array.isArray(t.implicit)||Array.isArray(t.explicit)))t.implicit&&(r=r.concat(t.implicit)),t.explicit&&(i=i.concat(t.explicit));else throw new Yt("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");r.forEach(function(n){if(!(n instanceof Ot))throw new Yt("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(n.loadKind&&n.loadKind!=="scalar")throw new Yt("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(n.multi)throw new Yt("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),i.forEach(function(n){if(!(n instanceof Ot))throw new Yt("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var a=Object.create(Ra.prototype);return a.implicit=(this.implicit||[]).concat(r),a.explicit=(this.explicit||[]).concat(i),a.compiledImplicit=bs(a,"implicit"),a.compiledExplicit=bs(a,"explicit"),a.compiledTypeMap=du(a.compiledImplicit,a.compiledExplicit),a},"extend");var b1=Ra,_1=new Ot("tag:yaml.org,2002:str",{kind:"scalar",construct:p(function(e){return e!==null?e:""},"construct")}),C1=new Ot("tag:yaml.org,2002:seq",{kind:"sequence",construct:p(function(e){return e!==null?e:[]},"construct")}),v1=new Ot("tag:yaml.org,2002:map",{kind:"mapping",construct:p(function(e){return e!==null?e:{}},"construct")}),w1=new b1({explicit:[_1,C1,v1]});function pu(e){if(e===null)return!0;var t=e.length;return t===1&&e==="~"||t===4&&(e==="null"||e==="Null"||e==="NULL")}p(pu,"resolveYamlNull");function gu(){return null}p(gu,"constructYamlNull");function mu(e){return e===null}p(mu,"isNull");var S1=new Ot("tag:yaml.org,2002:null",{kind:"scalar",resolve:pu,construct:gu,predicate:mu,represent:{canonical:p(function(){return"~"},"canonical"),lowercase:p(function(){return"null"},"lowercase"),uppercase:p(function(){return"NULL"},"uppercase"),camelcase:p(function(){return"Null"},"camelcase"),empty:p(function(){return""},"empty")},defaultStyle:"lowercase"});function yu(e){if(e===null)return!1;var t=e.length;return t===4&&(e==="true"||e==="True"||e==="TRUE")||t===5&&(e==="false"||e==="False"||e==="FALSE")}p(yu,"resolveYamlBoolean");function xu(e){return e==="true"||e==="True"||e==="TRUE"}p(xu,"constructYamlBoolean");function bu(e){return Object.prototype.toString.call(e)==="[object Boolean]"}p(bu,"isBoolean");var k1=new Ot("tag:yaml.org,2002:bool",{kind:"scalar",resolve:yu,construct:xu,predicate:bu,represent:{lowercase:p(function(e){return e?"true":"false"},"lowercase"),uppercase:p(function(e){return e?"TRUE":"FALSE"},"uppercase"),camelcase:p(function(e){return e?"True":"False"},"camelcase")},defaultStyle:"lowercase"});function _u(e){return 48<=e&&e<=57||65<=e&&e<=70||97<=e&&e<=102}p(_u,"isHexCode");function Cu(e){return 48<=e&&e<=55}p(Cu,"isOctCode");function vu(e){return 48<=e&&e<=57}p(vu,"isDecCode");function wu(e){if(e===null)return!1;var t=e.length,r=0,i=!1,a;if(!t)return!1;if(a=e[r],(a==="-"||a==="+")&&(a=e[++r]),a==="0"){if(r+1===t)return!0;if(a=e[++r],a==="b"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(a!=="0"&&a!=="1")return!1;i=!0}return i&&a!=="_"}if(a==="x"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(!_u(e.charCodeAt(r)))return!1;i=!0}return i&&a!=="_"}if(a==="o"){for(r++;r<t;r++)if(a=e[r],a!=="_"){if(!Cu(e.charCodeAt(r)))return!1;i=!0}return i&&a!=="_"}}if(a==="_")return!1;for(;r<t;r++)if(a=e[r],a!=="_"){if(!vu(e.charCodeAt(r)))return!1;i=!0}return!(!i||a==="_")}p(wu,"resolveYamlInteger");function Su(e){var t=e,r=1,i;if(t.indexOf("_")!==-1&&(t=t.replace(/_/g,"")),i=t[0],(i==="-"||i==="+")&&(i==="-"&&(r=-1),t=t.slice(1),i=t[0]),t==="0")return 0;if(i==="0"){if(t[1]==="b")return r*parseInt(t.slice(2),2);if(t[1]==="x")return r*parseInt(t.slice(2),16);if(t[1]==="o")return r*parseInt(t.slice(2),8)}return r*parseInt(t,10)}p(Su,"constructYamlInteger");function ku(e){return Object.prototype.toString.call(e)==="[object Number]"&&e%1===0&&!St.isNegativeZero(e)}p(ku,"isInteger");var T1=new Ot("tag:yaml.org,2002:int",{kind:"scalar",resolve:wu,construct:Su,predicate:ku,represent:{binary:p(function(e){return e>=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},"binary"),octal:p(function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},"octal"),decimal:p(function(e){return e.toString(10)},"decimal"),hexadecimal:p(function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),L1=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Tu(e){return!(e===null||!L1.test(e)||e[e.length-1]==="_")}p(Tu,"resolveYamlFloat");function Lu(e){var t,r;return t=e.replace(/_/g,"").toLowerCase(),r=t[0]==="-"?-1:1,"+-".indexOf(t[0])>=0&&(t=t.slice(1)),t===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:t===".nan"?NaN:r*parseFloat(t,10)}p(Lu,"constructYamlFloat");var B1=/^[-+]?[0-9]+e/;function Bu(e,t){var r;if(isNaN(e))switch(t){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(t){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(t){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(St.isNegativeZero(e))return"-0.0";return r=e.toString(10),B1.test(r)?r.replace("e",".e"):r}p(Bu,"representYamlFloat");function Au(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||St.isNegativeZero(e))}p(Au,"isFloat");var A1=new Ot("tag:yaml.org,2002:float",{kind:"scalar",resolve:Tu,construct:Lu,predicate:Au,represent:Bu,defaultStyle:"lowercase"}),Mu=w1.extend({implicit:[S1,k1,T1,A1]}),M1=Mu,Eu=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),$u=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function Fu(e){return e===null?!1:Eu.exec(e)!==null||$u.exec(e)!==null}p(Fu,"resolveYamlTimestamp");function Ou(e){var t,r,i,a,n,o,s,l=0,c=null,h,u,f;if(t=Eu.exec(e),t===null&&(t=$u.exec(e)),t===null)throw new Error("Date resolve error");if(r=+t[1],i=+t[2]-1,a=+t[3],!t[4])return new Date(Date.UTC(r,i,a));if(n=+t[4],o=+t[5],s=+t[6],t[7]){for(l=t[7].slice(0,3);l.length<3;)l+="0";l=+l}return t[9]&&(h=+t[10],u=+(t[11]||0),c=(h*60+u)*6e4,t[9]==="-"&&(c=-c)),f=new Date(Date.UTC(r,i,a,n,o,s,l)),c&&f.setTime(f.getTime()-c),f}p(Ou,"constructYamlTimestamp");function Du(e){return e.toISOString()}p(Du,"representYamlTimestamp");var E1=new Ot("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:Fu,construct:Ou,instanceOf:Date,represent:Du});function Iu(e){return e==="<<"||e===null}p(Iu,"resolveYamlMerge");var $1=new Ot("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Iu}),Co=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
|
|
88
|
+
\r`;function Ru(e){if(e===null)return!1;var t,r,i=0,a=e.length,n=Co;for(r=0;r<a;r++)if(t=n.indexOf(e.charAt(r)),!(t>64)){if(t<0)return!1;i+=6}return i%8===0}p(Ru,"resolveYamlBinary");function Pu(e){var t,r,i=e.replace(/[\r\n=]/g,""),a=i.length,n=Co,o=0,s=[];for(t=0;t<a;t++)t%4===0&&t&&(s.push(o>>16&255),s.push(o>>8&255),s.push(o&255)),o=o<<6|n.indexOf(i.charAt(t));return r=a%4*6,r===0?(s.push(o>>16&255),s.push(o>>8&255),s.push(o&255)):r===18?(s.push(o>>10&255),s.push(o>>2&255)):r===12&&s.push(o>>4&255),new Uint8Array(s)}p(Pu,"constructYamlBinary");function Nu(e){var t="",r=0,i,a,n=e.length,o=Co;for(i=0;i<n;i++)i%3===0&&i&&(t+=o[r>>18&63],t+=o[r>>12&63],t+=o[r>>6&63],t+=o[r&63]),r=(r<<8)+e[i];return a=n%3,a===0?(t+=o[r>>18&63],t+=o[r>>12&63],t+=o[r>>6&63],t+=o[r&63]):a===2?(t+=o[r>>10&63],t+=o[r>>4&63],t+=o[r<<2&63],t+=o[64]):a===1&&(t+=o[r>>2&63],t+=o[r<<4&63],t+=o[64],t+=o[64]),t}p(Nu,"representYamlBinary");function Wu(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}p(Wu,"isBinary");var F1=new Ot("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Ru,construct:Pu,predicate:Wu,represent:Nu}),O1=Object.prototype.hasOwnProperty,D1=Object.prototype.toString;function zu(e){if(e===null)return!0;var t=[],r,i,a,n,o,s=e;for(r=0,i=s.length;r<i;r+=1){if(a=s[r],o=!1,D1.call(a)!=="[object Object]")return!1;for(n in a)if(O1.call(a,n))if(!o)o=!0;else return!1;if(!o)return!1;if(t.indexOf(n)===-1)t.push(n);else return!1}return!0}p(zu,"resolveYamlOmap");function qu(e){return e!==null?e:[]}p(qu,"constructYamlOmap");var I1=new Ot("tag:yaml.org,2002:omap",{kind:"sequence",resolve:zu,construct:qu}),R1=Object.prototype.toString;function Hu(e){if(e===null)return!0;var t,r,i,a,n,o=e;for(n=new Array(o.length),t=0,r=o.length;t<r;t+=1){if(i=o[t],R1.call(i)!=="[object Object]"||(a=Object.keys(i),a.length!==1))return!1;n[t]=[a[0],i[a[0]]]}return!0}p(Hu,"resolveYamlPairs");function ju(e){if(e===null)return[];var t,r,i,a,n,o=e;for(n=new Array(o.length),t=0,r=o.length;t<r;t+=1)i=o[t],a=Object.keys(i),n[t]=[a[0],i[a[0]]];return n}p(ju,"constructYamlPairs");var P1=new Ot("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:Hu,construct:ju}),N1=Object.prototype.hasOwnProperty;function Yu(e){if(e===null)return!0;var t,r=e;for(t in r)if(N1.call(r,t)&&r[t]!==null)return!1;return!0}p(Yu,"resolveYamlSet");function Uu(e){return e!==null?e:{}}p(Uu,"constructYamlSet");var W1=new Ot("tag:yaml.org,2002:set",{kind:"mapping",resolve:Yu,construct:Uu}),Gu=M1.extend({implicit:[E1,$1],explicit:[F1,I1,P1,W1]}),Pe=Object.prototype.hasOwnProperty,Pa=1,Vu=2,Xu=3,Na=4,Yn=1,z1=2,Gl=3,q1=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,H1=/[\x85\u2028\u2029]/,j1=/[,\[\]\{\}]/,Ku=/^(?:!|!!|![a-z\-]+!)$/i,Zu=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function _s(e){return Object.prototype.toString.call(e)}p(_s,"_class");function se(e){return e===10||e===13}p(se,"is_EOL");function Ie(e){return e===9||e===32}p(Ie,"is_WHITE_SPACE");function Nt(e){return e===9||e===32||e===10||e===13}p(Nt,"is_WS_OR_EOL");function Je(e){return e===44||e===91||e===93||e===123||e===125}p(Je,"is_FLOW_INDICATOR");function Qu(e){var t;return 48<=e&&e<=57?e-48:(t=e|32,97<=t&&t<=102?t-97+10:-1)}p(Qu,"fromHexCode");function Ju(e){return e===120?2:e===117?4:e===85?8:0}p(Ju,"escapedHexLen");function tf(e){return 48<=e&&e<=57?e-48:-1}p(tf,"fromDecimalCode");function Cs(e){return e===48?"\0":e===97?"\x07":e===98?"\b":e===116||e===9?" ":e===110?`
|
|
89
|
+
`:e===118?"\v":e===102?"\f":e===114?"\r":e===101?"\x1B":e===32?" ":e===34?'"':e===47?"/":e===92?"\\":e===78?"
":e===95?" ":e===76?"\u2028":e===80?"\u2029":""}p(Cs,"simpleEscapeSequence");function ef(e){return e<=65535?String.fromCharCode(e):String.fromCharCode((e-65536>>10)+55296,(e-65536&1023)+56320)}p(ef,"charFromCodepoint");var rf=new Array(256),af=new Array(256);for(Ge=0;Ge<256;Ge++)rf[Ge]=Cs(Ge)?1:0,af[Ge]=Cs(Ge);var Ge;function nf(e,t){this.input=e,this.filename=t.filename||null,this.schema=t.schema||Gu,this.onWarning=t.onWarning||null,this.legacy=t.legacy||!1,this.json=t.json||!1,this.listener=t.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}p(nf,"State$1");function vo(e,t){var r={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return r.snippet=m1(r),new Yt(t,r)}p(vo,"generateError");function Q(e,t){throw vo(e,t)}p(Q,"throwError");function Ti(e,t){e.onWarning&&e.onWarning.call(null,vo(e,t))}p(Ti,"throwWarning");var Vl={YAML:p(function(t,r,i){var a,n,o;t.version!==null&&Q(t,"duplication of %YAML directive"),i.length!==1&&Q(t,"YAML directive accepts exactly one argument"),a=/^([0-9]+)\.([0-9]+)$/.exec(i[0]),a===null&&Q(t,"ill-formed argument of the YAML directive"),n=parseInt(a[1],10),o=parseInt(a[2],10),n!==1&&Q(t,"unacceptable YAML version of the document"),t.version=i[0],t.checkLineBreaks=o<2,o!==1&&o!==2&&Ti(t,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:p(function(t,r,i){var a,n;i.length!==2&&Q(t,"TAG directive accepts exactly two arguments"),a=i[0],n=i[1],Ku.test(a)||Q(t,"ill-formed tag handle (first argument) of the TAG directive"),Pe.call(t.tagMap,a)&&Q(t,'there is a previously declared suffix for "'+a+'" tag handle'),Zu.test(n)||Q(t,"ill-formed tag prefix (second argument) of the TAG directive");try{n=decodeURIComponent(n)}catch{Q(t,"tag prefix is malformed: "+n)}t.tagMap[a]=n},"handleTagDirective")};function Be(e,t,r,i){var a,n,o,s;if(t<r){if(s=e.input.slice(t,r),i)for(a=0,n=s.length;a<n;a+=1)o=s.charCodeAt(a),o===9||32<=o&&o<=1114111||Q(e,"expected valid JSON character");else q1.test(s)&&Q(e,"the stream contains non-printable characters");e.result+=s}}p(Be,"captureSegment");function vs(e,t,r,i){var a,n,o,s;for(St.isObject(r)||Q(e,"cannot merge mappings; the provided source object is unacceptable"),a=Object.keys(r),o=0,s=a.length;o<s;o+=1)n=a[o],Pe.call(t,n)||(t[n]=r[n],i[n]=!0)}p(vs,"mergeMappings");function tr(e,t,r,i,a,n,o,s,l){var c,h;if(Array.isArray(a))for(a=Array.prototype.slice.call(a),c=0,h=a.length;c<h;c+=1)Array.isArray(a[c])&&Q(e,"nested arrays are not supported inside keys"),typeof a=="object"&&_s(a[c])==="[object Object]"&&(a[c]="[object Object]");if(typeof a=="object"&&_s(a)==="[object Object]"&&(a="[object Object]"),a=String(a),t===null&&(t={}),i==="tag:yaml.org,2002:merge")if(Array.isArray(n))for(c=0,h=n.length;c<h;c+=1)vs(e,t,n[c],r);else vs(e,t,n,r);else!e.json&&!Pe.call(r,a)&&Pe.call(t,a)&&(e.line=o||e.line,e.lineStart=s||e.lineStart,e.position=l||e.position,Q(e,"duplicated mapping key")),a==="__proto__"?Object.defineProperty(t,a,{configurable:!0,enumerable:!0,writable:!0,value:n}):t[a]=n,delete r[a];return t}p(tr,"storeMappingPair");function un(e){var t;t=e.input.charCodeAt(e.position),t===10?e.position++:t===13?(e.position++,e.input.charCodeAt(e.position)===10&&e.position++):Q(e,"a line break is expected"),e.line+=1,e.lineStart=e.position,e.firstTabInLine=-1}p(un,"readLineBreak");function yt(e,t,r){for(var i=0,a=e.input.charCodeAt(e.position);a!==0;){for(;Ie(a);)a===9&&e.firstTabInLine===-1&&(e.firstTabInLine=e.position),a=e.input.charCodeAt(++e.position);if(t&&a===35)do a=e.input.charCodeAt(++e.position);while(a!==10&&a!==13&&a!==0);if(se(a))for(un(e),a=e.input.charCodeAt(e.position),i++,e.lineIndent=0;a===32;)e.lineIndent++,a=e.input.charCodeAt(++e.position);else break}return r!==-1&&i!==0&&e.lineIndent<r&&Ti(e,"deficient indentation"),i}p(yt,"skipSeparationSpace");function Ni(e){var t=e.position,r;return r=e.input.charCodeAt(t),!!((r===45||r===46)&&r===e.input.charCodeAt(t+1)&&r===e.input.charCodeAt(t+2)&&(t+=3,r=e.input.charCodeAt(t),r===0||Nt(r)))}p(Ni,"testDocumentSeparator");function fn(e,t){t===1?e.result+=" ":t>1&&(e.result+=St.repeat(`
|
|
90
|
+
`,t-1))}p(fn,"writeFoldedLines");function sf(e,t,r){var i,a,n,o,s,l,c,h,u=e.kind,f=e.result,d;if(d=e.input.charCodeAt(e.position),Nt(d)||Je(d)||d===35||d===38||d===42||d===33||d===124||d===62||d===39||d===34||d===37||d===64||d===96||(d===63||d===45)&&(a=e.input.charCodeAt(e.position+1),Nt(a)||r&&Je(a)))return!1;for(e.kind="scalar",e.result="",n=o=e.position,s=!1;d!==0;){if(d===58){if(a=e.input.charCodeAt(e.position+1),Nt(a)||r&&Je(a))break}else if(d===35){if(i=e.input.charCodeAt(e.position-1),Nt(i))break}else{if(e.position===e.lineStart&&Ni(e)||r&&Je(d))break;if(se(d))if(l=e.line,c=e.lineStart,h=e.lineIndent,yt(e,!1,-1),e.lineIndent>=t){s=!0,d=e.input.charCodeAt(e.position);continue}else{e.position=o,e.line=l,e.lineStart=c,e.lineIndent=h;break}}s&&(Be(e,n,o,!1),fn(e,e.line-l),n=o=e.position,s=!1),Ie(d)||(o=e.position+1),d=e.input.charCodeAt(++e.position)}return Be(e,n,o,!1),e.result?!0:(e.kind=u,e.result=f,!1)}p(sf,"readPlainScalar");function of(e,t){var r,i,a;if(r=e.input.charCodeAt(e.position),r!==39)return!1;for(e.kind="scalar",e.result="",e.position++,i=a=e.position;(r=e.input.charCodeAt(e.position))!==0;)if(r===39)if(Be(e,i,e.position,!0),r=e.input.charCodeAt(++e.position),r===39)i=e.position,e.position++,a=e.position;else return!0;else se(r)?(Be(e,i,a,!0),fn(e,yt(e,!1,t)),i=a=e.position):e.position===e.lineStart&&Ni(e)?Q(e,"unexpected end of the document within a single quoted scalar"):(e.position++,a=e.position);Q(e,"unexpected end of the stream within a single quoted scalar")}p(of,"readSingleQuotedScalar");function lf(e,t){var r,i,a,n,o,s;if(s=e.input.charCodeAt(e.position),s!==34)return!1;for(e.kind="scalar",e.result="",e.position++,r=i=e.position;(s=e.input.charCodeAt(e.position))!==0;){if(s===34)return Be(e,r,e.position,!0),e.position++,!0;if(s===92){if(Be(e,r,e.position,!0),s=e.input.charCodeAt(++e.position),se(s))yt(e,!1,t);else if(s<256&&rf[s])e.result+=af[s],e.position++;else if((o=Ju(s))>0){for(a=o,n=0;a>0;a--)s=e.input.charCodeAt(++e.position),(o=Qu(s))>=0?n=(n<<4)+o:Q(e,"expected hexadecimal character");e.result+=ef(n),e.position++}else Q(e,"unknown escape sequence");r=i=e.position}else se(s)?(Be(e,r,i,!0),fn(e,yt(e,!1,t)),r=i=e.position):e.position===e.lineStart&&Ni(e)?Q(e,"unexpected end of the document within a double quoted scalar"):(e.position++,i=e.position)}Q(e,"unexpected end of the stream within a double quoted scalar")}p(lf,"readDoubleQuotedScalar");function cf(e,t){var r=!0,i,a,n,o=e.tag,s,l=e.anchor,c,h,u,f,d,g=Object.create(null),m,y,x,b;if(b=e.input.charCodeAt(e.position),b===91)h=93,d=!1,s=[];else if(b===123)h=125,d=!0,s={};else return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=s),b=e.input.charCodeAt(++e.position);b!==0;){if(yt(e,!0,t),b=e.input.charCodeAt(e.position),b===h)return e.position++,e.tag=o,e.anchor=l,e.kind=d?"mapping":"sequence",e.result=s,!0;r?b===44&&Q(e,"expected the node content, but found ','"):Q(e,"missed comma between flow collection entries"),y=m=x=null,u=f=!1,b===63&&(c=e.input.charCodeAt(e.position+1),Nt(c)&&(u=f=!0,e.position++,yt(e,!0,t))),i=e.line,a=e.lineStart,n=e.position,or(e,t,Pa,!1,!0),y=e.tag,m=e.result,yt(e,!0,t),b=e.input.charCodeAt(e.position),(f||e.line===i)&&b===58&&(u=!0,b=e.input.charCodeAt(++e.position),yt(e,!0,t),or(e,t,Pa,!1,!0),x=e.result),d?tr(e,s,g,y,m,x,i,a,n):u?s.push(tr(e,null,g,y,m,x,i,a,n)):s.push(m),yt(e,!0,t),b=e.input.charCodeAt(e.position),b===44?(r=!0,b=e.input.charCodeAt(++e.position)):r=!1}Q(e,"unexpected end of the stream within a flow collection")}p(cf,"readFlowCollection");function hf(e,t){var r,i,a=Yn,n=!1,o=!1,s=t,l=0,c=!1,h,u;if(u=e.input.charCodeAt(e.position),u===124)i=!1;else if(u===62)i=!0;else return!1;for(e.kind="scalar",e.result="";u!==0;)if(u=e.input.charCodeAt(++e.position),u===43||u===45)Yn===a?a=u===43?Gl:z1:Q(e,"repeat of a chomping mode identifier");else if((h=tf(u))>=0)h===0?Q(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?Q(e,"repeat of an indentation width identifier"):(s=t+h-1,o=!0);else break;if(Ie(u)){do u=e.input.charCodeAt(++e.position);while(Ie(u));if(u===35)do u=e.input.charCodeAt(++e.position);while(!se(u)&&u!==0)}for(;u!==0;){for(un(e),e.lineIndent=0,u=e.input.charCodeAt(e.position);(!o||e.lineIndent<s)&&u===32;)e.lineIndent++,u=e.input.charCodeAt(++e.position);if(!o&&e.lineIndent>s&&(s=e.lineIndent),se(u)){l++;continue}if(e.lineIndent<s){a===Gl?e.result+=St.repeat(`
|
|
91
|
+
`,n?1+l:l):a===Yn&&n&&(e.result+=`
|
|
92
|
+
`);break}for(i?Ie(u)?(c=!0,e.result+=St.repeat(`
|
|
93
|
+
`,n?1+l:l)):c?(c=!1,e.result+=St.repeat(`
|
|
94
|
+
`,l+1)):l===0?n&&(e.result+=" "):e.result+=St.repeat(`
|
|
95
|
+
`,l):e.result+=St.repeat(`
|
|
96
|
+
`,n?1+l:l),n=!0,o=!0,l=0,r=e.position;!se(u)&&u!==0;)u=e.input.charCodeAt(++e.position);Be(e,r,e.position,!1)}return!0}p(hf,"readBlockScalar");function ws(e,t){var r,i=e.tag,a=e.anchor,n=[],o,s=!1,l;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=n),l=e.input.charCodeAt(e.position);l!==0&&(e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,Q(e,"tab characters must not be used in indentation")),!(l!==45||(o=e.input.charCodeAt(e.position+1),!Nt(o))));){if(s=!0,e.position++,yt(e,!0,-1)&&e.lineIndent<=t){n.push(null),l=e.input.charCodeAt(e.position);continue}if(r=e.line,or(e,t,Xu,!1,!0),n.push(e.result),yt(e,!0,-1),l=e.input.charCodeAt(e.position),(e.line===r||e.lineIndent>t)&&l!==0)Q(e,"bad indentation of a sequence entry");else if(e.lineIndent<t)break}return s?(e.tag=i,e.anchor=a,e.kind="sequence",e.result=n,!0):!1}p(ws,"readBlockSequence");function uf(e,t,r){var i,a,n,o,s,l,c=e.tag,h=e.anchor,u={},f=Object.create(null),d=null,g=null,m=null,y=!1,x=!1,b;if(e.firstTabInLine!==-1)return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=u),b=e.input.charCodeAt(e.position);b!==0;){if(!y&&e.firstTabInLine!==-1&&(e.position=e.firstTabInLine,Q(e,"tab characters must not be used in indentation")),i=e.input.charCodeAt(e.position+1),n=e.line,(b===63||b===58)&&Nt(i))b===63?(y&&(tr(e,u,f,d,g,null,o,s,l),d=g=m=null),x=!0,y=!0,a=!0):y?(y=!1,a=!0):Q(e,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),e.position+=1,b=i;else{if(o=e.line,s=e.lineStart,l=e.position,!or(e,r,Vu,!1,!0))break;if(e.line===n){for(b=e.input.charCodeAt(e.position);Ie(b);)b=e.input.charCodeAt(++e.position);if(b===58)b=e.input.charCodeAt(++e.position),Nt(b)||Q(e,"a whitespace character is expected after the key-value separator within a block mapping"),y&&(tr(e,u,f,d,g,null,o,s,l),d=g=m=null),x=!0,y=!1,a=!1,d=e.tag,g=e.result;else if(x)Q(e,"can not read an implicit mapping pair; a colon is missed");else return e.tag=c,e.anchor=h,!0}else if(x)Q(e,"can not read a block mapping entry; a multiline key may not be an implicit key");else return e.tag=c,e.anchor=h,!0}if((e.line===n||e.lineIndent>t)&&(y&&(o=e.line,s=e.lineStart,l=e.position),or(e,t,Na,!0,a)&&(y?g=e.result:m=e.result),y||(tr(e,u,f,d,g,m,o,s,l),d=g=m=null),yt(e,!0,-1),b=e.input.charCodeAt(e.position)),(e.line===n||e.lineIndent>t)&&b!==0)Q(e,"bad indentation of a mapping entry");else if(e.lineIndent<t)break}return y&&tr(e,u,f,d,g,null,o,s,l),x&&(e.tag=c,e.anchor=h,e.kind="mapping",e.result=u),x}p(uf,"readBlockMapping");function ff(e){var t,r=!1,i=!1,a,n,o;if(o=e.input.charCodeAt(e.position),o!==33)return!1;if(e.tag!==null&&Q(e,"duplication of a tag property"),o=e.input.charCodeAt(++e.position),o===60?(r=!0,o=e.input.charCodeAt(++e.position)):o===33?(i=!0,a="!!",o=e.input.charCodeAt(++e.position)):a="!",t=e.position,r){do o=e.input.charCodeAt(++e.position);while(o!==0&&o!==62);e.position<e.length?(n=e.input.slice(t,e.position),o=e.input.charCodeAt(++e.position)):Q(e,"unexpected end of the stream within a verbatim tag")}else{for(;o!==0&&!Nt(o);)o===33&&(i?Q(e,"tag suffix cannot contain exclamation marks"):(a=e.input.slice(t-1,e.position+1),Ku.test(a)||Q(e,"named tag handle cannot contain such characters"),i=!0,t=e.position+1)),o=e.input.charCodeAt(++e.position);n=e.input.slice(t,e.position),j1.test(n)&&Q(e,"tag suffix cannot contain flow indicator characters")}n&&!Zu.test(n)&&Q(e,"tag name cannot contain such characters: "+n);try{n=decodeURIComponent(n)}catch{Q(e,"tag name is malformed: "+n)}return r?e.tag=n:Pe.call(e.tagMap,a)?e.tag=e.tagMap[a]+n:a==="!"?e.tag="!"+n:a==="!!"?e.tag="tag:yaml.org,2002:"+n:Q(e,'undeclared tag handle "'+a+'"'),!0}p(ff,"readTagProperty");function df(e){var t,r;if(r=e.input.charCodeAt(e.position),r!==38)return!1;for(e.anchor!==null&&Q(e,"duplication of an anchor property"),r=e.input.charCodeAt(++e.position),t=e.position;r!==0&&!Nt(r)&&!Je(r);)r=e.input.charCodeAt(++e.position);return e.position===t&&Q(e,"name of an anchor node must contain at least one character"),e.anchor=e.input.slice(t,e.position),!0}p(df,"readAnchorProperty");function pf(e){var t,r,i;if(i=e.input.charCodeAt(e.position),i!==42)return!1;for(i=e.input.charCodeAt(++e.position),t=e.position;i!==0&&!Nt(i)&&!Je(i);)i=e.input.charCodeAt(++e.position);return e.position===t&&Q(e,"name of an alias node must contain at least one character"),r=e.input.slice(t,e.position),Pe.call(e.anchorMap,r)||Q(e,'unidentified alias "'+r+'"'),e.result=e.anchorMap[r],yt(e,!0,-1),!0}p(pf,"readAlias");function or(e,t,r,i,a){var n,o,s,l=1,c=!1,h=!1,u,f,d,g,m,y;if(e.listener!==null&&e.listener("open",e),e.tag=null,e.anchor=null,e.kind=null,e.result=null,n=o=s=Na===r||Xu===r,i&&yt(e,!0,-1)&&(c=!0,e.lineIndent>t?l=1:e.lineIndent===t?l=0:e.lineIndent<t&&(l=-1)),l===1)for(;ff(e)||df(e);)yt(e,!0,-1)?(c=!0,s=n,e.lineIndent>t?l=1:e.lineIndent===t?l=0:e.lineIndent<t&&(l=-1)):s=!1;if(s&&(s=c||a),(l===1||Na===r)&&(Pa===r||Vu===r?m=t:m=t+1,y=e.position-e.lineStart,l===1?s&&(ws(e,y)||uf(e,y,m))||cf(e,m)?h=!0:(o&&hf(e,m)||of(e,m)||lf(e,m)?h=!0:pf(e)?(h=!0,(e.tag!==null||e.anchor!==null)&&Q(e,"alias node should not have any properties")):sf(e,m,Pa===r)&&(h=!0,e.tag===null&&(e.tag="?")),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):l===0&&(h=s&&ws(e,y))),e.tag===null)e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);else if(e.tag==="?"){for(e.result!==null&&e.kind!=="scalar"&&Q(e,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+e.kind+'"'),u=0,f=e.implicitTypes.length;u<f;u+=1)if(g=e.implicitTypes[u],g.resolve(e.result)){e.result=g.construct(e.result),e.tag=g.tag,e.anchor!==null&&(e.anchorMap[e.anchor]=e.result);break}}else if(e.tag!=="!"){if(Pe.call(e.typeMap[e.kind||"fallback"],e.tag))g=e.typeMap[e.kind||"fallback"][e.tag];else for(g=null,d=e.typeMap.multi[e.kind||"fallback"],u=0,f=d.length;u<f;u+=1)if(e.tag.slice(0,d[u].tag.length)===d[u].tag){g=d[u];break}g||Q(e,"unknown tag !<"+e.tag+">"),e.result!==null&&g.kind!==e.kind&&Q(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+g.kind+'", not "'+e.kind+'"'),g.resolve(e.result,e.tag)?(e.result=g.construct(e.result,e.tag),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):Q(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return e.listener!==null&&e.listener("close",e),e.tag!==null||e.anchor!==null||h}p(or,"composeNode");function gf(e){var t=e.position,r,i,a,n=!1,o;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(o=e.input.charCodeAt(e.position))!==0&&(yt(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||o!==37));){for(n=!0,o=e.input.charCodeAt(++e.position),r=e.position;o!==0&&!Nt(o);)o=e.input.charCodeAt(++e.position);for(i=e.input.slice(r,e.position),a=[],i.length<1&&Q(e,"directive name must not be less than one character in length");o!==0;){for(;Ie(o);)o=e.input.charCodeAt(++e.position);if(o===35){do o=e.input.charCodeAt(++e.position);while(o!==0&&!se(o));break}if(se(o))break;for(r=e.position;o!==0&&!Nt(o);)o=e.input.charCodeAt(++e.position);a.push(e.input.slice(r,e.position))}o!==0&&un(e),Pe.call(Vl,i)?Vl[i](e,i,a):Ti(e,'unknown document directive "'+i+'"')}if(yt(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,yt(e,!0,-1)):n&&Q(e,"directives end mark is expected"),or(e,e.lineIndent-1,Na,!1,!0),yt(e,!0,-1),e.checkLineBreaks&&H1.test(e.input.slice(t,e.position))&&Ti(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&Ni(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,yt(e,!0,-1));return}if(e.position<e.length-1)Q(e,"end of the stream or a document separator is expected");else return}p(gf,"readDocument");function wo(e,t){e=String(e),t=t||{},e.length!==0&&(e.charCodeAt(e.length-1)!==10&&e.charCodeAt(e.length-1)!==13&&(e+=`
|
|
97
|
+
`),e.charCodeAt(0)===65279&&(e=e.slice(1)));var r=new nf(e,t),i=e.indexOf("\0");for(i!==-1&&(r.position=i,Q(r,"null byte is not allowed in input")),r.input+="\0";r.input.charCodeAt(r.position)===32;)r.lineIndent+=1,r.position+=1;for(;r.position<r.length-1;)gf(r);return r.documents}p(wo,"loadDocuments");function Y1(e,t,r){t!==null&&typeof t=="object"&&typeof r>"u"&&(r=t,t=null);var i=wo(e,r);if(typeof t!="function")return i;for(var a=0,n=i.length;a<n;a+=1)t(i[a])}p(Y1,"loadAll$1");function mf(e,t){var r=wo(e,t);if(r.length!==0){if(r.length===1)return r[0];throw new Yt("expected a single document in the stream, but found more")}}p(mf,"load$1");var U1=mf,G1={load:U1},yf=Object.prototype.toString,xf=Object.prototype.hasOwnProperty,So=65279,V1=9,Li=10,X1=13,K1=32,Z1=33,Q1=34,Ss=35,J1=37,t2=38,e2=39,r2=42,bf=44,i2=45,Wa=58,a2=61,n2=62,s2=63,o2=64,_f=91,Cf=93,l2=96,vf=123,c2=124,wf=125,It={};It[0]="\\0";It[7]="\\a";It[8]="\\b";It[9]="\\t";It[10]="\\n";It[11]="\\v";It[12]="\\f";It[13]="\\r";It[27]="\\e";It[34]='\\"';It[92]="\\\\";It[133]="\\N";It[160]="\\_";It[8232]="\\L";It[8233]="\\P";var h2=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],u2=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;function Sf(e,t){var r,i,a,n,o,s,l;if(t===null)return{};for(r={},i=Object.keys(t),a=0,n=i.length;a<n;a+=1)o=i[a],s=String(t[o]),o.slice(0,2)==="!!"&&(o="tag:yaml.org,2002:"+o.slice(2)),l=e.compiledTypeMap.fallback[o],l&&xf.call(l.styleAliases,s)&&(s=l.styleAliases[s]),r[o]=s;return r}p(Sf,"compileStyleMap");function kf(e){var t,r,i;if(t=e.toString(16).toUpperCase(),e<=255)r="x",i=2;else if(e<=65535)r="u",i=4;else if(e<=4294967295)r="U",i=8;else throw new Yt("code point within a string may not be greater than 0xFFFFFFFF");return"\\"+r+St.repeat("0",i-t.length)+t}p(kf,"encodeHex");var f2=1,Bi=2;function Tf(e){this.schema=e.schema||Gu,this.indent=Math.max(1,e.indent||2),this.noArrayIndent=e.noArrayIndent||!1,this.skipInvalid=e.skipInvalid||!1,this.flowLevel=St.isNothing(e.flowLevel)?-1:e.flowLevel,this.styleMap=Sf(this.schema,e.styles||null),this.sortKeys=e.sortKeys||!1,this.lineWidth=e.lineWidth||80,this.noRefs=e.noRefs||!1,this.noCompatMode=e.noCompatMode||!1,this.condenseFlow=e.condenseFlow||!1,this.quotingType=e.quotingType==='"'?Bi:f2,this.forceQuotes=e.forceQuotes||!1,this.replacer=typeof e.replacer=="function"?e.replacer:null,this.implicitTypes=this.schema.compiledImplicit,this.explicitTypes=this.schema.compiledExplicit,this.tag=null,this.result="",this.duplicates=[],this.usedDuplicates=null}p(Tf,"State");function ks(e,t){for(var r=St.repeat(" ",t),i=0,a=-1,n="",o,s=e.length;i<s;)a=e.indexOf(`
|
|
98
|
+
`,i),a===-1?(o=e.slice(i),i=s):(o=e.slice(i,a+1),i=a+1),o.length&&o!==`
|
|
99
|
+
`&&(n+=r),n+=o;return n}p(ks,"indentString");function za(e,t){return`
|
|
100
|
+
`+St.repeat(" ",e.indent*t)}p(za,"generateNextLine");function Lf(e,t){var r,i,a;for(r=0,i=e.implicitTypes.length;r<i;r+=1)if(a=e.implicitTypes[r],a.resolve(t))return!0;return!1}p(Lf,"testImplicitResolving");function Ai(e){return e===K1||e===V1}p(Ai,"isWhitespace");function qr(e){return 32<=e&&e<=126||161<=e&&e<=55295&&e!==8232&&e!==8233||57344<=e&&e<=65533&&e!==So||65536<=e&&e<=1114111}p(qr,"isPrintable");function Ts(e){return qr(e)&&e!==So&&e!==X1&&e!==Li}p(Ts,"isNsCharOrWhitespace");function Ls(e,t,r){var i=Ts(e),a=i&&!Ai(e);return(r?i:i&&e!==bf&&e!==_f&&e!==Cf&&e!==vf&&e!==wf)&&e!==Ss&&!(t===Wa&&!a)||Ts(t)&&!Ai(t)&&e===Ss||t===Wa&&a}p(Ls,"isPlainSafe");function Bf(e){return qr(e)&&e!==So&&!Ai(e)&&e!==i2&&e!==s2&&e!==Wa&&e!==bf&&e!==_f&&e!==Cf&&e!==vf&&e!==wf&&e!==Ss&&e!==t2&&e!==r2&&e!==Z1&&e!==c2&&e!==a2&&e!==n2&&e!==e2&&e!==Q1&&e!==J1&&e!==o2&&e!==l2}p(Bf,"isPlainSafeFirst");function Af(e){return!Ai(e)&&e!==Wa}p(Af,"isPlainSafeLast");function Sr(e,t){var r=e.charCodeAt(t),i;return r>=55296&&r<=56319&&t+1<e.length&&(i=e.charCodeAt(t+1),i>=56320&&i<=57343)?(r-55296)*1024+i-56320+65536:r}p(Sr,"codePointAt");function ko(e){var t=/^\n* /;return t.test(e)}p(ko,"needIndentIndicator");var Mf=1,Bs=2,Ef=3,$f=4,vr=5;function Ff(e,t,r,i,a,n,o,s){var l,c=0,h=null,u=!1,f=!1,d=i!==-1,g=-1,m=Bf(Sr(e,0))&&Af(Sr(e,e.length-1));if(t||o)for(l=0;l<e.length;c>=65536?l+=2:l++){if(c=Sr(e,l),!qr(c))return vr;m=m&&Ls(c,h,s),h=c}else{for(l=0;l<e.length;c>=65536?l+=2:l++){if(c=Sr(e,l),c===Li)u=!0,d&&(f=f||l-g-1>i&&e[g+1]!==" ",g=l);else if(!qr(c))return vr;m=m&&Ls(c,h,s),h=c}f=f||d&&l-g-1>i&&e[g+1]!==" "}return!u&&!f?m&&!o&&!a(e)?Mf:n===Bi?vr:Bs:r>9&&ko(e)?vr:o?n===Bi?vr:Bs:f?$f:Ef}p(Ff,"chooseScalarStyle");function Of(e,t,r,i,a){e.dump=(function(){if(t.length===0)return e.quotingType===Bi?'""':"''";if(!e.noCompatMode&&(h2.indexOf(t)!==-1||u2.test(t)))return e.quotingType===Bi?'"'+t+'"':"'"+t+"'";var n=e.indent*Math.max(1,r),o=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-n),s=i||e.flowLevel>-1&&r>=e.flowLevel;function l(c){return Lf(e,c)}switch(p(l,"testAmbiguity"),Ff(t,s,e.indent,o,l,e.quotingType,e.forceQuotes&&!i,a)){case Mf:return t;case Bs:return"'"+t.replace(/'/g,"''")+"'";case Ef:return"|"+As(t,e.indent)+Ms(ks(t,n));case $f:return">"+As(t,e.indent)+Ms(ks(Df(t,o),n));case vr:return'"'+If(t)+'"';default:throw new Yt("impossible error: invalid scalar style")}})()}p(Of,"writeScalar");function As(e,t){var r=ko(e)?String(t):"",i=e[e.length-1]===`
|
|
101
|
+
`,a=i&&(e[e.length-2]===`
|
|
102
|
+
`||e===`
|
|
103
|
+
`),n=a?"+":i?"":"-";return r+n+`
|
|
104
|
+
`}p(As,"blockHeader");function Ms(e){return e[e.length-1]===`
|
|
105
|
+
`?e.slice(0,-1):e}p(Ms,"dropEndingNewline");function Df(e,t){for(var r=/(\n+)([^\n]*)/g,i=(function(){var c=e.indexOf(`
|
|
106
|
+
`);return c=c!==-1?c:e.length,r.lastIndex=c,Es(e.slice(0,c),t)})(),a=e[0]===`
|
|
107
|
+
`||e[0]===" ",n,o;o=r.exec(e);){var s=o[1],l=o[2];n=l[0]===" ",i+=s+(!a&&!n&&l!==""?`
|
|
108
|
+
`:"")+Es(l,t),a=n}return i}p(Df,"foldString");function Es(e,t){if(e===""||e[0]===" ")return e;for(var r=/ [^ ]/g,i,a=0,n,o=0,s=0,l="";i=r.exec(e);)s=i.index,s-a>t&&(n=o>a?o:s,l+=`
|
|
109
|
+
`+e.slice(a,n),a=n+1),o=s;return l+=`
|
|
110
|
+
`,e.length-a>t&&o>a?l+=e.slice(a,o)+`
|
|
111
|
+
`+e.slice(o+1):l+=e.slice(a),l.slice(1)}p(Es,"foldLine");function If(e){for(var t="",r=0,i,a=0;a<e.length;r>=65536?a+=2:a++)r=Sr(e,a),i=It[r],!i&&qr(r)?(t+=e[a],r>=65536&&(t+=e[a+1])):t+=i||kf(r);return t}p(If,"escapeString");function Rf(e,t,r){var i="",a=e.tag,n,o,s;for(n=0,o=r.length;n<o;n+=1)s=r[n],e.replacer&&(s=e.replacer.call(r,String(n),s)),(ge(e,t,s,!1,!1)||typeof s>"u"&&ge(e,t,null,!1,!1))&&(i!==""&&(i+=","+(e.condenseFlow?"":" ")),i+=e.dump);e.tag=a,e.dump="["+i+"]"}p(Rf,"writeFlowSequence");function $s(e,t,r,i){var a="",n=e.tag,o,s,l;for(o=0,s=r.length;o<s;o+=1)l=r[o],e.replacer&&(l=e.replacer.call(r,String(o),l)),(ge(e,t+1,l,!0,!0,!1,!0)||typeof l>"u"&&ge(e,t+1,null,!0,!0,!1,!0))&&((!i||a!=="")&&(a+=za(e,t)),e.dump&&Li===e.dump.charCodeAt(0)?a+="-":a+="- ",a+=e.dump);e.tag=n,e.dump=a||"[]"}p($s,"writeBlockSequence");function Pf(e,t,r){var i="",a=e.tag,n=Object.keys(r),o,s,l,c,h;for(o=0,s=n.length;o<s;o+=1)h="",i!==""&&(h+=", "),e.condenseFlow&&(h+='"'),l=n[o],c=r[l],e.replacer&&(c=e.replacer.call(r,l,c)),ge(e,t,l,!1,!1)&&(e.dump.length>1024&&(h+="? "),h+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),ge(e,t,c,!1,!1)&&(h+=e.dump,i+=h));e.tag=a,e.dump="{"+i+"}"}p(Pf,"writeFlowMapping");function Nf(e,t,r,i){var a="",n=e.tag,o=Object.keys(r),s,l,c,h,u,f;if(e.sortKeys===!0)o.sort();else if(typeof e.sortKeys=="function")o.sort(e.sortKeys);else if(e.sortKeys)throw new Yt("sortKeys must be a boolean or a function");for(s=0,l=o.length;s<l;s+=1)f="",(!i||a!=="")&&(f+=za(e,t)),c=o[s],h=r[c],e.replacer&&(h=e.replacer.call(r,c,h)),ge(e,t+1,c,!0,!0,!0)&&(u=e.tag!==null&&e.tag!=="?"||e.dump&&e.dump.length>1024,u&&(e.dump&&Li===e.dump.charCodeAt(0)?f+="?":f+="? "),f+=e.dump,u&&(f+=za(e,t)),ge(e,t+1,h,!0,u)&&(e.dump&&Li===e.dump.charCodeAt(0)?f+=":":f+=": ",f+=e.dump,a+=f));e.tag=n,e.dump=a||"{}"}p(Nf,"writeBlockMapping");function Fs(e,t,r){var i,a,n,o,s,l;for(a=r?e.explicitTypes:e.implicitTypes,n=0,o=a.length;n<o;n+=1)if(s=a[n],(s.instanceOf||s.predicate)&&(!s.instanceOf||typeof t=="object"&&t instanceof s.instanceOf)&&(!s.predicate||s.predicate(t))){if(r?s.multi&&s.representName?e.tag=s.representName(t):e.tag=s.tag:e.tag="?",s.represent){if(l=e.styleMap[s.tag]||s.defaultStyle,yf.call(s.represent)==="[object Function]")i=s.represent(t,l);else if(xf.call(s.represent,l))i=s.represent[l](t,l);else throw new Yt("!<"+s.tag+'> tag resolver accepts not "'+l+'" style');e.dump=i}return!0}return!1}p(Fs,"detectType");function ge(e,t,r,i,a,n,o){e.tag=null,e.dump=r,Fs(e,r,!1)||Fs(e,r,!0);var s=yf.call(e.dump),l=i,c;i&&(i=e.flowLevel<0||e.flowLevel>t);var h=s==="[object Object]"||s==="[object Array]",u,f;if(h&&(u=e.duplicates.indexOf(r),f=u!==-1),(e.tag!==null&&e.tag!=="?"||f||e.indent!==2&&t>0)&&(a=!1),f&&e.usedDuplicates[u])e.dump="*ref_"+u;else{if(h&&f&&!e.usedDuplicates[u]&&(e.usedDuplicates[u]=!0),s==="[object Object]")i&&Object.keys(e.dump).length!==0?(Nf(e,t,e.dump,a),f&&(e.dump="&ref_"+u+e.dump)):(Pf(e,t,e.dump),f&&(e.dump="&ref_"+u+" "+e.dump));else if(s==="[object Array]")i&&e.dump.length!==0?(e.noArrayIndent&&!o&&t>0?$s(e,t-1,e.dump,a):$s(e,t,e.dump,a),f&&(e.dump="&ref_"+u+e.dump)):(Rf(e,t,e.dump),f&&(e.dump="&ref_"+u+" "+e.dump));else if(s==="[object String]")e.tag!=="?"&&Of(e,e.dump,t,n,l);else{if(s==="[object Undefined]")return!1;if(e.skipInvalid)return!1;throw new Yt("unacceptable kind of an object to dump "+s)}e.tag!==null&&e.tag!=="?"&&(c=encodeURI(e.tag[0]==="!"?e.tag.slice(1):e.tag).replace(/!/g,"%21"),e.tag[0]==="!"?c="!"+c:c.slice(0,18)==="tag:yaml.org,2002:"?c="!!"+c.slice(18):c="!<"+c+">",e.dump=c+" "+e.dump)}return!0}p(ge,"writeNode");function Wf(e,t){var r=[],i=[],a,n;for(qa(e,r,i),a=0,n=i.length;a<n;a+=1)t.duplicates.push(r[i[a]]);t.usedDuplicates=new Array(n)}p(Wf,"getDuplicateReferences");function qa(e,t,r){var i,a,n;if(e!==null&&typeof e=="object")if(a=t.indexOf(e),a!==-1)r.indexOf(a)===-1&&r.push(a);else if(t.push(e),Array.isArray(e))for(a=0,n=e.length;a<n;a+=1)qa(e[a],t,r);else for(i=Object.keys(e),a=0,n=i.length;a<n;a+=1)qa(e[i[a]],t,r)}p(qa,"inspectNode");function d2(e,t){t=t||{};var r=new Tf(t);r.noRefs||Wf(e,r);var i=e;return r.replacer&&(i=r.replacer.call({"":i},"",i)),ge(r,0,i,!0,!0)?r.dump+`
|
|
112
|
+
`:""}p(d2,"dump$1");function p2(e,t){return function(){throw new Error("Function yaml."+e+" is removed in js-yaml 4. Use yaml."+t+" instead, which is now safe by default.")}}p(p2,"renamed");var g2=Mu,m2=G1.load;var $t={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4},Xl={arrow_point:9,arrow_cross:12.5,arrow_circle:12.5};function di(e,t){if(e===void 0||t===void 0)return{angle:0,deltaX:0,deltaY:0};e=gt(e),t=gt(t);const[r,i]=[e.x,e.y],[a,n]=[t.x,t.y],o=a-r,s=n-i;return{angle:Math.atan(s/o),deltaX:o,deltaY:s}}p(di,"calculateDeltaAndAngle");var gt=p(e=>Array.isArray(e)?{x:e[0],y:e[1]}:e,"pointTransformer"),y2=p(e=>({x:p(function(t,r,i){let a=0;const n=gt(i[0]).x<gt(i[i.length-1]).x?"left":"right";if(r===0&&Object.hasOwn($t,e.arrowTypeStart)){const{angle:d,deltaX:g}=di(i[0],i[1]);a=$t[e.arrowTypeStart]*Math.cos(d)*(g>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn($t,e.arrowTypeEnd)){const{angle:d,deltaX:g}=di(i[i.length-1],i[i.length-2]);a=$t[e.arrowTypeEnd]*Math.cos(d)*(g>=0?1:-1)}const o=Math.abs(gt(t).x-gt(i[i.length-1]).x),s=Math.abs(gt(t).y-gt(i[i.length-1]).y),l=Math.abs(gt(t).x-gt(i[0]).x),c=Math.abs(gt(t).y-gt(i[0]).y),h=$t[e.arrowTypeStart],u=$t[e.arrowTypeEnd],f=1;if(o<u&&o>0&&s<u){let d=u+f-o;d*=n==="right"?-1:1,a-=d}if(l<h&&l>0&&c<h){let d=h+f-l;d*=n==="right"?-1:1,a+=d}return gt(t).x+a},"x"),y:p(function(t,r,i){let a=0;const n=gt(i[0]).y<gt(i[i.length-1]).y?"down":"up";if(r===0&&Object.hasOwn($t,e.arrowTypeStart)){const{angle:d,deltaY:g}=di(i[0],i[1]);a=$t[e.arrowTypeStart]*Math.abs(Math.sin(d))*(g>=0?1:-1)}else if(r===i.length-1&&Object.hasOwn($t,e.arrowTypeEnd)){const{angle:d,deltaY:g}=di(i[i.length-1],i[i.length-2]);a=$t[e.arrowTypeEnd]*Math.abs(Math.sin(d))*(g>=0?1:-1)}const o=Math.abs(gt(t).y-gt(i[i.length-1]).y),s=Math.abs(gt(t).x-gt(i[i.length-1]).x),l=Math.abs(gt(t).y-gt(i[0]).y),c=Math.abs(gt(t).x-gt(i[0]).x),h=$t[e.arrowTypeStart],u=$t[e.arrowTypeEnd],f=1;if(o<u&&o>0&&s<u){let d=u+f-o;d*=n==="up"?-1:1,a-=d}if(l<h&&l>0&&c<h){let d=h+f-l;d*=n==="up"?-1:1,a+=d}return gt(t).y+a},"y")}),"getLineFunctionsWithOffset"),To=p(({flowchart:e})=>{const t=e?.subGraphTitleMargin?.top??0,r=e?.subGraphTitleMargin?.bottom??0,i=t+r;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:r,subGraphTitleTotalMargin:i}},"getSubGraphTitleMargins"),x2=p(e=>{const{handDrawnSeed:t}=ut();return{fill:e,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:e,seed:t}},"solidStateFill"),Ur=p(e=>{const t=b2([...e.cssCompiledStyles||[],...e.cssStyles||[],...e.labelStyle||[]]);return{stylesMap:t,stylesArray:[...t]}},"compileStyles"),b2=p(e=>{const t=new Map;return e.forEach(r=>{const[i,a]=r.split(":");t.set(i.trim(),a?.trim())}),t},"styles2Map"),zf=p(e=>e==="color"||e==="font-size"||e==="font-family"||e==="font-weight"||e==="font-style"||e==="text-decoration"||e==="text-align"||e==="text-transform"||e==="line-height"||e==="letter-spacing"||e==="word-spacing"||e==="text-shadow"||e==="text-overflow"||e==="white-space"||e==="word-wrap"||e==="word-break"||e==="overflow-wrap"||e==="hyphens","isLabelStyle"),U=p(e=>{const{stylesArray:t}=Ur(e),r=[],i=[],a=[],n=[];return t.forEach(o=>{const s=o[0];zf(s)?r.push(o.join(":")+" !important"):(i.push(o.join(":")+" !important"),s.includes("stroke")&&a.push(o.join(":")+" !important"),s==="fill"&&n.push(o.join(":")+" !important"))}),{labelStyles:r.join(";"),nodeStyles:i.join(";"),stylesArray:t,borderStyles:a,backgroundStyles:n}},"styles2String"),Y=p((e,t)=>{const{themeVariables:r,handDrawnSeed:i}=ut(),{nodeBorder:a,mainBkg:n}=r,{stylesMap:o}=Ur(e);return Object.assign({roughness:.7,fill:o.get("fill")||n,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:o.get("stroke")||a,seed:i,strokeWidth:o.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0],strokeLineDash:_2(o.get("stroke-dasharray"))},t)},"userNodeOverrides"),_2=p(e=>{if(!e)return[0,0];const t=e.trim().split(/\s+/).map(Number);if(t.length===1){const a=isNaN(t[0])?0:t[0];return[a,a]}const r=isNaN(t[0])?0:t[0],i=isNaN(t[1])?0:t[1];return[r,i]},"getStrokeDashArray"),ni={},vt={},Kl;function C2(){return Kl||(Kl=1,Object.defineProperty(vt,"__esModule",{value:!0}),vt.BLANK_URL=vt.relativeFirstCharacters=vt.whitespaceEscapeCharsRegex=vt.urlSchemeRegex=vt.ctrlCharactersRegex=vt.htmlCtrlEntityRegex=vt.htmlEntitiesRegex=vt.invalidProtocolRegex=void 0,vt.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,vt.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,vt.htmlCtrlEntityRegex=/&(newline|tab);/gi,vt.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,vt.urlSchemeRegex=/^.+(:|:)/gim,vt.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,vt.relativeFirstCharacters=[".","/"],vt.BLANK_URL="about:blank"),vt}var Zl;function v2(){if(Zl)return ni;Zl=1,Object.defineProperty(ni,"__esModule",{value:!0}),ni.sanitizeUrl=void 0;var e=C2();function t(o){return e.relativeFirstCharacters.indexOf(o[0])>-1}function r(o){var s=o.replace(e.ctrlCharactersRegex,"");return s.replace(e.htmlEntitiesRegex,function(l,c){return String.fromCharCode(c)})}function i(o){return URL.canParse(o)}function a(o){try{return decodeURIComponent(o)}catch{return o}}function n(o){if(!o)return e.BLANK_URL;var s,l=a(o.trim());do l=r(l).replace(e.htmlCtrlEntityRegex,"").replace(e.ctrlCharactersRegex,"").replace(e.whitespaceEscapeCharsRegex,"").trim(),l=a(l),s=l.match(e.ctrlCharactersRegex)||l.match(e.htmlEntitiesRegex)||l.match(e.htmlCtrlEntityRegex)||l.match(e.whitespaceEscapeCharsRegex);while(s&&s.length>0);var c=l;if(!c)return e.BLANK_URL;if(t(c))return c;var h=c.trimStart(),u=h.match(e.urlSchemeRegex);if(!u)return c;var f=u[0].toLowerCase().trim();if(e.invalidProtocolRegex.test(f))return e.BLANK_URL;var d=h.replace(/\\/g,"/");if(f==="mailto:"||f.includes("://"))return d;if(f==="http:"||f==="https:"){if(!i(d))return e.BLANK_URL;var g=new URL(d);return g.protocol=g.protocol.toLowerCase(),g.hostname=g.hostname.toLowerCase(),g.toString()}return d}return ni.sanitizeUrl=n,ni}var w2=v2(),qf=typeof global=="object"&&global&&global.Object===Object&&global,S2=typeof self=="object"&&self&&self.Object===Object&&self,ye=qf||S2||Function("return this")(),Ha=ye.Symbol,Hf=Object.prototype,k2=Hf.hasOwnProperty,T2=Hf.toString,si=Ha?Ha.toStringTag:void 0;function L2(e){var t=k2.call(e,si),r=e[si];try{e[si]=void 0;var i=!0}catch{}var a=T2.call(e);return i&&(t?e[si]=r:delete e[si]),a}var B2=Object.prototype,A2=B2.toString;function M2(e){return A2.call(e)}var E2="[object Null]",$2="[object Undefined]",Ql=Ha?Ha.toStringTag:void 0;function Gr(e){return e==null?e===void 0?$2:E2:Ql&&Ql in Object(e)?L2(e):M2(e)}function hr(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var F2="[object AsyncFunction]",O2="[object Function]",D2="[object GeneratorFunction]",I2="[object Proxy]";function Lo(e){if(!hr(e))return!1;var t=Gr(e);return t==O2||t==D2||t==F2||t==I2}var Un=ye["__core-js_shared__"],Jl=(function(){var e=/[^.]+$/.exec(Un&&Un.keys&&Un.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function R2(e){return!!Jl&&Jl in e}var P2=Function.prototype,N2=P2.toString;function ur(e){if(e!=null){try{return N2.call(e)}catch{}try{return e+""}catch{}}return""}var W2=/[\\^$.*+?()[\]{}|]/g,z2=/^\[object .+?Constructor\]$/,q2=Function.prototype,H2=Object.prototype,j2=q2.toString,Y2=H2.hasOwnProperty,U2=RegExp("^"+j2.call(Y2).replace(W2,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function G2(e){if(!hr(e)||R2(e))return!1;var t=Lo(e)?U2:z2;return t.test(ur(e))}function V2(e,t){return e?.[t]}function fr(e,t){var r=V2(e,t);return G2(r)?r:void 0}var Mi=fr(Object,"create");function X2(){this.__data__=Mi?Mi(null):{},this.size=0}function K2(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Z2="__lodash_hash_undefined__",Q2=Object.prototype,J2=Q2.hasOwnProperty;function t_(e){var t=this.__data__;if(Mi){var r=t[e];return r===Z2?void 0:r}return J2.call(t,e)?t[e]:void 0}var e_=Object.prototype,r_=e_.hasOwnProperty;function i_(e){var t=this.__data__;return Mi?t[e]!==void 0:r_.call(t,e)}var a_="__lodash_hash_undefined__";function n_(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Mi&&t===void 0?a_:t,this}function lr(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}lr.prototype.clear=X2;lr.prototype.delete=K2;lr.prototype.get=t_;lr.prototype.has=i_;lr.prototype.set=n_;function s_(){this.__data__=[],this.size=0}function dn(e,t){return e===t||e!==e&&t!==t}function pn(e,t){for(var r=e.length;r--;)if(dn(e[r][0],t))return r;return-1}var o_=Array.prototype,l_=o_.splice;function c_(e){var t=this.__data__,r=pn(t,e);if(r<0)return!1;var i=t.length-1;return r==i?t.pop():l_.call(t,r,1),--this.size,!0}function h_(e){var t=this.__data__,r=pn(t,e);return r<0?void 0:t[r][1]}function u_(e){return pn(this.__data__,e)>-1}function f_(e,t){var r=this.__data__,i=pn(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}function $e(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}$e.prototype.clear=s_;$e.prototype.delete=c_;$e.prototype.get=h_;$e.prototype.has=u_;$e.prototype.set=f_;var Ei=fr(ye,"Map");function d_(){this.size=0,this.__data__={hash:new lr,map:new(Ei||$e),string:new lr}}function p_(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function gn(e,t){var r=e.__data__;return p_(t)?r[typeof t=="string"?"string":"hash"]:r.map}function g_(e){var t=gn(this,e).delete(e);return this.size-=t?1:0,t}function m_(e){return gn(this,e).get(e)}function y_(e){return gn(this,e).has(e)}function x_(e,t){var r=gn(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}function ze(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}ze.prototype.clear=d_;ze.prototype.delete=g_;ze.prototype.get=m_;ze.prototype.has=y_;ze.prototype.set=x_;var b_="Expected a function";function Wi(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(b_);var r=function(){var i=arguments,a=t?t.apply(this,i):i[0],n=r.cache;if(n.has(a))return n.get(a);var o=e.apply(this,i);return r.cache=n.set(a,o)||n,o};return r.cache=new(Wi.Cache||ze),r}Wi.Cache=ze;function __(){this.__data__=new $e,this.size=0}function C_(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}function v_(e){return this.__data__.get(e)}function w_(e){return this.__data__.has(e)}var S_=200;function k_(e,t){var r=this.__data__;if(r instanceof $e){var i=r.__data__;if(!Ei||i.length<S_-1)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new ze(i)}return r.set(e,t),this.size=r.size,this}function Vr(e){var t=this.__data__=new $e(e);this.size=t.size}Vr.prototype.clear=__;Vr.prototype.delete=C_;Vr.prototype.get=v_;Vr.prototype.has=w_;Vr.prototype.set=k_;var ja=(function(){try{var e=fr(Object,"defineProperty");return e({},"",{}),e}catch{}})();function Bo(e,t,r){t=="__proto__"&&ja?ja(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}function Os(e,t,r){(r!==void 0&&!dn(e[t],r)||r===void 0&&!(t in e))&&Bo(e,t,r)}function T_(e){return function(t,r,i){for(var a=-1,n=Object(t),o=i(t),s=o.length;s--;){var l=o[++a];if(r(n[l],l,n)===!1)break}return t}}var L_=T_(),jf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,tc=jf&&typeof module=="object"&&module&&!module.nodeType&&module,B_=tc&&tc.exports===jf,ec=B_?ye.Buffer:void 0,rc=ec?ec.allocUnsafe:void 0;function A_(e,t){if(t)return e.slice();var r=e.length,i=rc?rc(r):new e.constructor(r);return e.copy(i),i}var ic=ye.Uint8Array;function M_(e){var t=new e.constructor(e.byteLength);return new ic(t).set(new ic(e)),t}function E_(e,t){var r=t?M_(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}function $_(e,t){var r=-1,i=e.length;for(t||(t=Array(i));++r<i;)t[r]=e[r];return t}var ac=Object.create,F_=(function(){function e(){}return function(t){if(!hr(t))return{};if(ac)return ac(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}})();function Yf(e,t){return function(r){return e(t(r))}}var Uf=Yf(Object.getPrototypeOf,Object),O_=Object.prototype;function mn(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||O_;return e===r}function D_(e){return typeof e.constructor=="function"&&!mn(e)?F_(Uf(e)):{}}function zi(e){return e!=null&&typeof e=="object"}var I_="[object Arguments]";function nc(e){return zi(e)&&Gr(e)==I_}var Gf=Object.prototype,R_=Gf.hasOwnProperty,P_=Gf.propertyIsEnumerable,Ya=nc((function(){return arguments})())?nc:function(e){return zi(e)&&R_.call(e,"callee")&&!P_.call(e,"callee")},Ua=Array.isArray,N_=9007199254740991;function Vf(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=N_}function yn(e){return e!=null&&Vf(e.length)&&!Lo(e)}function W_(e){return zi(e)&&yn(e)}function z_(){return!1}var Xf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,sc=Xf&&typeof module=="object"&&module&&!module.nodeType&&module,q_=sc&&sc.exports===Xf,oc=q_?ye.Buffer:void 0,H_=oc?oc.isBuffer:void 0,Ao=H_||z_,j_="[object Object]",Y_=Function.prototype,U_=Object.prototype,Kf=Y_.toString,G_=U_.hasOwnProperty,V_=Kf.call(Object);function X_(e){if(!zi(e)||Gr(e)!=j_)return!1;var t=Uf(e);if(t===null)return!0;var r=G_.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Kf.call(r)==V_}var K_="[object Arguments]",Z_="[object Array]",Q_="[object Boolean]",J_="[object Date]",tC="[object Error]",eC="[object Function]",rC="[object Map]",iC="[object Number]",aC="[object Object]",nC="[object RegExp]",sC="[object Set]",oC="[object String]",lC="[object WeakMap]",cC="[object ArrayBuffer]",hC="[object DataView]",uC="[object Float32Array]",fC="[object Float64Array]",dC="[object Int8Array]",pC="[object Int16Array]",gC="[object Int32Array]",mC="[object Uint8Array]",yC="[object Uint8ClampedArray]",xC="[object Uint16Array]",bC="[object Uint32Array]",dt={};dt[uC]=dt[fC]=dt[dC]=dt[pC]=dt[gC]=dt[mC]=dt[yC]=dt[xC]=dt[bC]=!0;dt[K_]=dt[Z_]=dt[cC]=dt[Q_]=dt[hC]=dt[J_]=dt[tC]=dt[eC]=dt[rC]=dt[iC]=dt[aC]=dt[nC]=dt[sC]=dt[oC]=dt[lC]=!1;function _C(e){return zi(e)&&Vf(e.length)&&!!dt[Gr(e)]}function CC(e){return function(t){return e(t)}}var Zf=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ci=Zf&&typeof module=="object"&&module&&!module.nodeType&&module,vC=Ci&&Ci.exports===Zf,Gn=vC&&qf.process,lc=(function(){try{var e=Ci&&Ci.require&&Ci.require("util").types;return e||Gn&&Gn.binding&&Gn.binding("util")}catch{}})(),cc=lc&&lc.isTypedArray,Mo=cc?CC(cc):_C;function Ds(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var wC=Object.prototype,SC=wC.hasOwnProperty;function kC(e,t,r){var i=e[t];(!(SC.call(e,t)&&dn(i,r))||r===void 0&&!(t in e))&&Bo(e,t,r)}function TC(e,t,r,i){var a=!r;r||(r={});for(var n=-1,o=t.length;++n<o;){var s=t[n],l=void 0;l===void 0&&(l=e[s]),a?Bo(r,s,l):kC(r,s,l)}return r}function LC(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i}var BC=9007199254740991,AC=/^(?:0|[1-9]\d*)$/;function Qf(e,t){var r=typeof e;return t=t??BC,!!t&&(r=="number"||r!="symbol"&&AC.test(e))&&e>-1&&e%1==0&&e<t}var MC=Object.prototype,EC=MC.hasOwnProperty;function $C(e,t){var r=Ua(e),i=!r&&Ya(e),a=!r&&!i&&Ao(e),n=!r&&!i&&!a&&Mo(e),o=r||i||a||n,s=o?LC(e.length,String):[],l=s.length;for(var c in e)(t||EC.call(e,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||n&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Qf(c,l)))&&s.push(c);return s}function FC(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var OC=Object.prototype,DC=OC.hasOwnProperty;function IC(e){if(!hr(e))return FC(e);var t=mn(e),r=[];for(var i in e)i=="constructor"&&(t||!DC.call(e,i))||r.push(i);return r}function Jf(e){return yn(e)?$C(e,!0):IC(e)}function RC(e){return TC(e,Jf(e))}function PC(e,t,r,i,a,n,o){var s=Ds(e,r),l=Ds(t,r),c=o.get(l);if(c){Os(e,r,c);return}var h=n?n(s,l,r+"",e,t,o):void 0,u=h===void 0;if(u){var f=Ua(l),d=!f&&Ao(l),g=!f&&!d&&Mo(l);h=l,f||d||g?Ua(s)?h=s:W_(s)?h=$_(s):d?(u=!1,h=A_(l,!0)):g?(u=!1,h=E_(l,!0)):h=[]:X_(l)||Ya(l)?(h=s,Ya(s)?h=RC(s):(!hr(s)||Lo(s))&&(h=D_(l))):u=!1}u&&(o.set(l,h),a(h,l,i,n,o),o.delete(l)),Os(e,r,h)}function td(e,t,r,i,a){e!==t&&L_(t,function(n,o){if(a||(a=new Vr),hr(n))PC(e,t,o,r,td,i,a);else{var s=i?i(Ds(e,o),n,o+"",e,t,a):void 0;s===void 0&&(s=n),Os(e,o,s)}},Jf)}function ed(e){return e}function NC(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var hc=Math.max;function WC(e,t,r){return t=hc(t===void 0?e.length-1:t,0),function(){for(var i=arguments,a=-1,n=hc(i.length-t,0),o=Array(n);++a<n;)o[a]=i[t+a];a=-1;for(var s=Array(t+1);++a<t;)s[a]=i[a];return s[t]=r(o),NC(e,this,s)}}function zC(e){return function(){return e}}var qC=ja?function(e,t){return ja(e,"toString",{configurable:!0,enumerable:!1,value:zC(t),writable:!0})}:ed,HC=800,jC=16,YC=Date.now;function UC(e){var t=0,r=0;return function(){var i=YC(),a=jC-(i-r);if(r=i,a>0){if(++t>=HC)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var GC=UC(qC);function VC(e,t){return GC(WC(e,t,ed),e+"")}function XC(e,t,r){if(!hr(r))return!1;var i=typeof t;return(i=="number"?yn(r)&&Qf(t,r.length):i=="string"&&t in r)?dn(r[t],e):!1}function KC(e){return VC(function(t,r){var i=-1,a=r.length,n=a>1?r[a-1]:void 0,o=a>2?r[2]:void 0;for(n=e.length>3&&typeof n=="function"?(a--,n):void 0,o&&XC(r[0],r[1],o)&&(n=a<3?void 0:n,a=1),t=Object(t);++i<a;){var s=r[i];s&&e(t,s,i,n)}return t})}var ZC=KC(function(e,t,r){td(e,t,r)}),QC="",JC={curveBasis:pa,curveBasisClosed:e1,curveBasisOpen:r1,curveBumpX:Nh,curveBumpY:Wh,curveBundle:i1,curveCardinalClosed:a1,curveCardinalOpen:n1,curveCardinal:jh,curveCatmullRomClosed:s1,curveCatmullRomOpen:o1,curveCatmullRom:Uh,curveLinear:Fa,curveLinearClosed:l1,curveMonotoneX:Qh,curveMonotoneY:Jh,curveNatural:eu,curveStep:ru,curveStepAfter:au,curveStepBefore:iu},tv=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,ev=p(function(e,t){const r=rd(e,/(?:init\b)|(?:initialize\b)/);let i={};if(Array.isArray(r)){const o=r.map(s=>s.args);va(o),i=wt(i,[...o])}else i=r.args;if(!i)return;let a=Js(e,t);const n="config";return i[n]!==void 0&&(a==="flowchart-v2"&&(a="flowchart"),i[a]=i[n],delete i[n]),i},"detectInit"),rd=p(function(e,t=null){try{const r=new RegExp(`[%]{2}(?![{]${tv.source})(?=[}][%]{2}).*
|
|
113
|
+
`,"ig");e=e.trim().replace(r,"").replace(/'/gm,'"'),F.debug(`Detecting diagram directive${t!==null?" type:"+t:""} based on the text:${e}`);let i;const a=[];for(;(i=bi.exec(e))!==null;)if(i.index===bi.lastIndex&&bi.lastIndex++,i&&!t||t&&i[1]?.match(t)||t&&i[2]?.match(t)){const n=i[1]?i[1]:i[2],o=i[3]?i[3].trim():i[4]?JSON.parse(i[4].trim()):null;a.push({type:n,args:o})}return a.length===0?{type:e,args:null}:a.length===1?a[0]:a}catch(r){return F.error(`ERROR: ${r.message} - Unable to parse directive type: '${t}' based on the text: '${e}'`),{type:void 0,args:null}}},"detectDirective"),rv=p(function(e){return e.replace(bi,"")},"removeDirectives"),iv=p(function(e,t){for(const[r,i]of t.entries())if(i.match(e))return r;return-1},"isSubstringInArray");function Eo(e,t){if(!e)return t;const r=`curve${e.charAt(0).toUpperCase()+e.slice(1)}`;return JC[r]??t}p(Eo,"interpolateToCurve");function id(e,t){const r=e.trim();if(r)return t.securityLevel!=="loose"?w2.sanitizeUrl(r):r}p(id,"formatUrl");var av=p((e,...t)=>{const r=e.split("."),i=r.length-1,a=r[i];let n=window;for(let o=0;o<i;o++)if(n=n[r[o]],!n){F.error(`Function name: ${e} not found in window`);return}n[a](...t)},"runFunc");function $o(e,t){return!e||!t?0:Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))}p($o,"distance");function ad(e){let t,r=0;e.forEach(a=>{r+=$o(a,t),t=a});const i=r/2;return Fo(e,i)}p(ad,"traverseEdge");function nd(e){return e.length===1?e[0]:ad(e)}p(nd,"calcLabelPosition");var uc=p((e,t=2)=>{const r=Math.pow(10,t);return Math.round(e*r)/r},"roundNumber"),Fo=p((e,t)=>{let r,i=t;for(const a of e){if(r){const n=$o(a,r);if(n===0)return r;if(n<i)i-=n;else{const o=i/n;if(o<=0)return r;if(o>=1)return{x:a.x,y:a.y};if(o>0&&o<1)return{x:uc((1-o)*r.x+o*a.x,5),y:uc((1-o)*r.y+o*a.y,5)}}}r=a}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),nv=p((e,t,r)=>{F.info(`our points ${JSON.stringify(t)}`),t[0]!==r&&(t=t.reverse());const a=Fo(t,25),n=e?10:5,o=Math.atan2(t[0].y-a.y,t[0].x-a.x),s={x:0,y:0};return s.x=Math.sin(o)*n+(t[0].x+a.x)/2,s.y=-Math.cos(o)*n+(t[0].y+a.y)/2,s},"calcCardinalityPosition");function sd(e,t,r){const i=structuredClone(r);F.info("our points",i),t!=="start_left"&&t!=="start_right"&&i.reverse();const a=25+e,n=Fo(i,a),o=10+e*.5,s=Math.atan2(i[0].y-n.y,i[0].x-n.x),l={x:0,y:0};return t==="start_left"?(l.x=Math.sin(s+Math.PI)*o+(i[0].x+n.x)/2,l.y=-Math.cos(s+Math.PI)*o+(i[0].y+n.y)/2):t==="end_right"?(l.x=Math.sin(s-Math.PI)*o+(i[0].x+n.x)/2-5,l.y=-Math.cos(s-Math.PI)*o+(i[0].y+n.y)/2-5):t==="end_left"?(l.x=Math.sin(s)*o+(i[0].x+n.x)/2-5,l.y=-Math.cos(s)*o+(i[0].y+n.y)/2-5):(l.x=Math.sin(s)*o+(i[0].x+n.x)/2,l.y=-Math.cos(s)*o+(i[0].y+n.y)/2),l}p(sd,"calcTerminalLabelPosition");function od(e){let t="",r="";for(const i of e)i!==void 0&&(i.startsWith("color:")||i.startsWith("text-align:")?r=r+i+";":t=t+i+";");return{style:t,labelStyle:r}}p(od,"getStylesFromArray");var fc=0,sv=p(()=>(fc++,"id-"+Math.random().toString(36).substr(2,12)+"-"+fc),"generateId");function ld(e){let t="";const r="0123456789abcdef",i=r.length;for(let a=0;a<e;a++)t+=r.charAt(Math.floor(Math.random()*i));return t}p(ld,"makeRandomHex");var ov=p(e=>ld(e.length),"random"),lv=p(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),cv=p(function(e,t){const r=t.text.replace(Yr.lineBreakRegex," "),[,i]=xn(t.fontSize),a=e.append("text");a.attr("x",t.x),a.attr("y",t.y),a.style("text-anchor",t.anchor),a.style("font-family",t.fontFamily),a.style("font-size",i),a.style("font-weight",t.fontWeight),a.attr("fill",t.fill),t.class!==void 0&&a.attr("class",t.class);const n=a.append("tspan");return n.attr("x",t.x+t.textMargin*2),n.attr("fill",t.fill),n.text(r),a},"drawSimpleText"),hv=Wi((e,t,r)=>{if(!e||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},r),Yr.lineBreakRegex.test(e)))return e;const i=e.split(" ").filter(Boolean),a=[];let n="";return i.forEach((o,s)=>{const l=Me(`${o} `,r),c=Me(n,r);if(l>t){const{hyphenatedStrings:f,remainingWord:d}=uv(o,t,"-",r);a.push(n,...f),n=d}else c+l>=t?(a.push(n),n=o):n=[n,o].filter(Boolean).join(" ");s+1===i.length&&a.push(n)}),a.filter(o=>o!=="").join(r.joinWith)},(e,t,r)=>`${e}${t}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),uv=Wi((e,t,r="-",i)=>{i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},i);const a=[...e],n=[];let o="";return a.forEach((s,l)=>{const c=`${o}${s}`;if(Me(c,i)>=t){const u=l+1,f=a.length===u,d=`${c}${r}`;n.push(f?c:d),o=""}else o=c}),{hyphenatedStrings:n,remainingWord:o}},(e,t,r="-",i)=>`${e}${t}${r}${i.fontSize}${i.fontWeight}${i.fontFamily}`);function cd(e,t){return Oo(e,t).height}p(cd,"calculateTextHeight");function Me(e,t){return Oo(e,t).width}p(Me,"calculateTextWidth");var Oo=Wi((e,t)=>{const{fontSize:r=12,fontFamily:i="Arial",fontWeight:a=400}=t;if(!e)return{width:0,height:0};const[,n]=xn(r),o=["sans-serif",i],s=e.split(Yr.lineBreakRegex),l=[],c=ht("body");if(!c.remove)return{width:0,height:0,lineHeight:0};const h=c.append("svg");for(const f of o){let d=0;const g={width:0,height:0,lineHeight:0};for(const m of s){const y=lv();y.text=m||QC;const x=cv(h,y).style("font-size",n).style("font-weight",a).style("font-family",f),b=(x._groups||x)[0][0].getBBox();if(b.width===0&&b.height===0)throw new Error("svg element not in render tree");g.width=Math.round(Math.max(g.width,b.width)),d=Math.round(b.height),g.height+=d,g.lineHeight=Math.round(Math.max(g.lineHeight,d))}l.push(g)}h.remove();const u=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[u]},(e,t)=>`${e}${t.fontSize}${t.fontWeight}${t.fontFamily}`),Dr,fv=(Dr=class{constructor(t=!1,r){this.count=0,this.count=r?r.length:0,this.next=t?()=>this.count++:()=>Date.now()}},p(Dr,"InitIDGenerator"),Dr),ea,dv=p(function(e){return ea=ea||document.createElement("div"),e=escape(e).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ea.innerHTML=e,unescape(ea.textContent)},"entityDecode");function Do(e){return"str"in e}p(Do,"isDetailedError");var pv=p((e,t,r,i)=>{if(!i)return;const a=e.node()?.getBBox();a&&e.append("text").text(i).attr("text-anchor","middle").attr("x",a.x+a.width/2).attr("y",-r).attr("class",t)},"insertTitle"),xn=p(e=>{if(typeof e=="number")return[e,e+"px"];const t=parseInt(e??"",10);return Number.isNaN(t)?[void 0,void 0]:e===String(t)?[t,e+"px"]:[t,e]},"parseFontSize");function Io(e,t){return ZC({},e,t)}p(Io,"cleanAndMerge");var ne={assignWithDepth:wt,wrapLabel:hv,calculateTextHeight:cd,calculateTextWidth:Me,calculateTextDimensions:Oo,cleanAndMerge:Io,detectInit:ev,detectDirective:rd,isSubstringInArray:iv,interpolateToCurve:Eo,calcLabelPosition:nd,calcCardinalityPosition:nv,calcTerminalLabelPosition:sd,formatUrl:id,getStylesFromArray:od,generateId:sv,random:ov,runFunc:av,entityDecode:dv,insertTitle:pv,isLabelCoordinateInPath:hd,parseFontSize:xn,InitIDGenerator:fv},gv=p(function(e){let t=e;return t=t.replace(/style.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/classDef.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),t=t.replace(/#\w+;/g,function(r){const i=r.substring(1,r.length-1);return/^\+?\d+$/.test(i)?"fl°°"+i+"¶ß":"fl°"+i+"¶ß"}),t},"encodeEntities"),dr=p(function(e){return e.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),$L=p((e,t,{counter:r=0,prefix:i,suffix:a},n)=>n||`${i?`${i}_`:""}${e}_${t}_${r}${a?`_${a}`:""}`,"getEdgeId");function Dt(e){return e??null}p(Dt,"handleUndefinedAttr");function hd(e,t){const r=Math.round(e.x),i=Math.round(e.y),a=t.replace(/(\d+\.\d+)/g,n=>Math.round(parseFloat(n)).toString());return a.includes(r.toString())||a.includes(i.toString())}p(hd,"isLabelCoordinateInPath");const mv=Object.freeze({left:0,top:0,width:16,height:16}),Ga=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),ud=Object.freeze({...mv,...Ga}),yv=Object.freeze({...ud,body:"",hidden:!1}),xv=Object.freeze({width:null,height:null}),bv=Object.freeze({...xv,...Ga}),_v=(e,t,r,i="")=>{const a=e.split(":");if(e.slice(0,1)==="@"){if(a.length<2||a.length>3)return null;i=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const s=a.pop(),l=a.pop(),c={provider:a.length>0?a[0]:i,prefix:l,name:s};return Vn(c)?c:null}const n=a[0],o=n.split("-");if(o.length>1){const s={provider:i,prefix:o.shift(),name:o.join("-")};return Vn(s)?s:null}if(r&&i===""){const s={provider:i,prefix:"",name:n};return Vn(s,r)?s:null}return null},Vn=(e,t)=>e?!!((t&&e.prefix===""||e.prefix)&&e.name):!1;function Cv(e,t){const r={};!e.hFlip!=!t.hFlip&&(r.hFlip=!0),!e.vFlip!=!t.vFlip&&(r.vFlip=!0);const i=((e.rotate||0)+(t.rotate||0))%4;return i&&(r.rotate=i),r}function dc(e,t){const r=Cv(e,t);for(const i in yv)i in Ga?i in e&&!(i in r)&&(r[i]=Ga[i]):i in t?r[i]=t[i]:i in e&&(r[i]=e[i]);return r}function vv(e,t){const r=e.icons,i=e.aliases||Object.create(null),a=Object.create(null);function n(o){if(r[o])return a[o]=[];if(!(o in a)){a[o]=null;const s=i[o]&&i[o].parent,l=s&&n(s);l&&(a[o]=[s].concat(l))}return a[o]}return(t||Object.keys(r).concat(Object.keys(i))).forEach(n),a}function pc(e,t,r){const i=e.icons,a=e.aliases||Object.create(null);let n={};function o(s){n=dc(i[s]||a[s],n)}return o(t),r.forEach(o),dc(e,n)}function wv(e,t){if(e.icons[t])return pc(e,t,[]);const r=vv(e,[t])[t];return r?pc(e,t,r):null}const Sv=/(-?[0-9.]*[0-9]+[0-9.]*)/g,kv=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function gc(e,t,r){if(t===1)return e;if(r=r||100,typeof e=="number")return Math.ceil(e*t*r)/r;if(typeof e!="string")return e;const i=e.split(Sv);if(i===null||!i.length)return e;const a=[];let n=i.shift(),o=kv.test(n);for(;;){if(o){const s=parseFloat(n);isNaN(s)?a.push(n):a.push(Math.ceil(s*t*r)/r)}else a.push(n);if(n=i.shift(),n===void 0)return a.join("");o=!o}}function Tv(e,t="defs"){let r="";const i=e.indexOf("<"+t);for(;i>=0;){const a=e.indexOf(">",i),n=e.indexOf("</"+t);if(a===-1||n===-1)break;const o=e.indexOf(">",n);if(o===-1)break;r+=e.slice(a+1,n).trim(),e=e.slice(0,i).trim()+e.slice(o+1)}return{defs:r,content:e}}function Lv(e,t){return e?"<defs>"+e+"</defs>"+t:t}function Bv(e,t,r){const i=Tv(e);return Lv(i.defs,t+i.content+r)}const Av=e=>e==="unset"||e==="undefined"||e==="none";function Mv(e,t){const r={...ud,...e},i={...bv,...t},a={left:r.left,top:r.top,width:r.width,height:r.height};let n=r.body;[r,i].forEach(m=>{const y=[],x=m.hFlip,b=m.vFlip;let _=m.rotate;x?b?_+=2:(y.push("translate("+(a.width+a.left).toString()+" "+(0-a.top).toString()+")"),y.push("scale(-1 1)"),a.top=a.left=0):b&&(y.push("translate("+(0-a.left).toString()+" "+(a.height+a.top).toString()+")"),y.push("scale(1 -1)"),a.top=a.left=0);let w;switch(_<0&&(_-=Math.floor(_/4)*4),_=_%4,_){case 1:w=a.height/2+a.top,y.unshift("rotate(90 "+w.toString()+" "+w.toString()+")");break;case 2:y.unshift("rotate(180 "+(a.width/2+a.left).toString()+" "+(a.height/2+a.top).toString()+")");break;case 3:w=a.width/2+a.left,y.unshift("rotate(-90 "+w.toString()+" "+w.toString()+")");break}_%2===1&&(a.left!==a.top&&(w=a.left,a.left=a.top,a.top=w),a.width!==a.height&&(w=a.width,a.width=a.height,a.height=w)),y.length&&(n=Bv(n,'<g transform="'+y.join(" ")+'">',"</g>"))});const o=i.width,s=i.height,l=a.width,c=a.height;let h,u;o===null?(u=s===null?"1em":s==="auto"?c:s,h=gc(u,l/c)):(h=o==="auto"?l:o,u=s===null?gc(h,c/l):s==="auto"?c:s);const f={},d=(m,y)=>{Av(y)||(f[m]=y.toString())};d("width",h),d("height",u);const g=[a.left,a.top,l,c];return f.viewBox=g.join(" "),{attributes:f,viewBox:g,body:n}}const Ev=/\sid="(\S+)"/g,mc=new Map;function $v(e){e=e.replace(/[0-9]+$/,"")||"a";const t=mc.get(e)||0;return mc.set(e,t+1),t?`${e}${t}`:e}function Fv(e){const t=[];let r;for(;r=Ev.exec(e);)t.push(r[1]);if(!t.length)return e;const i="suffix"+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(a=>{const n=$v(a),o=a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+o+')([")]|\\.[a-z])',"g"),"$1"+n+i+"$3")}),e=e.replace(new RegExp(i,"g"),""),e}function Ov(e,t){let r=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const i in t)r+=" "+i+'="'+t[i]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+r+">"+e+"</svg>"}function fd(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var i=Array.from(typeof e=="string"?[e]:e);i[i.length-1]=i[i.length-1].replace(/\r?\n([\t ]*)$/,"");var a=i.reduce(function(s,l){var c=l.match(/\n([\t ]+|(?!\s).)/g);return c?s.concat(c.map(function(h){var u,f;return(f=(u=h.match(/[\t ]/g))===null||u===void 0?void 0:u.length)!==null&&f!==void 0?f:0})):s},[]);if(a.length){var n=new RegExp(`
|
|
114
|
+
[ ]{`+Math.min.apply(Math,a)+"}","g");i=i.map(function(s){return s.replace(n,`
|
|
115
|
+
`)})}i[0]=i[0].replace(/^\r?\n/,"");var o=i[0];return t.forEach(function(s,l){var c=o.match(/(?:^|\n)( *)$/),h=c?c[1]:"",u=s;typeof s=="string"&&s.includes(`
|
|
116
|
+
`)&&(u=String(s).split(`
|
|
117
|
+
`).map(function(f,d){return d===0?f:""+h+f}).join(`
|
|
118
|
+
`)),o+=u+i[l+1]}),o}var Dv={body:'<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',height:80,width:80},Is=new Map,dd=new Map,Iv=p(e=>{for(const t of e){if(!t.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(F.debug("Registering icon pack:",t.name),"loader"in t)dd.set(t.name,t.loader);else if("icons"in t)Is.set(t.name,t.icons);else throw F.error("Invalid icon loader:",t),new Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),pd=p(async(e,t)=>{const r=_v(e,!0,t!==void 0);if(!r)throw new Error(`Invalid icon name: ${e}`);const i=r.prefix||t;if(!i)throw new Error(`Icon name must contain a prefix: ${e}`);let a=Is.get(i);if(!a){const o=dd.get(i);if(!o)throw new Error(`Icon set not found: ${r.prefix}`);try{a={...await o(),prefix:i},Is.set(i,a)}catch(s){throw F.error(s),new Error(`Failed to load icon set: ${r.prefix}`)}}const n=wv(a,r.name);if(!n)throw new Error(`Icon not found: ${e}`);return n},"getRegisteredIconData"),Rv=p(async e=>{try{return await pd(e),!0}catch{return!1}},"isIconAvailable"),qi=p(async(e,t,r)=>{let i;try{i=await pd(e,t?.fallbackPrefix)}catch(o){F.error(o),i=Dv}const a=Mv(i,t),n=Ov(Fv(a.body),{...a.attributes,...r});return Jt(n,Ft())},"getIconSVG");function gd(e,{markdownAutoWrap:t}){const i=e.replace(/<br\/>/g,`
|
|
119
|
+
`).replace(/\n{2,}/g,`
|
|
120
|
+
`),a=fd(i);return t===!1?a.replace(/ /g," "):a}p(gd,"preprocessMarkdown");function md(e,t={}){const r=gd(e,t),i=Wc.lexer(r),a=[[]];let n=0;function o(s,l="normal"){s.type==="text"?s.text.split(`
|
|
121
|
+
`).forEach((h,u)=>{u!==0&&(n++,a.push([])),h.split(" ").forEach(f=>{f=f.replace(/'/g,"'"),f&&a[n].push({content:f,type:l})})}):s.type==="strong"||s.type==="em"?s.tokens.forEach(c=>{o(c,s.type)}):s.type==="html"&&a[n].push({content:s.text,type:"normal"})}return p(o,"processNode"),i.forEach(s=>{s.type==="paragraph"?s.tokens?.forEach(l=>{o(l)}):s.type==="html"?a[n].push({content:s.text,type:"normal"}):a[n].push({content:s.raw,type:"normal"})}),a}p(md,"markdownToLines");function yd(e,{markdownAutoWrap:t}={}){const r=Wc.lexer(e);function i(a){return a.type==="text"?t===!1?a.text.replace(/\n */g,"<br/>").replace(/ /g," "):a.text.replace(/\n */g,"<br/>"):a.type==="strong"?`<strong>${a.tokens?.map(i).join("")}</strong>`:a.type==="em"?`<em>${a.tokens?.map(i).join("")}</em>`:a.type==="paragraph"?`<p>${a.tokens?.map(i).join("")}</p>`:a.type==="space"?"":a.type==="html"?`${a.text}`:a.type==="escape"?a.text:(F.warn(`Unsupported markdown: ${a.type}`),a.raw)}return p(i,"output"),r.map(i).join("")}p(yd,"markdownToHTML");function xd(e){return Intl.Segmenter?[...new Intl.Segmenter().segment(e)].map(t=>t.segment):[...e]}p(xd,"splitTextToChars");function bd(e,t){const r=xd(t.content);return Ro(e,[],r,t.type)}p(bd,"splitWordToFitWidth");function Ro(e,t,r,i){if(r.length===0)return[{content:t.join(""),type:i},{content:"",type:i}];const[a,...n]=r,o=[...t,a];return e([{content:o.join(""),type:i}])?Ro(e,o,n,i):(t.length===0&&a&&(t.push(a),r.shift()),[{content:t.join(""),type:i},{content:r.join(""),type:i}])}p(Ro,"splitWordToFitWidthRecursion");function _d(e,t){if(e.some(({content:r})=>r.includes(`
|
|
122
|
+
`)))throw new Error("splitLineToFitWidth does not support newlines in the line");return Va(e,t)}p(_d,"splitLineToFitWidth");function Va(e,t,r=[],i=[]){if(e.length===0)return i.length>0&&r.push(i),r.length>0?r:[];let a="";e[0].content===" "&&(a=" ",e.shift());const n=e.shift()??{content:" ",type:"normal"},o=[...i];if(a!==""&&o.push({content:a,type:"normal"}),o.push(n),t(o))return Va(e,t,r,o);if(i.length>0)r.push(i),e.unshift(n);else if(n.content){const[s,l]=bd(t,n);r.push([s]),l.content&&e.unshift(l)}return Va(e,t,r)}p(Va,"splitLineToFitWidthRecursion");function Rs(e,t){t&&e.attr("style",t)}p(Rs,"applyStyle");async function Cd(e,t,r,i,a=!1,n=Ft()){const o=e.append("foreignObject");o.attr("width",`${10*r}px`),o.attr("height",`${10*r}px`);const s=o.append("xhtml:div"),l=Pr(t.label)?await to(t.label.replace(Yr.lineBreakRegex,`
|
|
123
|
+
`),n):Jt(t.label,n),c=t.isNode?"nodeLabel":"edgeLabel",h=s.append("span");h.html(l),Rs(h,t.labelStyle),h.attr("class",`${c} ${i}`),Rs(s,t.labelStyle),s.style("display","table-cell"),s.style("white-space","nowrap"),s.style("line-height","1.5"),s.style("max-width",r+"px"),s.style("text-align","center"),s.attr("xmlns","http://www.w3.org/1999/xhtml"),a&&s.attr("class","labelBkg");let u=s.node().getBoundingClientRect();return u.width===r&&(s.style("display","table"),s.style("white-space","break-spaces"),s.style("width",r+"px"),u=s.node().getBoundingClientRect()),o.node()}p(Cd,"addHtmlSpan");function bn(e,t,r){return e.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",t*r-.1+"em").attr("dy",r+"em")}p(bn,"createTspan");function vd(e,t,r){const i=e.append("text"),a=bn(i,1,t);_n(a,r);const n=a.node().getComputedTextLength();return i.remove(),n}p(vd,"computeWidthOfText");function Pv(e,t,r){const i=e.append("text"),a=bn(i,1,t);_n(a,[{content:r,type:"normal"}]);const n=a.node()?.getBoundingClientRect();return n&&i.remove(),n}p(Pv,"computeDimensionOfText");function wd(e,t,r,i=!1){const n=t.append("g"),o=n.insert("rect").attr("class","background").attr("style","stroke: none"),s=n.append("text").attr("y","-10.1");let l=0;for(const c of r){const h=p(f=>vd(n,1.1,f)<=e,"checkWidth"),u=h(c)?[c]:_d(c,h);for(const f of u){const d=bn(s,l,1.1);_n(d,f),l++}}if(i){const c=s.node().getBBox(),h=2;return o.attr("x",c.x-h).attr("y",c.y-h).attr("width",c.width+2*h).attr("height",c.height+2*h),n.node()}else return s.node()}p(wd,"createFormattedText");function _n(e,t){e.text(""),t.forEach((r,i)=>{const a=e.append("tspan").attr("font-style",r.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",r.type==="strong"?"bold":"normal");i===0?a.text(r.content):a.text(" "+r.content)})}p(_n,"updateTextContentAndStyles");async function Sd(e,t={}){const r=[];e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(a,n,o)=>(r.push((async()=>{const s=`${n}:${o}`;return await Rv(s)?await qi(s,void 0,{class:"label-icon"}):`<i class='${Jt(a,t).replace(":"," ")}'></i>`})()),a));const i=await Promise.all(r);return e.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>i.shift()??"")}p(Sd,"replaceIconSubstring");var qe=p(async(e,t="",{style:r="",isTitle:i=!1,classes:a="",useHtmlLabels:n=!0,isNode:o=!0,width:s=200,addSvgBackground:l=!1}={},c)=>{if(F.debug("XYZ createText",t,r,i,a,n,o,"addSvgBackground: ",l),n){const h=yd(t,c),u=await Sd(dr(h),c),f=t.replace(/\\\\/g,"\\"),d={isNode:o,label:Pr(t)?f:u,labelStyle:r.replace("fill:","color:")};return await Cd(e,d,s,a,l,c)}else{const h=t.replace(/<br\s*\/?>/g,"<br/>"),u=md(h.replace("<br>","<br/>"),c),f=wd(s,e,u,t?l:!1);if(o){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));const d=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");ht(f).attr("style",d)}else{const d=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");ht(f).select("rect").attr("style",d.replace(/background:/g,"fill:"));const g=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");ht(f).select("text").attr("style",g)}return f}},"createText");function Xn(e,t,r){if(e&&e.length){const[i,a]=t,n=Math.PI/180*r,o=Math.cos(n),s=Math.sin(n);for(const l of e){const[c,h]=l;l[0]=(c-i)*o-(h-a)*s+i,l[1]=(c-i)*s+(h-a)*o+a}}}function Nv(e,t){return e[0]===t[0]&&e[1]===t[1]}function Wv(e,t,r,i=1){const a=r,n=Math.max(t,.1),o=e[0]&&e[0][0]&&typeof e[0][0]=="number"?[e]:e,s=[0,0];if(a)for(const c of o)Xn(c,s,a);const l=(function(c,h,u){const f=[];for(const b of c){const _=[...b];Nv(_[0],_[_.length-1])||_.push([_[0][0],_[0][1]]),_.length>2&&f.push(_)}const d=[];h=Math.max(h,.1);const g=[];for(const b of f)for(let _=0;_<b.length-1;_++){const w=b[_],v=b[_+1];if(w[1]!==v[1]){const B=Math.min(w[1],v[1]);g.push({ymin:B,ymax:Math.max(w[1],v[1]),x:B===w[1]?w[0]:v[0],islope:(v[0]-w[0])/(v[1]-w[1])})}}if(g.sort(((b,_)=>b.ymin<_.ymin?-1:b.ymin>_.ymin?1:b.x<_.x?-1:b.x>_.x?1:b.ymax===_.ymax?0:(b.ymax-_.ymax)/Math.abs(b.ymax-_.ymax))),!g.length)return d;let m=[],y=g[0].ymin,x=0;for(;m.length||g.length;){if(g.length){let b=-1;for(let _=0;_<g.length&&!(g[_].ymin>y);_++)b=_;g.splice(0,b+1).forEach((_=>{m.push({s:y,edge:_})}))}if(m=m.filter((b=>!(b.edge.ymax<=y))),m.sort(((b,_)=>b.edge.x===_.edge.x?0:(b.edge.x-_.edge.x)/Math.abs(b.edge.x-_.edge.x))),(u!==1||x%h==0)&&m.length>1)for(let b=0;b<m.length;b+=2){const _=b+1;if(_>=m.length)break;const w=m[b].edge,v=m[_].edge;d.push([[Math.round(w.x),y],[Math.round(v.x),y]])}y+=u,m.forEach((b=>{b.edge.x=b.edge.x+u*b.edge.islope})),x++}return d})(o,n,i);if(a){for(const c of o)Xn(c,s,-a);(function(c,h,u){const f=[];c.forEach((d=>f.push(...d))),Xn(f,h,u)})(l,s,-a)}return l}function Hi(e,t){var r;const i=t.hachureAngle+90;let a=t.hachureGap;a<0&&(a=4*t.strokeWidth),a=Math.round(Math.max(a,.1));let n=1;return t.roughness>=1&&(((r=t.randomizer)===null||r===void 0?void 0:r.next())||Math.random())>.7&&(n=a),Wv(e,a,i,n||1)}class Po{constructor(t){this.helper=t}fillPolygons(t,r){return this._fillPolygons(t,r)}_fillPolygons(t,r){const i=Hi(t,r);return{type:"fillSketch",ops:this.renderLines(i,r)}}renderLines(t,r){const i=[];for(const a of t)i.push(...this.helper.doubleLineOps(a[0][0],a[0][1],a[1][0],a[1][1],r));return i}}function Cn(e){const t=e[0],r=e[1];return Math.sqrt(Math.pow(t[0]-r[0],2)+Math.pow(t[1]-r[1],2))}class zv extends Po{fillPolygons(t,r){let i=r.hachureGap;i<0&&(i=4*r.strokeWidth),i=Math.max(i,.1);const a=Hi(t,Object.assign({},r,{hachureGap:i})),n=Math.PI/180*r.hachureAngle,o=[],s=.5*i*Math.cos(n),l=.5*i*Math.sin(n);for(const[c,h]of a)Cn([c,h])&&o.push([[c[0]-s,c[1]+l],[...h]],[[c[0]+s,c[1]-l],[...h]]);return{type:"fillSketch",ops:this.renderLines(o,r)}}}class qv extends Po{fillPolygons(t,r){const i=this._fillPolygons(t,r),a=Object.assign({},r,{hachureAngle:r.hachureAngle+90}),n=this._fillPolygons(t,a);return i.ops=i.ops.concat(n.ops),i}}class Hv{constructor(t){this.helper=t}fillPolygons(t,r){const i=Hi(t,r=Object.assign({},r,{hachureAngle:0}));return this.dotsOnLines(i,r)}dotsOnLines(t,r){const i=[];let a=r.hachureGap;a<0&&(a=4*r.strokeWidth),a=Math.max(a,.1);let n=r.fillWeight;n<0&&(n=r.strokeWidth/2);const o=a/4;for(const s of t){const l=Cn(s),c=l/a,h=Math.ceil(c)-1,u=l-h*a,f=(s[0][0]+s[1][0])/2-a/4,d=Math.min(s[0][1],s[1][1]);for(let g=0;g<h;g++){const m=d+u+g*a,y=f-o+2*Math.random()*o,x=m-o+2*Math.random()*o,b=this.helper.ellipse(y,x,n,n,r);i.push(...b.ops)}}return{type:"fillSketch",ops:i}}}class jv{constructor(t){this.helper=t}fillPolygons(t,r){const i=Hi(t,r);return{type:"fillSketch",ops:this.dashedLine(i,r)}}dashedLine(t,r){const i=r.dashOffset<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashOffset,a=r.dashGap<0?r.hachureGap<0?4*r.strokeWidth:r.hachureGap:r.dashGap,n=[];return t.forEach((o=>{const s=Cn(o),l=Math.floor(s/(i+a)),c=(s+a-l*(i+a))/2;let h=o[0],u=o[1];h[0]>u[0]&&(h=o[1],u=o[0]);const f=Math.atan((u[1]-h[1])/(u[0]-h[0]));for(let d=0;d<l;d++){const g=d*(i+a),m=g+i,y=[h[0]+g*Math.cos(f)+c*Math.cos(f),h[1]+g*Math.sin(f)+c*Math.sin(f)],x=[h[0]+m*Math.cos(f)+c*Math.cos(f),h[1]+m*Math.sin(f)+c*Math.sin(f)];n.push(...this.helper.doubleLineOps(y[0],y[1],x[0],x[1],r))}})),n}}class Yv{constructor(t){this.helper=t}fillPolygons(t,r){const i=r.hachureGap<0?4*r.strokeWidth:r.hachureGap,a=r.zigzagOffset<0?i:r.zigzagOffset,n=Hi(t,r=Object.assign({},r,{hachureGap:i+a}));return{type:"fillSketch",ops:this.zigzagLines(n,a,r)}}zigzagLines(t,r,i){const a=[];return t.forEach((n=>{const o=Cn(n),s=Math.round(o/(2*r));let l=n[0],c=n[1];l[0]>c[0]&&(l=n[1],c=n[0]);const h=Math.atan((c[1]-l[1])/(c[0]-l[0]));for(let u=0;u<s;u++){const f=2*u*r,d=2*(u+1)*r,g=Math.sqrt(2*Math.pow(r,2)),m=[l[0]+f*Math.cos(h),l[1]+f*Math.sin(h)],y=[l[0]+d*Math.cos(h),l[1]+d*Math.sin(h)],x=[m[0]+g*Math.cos(h+Math.PI/4),m[1]+g*Math.sin(h+Math.PI/4)];a.push(...this.helper.doubleLineOps(m[0],m[1],x[0],x[1],i),...this.helper.doubleLineOps(x[0],x[1],y[0],y[1],i))}})),a}}const Ht={};class Uv{constructor(t){this.seed=t}next(){return this.seed?(2**31-1&(this.seed=Math.imul(48271,this.seed)))/2**31:Math.random()}}const Gv=0,Kn=1,yc=2,ra={A:7,a:7,C:6,c:6,H:1,h:1,L:2,l:2,M:2,m:2,Q:4,q:4,S:4,s:4,T:2,t:2,V:1,v:1,Z:0,z:0};function Zn(e,t){return e.type===t}function No(e){const t=[],r=(function(o){const s=new Array;for(;o!=="";)if(o.match(/^([ \t\r\n,]+)/))o=o.substr(RegExp.$1.length);else if(o.match(/^([aAcChHlLmMqQsStTvVzZ])/))s[s.length]={type:Gv,text:RegExp.$1},o=o.substr(RegExp.$1.length);else{if(!o.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];s[s.length]={type:Kn,text:`${parseFloat(RegExp.$1)}`},o=o.substr(RegExp.$1.length)}return s[s.length]={type:yc,text:""},s})(e);let i="BOD",a=0,n=r[a];for(;!Zn(n,yc);){let o=0;const s=[];if(i==="BOD"){if(n.text!=="M"&&n.text!=="m")return No("M0,0"+e);a++,o=ra[n.text],i=n.text}else Zn(n,Kn)?o=ra[i]:(a++,o=ra[n.text],i=n.text);if(!(a+o<r.length))throw new Error("Path data ended short");for(let l=a;l<a+o;l++){const c=r[l];if(!Zn(c,Kn))throw new Error("Param not a number: "+i+","+c.text);s[s.length]=+c.text}if(typeof ra[i]!="number")throw new Error("Bad segment: "+i);{const l={key:i,data:s};t.push(l),a+=o,n=r[a],i==="M"&&(i="L"),i==="m"&&(i="l")}}return t}function kd(e){let t=0,r=0,i=0,a=0;const n=[];for(const{key:o,data:s}of e)switch(o){case"M":n.push({key:"M",data:[...s]}),[t,r]=s,[i,a]=s;break;case"m":t+=s[0],r+=s[1],n.push({key:"M",data:[t,r]}),i=t,a=r;break;case"L":n.push({key:"L",data:[...s]}),[t,r]=s;break;case"l":t+=s[0],r+=s[1],n.push({key:"L",data:[t,r]});break;case"C":n.push({key:"C",data:[...s]}),t=s[4],r=s[5];break;case"c":{const l=s.map(((c,h)=>h%2?c+r:c+t));n.push({key:"C",data:l}),t=l[4],r=l[5];break}case"Q":n.push({key:"Q",data:[...s]}),t=s[2],r=s[3];break;case"q":{const l=s.map(((c,h)=>h%2?c+r:c+t));n.push({key:"Q",data:l}),t=l[2],r=l[3];break}case"A":n.push({key:"A",data:[...s]}),t=s[5],r=s[6];break;case"a":t+=s[5],r+=s[6],n.push({key:"A",data:[s[0],s[1],s[2],s[3],s[4],t,r]});break;case"H":n.push({key:"H",data:[...s]}),t=s[0];break;case"h":t+=s[0],n.push({key:"H",data:[t]});break;case"V":n.push({key:"V",data:[...s]}),r=s[0];break;case"v":r+=s[0],n.push({key:"V",data:[r]});break;case"S":n.push({key:"S",data:[...s]}),t=s[2],r=s[3];break;case"s":{const l=s.map(((c,h)=>h%2?c+r:c+t));n.push({key:"S",data:l}),t=l[2],r=l[3];break}case"T":n.push({key:"T",data:[...s]}),t=s[0],r=s[1];break;case"t":t+=s[0],r+=s[1],n.push({key:"T",data:[t,r]});break;case"Z":case"z":n.push({key:"Z",data:[]}),t=i,r=a}return n}function Td(e){const t=[];let r="",i=0,a=0,n=0,o=0,s=0,l=0;for(const{key:c,data:h}of e){switch(c){case"M":t.push({key:"M",data:[...h]}),[i,a]=h,[n,o]=h;break;case"C":t.push({key:"C",data:[...h]}),i=h[4],a=h[5],s=h[2],l=h[3];break;case"L":t.push({key:"L",data:[...h]}),[i,a]=h;break;case"H":i=h[0],t.push({key:"L",data:[i,a]});break;case"V":a=h[0],t.push({key:"L",data:[i,a]});break;case"S":{let u=0,f=0;r==="C"||r==="S"?(u=i+(i-s),f=a+(a-l)):(u=i,f=a),t.push({key:"C",data:[u,f,...h]}),s=h[0],l=h[1],i=h[2],a=h[3];break}case"T":{const[u,f]=h;let d=0,g=0;r==="Q"||r==="T"?(d=i+(i-s),g=a+(a-l)):(d=i,g=a);const m=i+2*(d-i)/3,y=a+2*(g-a)/3,x=u+2*(d-u)/3,b=f+2*(g-f)/3;t.push({key:"C",data:[m,y,x,b,u,f]}),s=d,l=g,i=u,a=f;break}case"Q":{const[u,f,d,g]=h,m=i+2*(u-i)/3,y=a+2*(f-a)/3,x=d+2*(u-d)/3,b=g+2*(f-g)/3;t.push({key:"C",data:[m,y,x,b,d,g]}),s=u,l=f,i=d,a=g;break}case"A":{const u=Math.abs(h[0]),f=Math.abs(h[1]),d=h[2],g=h[3],m=h[4],y=h[5],x=h[6];u===0||f===0?(t.push({key:"C",data:[i,a,y,x,y,x]}),i=y,a=x):(i!==y||a!==x)&&(Ld(i,a,y,x,u,f,d,g,m).forEach((function(b){t.push({key:"C",data:b})})),i=y,a=x);break}case"Z":t.push({key:"Z",data:[]}),i=n,a=o}r=c}return t}function oi(e,t,r){return[e*Math.cos(r)-t*Math.sin(r),e*Math.sin(r)+t*Math.cos(r)]}function Ld(e,t,r,i,a,n,o,s,l,c){const h=(u=o,Math.PI*u/180);var u;let f=[],d=0,g=0,m=0,y=0;if(c)[d,g,m,y]=c;else{[e,t]=oi(e,t,-h),[r,i]=oi(r,i,-h);const I=(e-r)/2,L=(t-i)/2;let A=I*I/(a*a)+L*L/(n*n);A>1&&(A=Math.sqrt(A),a*=A,n*=A);const k=a*a,$=n*n,M=k*$-k*L*L-$*I*I,q=k*L*L+$*I*I,V=(s===l?-1:1)*Math.sqrt(Math.abs(M/q));m=V*a*L/n+(e+r)/2,y=V*-n*I/a+(t+i)/2,d=Math.asin(parseFloat(((t-y)/n).toFixed(9))),g=Math.asin(parseFloat(((i-y)/n).toFixed(9))),e<m&&(d=Math.PI-d),r<m&&(g=Math.PI-g),d<0&&(d=2*Math.PI+d),g<0&&(g=2*Math.PI+g),l&&d>g&&(d-=2*Math.PI),!l&&g>d&&(g-=2*Math.PI)}let x=g-d;if(Math.abs(x)>120*Math.PI/180){const I=g,L=r,A=i;g=l&&g>d?d+120*Math.PI/180*1:d+120*Math.PI/180*-1,f=Ld(r=m+a*Math.cos(g),i=y+n*Math.sin(g),L,A,a,n,o,0,l,[g,I,m,y])}x=g-d;const b=Math.cos(d),_=Math.sin(d),w=Math.cos(g),v=Math.sin(g),B=Math.tan(x/4),T=4/3*a*B,O=4/3*n*B,R=[e,t],D=[e+T*_,t-O*b],E=[r+T*v,i-O*w],N=[r,i];if(D[0]=2*R[0]-D[0],D[1]=2*R[1]-D[1],c)return[D,E,N].concat(f);{f=[D,E,N].concat(f);const I=[];for(let L=0;L<f.length;L+=3){const A=oi(f[L][0],f[L][1],h),k=oi(f[L+1][0],f[L+1][1],h),$=oi(f[L+2][0],f[L+2][1],h);I.push([A[0],A[1],k[0],k[1],$[0],$[1]])}return I}}const Vv={randOffset:function(e,t){return at(e,t)},randOffsetWithRange:function(e,t,r){return Xa(e,t,r)},ellipse:function(e,t,r,i,a){const n=Ad(r,i,a);return Ps(e,t,a,n).opset},doubleLineOps:function(e,t,r,i,a){return Ne(e,t,r,i,a,!0)}};function Bd(e,t,r,i,a){return{type:"path",ops:Ne(e,t,r,i,a)}}function ya(e,t,r){const i=(e||[]).length;if(i>2){const a=[];for(let n=0;n<i-1;n++)a.push(...Ne(e[n][0],e[n][1],e[n+1][0],e[n+1][1],r));return t&&a.push(...Ne(e[i-1][0],e[i-1][1],e[0][0],e[0][1],r)),{type:"path",ops:a}}return i===2?Bd(e[0][0],e[0][1],e[1][0],e[1][1],r):{type:"path",ops:[]}}function Xv(e,t,r,i,a){return(function(n,o){return ya(n,!0,o)})([[e,t],[e+r,t],[e+r,t+i],[e,t+i]],a)}function xc(e,t){if(e.length){const r=typeof e[0][0]=="number"?[e]:e,i=ia(r[0],1*(1+.2*t.roughness),t),a=t.disableMultiStroke?[]:ia(r[0],1.5*(1+.22*t.roughness),Cc(t));for(let n=1;n<r.length;n++){const o=r[n];if(o.length){const s=ia(o,1*(1+.2*t.roughness),t),l=t.disableMultiStroke?[]:ia(o,1.5*(1+.22*t.roughness),Cc(t));for(const c of s)c.op!=="move"&&i.push(c);for(const c of l)c.op!=="move"&&a.push(c)}}return{type:"path",ops:i.concat(a)}}return{type:"path",ops:[]}}function Ad(e,t,r){const i=Math.sqrt(2*Math.PI*Math.sqrt((Math.pow(e/2,2)+Math.pow(t/2,2))/2)),a=Math.ceil(Math.max(r.curveStepCount,r.curveStepCount/Math.sqrt(200)*i)),n=2*Math.PI/a;let o=Math.abs(e/2),s=Math.abs(t/2);const l=1-r.curveFitting;return o+=at(o*l,r),s+=at(s*l,r),{increment:n,rx:o,ry:s}}function Ps(e,t,r,i){const[a,n]=vc(i.increment,e,t,i.rx,i.ry,1,i.increment*Xa(.1,Xa(.4,1,r),r),r);let o=Ka(a,null,r);if(!r.disableMultiStroke&&r.roughness!==0){const[s]=vc(i.increment,e,t,i.rx,i.ry,1.5,0,r),l=Ka(s,null,r);o=o.concat(l)}return{estimatedPoints:n,opset:{type:"path",ops:o}}}function bc(e,t,r,i,a,n,o,s,l){const c=e,h=t;let u=Math.abs(r/2),f=Math.abs(i/2);u+=at(.01*u,l),f+=at(.01*f,l);let d=a,g=n;for(;d<0;)d+=2*Math.PI,g+=2*Math.PI;g-d>2*Math.PI&&(d=0,g=2*Math.PI);const m=2*Math.PI/l.curveStepCount,y=Math.min(m/2,(g-d)/2),x=wc(y,c,h,u,f,d,g,1,l);if(!l.disableMultiStroke){const b=wc(y,c,h,u,f,d,g,1.5,l);x.push(...b)}return o&&(s?x.push(...Ne(c,h,c+u*Math.cos(d),h+f*Math.sin(d),l),...Ne(c,h,c+u*Math.cos(g),h+f*Math.sin(g),l)):x.push({op:"lineTo",data:[c,h]},{op:"lineTo",data:[c+u*Math.cos(d),h+f*Math.sin(d)]})),{type:"path",ops:x}}function _c(e,t){const r=Td(kd(No(e))),i=[];let a=[0,0],n=[0,0];for(const{key:o,data:s}of r)switch(o){case"M":n=[s[0],s[1]],a=[s[0],s[1]];break;case"L":i.push(...Ne(n[0],n[1],s[0],s[1],t)),n=[s[0],s[1]];break;case"C":{const[l,c,h,u,f,d]=s;i.push(...Kv(l,c,h,u,f,d,n,t)),n=[f,d];break}case"Z":i.push(...Ne(n[0],n[1],a[0],a[1],t)),n=[a[0],a[1]]}return{type:"path",ops:i}}function Qn(e,t){const r=[];for(const i of e)if(i.length){const a=t.maxRandomnessOffset||0,n=i.length;if(n>2){r.push({op:"move",data:[i[0][0]+at(a,t),i[0][1]+at(a,t)]});for(let o=1;o<n;o++)r.push({op:"lineTo",data:[i[o][0]+at(a,t),i[o][1]+at(a,t)]})}}return{type:"fillPath",ops:r}}function Cr(e,t){return(function(r,i){let a=r.fillStyle||"hachure";if(!Ht[a])switch(a){case"zigzag":Ht[a]||(Ht[a]=new zv(i));break;case"cross-hatch":Ht[a]||(Ht[a]=new qv(i));break;case"dots":Ht[a]||(Ht[a]=new Hv(i));break;case"dashed":Ht[a]||(Ht[a]=new jv(i));break;case"zigzag-line":Ht[a]||(Ht[a]=new Yv(i));break;default:a="hachure",Ht[a]||(Ht[a]=new Po(i))}return Ht[a]})(t,Vv).fillPolygons(e,t)}function Cc(e){const t=Object.assign({},e);return t.randomizer=void 0,e.seed&&(t.seed=e.seed+1),t}function Md(e){return e.randomizer||(e.randomizer=new Uv(e.seed||0)),e.randomizer.next()}function Xa(e,t,r,i=1){return r.roughness*i*(Md(r)*(t-e)+e)}function at(e,t,r=1){return Xa(-e,e,t,r)}function Ne(e,t,r,i,a,n=!1){const o=n?a.disableMultiStrokeFill:a.disableMultiStroke,s=Ns(e,t,r,i,a,!0,!1);if(o)return s;const l=Ns(e,t,r,i,a,!0,!0);return s.concat(l)}function Ns(e,t,r,i,a,n,o){const s=Math.pow(e-r,2)+Math.pow(t-i,2),l=Math.sqrt(s);let c=1;c=l<200?1:l>500?.4:-.0016668*l+1.233334;let h=a.maxRandomnessOffset||0;h*h*100>s&&(h=l/10);const u=h/2,f=.2+.2*Md(a);let d=a.bowing*a.maxRandomnessOffset*(i-t)/200,g=a.bowing*a.maxRandomnessOffset*(e-r)/200;d=at(d,a,c),g=at(g,a,c);const m=[],y=()=>at(u,a,c),x=()=>at(h,a,c),b=a.preserveVertices;return o?m.push({op:"move",data:[e+(b?0:y()),t+(b?0:y())]}):m.push({op:"move",data:[e+(b?0:at(h,a,c)),t+(b?0:at(h,a,c))]}),o?m.push({op:"bcurveTo",data:[d+e+(r-e)*f+y(),g+t+(i-t)*f+y(),d+e+2*(r-e)*f+y(),g+t+2*(i-t)*f+y(),r+(b?0:y()),i+(b?0:y())]}):m.push({op:"bcurveTo",data:[d+e+(r-e)*f+x(),g+t+(i-t)*f+x(),d+e+2*(r-e)*f+x(),g+t+2*(i-t)*f+x(),r+(b?0:x()),i+(b?0:x())]}),m}function ia(e,t,r){if(!e.length)return[];const i=[];i.push([e[0][0]+at(t,r),e[0][1]+at(t,r)]),i.push([e[0][0]+at(t,r),e[0][1]+at(t,r)]);for(let a=1;a<e.length;a++)i.push([e[a][0]+at(t,r),e[a][1]+at(t,r)]),a===e.length-1&&i.push([e[a][0]+at(t,r),e[a][1]+at(t,r)]);return Ka(i,null,r)}function Ka(e,t,r){const i=e.length,a=[];if(i>3){const n=[],o=1-r.curveTightness;a.push({op:"move",data:[e[1][0],e[1][1]]});for(let s=1;s+2<i;s++){const l=e[s];n[0]=[l[0],l[1]],n[1]=[l[0]+(o*e[s+1][0]-o*e[s-1][0])/6,l[1]+(o*e[s+1][1]-o*e[s-1][1])/6],n[2]=[e[s+1][0]+(o*e[s][0]-o*e[s+2][0])/6,e[s+1][1]+(o*e[s][1]-o*e[s+2][1])/6],n[3]=[e[s+1][0],e[s+1][1]],a.push({op:"bcurveTo",data:[n[1][0],n[1][1],n[2][0],n[2][1],n[3][0],n[3][1]]})}}else i===3?(a.push({op:"move",data:[e[1][0],e[1][1]]}),a.push({op:"bcurveTo",data:[e[1][0],e[1][1],e[2][0],e[2][1],e[2][0],e[2][1]]})):i===2&&a.push(...Ns(e[0][0],e[0][1],e[1][0],e[1][1],r,!0,!0));return a}function vc(e,t,r,i,a,n,o,s){const l=[],c=[];if(s.roughness===0){e/=4,c.push([t+i*Math.cos(-e),r+a*Math.sin(-e)]);for(let h=0;h<=2*Math.PI;h+=e){const u=[t+i*Math.cos(h),r+a*Math.sin(h)];l.push(u),c.push(u)}c.push([t+i*Math.cos(0),r+a*Math.sin(0)]),c.push([t+i*Math.cos(e),r+a*Math.sin(e)])}else{const h=at(.5,s)-Math.PI/2;c.push([at(n,s)+t+.9*i*Math.cos(h-e),at(n,s)+r+.9*a*Math.sin(h-e)]);const u=2*Math.PI+h-.01;for(let f=h;f<u;f+=e){const d=[at(n,s)+t+i*Math.cos(f),at(n,s)+r+a*Math.sin(f)];l.push(d),c.push(d)}c.push([at(n,s)+t+i*Math.cos(h+2*Math.PI+.5*o),at(n,s)+r+a*Math.sin(h+2*Math.PI+.5*o)]),c.push([at(n,s)+t+.98*i*Math.cos(h+o),at(n,s)+r+.98*a*Math.sin(h+o)]),c.push([at(n,s)+t+.9*i*Math.cos(h+.5*o),at(n,s)+r+.9*a*Math.sin(h+.5*o)])}return[c,l]}function wc(e,t,r,i,a,n,o,s,l){const c=n+at(.1,l),h=[];h.push([at(s,l)+t+.9*i*Math.cos(c-e),at(s,l)+r+.9*a*Math.sin(c-e)]);for(let u=c;u<=o;u+=e)h.push([at(s,l)+t+i*Math.cos(u),at(s,l)+r+a*Math.sin(u)]);return h.push([t+i*Math.cos(o),r+a*Math.sin(o)]),h.push([t+i*Math.cos(o),r+a*Math.sin(o)]),Ka(h,null,l)}function Kv(e,t,r,i,a,n,o,s){const l=[],c=[s.maxRandomnessOffset||1,(s.maxRandomnessOffset||1)+.3];let h=[0,0];const u=s.disableMultiStroke?1:2,f=s.preserveVertices;for(let d=0;d<u;d++)d===0?l.push({op:"move",data:[o[0],o[1]]}):l.push({op:"move",data:[o[0]+(f?0:at(c[0],s)),o[1]+(f?0:at(c[0],s))]}),h=f?[a,n]:[a+at(c[d],s),n+at(c[d],s)],l.push({op:"bcurveTo",data:[e+at(c[d],s),t+at(c[d],s),r+at(c[d],s),i+at(c[d],s),h[0],h[1]]});return l}function li(e){return[...e]}function Sc(e,t=0){const r=e.length;if(r<3)throw new Error("A curve must have at least three points.");const i=[];if(r===3)i.push(li(e[0]),li(e[1]),li(e[2]),li(e[2]));else{const a=[];a.push(e[0],e[0]);for(let s=1;s<e.length;s++)a.push(e[s]),s===e.length-1&&a.push(e[s]);const n=[],o=1-t;i.push(li(a[0]));for(let s=1;s+2<a.length;s++){const l=a[s];n[0]=[l[0],l[1]],n[1]=[l[0]+(o*a[s+1][0]-o*a[s-1][0])/6,l[1]+(o*a[s+1][1]-o*a[s-1][1])/6],n[2]=[a[s+1][0]+(o*a[s][0]-o*a[s+2][0])/6,a[s+1][1]+(o*a[s][1]-o*a[s+2][1])/6],n[3]=[a[s+1][0],a[s+1][1]],i.push(n[1],n[2],n[3])}}return i}function xa(e,t){return Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)}function Zv(e,t,r){const i=xa(t,r);if(i===0)return xa(e,t);let a=((e[0]-t[0])*(r[0]-t[0])+(e[1]-t[1])*(r[1]-t[1]))/i;return a=Math.max(0,Math.min(1,a)),xa(e,Xe(t,r,a))}function Xe(e,t,r){return[e[0]+(t[0]-e[0])*r,e[1]+(t[1]-e[1])*r]}function Ws(e,t,r,i){const a=i||[];if((function(s,l){const c=s[l+0],h=s[l+1],u=s[l+2],f=s[l+3];let d=3*h[0]-2*c[0]-f[0];d*=d;let g=3*h[1]-2*c[1]-f[1];g*=g;let m=3*u[0]-2*f[0]-c[0];m*=m;let y=3*u[1]-2*f[1]-c[1];return y*=y,d<m&&(d=m),g<y&&(g=y),d+g})(e,t)<r){const s=e[t+0];a.length?(n=a[a.length-1],o=s,Math.sqrt(xa(n,o))>1&&a.push(s)):a.push(s),a.push(e[t+3])}else{const l=e[t+0],c=e[t+1],h=e[t+2],u=e[t+3],f=Xe(l,c,.5),d=Xe(c,h,.5),g=Xe(h,u,.5),m=Xe(f,d,.5),y=Xe(d,g,.5),x=Xe(m,y,.5);Ws([l,f,m,x],0,r,a),Ws([x,y,g,u],0,r,a)}var n,o;return a}function Qv(e,t){return Za(e,0,e.length,t)}function Za(e,t,r,i,a){const n=a||[],o=e[t],s=e[r-1];let l=0,c=1;for(let h=t+1;h<r-1;++h){const u=Zv(e[h],o,s);u>l&&(l=u,c=h)}return Math.sqrt(l)>i?(Za(e,t,c+1,i,n),Za(e,c,r,i,n)):(n.length||n.push(o),n.push(s)),n}function Jn(e,t=.15,r){const i=[],a=(e.length-1)/3;for(let n=0;n<a;n++)Ws(e,3*n,t,i);return r&&r>0?Za(i,0,i.length,r):i}const Gt="none";class Qa{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,r,i){return{shape:t,sets:r||[],options:i||this.defaultOptions}}line(t,r,i,a,n){const o=this._o(n);return this._d("line",[Bd(t,r,i,a,o)],o)}rectangle(t,r,i,a,n){const o=this._o(n),s=[],l=Xv(t,r,i,a,o);if(o.fill){const c=[[t,r],[t+i,r],[t+i,r+a],[t,r+a]];o.fillStyle==="solid"?s.push(Qn([c],o)):s.push(Cr([c],o))}return o.stroke!==Gt&&s.push(l),this._d("rectangle",s,o)}ellipse(t,r,i,a,n){const o=this._o(n),s=[],l=Ad(i,a,o),c=Ps(t,r,o,l);if(o.fill)if(o.fillStyle==="solid"){const h=Ps(t,r,o,l).opset;h.type="fillPath",s.push(h)}else s.push(Cr([c.estimatedPoints],o));return o.stroke!==Gt&&s.push(c.opset),this._d("ellipse",s,o)}circle(t,r,i,a){const n=this.ellipse(t,r,i,i,a);return n.shape="circle",n}linearPath(t,r){const i=this._o(r);return this._d("linearPath",[ya(t,!1,i)],i)}arc(t,r,i,a,n,o,s=!1,l){const c=this._o(l),h=[],u=bc(t,r,i,a,n,o,s,!0,c);if(s&&c.fill)if(c.fillStyle==="solid"){const f=Object.assign({},c);f.disableMultiStroke=!0;const d=bc(t,r,i,a,n,o,!0,!1,f);d.type="fillPath",h.push(d)}else h.push((function(f,d,g,m,y,x,b){const _=f,w=d;let v=Math.abs(g/2),B=Math.abs(m/2);v+=at(.01*v,b),B+=at(.01*B,b);let T=y,O=x;for(;T<0;)T+=2*Math.PI,O+=2*Math.PI;O-T>2*Math.PI&&(T=0,O=2*Math.PI);const R=(O-T)/b.curveStepCount,D=[];for(let E=T;E<=O;E+=R)D.push([_+v*Math.cos(E),w+B*Math.sin(E)]);return D.push([_+v*Math.cos(O),w+B*Math.sin(O)]),D.push([_,w]),Cr([D],b)})(t,r,i,a,n,o,c));return c.stroke!==Gt&&h.push(u),this._d("arc",h,c)}curve(t,r){const i=this._o(r),a=[],n=xc(t,i);if(i.fill&&i.fill!==Gt)if(i.fillStyle==="solid"){const o=xc(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(o.ops)})}else{const o=[],s=t;if(s.length){const l=typeof s[0][0]=="number"?[s]:s;for(const c of l)c.length<3?o.push(...c):c.length===3?o.push(...Jn(Sc([c[0],c[0],c[1],c[2]]),10,(1+i.roughness)/2)):o.push(...Jn(Sc(c),10,(1+i.roughness)/2))}o.length&&a.push(Cr([o],i))}return i.stroke!==Gt&&a.push(n),this._d("curve",a,i)}polygon(t,r){const i=this._o(r),a=[],n=ya(t,!0,i);return i.fill&&(i.fillStyle==="solid"?a.push(Qn([t],i)):a.push(Cr([t],i))),i.stroke!==Gt&&a.push(n),this._d("polygon",a,i)}path(t,r){const i=this._o(r),a=[];if(!t)return this._d("path",a,i);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const n=i.fill&&i.fill!=="transparent"&&i.fill!==Gt,o=i.stroke!==Gt,s=!!(i.simplification&&i.simplification<1),l=(function(h,u,f){const d=Td(kd(No(h))),g=[];let m=[],y=[0,0],x=[];const b=()=>{x.length>=4&&m.push(...Jn(x,u)),x=[]},_=()=>{b(),m.length&&(g.push(m),m=[])};for(const{key:v,data:B}of d)switch(v){case"M":_(),y=[B[0],B[1]],m.push(y);break;case"L":b(),m.push([B[0],B[1]]);break;case"C":if(!x.length){const T=m.length?m[m.length-1]:y;x.push([T[0],T[1]])}x.push([B[0],B[1]]),x.push([B[2],B[3]]),x.push([B[4],B[5]]);break;case"Z":b(),m.push([y[0],y[1]])}if(_(),!f)return g;const w=[];for(const v of g){const B=Qv(v,f);B.length&&w.push(B)}return w})(t,1,s?4-4*(i.simplification||1):(1+i.roughness)/2),c=_c(t,i);if(n)if(i.fillStyle==="solid")if(l.length===1){const h=_c(t,Object.assign(Object.assign({},i),{disableMultiStroke:!0,roughness:i.roughness?i.roughness+i.fillShapeRoughnessGain:0}));a.push({type:"fillPath",ops:this._mergedShape(h.ops)})}else a.push(Qn(l,i));else a.push(Cr(l,i));return o&&(s?l.forEach((h=>{a.push(ya(h,!1,i))})):a.push(c)),this._d("path",a,i)}opsToPath(t,r){let i="";for(const a of t.ops){const n=typeof r=="number"&&r>=0?a.data.map((o=>+o.toFixed(r))):a.data;switch(a.op){case"move":i+=`M${n[0]} ${n[1]} `;break;case"bcurveTo":i+=`C${n[0]} ${n[1]}, ${n[2]} ${n[3]}, ${n[4]} ${n[5]} `;break;case"lineTo":i+=`L${n[0]} ${n[1]} `}}return i.trim()}toPaths(t){const r=t.sets||[],i=t.options||this.defaultOptions,a=[];for(const n of r){let o=null;switch(n.type){case"path":o={d:this.opsToPath(n),stroke:i.stroke,strokeWidth:i.strokeWidth,fill:Gt};break;case"fillPath":o={d:this.opsToPath(n),stroke:Gt,strokeWidth:0,fill:i.fill||Gt};break;case"fillSketch":o=this.fillSketch(n,i)}o&&a.push(o)}return a}fillSketch(t,r){let i=r.fillWeight;return i<0&&(i=r.strokeWidth/2),{d:this.opsToPath(t),stroke:r.fill||Gt,strokeWidth:i,fill:Gt}}_mergedShape(t){return t.filter(((r,i)=>i===0||r.op!=="move"))}}class Jv{constructor(t,r){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new Qa(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),a=this.ctx,n=t.options.fixedDecimalPlaceDigits;for(const o of r)switch(o.type){case"path":a.save(),a.strokeStyle=i.stroke==="none"?"transparent":i.stroke,a.lineWidth=i.strokeWidth,i.strokeLineDash&&a.setLineDash(i.strokeLineDash),i.strokeLineDashOffset&&(a.lineDashOffset=i.strokeLineDashOffset),this._drawToContext(a,o,n),a.restore();break;case"fillPath":{a.save(),a.fillStyle=i.fill||"";const s=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(a,o,n,s),a.restore();break}case"fillSketch":this.fillSketch(a,o,i)}}fillSketch(t,r,i){let a=i.fillWeight;a<0&&(a=i.strokeWidth/2),t.save(),i.fillLineDash&&t.setLineDash(i.fillLineDash),i.fillLineDashOffset&&(t.lineDashOffset=i.fillLineDashOffset),t.strokeStyle=i.fill||"",t.lineWidth=a,this._drawToContext(t,r,i.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,r,i,a="nonzero"){t.beginPath();for(const n of r.ops){const o=typeof i=="number"&&i>=0?n.data.map((s=>+s.toFixed(i))):n.data;switch(n.op){case"move":t.moveTo(o[0],o[1]);break;case"bcurveTo":t.bezierCurveTo(o[0],o[1],o[2],o[3],o[4],o[5]);break;case"lineTo":t.lineTo(o[0],o[1])}}r.type==="fillPath"?t.fill(a):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,r,i,a,n){const o=this.gen.line(t,r,i,a,n);return this.draw(o),o}rectangle(t,r,i,a,n){const o=this.gen.rectangle(t,r,i,a,n);return this.draw(o),o}ellipse(t,r,i,a,n){const o=this.gen.ellipse(t,r,i,a,n);return this.draw(o),o}circle(t,r,i,a){const n=this.gen.circle(t,r,i,a);return this.draw(n),n}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i),i}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i),i}arc(t,r,i,a,n,o,s=!1,l){const c=this.gen.arc(t,r,i,a,n,o,s,l);return this.draw(c),c}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i),i}path(t,r){const i=this.gen.path(t,r);return this.draw(i),i}}const aa="http://www.w3.org/2000/svg";class tw{constructor(t,r){this.svg=t,this.gen=new Qa(r)}draw(t){const r=t.sets||[],i=t.options||this.getDefaultOptions(),a=this.svg.ownerDocument||window.document,n=a.createElementNS(aa,"g"),o=t.options.fixedDecimalPlaceDigits;for(const s of r){let l=null;switch(s.type){case"path":l=a.createElementNS(aa,"path"),l.setAttribute("d",this.opsToPath(s,o)),l.setAttribute("stroke",i.stroke),l.setAttribute("stroke-width",i.strokeWidth+""),l.setAttribute("fill","none"),i.strokeLineDash&&l.setAttribute("stroke-dasharray",i.strokeLineDash.join(" ").trim()),i.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${i.strokeLineDashOffset}`);break;case"fillPath":l=a.createElementNS(aa,"path"),l.setAttribute("d",this.opsToPath(s,o)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",i.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(a,s,i)}l&&n.appendChild(l)}return n}fillSketch(t,r,i){let a=i.fillWeight;a<0&&(a=i.strokeWidth/2);const n=t.createElementNS(aa,"path");return n.setAttribute("d",this.opsToPath(r,i.fixedDecimalPlaceDigits)),n.setAttribute("stroke",i.fill||""),n.setAttribute("stroke-width",a+""),n.setAttribute("fill","none"),i.fillLineDash&&n.setAttribute("stroke-dasharray",i.fillLineDash.join(" ").trim()),i.fillLineDashOffset&&n.setAttribute("stroke-dashoffset",`${i.fillLineDashOffset}`),n}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,r){return this.gen.opsToPath(t,r)}line(t,r,i,a,n){const o=this.gen.line(t,r,i,a,n);return this.draw(o)}rectangle(t,r,i,a,n){const o=this.gen.rectangle(t,r,i,a,n);return this.draw(o)}ellipse(t,r,i,a,n){const o=this.gen.ellipse(t,r,i,a,n);return this.draw(o)}circle(t,r,i,a){const n=this.gen.circle(t,r,i,a);return this.draw(n)}linearPath(t,r){const i=this.gen.linearPath(t,r);return this.draw(i)}polygon(t,r){const i=this.gen.polygon(t,r);return this.draw(i)}arc(t,r,i,a,n,o,s=!1,l){const c=this.gen.arc(t,r,i,a,n,o,s,l);return this.draw(c)}curve(t,r){const i=this.gen.curve(t,r);return this.draw(i)}path(t,r){const i=this.gen.path(t,r);return this.draw(i)}}var j={canvas:(e,t)=>new Jv(e,t),svg:(e,t)=>new tw(e,t),generator:e=>new Qa(e),newSeed:()=>Qa.newSeed()},it=p(async(e,t,r)=>{let i;const a=t.useHtmlLabels||kt(ut()?.htmlLabels);r?i=r:i="node default";const n=e.insert("g").attr("class",i).attr("id",t.domId||t.id),o=n.insert("g").attr("class","label").attr("style",Dt(t.labelStyle));let s;t.label===void 0?s="":s=typeof t.label=="string"?t.label:t.label[0];const l=await qe(o,Jt(dr(s),ut()),{useHtmlLabels:a,width:t.width||ut().flowchart?.wrappingWidth,cssClasses:"markdown-node-label",style:t.labelStyle,addSvgBackground:!!t.icon||!!t.img});let c=l.getBBox();const h=(t?.padding??0)/2;if(a){const u=l.children[0],f=ht(l),d=u.getElementsByTagName("img");if(d){const g=s.replace(/<img[^>]*>/g,"").trim()==="";await Promise.all([...d].map(m=>new Promise(y=>{function x(){if(m.style.display="flex",m.style.flexDirection="column",g){const b=ut().fontSize?ut().fontSize:window.getComputedStyle(document.body).fontSize,_=5,[w=th.fontSize]=xn(b),v=w*_+"px";m.style.minWidth=v,m.style.maxWidth=v}else m.style.width="100%";y(m)}p(x,"setupImage"),setTimeout(()=>{m.complete&&x()}),m.addEventListener("error",x),m.addEventListener("load",x)})))}c=u.getBoundingClientRect(),f.attr("width",c.width),f.attr("height",c.height)}return a?o.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"):o.attr("transform","translate(0, "+-c.height/2+")"),t.centerLabel&&o.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),o.insert("rect",":first-child"),{shapeSvg:n,bbox:c,halfPadding:h,label:o}},"labelHelper"),ts=p(async(e,t,r)=>{const i=r.useHtmlLabels||kt(ut()?.flowchart?.htmlLabels),a=e.insert("g").attr("class","label").attr("style",r.labelStyle||""),n=await qe(a,Jt(dr(t),ut()),{useHtmlLabels:i,width:r.width||ut()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img});let o=n.getBBox();const s=r.padding/2;if(kt(ut()?.flowchart?.htmlLabels)){const l=n.children[0],c=ht(n);o=l.getBoundingClientRect(),c.attr("width",o.width),c.attr("height",o.height)}return i?a.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"):a.attr("transform","translate(0, "+-o.height/2+")"),r.centerLabel&&a.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),a.insert("rect",":first-child"),{shapeSvg:e,bbox:o,halfPadding:s,label:a}},"insertLabel"),G=p((e,t)=>{const r=t.node().getBBox();e.width=r.width,e.height=r.height},"updateNodeBounds"),rt=p((e,t)=>(e.look==="handDrawn"?"rough-node":"node")+" "+e.cssClasses+" "+(t||""),"getNodeClasses");function lt(e){const t=e.map((r,i)=>`${i===0?"M":"L"}${r.x},${r.y}`);return t.push("Z"),t.join(" ")}p(lt,"createPathFromPoints");function We(e,t,r,i,a,n){const o=[],l=r-e,c=i-t,h=l/n,u=2*Math.PI/h,f=t+c/2;for(let d=0;d<=50;d++){const g=d/50,m=e+g*l,y=f+a*Math.sin(u*(m-e));o.push({x:m,y})}return o}p(We,"generateFullSineWavePoints");function $i(e,t,r,i,a,n){const o=[],s=a*Math.PI/180,h=(n*Math.PI/180-s)/(i-1);for(let u=0;u<i;u++){const f=s+u*h,d=e+r*Math.cos(f),g=t+r*Math.sin(f);o.push({x:-d,y:-g})}return o}p($i,"generateCirclePoints");var ew=p((e,t)=>{var r=e.x,i=e.y,a=t.x-r,n=t.y-i,o=e.width/2,s=e.height/2,l,c;return Math.abs(n)*o>Math.abs(a)*s?(n<0&&(s=-s),l=n===0?0:s*a/n,c=s):(a<0&&(o=-o),l=o,c=a===0?0:o*n/a),{x:r+l,y:i+c}},"intersectRect"),Xr=ew;function Ed(e,t){t&&e.attr("style",t)}p(Ed,"applyStyle");async function $d(e){const t=ht(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),r=t.append("xhtml:div"),i=ut();let a=e.label;e.label&&Pr(e.label)&&(a=await to(e.label.replace(Yr.lineBreakRegex,`
|
|
124
|
+
`),i));const o='<span class="'+(e.isNode?"nodeLabel":"edgeLabel")+'" '+(e.labelStyle?'style="'+e.labelStyle+'"':"")+">"+a+"</span>";return r.html(Jt(o,i)),Ed(r,e.labelStyle),r.style("display","inline-block"),r.style("padding-right","1px"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),t.node()}p($d,"addHtmlLabel");var rw=p(async(e,t,r,i)=>{let a=e||"";if(typeof a=="object"&&(a=a[0]),kt(ut().flowchart.htmlLabels)){a=a.replace(/\\n|\n/g,"<br />"),F.info("vertexText"+a);const n={isNode:i,label:dr(a).replace(/fa[blrs]?:fa-[\w-]+/g,s=>`<i class='${s.replace(":"," ")}'></i>`),labelStyle:t&&t.replace("fill:","color:")};return await $d(n)}else{const n=document.createElementNS("http://www.w3.org/2000/svg","text");n.setAttribute("style",t.replace("color:","fill:"));let o=[];typeof a=="string"?o=a.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(a)?o=a:o=[];for(const s of o){const l=document.createElementNS("http://www.w3.org/2000/svg","tspan");l.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),l.setAttribute("dy","1em"),l.setAttribute("x","0"),r?l.setAttribute("class","title-row"):l.setAttribute("class","row"),l.textContent=s.trim(),n.appendChild(l)}return n}},"createLabel"),er=rw,He=p((e,t,r,i,a)=>["M",e+a,t,"H",e+r-a,"A",a,a,0,0,1,e+r,t+a,"V",t+i-a,"A",a,a,0,0,1,e+r-a,t+i,"H",e+a,"A",a,a,0,0,1,e,t+i-a,"V",t+a,"A",a,a,0,0,1,e+a,t,"Z"].join(" "),"createRoundedRectPathD"),Fd=p(async(e,t)=>{F.info("Creating subgraph rect for ",t.id,t);const r=ut(),{themeVariables:i,handDrawnSeed:a}=r,{clusterBkg:n,clusterBorder:o}=i,{labelStyles:s,nodeStyles:l,borderStyles:c,backgroundStyles:h}=U(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),f=kt(r.flowchart.htmlLabels),d=u.insert("g").attr("class","cluster-label "),g=await qe(d,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0});let m=g.getBBox();if(kt(r.flowchart.htmlLabels)){const T=g.children[0],O=ht(g);m=T.getBoundingClientRect(),O.attr("width",m.width),O.attr("height",m.height)}const y=t.width<=m.width+t.padding?m.width+t.padding:t.width;t.width<=m.width+t.padding?t.diff=(y-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height,b=t.x-y/2,_=t.y-x/2;F.trace("Data ",t,JSON.stringify(t));let w;if(t.look==="handDrawn"){const T=j.svg(u),O=Y(t,{roughness:.7,fill:n,stroke:o,fillWeight:3,seed:a}),R=T.path(He(b,_,y,x,0),O);w=u.insert(()=>(F.debug("Rough node insert CXC",R),R),":first-child"),w.select("path:nth-child(2)").attr("style",c.join(";")),w.select("path").attr("style",h.join(";").replace("fill","stroke"))}else w=u.insert("rect",":first-child"),w.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",b).attr("y",_).attr("width",y).attr("height",x);const{subGraphTitleTopMargin:v}=To(r);if(d.attr("transform",`translate(${t.x-m.width/2}, ${t.y-t.height/2+v})`),s){const T=d.select("span");T&&T.attr("style",s)}const B=w.node().getBBox();return t.offsetX=0,t.width=B.width,t.height=B.height,t.offsetY=m.height-t.padding/2,t.intersect=function(T){return Xr(t,T)},{cluster:u,labelBBox:m}},"rect"),iw=p((e,t)=>{const r=e.insert("g").attr("class","note-cluster").attr("id",t.id),i=r.insert("rect",":first-child"),a=0*t.padding,n=a/2;i.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-n).attr("y",t.y-t.height/2-n).attr("width",t.width+a).attr("height",t.height+a).attr("fill","none");const o=i.node().getBBox();return t.width=o.width,t.height=o.height,t.intersect=function(s){return Xr(t,s)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),aw=p(async(e,t)=>{const r=ut(),{themeVariables:i,handDrawnSeed:a}=r,{altBackground:n,compositeBackground:o,compositeTitleBackground:s,nodeBorder:l}=i,c=e.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-id",t.id).attr("data-look",t.look),h=c.insert("g",":first-child"),u=c.insert("g").attr("class","cluster-label");let f=c.append("rect");const d=u.node().appendChild(await er(t.label,t.labelStyle,void 0,!0));let g=d.getBBox();if(kt(r.flowchart.htmlLabels)){const R=d.children[0],D=ht(d);g=R.getBoundingClientRect(),D.attr("width",g.width),D.attr("height",g.height)}const m=0*t.padding,y=m/2,x=(t.width<=g.width+t.padding?g.width+t.padding:t.width)+m;t.width<=g.width+t.padding?t.diff=(x-t.width)/2-t.padding:t.diff=-t.padding;const b=t.height+m,_=t.height+m-g.height-6,w=t.x-x/2,v=t.y-b/2;t.width=x;const B=t.y-t.height/2-y+g.height+2;let T;if(t.look==="handDrawn"){const R=t.cssClasses.includes("statediagram-cluster-alt"),D=j.svg(c),E=t.rx||t.ry?D.path(He(w,v,x,b,10),{roughness:.7,fill:s,fillStyle:"solid",stroke:l,seed:a}):D.rectangle(w,v,x,b,{seed:a});T=c.insert(()=>E,":first-child");const N=D.rectangle(w,B,x,_,{fill:R?n:o,fillStyle:R?"hachure":"solid",stroke:l,seed:a});T=c.insert(()=>E,":first-child"),f=c.insert(()=>N)}else T=h.insert("rect",":first-child"),T.attr("class","outer").attr("x",w).attr("y",v).attr("width",x).attr("height",b).attr("data-look",t.look),f.attr("class","inner").attr("x",w).attr("y",B).attr("width",x).attr("height",_);u.attr("transform",`translate(${t.x-g.width/2}, ${v+1-(kt(r.flowchart.htmlLabels)?0:3)})`);const O=T.node().getBBox();return t.height=O.height,t.offsetX=0,t.offsetY=g.height-t.padding/2,t.labelBBox=g,t.intersect=function(R){return Xr(t,R)},{cluster:c,labelBBox:g}},"roundedWithTitle"),nw=p(async(e,t)=>{F.info("Creating subgraph rect for ",t.id,t);const r=ut(),{themeVariables:i,handDrawnSeed:a}=r,{clusterBkg:n,clusterBorder:o}=i,{labelStyles:s,nodeStyles:l,borderStyles:c,backgroundStyles:h}=U(t),u=e.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),f=kt(r.flowchart.htmlLabels),d=u.insert("g").attr("class","cluster-label "),g=await qe(d,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width});let m=g.getBBox();if(kt(r.flowchart.htmlLabels)){const T=g.children[0],O=ht(g);m=T.getBoundingClientRect(),O.attr("width",m.width),O.attr("height",m.height)}const y=t.width<=m.width+t.padding?m.width+t.padding:t.width;t.width<=m.width+t.padding?t.diff=(y-t.width)/2-t.padding:t.diff=-t.padding;const x=t.height,b=t.x-y/2,_=t.y-x/2;F.trace("Data ",t,JSON.stringify(t));let w;if(t.look==="handDrawn"){const T=j.svg(u),O=Y(t,{roughness:.7,fill:n,stroke:o,fillWeight:4,seed:a}),R=T.path(He(b,_,y,x,t.rx),O);w=u.insert(()=>(F.debug("Rough node insert CXC",R),R),":first-child"),w.select("path:nth-child(2)").attr("style",c.join(";")),w.select("path").attr("style",h.join(";").replace("fill","stroke"))}else w=u.insert("rect",":first-child"),w.attr("style",l).attr("rx",t.rx).attr("ry",t.ry).attr("x",b).attr("y",_).attr("width",y).attr("height",x);const{subGraphTitleTopMargin:v}=To(r);if(d.attr("transform",`translate(${t.x-m.width/2}, ${t.y-t.height/2+v})`),s){const T=d.select("span");T&&T.attr("style",s)}const B=w.node().getBBox();return t.offsetX=0,t.width=B.width,t.height=B.height,t.offsetY=m.height-t.padding/2,t.intersect=function(T){return Xr(t,T)},{cluster:u,labelBBox:m}},"kanbanSection"),sw=p((e,t)=>{const r=ut(),{themeVariables:i,handDrawnSeed:a}=r,{nodeBorder:n}=i,o=e.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-look",t.look),s=o.insert("g",":first-child"),l=0*t.padding,c=t.width+l;t.diff=-t.padding;const h=t.height+l,u=t.x-c/2,f=t.y-h/2;t.width=c;let d;if(t.look==="handDrawn"){const y=j.svg(o).rectangle(u,f,c,h,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:n,seed:a});d=o.insert(()=>y,":first-child")}else d=s.insert("rect",":first-child"),d.attr("class","divider").attr("x",u).attr("y",f).attr("width",c).attr("height",h).attr("data-look",t.look);const g=d.node().getBBox();return t.height=g.height,t.offsetX=0,t.offsetY=0,t.intersect=function(m){return Xr(t,m)},{cluster:o,labelBBox:{}}},"divider"),ow=Fd,lw={rect:Fd,squareRect:ow,roundedWithTitle:aw,noteGroup:iw,divider:sw,kanbanSection:nw},Od=new Map,cw=p(async(e,t)=>{const r=t.shape||"rect",i=await lw[r](e,t);return Od.set(t.id,i),i},"insertCluster"),FL=p(()=>{Od=new Map},"clear");function Dd(e,t){return e.intersect(t)}p(Dd,"intersectNode");var hw=Dd;function Id(e,t,r,i){var a=e.x,n=e.y,o=a-i.x,s=n-i.y,l=Math.sqrt(t*t*s*s+r*r*o*o),c=Math.abs(t*r*o/l);i.x<a&&(c=-c);var h=Math.abs(t*r*s/l);return i.y<n&&(h=-h),{x:a+c,y:n+h}}p(Id,"intersectEllipse");var Rd=Id;function Pd(e,t,r){return Rd(e,t,t,r)}p(Pd,"intersectCircle");var uw=Pd;function Nd(e,t,r,i){{const a=t.y-e.y,n=e.x-t.x,o=t.x*e.y-e.x*t.y,s=a*r.x+n*r.y+o,l=a*i.x+n*i.y+o,c=1e-6;if(s!==0&&l!==0&&zs(s,l))return;const h=i.y-r.y,u=r.x-i.x,f=i.x*r.y-r.x*i.y,d=h*e.x+u*e.y+f,g=h*t.x+u*t.y+f;if(Math.abs(d)<c&&Math.abs(g)<c&&zs(d,g))return;const m=a*u-h*n;if(m===0)return;const y=Math.abs(m/2);let x=n*f-u*o;const b=x<0?(x-y)/m:(x+y)/m;x=h*o-a*f;const _=x<0?(x-y)/m:(x+y)/m;return{x:b,y:_}}}p(Nd,"intersectLine");function zs(e,t){return e*t>0}p(zs,"sameSign");var fw=Nd;function Wd(e,t,r){let i=e.x,a=e.y,n=[],o=Number.POSITIVE_INFINITY,s=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(h){o=Math.min(o,h.x),s=Math.min(s,h.y)}):(o=Math.min(o,t.x),s=Math.min(s,t.y));let l=i-e.width/2-o,c=a-e.height/2-s;for(let h=0;h<t.length;h++){let u=t[h],f=t[h<t.length-1?h+1:0],d=fw(e,r,{x:l+u.x,y:c+u.y},{x:l+f.x,y:c+f.y});d&&n.push(d)}return n.length?(n.length>1&&n.sort(function(h,u){let f=h.x-r.x,d=h.y-r.y,g=Math.sqrt(f*f+d*d),m=u.x-r.x,y=u.y-r.y,x=Math.sqrt(m*m+y*y);return g<x?-1:g===x?0:1}),n[0]):e}p(Wd,"intersectPolygon");var dw=Wd,z={node:hw,circle:uw,ellipse:Rd,polygon:dw,rect:Xr};function zd(e,t){const{labelStyles:r}=U(t);t.labelStyle=r;const i=rt(t);let a=i;i||(a="anchor");const n=e.insert("g").attr("class",a).attr("id",t.domId||t.id),o=1,{cssStyles:s}=t,l=j.svg(n),c=Y(t,{fill:"black",stroke:"none",fillStyle:"solid"});t.look!=="handDrawn"&&(c.roughness=0);const h=l.circle(0,0,o*2,c),u=n.insert(()=>h,":first-child");return u.attr("class","anchor").attr("style",Dt(s)),G(t,u),t.intersect=function(f){return F.info("Circle intersect",t,o,f),z.circle(t,o,f)},n}p(zd,"anchor");function qs(e,t,r,i,a,n,o){const l=(e+r)/2,c=(t+i)/2,h=Math.atan2(i-t,r-e),u=(r-e)/2,f=(i-t)/2,d=u/a,g=f/n,m=Math.sqrt(d**2+g**2);if(m>1)throw new Error("The given radii are too small to create an arc between the points.");const y=Math.sqrt(1-m**2),x=l+y*n*Math.sin(h)*(o?-1:1),b=c-y*a*Math.cos(h)*(o?-1:1),_=Math.atan2((t-b)/n,(e-x)/a);let v=Math.atan2((i-b)/n,(r-x)/a)-_;o&&v<0&&(v+=2*Math.PI),!o&&v>0&&(v-=2*Math.PI);const B=[];for(let T=0;T<20;T++){const O=T/19,R=_+O*v,D=x+a*Math.cos(R),E=b+n*Math.sin(R);B.push({x:D,y:E})}return B}p(qs,"generateArcPoints");async function qd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.width+t.padding+20,s=n.height+t.padding,l=s/2,c=l/(2.5+s/50),{cssStyles:h}=t,u=[{x:o/2,y:-s/2},{x:-o/2,y:-s/2},...qs(-o/2,-s/2,-o/2,s/2,c,l,!1),{x:o/2,y:s/2},...qs(o/2,s/2,o/2,-s/2,c,l,!0)],f=j.svg(a),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=lt(u),m=f.path(g,d),y=a.insert(()=>m,":first-child");return y.attr("class","basic label-container"),h&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",h),i&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",i),y.attr("transform",`translate(${c/2}, 0)`),G(t,y),t.intersect=function(x){return z.polygon(t,u,x)},a}p(qd,"bowTieRect");function je(e,t,r,i){return e.insert("polygon",":first-child").attr("points",i.map(function(a){return a.x+","+a.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+r/2+")")}p(je,"insertPolygonShape");async function Hd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.height+t.padding,s=12,l=n.width+t.padding+s,c=0,h=l,u=-o,f=0,d=[{x:c+s,y:u},{x:h,y:u},{x:h,y:f},{x:c,y:f},{x:c,y:u+s},{x:c+s,y:u}];let g;const{cssStyles:m}=t;if(t.look==="handDrawn"){const y=j.svg(a),x=Y(t,{}),b=lt(d),_=y.path(b,x);g=a.insert(()=>_,":first-child").attr("transform",`translate(${-l/2}, ${o/2})`),m&&g.attr("style",m)}else g=je(a,l,o,d);return i&&g.attr("style",i),G(t,g),t.intersect=function(y){return z.polygon(t,d,y)},a}p(Hd,"card");function jd(e,t){const{nodeStyles:r}=U(t);t.label="";const i=e.insert("g").attr("class",rt(t)).attr("id",t.domId??t.id),{cssStyles:a}=t,n=Math.max(28,t.width??0),o=[{x:0,y:n/2},{x:n/2,y:0},{x:0,y:-n/2},{x:-n/2,y:0}],s=j.svg(i),l=Y(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const c=lt(o),h=s.path(c,l),u=i.insert(()=>h,":first-child");return a&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",a),r&&t.look!=="handDrawn"&&u.selectAll("path").attr("style",r),t.width=28,t.height=28,t.intersect=function(f){return z.polygon(t,o,f)},i}p(jd,"choice");async function Wo(e,t,r){const{labelStyles:i,nodeStyles:a}=U(t);t.labelStyle=i;const{shapeSvg:n,bbox:o,halfPadding:s}=await it(e,t,rt(t)),l=r?.padding??s,c=o.width/2+l;let h;const{cssStyles:u}=t;if(t.look==="handDrawn"){const f=j.svg(n),d=Y(t,{}),g=f.circle(0,0,c*2,d);h=n.insert(()=>g,":first-child"),h.attr("class","basic label-container").attr("style",Dt(u))}else h=n.insert("circle",":first-child").attr("class","basic label-container").attr("style",a).attr("r",c).attr("cx",0).attr("cy",0);return G(t,h),t.calcIntersect=function(f,d){const g=f.width/2;return z.circle(f,g,d)},t.intersect=function(f){return F.info("Circle intersect",t,c,f),z.circle(t,c,f)},n}p(Wo,"circle");function Yd(e){const t=Math.cos(Math.PI/4),r=Math.sin(Math.PI/4),i=e*2,a={x:i/2*t,y:i/2*r},n={x:-(i/2)*t,y:i/2*r},o={x:-(i/2)*t,y:-(i/2)*r},s={x:i/2*t,y:-(i/2)*r};return`M ${n.x},${n.y} L ${s.x},${s.y}
|
|
125
|
+
M ${a.x},${a.y} L ${o.x},${o.y}`}p(Yd,"createLine");function Ud(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r,t.label="";const a=e.insert("g").attr("class",rt(t)).attr("id",t.domId??t.id),n=Math.max(30,t?.width??0),{cssStyles:o}=t,s=j.svg(a),l=Y(t,{});t.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");const c=s.circle(0,0,n*2,l),h=Yd(n),u=s.path(h,l),f=a.insert(()=>c,":first-child");return f.insert(()=>u),o&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",o),i&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",i),G(t,f),t.intersect=function(d){return F.info("crossedCircle intersect",t,{radius:n,point:d}),z.circle(t,n,d)},a}p(Ud,"crossedCircle");function ke(e,t,r,i=100,a=0,n=180){const o=[],s=a*Math.PI/180,h=(n*Math.PI/180-s)/(i-1);for(let u=0;u<i;u++){const f=s+u*h,d=e+r*Math.cos(f),g=t+r*Math.sin(f);o.push({x:-d,y:-g})}return o}p(ke,"generateCirclePoints");async function Gd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=n.width+(t.padding??0),l=n.height+(t.padding??0),c=Math.max(5,l*.1),{cssStyles:h}=t,u=[...ke(s/2,-l/2,c,30,-90,0),{x:-s/2-c,y:c},...ke(s/2+c*2,-c,c,20,-180,-270),...ke(s/2+c*2,c,c,20,-90,-180),{x:-s/2-c,y:-l/2},...ke(s/2,l/2,c,20,0,90)],f=[{x:s/2,y:-l/2-c},{x:-s/2,y:-l/2-c},...ke(s/2,-l/2,c,20,-90,0),{x:-s/2-c,y:-c},...ke(s/2+s*.1,-c,c,20,-180,-270),...ke(s/2+s*.1,c,c,20,-90,-180),{x:-s/2-c,y:l/2},...ke(s/2,l/2,c,20,0,90),{x:-s/2,y:l/2+c},{x:s/2,y:l/2+c}],d=j.svg(a),g=Y(t,{fill:"none"});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const y=lt(u).replace("Z",""),x=d.path(y,g),b=lt(f),_=d.path(b,{...g}),w=a.insert("g",":first-child");return w.insert(()=>_,":first-child").attr("stroke-opacity",0),w.insert(()=>x,":first-child"),w.attr("class","text"),h&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",h),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),w.attr("transform",`translate(${c}, 0)`),o.attr("transform",`translate(${-s/2+c-(n.x-(n.left??0))},${-l/2+(t.padding??0)/2-(n.y-(n.top??0))})`),G(t,w),t.intersect=function(v){return z.polygon(t,f,v)},a}p(Gd,"curlyBraceLeft");function Te(e,t,r,i=100,a=0,n=180){const o=[],s=a*Math.PI/180,h=(n*Math.PI/180-s)/(i-1);for(let u=0;u<i;u++){const f=s+u*h,d=e+r*Math.cos(f),g=t+r*Math.sin(f);o.push({x:d,y:g})}return o}p(Te,"generateCirclePoints");async function Vd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=n.width+(t.padding??0),l=n.height+(t.padding??0),c=Math.max(5,l*.1),{cssStyles:h}=t,u=[...Te(s/2,-l/2,c,20,-90,0),{x:s/2+c,y:-c},...Te(s/2+c*2,-c,c,20,-180,-270),...Te(s/2+c*2,c,c,20,-90,-180),{x:s/2+c,y:l/2},...Te(s/2,l/2,c,20,0,90)],f=[{x:-s/2,y:-l/2-c},{x:s/2,y:-l/2-c},...Te(s/2,-l/2,c,20,-90,0),{x:s/2+c,y:-c},...Te(s/2+c*2,-c,c,20,-180,-270),...Te(s/2+c*2,c,c,20,-90,-180),{x:s/2+c,y:l/2},...Te(s/2,l/2,c,20,0,90),{x:s/2,y:l/2+c},{x:-s/2,y:l/2+c}],d=j.svg(a),g=Y(t,{fill:"none"});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const y=lt(u).replace("Z",""),x=d.path(y,g),b=lt(f),_=d.path(b,{...g}),w=a.insert("g",":first-child");return w.insert(()=>_,":first-child").attr("stroke-opacity",0),w.insert(()=>x,":first-child"),w.attr("class","text"),h&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",h),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),w.attr("transform",`translate(${-c}, 0)`),o.attr("transform",`translate(${-s/2+(t.padding??0)/2-(n.x-(n.left??0))},${-l/2+(t.padding??0)/2-(n.y-(n.top??0))})`),G(t,w),t.intersect=function(v){return z.polygon(t,f,v)},a}p(Vd,"curlyBraceRight");function Bt(e,t,r,i=100,a=0,n=180){const o=[],s=a*Math.PI/180,h=(n*Math.PI/180-s)/(i-1);for(let u=0;u<i;u++){const f=s+u*h,d=e+r*Math.cos(f),g=t+r*Math.sin(f);o.push({x:-d,y:-g})}return o}p(Bt,"generateCirclePoints");async function Xd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=n.width+(t.padding??0),l=n.height+(t.padding??0),c=Math.max(5,l*.1),{cssStyles:h}=t,u=[...Bt(s/2,-l/2,c,30,-90,0),{x:-s/2-c,y:c},...Bt(s/2+c*2,-c,c,20,-180,-270),...Bt(s/2+c*2,c,c,20,-90,-180),{x:-s/2-c,y:-l/2},...Bt(s/2,l/2,c,20,0,90)],f=[...Bt(-s/2+c+c/2,-l/2,c,20,-90,-180),{x:s/2-c/2,y:c},...Bt(-s/2-c/2,-c,c,20,0,90),...Bt(-s/2-c/2,c,c,20,-90,0),{x:s/2-c/2,y:-c},...Bt(-s/2+c+c/2,l/2,c,30,-180,-270)],d=[{x:s/2,y:-l/2-c},{x:-s/2,y:-l/2-c},...Bt(s/2,-l/2,c,20,-90,0),{x:-s/2-c,y:-c},...Bt(s/2+c*2,-c,c,20,-180,-270),...Bt(s/2+c*2,c,c,20,-90,-180),{x:-s/2-c,y:l/2},...Bt(s/2,l/2,c,20,0,90),{x:-s/2,y:l/2+c},{x:s/2-c-c/2,y:l/2+c},...Bt(-s/2+c+c/2,-l/2,c,20,-90,-180),{x:s/2-c/2,y:c},...Bt(-s/2-c/2,-c,c,20,0,90),...Bt(-s/2-c/2,c,c,20,-90,0),{x:s/2-c/2,y:-c},...Bt(-s/2+c+c/2,l/2,c,30,-180,-270)],g=j.svg(a),m=Y(t,{fill:"none"});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const x=lt(u).replace("Z",""),b=g.path(x,m),w=lt(f).replace("Z",""),v=g.path(w,m),B=lt(d),T=g.path(B,{...m}),O=a.insert("g",":first-child");return O.insert(()=>T,":first-child").attr("stroke-opacity",0),O.insert(()=>b,":first-child"),O.insert(()=>v,":first-child"),O.attr("class","text"),h&&t.look!=="handDrawn"&&O.selectAll("path").attr("style",h),i&&t.look!=="handDrawn"&&O.selectAll("path").attr("style",i),O.attr("transform",`translate(${c-c/4}, 0)`),o.attr("transform",`translate(${-s/2+(t.padding??0)/2-(n.x-(n.left??0))},${-l/2+(t.padding??0)/2-(n.y-(n.top??0))})`),G(t,O),t.intersect=function(R){return z.polygon(t,d,R)},a}p(Xd,"curlyBraces");async function Kd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=80,s=20,l=Math.max(o,(n.width+(t.padding??0)*2)*1.25,t?.width??0),c=Math.max(s,n.height+(t.padding??0)*2,t?.height??0),h=c/2,{cssStyles:u}=t,f=j.svg(a),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=l,m=c,y=g-h,x=m/4,b=[{x:y,y:0},{x,y:0},{x:0,y:m/2},{x,y:m},{x:y,y:m},...$i(-y,-m/2,h,50,270,90)],_=lt(b),w=f.path(_,d),v=a.insert(()=>w,":first-child");return v.attr("class","basic label-container"),u&&t.look!=="handDrawn"&&v.selectChildren("path").attr("style",u),i&&t.look!=="handDrawn"&&v.selectChildren("path").attr("style",i),v.attr("transform",`translate(${-l/2}, ${-c/2})`),G(t,v),t.intersect=function(B){return z.polygon(t,b,B)},a}p(Kd,"curvedTrapezoid");var pw=p((e,t,r,i,a,n)=>[`M${e},${t+n}`,`a${a},${n} 0,0,0 ${r},0`,`a${a},${n} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${n} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createCylinderPathD"),gw=p((e,t,r,i,a,n)=>[`M${e},${t+n}`,`M${e+r},${t+n}`,`a${a},${n} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${n} 0,0,0 ${r},0`,`l0,${-i}`].join(" "),"createOuterCylinderPathD"),mw=p((e,t,r,i,a,n)=>[`M${e-r/2},${-i/2}`,`a${a},${n} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");async function Zd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+t.padding,t.width??0),l=s/2,c=l/(2.5+s/50),h=Math.max(n.height+c+t.padding,t.height??0);let u;const{cssStyles:f}=t;if(t.look==="handDrawn"){const d=j.svg(a),g=gw(0,0,s,h,l,c),m=mw(0,c,s,h,l,c),y=d.path(g,Y(t,{})),x=d.path(m,Y(t,{fill:"none"}));u=a.insert(()=>x,":first-child"),u=a.insert(()=>y,":first-child"),u.attr("class","basic label-container"),f&&u.attr("style",f)}else{const d=pw(0,0,s,h,l,c);u=a.insert("path",":first-child").attr("d",d).attr("class","basic label-container").attr("style",Dt(f)).attr("style",i)}return u.attr("label-offset-y",c),u.attr("transform",`translate(${-s/2}, ${-(h/2+c)})`),G(t,u),o.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${-(n.height/2)+(t.padding??0)/1.5-(n.y-(n.top??0))})`),t.intersect=function(d){const g=z.rect(t,d),m=g.x-(t.x??0);if(l!=0&&(Math.abs(m)<(t.width??0)/2||Math.abs(m)==(t.width??0)/2&&Math.abs(g.y-(t.y??0))>(t.height??0)/2-c)){let y=c*c*(1-m*m/(l*l));y>0&&(y=Math.sqrt(y)),y=c-y,d.y-(t.y??0)>0&&(y=-y),g.y+=y}return g},a}p(Zd,"cylinder");async function Qd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=n.width+t.padding,l=n.height+t.padding,c=l*.2,h=-s/2,u=-l/2-c/2,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:h,y:u+c},{x:-h,y:u+c},{x:-h,y:-u},{x:h,y:-u},{x:h,y:u},{x:-h,y:u},{x:-h,y:u+c}],y=d.polygon(m.map(b=>[b.x,b.y]),g),x=a.insert(()=>y,":first-child");return x.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",i),o.attr("transform",`translate(${h+(t.padding??0)/2-(n.x-(n.left??0))}, ${u+c+(t.padding??0)/2-(n.y-(n.top??0))})`),G(t,x),t.intersect=function(b){return z.rect(t,b)},a}p(Qd,"dividedRectangle");async function Jd(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,halfPadding:o}=await it(e,t,rt(t)),l=n.width/2+o+5,c=n.width/2+o;let h;const{cssStyles:u}=t;if(t.look==="handDrawn"){const f=j.svg(a),d=Y(t,{roughness:.2,strokeWidth:2.5}),g=Y(t,{roughness:.2,strokeWidth:1.5}),m=f.circle(0,0,l*2,d),y=f.circle(0,0,c*2,g);h=a.insert("g",":first-child"),h.attr("class",Dt(t.cssClasses)).attr("style",Dt(u)),h.node()?.appendChild(m),h.node()?.appendChild(y)}else{h=a.insert("g",":first-child");const f=h.insert("circle",":first-child"),d=h.insert("circle");h.attr("class","basic label-container").attr("style",i),f.attr("class","outer-circle").attr("style",i).attr("r",l).attr("cx",0).attr("cy",0),d.attr("class","inner-circle").attr("style",i).attr("r",c).attr("cx",0).attr("cy",0)}return G(t,h),t.intersect=function(f){return F.info("DoubleCircle intersect",t,l,f),z.circle(t,l,f)},a}p(Jd,"doublecircle");function tp(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:a}=U(t);t.label="",t.labelStyle=i;const n=e.insert("g").attr("class",rt(t)).attr("id",t.domId??t.id),o=7,{cssStyles:s}=t,l=j.svg(n),{nodeBorder:c}=r,h=Y(t,{fillStyle:"solid"});t.look!=="handDrawn"&&(h.roughness=0);const u=l.circle(0,0,o*2,h),f=n.insert(()=>u,":first-child");return f.selectAll("path").attr("style",`fill: ${c} !important;`),s&&s.length>0&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",s),a&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",a),G(t,f),t.intersect=function(d){return F.info("filledCircle intersect",t,{radius:o,point:d}),z.circle(t,o,d)},n}p(tp,"filledCircle");async function ep(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=n.width+(t.padding??0),l=s+n.height,c=s+n.height,h=[{x:0,y:-l},{x:c,y:-l},{x:c/2,y:0}],{cssStyles:u}=t,f=j.svg(a),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=lt(h),m=f.path(g,d),y=a.insert(()=>m,":first-child").attr("transform",`translate(${-l/2}, ${l/2})`);return u&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",u),i&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",i),t.width=s,t.height=l,G(t,y),o.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${-l/2+(t.padding??0)/2+(n.y-(n.top??0))})`),t.intersect=function(x){return F.info("Triangle intersect",t,h,x),z.polygon(t,h,x)},a}p(ep,"flippedTriangle");function rp(e,t,{dir:r,config:{state:i,themeVariables:a}}){const{nodeStyles:n}=U(t);t.label="";const o=e.insert("g").attr("class",rt(t)).attr("id",t.domId??t.id),{cssStyles:s}=t;let l=Math.max(70,t?.width??0),c=Math.max(10,t?.height??0);r==="LR"&&(l=Math.max(10,t?.width??0),c=Math.max(70,t?.height??0));const h=-1*l/2,u=-1*c/2,f=j.svg(o),d=Y(t,{stroke:a.lineColor,fill:a.lineColor});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=f.rectangle(h,u,l,c,d),m=o.insert(()=>g,":first-child");s&&t.look!=="handDrawn"&&m.selectAll("path").attr("style",s),n&&t.look!=="handDrawn"&&m.selectAll("path").attr("style",n),G(t,m);const y=i?.padding??0;return t.width&&t.height&&(t.width+=y/2||0,t.height+=y/2||0),t.intersect=function(x){return z.rect(t,x)},o}p(rp,"forkJoin");async function ip(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const a=80,n=50,{shapeSvg:o,bbox:s}=await it(e,t,rt(t)),l=Math.max(a,s.width+(t.padding??0)*2,t?.width??0),c=Math.max(n,s.height+(t.padding??0)*2,t?.height??0),h=c/2,{cssStyles:u}=t,f=j.svg(o),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=[{x:-l/2,y:-c/2},{x:l/2-h,y:-c/2},...$i(-l/2+h,0,h,50,90,270),{x:l/2-h,y:c/2},{x:-l/2,y:c/2}],m=lt(g),y=f.path(m,d),x=o.insert(()=>y,":first-child");return x.attr("class","basic label-container"),u&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",u),i&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",i),G(t,x),t.intersect=function(b){return F.info("Pill intersect",t,{radius:h,point:b}),z.polygon(t,g,b)},o}p(ip,"halfRoundedRectangle");async function ap(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.height+(t.padding??0),s=n.width+(t.padding??0)*2.5,{cssStyles:l}=t,c=j.svg(a),h=Y(t,{});t.look!=="handDrawn"&&(h.roughness=0,h.fillStyle="solid");let u=s/2;const f=u/6;u=u+f;const d=o/2,g=d/2,m=u-g,y=[{x:-m,y:-d},{x:0,y:-d},{x:m,y:-d},{x:u,y:0},{x:m,y:d},{x:0,y:d},{x:-m,y:d},{x:-u,y:0}],x=lt(y),b=c.path(x,h),_=a.insert(()=>b,":first-child");return _.attr("class","basic label-container"),l&&t.look!=="handDrawn"&&_.selectChildren("path").attr("style",l),i&&t.look!=="handDrawn"&&_.selectChildren("path").attr("style",i),t.width=s,t.height=o,G(t,_),t.intersect=function(w){return z.polygon(t,y,w)},a}p(ap,"hexagon");async function np(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.label="",t.labelStyle=r;const{shapeSvg:a}=await it(e,t,rt(t)),n=Math.max(30,t?.width??0),o=Math.max(30,t?.height??0),{cssStyles:s}=t,l=j.svg(a),c=Y(t,{});t.look!=="handDrawn"&&(c.roughness=0,c.fillStyle="solid");const h=[{x:0,y:0},{x:n,y:0},{x:0,y:o},{x:n,y:o}],u=lt(h),f=l.path(u,c),d=a.insert(()=>f,":first-child");return d.attr("class","basic label-container"),s&&t.look!=="handDrawn"&&d.selectChildren("path").attr("style",s),i&&t.look!=="handDrawn"&&d.selectChildren("path").attr("style",i),d.attr("transform",`translate(${-n/2}, ${-o/2})`),G(t,d),t.intersect=function(g){return F.info("Pill intersect",t,{points:h}),z.polygon(t,h,g)},a}p(np,"hourglass");async function sp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=U(t);t.labelStyle=a;const n=t.assetHeight??48,o=t.assetWidth??48,s=Math.max(n,o),l=i?.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:h,label:u}=await it(e,t,"icon-shape default"),f=t.pos==="t",d=s,g=s,{nodeBorder:m}=r,{stylesMap:y}=Ur(t),x=-g/2,b=-d/2,_=t.label?8:0,w=j.svg(c),v=Y(t,{stroke:"none",fill:"none"});t.look!=="handDrawn"&&(v.roughness=0,v.fillStyle="solid");const B=w.rectangle(x,b,g,d,v),T=Math.max(g,h.width),O=d+h.height+_,R=w.rectangle(-T/2,-O/2,T,O,{...v,fill:"transparent",stroke:"none"}),D=c.insert(()=>B,":first-child"),E=c.insert(()=>R);if(t.icon){const N=c.append("g");N.html(`<g>${await qi(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const I=N.node().getBBox(),L=I.width,A=I.height,k=I.x,$=I.y;N.attr("transform",`translate(${-L/2-k},${f?h.height/2+_/2-A/2-$:-h.height/2-_/2-A/2-$})`),N.attr("style",`color: ${y.get("stroke")??m};`)}return u.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${f?-O/2:O/2-h.height})`),D.attr("transform",`translate(0,${f?h.height/2+_/2:-h.height/2-_/2})`),G(t,E),t.intersect=function(N){if(F.info("iconSquare intersect",t,N),!t.label)return z.rect(t,N);const I=t.x??0,L=t.y??0,A=t.height??0;let k=[];return f?k=[{x:I-h.width/2,y:L-A/2},{x:I+h.width/2,y:L-A/2},{x:I+h.width/2,y:L-A/2+h.height+_},{x:I+g/2,y:L-A/2+h.height+_},{x:I+g/2,y:L+A/2},{x:I-g/2,y:L+A/2},{x:I-g/2,y:L-A/2+h.height+_},{x:I-h.width/2,y:L-A/2+h.height+_}]:k=[{x:I-g/2,y:L-A/2},{x:I+g/2,y:L-A/2},{x:I+g/2,y:L-A/2+d},{x:I+h.width/2,y:L-A/2+d},{x:I+h.width/2/2,y:L+A/2},{x:I-h.width/2,y:L+A/2},{x:I-h.width/2,y:L-A/2+d},{x:I-g/2,y:L-A/2+d}],z.polygon(t,k,N)},c}p(sp,"icon");async function op(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=U(t);t.labelStyle=a;const n=t.assetHeight??48,o=t.assetWidth??48,s=Math.max(n,o),l=i?.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:h,label:u}=await it(e,t,"icon-shape default"),f=20,d=t.label?8:0,g=t.pos==="t",{nodeBorder:m,mainBkg:y}=r,{stylesMap:x}=Ur(t),b=j.svg(c),_=Y(t,{});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const w=x.get("fill");_.stroke=w??y;const v=c.append("g");t.icon&&v.html(`<g>${await qi(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const B=v.node().getBBox(),T=B.width,O=B.height,R=B.x,D=B.y,E=Math.max(T,O)*Math.SQRT2+f*2,N=b.circle(0,0,E,_),I=Math.max(E,h.width),L=E+h.height+d,A=b.rectangle(-I/2,-L/2,I,L,{..._,fill:"transparent",stroke:"none"}),k=c.insert(()=>N,":first-child"),$=c.insert(()=>A);return v.attr("transform",`translate(${-T/2-R},${g?h.height/2+d/2-O/2-D:-h.height/2-d/2-O/2-D})`),v.attr("style",`color: ${x.get("stroke")??m};`),u.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${g?-L/2:L/2-h.height})`),k.attr("transform",`translate(0,${g?h.height/2+d/2:-h.height/2-d/2})`),G(t,$),t.intersect=function(M){return F.info("iconSquare intersect",t,M),z.rect(t,M)},c}p(op,"iconCircle");async function lp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=U(t);t.labelStyle=a;const n=t.assetHeight??48,o=t.assetWidth??48,s=Math.max(n,o),l=i?.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:h,halfPadding:u,label:f}=await it(e,t,"icon-shape default"),d=t.pos==="t",g=s+u*2,m=s+u*2,{nodeBorder:y,mainBkg:x}=r,{stylesMap:b}=Ur(t),_=-m/2,w=-g/2,v=t.label?8:0,B=j.svg(c),T=Y(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const O=b.get("fill");T.stroke=O??x;const R=B.path(He(_,w,m,g,5),T),D=Math.max(m,h.width),E=g+h.height+v,N=B.rectangle(-D/2,-E/2,D,E,{...T,fill:"transparent",stroke:"none"}),I=c.insert(()=>R,":first-child").attr("class","icon-shape2"),L=c.insert(()=>N);if(t.icon){const A=c.append("g");A.html(`<g>${await qi(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const k=A.node().getBBox(),$=k.width,M=k.height,q=k.x,V=k.y;A.attr("transform",`translate(${-$/2-q},${d?h.height/2+v/2-M/2-V:-h.height/2-v/2-M/2-V})`),A.attr("style",`color: ${b.get("stroke")??y};`)}return f.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${d?-E/2:E/2-h.height})`),I.attr("transform",`translate(0,${d?h.height/2+v/2:-h.height/2-v/2})`),G(t,L),t.intersect=function(A){if(F.info("iconSquare intersect",t,A),!t.label)return z.rect(t,A);const k=t.x??0,$=t.y??0,M=t.height??0;let q=[];return d?q=[{x:k-h.width/2,y:$-M/2},{x:k+h.width/2,y:$-M/2},{x:k+h.width/2,y:$-M/2+h.height+v},{x:k+m/2,y:$-M/2+h.height+v},{x:k+m/2,y:$+M/2},{x:k-m/2,y:$+M/2},{x:k-m/2,y:$-M/2+h.height+v},{x:k-h.width/2,y:$-M/2+h.height+v}]:q=[{x:k-m/2,y:$-M/2},{x:k+m/2,y:$-M/2},{x:k+m/2,y:$-M/2+g},{x:k+h.width/2,y:$-M/2+g},{x:k+h.width/2/2,y:$+M/2},{x:k-h.width/2,y:$+M/2},{x:k-h.width/2,y:$-M/2+g},{x:k-m/2,y:$-M/2+g}],z.polygon(t,q,A)},c}p(lp,"iconRounded");async function cp(e,t,{config:{themeVariables:r,flowchart:i}}){const{labelStyles:a}=U(t);t.labelStyle=a;const n=t.assetHeight??48,o=t.assetWidth??48,s=Math.max(n,o),l=i?.wrappingWidth;t.width=Math.max(s,l??0);const{shapeSvg:c,bbox:h,halfPadding:u,label:f}=await it(e,t,"icon-shape default"),d=t.pos==="t",g=s+u*2,m=s+u*2,{nodeBorder:y,mainBkg:x}=r,{stylesMap:b}=Ur(t),_=-m/2,w=-g/2,v=t.label?8:0,B=j.svg(c),T=Y(t,{});t.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");const O=b.get("fill");T.stroke=O??x;const R=B.path(He(_,w,m,g,.1),T),D=Math.max(m,h.width),E=g+h.height+v,N=B.rectangle(-D/2,-E/2,D,E,{...T,fill:"transparent",stroke:"none"}),I=c.insert(()=>R,":first-child"),L=c.insert(()=>N);if(t.icon){const A=c.append("g");A.html(`<g>${await qi(t.icon,{height:s,width:s,fallbackPrefix:""})}</g>`);const k=A.node().getBBox(),$=k.width,M=k.height,q=k.x,V=k.y;A.attr("transform",`translate(${-$/2-q},${d?h.height/2+v/2-M/2-V:-h.height/2-v/2-M/2-V})`),A.attr("style",`color: ${b.get("stroke")??y};`)}return f.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${d?-E/2:E/2-h.height})`),I.attr("transform",`translate(0,${d?h.height/2+v/2:-h.height/2-v/2})`),G(t,L),t.intersect=function(A){if(F.info("iconSquare intersect",t,A),!t.label)return z.rect(t,A);const k=t.x??0,$=t.y??0,M=t.height??0;let q=[];return d?q=[{x:k-h.width/2,y:$-M/2},{x:k+h.width/2,y:$-M/2},{x:k+h.width/2,y:$-M/2+h.height+v},{x:k+m/2,y:$-M/2+h.height+v},{x:k+m/2,y:$+M/2},{x:k-m/2,y:$+M/2},{x:k-m/2,y:$-M/2+h.height+v},{x:k-h.width/2,y:$-M/2+h.height+v}]:q=[{x:k-m/2,y:$-M/2},{x:k+m/2,y:$-M/2},{x:k+m/2,y:$-M/2+g},{x:k+h.width/2,y:$-M/2+g},{x:k+h.width/2/2,y:$+M/2},{x:k-h.width/2,y:$+M/2},{x:k-h.width/2,y:$-M/2+g},{x:k-m/2,y:$-M/2+g}],z.polygon(t,q,A)},c}p(cp,"iconSquare");async function hp(e,t,{config:{flowchart:r}}){const i=new Image;i.src=t?.img??"",await i.decode();const a=Number(i.naturalWidth.toString().replace("px","")),n=Number(i.naturalHeight.toString().replace("px",""));t.imageAspectRatio=a/n;const{labelStyles:o}=U(t);t.labelStyle=o;const s=r?.wrappingWidth;t.defaultWidth=r?.wrappingWidth;const l=Math.max(t.label?s??0:0,t?.assetWidth??a),c=t.constraint==="on"&&t?.assetHeight?t.assetHeight*t.imageAspectRatio:l,h=t.constraint==="on"?c/t.imageAspectRatio:t?.assetHeight??n;t.width=Math.max(c,s??0);const{shapeSvg:u,bbox:f,label:d}=await it(e,t,"image-shape default"),g=t.pos==="t",m=-c/2,y=-h/2,x=t.label?8:0,b=j.svg(u),_=Y(t,{});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const w=b.rectangle(m,y,c,h,_),v=Math.max(c,f.width),B=h+f.height+x,T=b.rectangle(-v/2,-B/2,v,B,{..._,fill:"none",stroke:"none"}),O=u.insert(()=>w,":first-child"),R=u.insert(()=>T);if(t.img){const D=u.append("image");D.attr("href",t.img),D.attr("width",c),D.attr("height",h),D.attr("preserveAspectRatio","none"),D.attr("transform",`translate(${-c/2},${g?B/2-h:-B/2})`)}return d.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${g?-h/2-f.height/2-x/2:h/2-f.height/2+x/2})`),O.attr("transform",`translate(0,${g?f.height/2+x/2:-f.height/2-x/2})`),G(t,R),t.intersect=function(D){if(F.info("iconSquare intersect",t,D),!t.label)return z.rect(t,D);const E=t.x??0,N=t.y??0,I=t.height??0;let L=[];return g?L=[{x:E-f.width/2,y:N-I/2},{x:E+f.width/2,y:N-I/2},{x:E+f.width/2,y:N-I/2+f.height+x},{x:E+c/2,y:N-I/2+f.height+x},{x:E+c/2,y:N+I/2},{x:E-c/2,y:N+I/2},{x:E-c/2,y:N-I/2+f.height+x},{x:E-f.width/2,y:N-I/2+f.height+x}]:L=[{x:E-c/2,y:N-I/2},{x:E+c/2,y:N-I/2},{x:E+c/2,y:N-I/2+h},{x:E+f.width/2,y:N-I/2+h},{x:E+f.width/2/2,y:N+I/2},{x:E-f.width/2,y:N+I/2},{x:E-f.width/2,y:N-I/2+h},{x:E-c/2,y:N-I/2+h}],z.polygon(t,L,D)},u}p(hp,"imageSquare");async function up(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=Math.max(n.width+(t.padding??0)*2,t?.width??0),s=Math.max(n.height+(t.padding??0)*2,t?.height??0),l=[{x:0,y:0},{x:o,y:0},{x:o+3*s/6,y:-s},{x:-3*s/6,y:-s}];let c;const{cssStyles:h}=t;if(t.look==="handDrawn"){const u=j.svg(a),f=Y(t,{}),d=lt(l),g=u.path(d,f);c=a.insert(()=>g,":first-child").attr("transform",`translate(${-o/2}, ${s/2})`),h&&c.attr("style",h)}else c=je(a,o,s,l);return i&&c.attr("style",i),t.width=o,t.height=s,G(t,c),t.intersect=function(u){return z.polygon(t,l,u)},a}p(up,"inv_trapezoid");async function vn(e,t,r){const{labelStyles:i,nodeStyles:a}=U(t);t.labelStyle=i;const{shapeSvg:n,bbox:o}=await it(e,t,rt(t)),s=Math.max(o.width+r.labelPaddingX*2,t?.width||0),l=Math.max(o.height+r.labelPaddingY*2,t?.height||0),c=-s/2,h=-l/2;let u,{rx:f,ry:d}=t;const{cssStyles:g}=t;if(r?.rx&&r.ry&&(f=r.rx,d=r.ry),t.look==="handDrawn"){const m=j.svg(n),y=Y(t,{}),x=f||d?m.path(He(c,h,s,l,f||0),y):m.rectangle(c,h,s,l,y);u=n.insert(()=>x,":first-child"),u.attr("class","basic label-container").attr("style",Dt(g))}else u=n.insert("rect",":first-child"),u.attr("class","basic label-container").attr("style",a).attr("rx",Dt(f)).attr("ry",Dt(d)).attr("x",c).attr("y",h).attr("width",s).attr("height",l);return G(t,u),t.calcIntersect=function(m,y){return z.rect(m,y)},t.intersect=function(m){return z.rect(t,m)},n}p(vn,"drawRect");async function fp(e,t){const{shapeSvg:r,bbox:i,label:a}=await it(e,t,"label"),n=r.insert("rect",":first-child");return n.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),a.attr("transform",`translate(${-(i.width/2)-(i.x-(i.left??0))}, ${-(i.height/2)-(i.y-(i.top??0))})`),G(t,n),t.intersect=function(l){return z.rect(t,l)},r}p(fp,"labelRect");async function dp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=Math.max(n.width+(t.padding??0),t?.width??0),s=Math.max(n.height+(t.padding??0),t?.height??0),l=[{x:0,y:0},{x:o+3*s/6,y:0},{x:o,y:-s},{x:-(3*s)/6,y:-s}];let c;const{cssStyles:h}=t;if(t.look==="handDrawn"){const u=j.svg(a),f=Y(t,{}),d=lt(l),g=u.path(d,f);c=a.insert(()=>g,":first-child").attr("transform",`translate(${-o/2}, ${s/2})`),h&&c.attr("style",h)}else c=je(a,o,s,l);return i&&c.attr("style",i),t.width=o,t.height=s,G(t,c),t.intersect=function(u){return z.polygon(t,l,u)},a}p(dp,"lean_left");async function pp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=Math.max(n.width+(t.padding??0),t?.width??0),s=Math.max(n.height+(t.padding??0),t?.height??0),l=[{x:-3*s/6,y:0},{x:o,y:0},{x:o+3*s/6,y:-s},{x:0,y:-s}];let c;const{cssStyles:h}=t;if(t.look==="handDrawn"){const u=j.svg(a),f=Y(t,{}),d=lt(l),g=u.path(d,f);c=a.insert(()=>g,":first-child").attr("transform",`translate(${-o/2}, ${s/2})`),h&&c.attr("style",h)}else c=je(a,o,s,l);return i&&c.attr("style",i),t.width=o,t.height=s,G(t,c),t.intersect=function(u){return z.polygon(t,l,u)},a}p(pp,"lean_right");function gp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.label="",t.labelStyle=r;const a=e.insert("g").attr("class",rt(t)).attr("id",t.domId??t.id),{cssStyles:n}=t,o=Math.max(35,t?.width??0),s=Math.max(35,t?.height??0),l=7,c=[{x:o,y:0},{x:0,y:s+l/2},{x:o-2*l,y:s+l/2},{x:0,y:2*s},{x:o,y:s-l/2},{x:2*l,y:s-l/2}],h=j.svg(a),u=Y(t,{});t.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");const f=lt(c),d=h.path(f,u),g=a.insert(()=>d,":first-child");return n&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",n),i&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",i),g.attr("transform",`translate(-${o/2},${-s})`),G(t,g),t.intersect=function(m){return F.info("lightningBolt intersect",t,m),z.polygon(t,c,m)},a}p(gp,"lightningBolt");var yw=p((e,t,r,i,a,n,o)=>[`M${e},${t+n}`,`a${a},${n} 0,0,0 ${r},0`,`a${a},${n} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${n} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+n+o}`,`a${a},${n} 0,0,0 ${r},0`].join(" "),"createCylinderPathD"),xw=p((e,t,r,i,a,n,o)=>[`M${e},${t+n}`,`M${e+r},${t+n}`,`a${a},${n} 0,0,0 ${-r},0`,`l0,${i}`,`a${a},${n} 0,0,0 ${r},0`,`l0,${-i}`,`M${e},${t+n+o}`,`a${a},${n} 0,0,0 ${r},0`].join(" "),"createOuterCylinderPathD"),bw=p((e,t,r,i,a,n)=>[`M${e-r/2},${-i/2}`,`a${a},${n} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");async function mp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0),t.width??0),l=s/2,c=l/(2.5+s/50),h=Math.max(n.height+c+(t.padding??0),t.height??0),u=h*.1;let f;const{cssStyles:d}=t;if(t.look==="handDrawn"){const g=j.svg(a),m=xw(0,0,s,h,l,c,u),y=bw(0,c,s,h,l,c),x=Y(t,{}),b=g.path(m,x),_=g.path(y,x);a.insert(()=>_,":first-child").attr("class","line"),f=a.insert(()=>b,":first-child"),f.attr("class","basic label-container"),d&&f.attr("style",d)}else{const g=yw(0,0,s,h,l,c,u);f=a.insert("path",":first-child").attr("d",g).attr("class","basic label-container").attr("style",Dt(d)).attr("style",i)}return f.attr("label-offset-y",c),f.attr("transform",`translate(${-s/2}, ${-(h/2+c)})`),G(t,f),o.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${-(n.height/2)+c-(n.y-(n.top??0))})`),t.intersect=function(g){const m=z.rect(t,g),y=m.x-(t.x??0);if(l!=0&&(Math.abs(y)<(t.width??0)/2||Math.abs(y)==(t.width??0)/2&&Math.abs(m.y-(t.y??0))>(t.height??0)/2-c)){let x=c*c*(1-y*y/(l*l));x>0&&(x=Math.sqrt(x)),x=c-x,g.y-(t.y??0)>0&&(x=-x),m.y+=x}return m},a}p(mp,"linedCylinder");async function yp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=l/4,h=l+c,{cssStyles:u}=t,f=j.svg(a),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=[{x:-s/2-s/2*.1,y:-h/2},{x:-s/2-s/2*.1,y:h/2},...We(-s/2-s/2*.1,h/2,s/2+s/2*.1,h/2,c,.8),{x:s/2+s/2*.1,y:-h/2},{x:-s/2-s/2*.1,y:-h/2},{x:-s/2,y:-h/2},{x:-s/2,y:h/2*1.1},{x:-s/2,y:-h/2}],m=f.polygon(g.map(x=>[x.x,x.y]),d),y=a.insert(()=>m,":first-child");return y.attr("class","basic label-container"),u&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",u),i&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",i),y.attr("transform",`translate(0,${-c/2})`),o.attr("transform",`translate(${-s/2+(t.padding??0)+s/2*.1/2-(n.x-(n.left??0))},${-l/2+(t.padding??0)-c/2-(n.y-(n.top??0))})`),G(t,y),t.intersect=function(x){return z.polygon(t,g,x)},a}p(yp,"linedWaveEdgedRect");async function xp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=5,h=-s/2,u=-l/2,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{}),m=[{x:h-c,y:u+c},{x:h-c,y:u+l+c},{x:h+s-c,y:u+l+c},{x:h+s-c,y:u+l},{x:h+s,y:u+l},{x:h+s,y:u+l-c},{x:h+s+c,y:u+l-c},{x:h+s+c,y:u-c},{x:h+c,y:u-c},{x:h+c,y:u},{x:h,y:u},{x:h,y:u+c}],y=[{x:h,y:u+c},{x:h+s-c,y:u+c},{x:h+s-c,y:u+l},{x:h+s,y:u+l},{x:h+s,y:u},{x:h,y:u}];t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const x=lt(m),b=d.path(x,g),_=lt(y),w=d.path(_,{...g,fill:"none"}),v=a.insert(()=>w,":first-child");return v.insert(()=>b,":first-child"),v.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",i),o.attr("transform",`translate(${-(n.width/2)-c-(n.x-(n.left??0))}, ${-(n.height/2)+c-(n.y-(n.top??0))})`),G(t,v),t.intersect=function(B){return z.polygon(t,m,B)},a}p(xp,"multiRect");async function bp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=l/4,h=l+c,u=-s/2,f=-h/2,d=5,{cssStyles:g}=t,m=We(u-d,f+h+d,u+s-d,f+h+d,c,.8),y=m?.[m.length-1],x=[{x:u-d,y:f+d},{x:u-d,y:f+h+d},...m,{x:u+s-d,y:y.y-d},{x:u+s,y:y.y-d},{x:u+s,y:y.y-2*d},{x:u+s+d,y:y.y-2*d},{x:u+s+d,y:f-d},{x:u+d,y:f-d},{x:u+d,y:f},{x:u,y:f},{x:u,y:f+d}],b=[{x:u,y:f+d},{x:u+s-d,y:f+d},{x:u+s-d,y:y.y-d},{x:u+s,y:y.y-d},{x:u+s,y:f},{x:u,y:f}],_=j.svg(a),w=Y(t,{});t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");const v=lt(x),B=_.path(v,w),T=lt(b),O=_.path(T,w),R=a.insert(()=>B,":first-child");return R.insert(()=>O),R.attr("class","basic label-container"),g&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",g),i&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",i),R.attr("transform",`translate(0,${-c/2})`),o.attr("transform",`translate(${-(n.width/2)-d-(n.x-(n.left??0))}, ${-(n.height/2)+d-c/2-(n.y-(n.top??0))})`),G(t,R),t.intersect=function(D){return z.polygon(t,x,D)},a}p(bp,"multiWaveEdgedRectangle");async function _p(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:a}=U(t);t.labelStyle=i,t.useHtmlLabels||Ft().flowchart?.htmlLabels!==!1||(t.centerLabel=!0);const{shapeSvg:o,bbox:s,label:l}=await it(e,t,rt(t)),c=Math.max(s.width+(t.padding??0)*2,t?.width??0),h=Math.max(s.height+(t.padding??0)*2,t?.height??0),u=-c/2,f=-h/2,{cssStyles:d}=t,g=j.svg(o),m=Y(t,{fill:r.noteBkgColor,stroke:r.noteBorderColor});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const y=g.rectangle(u,f,c,h,m),x=o.insert(()=>y,":first-child");return x.attr("class","basic label-container"),d&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",d),a&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",a),l.attr("transform",`translate(${-s.width/2-(s.x-(s.left??0))}, ${-(s.height/2)-(s.y-(s.top??0))})`),G(t,x),t.intersect=function(b){return z.rect(t,b)},o}p(_p,"note");var _w=p((e,t,r)=>[`M${e+r/2},${t}`,`L${e+r},${t-r/2}`,`L${e+r/2},${t-r}`,`L${e},${t-r/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function Cp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.width+t.padding,s=n.height+t.padding,l=o+s,c=.5,h=[{x:l/2,y:0},{x:l,y:-l/2},{x:l/2,y:-l},{x:0,y:-l/2}];let u;const{cssStyles:f}=t;if(t.look==="handDrawn"){const d=j.svg(a),g=Y(t,{}),m=_w(0,0,l),y=d.path(m,g);u=a.insert(()=>y,":first-child").attr("transform",`translate(${-l/2+c}, ${l/2})`),f&&u.attr("style",f)}else u=je(a,l,l,h),u.attr("transform",`translate(${-l/2+c}, ${l/2})`);return i&&u.attr("style",i),G(t,u),t.calcIntersect=function(d,g){const m=d.width,y=[{x:m/2,y:0},{x:m,y:-m/2},{x:m/2,y:-m},{x:0,y:-m/2}],x=z.polygon(d,y,g);return{x:x.x-.5,y:x.y-.5}},t.intersect=function(d){return this.calcIntersect(t,d)},a}p(Cp,"question");async function vp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0),t?.width??0),l=Math.max(n.height+(t.padding??0),t?.height??0),c=-s/2,h=-l/2,u=h/2,f=[{x:c+u,y:h},{x:c,y:0},{x:c+u,y:-h},{x:-c,y:-h},{x:-c,y:h}],{cssStyles:d}=t,g=j.svg(a),m=Y(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const y=lt(f),x=g.path(y,m),b=a.insert(()=>x,":first-child");return b.attr("class","basic label-container"),d&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",i),b.attr("transform",`translate(${-u/2},0)`),o.attr("transform",`translate(${-u/2-n.width/2-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),G(t,b),t.intersect=function(_){return z.polygon(t,f,_)},a}p(vp,"rect_left_inv_arrow");async function wp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;let a;t.cssClasses?a="node "+t.cssClasses:a="node default";const n=e.insert("g").attr("class",a).attr("id",t.domId||t.id),o=n.insert("g"),s=n.insert("g").attr("class","label").attr("style",i),l=t.description,c=t.label,h=s.node().appendChild(await er(c,t.labelStyle,!0,!0));let u={width:0,height:0};if(kt(ut()?.flowchart?.htmlLabels)){const O=h.children[0],R=ht(h);u=O.getBoundingClientRect(),R.attr("width",u.width),R.attr("height",u.height)}F.info("Text 2",l);const f=l||[],d=h.getBBox(),g=s.node().appendChild(await er(f.join?f.join("<br/>"):f,t.labelStyle,!0,!0)),m=g.children[0],y=ht(g);u=m.getBoundingClientRect(),y.attr("width",u.width),y.attr("height",u.height);const x=(t.padding||0)/2;ht(g).attr("transform","translate( "+(u.width>d.width?0:(d.width-u.width)/2)+", "+(d.height+x+5)+")"),ht(h).attr("transform","translate( "+(u.width<d.width?0:-(d.width-u.width)/2)+", 0)"),u=s.node().getBBox(),s.attr("transform","translate("+-u.width/2+", "+(-u.height/2-x+3)+")");const b=u.width+(t.padding||0),_=u.height+(t.padding||0),w=-u.width/2-x,v=-u.height/2-x;let B,T;if(t.look==="handDrawn"){const O=j.svg(n),R=Y(t,{}),D=O.path(He(w,v,b,_,t.rx||0),R),E=O.line(-u.width/2-x,-u.height/2-x+d.height+x,u.width/2+x,-u.height/2-x+d.height+x,R);T=n.insert(()=>(F.debug("Rough node insert CXC",D),E),":first-child"),B=n.insert(()=>(F.debug("Rough node insert CXC",D),D),":first-child")}else B=o.insert("rect",":first-child"),T=o.insert("line"),B.attr("class","outer title-state").attr("style",i).attr("x",-u.width/2-x).attr("y",-u.height/2-x).attr("width",u.width+(t.padding||0)).attr("height",u.height+(t.padding||0)),T.attr("class","divider").attr("x1",-u.width/2-x).attr("x2",u.width/2+x).attr("y1",-u.height/2-x+d.height+x).attr("y2",-u.height/2-x+d.height+x);return G(t,B),t.intersect=function(O){return z.rect(t,O)},n}p(wp,"rectWithTitle");function pi(e,t,r,i,a,n,o){const l=(e+r)/2,c=(t+i)/2,h=Math.atan2(i-t,r-e),u=(r-e)/2,f=(i-t)/2,d=u/a,g=f/n,m=Math.sqrt(d**2+g**2);if(m>1)throw new Error("The given radii are too small to create an arc between the points.");const y=Math.sqrt(1-m**2),x=l+y*n*Math.sin(h)*(o?-1:1),b=c-y*a*Math.cos(h)*(o?-1:1),_=Math.atan2((t-b)/n,(e-x)/a);let v=Math.atan2((i-b)/n,(r-x)/a)-_;o&&v<0&&(v+=2*Math.PI),!o&&v>0&&(v-=2*Math.PI);const B=[];for(let T=0;T<20;T++){const O=T/19,R=_+O*v,D=x+a*Math.cos(R),E=b+n*Math.sin(R);B.push({x:D,y:E})}return B}p(pi,"generateArcPoints");async function Sp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=t?.padding??0,s=t?.padding??0,l=(t?.width?t?.width:n.width)+o*2,c=(t?.height?t?.height:n.height)+s*2,h=t.radius||5,u=t.taper||5,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{});t.stroke&&(g.stroke=t.stroke),t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:-l/2+u,y:-c/2},{x:l/2-u,y:-c/2},...pi(l/2-u,-c/2,l/2,-c/2+u,h,h,!0),{x:l/2,y:-c/2+u},{x:l/2,y:c/2-u},...pi(l/2,c/2-u,l/2-u,c/2,h,h,!0),{x:l/2-u,y:c/2},{x:-l/2+u,y:c/2},...pi(-l/2+u,c/2,-l/2,c/2-u,h,h,!0),{x:-l/2,y:c/2-u},{x:-l/2,y:-c/2+u},...pi(-l/2,-c/2+u,-l/2+u,-c/2,h,h,!0)],y=lt(m),x=d.path(y,g),b=a.insert(()=>x,":first-child");return b.attr("class","basic label-container outer-path"),f&&t.look!=="handDrawn"&&b.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&b.selectChildren("path").attr("style",i),G(t,b),t.intersect=function(_){return z.polygon(t,m,_)},a}p(Sp,"roundedRect");async function kp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=t?.padding??0,l=Math.max(n.width+(t.padding??0)*2,t?.width??0),c=Math.max(n.height+(t.padding??0)*2,t?.height??0),h=-n.width/2-s,u=-n.height/2-s,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=[{x:h,y:u},{x:h+l+8,y:u},{x:h+l+8,y:u+c},{x:h-8,y:u+c},{x:h-8,y:u},{x:h,y:u},{x:h,y:u+c}],y=d.polygon(m.map(b=>[b.x,b.y]),g),x=a.insert(()=>y,":first-child");return x.attr("class","basic label-container").attr("style",Dt(f)),i&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",i),f&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",i),o.attr("transform",`translate(${-l/2+4+(t.padding??0)-(n.x-(n.left??0))},${-c/2+(t.padding??0)-(n.y-(n.top??0))})`),G(t,x),t.intersect=function(b){return z.rect(t,b)},a}p(kp,"shadedProcess");async function Tp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=-s/2,h=-l/2,{cssStyles:u}=t,f=j.svg(a),d=Y(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");const g=[{x:c,y:h},{x:c,y:h+l},{x:c+s,y:h+l},{x:c+s,y:h-l/2}],m=lt(g),y=f.path(m,d),x=a.insert(()=>y,":first-child");return x.attr("class","basic label-container"),u&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",u),i&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",i),x.attr("transform",`translate(0, ${l/4})`),o.attr("transform",`translate(${-s/2+(t.padding??0)-(n.x-(n.left??0))}, ${-l/4+(t.padding??0)-(n.y-(n.top??0))})`),G(t,x),t.intersect=function(b){return z.polygon(t,g,b)},a}p(Tp,"slopedRect");async function Lp(e,t){const r={rx:0,ry:0,labelPaddingX:t.labelPaddingX??(t?.padding||0)*2,labelPaddingY:(t?.padding||0)*1};return vn(e,t,r)}p(Lp,"squareRect");async function Bp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.height+t.padding,s=n.width+o/4+t.padding,l=o/2,{cssStyles:c}=t,h=j.svg(a),u=Y(t,{});t.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");const f=[{x:-s/2+l,y:-o/2},{x:s/2-l,y:-o/2},...$i(-s/2+l,0,l,50,90,270),{x:s/2-l,y:o/2},...$i(s/2-l,0,l,50,270,450)],d=lt(f),g=h.path(d,u),m=a.insert(()=>g,":first-child");return m.attr("class","basic label-container outer-path"),c&&t.look!=="handDrawn"&&m.selectChildren("path").attr("style",c),i&&t.look!=="handDrawn"&&m.selectChildren("path").attr("style",i),G(t,m),t.intersect=function(y){return z.polygon(t,f,y)},a}p(Bp,"stadium");async function Ap(e,t){return vn(e,t,{rx:5,ry:5})}p(Ap,"state");function Mp(e,t,{config:{themeVariables:r}}){const{labelStyles:i,nodeStyles:a}=U(t);t.labelStyle=i;const{cssStyles:n}=t,{lineColor:o,stateBorder:s,nodeBorder:l}=r,c=e.insert("g").attr("class","node default").attr("id",t.domId||t.id),h=j.svg(c),u=Y(t,{});t.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");const f=h.circle(0,0,14,{...u,stroke:o,strokeWidth:2}),d=s??l,g=h.circle(0,0,5,{...u,fill:d,stroke:d,strokeWidth:2,fillStyle:"solid"}),m=c.insert(()=>f,":first-child");return m.insert(()=>g),n&&m.selectAll("path").attr("style",n),a&&m.selectAll("path").attr("style",a),G(t,m),t.intersect=function(y){return z.circle(t,7,y)},c}p(Mp,"stateEnd");function Ep(e,t,{config:{themeVariables:r}}){const{lineColor:i}=r,a=e.insert("g").attr("class","node default").attr("id",t.domId||t.id);let n;if(t.look==="handDrawn"){const s=j.svg(a).circle(0,0,14,x2(i));n=a.insert(()=>s),n.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14)}else n=a.insert("circle",":first-child"),n.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14);return G(t,n),t.intersect=function(o){return z.circle(t,7,o)},a}p(Ep,"stateStart");async function $p(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=(t?.padding||0)/2,s=n.width+t.padding,l=n.height+t.padding,c=-n.width/2-o,h=-n.height/2-o,u=[{x:0,y:0},{x:s,y:0},{x:s,y:-l},{x:0,y:-l},{x:0,y:0},{x:-8,y:0},{x:s+8,y:0},{x:s+8,y:-l},{x:-8,y:-l},{x:-8,y:0}];if(t.look==="handDrawn"){const f=j.svg(a),d=Y(t,{}),g=f.rectangle(c-8,h,s+16,l,d),m=f.line(c,h,c,h+l,d),y=f.line(c+s,h,c+s,h+l,d);a.insert(()=>m,":first-child"),a.insert(()=>y,":first-child");const x=a.insert(()=>g,":first-child"),{cssStyles:b}=t;x.attr("class","basic label-container").attr("style",Dt(b)),G(t,x)}else{const f=je(a,s,l,u);i&&f.attr("style",i),G(t,f)}return t.intersect=function(f){return z.polygon(t,u,f)},a}p($p,"subroutine");async function Fp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=Math.max(n.width+(t.padding??0)*2,t?.width??0),s=Math.max(n.height+(t.padding??0)*2,t?.height??0),l=-o/2,c=-s/2,h=.2*s,u=.2*s,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{}),m=[{x:l-h/2,y:c},{x:l+o+h/2,y:c},{x:l+o+h/2,y:c+s},{x:l-h/2,y:c+s}],y=[{x:l+o-h/2,y:c+s},{x:l+o+h/2,y:c+s},{x:l+o+h/2,y:c+s-u}];t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const x=lt(m),b=d.path(x,g),_=lt(y),w=d.path(_,{...g,fillStyle:"solid"}),v=a.insert(()=>w,":first-child");return v.insert(()=>b,":first-child"),v.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",i),G(t,v),t.intersect=function(B){return z.polygon(t,m,B)},a}p(Fp,"taggedRect");async function Op(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=l/4,h=.2*s,u=.2*l,f=l+c,{cssStyles:d}=t,g=j.svg(a),m=Y(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");const y=[{x:-s/2-s/2*.1,y:f/2},...We(-s/2-s/2*.1,f/2,s/2+s/2*.1,f/2,c,.8),{x:s/2+s/2*.1,y:-f/2},{x:-s/2-s/2*.1,y:-f/2}],x=-s/2+s/2*.1,b=-f/2-u*.4,_=[{x:x+s-h,y:(b+l)*1.4},{x:x+s,y:b+l-u},{x:x+s,y:(b+l)*.9},...We(x+s,(b+l)*1.3,x+s-h,(b+l)*1.5,-l*.03,.5)],w=lt(y),v=g.path(w,m),B=lt(_),T=g.path(B,{...m,fillStyle:"solid"}),O=a.insert(()=>T,":first-child");return O.insert(()=>v,":first-child"),O.attr("class","basic label-container"),d&&t.look!=="handDrawn"&&O.selectAll("path").attr("style",d),i&&t.look!=="handDrawn"&&O.selectAll("path").attr("style",i),O.attr("transform",`translate(0,${-c/2})`),o.attr("transform",`translate(${-s/2+(t.padding??0)-(n.x-(n.left??0))},${-l/2+(t.padding??0)-c/2-(n.y-(n.top??0))})`),G(t,O),t.intersect=function(R){return z.polygon(t,y,R)},a}p(Op,"taggedWaveEdgedRectangle");async function Dp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=Math.max(n.width+t.padding,t?.width||0),s=Math.max(n.height+t.padding,t?.height||0),l=-o/2,c=-s/2,h=a.insert("rect",":first-child");return h.attr("class","text").attr("style",i).attr("rx",0).attr("ry",0).attr("x",l).attr("y",c).attr("width",o).attr("height",s),G(t,h),t.intersect=function(u){return z.rect(t,u)},a}p(Dp,"text");var Cw=p((e,t,r,i,a,n)=>`M${e},${t}
|
|
126
|
+
a${a},${n} 0,0,1 0,${-i}
|
|
127
|
+
l${r},0
|
|
128
|
+
a${a},${n} 0,0,1 0,${i}
|
|
129
|
+
M${r},${-i}
|
|
130
|
+
a${a},${n} 0,0,0 0,${i}
|
|
131
|
+
l${-r},0`,"createCylinderPathD"),vw=p((e,t,r,i,a,n)=>[`M${e},${t}`,`M${e+r},${t}`,`a${a},${n} 0,0,0 0,${-i}`,`l${-r},0`,`a${a},${n} 0,0,0 0,${i}`,`l${r},0`].join(" "),"createOuterCylinderPathD"),ww=p((e,t,r,i,a,n)=>[`M${e+r/2},${-i/2}`,`a${a},${n} 0,0,0 0,${i}`].join(" "),"createInnerCylinderPathD");async function Ip(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o,halfPadding:s}=await it(e,t,rt(t)),l=t.look==="neo"?s*2:s,c=n.height+l,h=c/2,u=h/(2.5+c/50),f=n.width+u+l,{cssStyles:d}=t;let g;if(t.look==="handDrawn"){const m=j.svg(a),y=vw(0,0,f,c,u,h),x=ww(0,0,f,c,u,h),b=m.path(y,Y(t,{})),_=m.path(x,Y(t,{fill:"none"}));g=a.insert(()=>_,":first-child"),g=a.insert(()=>b,":first-child"),g.attr("class","basic label-container"),d&&g.attr("style",d)}else{const m=Cw(0,0,f,c,u,h);g=a.insert("path",":first-child").attr("d",m).attr("class","basic label-container").attr("style",Dt(d)).attr("style",i),g.attr("class","basic label-container"),d&&g.selectAll("path").attr("style",d),i&&g.selectAll("path").attr("style",i)}return g.attr("label-offset-x",u),g.attr("transform",`translate(${-f/2}, ${c/2} )`),o.attr("transform",`translate(${-(n.width/2)-u-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),G(t,g),t.intersect=function(m){const y=z.rect(t,m),x=y.y-(t.y??0);if(h!=0&&(Math.abs(x)<(t.height??0)/2||Math.abs(x)==(t.height??0)/2&&Math.abs(y.x-(t.x??0))>(t.width??0)/2-u)){let b=u*u*(1-x*x/(h*h));b!=0&&(b=Math.sqrt(Math.abs(b))),b=u-b,m.x-(t.x??0)>0&&(b=-b),y.x+=b}return y},a}p(Ip,"tiltedCylinder");async function Rp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=n.width+t.padding,s=n.height+t.padding,l=[{x:-3*s/6,y:0},{x:o+3*s/6,y:0},{x:o,y:-s},{x:0,y:-s}];let c;const{cssStyles:h}=t;if(t.look==="handDrawn"){const u=j.svg(a),f=Y(t,{}),d=lt(l),g=u.path(d,f);c=a.insert(()=>g,":first-child").attr("transform",`translate(${-o/2}, ${s/2})`),h&&c.attr("style",h)}else c=je(a,o,s,l);return i&&c.attr("style",i),t.width=o,t.height=s,G(t,c),t.intersect=function(u){return z.polygon(t,l,u)},a}p(Rp,"trapezoid");async function Pp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=60,s=20,l=Math.max(o,n.width+(t.padding??0)*2,t?.width??0),c=Math.max(s,n.height+(t.padding??0)*2,t?.height??0),{cssStyles:h}=t,u=j.svg(a),f=Y(t,{});t.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");const d=[{x:-l/2*.8,y:-c/2},{x:l/2*.8,y:-c/2},{x:l/2,y:-c/2*.6},{x:l/2,y:c/2},{x:-l/2,y:c/2},{x:-l/2,y:-c/2*.6}],g=lt(d),m=u.path(g,f),y=a.insert(()=>m,":first-child");return y.attr("class","basic label-container"),h&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",h),i&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",i),G(t,y),t.intersect=function(x){return z.polygon(t,d,x)},a}p(Pp,"trapezoidalPentagon");async function Np(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=kt(ut().flowchart?.htmlLabels),l=n.width+(t.padding??0),c=l+n.height,h=l+n.height,u=[{x:0,y:0},{x:h,y:0},{x:h/2,y:-c}],{cssStyles:f}=t,d=j.svg(a),g=Y(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=lt(u),y=d.path(m,g),x=a.insert(()=>y,":first-child").attr("transform",`translate(${-c/2}, ${c/2})`);return f&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",f),i&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",i),t.width=l,t.height=c,G(t,x),o.attr("transform",`translate(${-n.width/2-(n.x-(n.left??0))}, ${c/2-(n.height+(t.padding??0)/(s?2:1)-(n.y-(n.top??0)))})`),t.intersect=function(b){return F.info("Triangle intersect",t,u,b),z.polygon(t,u,b)},a}p(Np,"triangle");async function Wp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=l/8,h=l+c,{cssStyles:u}=t,d=70-s,g=d>0?d/2:0,m=j.svg(a),y=Y(t,{});t.look!=="handDrawn"&&(y.roughness=0,y.fillStyle="solid");const x=[{x:-s/2-g,y:h/2},...We(-s/2-g,h/2,s/2+g,h/2,c,.8),{x:s/2+g,y:-h/2},{x:-s/2-g,y:-h/2}],b=lt(x),_=m.path(b,y),w=a.insert(()=>_,":first-child");return w.attr("class","basic label-container"),u&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",u),i&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",i),w.attr("transform",`translate(0,${-c/2})`),o.attr("transform",`translate(${-s/2+(t.padding??0)-(n.x-(n.left??0))},${-l/2+(t.padding??0)-c-(n.y-(n.top??0))})`),G(t,w),t.intersect=function(v){return z.polygon(t,x,v)},a}p(Wp,"waveEdgedRectangle");async function zp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n}=await it(e,t,rt(t)),o=100,s=50,l=Math.max(n.width+(t.padding??0)*2,t?.width??0),c=Math.max(n.height+(t.padding??0)*2,t?.height??0),h=l/c;let u=l,f=c;u>f*h?f=u/h:u=f*h,u=Math.max(u,o),f=Math.max(f,s);const d=Math.min(f*.2,f/4),g=f+d*2,{cssStyles:m}=t,y=j.svg(a),x=Y(t,{});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");const b=[{x:-u/2,y:g/2},...We(-u/2,g/2,u/2,g/2,d,1),{x:u/2,y:-g/2},...We(u/2,-g/2,-u/2,-g/2,d,-1)],_=lt(b),w=y.path(_,x),v=a.insert(()=>w,":first-child");return v.attr("class","basic label-container"),m&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",m),i&&t.look!=="handDrawn"&&v.selectAll("path").attr("style",i),G(t,v),t.intersect=function(B){return z.polygon(t,b,B)},a}p(zp,"waveRectangle");async function qp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,label:o}=await it(e,t,rt(t)),s=Math.max(n.width+(t.padding??0)*2,t?.width??0),l=Math.max(n.height+(t.padding??0)*2,t?.height??0),c=5,h=-s/2,u=-l/2,{cssStyles:f}=t,d=j.svg(a),g=Y(t,{}),m=[{x:h-c,y:u-c},{x:h-c,y:u+l},{x:h+s,y:u+l},{x:h+s,y:u-c}],y=`M${h-c},${u-c} L${h+s},${u-c} L${h+s},${u+l} L${h-c},${u+l} L${h-c},${u-c}
|
|
132
|
+
M${h-c},${u} L${h+s},${u}
|
|
133
|
+
M${h},${u-c} L${h},${u+l}`;t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const x=d.path(y,g),b=a.insert(()=>x,":first-child");return b.attr("transform",`translate(${c/2}, ${c/2})`),b.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",f),i&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",i),o.attr("transform",`translate(${-(n.width/2)+c/2-(n.x-(n.left??0))}, ${-(n.height/2)+c/2-(n.y-(n.top??0))})`),G(t,b),t.intersect=function(_){return z.polygon(t,m,_)},a}p(qp,"windowPane");async function zo(e,t){const r=t;if(r.alias&&(t.label=r.alias),t.look==="handDrawn"){const{themeVariables:J}=Ft(),{background:X}=J,ct={...t,id:t.id+"-background",look:"default",cssStyles:["stroke: none",`fill: ${X}`]};await zo(e,ct)}const i=Ft();t.useHtmlLabels=i.htmlLabels;let a=i.er?.diagramPadding??10,n=i.er?.entityPadding??6;const{cssStyles:o}=t,{labelStyles:s,nodeStyles:l}=U(t);if(r.attributes.length===0&&t.label){const J={rx:0,ry:0,labelPaddingX:a,labelPaddingY:a*1.5};Me(t.label,i)+J.labelPaddingX*2<i.er.minEntityWidth&&(t.width=i.er.minEntityWidth);const X=await vn(e,t,J);if(!kt(i.htmlLabels)){const ct=X.select("text"),nt=ct.node()?.getBBox();ct.attr("transform",`translate(${-nt.width/2}, 0)`)}return X}i.htmlLabels||(a*=1.25,n*=1.25);let c=rt(t);c||(c="node default");const h=e.insert("g").attr("class",c).attr("id",t.domId||t.id),u=await wr(h,t.label??"",i,0,0,["name"],s);u.height+=n;let f=0;const d=[],g=[];let m=0,y=0,x=0,b=0,_=!0,w=!0;for(const J of r.attributes){const X=await wr(h,J.type,i,0,f,["attribute-type"],s);m=Math.max(m,X.width+a);const ct=await wr(h,J.name,i,0,f,["attribute-name"],s);y=Math.max(y,ct.width+a);const nt=await wr(h,J.keys.join(),i,0,f,["attribute-keys"],s);x=Math.max(x,nt.width+a);const xt=await wr(h,J.comment,i,0,f,["attribute-comment"],s);b=Math.max(b,xt.width+a);const bt=Math.max(X.height,ct.height,nt.height,xt.height)+n;g.push({yOffset:f,rowHeight:bt}),f+=bt}let v=4;x<=a&&(_=!1,x=0,v--),b<=a&&(w=!1,b=0,v--);const B=h.node().getBBox();if(u.width+a*2-(m+y+x+b)>0){const J=u.width+a*2-(m+y+x+b);m+=J/v,y+=J/v,x>0&&(x+=J/v),b>0&&(b+=J/v)}const T=m+y+x+b,O=j.svg(h),R=Y(t,{});t.look!=="handDrawn"&&(R.roughness=0,R.fillStyle="solid");let D=0;g.length>0&&(D=g.reduce((J,X)=>J+(X?.rowHeight??0),0));const E=Math.max(B.width+a*2,t?.width||0,T),N=Math.max((D??0)+u.height,t?.height||0),I=-E/2,L=-N/2;h.selectAll("g:not(:first-child)").each((J,X,ct)=>{const nt=ht(ct[X]),xt=nt.attr("transform");let bt=0,ee=0;if(xt){const mt=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(xt);mt&&(bt=parseFloat(mt[1]),ee=parseFloat(mt[2]),nt.attr("class").includes("attribute-name")?bt+=m:nt.attr("class").includes("attribute-keys")?bt+=m+y:nt.attr("class").includes("attribute-comment")&&(bt+=m+y+x))}nt.attr("transform",`translate(${I+a/2+bt}, ${ee+L+u.height+n/2})`)}),h.select(".name").attr("transform","translate("+-u.width/2+", "+(L+n/2)+")");const A=O.rectangle(I,L,E,N,R),k=h.insert(()=>A,":first-child").attr("style",o.join("")),{themeVariables:$}=Ft(),{rowEven:M,rowOdd:q,nodeBorder:V}=$;d.push(0);for(const[J,X]of g.entries()){const nt=(J+1)%2===0&&X.yOffset!==0,xt=O.rectangle(I,u.height+L+X?.yOffset,E,X?.rowHeight,{...R,fill:nt?M:q,stroke:V});h.insert(()=>xt,"g.label").attr("style",o.join("")).attr("class",`row-rect-${nt?"even":"odd"}`)}let Z=O.line(I,u.height+L,E+I,u.height+L,R);h.insert(()=>Z).attr("class","divider"),Z=O.line(m+I,u.height+L,m+I,N+L,R),h.insert(()=>Z).attr("class","divider"),_&&(Z=O.line(m+y+I,u.height+L,m+y+I,N+L,R),h.insert(()=>Z).attr("class","divider")),w&&(Z=O.line(m+y+x+I,u.height+L,m+y+x+I,N+L,R),h.insert(()=>Z).attr("class","divider"));for(const J of d)Z=O.line(I,u.height+L+J,E+I,u.height+L+J,R),h.insert(()=>Z).attr("class","divider");if(G(t,k),l&&t.look!=="handDrawn"){const X=l.split(";")?.filter(ct=>ct.includes("stroke"))?.map(ct=>`${ct}`).join("; ");h.selectAll("path").attr("style",X??""),h.selectAll(".row-rect-even path").attr("style",l)}return t.intersect=function(J){return z.rect(t,J)},h}p(zo,"erBox");async function wr(e,t,r,i=0,a=0,n=[],o=""){const s=e.insert("g").attr("class",`label ${n.join(" ")}`).attr("transform",`translate(${i}, ${a})`).attr("style",o);t!==vl(t)&&(t=vl(t),t=t.replaceAll("<","<").replaceAll(">",">"));const l=s.node().appendChild(await qe(s,t,{width:Me(t,r)+100,style:o,useHtmlLabels:r.htmlLabels},r));if(t.includes("<")||t.includes(">")){let h=l.children[0];for(h.textContent=h.textContent.replaceAll("<","<").replaceAll(">",">");h.childNodes[0];)h=h.childNodes[0],h.textContent=h.textContent.replaceAll("<","<").replaceAll(">",">")}let c=l.getBBox();if(kt(r.htmlLabels)){const h=l.children[0];h.style.textAlign="start";const u=ht(l);c=h.getBoundingClientRect(),u.attr("width",c.width),u.attr("height",c.height)}return c}p(wr,"addText");async function Hp(e,t,r,i,a=r.class.padding??12){const n=i?0:3,o=e.insert("g").attr("class",rt(t)).attr("id",t.domId||t.id);let s=null,l=null,c=null,h=null,u=0,f=0,d=0;if(s=o.insert("g").attr("class","annotation-group text"),t.annotations.length>0){const b=t.annotations[0];await gi(s,{text:`«${b}»`},0),u=s.node().getBBox().height}l=o.insert("g").attr("class","label-group text"),await gi(l,t,0,["font-weight: bolder"]);const g=l.node().getBBox();f=g.height,c=o.insert("g").attr("class","members-group text");let m=0;for(const b of t.members){const _=await gi(c,b,m,[b.parseClassifier()]);m+=_+n}d=c.node().getBBox().height,d<=0&&(d=a/2),h=o.insert("g").attr("class","methods-group text");let y=0;for(const b of t.methods){const _=await gi(h,b,y,[b.parseClassifier()]);y+=_+n}let x=o.node().getBBox();if(s!==null){const b=s.node().getBBox();s.attr("transform",`translate(${-b.width/2})`)}return l.attr("transform",`translate(${-g.width/2}, ${u})`),x=o.node().getBBox(),c.attr("transform",`translate(0, ${u+f+a*2})`),x=o.node().getBBox(),h.attr("transform",`translate(0, ${u+f+(d?d+a*4:a*2)})`),x=o.node().getBBox(),{shapeSvg:o,bbox:x}}p(Hp,"textHelper");async function gi(e,t,r,i=[]){const a=e.insert("g").attr("class","label").attr("style",i.join("; ")),n=Ft();let o="useHtmlLabels"in t?t.useHtmlLabels:kt(n.htmlLabels)??!0,s="";"text"in t?s=t.text:s=t.label,!o&&s.startsWith("\\")&&(s=s.substring(1)),Pr(s)&&(o=!0);const l=await qe(a,no(dr(s)),{width:Me(s,n)+50,classes:"markdown-node-label",useHtmlLabels:o},n);let c,h=1;if(o){const u=l.children[0],f=ht(l);h=u.innerHTML.split("<br>").length,u.innerHTML.includes("</math>")&&(h+=u.innerHTML.split("<mrow>").length-1);const d=u.getElementsByTagName("img");if(d){const g=s.replace(/<img[^>]*>/g,"").trim()==="";await Promise.all([...d].map(m=>new Promise(y=>{function x(){if(m.style.display="flex",m.style.flexDirection="column",g){const b=n.fontSize?.toString()??window.getComputedStyle(document.body).fontSize,w=parseInt(b,10)*5+"px";m.style.minWidth=w,m.style.maxWidth=w}else m.style.width="100%";y(m)}p(x,"setupImage"),setTimeout(()=>{m.complete&&x()}),m.addEventListener("error",x),m.addEventListener("load",x)})))}c=u.getBoundingClientRect(),f.attr("width",c.width),f.attr("height",c.height)}else{i.includes("font-weight: bolder")&&ht(l).selectAll("tspan").attr("font-weight",""),h=l.children.length;const u=l.children[0];(l.textContent===""||l.textContent.includes(">"))&&(u.textContent=s[0]+s.substring(1).replaceAll(">",">").replaceAll("<","<").trim(),s[1]===" "&&(u.textContent=u.textContent[0]+" "+u.textContent.substring(1))),u.textContent==="undefined"&&(u.textContent=""),c=l.getBBox()}return a.attr("transform","translate(0,"+(-c.height/(2*h)+r)+")"),c.height}p(gi,"addText");async function jp(e,t){const r=ut(),i=r.class.padding??12,a=i,n=t.useHtmlLabels??kt(r.htmlLabels)??!0,o=t;o.annotations=o.annotations??[],o.members=o.members??[],o.methods=o.methods??[];const{shapeSvg:s,bbox:l}=await Hp(e,t,r,n,a),{labelStyles:c,nodeStyles:h}=U(t);t.labelStyle=c,t.cssStyles=o.styles||"";const u=o.styles?.join(";")||h||"";t.cssStyles||(t.cssStyles=u.replaceAll("!important","").split(";"));const f=o.members.length===0&&o.methods.length===0&&!r.class?.hideEmptyMembersBox,d=j.svg(s),g=Y(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");const m=l.width;let y=l.height;o.members.length===0&&o.methods.length===0?y+=a:o.members.length>0&&o.methods.length===0&&(y+=a*2);const x=-m/2,b=-y/2,_=d.rectangle(x-i,b-i-(f?i:o.members.length===0&&o.methods.length===0?-i/2:0),m+2*i,y+2*i+(f?i*2:o.members.length===0&&o.methods.length===0?-i:0),g),w=s.insert(()=>_,":first-child");w.attr("class","basic label-container");const v=w.node().getBBox();s.selectAll(".text").each((R,D,E)=>{const N=ht(E[D]),I=N.attr("transform");let L=0;if(I){const M=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(I);M&&(L=parseFloat(M[2]))}let A=L+b+i-(f?i:o.members.length===0&&o.methods.length===0?-i/2:0);n||(A-=4);let k=x;(N.attr("class").includes("label-group")||N.attr("class").includes("annotation-group"))&&(k=-N.node()?.getBBox().width/2||0,s.selectAll("text").each(function($,M,q){window.getComputedStyle(q[M]).textAnchor==="middle"&&(k=0)})),N.attr("transform",`translate(${k}, ${A})`)});const B=s.select(".annotation-group").node().getBBox().height-(f?i/2:0)||0,T=s.select(".label-group").node().getBBox().height-(f?i/2:0)||0,O=s.select(".members-group").node().getBBox().height-(f?i/2:0)||0;if(o.members.length>0||o.methods.length>0||f){const R=d.line(v.x,B+T+b+i,v.x+v.width,B+T+b+i,g);s.insert(()=>R).attr("class","divider").attr("style",u)}if(f||o.members.length>0||o.methods.length>0){const R=d.line(v.x,B+T+O+b+a*2+i,v.x+v.width,B+T+O+b+i+a*2,g);s.insert(()=>R).attr("class","divider").attr("style",u)}if(o.look!=="handDrawn"&&s.selectAll("path").attr("style",u),w.select(":nth-child(2)").attr("style",u),s.selectAll(".divider").select("path").attr("style",u),t.labelStyle?s.selectAll("span").attr("style",t.labelStyle):s.selectAll("span").attr("style",u),!n){const R=RegExp(/color\s*:\s*([^;]*)/),D=R.exec(u);if(D){const E=D[0].replace("color","fill");s.selectAll("tspan").attr("style",E)}else if(c){const E=R.exec(c);if(E){const N=E[0].replace("color","fill");s.selectAll("tspan").attr("style",N)}}}return G(t,w),t.intersect=function(R){return z.rect(t,R)},s}p(jp,"classBox");async function Yp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const a=t,n=t,o=20,s=20,l="verifyMethod"in t,c=rt(t),h=e.insert("g").attr("class",c).attr("id",t.domId??t.id);let u;l?u=await ue(h,`<<${a.type}>>`,0,t.labelStyle):u=await ue(h,"<<Element>>",0,t.labelStyle);let f=u;const d=await ue(h,a.name,f,t.labelStyle+"; font-weight: bold;");if(f+=d+s,l){const B=await ue(h,`${a.requirementId?`ID: ${a.requirementId}`:""}`,f,t.labelStyle);f+=B;const T=await ue(h,`${a.text?`Text: ${a.text}`:""}`,f,t.labelStyle);f+=T;const O=await ue(h,`${a.risk?`Risk: ${a.risk}`:""}`,f,t.labelStyle);f+=O,await ue(h,`${a.verifyMethod?`Verification: ${a.verifyMethod}`:""}`,f,t.labelStyle)}else{const B=await ue(h,`${n.type?`Type: ${n.type}`:""}`,f,t.labelStyle);f+=B,await ue(h,`${n.docRef?`Doc Ref: ${n.docRef}`:""}`,f,t.labelStyle)}const g=(h.node()?.getBBox().width??200)+o,m=(h.node()?.getBBox().height??200)+o,y=-g/2,x=-m/2,b=j.svg(h),_=Y(t,{});t.look!=="handDrawn"&&(_.roughness=0,_.fillStyle="solid");const w=b.rectangle(y,x,g,m,_),v=h.insert(()=>w,":first-child");if(v.attr("class","basic label-container").attr("style",i),h.selectAll(".label").each((B,T,O)=>{const R=ht(O[T]),D=R.attr("transform");let E=0,N=0;if(D){const k=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(D);k&&(E=parseFloat(k[1]),N=parseFloat(k[2]))}const I=N-m/2;let L=y+o/2;(T===0||T===1)&&(L=E),R.attr("transform",`translate(${L}, ${I+o})`)}),f>u+d+s){const B=b.line(y,x+u+d+s,y+g,x+u+d+s,_);h.insert(()=>B).attr("style",i)}return G(t,v),t.intersect=function(B){return z.rect(t,B)},h}p(Yp,"requirementBox");async function ue(e,t,r,i=""){if(t==="")return 0;const a=e.insert("g").attr("class","label").attr("style",i),n=ut(),o=n.htmlLabels??!0,s=await qe(a,no(dr(t)),{width:Me(t,n)+50,classes:"markdown-node-label",useHtmlLabels:o,style:i},n);let l;if(o){const c=s.children[0],h=ht(s);l=c.getBoundingClientRect(),h.attr("width",l.width),h.attr("height",l.height)}else{const c=s.children[0];for(const h of c.children)h.textContent=h.textContent.replaceAll(">",">").replaceAll("<","<"),i&&h.setAttribute("style",i);l=s.getBBox(),l.height+=6}return a.attr("transform",`translate(${-l.width/2},${-l.height/2+r})`),l.height}p(ue,"addText");var Sw=p(e=>{switch(e){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function Up(e,t,{config:r}){const{labelStyles:i,nodeStyles:a}=U(t);t.labelStyle=i||"";const n=10,o=t.width;t.width=(t.width??200)-10;const{shapeSvg:s,bbox:l,label:c}=await it(e,t,rt(t)),h=t.padding||10;let u="",f;"ticket"in t&&t.ticket&&r?.kanban?.ticketBaseUrl&&(u=r?.kanban?.ticketBaseUrl.replace("#TICKET#",t.ticket),f=s.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",u).attr("target","_blank"));const d={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||"",width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1};let g,m;f?{label:g,bbox:m}=await ts(f,"ticket"in t&&t.ticket||"",d):{label:g,bbox:m}=await ts(s,"ticket"in t&&t.ticket||"",d);const{label:y,bbox:x}=await ts(s,"assigned"in t&&t.assigned||"",d);t.width=o;const b=10,_=t?.width||0,w=Math.max(m.height,x.height)/2,v=Math.max(l.height+b*2,t?.height||0)+w,B=-_/2,T=-v/2;c.attr("transform","translate("+(h-_/2)+", "+(-w-l.height/2)+")"),g.attr("transform","translate("+(h-_/2)+", "+(-w+l.height/2)+")"),y.attr("transform","translate("+(h+_/2-x.width-2*n)+", "+(-w+l.height/2)+")");let O;const{rx:R,ry:D}=t,{cssStyles:E}=t;if(t.look==="handDrawn"){const N=j.svg(s),I=Y(t,{}),L=R||D?N.path(He(B,T,_,v,R||0),I):N.rectangle(B,T,_,v,I);O=s.insert(()=>L,":first-child"),O.attr("class","basic label-container").attr("style",E||null)}else{O=s.insert("rect",":first-child"),O.attr("class","basic label-container __APA__").attr("style",a).attr("rx",R??5).attr("ry",D??5).attr("x",B).attr("y",T).attr("width",_).attr("height",v);const N="priority"in t&&t.priority;if(N){const I=s.append("line"),L=B+2,A=T+Math.floor((R??0)/2),k=T+v-Math.floor((R??0)/2);I.attr("x1",L).attr("y1",A).attr("x2",L).attr("y2",k).attr("stroke-width","4").attr("stroke",Sw(N))}}return G(t,O),t.height=v,t.intersect=function(N){return z.rect(t,N)},s}p(Up,"kanbanItem");async function Gp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,halfPadding:o,label:s}=await it(e,t,rt(t)),l=n.width+10*o,c=n.height+8*o,h=.15*l,{cssStyles:u}=t,f=n.width+20,d=n.height+20,g=Math.max(l,f),m=Math.max(c,d);s.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`);let y;const x=`M0 0
|
|
134
|
+
a${h},${h} 1 0,0 ${g*.25},${-1*m*.1}
|
|
135
|
+
a${h},${h} 1 0,0 ${g*.25},0
|
|
136
|
+
a${h},${h} 1 0,0 ${g*.25},0
|
|
137
|
+
a${h},${h} 1 0,0 ${g*.25},${m*.1}
|
|
138
|
+
|
|
139
|
+
a${h},${h} 1 0,0 ${g*.15},${m*.33}
|
|
140
|
+
a${h*.8},${h*.8} 1 0,0 0,${m*.34}
|
|
141
|
+
a${h},${h} 1 0,0 ${-1*g*.15},${m*.33}
|
|
142
|
+
|
|
143
|
+
a${h},${h} 1 0,0 ${-1*g*.25},${m*.15}
|
|
144
|
+
a${h},${h} 1 0,0 ${-1*g*.25},0
|
|
145
|
+
a${h},${h} 1 0,0 ${-1*g*.25},0
|
|
146
|
+
a${h},${h} 1 0,0 ${-1*g*.25},${-1*m*.15}
|
|
147
|
+
|
|
148
|
+
a${h},${h} 1 0,0 ${-1*g*.1},${-1*m*.33}
|
|
149
|
+
a${h*.8},${h*.8} 1 0,0 0,${-1*m*.34}
|
|
150
|
+
a${h},${h} 1 0,0 ${g*.1},${-1*m*.33}
|
|
151
|
+
H0 V0 Z`;if(t.look==="handDrawn"){const b=j.svg(a),_=Y(t,{}),w=b.path(x,_);y=a.insert(()=>w,":first-child"),y.attr("class","basic label-container").attr("style",Dt(u))}else y=a.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",x);return y.attr("transform",`translate(${-g/2}, ${-m/2})`),G(t,y),t.calcIntersect=function(b,_){return z.rect(b,_)},t.intersect=function(b){return F.info("Bang intersect",t,b),z.rect(t,b)},a}p(Gp,"bang");async function Vp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,halfPadding:o,label:s}=await it(e,t,rt(t)),l=n.width+2*o,c=n.height+2*o,h=.15*l,u=.25*l,f=.35*l,d=.2*l,{cssStyles:g}=t;let m;const y=`M0 0
|
|
152
|
+
a${h},${h} 0 0,1 ${l*.25},${-1*l*.1}
|
|
153
|
+
a${f},${f} 1 0,1 ${l*.4},${-1*l*.1}
|
|
154
|
+
a${u},${u} 1 0,1 ${l*.35},${l*.2}
|
|
155
|
+
|
|
156
|
+
a${h},${h} 1 0,1 ${l*.15},${c*.35}
|
|
157
|
+
a${d},${d} 1 0,1 ${-1*l*.15},${c*.65}
|
|
158
|
+
|
|
159
|
+
a${u},${h} 1 0,1 ${-1*l*.25},${l*.15}
|
|
160
|
+
a${f},${f} 1 0,1 ${-1*l*.5},0
|
|
161
|
+
a${h},${h} 1 0,1 ${-1*l*.25},${-1*l*.15}
|
|
162
|
+
|
|
163
|
+
a${h},${h} 1 0,1 ${-1*l*.1},${-1*c*.35}
|
|
164
|
+
a${d},${d} 1 0,1 ${l*.1},${-1*c*.65}
|
|
165
|
+
H0 V0 Z`;if(t.look==="handDrawn"){const x=j.svg(a),b=Y(t,{}),_=x.path(y,b);m=a.insert(()=>_,":first-child"),m.attr("class","basic label-container").attr("style",Dt(g))}else m=a.insert("path",":first-child").attr("class","basic label-container").attr("style",i).attr("d",y);return s.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`),m.attr("transform",`translate(${-l/2}, ${-c/2})`),G(t,m),t.calcIntersect=function(x,b){return z.rect(x,b)},t.intersect=function(x){return F.info("Cloud intersect",t,x),z.rect(t,x)},a}p(Vp,"cloud");async function Xp(e,t){const{labelStyles:r,nodeStyles:i}=U(t);t.labelStyle=r;const{shapeSvg:a,bbox:n,halfPadding:o,label:s}=await it(e,t,rt(t)),l=n.width+8*o,c=n.height+2*o,h=5,u=`
|
|
166
|
+
M${-l/2} ${c/2-h}
|
|
167
|
+
v${-c+2*h}
|
|
168
|
+
q0,-${h} ${h},-${h}
|
|
169
|
+
h${l-2*h}
|
|
170
|
+
q${h},0 ${h},${h}
|
|
171
|
+
v${c-2*h}
|
|
172
|
+
q0,${h} -${h},${h}
|
|
173
|
+
h${-l+2*h}
|
|
174
|
+
q-${h},0 -${h},-${h}
|
|
175
|
+
Z
|
|
176
|
+
`,f=a.append("path").attr("id","node-"+t.id).attr("class","node-bkg node-"+t.type).attr("style",i).attr("d",u);return a.append("line").attr("class","node-line-").attr("x1",-l/2).attr("y1",c/2).attr("x2",l/2).attr("y2",c/2),s.attr("transform",`translate(${-n.width/2}, ${-n.height/2})`),a.append(()=>s.node()),G(t,f),t.calcIntersect=function(d,g){return z.rect(d,g)},t.intersect=function(d){return z.rect(t,d)},a}p(Xp,"defaultMindmapNode");async function Kp(e,t){const r={padding:t.padding??0};return Wo(e,t,r)}p(Kp,"mindmapCircle");var kw=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:Lp},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:Sp},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:Bp},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:$p},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:Zd},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:Wo},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:Gp},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:Vp},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Cp},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:ap},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:pp},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:dp},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:Rp},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:up},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:Jd},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:Dp},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:Hd},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:kp},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:Ep},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:Mp},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:rp},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:np},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:Gd},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:Vd},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:Xd},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:gp},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:Wp},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:ip},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:Ip},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:mp},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:Kd},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:Qd},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:Np},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:qp},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:tp},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:Pp},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:ep},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:Tp},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:bp},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:xp},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:qd},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:Ud},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:Op},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:Fp},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:zp},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:vp},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:yp}],Tw=p(()=>{const t=[...Object.entries({state:Ap,choice:jd,note:_p,rectWithTitle:wp,labelRect:fp,iconSquare:cp,iconCircle:op,icon:sp,iconRounded:lp,imageSquare:hp,anchor:zd,kanbanItem:Up,mindmapCircle:Kp,defaultMindmapNode:Xp,classBox:jp,erBox:zo,requirementBox:Yp}),...kw.flatMap(r=>[r.shortName,..."aliases"in r?r.aliases:[],..."internalAliases"in r?r.internalAliases:[]].map(a=>[a,r.handler]))];return Object.fromEntries(t)},"generateShapeMap"),Zp=Tw();function Lw(e){return e in Zp}p(Lw,"isValidShape");var wn=new Map;async function Qp(e,t,r){let i,a;t.shape==="rect"&&(t.rx&&t.ry?t.shape="roundedRect":t.shape="squareRect");const n=t.shape?Zp[t.shape]:void 0;if(!n)throw new Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let o;r.config.securityLevel==="sandbox"?o="_top":t.linkTarget&&(o=t.linkTarget||"_blank"),i=e.insert("svg:a").attr("xlink:href",t.link).attr("target",o??null),a=await n(i,t,r)}else a=await n(e,t,r),i=a;return t.tooltip&&a.attr("title",t.tooltip),wn.set(t.id,i),t.haveCallback&&i.attr("class",i.attr("class")+" clickable"),i}p(Qp,"insertNode");var OL=p((e,t)=>{wn.set(t.id,e)},"setNodeElem"),DL=p(()=>{wn.clear()},"clear"),IL=p(e=>{const t=wn.get(e.id);F.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");const r=8,i=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+i-e.width/2)+", "+(e.y-e.height/2-r)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),i},"positionNode"),Bw=p((e,t,r,i,a,n)=>{t.arrowTypeStart&&kc(e,"start",t.arrowTypeStart,r,i,a,n),t.arrowTypeEnd&&kc(e,"end",t.arrowTypeEnd,r,i,a,n)},"addEdgeMarkers"),Aw={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},kc=p((e,t,r,i,a,n,o)=>{const s=Aw[r];if(!s){F.warn(`Unknown arrow type: ${r}`);return}const l=s.type,h=`${a}_${n}-${l}${t==="start"?"Start":"End"}`;if(o&&o.trim()!==""){const u=o.replace(/[^\dA-Za-z]/g,"_"),f=`${h}_${u}`;if(!document.getElementById(f)){const d=document.getElementById(h);if(d){const g=d.cloneNode(!0);g.id=f,g.querySelectorAll("path, circle, line").forEach(y=>{y.setAttribute("stroke",o),s.fill&&y.setAttribute("fill",o)}),d.parentNode?.appendChild(g)}}e.attr(`marker-${t}`,`url(${i}#${f})`)}else e.attr(`marker-${t}`,`url(${i}#${h})`)},"addEdgeMarker"),Ja=new Map,At=new Map,RL=p(()=>{Ja.clear(),At.clear()},"clear"),na=p(e=>e?e.reduce((r,i)=>r+";"+i,""):"","getLabelStyles"),Mw=p(async(e,t)=>{let r=kt(ut().flowchart.htmlLabels);const{labelStyles:i}=U(t);t.labelStyle=i;const a=await qe(e,t.label,{style:t.labelStyle,useHtmlLabels:r,addSvgBackground:!0,isNode:!1});F.info("abc82",t,t.labelType);const n=e.insert("g").attr("class","edgeLabel"),o=n.insert("g").attr("class","label").attr("data-id",t.id);o.node().appendChild(a);let s=a.getBBox();if(r){const c=a.children[0],h=ht(a);s=c.getBoundingClientRect(),h.attr("width",s.width),h.attr("height",s.height)}o.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),Ja.set(t.id,n),t.width=s.width,t.height=s.height;let l;if(t.startLabelLeft){const c=await er(t.startLabelLeft,na(t.labelStyle)),h=e.insert("g").attr("class","edgeTerminals"),u=h.insert("g").attr("class","inner");l=u.node().appendChild(c);const f=c.getBBox();u.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),At.get(t.id)||At.set(t.id,{}),At.get(t.id).startLeft=h,mi(l,t.startLabelLeft)}if(t.startLabelRight){const c=await er(t.startLabelRight,na(t.labelStyle)),h=e.insert("g").attr("class","edgeTerminals"),u=h.insert("g").attr("class","inner");l=h.node().appendChild(c),u.node().appendChild(c);const f=c.getBBox();u.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),At.get(t.id)||At.set(t.id,{}),At.get(t.id).startRight=h,mi(l,t.startLabelRight)}if(t.endLabelLeft){const c=await er(t.endLabelLeft,na(t.labelStyle)),h=e.insert("g").attr("class","edgeTerminals"),u=h.insert("g").attr("class","inner");l=u.node().appendChild(c);const f=c.getBBox();u.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),h.node().appendChild(c),At.get(t.id)||At.set(t.id,{}),At.get(t.id).endLeft=h,mi(l,t.endLabelLeft)}if(t.endLabelRight){const c=await er(t.endLabelRight,na(t.labelStyle)),h=e.insert("g").attr("class","edgeTerminals"),u=h.insert("g").attr("class","inner");l=u.node().appendChild(c);const f=c.getBBox();u.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),h.node().appendChild(c),At.get(t.id)||At.set(t.id,{}),At.get(t.id).endRight=h,mi(l,t.endLabelRight)}return a},"insertEdgeLabel");function mi(e,t){ut().flowchart.htmlLabels&&e&&(e.style.width=t.length*9+"px",e.style.height="12px")}p(mi,"setTerminalWidth");var Ew=p((e,t)=>{F.debug("Moving label abc88 ",e.id,e.label,Ja.get(e.id),t);let r=t.updatedPath?t.updatedPath:t.originalPath;const i=ut(),{subGraphTitleTotalMargin:a}=To(i);if(e.label){const n=Ja.get(e.id);let o=e.x,s=e.y;if(r){const l=ne.calcLabelPosition(r);F.debug("Moving label "+e.label+" from (",o,",",s,") to (",l.x,",",l.y,") abc88"),t.updatedPath&&(o=l.x,s=l.y)}n.attr("transform",`translate(${o}, ${s+a/2})`)}if(e.startLabelLeft){const n=At.get(e.id).startLeft;let o=e.x,s=e.y;if(r){const l=ne.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",r);o=l.x,s=l.y}n.attr("transform",`translate(${o}, ${s})`)}if(e.startLabelRight){const n=At.get(e.id).startRight;let o=e.x,s=e.y;if(r){const l=ne.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",r);o=l.x,s=l.y}n.attr("transform",`translate(${o}, ${s})`)}if(e.endLabelLeft){const n=At.get(e.id).endLeft;let o=e.x,s=e.y;if(r){const l=ne.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",r);o=l.x,s=l.y}n.attr("transform",`translate(${o}, ${s})`)}if(e.endLabelRight){const n=At.get(e.id).endRight;let o=e.x,s=e.y;if(r){const l=ne.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",r);o=l.x,s=l.y}n.attr("transform",`translate(${o}, ${s})`)}},"positionEdgeLabel"),$w=p((e,t)=>{const r=e.x,i=e.y,a=Math.abs(t.x-r),n=Math.abs(t.y-i),o=e.width/2,s=e.height/2;return a>=o||n>=s},"outsideNode"),Fw=p((e,t,r)=>{F.debug(`intersection calc abc89:
|
|
177
|
+
outsidePoint: ${JSON.stringify(t)}
|
|
178
|
+
insidePoint : ${JSON.stringify(r)}
|
|
179
|
+
node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);const i=e.x,a=e.y,n=Math.abs(i-r.x),o=e.width/2;let s=r.x<t.x?o-n:o+n;const l=e.height/2,c=Math.abs(t.y-r.y),h=Math.abs(t.x-r.x);if(Math.abs(a-t.y)*o>Math.abs(i-t.x)*l){let u=r.y<t.y?t.y-l-a:a-l-t.y;s=h*u/c;const f={x:r.x<t.x?r.x+s:r.x-h+s,y:r.y<t.y?r.y+c-u:r.y-c+u};return s===0&&(f.x=t.x,f.y=t.y),h===0&&(f.x=t.x),c===0&&(f.y=t.y),F.debug(`abc89 top/bottom calc, Q ${c}, q ${u}, R ${h}, r ${s}`,f),f}else{r.x<t.x?s=t.x-o-i:s=i-o-t.x;let u=c*s/h,f=r.x<t.x?r.x+h-s:r.x-h+s,d=r.y<t.y?r.y+u:r.y-u;return F.debug(`sides calc abc89, Q ${c}, q ${u}, R ${h}, r ${s}`,{_x:f,_y:d}),s===0&&(f=t.x,d=t.y),h===0&&(f=t.x),c===0&&(d=t.y),{x:f,y:d}}},"intersection"),Tc=p((e,t)=>{F.warn("abc88 cutPathAtIntersect",e,t);let r=[],i=e[0],a=!1;return e.forEach(n=>{if(F.info("abc88 checking point",n,t),!$w(t,n)&&!a){const o=Fw(t,i,n);F.debug("abc88 inside",n,i,o),F.debug("abc88 intersection",o,t);let s=!1;r.forEach(l=>{s=s||l.x===o.x&&l.y===o.y}),r.some(l=>l.x===o.x&&l.y===o.y)?F.warn("abc88 no intersect",o,r):r.push(o),a=!0}else F.warn("abc88 outside",n,i),i=n,a||r.push(n)}),F.debug("returning points",r),r},"cutPathAtIntersect");function Jp(e){const t=[],r=[];for(let i=1;i<e.length-1;i++){const a=e[i-1],n=e[i],o=e[i+1];(a.x===n.x&&n.y===o.y&&Math.abs(n.x-o.x)>5&&Math.abs(n.y-a.y)>5||a.y===n.y&&n.x===o.x&&Math.abs(n.x-a.x)>5&&Math.abs(n.y-o.y)>5)&&(t.push(n),r.push(i))}return{cornerPoints:t,cornerPointPositions:r}}p(Jp,"extractCornerPoints");var Lc=p(function(e,t,r){const i=t.x-e.x,a=t.y-e.y,n=Math.sqrt(i*i+a*a),o=r/n;return{x:t.x-o*i,y:t.y-o*a}},"findAdjacentPoint"),Ow=p(function(e){const{cornerPointPositions:t}=Jp(e),r=[];for(let i=0;i<e.length;i++)if(t.includes(i)){const a=e[i-1],n=e[i+1],o=e[i],s=Lc(a,o,5),l=Lc(n,o,5),c=l.x-s.x,h=l.y-s.y;r.push(s);const u=Math.sqrt(2)*2;let f={x:o.x,y:o.y};if(Math.abs(n.x-a.x)>10&&Math.abs(n.y-a.y)>=10){F.debug("Corner point fixing",Math.abs(n.x-a.x),Math.abs(n.y-a.y));const d=5;o.x===s.x?f={x:c<0?s.x-d+u:s.x+d-u,y:h<0?s.y-u:s.y+u}:f={x:c<0?s.x-u:s.x+u,y:h<0?s.y-d+u:s.y+d-u}}else F.debug("Corner point skipping fixing",Math.abs(n.x-a.x),Math.abs(n.y-a.y));r.push(f,l)}else r.push(e[i]);return r},"fixCorners"),Dw=p((e,t,r)=>{const i=e-t-r,a=2,n=2,o=a+n,s=Math.floor(i/o),l=Array(s).fill(`${a} ${n}`).join(" ");return`0 ${t} ${l} ${r}`},"generateDashArray"),Iw=p(function(e,t,r,i,a,n,o,s=!1){const{handDrawnSeed:l}=ut();let c=t.points,h=!1;const u=a;var f=n;const d=[];for(const L in t.cssCompiledStyles)zf(L)||d.push(t.cssCompiledStyles[L]);F.debug("UIO intersect check",t.points,f.x,u.x),f.intersect&&u.intersect&&!s&&(c=c.slice(1,t.points.length-1),c.unshift(u.intersect(c[0])),F.debug("Last point UIO",t.start,"-->",t.end,c[c.length-1],f,f.intersect(c[c.length-1])),c.push(f.intersect(c[c.length-1])));const g=btoa(JSON.stringify(c));t.toCluster&&(F.info("to cluster abc88",r.get(t.toCluster)),c=Tc(t.points,r.get(t.toCluster).node),h=!0),t.fromCluster&&(F.debug("from cluster abc88",r.get(t.fromCluster),JSON.stringify(c,null,2)),c=Tc(c.reverse(),r.get(t.fromCluster).node).reverse(),h=!0);let m=c.filter(L=>!Number.isNaN(L.y));m=Ow(m);let y=pa;switch(y=Fa,t.curve){case"linear":y=Fa;break;case"basis":y=pa;break;case"cardinal":y=jh;break;case"bumpX":y=Nh;break;case"bumpY":y=Wh;break;case"catmullRom":y=Uh;break;case"monotoneX":y=Qh;break;case"monotoneY":y=Jh;break;case"natural":y=eu;break;case"step":y=ru;break;case"stepAfter":y=au;break;case"stepBefore":y=iu;break;default:y=pa}const{x,y:b}=y2(t),_=t1().x(x).y(b).curve(y);let w;switch(t.thickness){case"normal":w="edge-thickness-normal";break;case"thick":w="edge-thickness-thick";break;case"invisible":w="edge-thickness-invisible";break;default:w="edge-thickness-normal"}switch(t.pattern){case"solid":w+=" edge-pattern-solid";break;case"dotted":w+=" edge-pattern-dotted";break;case"dashed":w+=" edge-pattern-dashed";break;default:w+=" edge-pattern-solid"}let v,B=t.curve==="rounded"?tg(eg(m,t),5):_(m);const T=Array.isArray(t.style)?t.style:[t.style];let O=T.find(L=>L?.startsWith("stroke:")),R=!1;if(t.look==="handDrawn"){const L=j.svg(e);Object.assign([],m);const A=L.path(B,{roughness:.3,seed:l});w+=" transition",v=ht(A).select("path").attr("id",t.id).attr("class"," "+w+(t.classes?" "+t.classes:"")).attr("style",T?T.reduce(($,M)=>$+";"+M,""):"");let k=v.attr("d");v.attr("d",k),e.node().appendChild(v.node())}else{const L=d.join(";"),A=T?T.reduce((J,X)=>J+X+";",""):"";let k="";t.animate&&(k=" edge-animation-fast"),t.animation&&(k=" edge-animation-"+t.animation);const $=(L?L+";"+A+";":A)+";"+(T?T.reduce((J,X)=>J+";"+X,""):"");v=e.append("path").attr("d",B).attr("id",t.id).attr("class"," "+w+(t.classes?" "+t.classes:"")+(k??"")).attr("style",$),O=$.match(/stroke:([^;]+)/)?.[1],R=t.animate===!0||!!t.animation||L.includes("animation");const M=v.node(),q=typeof M.getTotalLength=="function"?M.getTotalLength():0,V=Xl[t.arrowTypeStart]||0,Z=Xl[t.arrowTypeEnd]||0;if(t.look==="neo"&&!R){const X=`stroke-dasharray: ${t.pattern==="dotted"||t.pattern==="dashed"?Dw(q,V,Z):`0 ${V} ${q-V-Z} ${Z}`}; stroke-dashoffset: 0;`;v.attr("style",X+v.attr("style"))}}v.attr("data-edge",!0),v.attr("data-et","edge"),v.attr("data-id",t.id),v.attr("data-points",g),t.showPoints&&m.forEach(L=>{e.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",L.x).attr("cy",L.y)});let D="";(ut().flowchart.arrowMarkerAbsolute||ut().state.arrowMarkerAbsolute)&&(D=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,D=D.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),F.info("arrowTypeStart",t.arrowTypeStart),F.info("arrowTypeEnd",t.arrowTypeEnd),Bw(v,t,D,o,i,O);const E=Math.floor(c.length/2),N=c[E];ne.isLabelCoordinateInPath(N,v.attr("d"))||(h=!0);let I={};return h&&(I.updatedPath=c),I.originalPath=t.points,I},"insertEdge");function tg(e,t){if(e.length<2)return"";let r="";const i=e.length,a=1e-5;for(let n=0;n<i;n++){const o=e[n],s=e[n-1],l=e[n+1];if(n===0)r+=`M${o.x},${o.y}`;else if(n===i-1)r+=`L${o.x},${o.y}`;else{const c=o.x-s.x,h=o.y-s.y,u=l.x-o.x,f=l.y-o.y,d=Math.hypot(c,h),g=Math.hypot(u,f);if(d<a||g<a){r+=`L${o.x},${o.y}`;continue}const m=c/d,y=h/d,x=u/g,b=f/g,_=m*x+y*b,w=Math.max(-1,Math.min(1,_)),v=Math.acos(w);if(v<a||Math.abs(Math.PI-v)<a){r+=`L${o.x},${o.y}`;continue}const B=Math.min(t/Math.sin(v/2),d/2,g/2),T=o.x-m*B,O=o.y-y*B,R=o.x+x*B,D=o.y+b*B;r+=`L${T},${O}`,r+=`Q${o.x},${o.y} ${R},${D}`}}return r}p(tg,"generateRoundedPath");function Hs(e,t){if(!e||!t)return{angle:0,deltaX:0,deltaY:0};const r=t.x-e.x,i=t.y-e.y;return{angle:Math.atan2(i,r),deltaX:r,deltaY:i}}p(Hs,"calculateDeltaAndAngle");function eg(e,t){const r=e.map(a=>({...a}));if(e.length>=2&&$t[t.arrowTypeStart]){const a=$t[t.arrowTypeStart],n=e[0],o=e[1],{angle:s}=Hs(n,o),l=a*Math.cos(s),c=a*Math.sin(s);r[0].x=n.x+l,r[0].y=n.y+c}const i=e.length;if(i>=2&&$t[t.arrowTypeEnd]){const a=$t[t.arrowTypeEnd],n=e[i-1],o=e[i-2],{angle:s}=Hs(o,n),l=a*Math.cos(s),c=a*Math.sin(s);r[i-1].x=n.x-l,r[i-1].y=n.y-c}return r}p(eg,"applyMarkerOffsetsToPoints");var Rw=p((e,t,r,i)=>{t.forEach(a=>{Jw[a](e,r,i)})},"insertMarkers"),Pw=p((e,t,r)=>{F.trace("Making markers for ",r),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},"extension"),Nw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),Ww=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),zw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",r+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),qw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",r+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},"lollipop"),Hw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"point"),jw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"circle"),Yw=p((e,t,r)=>{e.append("marker").attr("id",r+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",r+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},"cross"),Uw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),Gw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneStart").attr("class","marker onlyOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),e.append("defs").append("marker").attr("id",r+"_"+t+"-onlyOneEnd").attr("class","marker onlyOne "+t).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),Vw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneStart").attr("class","marker zeroOrOne "+t).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),i.append("path").attr("d","M9,0 L9,18");const a=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+t).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),a.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),Xw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreStart").attr("class","marker oneOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),e.append("defs").append("marker").attr("id",r+"_"+t+"-oneOrMoreEnd").attr("class","marker oneOrMore "+t).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),Kw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+t).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),i.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");const a=e.append("defs").append("marker").attr("id",r+"_"+t+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+t).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");a.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),a.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),Zw=p((e,t,r)=>{e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0
|
|
180
|
+
L20,10
|
|
181
|
+
M20,10
|
|
182
|
+
L0,20`)},"requirement_arrow"),Qw=p((e,t,r)=>{const i=e.append("defs").append("marker").attr("id",r+"_"+t+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");i.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),i.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),i.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),Jw={extension:Pw,composition:Nw,aggregation:Ww,dependency:zw,lollipop:qw,point:Hw,circle:jw,cross:Yw,barb:Uw,only_one:Gw,zero_or_one:Vw,one_or_more:Xw,zero_or_more:Kw,requirement_arrow:Zw,requirement_contains:Qw},tS=Rw,eS={common:Yr,getConfig:Ft,insertCluster:cw,insertEdge:Iw,insertEdgeLabel:Mw,insertMarkers:tS,insertNode:Qp,interpolateToCurve:Eo,labelHelper:it,log:F,positionEdgeLabel:Ew},Fi={},rg=p(e=>{for(const t of e)Fi[t.name]=t},"registerLayoutLoaders"),rS=p(()=>{rg([{name:"dagre",loader:p(async()=>await ft(()=>import("./dagre-6UL2VRFP-CLN6NsN5.js"),__vite__mapDeps([6,7,8,9,10,11,1,2,0,3,4,5])),"loader")},{name:"cose-bilkent",loader:p(async()=>await ft(()=>import("./cose-bilkent-S5V4N54A-DqXTIalc.js"),__vite__mapDeps([12,13,1,2,0,3,4,5])),"loader")}])},"registerDefaultLayoutLoaders");rS();var PL=p(async(e,t)=>{if(!(e.layoutAlgorithm in Fi))throw new Error(`Unknown layout algorithm: ${e.layoutAlgorithm}`);const r=Fi[e.layoutAlgorithm];return(await r.loader()).render(e,t,eS,{algorithm:r.algorithm})},"render"),NL=p((e="",{fallback:t="dagre"}={})=>{if(e in Fi)return e;if(t in Fi)return F.warn(`Layout algorithm ${e} is not registered. Using ${t} as fallback.`),t;throw new Error(`Both layout algorithms ${e} and ${t} are not registered.`)},"getRegisteredLayoutAlgorithm"),ig="comm",ag="rule",ng="decl",iS="@import",aS="@namespace",nS="@keyframes",sS="@layer",sg=Math.abs,qo=String.fromCharCode;function og(e){return e.trim()}function ba(e,t,r){return e.replace(t,r)}function oS(e,t,r){return e.indexOf(t,r)}function Lr(e,t){return e.charCodeAt(t)|0}function Hr(e,t,r){return e.slice(t,r)}function fe(e){return e.length}function lS(e){return e.length}function sa(e,t){return t.push(e),e}var Sn=1,jr=1,lg=0,te=0,Ct=0,Kr="";function Ho(e,t,r,i,a,n,o,s){return{value:e,root:t,parent:r,type:i,props:a,children:n,line:Sn,column:jr,length:o,return:"",siblings:s}}function cS(){return Ct}function hS(){return Ct=te>0?Lr(Kr,--te):0,jr--,Ct===10&&(jr=1,Sn--),Ct}function oe(){return Ct=te<lg?Lr(Kr,te++):0,jr++,Ct===10&&(jr=1,Sn++),Ct}function De(){return Lr(Kr,te)}function _a(){return te}function kn(e,t){return Hr(Kr,e,t)}function Oi(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function uS(e){return Sn=jr=1,lg=fe(Kr=e),te=0,[]}function fS(e){return Kr="",e}function es(e){return og(kn(te-1,js(e===91?e+2:e===40?e+1:e)))}function dS(e){for(;(Ct=De())&&Ct<33;)oe();return Oi(e)>2||Oi(Ct)>3?"":" "}function pS(e,t){for(;--t&&oe()&&!(Ct<48||Ct>102||Ct>57&&Ct<65||Ct>70&&Ct<97););return kn(e,_a()+(t<6&&De()==32&&oe()==32))}function js(e){for(;oe();)switch(Ct){case e:return te;case 34:case 39:e!==34&&e!==39&&js(Ct);break;case 40:e===41&&js(e);break;case 92:oe();break}return te}function gS(e,t){for(;oe()&&e+Ct!==57;)if(e+Ct===84&&De()===47)break;return"/*"+kn(t,te-1)+"*"+qo(e===47?e:oe())}function mS(e){for(;!Oi(De());)oe();return kn(e,te)}function yS(e){return fS(Ca("",null,null,null,[""],e=uS(e),0,[0],e))}function Ca(e,t,r,i,a,n,o,s,l){for(var c=0,h=0,u=o,f=0,d=0,g=0,m=1,y=1,x=1,b=0,_="",w=a,v=n,B=i,T=_;y;)switch(g=b,b=oe()){case 40:if(g!=108&&Lr(T,u-1)==58){oS(T+=ba(es(b),"&","&\f"),"&\f",sg(c?s[c-1]:0))!=-1&&(x=-1);break}case 34:case 39:case 91:T+=es(b);break;case 9:case 10:case 13:case 32:T+=dS(g);break;case 92:T+=pS(_a()-1,7);continue;case 47:switch(De()){case 42:case 47:sa(xS(gS(oe(),_a()),t,r,l),l),(Oi(g||1)==5||Oi(De()||1)==5)&&fe(T)&&Hr(T,-1,void 0)!==" "&&(T+=" ");break;default:T+="/"}break;case 123*m:s[c++]=fe(T)*x;case 125*m:case 59:case 0:switch(b){case 0:case 125:y=0;case 59+h:x==-1&&(T=ba(T,/\f/g,"")),d>0&&(fe(T)-u||m===0&&g===47)&&sa(d>32?Ac(T+";",i,r,u-1,l):Ac(ba(T," ","")+";",i,r,u-2,l),l);break;case 59:T+=";";default:if(sa(B=Bc(T,t,r,c,h,a,s,_,w=[],v=[],u,n),n),b===123)if(h===0)Ca(T,t,B,B,w,n,u,s,v);else{switch(f){case 99:if(Lr(T,3)===110)break;case 108:if(Lr(T,2)===97)break;default:h=0;case 100:case 109:case 115:}h?Ca(e,B,B,i&&sa(Bc(e,B,B,0,0,a,s,_,a,w=[],u,v),v),a,v,u,s,i?w:v):Ca(T,B,B,B,[""],v,0,s,v)}}c=h=d=0,m=x=1,_=T="",u=o;break;case 58:u=1+fe(T),d=g;default:if(m<1){if(b==123)--m;else if(b==125&&m++==0&&hS()==125)continue}switch(T+=qo(b),b*m){case 38:x=h>0?1:(T+="\f",-1);break;case 44:s[c++]=(fe(T)-1)*x,x=1;break;case 64:De()===45&&(T+=es(oe())),f=De(),h=u=fe(_=T+=mS(_a())),b++;break;case 45:g===45&&fe(T)==2&&(m=0)}}return n}function Bc(e,t,r,i,a,n,o,s,l,c,h,u){for(var f=a-1,d=a===0?n:[""],g=lS(d),m=0,y=0,x=0;m<i;++m)for(var b=0,_=Hr(e,f+1,f=sg(y=o[m])),w=e;b<g;++b)(w=og(y>0?d[b]+" "+_:ba(_,/&\f/g,d[b])))&&(l[x++]=w);return Ho(e,t,r,a===0?ag:s,l,c,h,u)}function xS(e,t,r,i){return Ho(e,t,r,ig,qo(cS()),Hr(e,2,-2),0,i)}function Ac(e,t,r,i,a){return Ho(e,t,r,ng,Hr(e,0,i),Hr(e,i+1,-1),i,a)}function Ys(e,t){for(var r="",i=0;i<e.length;i++)r+=t(e[i],i,e,t)||"";return r}function bS(e,t,r,i){switch(e.type){case sS:if(e.children.length)break;case iS:case aS:case ng:return e.return=e.return||e.value;case ig:return"";case nS:return e.return=e.value+"{"+Ys(e.children,i)+"}";case ag:if(!fe(e.value=e.props.join(",")))return""}return fe(r=Ys(e.children,i))?e.return=e.value+"{"+r+"}":""}var _S=Yf(Object.keys,Object),CS=Object.prototype,vS=CS.hasOwnProperty;function wS(e){if(!mn(e))return _S(e);var t=[];for(var r in Object(e))vS.call(e,r)&&r!="constructor"&&t.push(r);return t}var Us=fr(ye,"DataView"),Gs=fr(ye,"Promise"),Vs=fr(ye,"Set"),Xs=fr(ye,"WeakMap"),Mc="[object Map]",SS="[object Object]",Ec="[object Promise]",$c="[object Set]",Fc="[object WeakMap]",Oc="[object DataView]",kS=ur(Us),TS=ur(Ei),LS=ur(Gs),BS=ur(Vs),AS=ur(Xs),Ke=Gr;(Us&&Ke(new Us(new ArrayBuffer(1)))!=Oc||Ei&&Ke(new Ei)!=Mc||Gs&&Ke(Gs.resolve())!=Ec||Vs&&Ke(new Vs)!=$c||Xs&&Ke(new Xs)!=Fc)&&(Ke=function(e){var t=Gr(e),r=t==SS?e.constructor:void 0,i=r?ur(r):"";if(i)switch(i){case kS:return Oc;case TS:return Mc;case LS:return Ec;case BS:return $c;case AS:return Fc}return t});var MS="[object Map]",ES="[object Set]",$S=Object.prototype,FS=$S.hasOwnProperty;function Dc(e){if(e==null)return!0;if(yn(e)&&(Ua(e)||typeof e=="string"||typeof e.splice=="function"||Ao(e)||Mo(e)||Ya(e)))return!e.length;var t=Ke(e);if(t==MS||t==ES)return!e.size;if(mn(e))return!wS(e).length;for(var r in e)if(FS.call(e,r))return!1;return!0}var cg="c4",OS=p(e=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(e),"detector"),DS=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./c4Diagram-YG6GDRKO-gX9j2-0Z.js");return{diagram:t}},__vite__mapDeps([14,15,1,2,0,3,4,5]));return{id:cg,diagram:e}},"loader"),IS={id:cg,detector:OS,loader:DS},RS=IS,hg="flowchart",PS=p((e,t)=>t?.flowchart?.defaultRenderer==="dagre-wrapper"||t?.flowchart?.defaultRenderer==="elk"?!1:/^\s*graph/.test(e),"detector"),NS=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./flowDiagram-NV44I4VS-DgOYOnAl.js");return{diagram:t}},__vite__mapDeps([16,17,18,19,20,1,2,0,3,4,5]));return{id:hg,diagram:e}},"loader"),WS={id:hg,detector:PS,loader:NS},zS=WS,ug="flowchart-v2",qS=p((e,t)=>t?.flowchart?.defaultRenderer==="dagre-d3"?!1:(t?.flowchart?.defaultRenderer==="elk"&&(t.layout="elk"),/^\s*graph/.test(e)&&t?.flowchart?.defaultRenderer==="dagre-wrapper"?!0:/^\s*flowchart/.test(e)),"detector"),HS=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./flowDiagram-NV44I4VS-DgOYOnAl.js");return{diagram:t}},__vite__mapDeps([16,17,18,19,20,1,2,0,3,4,5]));return{id:ug,diagram:e}},"loader"),jS={id:ug,detector:qS,loader:HS},YS=jS,fg="er",US=p(e=>/^\s*erDiagram/.test(e),"detector"),GS=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./erDiagram-Q2GNP2WA-CkGXgXvC.js");return{diagram:t}},__vite__mapDeps([21,18,19,20,1,2,0,3,4,5]));return{id:fg,diagram:e}},"loader"),VS={id:fg,detector:US,loader:GS},XS=VS,dg="gitGraph",KS=p(e=>/^\s*gitGraph/.test(e),"detector"),ZS=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./gitGraphDiagram-NY62KEGX-Bcm5bNVl.js");return{diagram:t}},__vite__mapDeps([22,23,24,25,1,2,10,8,0,3,4,5]));return{id:dg,diagram:e}},"loader"),QS={id:dg,detector:KS,loader:ZS},JS=QS,pg="gantt",tk=p(e=>/^\s*gantt/.test(e),"detector"),ek=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./ganttDiagram-JELNMOA3-DRLDy2OX.js");return{diagram:t}},__vite__mapDeps([26,1,2,27,28,29,0,3,4,5]));return{id:pg,diagram:e}},"loader"),rk={id:pg,detector:tk,loader:ek},ik=rk,gg="info",ak=p(e=>/^\s*info/.test(e),"detector"),nk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./infoDiagram-WHAUD3N6-BtU1uKqv.js");return{diagram:t}},__vite__mapDeps([30,25,1,2,10,8,0,3,4,5]));return{id:gg,diagram:e}},"loader"),sk={id:gg,detector:ak,loader:nk},mg="pie",ok=p(e=>/^\s*pie/.test(e),"detector"),lk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./pieDiagram-ADFJNKIX-BUiWlVgQ.js");return{diagram:t}},__vite__mapDeps([31,23,25,1,2,10,8,32,33,28,0,3,4,5]));return{id:mg,diagram:e}},"loader"),ck={id:mg,detector:ok,loader:lk},yg="quadrantChart",hk=p(e=>/^\s*quadrantChart/.test(e),"detector"),uk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./quadrantDiagram-AYHSOK5B-C_TyzYH5.js");return{diagram:t}},__vite__mapDeps([34,27,28,29,1,2,0,3,4,5]));return{id:yg,diagram:e}},"loader"),fk={id:yg,detector:hk,loader:uk},dk=fk,xg="xychart",pk=p(e=>/^\s*xychart(-beta)?/.test(e),"detector"),gk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./xychartDiagram-PRI3JC2R-CnlrCSYS.js");return{diagram:t}},__vite__mapDeps([35,28,33,27,29,1,2,0,3,4,5]));return{id:xg,diagram:e}},"loader"),mk={id:xg,detector:pk,loader:gk},yk=mk,bg="requirement",xk=p(e=>/^\s*requirement(Diagram)?/.test(e),"detector"),bk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./requirementDiagram-UZGBJVZJ-BVMFXDeK.js");return{diagram:t}},__vite__mapDeps([36,18,19,1,2,0,3,4,5]));return{id:bg,diagram:e}},"loader"),_k={id:bg,detector:xk,loader:bk},Ck=_k,_g="sequence",vk=p(e=>/^\s*sequenceDiagram/.test(e),"detector"),wk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./sequenceDiagram-WL72ISMW-3uaEP9A9.js");return{diagram:t}},__vite__mapDeps([37,15,24,1,2,0,3,4,5]));return{id:_g,diagram:e}},"loader"),Sk={id:_g,detector:vk,loader:wk},kk=Sk,Cg="class",Tk=p((e,t)=>t?.class?.defaultRenderer==="dagre-wrapper"?!1:/^\s*classDiagram/.test(e),"detector"),Lk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./classDiagram-2ON5EDUG-BtPJeqYQ.js");return{diagram:t}},__vite__mapDeps([38,39,17,18,19,1,2,0,3,4,5]));return{id:Cg,diagram:e}},"loader"),Bk={id:Cg,detector:Tk,loader:Lk},Ak=Bk,vg="classDiagram",Mk=p((e,t)=>/^\s*classDiagram/.test(e)&&t?.class?.defaultRenderer==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(e),"detector"),Ek=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./classDiagram-v2-WZHVMYZB-BtPJeqYQ.js");return{diagram:t}},__vite__mapDeps([40,39,17,18,19,1,2,0,3,4,5]));return{id:vg,diagram:e}},"loader"),$k={id:vg,detector:Mk,loader:Ek},Fk=$k,wg="state",Ok=p((e,t)=>t?.state?.defaultRenderer==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(e),"detector"),Dk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./stateDiagram-FKZM4ZOC-yAiNIUHs.js");return{diagram:t}},__vite__mapDeps([41,42,18,19,7,8,9,10,1,2,0,3,4,5]));return{id:wg,diagram:e}},"loader"),Ik={id:wg,detector:Ok,loader:Dk},Rk=Ik,Sg="stateDiagram",Pk=p((e,t)=>!!(/^\s*stateDiagram-v2/.test(e)||/^\s*stateDiagram/.test(e)&&t?.state?.defaultRenderer==="dagre-wrapper"),"detector"),Nk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./stateDiagram-v2-4FDKWEC3-BRP3xAkf.js");return{diagram:t}},__vite__mapDeps([43,42,18,19,1,2,0,3,4,5]));return{id:Sg,diagram:e}},"loader"),Wk={id:Sg,detector:Pk,loader:Nk},zk=Wk,kg="journey",qk=p(e=>/^\s*journey/.test(e),"detector"),Hk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./journeyDiagram-XKPGCS4Q-oDLycO4E.js");return{diagram:t}},__vite__mapDeps([44,15,17,32,1,2,0,3,4,5]));return{id:kg,diagram:e}},"loader"),jk={id:kg,detector:qk,loader:Hk},Yk=jk,Uk=p((e,t,r)=>{F.debug(`rendering svg for syntax error
|
|
183
|
+
`);const i=c1(t),a=i.append("g");i.attr("viewBox","0 0 2412 512"),lh(i,100,512,!0),a.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),a.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),a.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),a.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),a.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),a.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),a.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),a.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${r}`)},"draw"),Tg={draw:Uk},Gk=Tg,Vk={db:{},renderer:Tg,parser:{parse:p(()=>{},"parse")}},Xk=Vk,Lg="flowchart-elk",Kk=p((e,t={})=>/^\s*flowchart-elk/.test(e)||/^\s*(flowchart|graph)/.test(e)&&t?.flowchart?.defaultRenderer==="elk"?(t.layout="elk",!0):!1,"detector"),Zk=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./flowDiagram-NV44I4VS-DgOYOnAl.js");return{diagram:t}},__vite__mapDeps([16,17,18,19,20,1,2,0,3,4,5]));return{id:Lg,diagram:e}},"loader"),Qk={id:Lg,detector:Kk,loader:Zk},Jk=Qk,Bg="timeline",tT=p(e=>/^\s*timeline/.test(e),"detector"),eT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./timeline-definition-IT6M3QCI-Bzobs3Yi.js");return{diagram:t}},__vite__mapDeps([45,32,1,2,0,3,4,5]));return{id:Bg,diagram:e}},"loader"),rT={id:Bg,detector:tT,loader:eT},iT=rT,Ag="mindmap",aT=p(e=>/^\s*mindmap/.test(e),"detector"),nT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./mindmap-definition-VGOIOE7T-CipFHRae.js");return{diagram:t}},__vite__mapDeps([46,18,19,1,2,0,3,4,5]));return{id:Ag,diagram:e}},"loader"),sT={id:Ag,detector:aT,loader:nT},oT=sT,Mg="kanban",lT=p(e=>/^\s*kanban/.test(e),"detector"),cT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./kanban-definition-3W4ZIXB7-DIfa4j4L.js");return{diagram:t}},__vite__mapDeps([47,17,1,2,0,3,4,5]));return{id:Mg,diagram:e}},"loader"),hT={id:Mg,detector:lT,loader:cT},uT=hT,Eg="sankey",fT=p(e=>/^\s*sankey(-beta)?/.test(e),"detector"),dT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./sankeyDiagram-TZEHDZUN-C3bvRR0p.js");return{diagram:t}},__vite__mapDeps([48,33,28,1,2,0,3,4,5]));return{id:Eg,diagram:e}},"loader"),pT={id:Eg,detector:fT,loader:dT},gT=pT,$g="packet",mT=p(e=>/^\s*packet(-beta)?/.test(e),"detector"),yT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./diagram-S2PKOQOG-BqUHyr8W.js");return{diagram:t}},__vite__mapDeps([49,23,25,1,2,10,8,0,3,4,5]));return{id:$g,diagram:e}},"loader"),xT={id:$g,detector:mT,loader:yT},Fg="radar",bT=p(e=>/^\s*radar-beta/.test(e),"detector"),_T=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./diagram-QEK2KX5R-BoH7syf_.js");return{diagram:t}},__vite__mapDeps([50,23,25,1,2,10,8,0,3,4,5]));return{id:Fg,diagram:e}},"loader"),CT={id:Fg,detector:bT,loader:_T},Og="block",vT=p(e=>/^\s*block(-beta)?/.test(e),"detector"),wT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./blockDiagram-VD42YOAC-DeY844Kv.js");return{diagram:t}},__vite__mapDeps([51,17,11,7,8,20,1,2,0,3,4,5]));return{id:Og,diagram:e}},"loader"),ST={id:Og,detector:vT,loader:wT},kT=ST,Dg="architecture",TT=p(e=>/^\s*architecture/.test(e),"detector"),LT=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./architectureDiagram-VXUJARFQ-BCmD-Gj_.js");return{diagram:t}},__vite__mapDeps([52,23,25,1,2,10,8,13,0,3,4,5]));return{id:Dg,diagram:e}},"loader"),BT={id:Dg,detector:TT,loader:LT},AT=BT,Ig="treemap",MT=p(e=>/^\s*treemap/.test(e),"detector"),ET=p(async()=>{const{diagram:e}=await ft(async()=>{const{diagram:t}=await import("./diagram-PSM6KHXK-ByycaI76.js");return{diagram:t}},__vite__mapDeps([53,19,23,25,1,2,10,8,29,33,28,0,3,4,5]));return{id:Ig,diagram:e}},"loader"),$T={id:Ig,detector:MT,loader:ET},Ic=!1,Tn=p(()=>{Ic||(Ic=!0,Ta("error",Xk,e=>e.toLowerCase().trim()==="error"),Ta("---",{db:{clear:p(()=>{},"clear")},styles:{},renderer:{draw:p(()=>{},"draw")},parser:{parse:p(()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")},"parse")},init:p(()=>null,"init")},e=>e.toLowerCase().trimStart().startsWith("---")),ns(Jk,oT,AT),ns(RS,uT,Fk,Ak,XS,ik,sk,ck,Ck,kk,YS,zS,iT,JS,zk,Rk,Yk,dk,gT,xT,yk,kT,CT,$T))},"addDiagrams"),FT=p(async()=>{F.debug("Loading registered diagrams");const t=(await Promise.allSettled(Object.entries(ar).map(async([r,{detector:i,loader:a}])=>{if(a)try{cs(r)}catch{try{const{diagram:n,id:o}=await a();Ta(o,n,i)}catch(n){throw F.error(`Failed to load external diagram with key ${r}. Removing from detectors.`),delete ar[r],n}}}))).filter(r=>r.status==="rejected");if(t.length>0){F.error(`Failed to load ${t.length} external diagrams`);for(const r of t)F.error(r);throw new Error(`Failed to load ${t.length} external diagrams`)}},"loadRegisteredDiagrams"),OT="graphics-document document";function Rg(e,t){e.attr("role",OT),t!==""&&e.attr("aria-roledescription",t)}p(Rg,"setA11yDiagramInfo");function Pg(e,t,r,i){if(e.insert!==void 0){if(r){const a=`chart-desc-${i}`;e.attr("aria-describedby",a),e.insert("desc",":first-child").attr("id",a).text(r)}if(t){const a=`chart-title-${i}`;e.attr("aria-labelledby",a),e.insert("title",":first-child").attr("id",a).text(t)}}}p(Pg,"addSVGa11yTitleDescription");var ir,Ks=(ir=class{constructor(t,r,i,a,n){this.type=t,this.text=r,this.db=i,this.parser=a,this.renderer=n}static async fromText(t,r={}){const i=Ft(),a=Js(t,i);t=gv(t)+`
|
|
184
|
+
`;try{cs(a)}catch{const c=Nm(a);if(!c)throw new Kc(`Diagram ${a} not found.`);const{id:h,diagram:u}=await c();Ta(h,u)}const{db:n,parser:o,renderer:s,init:l}=cs(a);return o.parser&&(o.parser.yy=n),n.clear?.(),l?.(i),r.title&&n.setDiagramTitle?.(r.title),await o.parse(t),new ir(a,t,n,o,s)}async render(t,r){await this.renderer.draw(this.text,t,r,this)}getParser(){return this.parser}getType(){return this.type}},p(ir,"Diagram"),ir),Rc=[],DT=p(()=>{Rc.forEach(e=>{e()}),Rc=[]},"attachFunctions"),IT=p(e=>e.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart(),"cleanupComments");function Ng(e){const t=e.match(Xc);if(!t)return{text:e,metadata:{}};let r=m2(t[1],{schema:g2})??{};r=typeof r=="object"&&!Array.isArray(r)?r:{};const i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:e.slice(t[0].length),metadata:i}}p(Ng,"extractFrontMatter");var RT=p(e=>e.replace(/\r\n?/g,`
|
|
185
|
+
`).replace(/<(\w+)([^>]*)>/g,(t,r,i)=>"<"+r+i.replace(/="([^"]*)"/g,"='$1'")+">"),"cleanupText"),PT=p(e=>{const{text:t,metadata:r}=Ng(e),{displayMode:i,title:a,config:n={}}=r;return i&&(n.gantt||(n.gantt={}),n.gantt.displayMode=i),{title:a,config:n,text:t}},"processFrontmatter"),NT=p(e=>{const t=ne.detectInit(e)??{},r=ne.detectDirective(e,"wrap");return Array.isArray(r)?t.wrap=r.some(({type:i})=>i==="wrap"):r?.type==="wrap"&&(t.wrap=!0),{text:rv(e),directive:t}},"processDirectives");function jo(e){const t=RT(e),r=PT(t),i=NT(r.text),a=Io(r.config,i.directive);return e=IT(i.text),{code:e,title:r.title,config:a}}p(jo,"preprocessDiagram");function Wg(e){const t=new TextEncoder().encode(e),r=Array.from(t,i=>String.fromCodePoint(i)).join("");return btoa(r)}p(Wg,"toBase64");var WT=5e4,zT="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",qT="sandbox",HT="loose",jT="http://www.w3.org/2000/svg",YT="http://www.w3.org/1999/xlink",UT="http://www.w3.org/1999/xhtml",GT="100%",VT="100%",XT="border:0;margin:0;",KT="margin:0",ZT="allow-top-navigation-by-user-activation allow-popups",QT='The "iframe" tag is not supported by your browser.',JT=["foreignobject"],tL=["dominant-baseline"];function Yo(e){const t=jo(e);return Sa(),e0(t.config??{}),t}p(Yo,"processAndSetConfigs");async function zg(e,t){Tn();try{const{code:r,config:i}=Yo(e);return{diagramType:(await Hg(r)).type,config:i}}catch(r){if(t?.suppressErrors)return!1;throw r}}p(zg,"parse");var Pc=p((e,t,r=[])=>`
|
|
186
|
+
.${e} ${t} { ${r.join(" !important; ")} !important; }`,"cssImportantStyles"),eL=p((e,t=new Map)=>{let r="";if(e.themeCSS!==void 0&&(r+=`
|
|
187
|
+
${e.themeCSS}`),e.fontFamily!==void 0&&(r+=`
|
|
188
|
+
:root { --mermaid-font-family: ${e.fontFamily}}`),e.altFontFamily!==void 0&&(r+=`
|
|
189
|
+
:root { --mermaid-alt-font-family: ${e.altFontFamily}}`),t instanceof Map){const o=e.htmlLabels??e.flowchart?.htmlLabels?["> *","span"]:["rect","polygon","ellipse","circle","path"];t.forEach(s=>{Dc(s.styles)||o.forEach(l=>{r+=Pc(s.id,l,s.styles)}),Dc(s.textStyles)||(r+=Pc(s.id,"tspan",(s?.textStyles||[]).map(l=>l.replace("color","fill"))))})}return r},"createCssStyles"),rL=p((e,t,r,i)=>{const a=eL(e,r),n=C0(t,a,e.themeVariables);return Ys(yS(`${i}{${n}}`),bS)},"createUserStyles"),iL=p((e="",t,r)=>{let i=e;return!r&&!t&&(i=i.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),i=dr(i),i=i.replace(/<br>/g,"<br/>"),i},"cleanUpSvgCode"),aL=p((e="",t)=>{const r=t?.viewBox?.baseVal?.height?t.viewBox.baseVal.height+"px":VT,i=Wg(`<body style="${KT}">${e}</body>`);return`<iframe style="width:${GT};height:${r};${XT}" src="data:text/html;charset=UTF-8;base64,${i}" sandbox="${ZT}">
|
|
190
|
+
${QT}
|
|
191
|
+
</iframe>`},"putIntoIFrame"),Nc=p((e,t,r,i,a)=>{const n=e.append("div");n.attr("id",r),i&&n.attr("style",i);const o=n.append("svg").attr("id",t).attr("width","100%").attr("xmlns",jT);return a&&o.attr("xmlns:xlink",a),o.append("g"),e},"appendDivSvgG");function Zs(e,t){return e.append("iframe").attr("id",t).attr("style","width: 100%; height: 100%;").attr("sandbox","")}p(Zs,"sandboxedIframe");var nL=p((e,t,r,i)=>{e.getElementById(t)?.remove(),e.getElementById(r)?.remove(),e.getElementById(i)?.remove()},"removeExistingElements"),sL=p(async function(e,t,r){Tn();const i=Yo(t);t=i.code;const a=Ft();F.debug(a),t.length>(a?.maxTextSize??WT)&&(t=zT);const n="#"+e,o="i"+e,s="#"+o,l="d"+e,c="#"+l,h=p(()=>{const I=ht(f?s:c).node();I&&"remove"in I&&I.remove()},"removeTempElements");let u=ht("body");const f=a.securityLevel===qT,d=a.securityLevel===HT,g=a.fontFamily;if(r!==void 0){if(r&&(r.innerHTML=""),f){const N=Zs(ht(r),o);u=ht(N.nodes()[0].contentDocument.body),u.node().style.margin=0}else u=ht(r);Nc(u,e,l,`font-family: ${g}`,YT)}else{if(nL(document,e,l,o),f){const N=Zs(ht("body"),o);u=ht(N.nodes()[0].contentDocument.body),u.node().style.margin=0}else u=ht("body");Nc(u,e,l)}let m,y;try{m=await Ks.fromText(t,{title:i.title})}catch(N){if(a.suppressErrorRendering)throw h(),N;m=await Ks.fromText("error"),y=N}const x=u.select(c).node(),b=m.type,_=x.firstChild,w=_.firstChild,v=m.renderer.getClasses?.(t,m),B=rL(a,b,v,n),T=document.createElement("style");T.innerHTML=B,_.insertBefore(T,w);try{await m.renderer.draw(t,e,hl.version,m)}catch(N){throw a.suppressErrorRendering?h():Gk.draw(t,e,hl.version),N}const O=u.select(`${c} svg`),R=m.db.getAccTitle?.(),D=m.db.getAccDescription?.();jg(b,O,R,D),u.select(`[id="${e}"]`).selectAll("foreignobject > *").attr("xmlns",UT);let E=u.select(c).node().innerHTML;if(F.debug("config.arrowMarkerAbsolute",a.arrowMarkerAbsolute),E=iL(E,f,kt(a.arrowMarkerAbsolute)),f){const N=u.select(c+" svg").node();E=aL(E,N)}else d||(E=Ir.sanitize(E,{ADD_TAGS:JT,ADD_ATTR:tL,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));if(DT(),y)throw y;return h(),{diagramType:b,svg:E,bindFunctions:m.db.bindFunctions}},"render");function qg(e={}){const t=wt({},e);t?.fontFamily&&!t.themeVariables?.fontFamily&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),Jm(t),t?.theme&&t.theme in Le?t.themeVariables=Le[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=Le.default.getThemeVariables(t.themeVariables));const r=typeof t=="object"?Qm(t):eh();Qs(r.logLevel),Tn()}p(qg,"initialize");var Hg=p((e,t={})=>{const{code:r}=jo(e);return Ks.fromText(r,t)},"getDiagramFromText");function jg(e,t,r,i){Rg(t,e),Pg(t,r,i,t.attr("id"))}p(jg,"addA11yInfo");var cr=Object.freeze({render:sL,parse:zg,getDiagramFromText:Hg,initialize:qg,getConfig:Ft,setConfig:rh,getSiteConfig:eh,updateSiteConfig:t0,reset:p(()=>{Sa()},"reset"),globalReset:p(()=>{Sa(Rr)},"globalReset"),defaultConfig:Rr});Qs(Ft().logLevel);Sa(Ft());var oL=p((e,t,r)=>{F.warn(e),Do(e)?(r&&r(e.str,e.hash),t.push({...e,message:e.str,error:e})):(r&&r(e),e instanceof Error&&t.push({str:e.message,message:e.message,hash:e.name,error:e}))},"handleError"),Yg=p(async function(e={querySelector:".mermaid"}){try{await lL(e)}catch(t){if(Do(t)&&F.error(t.str),Ee.parseError&&Ee.parseError(t),!e.suppressErrors)throw F.error("Use the suppressErrors option to suppress these errors"),t}},"run"),lL=p(async function({postRenderCallback:e,querySelector:t,nodes:r}={querySelector:".mermaid"}){const i=cr.getConfig();F.debug(`${e?"":"No "}Callback function found`);let a;if(r)a=r;else if(t)a=document.querySelectorAll(t);else throw new Error("Nodes and querySelector are both undefined");F.debug(`Found ${a.length} diagrams`),i?.startOnLoad!==void 0&&(F.debug("Start On Load: "+i?.startOnLoad),cr.updateSiteConfig({startOnLoad:i?.startOnLoad}));const n=new ne.InitIDGenerator(i.deterministicIds,i.deterministicIDSeed);let o;const s=[];for(const l of Array.from(a)){if(F.info("Rendering diagram: "+l.id),l.getAttribute("data-processed"))continue;l.setAttribute("data-processed","true");const c=`mermaid-${n.next()}`;o=l.innerHTML,o=fd(ne.entityDecode(o)).trim().replace(/<br\s*\/?>/gi,"<br/>");const h=ne.detectInit(o);h&&F.debug("Detected early reinit: ",h);try{const{svg:u,bindFunctions:f}=await Xg(c,o,l);l.innerHTML=u,e&&await e(c),f&&f(l)}catch(u){oL(u,s,Ee.parseError)}}if(s.length>0)throw s[0]},"runThrowsErrors"),Ug=p(function(e){cr.initialize(e)},"initialize"),cL=p(async function(e,t,r){F.warn("mermaid.init is deprecated. Please use run instead."),e&&Ug(e);const i={postRenderCallback:r,querySelector:".mermaid"};typeof t=="string"?i.querySelector=t:t&&(t instanceof HTMLElement?i.nodes=[t]:i.nodes=t),await Yg(i)},"init"),hL=p(async(e,{lazyLoad:t=!0}={})=>{Tn(),ns(...e),t===!1&&await FT()},"registerExternalDiagrams"),Gg=p(function(){if(Ee.startOnLoad){const{startOnLoad:e}=cr.getConfig();e&&Ee.run().catch(t=>F.error("Mermaid failed to initialize",t))}},"contentLoaded");typeof document<"u"&&window.addEventListener("load",Gg,!1);var uL=p(function(e){Ee.parseError=e},"setParseErrorHandler"),tn=[],rs=!1,Vg=p(async()=>{if(!rs){for(rs=!0;tn.length>0;){const e=tn.shift();if(e)try{await e()}catch(t){F.error("Error executing queue",t)}}rs=!1}},"executeQueue"),fL=p(async(e,t)=>new Promise((r,i)=>{const a=p(()=>new Promise((n,o)=>{cr.parse(e,t).then(s=>{n(s),r(s)},s=>{F.error("Error parsing",s),Ee.parseError?.(s),o(s),i(s)})}),"performCall");tn.push(a),Vg().catch(i)}),"parse"),Xg=p((e,t,r)=>new Promise((i,a)=>{const n=p(()=>new Promise((o,s)=>{cr.render(e,t,r).then(l=>{o(l),i(l)},l=>{F.error("Error parsing",l),Ee.parseError?.(l),s(l),a(l)})}),"performCall");tn.push(n),Vg().catch(a)}),"render"),dL=p(()=>Object.keys(ar).map(e=>({id:e})),"getRegisteredDiagramsMetadata"),Ee={startOnLoad:!0,mermaidAPI:cr,parse:fL,render:Xg,init:cL,run:Yg,registerExternalDiagrams:hL,registerLayoutLoaders:rg,initialize:Ug,parseError:void 0,contentLoaded:Gg,setParseErrorHandler:uL,detectType:Js,registerIconPacks:Iv,getRegisteredDiagramsMetadata:dL},pL=Ee;const WL=Object.freeze(Object.defineProperty({__proto__:null,default:pL},Symbol.toStringTag,{value:"Module"}));export{kL as $,_L as A,xi as B,pe as C,cm as D,M0 as E,Io as F,Ft as G,th as H,ov as I,g2 as J,c1 as K,hl as L,Kb as M,po as N,SL as O,LL as P,_r as Q,ql as R,zl as S,AL as T,st as U,BL as V,TL as W,vL as X,wL as Y,EL as Z,p as _,S0 as a,A_ as a$,ML as a0,Ym as a1,Pr as a2,xL as a3,xn as a4,QC as a5,h0 as a6,to as a7,vl as a8,t1 as a9,Pv as aA,Zb as aB,yL as aC,yn as aD,Ua as aE,ed as aF,qi as aG,Iv as aH,Dv as aI,co as aJ,Oe as aK,Dl as aL,Mx as aM,Si as aN,TC as aO,Jf as aP,Uf as aQ,M_ as aR,Ha as aS,E_ as aT,zi as aU,Ke as aV,CC as aW,lc as aX,hr as aY,$_ as aZ,Ao as a_,pa as aa,sv as ab,x0 as ac,Di as ad,H as ae,et as af,ch as ag,cw as ah,Qp as ai,IL as aj,y2 as ak,kt as al,qe as am,To as an,Sd as ao,dr as ap,od as aq,tS as ar,DL as as,RL as at,FL as au,G as av,OL as aw,Iw as ax,Ew as ay,Mw as az,w0 as b,D_ as b0,Vr as b1,kC as b2,VC as b3,W_ as b4,zC as b5,Lo as b6,Dc as b7,U as b8,zf as b9,WL as bA,Ut as ba,wx as bb,lo as bc,wh as bd,Pi as be,Th as bf,CL as bg,lm as bh,Gr as bi,$C as bj,wS as bk,Wi as bl,Ya as bm,ze as bn,dn as bo,ic as bp,Mo as bq,Vf as br,Qf as bs,L_ as bt,Vs as bu,GC as bv,WC as bw,XC as bx,Bo as by,ZC as bz,ut as c,ht as d,lh as e,wt as f,T0 as g,Me as h,Jt as i,w2 as j,Yr as k,F as l,cd as m,Ii as n,bL as o,NL as p,L0 as q,PL as r,k0 as s,B0 as t,ne as u,m2 as v,hv as w,Lw as x,$L as y,v0 as z};
|