@inkeep/open-knowledge 0.35.1 → 0.35.2
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/THIRD_PARTY_NOTICES.md +21 -0
- package/dist/assets/skills/discovery/SKILL.md +1 -1
- package/dist/assets/skills/project/SKILL.md +1 -1
- package/dist/assets/skills/write-skill/SKILL.md +1 -1
- package/dist/cli.mjs +7 -7
- package/dist/constants-DOhk9Wk6.mjs +2 -0
- package/dist/{gh-detect-93wtg_nV.mjs → gh-detect-dM8nUKzs.mjs} +2 -2
- package/dist/git-handle-BAtE8N7I.mjs +1 -0
- package/dist/{git-handle-DPCY4VMM.mjs → git-handle-CPWu4DPI.mjs} +2 -2
- package/dist/index.mjs +1 -1
- package/dist/init-BSBws6GC.mjs +1 -0
- package/dist/{init-CINP1v0y.mjs → init-CCbdbwFE.mjs} +3 -3
- package/dist/{launch-json-removal-Cp88-Nri.mjs → launch-json-removal-BazOhu5J.mjs} +2 -2
- package/dist/loader-Bzj7bCkI.mjs +1 -0
- package/dist/{loader-a2k4G6Yz.mjs → loader-DTXXGsgs.mjs} +2 -2
- package/dist/{open-browser-CP3YN1jA.mjs → open-browser-DLXd14zy.mjs} +2 -2
- package/dist/preview-CqfzXtXd.mjs +1 -0
- package/dist/{preview-CvyqQIIL.mjs → preview-D0QS35sT.mjs} +2 -2
- package/dist/public/assets/ActivityModeContent-BnuEB0TT.js +1 -0
- package/dist/public/assets/AgentDiffPane-DE0fYFiY.js +2 -0
- package/dist/public/assets/{CodeMirrorPropInput-BaaMh183.js → CodeMirrorPropInput-D7LKYsQT.js} +3 -3
- package/dist/public/assets/{ConsentDialogBody-Dac-eNHp.js → ConsentDialogBody-CFh9gVKe.js} +1 -1
- package/dist/public/assets/{DocumentContext-DVJ7yEqv.js → DocumentContext-CD-cYy1t.js} +11 -11
- package/dist/public/assets/{EnableSyncConfirmDialog-pUJ0-0Xd.js → EnableSyncConfirmDialog-BsDontPj.js} +1 -1
- package/dist/public/assets/{GraphPanel-CLbL3_7S.js → GraphPanel-D-LFOZKp.js} +1 -1
- package/dist/public/assets/{ManagedArtifactProperties-BbvAZvc9.js → ManagedArtifactProperties-BNqA6-pR.js} +1 -1
- package/dist/public/assets/{McpConsentDialogBody-D_ALgiPf.js → McpConsentDialogBody-DIH6Ms1u.js} +1 -1
- package/dist/public/assets/{MermaidDocEditor-C4zrJQLq.js → MermaidDocEditor-Dtd-8jJV.js} +1 -1
- package/dist/public/assets/PropertyPanel-jcK4Zprh.js +2 -0
- package/dist/public/assets/{ReportBugDialogBody-By8lUyez.js → ReportBugDialogBody-BCRLTK8_.js} +1 -1
- package/dist/public/assets/SettingsDialogBody-DCw6gLhI.js +7 -0
- package/dist/public/assets/{ShareBranchSwitchDialog-COA225Wh.js → ShareBranchSwitchDialog-BU6DMxX1.js} +1 -1
- package/dist/public/assets/{ShareReceiveDialog-CGeUbVX5.js → ShareReceiveDialog-BbWq-gzG.js} +1 -1
- package/dist/public/assets/{ShareReceiveMissDialog-BiFbvWX1.js → ShareReceiveMissDialog-yXLs8-wZ.js} +1 -1
- package/dist/public/assets/{SkillEditorActions-HOX1vQzN.js → SkillEditorActions-BSrcCPDd.js} +1 -1
- package/dist/public/assets/{SourceEditor-BbNBxNCg.js → SourceEditor-FDhGbuG2.js} +1 -1
- package/dist/public/assets/{TerminalPanel-CJcXd9VC.js → TerminalPanel-Mz8BwF5T.js} +1 -1
- package/dist/public/assets/TimelineDiffPane-DmEbcjcV.js +2 -0
- package/dist/public/assets/{abnfDiagram-VRR7QNED-s07JwBrQ.js → abnfDiagram-VRR7QNED-DxPP95nn.js} +1 -1
- package/dist/public/assets/agent-presence-C7KW4GFN.js +1 -0
- package/dist/public/assets/{arc-C2sMPVKm.js → arc-B-QPMw-K.js} +1 -1
- package/dist/public/assets/architecture-TIHT7OUA-CltUrdi_.js +1 -0
- package/dist/public/assets/{architectureDiagram-ZJ3FMSHR-DQ9Uvn9z.js → architectureDiagram-ZJ3FMSHR-DI2cSyhR.js} +1 -1
- package/dist/public/assets/{auth-state-cache-Di7tO3rZ.js → auth-state-cache-CQH-tSHp.js} +8 -8
- package/dist/public/assets/{blockDiagram-677ZJIJ3-DSk8Ogpy.js → blockDiagram-677ZJIJ3-h5oSMPKD.js} +1 -1
- package/dist/public/assets/{c4Diagram-LMCZKHZV-Bz59H0KA.js → c4Diagram-LMCZKHZV-CK2iEE3c.js} +1 -1
- package/dist/public/assets/{calendar-BxfDpUWv.js → calendar-BWOC8yrW.js} +1 -1
- package/dist/public/assets/channel-u6IlPa4M.js +1 -0
- package/dist/public/assets/chunk-2Q5K7J3B-Dp_z4y0p.js +1 -0
- package/dist/public/assets/{chunk-32BRIVSS-CrIqwJxq.js → chunk-32BRIVSS-DSjkImiO.js} +1 -1
- package/dist/public/assets/{chunk-52WLFC77-mgHjwXy8.js → chunk-52WLFC77-Dcxgn7aY.js} +1 -1
- package/dist/public/assets/{chunk-5FCAYU7R-DsN08wYr.js → chunk-5FCAYU7R-BfGI-oMu.js} +1 -1
- package/dist/public/assets/{chunk-5HE753X5-DR9Xb784.js → chunk-5HE753X5-weABv-wL.js} +1 -1
- package/dist/public/assets/{chunk-5JV3BV7I-DUGJruxJ.js → chunk-5JV3BV7I-DEhUP77q.js} +1 -1
- package/dist/public/assets/{chunk-5TONJI2A-DGpS165P.js → chunk-5TONJI2A-D8ryhTto.js} +1 -1
- package/dist/public/assets/{chunk-5VM5RSS4-Y6UOitXa.js → chunk-5VM5RSS4-BlyT0CoP.js} +1 -1
- package/dist/public/assets/{chunk-7BUUIJ7U-kgbsT0Ie.js → chunk-7BUUIJ7U-D9n2zFWa.js} +1 -1
- package/dist/public/assets/{chunk-BIQX33UG-ir0YjVc1.js → chunk-BIQX33UG-CZyszYrJ.js} +1 -1
- package/dist/public/assets/{chunk-C7G6YPKG-C4mkeqaG.js → chunk-C7G6YPKG-DA4AzgS1.js} +1 -1
- package/dist/public/assets/{chunk-CQNSW5MT-cO-NnCqU.js → chunk-CQNSW5MT-ClwiAtII.js} +1 -1
- package/dist/public/assets/{chunk-CYSBUYHQ-DOHROXyM.js → chunk-CYSBUYHQ-CGwDjQlh.js} +1 -1
- package/dist/public/assets/{chunk-EMLP6XTP-D4HTBqLV.js → chunk-EMLP6XTP-DjxQVp6i.js} +1 -1
- package/dist/public/assets/{chunk-EX3LRPZG-Do_cb0BC.js → chunk-EX3LRPZG-BcSqmSt4.js} +1 -1
- package/dist/public/assets/{chunk-FWX5IMBZ-CKeYA6zq.js → chunk-FWX5IMBZ-BTxv6yrt.js} +2 -2
- package/dist/public/assets/{chunk-HOUHSVGY-DLoarw7-.js → chunk-HOUHSVGY-3n2-KijJ.js} +1 -1
- package/dist/public/assets/{chunk-ICXQ74PX-MBl6EECh.js → chunk-ICXQ74PX-DWIJquJc.js} +1 -1
- package/dist/public/assets/{chunk-JG7HCLWE-CUeTjaY5.js → chunk-JG7HCLWE-BZZpuOy0.js} +1 -1
- package/dist/public/assets/{chunk-JWPE2WC7-CHGGBN9h.js → chunk-JWPE2WC7-DdwvzMEp.js} +1 -1
- package/dist/public/assets/{chunk-MOJQB5TN-CcZUk23X.js → chunk-MOJQB5TN-CmK9Iu27.js} +1 -1
- package/dist/public/assets/{chunk-MOZMSUNE-5QQVj3ss.js → chunk-MOZMSUNE-LyrnwAsU.js} +1 -1
- package/dist/public/assets/{chunk-OGEWGWER-BkptVqQ1.js → chunk-OGEWGWER-CeOp0xbH.js} +1 -1
- package/dist/public/assets/{chunk-OSBZ3O6U-ONf5Rxuf.js → chunk-OSBZ3O6U-DFiAaUHT.js} +1 -1
- package/dist/public/assets/{chunk-PUDLZKDR-DXTd_WWd.js → chunk-PUDLZKDR-BdJDvOQD.js} +1 -1
- package/dist/public/assets/{chunk-Q4XR5HBZ-QUWmwLf-.js → chunk-Q4XR5HBZ-C3mWTH_s.js} +1 -1
- package/dist/public/assets/{chunk-QBLGF6JB-DAW-PjRz.js → chunk-QBLGF6JB-Cip_ZYPa.js} +1 -1
- package/dist/public/assets/{chunk-R7FJI6CG-e7KlR5WR.js → chunk-R7FJI6CG-DLyapyIO.js} +1 -1
- package/dist/public/assets/{chunk-RYQCIY6F-DKYUXbW_.js → chunk-RYQCIY6F-C20EyDLP.js} +1 -1
- package/dist/public/assets/{chunk-U6XO7XAA-zuSavVpE.js → chunk-U6XO7XAA-DN2BTHsF.js} +1 -1
- package/dist/public/assets/{chunk-V7JOEXUC-BDcL_HF2.js → chunk-V7JOEXUC-BkdbQSd6.js} +1 -1
- package/dist/public/assets/chunk-VAUOI2AC-ql8j5-ta.js +1 -0
- package/dist/public/assets/{chunk-VR4S4FIN-CoKaVJob.js → chunk-VR4S4FIN-BXKGzdjR.js} +1 -1
- package/dist/public/assets/{chunk-WYO6CB5R-CPK-Z4Zn.js → chunk-WYO6CB5R-DDA9TMxs.js} +1 -1
- package/dist/public/assets/chunk-XXDRQBXY-BGFIrdGe.js +1 -0
- package/dist/public/assets/{chunk-YOTPTUD7-ZJ64LPBH.js → chunk-YOTPTUD7-CAY_zY8l.js} +1 -1
- package/dist/public/assets/{chunk-ZGVPDNZ5-D8S_HhHE.js → chunk-ZGVPDNZ5-gtD66mSa.js} +1 -1
- package/dist/public/assets/{chunk-ZIRB5QZD-CBAmXOZf.js → chunk-ZIRB5QZD-Bh7823OJ.js} +1 -1
- package/dist/public/assets/classDiagram-OUVF2IWQ-f__yrCN3.js +1 -0
- package/dist/public/assets/classDiagram-v2-EOCWNBFH-De7msUum.js +1 -0
- package/dist/public/assets/{config-provider-DGMqQCfP.js → config-provider-CKgTRKRt.js} +2 -2
- package/dist/public/assets/{cose-bilkent-JH36ORCC-BhCfvPJo.js → cose-bilkent-JH36ORCC-pqj5AHZx.js} +1 -1
- package/dist/public/assets/cynefin-VYW2F7L2-BaabRBtQ.js +1 -0
- package/dist/public/assets/{cynefinDiagram-TSTJHNR4-DZZpsQlh.js → cynefinDiagram-TSTJHNR4-BCdPoMcA.js} +1 -1
- package/dist/public/assets/{dagre-BCcof4fp.js → dagre-DK7PvNVd.js} +1 -1
- package/dist/public/assets/{dagre-VKFMJZFB-BVGAKvzT.js → dagre-VKFMJZFB-BMhbjrXq.js} +1 -1
- package/dist/public/assets/{diagram-FQU43EPY-BEAcnoVT.js → diagram-FQU43EPY-CI-dlZCc.js} +1 -1
- package/dist/public/assets/{diagram-G47NLZAW-B5YwZccl.js → diagram-G47NLZAW-7OA_hqYO.js} +1 -1
- package/dist/public/assets/{diagram-NH7WQ7WH-DJ729xkg.js → diagram-NH7WQ7WH-DGZoq1pS.js} +1 -1
- package/dist/public/assets/{diagram-OA4YK3LP-ComZLTwZ.js → diagram-OA4YK3LP-BgAzAKhY.js} +1 -1
- package/dist/public/assets/{diagram-WEI45ONY-DUpwGJzG.js → diagram-WEI45ONY-DWkPIxW4.js} +1 -1
- package/dist/public/assets/{dialog-D9fMUB3u.js → dialog-492Ff7fG.js} +1 -1
- package/dist/public/assets/{dist-CiO2pCFe.js → dist-B768eFXg.js} +1 -1
- package/dist/public/assets/{dist-Ddrqoe4c.js → dist-B76xtaAd.js} +1 -1
- package/dist/public/assets/{dist-TIByzzIF.js → dist-BZciNIwH.js} +1 -1
- package/dist/public/assets/{dist-CSbnaLam.js → dist-BiVF6Gdz.js} +1 -1
- package/dist/public/assets/{dist-D6P0HEvG.js → dist-BjlQpfm2.js} +1 -1
- package/dist/public/assets/{dist-Uf9Tc8KS.js → dist-BuhX1ZiW.js} +1 -1
- package/dist/public/assets/{dist-C6B3IZlW.js → dist-Bvng05Ux.js} +1 -1
- package/dist/public/assets/{dist-CN1nOe9M.js → dist-Byo4jhAQ.js} +1 -1
- package/dist/public/assets/{dist-RKGXlTOn.js → dist-CCfVhAvJ.js} +1 -1
- package/dist/public/assets/{dist-DQ98O3oW.js → dist-CML_8CPx.js} +1 -1
- package/dist/public/assets/{dist-Cid07B-b.js → dist-D1KI0nTz.js} +1 -1
- package/dist/public/assets/{dist-DLiIchlL.js → dist-DXywpqg-.js} +1 -1
- package/dist/public/assets/{dist-Cf-rDWvg.js → dist-z6xoO_FO.js} +2 -2
- package/dist/public/assets/{doc-hash-vKFY-V-Y.js → doc-hash-CR_v-pVy.js} +1 -1
- package/dist/public/assets/{documents-events-BzjmhSSx.js → documents-events-WLCQAftW.js} +1 -1
- package/dist/public/assets/{ebnfDiagram-CCIWWBDH-C0qN5Z1L.js → ebnfDiagram-CCIWWBDH-BRvvZw_B.js} +1 -1
- package/dist/public/assets/{erDiagram-Q63AITRT-B2y03i9k.js → erDiagram-Q63AITRT-DVXRJxAV.js} +1 -1
- package/dist/public/assets/eventmodeling-45OFAUF4-CpX_MdG2.js +1 -0
- package/dist/public/assets/{file-tree-adapter-DNsVn4SH.js → file-tree-adapter-BrNRZNNL.js} +1 -1
- package/dist/public/assets/flowDiagram-23GEKE2U-qBrVAQAs.js +1 -0
- package/dist/public/assets/{ganttDiagram-NO4QXBWP-CbAMuscB.js → ganttDiagram-NO4QXBWP-DfilZK9a.js} +1 -1
- package/dist/public/assets/gitGraph-TEB2WS4Q-Cl_Wohm-.js +1 -0
- package/dist/public/assets/{gitGraphDiagram-IHSO6WYX-BDtmrkrv.js → gitGraphDiagram-IHSO6WYX-CzPu78YW.js} +1 -1
- package/dist/public/assets/{graphlib-T74nenG1.js → graphlib-DcRmeD3e.js} +1 -1
- package/dist/public/assets/index-C3iemlkC.css +1 -0
- package/dist/public/assets/index-DMdt07dO.js +1995 -0
- package/dist/public/assets/info-DKCQHKI2-Df0PBh-0.js +1 -0
- package/dist/public/assets/{infoDiagram-FWYZ7A6U-BgSrBQZn.js → infoDiagram-FWYZ7A6U-C6-KcSYK.js} +1 -1
- package/dist/public/assets/{ishikawaDiagram-FXEZZL3T-B58n1EAe.js → ishikawaDiagram-FXEZZL3T-BjawhLso.js} +1 -1
- package/dist/public/assets/{journeyDiagram-5HDEW3XC-CtbbmL9o.js → journeyDiagram-5HDEW3XC-CKJ88ogB.js} +1 -1
- package/dist/public/assets/{kanban-definition-HUTT4EX6-PYnVKIRv.js → kanban-definition-HUTT4EX6-BGwYHT7Q.js} +1 -1
- package/dist/public/assets/{line-Bn4tqKip.js → line-BSndhJaA.js} +1 -1
- package/dist/public/assets/{linear-B7qown3H.js → linear-CWEI_5Iw.js} +1 -1
- package/dist/public/assets/{lint-config-client-C1xGkxTP.js → lint-config-client-DrncMKpi.js} +1 -1
- package/dist/public/assets/lru-string-cache-WgNrdYaR.js +1 -0
- package/dist/public/assets/{map-CAMtT7C7.js → map-CjcUXw9E.js} +1 -1
- package/dist/public/assets/{mermaid-parser.core-B1wAzOcl.js → mermaid-parser.core-Dd1-Tdhf.js} +2 -2
- package/dist/public/assets/{mermaid.core-CPVA3QHQ.js → mermaid.core-C3NRxXYk.js} +3 -3
- package/dist/public/assets/{mindmap-definition-LN4V7U3C-dzrg2t0C.js → mindmap-definition-LN4V7U3C-CMjs8uw1.js} +1 -1
- package/dist/public/assets/{navigation-targets-nvGLJ1po.js → navigation-targets-BW-vH_E0.js} +1 -1
- package/dist/public/assets/{now-7lIApcFa.js → now-DuonpS3w.js} +1 -1
- package/dist/public/assets/{open-managed-artifact-tab-CUhx9b-j.js → open-managed-artifact-tab-Mlt2_LRl.js} +1 -1
- package/dist/public/assets/{ordinal-RCdkn_04.js → ordinal-DqdsPg4w.js} +1 -1
- package/dist/public/assets/packet-7NZHBO7P-BzSOWp_y.js +1 -0
- package/dist/public/assets/panel-right-open-CBQxOUPX.js +1 -0
- package/dist/public/assets/{pegDiagram-2B236MQR-BSfr2juy.js → pegDiagram-2B236MQR-DbZNXK4F.js} +1 -1
- package/dist/public/assets/{pending-receive-nav-store-HxClZpU_.js → pending-receive-nav-store-VIiKipN9.js} +1 -1
- package/dist/public/assets/pie-RZYD4A2V-DQMer8ON.js +1 -0
- package/dist/public/assets/{pieDiagram-ENE6RG2P-BZpnpN-F.js → pieDiagram-ENE6RG2P-Cl1aNURz.js} +1 -1
- package/dist/public/assets/{prop-types-y7w6_eIH.js → prop-types-D0GhY5_m.js} +1 -1
- package/dist/public/assets/{quadrantDiagram-ABIIQ3AL-DbLxt4AH.js → quadrantDiagram-ABIIQ3AL-O0r_liGM.js} +1 -1
- package/dist/public/assets/radar-I7S5WNFK-BcSNWNdo.js +1 -0
- package/dist/public/assets/railroad-3IZDKUUU-Bki7TUdv.js +1 -0
- package/dist/public/assets/railroad-abnf-AHOZXSZD-TNcYa0Mz.js +1 -0
- package/dist/public/assets/railroad-ebnf-EBAXGLYW-BkoUFicN.js +1 -0
- package/dist/public/assets/railroad-peg-LSFZ7HO6-CPN1xC04.js +1 -0
- package/dist/public/assets/{railroadDiagram-RFXS5EU6-C848pWoS.js → railroadDiagram-RFXS5EU6-5qWlaSRR.js} +1 -1
- package/dist/public/assets/{receive-store-BBpK7Or2.js → receive-store-C5i5j6PY.js} +1 -1
- package/dist/public/assets/{requirementDiagram-TGXJPOKE-BYghLNMR.js → requirementDiagram-TGXJPOKE-P9qf5Z4Z.js} +1 -1
- package/dist/public/assets/{sankeyDiagram-HTMAVEWB-D4YIknL1.js → sankeyDiagram-HTMAVEWB-BWtC9T4g.js} +1 -1
- package/dist/public/assets/{selection-context-iozWEaD1.js → selection-context-B8-qhck0.js} +1 -1
- package/dist/public/assets/{sequenceDiagram-DBY2YBRQ-TyOsGnRM.js → sequenceDiagram-DBY2YBRQ-B8Hbf_bB.js} +1 -1
- package/dist/public/assets/{sizeCapture-X5ZJPWSS-BM5e48hL.js → sizeCapture-X5ZJPWSS-B93fpSFm.js} +1 -1
- package/dist/public/assets/{skill-actions-DL-yNOVR.js → skill-actions-MlZySxOC.js} +1 -1
- package/dist/public/assets/{skills-api-T6KNnXbb.js → skills-api-ej5KW5dn.js} +1 -1
- package/dist/public/assets/{src-DU4IiWLl.js → src-Bejbc0T8.js} +1 -1
- package/dist/public/assets/{src-DL3Zlx5X.js → src-qvqzPkMT.js} +1 -1
- package/dist/public/assets/{stateDiagram-2N3HPSRC-1BTIo0Qo.js → stateDiagram-2N3HPSRC-CCyXUsZO.js} +1 -1
- package/dist/public/assets/stateDiagram-v2-6OUMAXLB-D5lbOImg.js +1 -0
- package/dist/public/assets/{swimlanes-5IMT3BWC-DN05P38q.js → swimlanes-5IMT3BWC-B-sLEl82.js} +2 -2
- package/dist/public/assets/swimlanesDiagram-G3AALYLV-BI78kzuy.js +8 -0
- package/dist/public/assets/{target-navigation-intent-JPOSvf1i.js → target-navigation-intent-CmDfj84r.js} +1 -1
- package/dist/public/assets/{telemetry-impl-jUMr-Cv1.js → telemetry-impl-BWgeQHlt.js} +2 -2
- package/dist/public/assets/{telemetry-startup-jMwHqIQ4.js → telemetry-startup-kV7RyeHQ.js} +1 -1
- package/dist/public/assets/{timeline-definition-FHXFAJF6-m9Ty-Kvs.js → timeline-definition-FHXFAJF6-B4-HCQ_I.js} +1 -1
- package/dist/public/assets/timeline-diff-store-HBj2AFCu.js +1 -0
- package/dist/public/assets/treeView-QDETBFTQ-CT2knITr.js +1 -0
- package/dist/public/assets/treemap-6X3UGDF4-BWe4kQzY.js +1 -0
- package/dist/public/assets/{typing-burst-detector-50DGt0NB.js → typing-burst-detector-3hPuqdYY.js} +1 -1
- package/dist/public/assets/use-activity-panel-Gn1IB308.js +1 -0
- package/dist/public/assets/{use-apply-config-color-theme-C4-L1m1x.js → use-apply-config-color-theme-BHcKd5uB.js} +1 -1
- package/dist/public/assets/use-timeline-entry-diff-Dng-AG98.js +18 -0
- package/dist/public/assets/{vennDiagram-L72KCM5P-CeGSzDp-.js → vennDiagram-L72KCM5P-DIXJ-f9A.js} +1 -1
- package/dist/public/assets/wardley-OPB4EBWU-BjTiRqi1.js +1 -0
- package/dist/public/assets/{wardleyDiagram-EHGQE667-CEiEgHEP.js → wardleyDiagram-EHGQE667-DuaGh-EA.js} +1 -1
- package/dist/public/assets/{workspace-paths-BzYkZqjr.js → workspace-paths-DTMEcAKi.js} +1 -1
- package/dist/public/assets/{xychartDiagram-FW5EYKEG-D2AGvwUv.js → xychartDiagram-FW5EYKEG-BGEm2ArJ.js} +1 -1
- package/dist/public/index.html +60 -58
- package/dist/{repair-launch-json-xDbECVti.mjs → repair-launch-json-BRDADYRm.mjs} +2 -2
- package/dist/{repair-mcp-configs-BPCRXAai.mjs → repair-mcp-configs-Be-QiQqq.mjs} +2 -2
- package/dist/repair-skills-B95d0UWj.mjs +1 -0
- package/dist/{repair-skills-CZbrTVch.mjs → repair-skills-CjpripUK.mjs} +2 -2
- package/dist/{server-lock-wMKEjgnN.mjs → server-lock-Cn2-KrjV.mjs} +2 -2
- package/dist/server-lock-kLJ8OVOq.mjs +1 -0
- package/dist/{src-BU7I7py6.mjs → src-BgrRg-nl.mjs} +2 -2
- package/dist/{src-cvLOShuL.mjs → src-CrEPVorI.mjs} +2 -2
- package/dist/{src-FMIoftZv.mjs → src-D3RAM6vg.mjs} +1 -1
- package/dist/{src-C0CgVA8i.mjs → src-D87GkAFF.mjs} +312 -308
- package/dist/{start-DcF59Yvb.mjs → start-4YMTDGKf.mjs} +2 -2
- package/dist/start-DiJGCN7X.mjs +1 -0
- package/dist/{write-project-skill-DkTM_Oeh.mjs → write-project-skill-CLggzjLg.mjs} +2 -2
- package/package.json +4 -4
- package/dist/constants-B51-MH_i.mjs +0 -2
- package/dist/git-handle-CeejIzW4.mjs +0 -1
- package/dist/init-EO9D9f7g.mjs +0 -1
- package/dist/loader-DrTu23Tp.mjs +0 -1
- package/dist/preview-Un26Rvbh.mjs +0 -1
- package/dist/public/assets/ActivityModeContent-BzCteFud.js +0 -2
- package/dist/public/assets/PropertyPanel-D2cHpPyn.js +0 -2
- package/dist/public/assets/SettingsDialogBody-Ivdm3ToR.js +0 -7
- package/dist/public/assets/agent-presence-DWEqGNHh.js +0 -1
- package/dist/public/assets/architecture-TIHT7OUA-CT1tXplN.js +0 -1
- package/dist/public/assets/channel-CSqODHBX.js +0 -1
- package/dist/public/assets/chunk-2Q5K7J3B-6231eKaz.js +0 -1
- package/dist/public/assets/chunk-VAUOI2AC-D5KfNXdk.js +0 -1
- package/dist/public/assets/chunk-XXDRQBXY-z12okRSH.js +0 -1
- package/dist/public/assets/classDiagram-OUVF2IWQ-3k_vKgMb.js +0 -1
- package/dist/public/assets/classDiagram-v2-EOCWNBFH-BWUMDcI-.js +0 -1
- package/dist/public/assets/cynefin-VYW2F7L2-CCaQNOor.js +0 -1
- package/dist/public/assets/eventmodeling-45OFAUF4-Dv2dElMn.js +0 -1
- package/dist/public/assets/flowDiagram-23GEKE2U-Cj2cm6wb.js +0 -1
- package/dist/public/assets/gitGraph-TEB2WS4Q-B_v5HTd2.js +0 -1
- package/dist/public/assets/index-BFfvrj_R.js +0 -2007
- package/dist/public/assets/index-Zwl7lo8a.css +0 -1
- package/dist/public/assets/info-DKCQHKI2-ChXVyprm.js +0 -1
- package/dist/public/assets/packet-7NZHBO7P--nGkFp-F.js +0 -1
- package/dist/public/assets/pie-RZYD4A2V-jLTQTVR2.js +0 -1
- package/dist/public/assets/radar-I7S5WNFK-C3lNKZB3.js +0 -1
- package/dist/public/assets/railroad-3IZDKUUU-zkTIyGxU.js +0 -1
- package/dist/public/assets/railroad-abnf-AHOZXSZD-CGyrnBSJ.js +0 -1
- package/dist/public/assets/railroad-ebnf-EBAXGLYW-BllS7VWZ.js +0 -1
- package/dist/public/assets/railroad-peg-LSFZ7HO6-C1CM3IeV.js +0 -1
- package/dist/public/assets/stateDiagram-v2-6OUMAXLB-C-nM9igb.js +0 -1
- package/dist/public/assets/swimlanesDiagram-G3AALYLV-DOdX5jTT.js +0 -8
- package/dist/public/assets/treeView-QDETBFTQ-CQFmlWUc.js +0 -1
- package/dist/public/assets/treemap-6X3UGDF4-BrZNJeo7.js +0 -1
- package/dist/public/assets/wardley-OPB4EBWU-KBVce8aR.js +0 -1
- package/dist/repair-skills-CyhWReZX.mjs +0 -1
- package/dist/server-lock-DGqK-4av.mjs +0 -1
- package/dist/start-D7QSP49B.mjs +0 -1
- /package/dist/public/assets/{ActivityPanelDiffView-COM6jgM6.js → ActivityPanelDiffView-CojvWN5u.js} +0 -0
- /package/dist/public/assets/{__vite-browser-external-B-733T4c.js → __vite-browser-external-W0BYeUy6.js} +0 -0
- /package/dist/public/assets/{array-Dz4vndSy.js → array-DZrUSYBX.js} +0 -0
- /package/dist/public/assets/{chunk-KEIR6QF5-YxiaonDF.js → chunk-KEIR6QF5-kMpbALDh.js} +0 -0
- /package/dist/public/assets/{chunk-Y2CYZVJY-B5uX60M6.js → chunk-Y2CYZVJY-C7afl5rZ.js} +0 -0
- /package/dist/public/assets/{clike-DrU-cR_S.js → clike-BgMHoZVb.js} +0 -0
- /package/dist/public/assets/{clipboard-adapter-BHfhAZ-n.js → clipboard-adapter-CfjsRFpv.js} +0 -0
- /package/dist/public/assets/{colors-yCcn8znj.js → colors-BtGPfaz7.js} +0 -0
- /package/dist/public/assets/{config-context-BbS_JaHs.js → config-context-BaIZpYSb.js} +0 -0
- /package/dist/public/assets/{cursor-Rw-XIAht.js → cursor-jdIvZ4dc.js} +0 -0
- /package/dist/public/assets/{cytoscape.esm-D6meekAa.js → cytoscape.esm-wfVGet9g.js} +0 -0
- /package/dist/public/assets/{defaultLocale-CKlKs72A.js → defaultLocale-CCuQb4WR.js} +0 -0
- /package/dist/public/assets/{desktop-bridge-types-_D7JSBL8.js → desktop-bridge-types-4c7gjz59.js} +0 -0
- /package/dist/public/assets/{diff-BVcHwfdB.js → diff-B7WgJJz8.js} +0 -0
- /package/dist/public/assets/{dist-DOee8t3p.js → dist-BQhSFgYM.js} +0 -0
- /package/dist/public/assets/{dist-Qabe7wDM.js → dist-CAIcun02.js} +0 -0
- /package/dist/public/assets/{dist-DMFtCzYE.js → dist-DN9vrt63.js} +0 -0
- /package/dist/public/assets/{dist-7hPoK5kq.js → dist-SUVx2c2e.js} +0 -0
- /package/dist/public/assets/{dist-C87Ou6G5.js → dist-o9cVHl8Q.js} +0 -0
- /package/dist/public/assets/{documents-fetch-CD85Qoe6.js → documents-fetch-BzTSsuPI.js} +0 -0
- /package/dist/public/assets/{external-link-BfiFPJEx.js → external-link-BUoZ56id.js} +0 -0
- /package/dist/public/assets/{file-tree-rename-validation-BBSv40Qz.js → file-tree-rename-validation-GUkltgNP.js} +0 -0
- /package/dist/public/assets/{format-DJS8_tfZ.js → format-ClWHbKHd.js} +0 -0
- /package/dist/public/assets/{go-Ceq0cEZq.js → go-DTLWKePr.js} +0 -0
- /package/dist/public/assets/{init-DSak-Kkw.js → init-B2r4ykR3.js} +0 -0
- /package/dist/public/assets/{input-BX4UDDMJ.js → input-b4FSCbA5.js} +0 -0
- /package/dist/public/assets/{isObject-qQeVObYJ.js → isObject-Bj-0X2GB.js} +0 -0
- /package/dist/public/assets/{lua-DM28D-6o.js → lua-B3utixrX.js} +0 -0
- /package/dist/public/assets/{mcp-consent-store-O7e02Mi1.js → mcp-consent-store-DL93ger0.js} +0 -0
- /package/dist/public/assets/{min-wGNVvSoq.js → min-B7KH7bOg.js} +0 -0
- /package/dist/public/assets/{panzoom.es-DeqEaiMH.js → panzoom.es-Cs7b857v.js} +0 -0
- /package/dist/public/assets/{parse-api-error-Mgtc4OJu.js → parse-api-error-DfesE4Y7.js} +0 -0
- /package/dist/public/assets/{path-B3Wp5BLm.js → path-BQp9Hq4z.js} +0 -0
- /package/dist/public/assets/{pdf-CSS8JMnh.js → pdf-BHHpPt0J.js} +0 -0
- /package/dist/public/assets/{pdf.worker-BojfP6R3.js → pdf.worker-BZYXl7oP.js} +0 -0
- /package/dist/public/assets/{perl-D5vgbj2Y.js → perl-CZ2U9dfT.js} +0 -0
- /package/dist/public/assets/{project-paths-DJDWBB-8.js → project-paths-CSBBkRS0.js} +0 -0
- /package/dist/public/assets/{properties-C7p4lNrk.js → properties-CwLn0BUZ.js} +0 -0
- /package/dist/public/assets/{r-BcyApZ2Y.js → r-Crnq5PtH.js} +0 -0
- /package/dist/public/assets/{refresh-cw-FMnveNBD.js → refresh-cw-DgVrChIu.js} +0 -0
- /package/dist/public/assets/{rough.esm-CIwjGUJO.js → rough.esm-B1TTUqnd.js} +0 -0
- /package/dist/public/assets/{ruby-DxabsNt7.js → ruby-nTEDjg1w.js} +0 -0
- /package/dist/public/assets/{share-metadata-rows-CVWX1vOJ.js → share-metadata-rows-DTrx2e2E.js} +0 -0
- /package/dist/public/assets/{shell-B2Oc-2BR.js → shell-CJ7sRXEH.js} +0 -0
- /package/dist/public/assets/{sql-DWXp9JcL.js → sql-B7jXn3j6.js} +0 -0
- /package/dist/public/assets/{src-DyReJWGm.js → src-CvdYkko8.js} +0 -0
- /package/dist/public/assets/{startup-marks-BJwpvHMe.js → startup-marks-2VTPXUbb.js} +0 -0
- /package/dist/public/assets/{stex-lDOZN-ZW.js → stex-CLng_sPo.js} +0 -0
- /package/dist/public/assets/{swift-BlyE8smW.js → swift-DKG9kMYe.js} +0 -0
- /package/dist/public/assets/{textarea--26Ac0EI.js → textarea-D45cTFgp.js} +0 -0
- /package/dist/public/assets/{toml-Bg2104qZ.js → toml-ClZMF6Q0.js} +0 -0
- /package/dist/public/assets/{trash-2-Cgf308yS.js → trash-2-U9wpS1zc.js} +0 -0
- /package/dist/public/assets/{triangle-alert-VZ_Cki-r.js → triangle-alert-BaZPlVka.js} +0 -0
- /package/dist/public/assets/{worktree-store-DFmh2OE1.js → worktree-store-Dwj7qwtV.js} +0 -0
- /package/dist/public/assets/{x-BUBUnCd-.js → x-_C6KOlzX.js} +0 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import{i as e,t}from"./chunk-DseTPa7n.js";import{n,r,t as i}from"./compiler-runtime-DrcePeIl.js";import{n as a,p as o}from"./DocumentContext-CD-cYy1t.js";import{t as s}from"./react-dom-CMNLH3L-.js";import{I as c,et as l,st as u}from"./CodeMirrorPropInput-D7LKYsQT.js";import{Gi as d,Ji as f,K as p,Ni as m,Pi as h,Ri as g,Ui as _,Vr as v,Yi as y,ci as b,qi as x,xi as S,zi as ee}from"./dist-z6xoO_FO.js";var C=t((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.Pointer=void 0,e.unescapeToken=t,e.escapeToken=n;function t(e){return e.replace(/~1/g,`/`).replace(/~0/g,`~`)}function n(e){return e.replace(/~/g,`~0`).replace(/\//g,`~1`)}e.Pointer=function(){function e(e){e===void 0&&(e=[``]),this.tokens=e}return e.fromJSON=function(n){var r=n.split(`/`).map(t);if(r[0]!==``)throw Error(`Invalid JSON Pointer: ${n}`);return new e(r)},e.prototype.toString=function(){return this.tokens.map(n).join(`/`)},e.prototype.evaluate=function(e){for(var t=null,n=``,r=e,i=1,a=this.tokens.length;i<a;i++)t=r,n=this.tokens[i],!(n==`__proto__`||n==`constructor`||n==`prototype`)&&(r=(t||{})[n]);return{parent:t,key:n,value:r}},e.prototype.get=function(e){return this.evaluate(e).value},e.prototype.set=function(e,t){var n=this.evaluate(e);n.parent&&(n.parent[n.key]=t)},e.prototype.push=function(e){this.tokens.push(e)},e.prototype.add=function(t){return new e(this.tokens.concat(String(t)))},e.prototype.parent=function(){return new e(this.tokens.length>1?this.tokens.slice(0,-1):[``])},e}()})),te=t((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.hasOwnProperty=void 0,e.objectType=t,e.clone=r,e.hasOwnProperty=Object.prototype.hasOwnProperty;function t(e){return e===void 0?`undefined`:e===null?`null`:Array.isArray(e)?`array`:typeof e}function n(e){return typeof e==`object`&&!!e}function r(t){if(!n(t))return t;if(t.constructor==Array){for(var i=t.length,a=Array(i),o=0;o<i;o++)a[o]=r(t[o]);return a}if(t.constructor==Date)return new Date(+t);var s={};for(var c in t)e.hasOwnProperty.call(t,c)&&(s[c]=r(t[c]));return s}})),ne=t((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.isDestructive=n,e.subtract=r,e.intersection=i,e.diffArrays=l,e.diffObjects=u,e.diffAny=d;var t=te();function n(e){var t=e.op;return t===`remove`||t===`replace`||t===`copy`||t===`move`}function r(e,n){var r=[];for(var i in e)t.hasOwnProperty.call(e,i)&&e[i]!==void 0&&!(t.hasOwnProperty.call(n,i)&&n[i]!==void 0)&&r.push(i);return r}function i(e){for(var n=e.length,r={},i=0;i<n;i++){var a=e[i];for(var o in a)t.hasOwnProperty.call(a,o)&&a[o]!==void 0&&(r[o]=(r[o]||0)+1)}for(var o in r)r[o]<n&&delete r[o];return Object.keys(r)}function a(e,n){var r=[];for(var i in e)t.hasOwnProperty.call(e,i)&&e[i]!==void 0&&t.hasOwnProperty.call(n,i)&&n[i]!==void 0&&r.push(i);return r}function o(e){return e.op===`add`}function s(e){return e.op===`remove`}function c(e,t){return{operations:e.operations.concat(t),cost:e.cost+1}}function l(e,t,n,r){r===void 0&&(r=d);var i=Math.max(e.length,t.length),a=new Map([[0,{operations:[],cost:0}]]);function l(o,s){var u=o*i+s,d=a.get(u);if(d===void 0){if(o>0&&s>0&&!r(e[o-1],t[s-1],n.add(String(o-1))).length)d=l(o-1,s-1);else{var f=[];if(o>0){var p=l(o-1,s),m={op:`remove`,index:o-1};f.push(c(p,m))}if(s>0){var h=l(o,s-1),g={op:`add`,index:o-1,value:t[s-1]};f.push(c(h,g))}if(o>0&&s>0){var _=l(o-1,s-1),v={op:`replace`,index:o-1,original:e[o-1],value:t[s-1]};f.push(c(_,v))}d=f.sort(function(e,t){return e.cost-t.cost})[0]}a.set(u,d)}return d}var u=isNaN(e.length)||e.length<=0?0:e.length;return l(u,isNaN(t.length)||t.length<=0?0:t.length).operations.reduce(function(e,t){var i=e[0],a=e[1];if(o(t)){var c=t.index+1+a,l=c<u+a?String(c):`-`,d={op:t.op,path:n.add(l).toString(),value:t.value};return[i.concat(d),a+1]}else if(s(t)){var d={op:t.op,path:n.add(String(t.index+a)).toString()};return[i.concat(d),a-1]}else{var f=n.add(String(t.index+a)),p=r(t.original,t.value,f);return[i.concat.apply(i,p),a]}},[[],0])[0]}function u(e,t,n,i){i===void 0&&(i=d);var o=[];return r(e,t).forEach(function(e){o.push({op:`remove`,path:n.add(e).toString()})}),r(t,e).forEach(function(e){o.push({op:`add`,path:n.add(e).toString(),value:t[e]})}),a(e,t).forEach(function(r){o.push.apply(o,i(e[r],t[r],n.add(r)))}),o}function d(e,n,r,i){if(i===void 0&&(i=d),e===n)return[];var a=(0,t.objectType)(e),o=(0,t.objectType)(n);return a==`array`&&o==`array`?l(e,n,r,i):a==`object`&&o==`object`?u(e,n,r,i):[{op:`replace`,path:r.toString(),value:n}]}})),re=t((e=>{var t=e&&e.__extends||(function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if(typeof n!=`function`&&n!==null)throw TypeError(`Class extends value `+String(n)+` is not a constructor or null`);e(t,n);function r(){this.constructor=t}t.prototype=n===null?Object.create(n):(r.prototype=n.prototype,new r)}})();Object.defineProperty(e,`__esModule`,{value:!0}),e.InvalidOperationError=e.TestError=e.MissingError=void 0,e.add=l,e.remove=u,e.replace=d,e.move=f,e.copy=p,e.test=m,e.apply=g;var n=C(),r=te(),i=ne(),a=function(e){t(n,e);function n(t){var n=e.call(this,`Value required at path: ${t}`)||this;return n.path=t,n.name=`MissingError`,n}return n}(Error);e.MissingError=a;var o=function(e){t(n,e);function n(t,n){var r=e.call(this,`Test failed: ${t} != ${n}`)||this;return r.actual=t,r.expected=n,r.name=`TestError`,r}return n}(Error);e.TestError=o;function s(e,t,n){if(Array.isArray(e))if(t==`-`)e.push(n);else{var r=parseInt(t,10);e.splice(r,0,n)}else e[t]=n}function c(e,t){if(Array.isArray(e)){var n=parseInt(t,10);e.splice(n,1)}else delete e[t]}function l(e,t,i){var o=n.Pointer.fromJSON(t.path);if(i?.implicitArrayCreation&&o.tokens[o.tokens.length-1]===`-`){var c=o.parent().evaluate(e);c.value===void 0&&(0,r.objectType)(c.parent)===`object`&&(c.parent[c.key]=[])}var l=o.evaluate(e);return l.parent===void 0||i?.implicitArrayCreation&&l.key===`-`&&!Array.isArray(l.parent)?new a(t.path):(s(l.parent,l.key,(0,r.clone)(t.value)),null)}function u(e,t,r){var i=n.Pointer.fromJSON(t.path).evaluate(e);return i.value===void 0?new a(t.path):(c(i.parent,i.key),null)}function d(e,t,i){var o=n.Pointer.fromJSON(t.path).evaluate(e);if(o.parent===null)return new a(t.path);if(Array.isArray(o.parent)){if(parseInt(o.key,10)>=o.parent.length)return new a(t.path)}else if(o.value===void 0)return new a(t.path);return o.parent[o.key]=(0,r.clone)(t.value),null}function f(e,t,r){var i=n.Pointer.fromJSON(t.from).evaluate(e);if(i.value===void 0)return new a(t.from);var o=n.Pointer.fromJSON(t.path).evaluate(e);return o.parent===void 0?new a(t.path):(c(i.parent,i.key),s(o.parent,o.key,i.value),null)}function p(e,t,i){var o=n.Pointer.fromJSON(t.from).evaluate(e);if(o.value===void 0)return new a(t.from);var c=n.Pointer.fromJSON(t.path).evaluate(e);return c.parent===void 0?new a(t.path):(s(c.parent,c.key,(0,r.clone)(o.value)),null)}function m(e,t,r){var a=n.Pointer.fromJSON(t.path).evaluate(e);return(0,i.diffAny)(a.value,t.value,new n.Pointer).length?new o(a.value,t.value):null}var h=function(e){t(n,e);function n(t){var n=e.call(this,`Invalid operation: ${t.op}`)||this;return n.operation=t,n.name=`InvalidOperationError`,n}return n}(Error);e.InvalidOperationError=h;function g(e,t,n){switch(t.op){case`add`:return l(e,t,n);case`remove`:return u(e,t,n);case`replace`:return d(e,t,n);case`move`:return f(e,t,n);case`copy`:return p(e,t,n);case`test`:return m(e,t,n)}return new h(t)}})),ie=t((e=>{Object.defineProperty(e,`__esModule`,{value:!0}),e.Pointer=void 0,e.applyPatch=i,e.createPatch=o;var t=C();Object.defineProperty(e,`Pointer`,{enumerable:!0,get:function(){return t.Pointer}});var n=re(),r=ne();function i(e,t,r){return t.map(function(t){return(0,n.apply)(e,t,r)})}function a(e){function t(n,i,a){var o=e(n,i,a);return Array.isArray(o)?o:(0,r.diffAny)(n,i,a,t)}return t}function o(e,n,i){var o=new t.Pointer;return(i?a(i):r.diffAny)(e,n,o)}})),w=e(n(),1),ae=e(s(),1),T=i(),E=ie();function D(){}D.prototype={diff:function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.callback;typeof n==`function`&&(r=n,n={}),this.options=n;var i=this;function a(e){return r?(setTimeout(function(){r(void 0,e)},0),!0):e}e=this.castInput(e),t=this.castInput(t),e=this.removeEmpty(this.tokenize(e)),t=this.removeEmpty(this.tokenize(t));var o=t.length,s=e.length,c=1,l=o+s;n.maxEditLength&&(l=Math.min(l,n.maxEditLength));var u=n.timeout??1/0,d=Date.now()+u,f=[{oldPos:-1,lastComponent:void 0}],p=this.extractCommon(f[0],t,e,0);if(f[0].oldPos+1>=s&&p+1>=o)return a([{value:this.join(t),count:t.length}]);var m=-1/0,h=1/0;function g(){for(var n=Math.max(m,-c);n<=Math.min(h,c);n+=2){var r=void 0,l=f[n-1],u=f[n+1];l&&(f[n-1]=void 0);var d=!1;if(u){var g=u.oldPos-n;d=u&&0<=g&&g<o}var _=l&&l.oldPos+1<s;if(!d&&!_){f[n]=void 0;continue}if(r=!_||d&&l.oldPos+1<u.oldPos?i.addToPath(u,!0,void 0,0):i.addToPath(l,void 0,!0,1),p=i.extractCommon(r,t,e,n),r.oldPos+1>=s&&p+1>=o)return a(oe(i,r.lastComponent,t,e,i.useLongestToken));f[n]=r,r.oldPos+1>=s&&(h=Math.min(h,n-1)),p+1>=o&&(m=Math.max(m,n+1))}c++}if(r)(function e(){setTimeout(function(){if(c>l||Date.now()>d)return r();g()||e()},0)})();else for(;c<=l&&Date.now()<=d;){var _=g();if(_)return _}},addToPath:function(e,t,n,r){var i=e.lastComponent;return i&&i.added===t&&i.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:i.count+1,added:t,removed:n,previousComponent:i.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:i}}},extractCommon:function(e,t,n,r){for(var i=t.length,a=n.length,o=e.oldPos,s=o-r,c=0;s+1<i&&o+1<a&&this.equals(t[s+1],n[o+1]);)s++,o++,c++;return c&&(e.lastComponent={count:c,previousComponent:e.lastComponent}),e.oldPos=o,s},equals:function(e,t){return this.options.comparator?this.options.comparator(e,t):e===t||this.options.ignoreCase&&e.toLowerCase()===t.toLowerCase()},removeEmpty:function(e){for(var t=[],n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t},castInput:function(e){return e},tokenize:function(e){return e.split(``)},join:function(e){return e.join(``)}};function oe(e,t,n,r,i){for(var a=[],o;t;)a.push(t),o=t.previousComponent,delete t.previousComponent,t=o;a.reverse();for(var s=0,c=a.length,l=0,u=0;s<c;s++){var d=a[s];if(!d.removed){if(!d.added&&i){var f=n.slice(l,l+d.count);f=f.map(function(e,t){var n=r[u+t];return n.length>e.length?n:e}),d.value=e.join(f)}else d.value=e.join(n.slice(l,l+d.count));l+=d.count,d.added||(u+=d.count)}else if(d.value=e.join(r.slice(u,u+d.count)),u+=d.count,s&&a[s-1].added){var p=a[s-1];a[s-1]=a[s],a[s]=p}}var m=a[c-1];return c>1&&typeof m.value==`string`&&(m.added||m.removed)&&e.equals(``,m.value)&&(a[c-2].value+=m.value,a.pop()),a}var se=new D;function ce(e,t,n){return se.diff(e,t,n)}var le=/^[A-Za-z\xC0-\u02C6\u02C8-\u02D7\u02DE-\u02FF\u1E00-\u1EFF]+$/,ue=/\S/,O=new D;O.equals=function(e,t){return this.options.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e===t||this.options.ignoreWhitespace&&!ue.test(e)&&!ue.test(t)},O.tokenize=function(e){for(var t=e.split(/([^\S\r\n]+|[()[\]{}'"\r\n]|\b)/),n=0;n<t.length-1;n++)!t[n+1]&&t[n+2]&&le.test(t[n])&&le.test(t[n+2])&&(t[n]+=t[n+2],t.splice(n+1,2),n--);return t};function de(e,t,n){return O.diff(e,t,n)}var fe=new D;fe.tokenize=function(e){this.options.stripTrailingCr&&(e=e.replace(/\r\n/g,`
|
|
2
|
+
`));var t=[],n=e.split(/(\n|\r\n)/);n[n.length-1]||n.pop();for(var r=0;r<n.length;r++){var i=n[r];r%2&&!this.options.newlineIsToken?t[t.length-1]+=i:(this.options.ignoreWhitespace&&(i=i.trim()),t.push(i))}return t};var pe=new D;pe.tokenize=function(e){return e.split(/(\S.+?[.!?])(?=\s+|$)/)};var me=new D;me.tokenize=function(e){return e.split(/([{}:;,]|\s+)/)};function k(e){"@babel/helpers - typeof";return k=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},k(e)}var he=Object.prototype.toString,A=new D;A.useLongestToken=!0,A.tokenize=fe.tokenize,A.castInput=function(e){var t=this.options,n=t.undefinedReplacement,r=t.stringifyReplacer,i=r===void 0?function(e,t){return t===void 0?n:t}:r;return typeof e==`string`?e:JSON.stringify(j(e,null,null,i),i,` `)},A.equals=function(e,t){return D.prototype.equals.call(A,e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`))};function j(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i,e));var a;for(a=0;a<t.length;a+=1)if(t[a]===e)return n[a];var o;if(he.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=j(e[a],t,n,r,i);return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),k(e)===`object`&&e!==null){t.push(e),o={},n.push(o);var s=[],c;for(c in e)e.hasOwnProperty(c)&&s.push(c);for(s.sort(),a=0;a<s.length;a+=1)c=s[a],o[c]=j(e[c],t,n,r,c);t.pop(),n.pop()}else o=e;return o}var M=new D;M.tokenize=function(e){return e.slice()},M.join=M.removeEmpty=function(e){return e};function N(e,t){let n=t.content.findDiffStart(e.content);if(n===null)return!1;let{a:r,b:i}=t.content.findDiffEnd(e.content),a=n-Math.min(r,i);return a>0&&(e.resolve(n-a).depth<t.resolve(r+a).depth?n-=a:(r+=a,i+=a)),new x(n,i,t.slice(n,r))}function ge(e){if(!e.steps.length)return;let t=new f(e.docs[0]),n=e.steps.slice();for(;n.length;){let e=n.shift();for(;n.length&&e.merge(n[0]);){let r=n.shift();e=e instanceof x&&r instanceof x?N(t.doc,r.apply(e.apply(t.doc).doc).doc):e.merge(r)}t.step(e)}return t}function P(e){let t=new f(e);return t.removeMark(0,e.nodeSize-2),t.doc}function _e(e,t){let n=t.split(`/`);for(n.shift();n.length;){if(typeof e!=`object`)throw Error();let t=n.shift();e=e[t]}return e}function F(e){return JSON.parse(JSON.stringify(e))}var ve=class{fromDoc;toDoc;complexSteps;wordDiffs;simplifyDiff;schema;tr;currentJSON;finalJSON;ops;constructor(e,t,n={}){let r={complexSteps:!0,wordDiffs:!1,simplifyDiff:!0,...n};this.fromDoc=e,this.toDoc=t,this.complexSteps=r.complexSteps,this.wordDiffs=r.wordDiffs,this.simplifyDiff=r.simplifyDiff,this.schema=e.type.schema,this.tr=new f(e),this.currentJSON={},this.finalJSON={},this.ops=[]}init(){return this.complexSteps?(this.currentJSON=P(this.fromDoc).toJSON(),this.finalJSON=P(this.toDoc).toJSON(),this.ops=(0,E.createPatch)(this.currentJSON,this.finalJSON),this.recreateChangeContentSteps(),this.recreateChangeMarkSteps()):(this.currentJSON=this.fromDoc.toJSON(),this.finalJSON=this.toDoc.toJSON(),this.ops=(0,E.createPatch)(this.currentJSON,this.finalJSON),this.recreateChangeContentSteps()),this.simplifyDiff&&(this.tr=ge(this.tr)||this.tr),this.tr}recreateChangeContentSteps(){let e=[];for(;this.ops.length;){let t=this.ops.shift();e.push(t);let n,r=F(this.currentJSON),i=t.path.split(`/`);for(;n==null;){(0,E.applyPatch)(r,[t]);try{n=this.schema.nodeFromJSON(r),n.check()}catch{if(n=null,this.ops.length>0)t=this.ops.shift(),e.push(t);else throw Error(`No valid diff possible applying ${t.path}`)}}this.complexSteps&&e.length===1&&(i.includes(`attrs`)||i.includes(`type`))?(this.addSetNodeMarkup(),e=[]):e.length===1&&t.op===`replace`&&i[i.length-1]===`text`?(this.addReplaceTextSteps(t,r),e=[]):this.addReplaceStep(n,r)&&(e=[])}}addSetNodeMarkup(){let e=this.schema.nodeFromJSON(this.currentJSON),t=this.schema.nodeFromJSON(this.finalJSON),n=t.content.findDiffStart(e.content),r=e.nodeAt(n),i=t.nodeAt(n);if(n!=null){let e=r.type===i.type?null:i.type;try{this.tr.setNodeMarkup(n,e,i.attrs,i.marks)}catch(t){if(e&&t.message.includes(`Invalid content`))this.tr.replaceWith(n,n+r.nodeSize,i);else throw t}return this.currentJSON=P(this.tr.doc).toJSON(),this.ops=(0,E.createPatch)(this.currentJSON,this.finalJSON),!0}return!1}recreateChangeMarkSteps(){this.toDoc.descendants((e,t)=>{if(!e.isInline)return!0;this.tr.doc.nodesBetween(t,t+e.nodeSize,(n,r)=>{if(!n.isInline)return!0;let i=Math.max(t,r),a=Math.min(t+e.nodeSize,r+n.nodeSize);n.marks.forEach(t=>{t.isInSet(e.marks)||this.tr.removeMark(i,a,t)}),e.marks.forEach(e=>{e.isInSet(n.marks)||this.tr.addMark(i,a,e)})})})}addReplaceStep(e,t){let n=N(this.schema.nodeFromJSON(this.currentJSON),e);if(!n)return!1;if(!this.tr.maybeStep(n).failed)return this.currentJSON=t,!0;throw Error(`No valid step found.`)}addReplaceTextSteps(e,t){let n={...e,value:`xx`},r={...e,value:`yy`},i=F(this.currentJSON),a=F(this.currentJSON);(0,E.applyPatch)(i,[n]),(0,E.applyPatch)(a,[r]);let o=this.schema.nodeFromJSON(i),s=this.schema.nodeFromJSON(a),c=e.value,l=_e(this.currentJSON,e.path),u=this.wordDiffs?de(l,c):ce(l,c),d=o.content.findDiffStart(s.content),f=o.resolve(d+1).marks();for(;u.length;){let e=u.shift();if(e.added){let t=this.schema.nodeFromJSON({type:`text`,text:e.value}).mark(f);if(u.length&&u[0].removed){let e=u.shift();this.tr.replaceWith(d,d+e.value.length,t)}else this.tr.insert(d,t);d+=e.value.length}else if(e.removed)if(u.length&&u[0].added){let t=u.shift(),n=this.schema.nodeFromJSON({type:`text`,text:t.value}).mark(f);this.tr.replaceWith(d,d+e.value.length,n),d+=t.value.length}else this.tr.delete(d,d+e.value.length);else d+=e.value.length}this.currentJSON=t}};function ye(e,t,n={}){return new ve(e,t,n).init()}var be=new Set([`list`,`bulletList`,`orderedList`,`taskList`]);function I(e){let t=[];return e.forEach((e,n)=>{if(be.has(e.type.name)){let r=n+1,i=0;e.forEach(e=>{let n=r+i;t.push({from:n,to:n+e.nodeSize,key:`${e.type.name}:${e.textContent}`}),i+=e.nodeSize})}else t.push({from:n,to:n+e.nodeSize,key:`${e.type.name}:${e.textContent}`})}),t}function xe(e,t){let n=e.length,r=t.length,i=Array.from({length:n+1},()=>Array(r+1).fill(0));for(let a=n-1;a>=0;a--)for(let n=r-1;n>=0;n--)i[a][n]=e[a].key===t[n].key?i[a+1][n+1]+1:Math.max(i[a+1][n],i[a][n+1]);let a=[],o=0,s=0;for(;o<n&&s<r;)e[o].key===t[s].key?(a.push({type:`same`,b:t[s]}),o++,s++):i[o+1][s]>=i[o][s+1]?(a.push({type:`del`,a:e[o]}),o++):(a.push({type:`ins`,b:t[s]}),s++);for(;o<n;)a.push({type:`del`,a:e[o++]});for(;s<r;)a.push({type:`ins`,b:t[s++]});return a}function Se(e,t){let n=xe(I(e),I(t)),r=[],i=0;for(let e of n)e.type===`same`?i=e.b.to:e.type===`ins`?(r.push({fromA:0,toA:0,fromB:e.b.from,toB:e.b.to}),i=e.b.to):r.push({fromA:e.a.from,toA:e.a.to,fromB:i,toB:i});return r}var Ce=400;function L(e,t,n){return t.nodeFromJSON(e.parseWithFallback(n))}function we(e,t){let n=t.filter(e=>e.toB>e.fromB),r=[];return e.steps.forEach((t,i)=>{let a=t instanceof _?`add`:t instanceof d?`remove`:null;if(a===null)return;let o=t,s=e.mapping.slice(i+1),c=s.map(o.from,-1),l=s.map(o.to,1);if(l<=c||n.some(e=>e.fromB<=c&&l<=e.toB))return;let u=e.mapping.slice(0,i).invert(),f=u.map(o.from),p=u.map(o.to);p<=f||r.push({fromA:f,toA:p,fromB:c,toB:l,markName:o.mark.type.name,kind:a})}),r}function Te(e,t,n,r){if(e.length>2e5||t.length>2e5)return{ok:!1,reason:`ceiling`};let i,a;try{i=L(r,n,e),a=L(r,n,t)}catch{return{ok:!1,reason:`parse`}}let o=a,s=null;try{s=ye(i,a,{complexSteps:!0,wordDiffs:!0,simplifyDiff:!0}),o=s.doc}catch{}let c=Se(i,o),l=s?we(s,c):[];return c.length+l.length>Ce?{ok:!1,reason:`ceiling`}:{ok:!0,afterDoc:o,beforeDoc:i,changes:c,markChanges:l}}var Ee=`.ok-diff-ins, .ok-diff-ins-block, [data-diff-deleted]`;function De(e){return e.changes.length+2*e.markChanges.length}function R(e){let t=!1;return e.forEach(e=>{e.isBlock&&(t=!0)}),t}function Oe(e){if(e.childCount===0)return!1;let t=!0;return e.forEach(e=>{e.type.name!==`listItem`&&e.type.name!==`taskItem`&&(t=!1)}),t}function z(e,t,n){let r=document.createElement(n?`div`:`span`);r.className=n?`ok-diff-del ok-diff-del-block`:`ok-diff-del`,r.setAttribute(`data-diff-deleted`,``);let i=e.serializeFragment(t);if(n&&Oe(t)){let e=document.createElement(`ul`);e.appendChild(i),r.appendChild(e)}else r.appendChild(i);return r}function ke(e,t,n,r,i){let a=y.fromSchema(i),o=[];for(let e of r){let n=t.slice(e.fromA,e.toA),r=R(n.content);o.push(m.widget(e.fromB,()=>z(a,n.content,r),{side:-1,ignoreSelection:!0,marks:[]})),o.push(m.inline(e.fromB,e.toB,{class:`ok-diff-ins`},{inclusiveEnd:!0}))}for(let e of n)if(e.toB>e.fromB&&o.push(m.node(e.fromB,e.toB,{class:`ok-diff-ins-block`})),e.toA>e.fromA){let n=t.slice(e.fromA,e.toA),r=R(n.content);o.push(m.widget(e.fromB,()=>z(a,n.content,r),{side:-1,ignoreSelection:!0,marks:[]}))}return h.create(e,o)}var Ae=new Set([`slashCommand`,`blockDragHandle`,`blockMover`,`tableInsertControls`,`fileHandler`,`gfmAutolink`,`inlineLinkInputRule`,`keyboardNav`,`tiptapFindReplace`,`selectionState`,`sourceDirtyObserver`,`tabFocusTrap`]),je=o.filter(e=>!Ae.has(e.name)).map(e=>e.name===`jsxComponent`?p:e),B=r(),Me=S(je);function Ne(e,t){return Te(e,t,Me,c())}var Pe=b.create({name:`renderedDiffDecorations`,addOptions(){return{decorations:h.empty}},addProseMirrorPlugins(){let e=this.options.decorations;return[new g({key:new ee(`renderedDiffDecorations`),props:{decorations:()=>e}})]}});function Fe(e){let t=(0,T.c)(31),{diff:n}=e,r,i,a,o;if(t[0]!==n.afterDoc||t[1]!==n.beforeDoc||t[2]!==n.changes||t[3]!==n.markChanges){let e=ke(n.afterDoc,n.beforeDoc,n.changes,n.markChanges,Me);o=u,a=!1,r=je,i=Pe.configure({decorations:e}),t[0]=n.afterDoc,t[1]=n.beforeDoc,t[2]=n.changes,t[3]=n.markChanges,t[4]=r,t[5]=i,t[6]=a,t[7]=o}else r=t[4],i=t[5],a=t[6],o=t[7];let s;t[8]!==r||t[9]!==i?(s=[...r,i],t[8]=r,t[9]=i,t[10]=s):s=t[10];let c;t[11]===n.afterDoc?c=t[12]:(c=n.afterDoc.toJSON(),t[11]=n.afterDoc,t[12]=c);let d;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(d={attributes:{class:`pt-4 pb-4`}},t[13]=d):d=t[13];let f;t[14]!==a||t[15]!==s||t[16]!==c?(f={editable:a,extensions:s,content:c,editorProps:d},t[14]=a,t[15]=s,t[16]=c,t[17]=f):f=t[17];let p;t[18]===n?p=t[19]:(p=[n],t[18]=n,t[19]=p);let m=o(f,p),[h]=(0,w.useState)(Ie),g=(0,w.useRef)(null),_,v;t[20]===h?(_=t[21],v=t[22]):(_=()=>{let e=g.current;if(e)return e.appendChild(h),()=>{h.parentNode===e&&e.removeChild(h)}},v=[h],t[20]=h,t[21]=_,t[22]=v),(0,w.useLayoutEffect)(_,v);let y;t[23]===Symbol.for(`react.memo_cache_sentinel`)?(y=(0,B.jsx)(`div`,{className:`tiptap-editor`,children:(0,B.jsx)(`div`,{ref:g,style:{display:`contents`}})}),t[23]=y):y=t[23];let b;t[24]===m?b=t[25]:(b=(0,B.jsx)(l,{editor:m,className:`tiptap-editor-portal-content`}),t[24]=m,t[25]=b);let x;t[26]!==h||t[27]!==b?(x=(0,ae.createPortal)(b,h),t[26]=h,t[27]=b,t[28]=x):x=t[28];let S;return t[29]===x?S=t[30]:(S=(0,B.jsxs)(`div`,{className:`editor-doc-scroll min-h-0 flex-1`,"data-testid":`rendered-diff-view`,children:[y,x]}),t[29]=x,t[30]=S),S}function Ie(){let e=document.createElement(`div`);return e.style.display=`contents`,e}function Le(e){let t=0,n=!1;for(let r of e.split(`
|
|
3
|
+
`)){let e=r.startsWith(`+`)&&!r.startsWith(`+++`)||r.startsWith(`-`)&&!r.startsWith(`---`);e&&!n&&(t+=1),n=e}return t}function Re(e){let t=Array.from(e.querySelectorAll(`.diff-code-insert, .diff-code-delete`)),n=[],r=null;for(let e of t){let t=e.closest(`tr`);t&&((r===null||t.previousElementSibling!==r)&&n.push(e),r=t)}return n}var V=class{diff(e,t,n={}){let r;typeof n==`function`?(r=n,n={}):`callback`in n&&(r=n.callback);let i=this.castInput(e,n),a=this.castInput(t,n),o=this.removeEmpty(this.tokenize(i,n)),s=this.removeEmpty(this.tokenize(a,n));return this.diffWithOptionsObj(o,s,n,r)}diffWithOptionsObj(e,t,n,r){let i=e=>{if(e=this.postProcess(e,n),r){setTimeout(function(){r(e)},0);return}else return e},a=t.length,o=e.length,s=1,c=a+o;n.maxEditLength!=null&&(c=Math.min(c,n.maxEditLength));let l=n.timeout??1/0,u=Date.now()+l,d=[{oldPos:-1,lastComponent:void 0}],f=this.extractCommon(d[0],t,e,0,n);if(d[0].oldPos+1>=o&&f+1>=a)return i(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,m=1/0,h=()=>{for(let r=Math.max(p,-s);r<=Math.min(m,s);r+=2){let s,c=d[r-1],l=d[r+1];c&&(d[r-1]=void 0);let u=!1;if(l){let e=l.oldPos-r;u=l&&0<=e&&e<a}let h=c&&c.oldPos+1<o;if(!u&&!h){d[r]=void 0;continue}if(s=!h||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,n):this.addToPath(c,!1,!0,1,n),f=this.extractCommon(s,t,e,r,n),s.oldPos+1>=o&&f+1>=a)return i(this.buildValues(s.lastComponent,t,e))||!0;d[r]=s,s.oldPos+1>=o&&(m=Math.min(m,r-1)),f+1>=a&&(p=Math.max(p,r+1))}s++};if(r)(function e(){setTimeout(function(){if(s>c||Date.now()>u)return r(void 0);h()||e()},0)})();else for(;s<=c&&Date.now()<=u;){let e=h();if(e)return e}}addToPath(e,t,n,r,i){let a=e.lastComponent;return a&&!i.oneChangePerToken&&a.added===t&&a.removed===n?{oldPos:e.oldPos+r,lastComponent:{count:a.count+1,added:t,removed:n,previousComponent:a.previousComponent}}:{oldPos:e.oldPos+r,lastComponent:{count:1,added:t,removed:n,previousComponent:a}}}extractCommon(e,t,n,r,i){let a=t.length,o=n.length,s=e.oldPos,c=s-r,l=0;for(;c+1<a&&s+1<o&&this.equals(n[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,n){return n.comparator?n.comparator(e,t):e===t||!!n.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){let t=[];for(let n=0;n<e.length;n++)e[n]&&t.push(e[n]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join(``)}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,n){let r=[],i;for(;e;)r.push(e),i=e.previousComponent,delete e.previousComponent,e=i;r.reverse();let a=r.length,o=0,s=0,c=0;for(;o<a;o++){let e=r[o];if(e.removed)e.value=this.join(n.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let r=t.slice(s,s+e.count);r=r.map(function(e,t){let r=n[c+t];return r.length>e.length?r:e}),e.value=this.join(r)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return r}};new class extends V{};function ze(e,t){let n;for(n=0;n<e.length&&n<t.length;n++)if(e[n]!=t[n])return e.slice(0,n);return e.slice(0,n)}function Be(e,t){let n;if(!e||!t||e[e.length-1]!=t[t.length-1])return``;for(n=0;n<e.length&&n<t.length;n++)if(e[e.length-(n+1)]!=t[t.length-(n+1)])return e.slice(-n);return e.slice(-n)}function H(e,t,n){if(e.slice(0,t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't start with prefix ${JSON.stringify(t)}; this is a bug`);return n+e.slice(t.length)}function U(e,t,n){if(!t)return e+n;if(e.slice(-t.length)!=t)throw Error(`string ${JSON.stringify(e)} doesn't end with suffix ${JSON.stringify(t)}; this is a bug`);return e.slice(0,-t.length)+n}function W(e,t){return H(e,t,``)}function G(e,t){return U(e,t,``)}function Ve(e,t){return t.slice(0,He(e,t))}function He(e,t){let n=0;e.length>t.length&&(n=e.length-t.length);let r=t.length;e.length<t.length&&(r=e.length);let i=Array(r),a=0;i[0]=0;for(let e=1;e<r;e++){for(t[e]==t[a]?i[e]=i[a]:i[e]=a;a>0&&t[e]!=t[a];)a=i[a];t[e]==t[a]&&a++}a=0;for(let r=n;r<e.length;r++){for(;a>0&&e[r]!=t[a];)a=i[a];e[r]==t[a]&&a++}return a}function Ue(e,t){let n=[];for(let r of Array.from(t.segment(e))){let e=r.segment;n.length&&/\s/.test(n[n.length-1])&&/\s/.test(e)?n[n.length-1]+=e:n.push(e)}return n}function K(e,t){if(t)return J(e,t)[1];let n;for(n=e.length-1;n>=0&&e[n].match(/\s/);n--);return e.substring(n+1)}function q(e,t){if(t)return J(e,t)[0];let n=e.match(/^\s*/);return n?n[0]:``}function J(e,t){if(!t)return[q(e),K(e)];if(t.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);let n=Ue(e,t),r=n[0],i=n[n.length-1];return[/\s/.test(r)?r:``,/\s/.test(i)?i:``]}var Y=`a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}`,We=RegExp(`[${Y}]+|\\s+|[^${Y}]`,`ug`);new class extends V{equals(e,t,n){return n.ignoreCase&&(e=e.toLowerCase(),t=t.toLowerCase()),e.trim()===t.trim()}tokenize(e,t={}){let n;if(t.intlSegmenter){let r=t.intlSegmenter;if(r.resolvedOptions().granularity!=`word`)throw Error(`The segmenter passed must have a granularity of "word"`);n=Ue(e,r)}else n=e.match(We)||[];let r=[],i=null;return n.forEach(e=>{/\s/.test(e)?i==null?r.push(e):r.push(r.pop()+e):i!=null&&/\s/.test(i)?r[r.length-1]==i?r.push(r.pop()+e):r.push(i+e):r.push(e),i=e}),r}join(e){return e.map((e,t)=>t==0?e:e.replace(/^\s+/,``)).join(``)}postProcess(e,t){if(!e||t.oneChangePerToken)return e;let n=null,r=null,i=null;return e.forEach(e=>{e.added?r=e:e.removed?i=e:((r||i)&&Ge(n,i,r,e,t.intlSegmenter),n=e,r=null,i=null)}),(r||i)&&Ge(n,i,r,null,t.intlSegmenter),e}};function Ge(e,t,n,r,i){if(t&&n){let[a,o]=J(t.value,i),[s,c]=J(n.value,i);if(e){let r=ze(a,s);e.value=U(e.value,s,r),t.value=W(t.value,r),n.value=W(n.value,r)}if(r){let e=Be(o,c);r.value=H(r.value,c,e),t.value=G(t.value,e),n.value=G(n.value,e)}}else if(n){if(e){let e=q(n.value,i);n.value=n.value.substring(e.length)}if(r){let e=q(r.value,i);r.value=r.value.substring(e.length)}}else if(e&&r){let n=q(r.value,i),[a,o]=J(t.value,i),s=ze(n,a);t.value=W(t.value,s);let c=Be(W(n,s),o);t.value=G(t.value,c),r.value=H(r.value,n,c),e.value=U(e.value,n,n.slice(0,n.length-c.length))}else if(r){let e=q(r.value,i),n=Ve(K(t.value,i),e);t.value=G(t.value,n)}else if(e){let n=Ve(K(e.value,i),q(t.value,i));t.value=W(t.value,n)}}new class extends V{tokenize(e){let t=RegExp(`(\\r?\\n)|[${Y}]+|[^\\S\\n\\r]+|[^${Y}]`,`ug`);return e.match(t)||[]}};var Ke=new class extends V{constructor(){super(...arguments),this.tokenize=X}equals(e,t,n){return n.ignoreWhitespace?((!n.newlineIsToken||!e.includes(`
|
|
4
|
+
`))&&(e=e.trim()),(!n.newlineIsToken||!t.includes(`
|
|
5
|
+
`))&&(t=t.trim())):n.ignoreNewlineAtEof&&!n.newlineIsToken&&(e.endsWith(`
|
|
6
|
+
`)&&(e=e.slice(0,-1)),t.endsWith(`
|
|
7
|
+
`)&&(t=t.slice(0,-1))),super.equals(e,t,n)}};function qe(e,t,n){return Ke.diff(e,t,n)}function X(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
|
|
8
|
+
`));let n=[],r=e.split(/(\n|\r\n)/);r[r.length-1]||r.pop();for(let e=0;e<r.length;e++){let i=r[e];e%2&&!t.newlineIsToken?n[n.length-1]+=i:n.push(i)}return n}function Je(e){return e==`.`||e==`!`||e==`?`}new class extends V{tokenize(e){let t=[],n=0;for(let r=0;r<e.length;r++){if(r==e.length-1){t.push(e.slice(n));break}if(Je(e[r])&&e[r+1].match(/\s/)){for(t.push(e.slice(n,r+1)),r=n=r+1;e[r+1]?.match(/\s/);)r++;t.push(e.slice(n,r+1)),n=r+1}}return t}},new class extends V{tokenize(e){return e.split(/([{}:;,]|\s+)/)}},new class extends V{constructor(){super(...arguments),this.tokenize=X}get useLongestToken(){return!0}castInput(e,t){let{undefinedReplacement:n,stringifyReplacer:r=(e,t)=>t===void 0?n:t}=t;return typeof e==`string`?e:JSON.stringify(Z(e,null,null,r),null,` `)}equals(e,t,n){return super.equals(e.replace(/,([\r\n])/g,`$1`),t.replace(/,([\r\n])/g,`$1`),n)}};function Z(e,t,n,r,i){t||=[],n||=[],r&&(e=r(i===void 0?``:i,e));let a;for(a=0;a<t.length;a+=1)if(t[a]===e)return n[a];let o;if(Object.prototype.toString.call(e)===`[object Array]`){for(t.push(e),o=Array(e.length),n.push(o),a=0;a<e.length;a+=1)o[a]=Z(e[a],t,n,r,String(a));return t.pop(),n.pop(),o}if(e&&e.toJSON&&(e=e.toJSON()),typeof e==`object`&&e){t.push(e),o={},n.push(o);let i=[],s;for(s in e)Object.prototype.hasOwnProperty.call(e,s)&&i.push(s);for(i.sort(),a=0;a<i.length;a+=1)s=i[a],o[s]=Z(e[s],t,n,r,s);t.pop(),n.pop()}else o=e;return o}new class extends V{tokenize(e){return e.slice()}join(e){return e}removeEmpty(e){return e}};var Ye={includeIndex:!0,includeUnderline:!0,includeFileHeaders:!0};function Xe(e,t,n,r,i,a,o){let s;s=o?typeof o==`function`?{callback:o}:o:{},s.context===void 0&&(s.context=4);let c=s.context;if(s.newlineIsToken)throw Error(`newlineIsToken may not be used with patch-generation functions, only with diffing functions`);if(s.callback){let{callback:e}=s;qe(n,r,Object.assign(Object.assign({},s),{callback:t=>{e(l(t))}}))}else return l(qe(n,r,s));function l(n){if(!n)return;n.push({value:``,lines:[]});function r(e){return e.map(function(e){return` `+e})}let o=[],s=0,l=0,u=[],d=1,f=1;for(let e=0;e<n.length;e++){let t=n[e],i=t.lines||$e(t.value);if(t.lines=i,t.added||t.removed){if(!s){let t=n[e-1];s=d,l=f,t&&(u=c>0?r(t.lines.slice(-c)):[],s-=u.length,l-=u.length)}for(let e of i)u.push((t.added?`+`:`-`)+e);t.added?f+=i.length:d+=i.length}else{if(s)if(i.length<=c*2&&e<n.length-2)for(let e of r(i))u.push(e);else{let e=Math.min(i.length,c);for(let t of r(i.slice(0,e)))u.push(t);let t={oldStart:s,oldLines:d-s+e,newStart:l,newLines:f-l+e,lines:u};o.push(t),s=0,l=0,u=[]}d+=i.length,f+=i.length}}for(let e of o)for(let t=0;t<e.lines.length;t++)e.lines[t].endsWith(`
|
|
9
|
+
`)?e.lines[t]=e.lines[t].slice(0,-1):(e.lines.splice(t+1,0,`\`),t++);return{oldFileName:e,newFileName:t,oldHeader:i,newHeader:a,hunks:o}}}function Q(e,t){if(t||=Ye,Array.isArray(e)){if(e.length>1&&!t.includeFileHeaders)throw Error(`Cannot omit file headers on a multi-file patch. (The result would be unparseable; how would a tool trying to apply the patch know which changes are to which file?)`);return e.map(e=>Q(e,t)).join(`
|
|
10
|
+
`)}let n=[];t.includeIndex&&e.oldFileName==e.newFileName&&n.push(`Index: `+e.oldFileName),t.includeUnderline&&n.push(`===================================================================`),t.includeFileHeaders&&(n.push(`--- `+e.oldFileName+(e.oldHeader===void 0?``:` `+e.oldHeader)),n.push(`+++ `+e.newFileName+(e.newHeader===void 0?``:` `+e.newHeader)));for(let t=0;t<e.hunks.length;t++){let r=e.hunks[t];r.oldLines===0&&--r.oldStart,r.newLines===0&&--r.newStart,n.push(`@@ -`+r.oldStart+`,`+r.oldLines+` +`+r.newStart+`,`+r.newLines+` @@`);for(let e of r.lines)n.push(e)}return n.join(`
|
|
11
|
+
`)+`
|
|
12
|
+
`}function Ze(e,t,n,r,i,a,o){if(typeof o==`function`&&(o={callback:o}),o?.callback){let{callback:s}=o;Xe(e,t,n,r,i,a,Object.assign(Object.assign({},o),{callback:e=>{s(e?Q(e,o.headerOptions):void 0)}}))}else{let s=Xe(e,t,n,r,i,a,o);return s?Q(s,o?.headerOptions):void 0}}function Qe(e,t,n,r,i,a){return Ze(e,e,t,n,r,i,a)}function $e(e){let t=e.endsWith(`
|
|
13
|
+
`),n=e.split(`
|
|
14
|
+
`).map(e=>e+`
|
|
15
|
+
`);return t?n.pop():n.push(n.pop().slice(0,-1)),n}function $(e){let t=0,n=0;for(let r of e.split(`
|
|
16
|
+
`))r.startsWith(`+`)&&!r.startsWith(`+++`)?t++:r.startsWith(`-`)&&!r.startsWith(`---`)&&n++;return{additions:t,deletions:n}}function et(e,t){return`${e}\u0000${t}`}function tt(e,t,n){let r=v(e).body,i=v(t).body;return r===i?``:Qe(n,r,i,``,``,{context:Math.max(r.split(`
|
|
17
|
+
`).length,i.split(`
|
|
18
|
+
`).length)})}function nt(e,t,n,r,i){let o=(0,T.c)(10),s=r===void 0?`vs-live`:r,c=i===void 0?null:i,{activeProvider:l}=a(),u;o[0]===Symbol.for(`react.memo_cache_sentinel`)?(u={status:`idle`,diff:null},o[0]=u):u=o[0];let[d,f]=(0,w.useState)(u),p=(0,w.useRef)(l),m;o[1]===l?m=o[2]:(m=()=>{p.current=l},o[1]=l,o[2]=m),(0,w.useEffect)(m);let h,g;return o[3]!==n||o[4]!==t||o[5]!==s||o[6]!==c||o[7]!==e?(h=()=>{if(!e){f({status:`idle`,diff:null});return}let r=e,i=!1;f({status:`loading`,diff:null});let a=async function(e){let r=et(t,e),i=n.get(r);if(i!==void 0)return i;let a=await fetch(`/api/history/${e}?docName=${encodeURIComponent(t)}`);if(!a.ok)return console.error(`[timeline-diff] history fetch returned non-ok response`,{sha:e,docName:t,status:a.status}),null;let o=(await a.json()).content??``;return n.set(r,o),o};return(async function(){try{let e=await a(r);if(i)return;if(e===null){f({status:`error`,diff:null});return}let n,o;if(s===`vs-parent`){let t=c?await a(c):``;if(i)return;if(t===null){f({status:`error`,diff:null});return}n=t,o=e}else n=e,o=p.current?.document.getText(`source`).toString()??``;let l=v(n).body,u=v(o).body,d=tt(n,o,t);if(i)return;let{additions:m,deletions:h}=$(d);f({status:`ready`,diff:d,additions:m,deletions:h,before:l,after:u})}catch(e){i||(console.error(`[timeline-diff] failed to load entry diff`,{sha:r,docName:t,mode:s,err:e}),f({status:`error`,diff:null}))}})(),()=>{i=!0}},g=[e,t,n,s,c],o[3]=n,o[4]=t,o[5]=s,o[6]=c,o[7]=e,o[8]=h,o[9]=g):(h=o[8],g=o[9]),(0,w.useEffect)(h,g),d}export{Fe as a,De as c,Le as i,nt as n,Ne as o,Re as r,Ee as s,$ as t};
|
package/dist/public/assets/{vennDiagram-L72KCM5P-CeGSzDp-.js → vennDiagram-L72KCM5P-DIXJ-f9A.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e}from"./chunk-Y2CYZVJY-B5uX60M6.js";import"./src-DU4IiWLl.js";import{H as t,K as n,U as r,a as i,b as a,c as o,et as s,f as c,nt as l,rt as u,tt as d,v as f,w as p,y as m}from"./chunk-WYO6CB5R-CPK-Z4Zn.js";import{C as h}from"./src-DyReJWGm.js";import{i as g}from"./chunk-ICXQ74PX-MBl6EECh.js";import{t as _}from"./chunk-VAUOI2AC-D5KfNXdk.js";import{t as v}from"./rough.esm-CIwjGUJO.js";var y=(e,t)=>l(e,`a`,-t),b=1e-10;function x(e,t){let n=C(e),r=n.filter(t=>S(t,e)),i=0,a=0,o=[];if(r.length>1){let t=O(r);for(let e=0;e<r.length;++e){let n=r[e];n.angle=Math.atan2(n.x-t.x,n.y-t.y)}r.sort((e,t)=>t.angle-e.angle);let n=r[r.length-1];for(let t=0;t<r.length;++t){let s=r[t];a+=(n.x+s.x)*(s.y-n.y);let c={x:(s.x+n.x)/2,y:(s.y+n.y)/2},l=null;for(let t=0;t<s.parentIndex.length;++t)if(n.parentIndex.includes(s.parentIndex[t])){let r=e[s.parentIndex[t]],i=Math.atan2(s.x-r.x,s.y-r.y),a=Math.atan2(n.x-r.x,n.y-r.y),o=a-i;o<0&&(o+=2*Math.PI);let u=a-o/2,d=T(c,{x:r.x+r.radius*Math.sin(u),y:r.y+r.radius*Math.cos(u)});d>r.radius*2&&(d=r.radius*2),(l==null||l.width>d)&&(l={circle:r,width:d,p1:s,p2:n,large:d>r.radius,sweep:!0})}l!=null&&(o.push(l),i+=w(l.circle.radius,l.width),n=s)}}else{let t=e[0];for(let n=1;n<e.length;++n)e[n].radius<t.radius&&(t=e[n]);let n=!1;for(let r=0;r<e.length;++r)if(T(e[r],t)>Math.abs(t.radius-e[r].radius)){n=!0;break}n?i=a=0:(i=t.radius*t.radius*Math.PI,o.push({circle:t,p1:{x:t.x,y:t.y+t.radius},p2:{x:t.x-b,y:t.y+t.radius},width:t.radius*2,large:!0,sweep:!0}))}return a/=2,t&&(t.area=i+a,t.arcArea=i,t.polygonArea=a,t.arcs=o,t.innerPoints=r,t.intersectionPoints=n),i+a}function S(e,t){return t.every(t=>T(e,t)<t.radius+b)}function C(e){let t=[];for(let n=0;n<e.length;++n)for(let r=n+1;r<e.length;++r){let i=D(e[n],e[r]);for(let e of i)e.parentIndex=[n,r],t.push(e)}return t}function w(e,t){return e*e*Math.acos(1-t/e)-(e-t)*Math.sqrt(t*(2*e-t))}function T(e,t){return Math.sqrt((e.x-t.x)*(e.x-t.x)+(e.y-t.y)*(e.y-t.y))}function E(e,t,n){if(n>=e+t)return 0;if(n<=Math.abs(e-t))return Math.PI*Math.min(e,t)*Math.min(e,t);let r=e-(n*n-t*t+e*e)/(2*n),i=t-(n*n-e*e+t*t)/(2*n);return w(e,r)+w(t,i)}function D(e,t){let n=T(e,t),r=e.radius,i=t.radius;if(n>=r+i||n<=Math.abs(r-i))return[];let a=(r*r-i*i+n*n)/(2*n),o=Math.sqrt(r*r-a*a),s=e.x+a*(t.x-e.x)/n,c=e.y+a*(t.y-e.y)/n,l=-(t.y-e.y)*(o/n),u=-(t.x-e.x)*(o/n);return[{x:s+l,y:c-u},{x:s-l,y:c+u}]}function O(e){let t={x:0,y:0};for(let n of e)t.x+=n.x,t.y+=n.y;return t.x/=e.length,t.y/=e.length,t}function k(e,t,n,r){r||={};let i=r.maxIterations||100,a=r.tolerance||1e-10,o=e(t),s=e(n),c=n-t;if(o*s>0)throw`Initial bisect points must have opposite signs`;if(o===0)return t;if(s===0)return n;for(let n=0;n<i;++n){c/=2;let n=t+c,r=e(n);if(r*o>=0&&(t=n),Math.abs(c)<a||r===0)return n}return t+c}function A(e){let t=Array(e);for(let n=0;n<e;++n)t[n]=0;return t}function j(e,t){return A(e).map(()=>A(t))}function M(e,t){let n=0;for(let r=0;r<e.length;++r)n+=e[r]*t[r];return n}function N(e){return Math.sqrt(M(e,e))}function P(e,t,n){for(let r=0;r<t.length;++r)e[r]=t[r]*n}function F(e,t,n,r,i){for(let a=0;a<e.length;++a)e[a]=t*n[a]+r*i[a]}function I(e,t,n){n||={};let r=n.maxIterations||t.length*200,i=n.nonZeroDelta||1.05,a=n.zeroDelta||.001,o=n.minErrorDelta||1e-6,s=n.minErrorDelta||1e-5,c=n.rho===void 0?1:n.rho,l=n.chi===void 0?2:n.chi,u=n.psi===void 0?-.5:n.psi,d=n.sigma===void 0?.5:n.sigma,f,p=t.length,m=Array(p+1);m[0]=t,m[0].fx=e(t),m[0].id=0;for(let n=0;n<p;++n){let r=t.slice();r[n]=r[n]?r[n]*i:a,m[n+1]=r,m[n+1].fx=e(r),m[n+1].id=n+1}function h(e){for(let t=0;t<e.length;t++)m[p][t]=e[t];m[p].fx=e.fx}let g=(e,t)=>e.fx-t.fx,_=t.slice(),v=t.slice(),y=t.slice(),b=t.slice();for(let t=0;t<r;++t){if(m.sort(g),n.history){let e=m.map(e=>{let t=e.slice();return t.fx=e.fx,t.id=e.id,t});e.sort((e,t)=>e.id-t.id),n.history.push({x:m[0].slice(),fx:m[0].fx,simplex:e})}f=0;for(let e=0;e<p;++e)f=Math.max(f,Math.abs(m[0][e]-m[1][e]));if(Math.abs(m[0].fx-m[p].fx)<o&&f<s)break;for(let e=0;e<p;++e){_[e]=0;for(let t=0;t<p;++t)_[e]+=m[t][e];_[e]/=p}let t=m[p];if(F(v,1+c,_,-c,t),v.fx=e(v),v.fx<m[0].fx)F(b,1+l,_,-l,t),b.fx=e(b),b.fx<v.fx?h(b):h(v);else if(v.fx>=m[p-1].fx){let n=!1;if(v.fx>t.fx?(F(y,1+u,_,-u,t),y.fx=e(y),y.fx<t.fx?h(y):n=!0):(F(y,1-u*c,_,u*c,t),y.fx=e(y),y.fx<v.fx?h(y):n=!0),n){if(d>=1)break;for(let t=1;t<m.length;++t)F(m[t],1-d,m[0],d,m[t]),m[t].fx=e(m[t])}}else h(v)}return m.sort(g),{fx:m[0].fx,x:m[0]}}function L(e,t,n,r,i,a,o){let s=n.fx,c=M(n.fxprime,t),l=s,u=s,d=c,f=0;i||=1,a||=1e-6,o||=.1;function p(u,f,p){for(let m=0;m<16;++m)if(i=(u+f)/2,F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||l>=p)f=i;else{if(Math.abs(d)<=-o*c)return i;d*(f-u)>=0&&(f=u),u=i,p=l}return 0}for(let m=0;m<10;++m){if(F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||m&&l>=u)return p(f,i,u);if(Math.abs(d)<=-o*c)return i;if(d>=0)return p(i,f,l);u=l,f=i,i*=2}return i}function R(e,t,n){let r={x:t.slice(),fx:0,fxprime:t.slice()},i={x:t.slice(),fx:0,fxprime:t.slice()},a=t.slice(),o,s,c=1,l;n||={},l=n.maxIterations||t.length*20,r.fx=e(r.x,r.fxprime),o=r.fxprime.slice(),P(o,r.fxprime,-1);for(let t=0;t<l;++t){if(c=L(e,o,r,i,c),n.history&&n.history.push({x:r.x.slice(),fx:r.fx,fxprime:r.fxprime.slice(),alpha:c}),!c)P(o,r.fxprime,-1);else{F(a,1,i.fxprime,-1,r.fxprime);let e=M(r.fxprime,r.fxprime),t=Math.max(0,M(a,i.fxprime)/e);F(o,t,o,-1,i.fxprime),s=r,r=i,i=s}if(N(r.fxprime)<=1e-5)break}return n.history&&n.history.push({x:r.x.slice(),fx:r.fx,fxprime:r.fxprime.slice(),alpha:c}),r}function ee(e,t={}){t.maxIterations=t.maxIterations||500;let n=t.initialLayout||ae,r=t.lossFunction||B,i=ne(e,t),a=n(i,t),o=Object.keys(a),s=[];for(let e of o)s.push(a[e].x),s.push(a[e].y);let c=I(e=>{let t={};for(let n=0;n<o.length;++n){let r=o[n];t[r]={x:e[2*n],y:e[2*n+1],radius:a[r].radius}}return r(t,i)},s,t).x;for(let e=0;e<o.length;++e){let t=o[e];a[t].x=c[2*e],a[t].y=c[2*e+1]}return a}var te=1e-10;function z(e,t,n){return Math.min(e,t)*Math.min(e,t)*Math.PI<=n+te?Math.abs(e-t):k(r=>E(e,t,r)-n,0,e+t)}function ne(e,t={}){let n=t.distinct,r=e.map(e=>Object.assign({},e));function i(e){return e.join(`;`)}if(n){let e=new Map;for(let t of r)for(let n=0;n<t.sets.length;n++){let r=String(t.sets[n]);e.set(r,t.size+(e.get(r)||0));for(let i=n+1;i<t.sets.length;i++){let n=String(t.sets[i]),a=`${r};${n}`,o=`${n};${r}`;e.set(a,t.size+(e.get(a)||0)),e.set(o,t.size+(e.get(o)||0))}}for(let t of r)t.sets.length<3&&(t.size=e.get(i(t.sets)))}let a=[],o=new Set;for(let e of r)if(e.sets.length===1)a.push(e.sets[0]);else if(e.sets.length===2){let t=e.sets[0],n=e.sets[1];o.add(i(e.sets)),o.add(i([n,t]))}a.sort((e,t)=>e===t?0:e<t?-1:1);for(let e=0;e<a.length;++e){let t=a[e];for(let n=e+1;n<a.length;++n){let e=a[n];o.has(i([t,e]))||r.push({sets:[t,e],size:0})}}return r}function re(e,t,n){let r=j(t.length,t.length),i=j(t.length,t.length);return e.filter(e=>e.sets.length===2).forEach(e=>{let a=n[e.sets[0]],o=n[e.sets[1]],s=z(Math.sqrt(t[a].size/Math.PI),Math.sqrt(t[o].size/Math.PI),e.size);r[a][o]=r[o][a]=s;let c=0;e.size+1e-10>=Math.min(t[a].size,t[o].size)?c=1:e.size<=1e-10&&(c=-1),i[a][o]=i[o][a]=c}),{distances:r,constraints:i}}function ie(e,t,n,r){for(let e=0;e<t.length;++e)t[e]=0;let i=0;for(let a=0;a<n.length;++a){let o=e[2*a],s=e[2*a+1];for(let c=a+1;c<n.length;++c){let l=e[2*c],u=e[2*c+1],d=n[a][c],f=r[a][c],p=(l-o)*(l-o)+(u-s)*(u-s),m=Math.sqrt(p),h=p-d*d;f>0&&m<=d||f<0&&m>=d||(i+=2*h*h,t[2*a]+=4*h*(o-l),t[2*a+1]+=4*h*(s-u),t[2*c]+=4*h*(l-o),t[2*c+1]+=4*h*(u-s))}}return i}function ae(e,t={}){let n=se(e,t),r=t.lossFunction||B;if(e.length>=8){let i=oe(e,t),a=r(i,e),o=r(n,e);a+1e-8<o&&(n=i)}return n}function oe(e,t={}){let n=t.restarts||10,r=[],i={};for(let t of e)t.sets.length===1&&(i[t.sets[0]]=r.length,r.push(t));let{distances:a,constraints:o}=re(e,r,i),s=N(a.map(N))/a.length;a=a.map(e=>e.map(e=>e/s));let c=(e,t)=>ie(e,t,a,o),l=null;for(let e=0;e<n;++e){let e=R(c,A(a.length*2).map(Math.random),t);(!l||e.fx<l.fx)&&(l=e)}let u=l.x,d={};for(let e=0;e<r.length;++e){let t=r[e];d[t.sets[0]]={x:u[2*e]*s,y:u[2*e+1]*s,radius:Math.sqrt(t.size/Math.PI)}}if(t.history)for(let e of t.history)P(e.x,s);return d}function se(e,t){let n=t&&t.lossFunction?t.lossFunction:B,r={},i={};for(let t of e)if(t.sets.length===1){let e=t.sets[0];r[e]={x:1e10,y:1e10,rowid:r.length,size:t.size,radius:Math.sqrt(t.size/Math.PI)},i[e]=[]}e=e.filter(e=>e.sets.length===2);for(let t of e){let e=t.weight==null?1:t.weight,n=t.sets[0],a=t.sets[1];t.size+te>=Math.min(r[n].size,r[a].size)&&(e=0),i[n].push({set:a,size:t.size,weight:e}),i[a].push({set:n,size:t.size,weight:e})}let a=[];Object.keys(i).forEach(e=>{let t=0;for(let n=0;n<i[e].length;++n)t+=i[e][n].size*i[e][n].weight;a.push({set:e,size:t})});function o(e,t){return t.size-e.size}a.sort(o);let s={};function c(e){return e.set in s}function l(e,t){r[t].x=e.x,r[t].y=e.y,s[t]=!0}l({x:0,y:0},a[0].set);for(let t=1;t<a.length;++t){let s=a[t].set,d=i[s].filter(c),f=r[s];if(d.sort(o),d.length===0)throw`ERROR: missing pairwise overlap information`;let p=[];for(var u=0;u<d.length;++u){let e=r[d[u].set],t=z(f.radius,e.radius,d[u].size);p.push({x:e.x+t,y:e.y}),p.push({x:e.x-t,y:e.y}),p.push({y:e.y+t,x:e.x}),p.push({y:e.y-t,x:e.x});for(let n=u+1;n<d.length;++n){let i=r[d[n].set],a=z(f.radius,i.radius,d[n].size),o=D({x:e.x,y:e.y,radius:t},{x:i.x,y:i.y,radius:a});p.push(...o)}}let m=1e50,h=p[0];for(let t of p){r[s].x=t.x,r[s].y=t.y;let i=n(r,e);i<m&&(m=i,h=t)}l(h,s)}return r}function B(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight;n+=i*(t-r.size)*(t-r.size)}return n}function ce(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight,a=Math.log((t+1)/(r.size+1));n+=i*a*a}return n}function le(e,t,n){if(n==null?e.sort((e,t)=>t.radius-e.radius):e.sort(n),e.length>0){let t=e[0].x,n=e[0].y;for(let r of e)r.x-=t,r.y-=n}if(e.length===2&&T(e[0],e[1])<Math.abs(e[1].radius-e[0].radius)&&(e[1].x=e[0].x+e[0].radius-e[1].radius-1e-10,e[1].y=e[0].y),e.length>1){let n=Math.atan2(e[1].x,e[1].y)-t,r=Math.cos(n),i=Math.sin(n);for(let t of e){let e=t.x,n=t.y;t.x=r*e-i*n,t.y=i*e+r*n}}if(e.length>2){let n=Math.atan2(e[2].x,e[2].y)-t;for(;n<0;)n+=2*Math.PI;for(;n>2*Math.PI;)n-=2*Math.PI;if(n>Math.PI){let t=e[1].y/(1e-10+e[1].x);for(let n of e){var r=(n.x+t*n.y)/(1+t*t);n.x=2*r-n.x,n.y=2*r*t-n.y}}}}function ue(e){e.forEach(e=>{e.parent=e});function t(e){return e.parent!==e&&(e.parent=t(e.parent)),e.parent}function n(e,n){let r=t(e);r.parent=t(n)}for(let t=0;t<e.length;++t)for(let r=t+1;r<e.length;++r){let i=e[t].radius+e[r].radius;T(e[t],e[r])+1e-10<i&&n(e[r],e[t])}let r=new Map;for(let n=0;n<e.length;++n){let i=t(e[n]).parent.setid;r.has(i)||r.set(i,[]),r.get(i).push(e[n])}return e.forEach(e=>{delete e.parent}),Array.from(r.values())}function V(e){let t=t=>({max:e.reduce((e,n)=>Math.max(e,n[t]+n.radius),-1/0),min:e.reduce((e,n)=>Math.min(e,n[t]-n.radius),1/0)});return{xRange:t(`x`),yRange:t(`y`)}}function de(e,t,n){t??=Math.PI/2;let r=me(e).map(e=>Object.assign({},e)),i=ue(r);for(let e of i){le(e,t,n);let r=V(e);e.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),e.bounds=r}i.sort((e,t)=>t.size-e.size),r=i[0];let a=r.bounds,o=(a.xRange.max-a.xRange.min)/50;function s(e,t,n){if(!e)return;let i=e.bounds,s,c;if(t)s=a.xRange.max-i.xRange.min+o;else{s=a.xRange.max-i.xRange.max;let e=(i.xRange.max-i.xRange.min)/2-(a.xRange.max-a.xRange.min)/2;e<0&&(s+=e)}if(n)c=a.yRange.max-i.yRange.min+o;else{c=a.yRange.max-i.yRange.max;let e=(i.yRange.max-i.yRange.min)/2-(a.yRange.max-a.yRange.min)/2;e<0&&(c+=e)}for(let t of e)t.x+=s,t.y+=c,r.push(t)}let c=1;for(;c<i.length;)s(i[c],!0,!1),s(i[c+1],!1,!0),s(i[c+2],!0,!0),c+=3,a=V(r);return pe(r)}function fe(e,t,n,r,i){let a=me(e);t-=2*r,n-=2*r;let{xRange:o,yRange:s}=V(a);if(o.max===o.min||s.max===s.min)return console.log(`not scaling solution: zero size detected`),e;let c,l;if(i){let e=Math.sqrt(i/Math.PI)*2;c=t/e,l=n/e}else c=t/(o.max-o.min),l=n/(s.max-s.min);let u=Math.min(l,c),d=(t-(o.max-o.min)*u)/2,f=(n-(s.max-s.min)*u)/2;return pe(a.map(e=>({radius:u*e.radius,x:r+d+(e.x-o.min)*u,y:r+f+(e.y-s.min)*u,setid:e.setid})))}function pe(e){let t={};for(let n of e)t[n.setid]=n;return t}function me(e){return Object.keys(e).map(t=>Object.assign(e[t],{setid:t}))}function he(e={}){let t=!1,n=600,r=350,i=15,a=1e3,o=Math.PI/2,s=!0,c=null,l=!0,u=!0,d=null,f=null,p=!1,m=null,h=e&&e.symmetricalTextCentre?e.symmetricalTextCentre:!1,g={},_=e&&e.colourScheme?e.colourScheme:e&&e.colorScheme?e.colorScheme:[`#1f77b4`,`#ff7f0e`,`#2ca02c`,`#d62728`,`#9467bd`,`#8c564b`,`#e377c2`,`#7f7f7f`,`#bcbd22`,`#17becf`],v=0,y=function(e){if(e in g)return g[e];var t=g[e]=_[v];return v+=1,v>=_.length&&(v=0),t},b=ee,x=B;function S(g){let _=g.datum(),v=new Set;_.forEach(e=>{e.size==0&&e.sets.length==1&&v.add(e.sets[0])}),_=_.filter(e=>!e.sets.some(e=>v.has(e)));let S={},C={};if(_.length>0){let e=b(_,{lossFunction:x,distinct:p});s&&(e=de(e,o,f)),S=fe(e,n,r,i,c),C=ve(S,_,h)}let w={};_.forEach(e=>{e.label&&(w[e.sets]=e.label)});function T(e){if(e.sets in w)return w[e.sets];if(e.sets.length==1)return``+e.sets[0]}g.selectAll(`svg`).data([S]).enter().append(`svg`);let E=g.select(`svg`);t?E.attr(`viewBox`,`0 0 ${n} ${r}`):E.attr(`width`,n).attr(`height`,r);let D={},O=!1;E.selectAll(`.venn-area path`).each(function(e){let t=this.getAttribute(`d`);e.sets.length==1&&t&&!p&&(O=!0,D[e.sets[0]]=be(t))});function k(e){return t=>Ce(e.sets.map(e=>{let i=D[e],a=S[e];return i||={x:n/2,y:r/2,radius:1},a||={x:n/2,y:r/2,radius:1},{x:i.x*(1-t)+a.x*t,y:i.y*(1-t)+a.y*t,radius:i.radius*(1-t)+a.radius*t}}),m)}let A=E.selectAll(`.venn-area`).data(_,e=>e.sets),j=A.enter().append(`g`).attr(`class`,e=>`venn-area venn-${e.sets.length==1?`circle`:`intersection`}${e.colour||e.color?` venn-coloured`:``}`).attr(`data-venn-sets`,e=>e.sets.join(`_`)),M=j.append(`path`),N=j.append(`text`).attr(`class`,`label`).text(e=>T(e)).attr(`text-anchor`,`middle`).attr(`dy`,`.35em`).attr(`x`,n/2).attr(`y`,r/2);u&&(M.style(`fill-opacity`,`0`).filter(e=>e.sets.length==1).style(`fill`,e=>e.colour?e.colour:e.color?e.color:y(e.sets)).style(`fill-opacity`,`.25`),N.style(`fill`,t=>t.colour||t.color?`#FFF`:e.textFill?e.textFill:t.sets.length==1?y(t.sets):`#444`));function P(e){return typeof e.transition==`function`?e.transition(`venn`).duration(a):e}let F=g;O&&typeof F.transition==`function`?(F=P(g),F.selectAll(`path`).attrTween(`d`,k)):F.selectAll(`path`).attr(`d`,e=>Ce(e.sets.map(e=>S[e])),m);let I=F.selectAll(`text`).filter(e=>e.sets in C).text(e=>T(e)).attr(`x`,e=>Math.floor(C[e.sets].x)).attr(`y`,e=>Math.floor(C[e.sets].y));l&&(O?`on`in I?I.on(`end`,H(S,T)):I.each(`end`,H(S,T)):I.each(H(S,T)));let L=P(A.exit()).remove();typeof A.transition==`function`&&L.selectAll(`path`).attrTween(`d`,k);let R=L.selectAll(`text`).attr(`x`,n/2).attr(`y`,r/2);return d!==null&&(N.style(`font-size`,`0px`),I.style(`font-size`,d),R.style(`font-size`,`0px`)),{circles:S,textCentres:C,nodes:A,enter:j,update:F,exit:L}}return S.wrap=function(e){return arguments.length?(l=e,S):l},S.useViewBox=function(){return t=!0,S},S.width=function(e){return arguments.length?(n=e,S):n},S.height=function(e){return arguments.length?(r=e,S):r},S.padding=function(e){return arguments.length?(i=e,S):i},S.distinct=function(e){return arguments.length?(p=e,S):p},S.colours=function(e){return arguments.length?(y=e,S):y},S.colors=function(e){return arguments.length?(y=e,S):y},S.fontSize=function(e){return arguments.length?(d=e,S):d},S.round=function(e){return arguments.length?(m=e,S):m},S.duration=function(e){return arguments.length?(a=e,S):a},S.layoutFunction=function(e){return arguments.length?(b=e,S):b},S.normalize=function(e){return arguments.length?(s=e,S):s},S.scaleToFit=function(e){return arguments.length?(c=e,S):c},S.styled=function(e){return arguments.length?(u=e,S):u},S.orientation=function(e){return arguments.length?(o=e,S):o},S.orientationOrder=function(e){return arguments.length?(f=e,S):f},S.lossFunction=function(e){return arguments.length?(x=e===`default`?B:e===`logRatio`?ce:e,S):x},S}function H(e,t){return function(n){let r=this,i=e[n.sets[0]].radius||50,a=t(n)||``,o=a.split(/\s+/).reverse(),s=(a.length+o.length)/3,c=o.pop(),l=[c],u=0,d=1.1;r.textContent=null;let f=[];function p(e){let t=r.ownerDocument.createElementNS(r.namespaceURI,`tspan`);return t.textContent=e,f.push(t),r.append(t),t}let m=p(c);for(;c=o.pop(),c;){l.push(c);let e=l.join(` `);m.textContent=e,e.length>s&&m.getComputedTextLength()>i&&(l.pop(),m.textContent=l.join(` `),l=[c],m=p(c),u++)}let h=.35-u*d/2,g=r.getAttribute(`x`),_=r.getAttribute(`y`);f.forEach((e,t)=>{e.setAttribute(`x`,g),e.setAttribute(`y`,_),e.setAttribute(`dy`,`${h+t*d}em`)})}}function U(e,t,n){let r=t[0].radius-T(t[0],e);for(let n=1;n<t.length;++n){let i=t[n].radius-T(t[n],e);i<=r&&(r=i)}for(let t=0;t<n.length;++t){let i=T(n[t],e)-n[t].radius;i<=r&&(r=i)}return r}function ge(e,t,n){let r=[];for(let t of e)r.push({x:t.x,y:t.y}),r.push({x:t.x+t.radius/2,y:t.y}),r.push({x:t.x-t.radius/2,y:t.y}),r.push({x:t.x,y:t.y+t.radius/2}),r.push({x:t.x,y:t.y-t.radius/2});let i=r[0],a=U(r[0],e,t);for(let n=1;n<r.length;++n){let o=U(r[n],e,t);o>=a&&(i=r[n],a=o)}let o=I(n=>-1*U({x:n[0],y:n[1]},e,t),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,s={x:n?0:o[0],y:o[1]},c=!0;for(let t of e)if(T(s,t)>t.radius){c=!1;break}for(let e of t)if(T(s,e)<e.radius){c=!1;break}if(c)return s;if(e.length==1)return{x:e[0].x,y:e[0].y};let l={};return x(e,l),l.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:l.arcs.length==1?{x:l.arcs[0].circle.x,y:l.arcs[0].circle.y}:t.length?ge(e,[]):O(l.arcs.map(e=>e.p1))}function _e(e){let t={},n=Object.keys(e);for(let e of n)t[e]=[];for(let r=0;r<n.length;r++){let i=n[r],a=e[i];for(let o=r+1;o<n.length;++o){let r=n[o],s=e[r],c=T(a,s);c+s.radius<=a.radius+1e-10?t[r].push(i):c+a.radius<=s.radius+1e-10&&t[i].push(r)}}return t}function ve(e,t,n){let r={},i=_e(e);for(let a=0;a<t.length;++a){let o=t[a].sets,s={},c={};for(let e=0;e<o.length;++e){s[o[e]]=!0;let t=i[o[e]];for(let e=0;e<t.length;++e)c[t[e]]=!0}let l=[],u=[];for(let t in e)t in s?l.push(e[t]):t in c||u.push(e[t]);let d=ge(l,u,n);r[o]=d,d.disjoint&&t[a].size>0&&console.log(`WARNING: area `+o+` not represented on screen`)}return r}function ye(e,t,n){let r=[];return r.push(`
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-C7afl5rZ.js";import"./src-Bejbc0T8.js";import{H as t,K as n,U as r,a as i,b as a,c as o,et as s,f as c,nt as l,rt as u,tt as d,v as f,w as p,y as m}from"./chunk-WYO6CB5R-DDA9TMxs.js";import{C as h}from"./src-CvdYkko8.js";import{i as g}from"./chunk-ICXQ74PX-DWIJquJc.js";import{t as _}from"./chunk-VAUOI2AC-ql8j5-ta.js";import{t as v}from"./rough.esm-B1TTUqnd.js";var y=(e,t)=>l(e,`a`,-t),b=1e-10;function x(e,t){let n=C(e),r=n.filter(t=>S(t,e)),i=0,a=0,o=[];if(r.length>1){let t=O(r);for(let e=0;e<r.length;++e){let n=r[e];n.angle=Math.atan2(n.x-t.x,n.y-t.y)}r.sort((e,t)=>t.angle-e.angle);let n=r[r.length-1];for(let t=0;t<r.length;++t){let s=r[t];a+=(n.x+s.x)*(s.y-n.y);let c={x:(s.x+n.x)/2,y:(s.y+n.y)/2},l=null;for(let t=0;t<s.parentIndex.length;++t)if(n.parentIndex.includes(s.parentIndex[t])){let r=e[s.parentIndex[t]],i=Math.atan2(s.x-r.x,s.y-r.y),a=Math.atan2(n.x-r.x,n.y-r.y),o=a-i;o<0&&(o+=2*Math.PI);let u=a-o/2,d=T(c,{x:r.x+r.radius*Math.sin(u),y:r.y+r.radius*Math.cos(u)});d>r.radius*2&&(d=r.radius*2),(l==null||l.width>d)&&(l={circle:r,width:d,p1:s,p2:n,large:d>r.radius,sweep:!0})}l!=null&&(o.push(l),i+=w(l.circle.radius,l.width),n=s)}}else{let t=e[0];for(let n=1;n<e.length;++n)e[n].radius<t.radius&&(t=e[n]);let n=!1;for(let r=0;r<e.length;++r)if(T(e[r],t)>Math.abs(t.radius-e[r].radius)){n=!0;break}n?i=a=0:(i=t.radius*t.radius*Math.PI,o.push({circle:t,p1:{x:t.x,y:t.y+t.radius},p2:{x:t.x-b,y:t.y+t.radius},width:t.radius*2,large:!0,sweep:!0}))}return a/=2,t&&(t.area=i+a,t.arcArea=i,t.polygonArea=a,t.arcs=o,t.innerPoints=r,t.intersectionPoints=n),i+a}function S(e,t){return t.every(t=>T(e,t)<t.radius+b)}function C(e){let t=[];for(let n=0;n<e.length;++n)for(let r=n+1;r<e.length;++r){let i=D(e[n],e[r]);for(let e of i)e.parentIndex=[n,r],t.push(e)}return t}function w(e,t){return e*e*Math.acos(1-t/e)-(e-t)*Math.sqrt(t*(2*e-t))}function T(e,t){return Math.sqrt((e.x-t.x)*(e.x-t.x)+(e.y-t.y)*(e.y-t.y))}function E(e,t,n){if(n>=e+t)return 0;if(n<=Math.abs(e-t))return Math.PI*Math.min(e,t)*Math.min(e,t);let r=e-(n*n-t*t+e*e)/(2*n),i=t-(n*n-e*e+t*t)/(2*n);return w(e,r)+w(t,i)}function D(e,t){let n=T(e,t),r=e.radius,i=t.radius;if(n>=r+i||n<=Math.abs(r-i))return[];let a=(r*r-i*i+n*n)/(2*n),o=Math.sqrt(r*r-a*a),s=e.x+a*(t.x-e.x)/n,c=e.y+a*(t.y-e.y)/n,l=-(t.y-e.y)*(o/n),u=-(t.x-e.x)*(o/n);return[{x:s+l,y:c-u},{x:s-l,y:c+u}]}function O(e){let t={x:0,y:0};for(let n of e)t.x+=n.x,t.y+=n.y;return t.x/=e.length,t.y/=e.length,t}function k(e,t,n,r){r||={};let i=r.maxIterations||100,a=r.tolerance||1e-10,o=e(t),s=e(n),c=n-t;if(o*s>0)throw`Initial bisect points must have opposite signs`;if(o===0)return t;if(s===0)return n;for(let n=0;n<i;++n){c/=2;let n=t+c,r=e(n);if(r*o>=0&&(t=n),Math.abs(c)<a||r===0)return n}return t+c}function A(e){let t=Array(e);for(let n=0;n<e;++n)t[n]=0;return t}function j(e,t){return A(e).map(()=>A(t))}function M(e,t){let n=0;for(let r=0;r<e.length;++r)n+=e[r]*t[r];return n}function N(e){return Math.sqrt(M(e,e))}function P(e,t,n){for(let r=0;r<t.length;++r)e[r]=t[r]*n}function F(e,t,n,r,i){for(let a=0;a<e.length;++a)e[a]=t*n[a]+r*i[a]}function I(e,t,n){n||={};let r=n.maxIterations||t.length*200,i=n.nonZeroDelta||1.05,a=n.zeroDelta||.001,o=n.minErrorDelta||1e-6,s=n.minErrorDelta||1e-5,c=n.rho===void 0?1:n.rho,l=n.chi===void 0?2:n.chi,u=n.psi===void 0?-.5:n.psi,d=n.sigma===void 0?.5:n.sigma,f,p=t.length,m=Array(p+1);m[0]=t,m[0].fx=e(t),m[0].id=0;for(let n=0;n<p;++n){let r=t.slice();r[n]=r[n]?r[n]*i:a,m[n+1]=r,m[n+1].fx=e(r),m[n+1].id=n+1}function h(e){for(let t=0;t<e.length;t++)m[p][t]=e[t];m[p].fx=e.fx}let g=(e,t)=>e.fx-t.fx,_=t.slice(),v=t.slice(),y=t.slice(),b=t.slice();for(let t=0;t<r;++t){if(m.sort(g),n.history){let e=m.map(e=>{let t=e.slice();return t.fx=e.fx,t.id=e.id,t});e.sort((e,t)=>e.id-t.id),n.history.push({x:m[0].slice(),fx:m[0].fx,simplex:e})}f=0;for(let e=0;e<p;++e)f=Math.max(f,Math.abs(m[0][e]-m[1][e]));if(Math.abs(m[0].fx-m[p].fx)<o&&f<s)break;for(let e=0;e<p;++e){_[e]=0;for(let t=0;t<p;++t)_[e]+=m[t][e];_[e]/=p}let t=m[p];if(F(v,1+c,_,-c,t),v.fx=e(v),v.fx<m[0].fx)F(b,1+l,_,-l,t),b.fx=e(b),b.fx<v.fx?h(b):h(v);else if(v.fx>=m[p-1].fx){let n=!1;if(v.fx>t.fx?(F(y,1+u,_,-u,t),y.fx=e(y),y.fx<t.fx?h(y):n=!0):(F(y,1-u*c,_,u*c,t),y.fx=e(y),y.fx<v.fx?h(y):n=!0),n){if(d>=1)break;for(let t=1;t<m.length;++t)F(m[t],1-d,m[0],d,m[t]),m[t].fx=e(m[t])}}else h(v)}return m.sort(g),{fx:m[0].fx,x:m[0]}}function L(e,t,n,r,i,a,o){let s=n.fx,c=M(n.fxprime,t),l=s,u=s,d=c,f=0;i||=1,a||=1e-6,o||=.1;function p(u,f,p){for(let m=0;m<16;++m)if(i=(u+f)/2,F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||l>=p)f=i;else{if(Math.abs(d)<=-o*c)return i;d*(f-u)>=0&&(f=u),u=i,p=l}return 0}for(let m=0;m<10;++m){if(F(r.x,1,n.x,i,t),l=r.fx=e(r.x,r.fxprime),d=M(r.fxprime,t),l>s+a*i*c||m&&l>=u)return p(f,i,u);if(Math.abs(d)<=-o*c)return i;if(d>=0)return p(i,f,l);u=l,f=i,i*=2}return i}function R(e,t,n){let r={x:t.slice(),fx:0,fxprime:t.slice()},i={x:t.slice(),fx:0,fxprime:t.slice()},a=t.slice(),o,s,c=1,l;n||={},l=n.maxIterations||t.length*20,r.fx=e(r.x,r.fxprime),o=r.fxprime.slice(),P(o,r.fxprime,-1);for(let t=0;t<l;++t){if(c=L(e,o,r,i,c),n.history&&n.history.push({x:r.x.slice(),fx:r.fx,fxprime:r.fxprime.slice(),alpha:c}),!c)P(o,r.fxprime,-1);else{F(a,1,i.fxprime,-1,r.fxprime);let e=M(r.fxprime,r.fxprime),t=Math.max(0,M(a,i.fxprime)/e);F(o,t,o,-1,i.fxprime),s=r,r=i,i=s}if(N(r.fxprime)<=1e-5)break}return n.history&&n.history.push({x:r.x.slice(),fx:r.fx,fxprime:r.fxprime.slice(),alpha:c}),r}function ee(e,t={}){t.maxIterations=t.maxIterations||500;let n=t.initialLayout||ae,r=t.lossFunction||B,i=ne(e,t),a=n(i,t),o=Object.keys(a),s=[];for(let e of o)s.push(a[e].x),s.push(a[e].y);let c=I(e=>{let t={};for(let n=0;n<o.length;++n){let r=o[n];t[r]={x:e[2*n],y:e[2*n+1],radius:a[r].radius}}return r(t,i)},s,t).x;for(let e=0;e<o.length;++e){let t=o[e];a[t].x=c[2*e],a[t].y=c[2*e+1]}return a}var te=1e-10;function z(e,t,n){return Math.min(e,t)*Math.min(e,t)*Math.PI<=n+te?Math.abs(e-t):k(r=>E(e,t,r)-n,0,e+t)}function ne(e,t={}){let n=t.distinct,r=e.map(e=>Object.assign({},e));function i(e){return e.join(`;`)}if(n){let e=new Map;for(let t of r)for(let n=0;n<t.sets.length;n++){let r=String(t.sets[n]);e.set(r,t.size+(e.get(r)||0));for(let i=n+1;i<t.sets.length;i++){let n=String(t.sets[i]),a=`${r};${n}`,o=`${n};${r}`;e.set(a,t.size+(e.get(a)||0)),e.set(o,t.size+(e.get(o)||0))}}for(let t of r)t.sets.length<3&&(t.size=e.get(i(t.sets)))}let a=[],o=new Set;for(let e of r)if(e.sets.length===1)a.push(e.sets[0]);else if(e.sets.length===2){let t=e.sets[0],n=e.sets[1];o.add(i(e.sets)),o.add(i([n,t]))}a.sort((e,t)=>e===t?0:e<t?-1:1);for(let e=0;e<a.length;++e){let t=a[e];for(let n=e+1;n<a.length;++n){let e=a[n];o.has(i([t,e]))||r.push({sets:[t,e],size:0})}}return r}function re(e,t,n){let r=j(t.length,t.length),i=j(t.length,t.length);return e.filter(e=>e.sets.length===2).forEach(e=>{let a=n[e.sets[0]],o=n[e.sets[1]],s=z(Math.sqrt(t[a].size/Math.PI),Math.sqrt(t[o].size/Math.PI),e.size);r[a][o]=r[o][a]=s;let c=0;e.size+1e-10>=Math.min(t[a].size,t[o].size)?c=1:e.size<=1e-10&&(c=-1),i[a][o]=i[o][a]=c}),{distances:r,constraints:i}}function ie(e,t,n,r){for(let e=0;e<t.length;++e)t[e]=0;let i=0;for(let a=0;a<n.length;++a){let o=e[2*a],s=e[2*a+1];for(let c=a+1;c<n.length;++c){let l=e[2*c],u=e[2*c+1],d=n[a][c],f=r[a][c],p=(l-o)*(l-o)+(u-s)*(u-s),m=Math.sqrt(p),h=p-d*d;f>0&&m<=d||f<0&&m>=d||(i+=2*h*h,t[2*a]+=4*h*(o-l),t[2*a+1]+=4*h*(s-u),t[2*c]+=4*h*(l-o),t[2*c+1]+=4*h*(u-s))}}return i}function ae(e,t={}){let n=se(e,t),r=t.lossFunction||B;if(e.length>=8){let i=oe(e,t),a=r(i,e),o=r(n,e);a+1e-8<o&&(n=i)}return n}function oe(e,t={}){let n=t.restarts||10,r=[],i={};for(let t of e)t.sets.length===1&&(i[t.sets[0]]=r.length,r.push(t));let{distances:a,constraints:o}=re(e,r,i),s=N(a.map(N))/a.length;a=a.map(e=>e.map(e=>e/s));let c=(e,t)=>ie(e,t,a,o),l=null;for(let e=0;e<n;++e){let e=R(c,A(a.length*2).map(Math.random),t);(!l||e.fx<l.fx)&&(l=e)}let u=l.x,d={};for(let e=0;e<r.length;++e){let t=r[e];d[t.sets[0]]={x:u[2*e]*s,y:u[2*e+1]*s,radius:Math.sqrt(t.size/Math.PI)}}if(t.history)for(let e of t.history)P(e.x,s);return d}function se(e,t){let n=t&&t.lossFunction?t.lossFunction:B,r={},i={};for(let t of e)if(t.sets.length===1){let e=t.sets[0];r[e]={x:1e10,y:1e10,rowid:r.length,size:t.size,radius:Math.sqrt(t.size/Math.PI)},i[e]=[]}e=e.filter(e=>e.sets.length===2);for(let t of e){let e=t.weight==null?1:t.weight,n=t.sets[0],a=t.sets[1];t.size+te>=Math.min(r[n].size,r[a].size)&&(e=0),i[n].push({set:a,size:t.size,weight:e}),i[a].push({set:n,size:t.size,weight:e})}let a=[];Object.keys(i).forEach(e=>{let t=0;for(let n=0;n<i[e].length;++n)t+=i[e][n].size*i[e][n].weight;a.push({set:e,size:t})});function o(e,t){return t.size-e.size}a.sort(o);let s={};function c(e){return e.set in s}function l(e,t){r[t].x=e.x,r[t].y=e.y,s[t]=!0}l({x:0,y:0},a[0].set);for(let t=1;t<a.length;++t){let s=a[t].set,d=i[s].filter(c),f=r[s];if(d.sort(o),d.length===0)throw`ERROR: missing pairwise overlap information`;let p=[];for(var u=0;u<d.length;++u){let e=r[d[u].set],t=z(f.radius,e.radius,d[u].size);p.push({x:e.x+t,y:e.y}),p.push({x:e.x-t,y:e.y}),p.push({y:e.y+t,x:e.x}),p.push({y:e.y-t,x:e.x});for(let n=u+1;n<d.length;++n){let i=r[d[n].set],a=z(f.radius,i.radius,d[n].size),o=D({x:e.x,y:e.y,radius:t},{x:i.x,y:i.y,radius:a});p.push(...o)}}let m=1e50,h=p[0];for(let t of p){r[s].x=t.x,r[s].y=t.y;let i=n(r,e);i<m&&(m=i,h=t)}l(h,s)}return r}function B(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight;n+=i*(t-r.size)*(t-r.size)}return n}function ce(e,t){let n=0;for(let r of t){if(r.sets.length===1)continue;let t;if(r.sets.length===2){let n=e[r.sets[0]],i=e[r.sets[1]];t=E(n.radius,i.radius,T(n,i))}else t=x(r.sets.map(t=>e[t]));let i=r.weight==null?1:r.weight,a=Math.log((t+1)/(r.size+1));n+=i*a*a}return n}function le(e,t,n){if(n==null?e.sort((e,t)=>t.radius-e.radius):e.sort(n),e.length>0){let t=e[0].x,n=e[0].y;for(let r of e)r.x-=t,r.y-=n}if(e.length===2&&T(e[0],e[1])<Math.abs(e[1].radius-e[0].radius)&&(e[1].x=e[0].x+e[0].radius-e[1].radius-1e-10,e[1].y=e[0].y),e.length>1){let n=Math.atan2(e[1].x,e[1].y)-t,r=Math.cos(n),i=Math.sin(n);for(let t of e){let e=t.x,n=t.y;t.x=r*e-i*n,t.y=i*e+r*n}}if(e.length>2){let n=Math.atan2(e[2].x,e[2].y)-t;for(;n<0;)n+=2*Math.PI;for(;n>2*Math.PI;)n-=2*Math.PI;if(n>Math.PI){let t=e[1].y/(1e-10+e[1].x);for(let n of e){var r=(n.x+t*n.y)/(1+t*t);n.x=2*r-n.x,n.y=2*r*t-n.y}}}}function ue(e){e.forEach(e=>{e.parent=e});function t(e){return e.parent!==e&&(e.parent=t(e.parent)),e.parent}function n(e,n){let r=t(e);r.parent=t(n)}for(let t=0;t<e.length;++t)for(let r=t+1;r<e.length;++r){let i=e[t].radius+e[r].radius;T(e[t],e[r])+1e-10<i&&n(e[r],e[t])}let r=new Map;for(let n=0;n<e.length;++n){let i=t(e[n]).parent.setid;r.has(i)||r.set(i,[]),r.get(i).push(e[n])}return e.forEach(e=>{delete e.parent}),Array.from(r.values())}function V(e){let t=t=>({max:e.reduce((e,n)=>Math.max(e,n[t]+n.radius),-1/0),min:e.reduce((e,n)=>Math.min(e,n[t]-n.radius),1/0)});return{xRange:t(`x`),yRange:t(`y`)}}function de(e,t,n){t??=Math.PI/2;let r=me(e).map(e=>Object.assign({},e)),i=ue(r);for(let e of i){le(e,t,n);let r=V(e);e.size=(r.xRange.max-r.xRange.min)*(r.yRange.max-r.yRange.min),e.bounds=r}i.sort((e,t)=>t.size-e.size),r=i[0];let a=r.bounds,o=(a.xRange.max-a.xRange.min)/50;function s(e,t,n){if(!e)return;let i=e.bounds,s,c;if(t)s=a.xRange.max-i.xRange.min+o;else{s=a.xRange.max-i.xRange.max;let e=(i.xRange.max-i.xRange.min)/2-(a.xRange.max-a.xRange.min)/2;e<0&&(s+=e)}if(n)c=a.yRange.max-i.yRange.min+o;else{c=a.yRange.max-i.yRange.max;let e=(i.yRange.max-i.yRange.min)/2-(a.yRange.max-a.yRange.min)/2;e<0&&(c+=e)}for(let t of e)t.x+=s,t.y+=c,r.push(t)}let c=1;for(;c<i.length;)s(i[c],!0,!1),s(i[c+1],!1,!0),s(i[c+2],!0,!0),c+=3,a=V(r);return pe(r)}function fe(e,t,n,r,i){let a=me(e);t-=2*r,n-=2*r;let{xRange:o,yRange:s}=V(a);if(o.max===o.min||s.max===s.min)return console.log(`not scaling solution: zero size detected`),e;let c,l;if(i){let e=Math.sqrt(i/Math.PI)*2;c=t/e,l=n/e}else c=t/(o.max-o.min),l=n/(s.max-s.min);let u=Math.min(l,c),d=(t-(o.max-o.min)*u)/2,f=(n-(s.max-s.min)*u)/2;return pe(a.map(e=>({radius:u*e.radius,x:r+d+(e.x-o.min)*u,y:r+f+(e.y-s.min)*u,setid:e.setid})))}function pe(e){let t={};for(let n of e)t[n.setid]=n;return t}function me(e){return Object.keys(e).map(t=>Object.assign(e[t],{setid:t}))}function he(e={}){let t=!1,n=600,r=350,i=15,a=1e3,o=Math.PI/2,s=!0,c=null,l=!0,u=!0,d=null,f=null,p=!1,m=null,h=e&&e.symmetricalTextCentre?e.symmetricalTextCentre:!1,g={},_=e&&e.colourScheme?e.colourScheme:e&&e.colorScheme?e.colorScheme:[`#1f77b4`,`#ff7f0e`,`#2ca02c`,`#d62728`,`#9467bd`,`#8c564b`,`#e377c2`,`#7f7f7f`,`#bcbd22`,`#17becf`],v=0,y=function(e){if(e in g)return g[e];var t=g[e]=_[v];return v+=1,v>=_.length&&(v=0),t},b=ee,x=B;function S(g){let _=g.datum(),v=new Set;_.forEach(e=>{e.size==0&&e.sets.length==1&&v.add(e.sets[0])}),_=_.filter(e=>!e.sets.some(e=>v.has(e)));let S={},C={};if(_.length>0){let e=b(_,{lossFunction:x,distinct:p});s&&(e=de(e,o,f)),S=fe(e,n,r,i,c),C=ve(S,_,h)}let w={};_.forEach(e=>{e.label&&(w[e.sets]=e.label)});function T(e){if(e.sets in w)return w[e.sets];if(e.sets.length==1)return``+e.sets[0]}g.selectAll(`svg`).data([S]).enter().append(`svg`);let E=g.select(`svg`);t?E.attr(`viewBox`,`0 0 ${n} ${r}`):E.attr(`width`,n).attr(`height`,r);let D={},O=!1;E.selectAll(`.venn-area path`).each(function(e){let t=this.getAttribute(`d`);e.sets.length==1&&t&&!p&&(O=!0,D[e.sets[0]]=be(t))});function k(e){return t=>Ce(e.sets.map(e=>{let i=D[e],a=S[e];return i||={x:n/2,y:r/2,radius:1},a||={x:n/2,y:r/2,radius:1},{x:i.x*(1-t)+a.x*t,y:i.y*(1-t)+a.y*t,radius:i.radius*(1-t)+a.radius*t}}),m)}let A=E.selectAll(`.venn-area`).data(_,e=>e.sets),j=A.enter().append(`g`).attr(`class`,e=>`venn-area venn-${e.sets.length==1?`circle`:`intersection`}${e.colour||e.color?` venn-coloured`:``}`).attr(`data-venn-sets`,e=>e.sets.join(`_`)),M=j.append(`path`),N=j.append(`text`).attr(`class`,`label`).text(e=>T(e)).attr(`text-anchor`,`middle`).attr(`dy`,`.35em`).attr(`x`,n/2).attr(`y`,r/2);u&&(M.style(`fill-opacity`,`0`).filter(e=>e.sets.length==1).style(`fill`,e=>e.colour?e.colour:e.color?e.color:y(e.sets)).style(`fill-opacity`,`.25`),N.style(`fill`,t=>t.colour||t.color?`#FFF`:e.textFill?e.textFill:t.sets.length==1?y(t.sets):`#444`));function P(e){return typeof e.transition==`function`?e.transition(`venn`).duration(a):e}let F=g;O&&typeof F.transition==`function`?(F=P(g),F.selectAll(`path`).attrTween(`d`,k)):F.selectAll(`path`).attr(`d`,e=>Ce(e.sets.map(e=>S[e])),m);let I=F.selectAll(`text`).filter(e=>e.sets in C).text(e=>T(e)).attr(`x`,e=>Math.floor(C[e.sets].x)).attr(`y`,e=>Math.floor(C[e.sets].y));l&&(O?`on`in I?I.on(`end`,H(S,T)):I.each(`end`,H(S,T)):I.each(H(S,T)));let L=P(A.exit()).remove();typeof A.transition==`function`&&L.selectAll(`path`).attrTween(`d`,k);let R=L.selectAll(`text`).attr(`x`,n/2).attr(`y`,r/2);return d!==null&&(N.style(`font-size`,`0px`),I.style(`font-size`,d),R.style(`font-size`,`0px`)),{circles:S,textCentres:C,nodes:A,enter:j,update:F,exit:L}}return S.wrap=function(e){return arguments.length?(l=e,S):l},S.useViewBox=function(){return t=!0,S},S.width=function(e){return arguments.length?(n=e,S):n},S.height=function(e){return arguments.length?(r=e,S):r},S.padding=function(e){return arguments.length?(i=e,S):i},S.distinct=function(e){return arguments.length?(p=e,S):p},S.colours=function(e){return arguments.length?(y=e,S):y},S.colors=function(e){return arguments.length?(y=e,S):y},S.fontSize=function(e){return arguments.length?(d=e,S):d},S.round=function(e){return arguments.length?(m=e,S):m},S.duration=function(e){return arguments.length?(a=e,S):a},S.layoutFunction=function(e){return arguments.length?(b=e,S):b},S.normalize=function(e){return arguments.length?(s=e,S):s},S.scaleToFit=function(e){return arguments.length?(c=e,S):c},S.styled=function(e){return arguments.length?(u=e,S):u},S.orientation=function(e){return arguments.length?(o=e,S):o},S.orientationOrder=function(e){return arguments.length?(f=e,S):f},S.lossFunction=function(e){return arguments.length?(x=e===`default`?B:e===`logRatio`?ce:e,S):x},S}function H(e,t){return function(n){let r=this,i=e[n.sets[0]].radius||50,a=t(n)||``,o=a.split(/\s+/).reverse(),s=(a.length+o.length)/3,c=o.pop(),l=[c],u=0,d=1.1;r.textContent=null;let f=[];function p(e){let t=r.ownerDocument.createElementNS(r.namespaceURI,`tspan`);return t.textContent=e,f.push(t),r.append(t),t}let m=p(c);for(;c=o.pop(),c;){l.push(c);let e=l.join(` `);m.textContent=e,e.length>s&&m.getComputedTextLength()>i&&(l.pop(),m.textContent=l.join(` `),l=[c],m=p(c),u++)}let h=.35-u*d/2,g=r.getAttribute(`x`),_=r.getAttribute(`y`);f.forEach((e,t)=>{e.setAttribute(`x`,g),e.setAttribute(`y`,_),e.setAttribute(`dy`,`${h+t*d}em`)})}}function U(e,t,n){let r=t[0].radius-T(t[0],e);for(let n=1;n<t.length;++n){let i=t[n].radius-T(t[n],e);i<=r&&(r=i)}for(let t=0;t<n.length;++t){let i=T(n[t],e)-n[t].radius;i<=r&&(r=i)}return r}function ge(e,t,n){let r=[];for(let t of e)r.push({x:t.x,y:t.y}),r.push({x:t.x+t.radius/2,y:t.y}),r.push({x:t.x-t.radius/2,y:t.y}),r.push({x:t.x,y:t.y+t.radius/2}),r.push({x:t.x,y:t.y-t.radius/2});let i=r[0],a=U(r[0],e,t);for(let n=1;n<r.length;++n){let o=U(r[n],e,t);o>=a&&(i=r[n],a=o)}let o=I(n=>-1*U({x:n[0],y:n[1]},e,t),[i.x,i.y],{maxIterations:500,minErrorDelta:1e-10}).x,s={x:n?0:o[0],y:o[1]},c=!0;for(let t of e)if(T(s,t)>t.radius){c=!1;break}for(let e of t)if(T(s,e)<e.radius){c=!1;break}if(c)return s;if(e.length==1)return{x:e[0].x,y:e[0].y};let l={};return x(e,l),l.arcs.length===0?{x:0,y:-1e3,disjoint:!0}:l.arcs.length==1?{x:l.arcs[0].circle.x,y:l.arcs[0].circle.y}:t.length?ge(e,[]):O(l.arcs.map(e=>e.p1))}function _e(e){let t={},n=Object.keys(e);for(let e of n)t[e]=[];for(let r=0;r<n.length;r++){let i=n[r],a=e[i];for(let o=r+1;o<n.length;++o){let r=n[o],s=e[r],c=T(a,s);c+s.radius<=a.radius+1e-10?t[r].push(i):c+a.radius<=s.radius+1e-10&&t[i].push(r)}}return t}function ve(e,t,n){let r={},i=_e(e);for(let a=0;a<t.length;++a){let o=t[a].sets,s={},c={};for(let e=0;e<o.length;++e){s[o[e]]=!0;let t=i[o[e]];for(let e=0;e<t.length;++e)c[t[e]]=!0}let l=[],u=[];for(let t in e)t in s?l.push(e[t]):t in c||u.push(e[t]);let d=ge(l,u,n);r[o]=d,d.disjoint&&t[a].size>0&&console.log(`WARNING: area `+o+` not represented on screen`)}return r}function ye(e,t,n){let r=[];return r.push(`
|
|
2
2
|
M`,e,t),r.push(`
|
|
3
3
|
m`,-n,0),r.push(`
|
|
4
4
|
a`,n,n,0,1,0,n*2,0),r.push(`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./chunk-KEIR6QF5-kMpbALDh.js";import{n as e}from"./chunk-5FCAYU7R-BfGI-oMu.js";export{e as createWardleyServices};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e}from"./chunk-Y2CYZVJY-
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-C7afl5rZ.js";import{t}from"./src-Bejbc0T8.js";import{D as n,H as r,K as i,U as a,a as o,b as s,c,v as l,w as u,x as d,y as f}from"./chunk-WYO6CB5R-DDA9TMxs.js";import{i as p}from"./chunk-ICXQ74PX-DWIJquJc.js";import{t as m}from"./chunk-VAUOI2AC-ql8j5-ta.js";import{t as h}from"./chunk-JWPE2WC7-DdwvzMEp.js";import{n as g}from"./mermaid-parser.core-Dd1-Tdhf.js";var _=e((e,t)=>{let n=e<=1?e*100:e;if(n<0||n>100)throw Error(`${t} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${e}`);return n},`toPercent`),v=e((e,t,n)=>({x:_(t,`${n} evolution`),y:_(e,`${n} visibility`)}),`toCoordinates`),y=e(e=>{if(e){if(e===`+<>`)return`bidirectional`;if(e===`+<`)return`backward`;if(e===`+>`)return`forward`}},`getFlowFromPort`),b=e(e=>{if(!e?.startsWith(`+`))return{};let t=/^\+'([^']*)'/.exec(e)?.[1];return e.includes(`<>`)?{flow:`bidirectional`,label:t}:e.includes(`<`)?{flow:`backward`,label:t}:e.includes(`>`)?{flow:`forward`,label:t}:{label:t}},`extractFlowFromArrow`),x=e((e,t)=>{if(h(e,t),e.size&&t.setSize(e.size.width,e.size.height),e.evolution){let n=e.evolution.stages.map(e=>e.secondName?`${e.name.trim()} / ${e.secondName.trim()}`:e.name.trim()),r=e.evolution.stages.filter(e=>e.boundary!==void 0).map(e=>e.boundary);t.updateAxes({stages:n,stageBoundaries:r})}if(e.anchors.forEach(e=>{let n=v(e.visibility,e.evolution,`Anchor "${e.name}"`);t.addNode(e.name,e.name,n.x,n.y,`anchor`)}),e.components.forEach(e=>{let n=v(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,i=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,a=e.decorator?.strategy;t.addNode(e.name,e.name,n.x,n.y,`component`,r,i,e.inertia,a)}),e.notes.forEach(e=>{let n=v(e.visibility,e.evolution,`Note "${e.text}"`);t.addNote(e.text,n.x,n.y)}),e.pipelines.forEach(e=>{let n=t.getNode(e.parent);if(!n||typeof n.y!=`number`)throw Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);let r=n.y;t.startPipeline(e.parent),e.components.forEach(n=>{let i=`${e.parent}_${n.name}`,a=n.label?(n.label.negX?-1:1)*n.label.offsetX:void 0,o=n.label?(n.label.negY?-1:1)*n.label.offsetY:void 0,s=_(n.evolution,`Pipeline component "${n.name}" evolution`);t.addNode(i,n.name,s,r,`pipeline-component`,a,o),t.addPipelineComponent(e.parent,i)})}),e.links.forEach(e=>{let n=!!e.arrow&&(e.arrow.includes(`-.->`)||e.arrow.includes(`.-.`)),r=y(e.fromPort)??y(e.toPort),{flow:i,label:a}=b(e.arrow);!r&&i&&(r=i);let o=e.linkLabel,s=a??o;t.addLink(t.resolveNodeId(e.from),t.resolveNodeId(e.to),n,s,r)}),e.evolves.forEach(e=>{let n=t.getNode(e.component);if(n?.y!==void 0){let r=_(e.target,`Evolve target for "${e.component}"`);t.addTrend(e.component,r,n.y)}}),e.annotations.length>0){let n=e.annotations[0],r=v(n.x,n.y,`Annotations box`);t.setAnnotationsBox(r.x,r.y)}e.annotation.forEach(e=>{let n=v(e.x,e.y,`Annotation ${e.number}`);t.addAnnotation(e.number,[{x:n.x,y:n.y}],e.text)}),e.accelerators.forEach(e=>{let n=v(e.x,e.y,`Accelerator "${e.name}"`);t.addAccelerator(e.name,n.x,n.y)}),e.deaccelerators.forEach(e=>{let n=v(e.x,e.y,`Deaccelerator "${e.name}"`);t.addDeaccelerator(e.name,n.x,n.y)})},`populateDb`),S={parser:{yy:void 0},parse:e(async e=>{let n=await g(`wardley`,e);t.debug(n);let r=S.parser?.yy;if(!r||typeof r.addNode!=`function`)throw Error(`parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.`);x(n,r)},`parse`)},C=new class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}static{e(this,`WardleyBuilder`)}addNode(e){let t=this.nodes.get(e.id)??{id:e.id,label:e.label},n={...t,...e,className:e.className??t.className,labelOffsetX:e.labelOffsetX??t.labelOffsetX,labelOffsetY:e.labelOffsetY??t.labelOffsetY};this.nodes.set(e.id,n)}addLink(e){this.links.push(e)}addTrend(e){this.trends.set(e.nodeId,e)}startPipeline(e){this.pipelines.set(e,{nodeId:e,componentIds:[]});let t=this.nodes.get(e);t&&(t.isPipelineParent=!0)}addPipelineComponent(e,t){let n=this.pipelines.get(e);n&&n.componentIds.push(t);let r=this.nodes.get(t);r&&(r.inPipeline=!0)}addAnnotation(e){this.annotations.push(e)}addNote(e){this.notes.push(e)}addAccelerator(e){this.accelerators.push(e)}addDeaccelerator(e){this.deaccelerators.push(e)}setAnnotationsBox(e,t){this.annotationsBox={x:e,y:t}}setAxes(e){this.axes={...this.axes,...e}}setSize(e,t){this.size={width:e,height:t}}getNode(e){return this.nodes.get(e)}resolveNodeId(e){if(this.nodes.has(e))return e;for(let[t,n]of this.nodes)if(n.label===e)return t;return e}build(){let e=[];for(let t of this.nodes.values()){if(typeof t.x!=`number`||typeof t.y!=`number`)throw Error(`Node "${t.label}" is missing coordinates`);e.push(t)}return{nodes:e,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}};function w(){return d()[`wardley-beta`]}e(w,`getConfig`);function T(e,t,n,r,i,a,o,s,c){C.addNode({id:e,label:t,x:n,y:r,className:i,labelOffsetX:a,labelOffsetY:o,inertia:s,sourceStrategy:c})}e(T,`addNode`);function E(e,t,n=!1,r,i){C.addLink({source:e,target:t,dashed:n,label:r,flow:i})}e(E,`addLink`);function D(e,t,n){C.addTrend({nodeId:e,targetX:t,targetY:n})}e(D,`addTrend`);function O(e,t,n){C.addAnnotation({number:e,coordinates:t,text:n})}e(O,`addAnnotation`);function k(e,t,n){C.addNote({text:e,x:t,y:n})}e(k,`addNote`);function A(e,t,n){C.addAccelerator({name:e,x:t,y:n})}e(A,`addAccelerator`);function j(e,t,n){C.addDeaccelerator({name:e,x:t,y:n})}e(j,`addDeaccelerator`);function M(e,t){C.setAnnotationsBox(e,t)}e(M,`setAnnotationsBox`);function N(e,t){C.setSize(e,t)}e(N,`setSize`);function P(e){C.startPipeline(e)}e(P,`startPipeline`);function F(e,t){C.addPipelineComponent(e,t)}e(F,`addPipelineComponent`);function I(e){C.setAxes(e)}e(I,`updateAxes`);function L(e){return C.getNode(e)}e(L,`getNode`);function R(e){return C.resolveNodeId(e)}e(R,`resolveNodeId`);function z(){return C.build()}e(z,`getWardleyData`);function B(){C.clear(),o()}e(B,`clear`);var V={getConfig:w,addNode:T,addLink:E,addTrend:D,addAnnotation:O,addNote:k,addAccelerator:A,addDeaccelerator:j,setAnnotationsBox:M,setSize:N,startPipeline:P,addPipelineComponent:F,updateAxes:I,getNode:L,resolveNodeId:R,getWardleyData:z,clear:B,setAccTitle:a,getAccTitle:f,setDiagramTitle:i,getDiagramTitle:u,getAccDescription:l,setAccDescription:r},H=[`Genesis`,`Custom Built`,`Product`,`Commodity`],U=e(()=>{let{themeVariables:e}=d();return{backgroundColor:e.wardley?.backgroundColor??e.background??`#fff`,axisColor:e.wardley?.axisColor??`#000`,axisTextColor:e.wardley?.axisTextColor??e.primaryTextColor??`#222`,gridColor:e.wardley?.gridColor??`rgba(100, 100, 100, 0.2)`,componentFill:e.wardley?.componentFill??`#fff`,componentStroke:e.wardley?.componentStroke??`#000`,componentLabelColor:e.wardley?.componentLabelColor??e.primaryTextColor??`#222`,linkStroke:e.wardley?.linkStroke??`#000`,evolutionStroke:e.wardley?.evolutionStroke??`#dc3545`,annotationStroke:e.wardley?.annotationStroke??`#000`,annotationTextColor:e.wardley?.annotationTextColor??e.primaryTextColor??`#222`,annotationFill:e.wardley?.annotationFill??e.background??`#fff`}},`getTheme`),W=e(()=>{let e=d()[`wardley-beta`];return{width:e?.width??900,height:e?.height??600,padding:e?.padding??48,nodeRadius:e?.nodeRadius??6,nodeLabelOffset:e?.nodeLabelOffset??8,axisFontSize:e?.axisFontSize??12,labelFontSize:e?.labelFontSize??10,showGrid:e?.showGrid??!1,useMaxWidth:e?.useMaxWidth??!0}},`getConfigValues`),G={parser:S,db:V,renderer:{draw:e((n,r,i,a)=>{t.debug(`Rendering Wardley map
|
|
2
2
|
`+n);let o=W(),s=U(),l=o.nodeRadius*1.6,u=a.db,d=u.getWardleyData(),f=u.getDiagramTitle(),p=d.size?.width??o.width,h=d.size?.height??o.height,g=m(r);g.selectAll(`*`).remove(),c(g,h,p,o.useMaxWidth),g.attr(`viewBox`,`0 0 ${p} ${h}`);let _=g.append(`g`).attr(`class`,`wardley-map`),v=g.append(`defs`);v.append(`marker`).attr(`id`,`arrow-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,6).attr(`markerHeight`,6).attr(`orient`,`auto-start-reverse`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,s.evolutionStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-end-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,9).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 0 0 L 10 5 L 0 10 z`).attr(`fill`,s.linkStroke).attr(`stroke`,`none`),v.append(`marker`).attr(`id`,`link-arrow-start-${r}`).attr(`viewBox`,`0 0 10 10`).attr(`refX`,1).attr(`refY`,5).attr(`markerWidth`,5).attr(`markerHeight`,5).attr(`orient`,`auto`).append(`path`).attr(`d`,`M 10 0 L 0 5 L 10 10 z`).attr(`fill`,s.linkStroke).attr(`stroke`,`none`),_.append(`rect`).attr(`class`,`wardley-background`).attr(`width`,p).attr(`height`,h).attr(`fill`,s.backgroundColor);let y=p-o.padding*2,b=h-o.padding*2;f&&_.append(`text`).attr(`class`,`wardley-title`).attr(`x`,p/2).attr(`y`,o.padding/2).attr(`fill`,s.axisTextColor).attr(`font-size`,o.axisFontSize*1.05).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).text(f);let x=e(e=>o.padding+e/100*y,`projectX`),S=e(e=>h-o.padding-e/100*b,`projectY`),C=_.append(`g`).attr(`class`,`wardley-axes`);C.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding).attr(`y2`,h-o.padding).attr(`stroke`,s.axisColor).attr(`stroke-width`,1),C.append(`line`).attr(`x1`,o.padding).attr(`x2`,o.padding).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,s.axisColor).attr(`stroke-width`,1);let w=d.axes.xLabel??`Evolution`,T=d.axes.yLabel??`Visibility`;C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-x`).attr(`x`,o.padding+y/2).attr(`y`,h-o.padding/4).attr(`fill`,s.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).text(w),C.append(`text`).attr(`class`,`wardley-axis-label wardley-axis-label-y`).attr(`x`,o.padding/3).attr(`y`,o.padding+b/2).attr(`fill`,s.axisTextColor).attr(`font-size`,o.axisFontSize).attr(`font-weight`,`bold`).attr(`text-anchor`,`middle`).attr(`transform`,`rotate(-90 ${o.padding/3} ${o.padding+b/2})`).text(T);let E=d.axes.stages&&d.axes.stages.length>0?d.axes.stages:H;if(E.length>0){let e=_.append(`g`).attr(`class`,`wardley-stages`),t=d.axes.stageBoundaries,n=[];if(t&&t.length===E.length){let e=0;t.forEach(t=>{n.push({start:e,end:t}),e=t})}else{let e=1/E.length;E.forEach((t,r)=>{n.push({start:r*e,end:(r+1)*e})})}E.forEach((t,r)=>{let i=n[r],a=o.padding+i.start*y,c=(a+(o.padding+i.end*y))/2;r>0&&e.append(`line`).attr(`x1`,a).attr(`x2`,a).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,`#000`).attr(`stroke-width`,1).attr(`stroke-dasharray`,`5 5`).attr(`opacity`,.8),e.append(`text`).attr(`class`,`wardley-stage-label`).attr(`x`,c).attr(`y`,h-o.padding/1.5).attr(`fill`,s.axisTextColor).attr(`font-size`,o.axisFontSize-2).attr(`text-anchor`,`middle`).text(t)})}if(o.showGrid){let e=_.append(`g`).attr(`class`,`wardley-grid`);for(let t=1;t<4;t++){let n=t/4,r=o.padding+y*n;e.append(`line`).attr(`x1`,r).attr(`x2`,r).attr(`y1`,o.padding).attr(`y2`,h-o.padding).attr(`stroke`,s.gridColor).attr(`stroke-dasharray`,`2 6`),e.append(`line`).attr(`x1`,o.padding).attr(`x2`,p-o.padding).attr(`y1`,h-o.padding-b*n).attr(`y2`,h-o.padding-b*n).attr(`stroke`,s.gridColor).attr(`stroke-dasharray`,`2 6`)}}let D=new Map;if(d.nodes.forEach(e=>{D.set(e.id,{x:x(e.x),y:S(e.y),node:e})}),d.pipelines.length>0){let e=_.append(`g`).attr(`class`,`wardley-pipelines`),t=_.append(`g`).attr(`class`,`wardley-pipeline-links`);d.pipelines.forEach(n=>{if(n.componentIds.length===0)return;let r=n.componentIds.map(e=>({id:e,pos:D.get(e),node:d.nodes.find(t=>t.id===e)})).filter(e=>e.pos&&e.node).sort((e,t)=>e.node.x-t.node.x);for(let e=0;e<r.length-1;e++){let n=r[e],i=r[e+1];t.append(`line`).attr(`class`,`wardley-pipeline-evolution-link`).attr(`x1`,n.pos.x).attr(`y1`,n.pos.y).attr(`x2`,i.pos.x).attr(`y2`,i.pos.y).attr(`stroke`,s.linkStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,`4 4`)}let i=1/0,a=-1/0,c=0;if(n.componentIds.forEach(e=>{let t=D.get(e);t&&(i=Math.min(i,t.x),a=Math.max(a,t.x),c=t.y)}),i!==1/0&&a!==-1/0){let t=o.nodeRadius*4,r=c-t/2,u=D.get(n.nodeId);u&&(u.x=(i+a)/2,u.y=r-l/6),e.append(`rect`).attr(`class`,`wardley-pipeline-box`).attr(`x`,i-15).attr(`y`,r).attr(`width`,a-i+30).attr(`height`,t).attr(`fill`,`none`).attr(`stroke`,s.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}})}let O=_.append(`g`).attr(`class`,`wardley-links`),k=new Map;d.pipelines.forEach(e=>{k.set(e.nodeId,new Set(e.componentIds))});let A=d.links.filter(e=>!(!D.has(e.source)||!D.has(e.target)||k.get(e.target)?.has(e.source)));O.selectAll(`line`).data(A).enter().append(`line`).attr(`class`,e=>`wardley-link${e.dashed?` wardley-link--dashed`:``}`).attr(`x1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.x+i/s*r}).attr(`y1`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.source).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=n.x-t.x,a=n.y-t.y,s=Math.sqrt(i*i+a*a);return t.y+a/s*r}).attr(`x2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.x+i/s*r}).attr(`y2`,e=>{let t=D.get(e.source),n=D.get(e.target),r=d.nodes.find(t=>t.id===e.target).isPipelineParent?l/Math.sqrt(2):o.nodeRadius,i=t.x-n.x,a=t.y-n.y,s=Math.sqrt(i*i+a*a);return n.y+a/s*r}).attr(`stroke`,s.linkStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,e=>e.dashed?`6 6`:null).attr(`marker-end`,e=>e.flow===`forward`||e.flow===`bidirectional`?`url(#link-arrow-end-${r})`:null).attr(`marker-start`,e=>e.flow===`backward`||e.flow===`bidirectional`?`url(#link-arrow-start-${r})`:null),O.selectAll(`text`).data(A.filter(e=>e.label)).enter().append(`text`).attr(`class`,`wardley-link-label`).attr(`x`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=n.y-t.y,a=n.x-t.x;return r+i/Math.sqrt(a*a+i*i)*8}).attr(`y`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.y+n.y)/2,i=n.x-t.x,a=n.y-t.y,o=Math.sqrt(i*i+a*a);return r+-i/o*8}).attr(`fill`,s.axisTextColor).attr(`font-size`,o.labelFontSize).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`middle`).attr(`transform`,e=>{let t=D.get(e.source),n=D.get(e.target),r=(t.x+n.x)/2,i=(t.y+n.y)/2,a=n.x-t.x,o=n.y-t.y,s=Math.sqrt(a*a+o*o),c=o/s,l=-a/s,u=r+c*8,d=i+l*8,f=Math.atan2(o,a)*180/Math.PI;return(f>90||f<-90)&&(f+=180),`rotate(${f} ${u} ${d})`}).text(e=>e.label);let j=_.append(`g`).attr(`class`,`wardley-trends`),M=d.trends.map(e=>{let t=D.get(e.nodeId);if(!t)return null;let n=x(e.targetX),r=S(e.targetY),i=n-t.x,a=r-t.y,s=Math.sqrt(i*i+a*a),c=o.nodeRadius+2;return{origin:t,targetX:n,targetY:r,adjustedX2:s>c?n-i/s*c:n,adjustedY2:s>c?r-a/s*c:r}}).filter(e=>e!==null);j.selectAll(`line`).data(M).enter().append(`line`).attr(`class`,`wardley-trend`).attr(`x1`,e=>e.origin.x).attr(`y1`,e=>e.origin.y).attr(`x2`,e=>e.adjustedX2).attr(`y2`,e=>e.adjustedY2).attr(`stroke`,s.evolutionStroke).attr(`stroke-width`,1).attr(`stroke-dasharray`,`4 4`).attr(`marker-end`,`url(#arrow-${r})`);let N=_.append(`g`).attr(`class`,`wardley-nodes`).selectAll(`g`).data(d.nodes).enter().append(`g`).attr(`class`,e=>[`wardley-node`,e.className?`wardley-node--${e.className}`:``].filter(Boolean).join(` `));N.filter(e=>e.sourceStrategy===`outsource`).append(`circle`).attr(`class`,`wardley-outsource-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#666`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`buy`).append(`circle`).attr(`class`,`wardley-buy-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#ccc`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.sourceStrategy===`build`).append(`circle`).attr(`class`,`wardley-build-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`#eee`).attr(`stroke`,`#000`).attr(`stroke-width`,1);let P=N.filter(e=>e.sourceStrategy===`market`);P.append(`circle`).attr(`class`,`wardley-market-overlay`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius*2).attr(`fill`,`white`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),N.filter(e=>!e.isPipelineParent&&e.sourceStrategy!==`market`&&e.className!==`anchor`).append(`circle`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y).attr(`r`,o.nodeRadius).attr(`fill`,s.componentFill).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1);let F=o.nodeRadius*.7,I=o.nodeRadius*1.2;if(P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x).attr(`y1`,e=>D.get(e.id).y-I).attr(`x2`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y2`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),P.append(`line`).attr(`class`,`wardley-market-line`).attr(`x1`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`y1`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`x2`,e=>D.get(e.id).x).attr(`y2`,e=>D.get(e.id).y-I).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x).attr(`cy`,e=>D.get(e.id).y-I).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x-I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,2),P.append(`circle`).attr(`class`,`wardley-market-dot`).attr(`cx`,e=>D.get(e.id).x+I*Math.cos(Math.PI/6)).attr(`cy`,e=>D.get(e.id).y+I*Math.sin(Math.PI/6)).attr(`r`,F).attr(`fill`,`white`).attr(`stroke`,s.componentStroke).attr(`stroke-width`,2),N.filter(e=>e.isPipelineParent===!0).append(`rect`).attr(`x`,e=>D.get(e.id).x-l/2).attr(`y`,e=>D.get(e.id).y-l/2).attr(`width`,l).attr(`height`,l).attr(`fill`,s.componentFill).attr(`stroke`,s.componentStroke).attr(`stroke-width`,1),N.filter(e=>e.inertia===!0).append(`line`).attr(`class`,`wardley-inertia`).attr(`x1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y1`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y-n/2}).attr(`x2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l/2+15:o.nodeRadius+15;return e.sourceStrategy&&(n+=o.nodeRadius+10),t.x+n}).attr(`y2`,e=>{let t=D.get(e.id),n=e.isPipelineParent?l:o.nodeRadius*2;return t.y+n/2}).attr(`stroke`,s.componentStroke).attr(`stroke-width`,6),N.append(`text`).attr(`x`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetX===void 0?t.x:t.x+e.labelOffsetX;let n=o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetX===void 0&&(n+=10);let r=e.labelOffsetX??n;return t.x+r}).attr(`y`,e=>{let t=D.get(e.id);if(e.className===`anchor`)return e.labelOffsetY===void 0?t.y-3:t.y+e.labelOffsetY;let n=-o.nodeLabelOffset;e.sourceStrategy&&e.labelOffsetY===void 0&&(n-=10);let r=e.labelOffsetY??n;return t.y+r}).attr(`class`,`wardley-node-label`).attr(`fill`,e=>e.className===`evolved`?s.evolutionStroke:e.className===`anchor`?`#000`:s.componentLabelColor).attr(`font-size`,o.labelFontSize).attr(`font-weight`,e=>e.className===`anchor`?`bold`:`normal`).attr(`text-anchor`,e=>e.className===`anchor`?`middle`:`start`).attr(`dominant-baseline`,e=>e.className===`anchor`?`middle`:`auto`).text(e=>e.label),d.annotations.length>0){let e=_.append(`g`).attr(`class`,`wardley-annotations`);if(d.annotations.forEach(t=>{let n=t.coordinates.map(e=>({x:x(e.x),y:S(e.y)}));if(n.length>1)for(let t=0;t<n.length-1;t++)e.append(`line`).attr(`class`,`wardley-annotation-line`).attr(`x1`,n[t].x).attr(`y1`,n[t].y).attr(`x2`,n[t+1].x).attr(`y2`,n[t+1].y).attr(`stroke`,s.axisColor).attr(`stroke-width`,1.5).attr(`stroke-dasharray`,`4 4`);n.forEach(n=>{let r=e.append(`g`).attr(`class`,`wardley-annotation`);r.append(`circle`).attr(`cx`,n.x).attr(`cy`,n.y).attr(`r`,10).attr(`fill`,`white`).attr(`stroke`,s.axisColor).attr(`stroke-width`,1.5),r.append(`text`).attr(`x`,n.x).attr(`y`,n.y).attr(`text-anchor`,`middle`).attr(`dominant-baseline`,`central`).attr(`font-size`,10).attr(`fill`,s.axisTextColor).attr(`font-weight`,`bold`).text(t.number)})}),d.annotationsBox){let t=x(d.annotationsBox.x),n=S(d.annotationsBox.y),r=e.append(`g`).attr(`class`,`wardley-annotations-box`),i=[...d.annotations].filter(e=>e.text).sort((e,t)=>e.number-t.number),a=[];if(i.forEach((e,i)=>{let o=r.append(`text`).attr(`x`,t+10).attr(`y`,n+10+(i+1)*16).attr(`font-size`,11).attr(`fill`,s.axisTextColor).attr(`text-anchor`,`start`).attr(`dominant-baseline`,`middle`).text(`${e.number}. ${e.text}`);a.push(o)}),a.length>0){let e=0,c=0;a.forEach(t=>{let n=t.node(),r=n.getComputedTextLength();e=Math.max(e,r);let i=n.getBBox();c=Math.max(c,i.height)});let l=e+20+105,u=i.length*16+20+c/2,d=o.padding,f=p-o.padding-l,m=o.padding,g=h-o.padding-u;t=Math.max(d,Math.min(t,f)),n=Math.max(m,Math.min(n,g)),a.forEach((e,r)=>{e.attr(`x`,t+10).attr(`y`,n+10+(r+1)*16)}),r.insert(`rect`,`text`).attr(`x`,t).attr(`y`,n).attr(`width`,l).attr(`height`,u).attr(`fill`,`white`).attr(`stroke`,s.axisColor).attr(`stroke-width`,1.5).attr(`rx`,4).attr(`ry`,4)}}}if(d.notes.length>0){let e=_.append(`g`).attr(`class`,`wardley-notes`);d.notes.forEach(t=>{let n=x(t.x),r=S(t.y);e.append(`text`).attr(`x`,n).attr(`y`,r).attr(`text-anchor`,`start`).attr(`font-size`,11).attr(`fill`,s.axisTextColor).attr(`font-weight`,`bold`).text(t.text)})}if(d.accelerators.length>0){let e=_.append(`g`).attr(`class`,`wardley-accelerators`);d.accelerators.forEach(t=>{let n=x(t.x),r=S(t.y),i=`
|
|
3
3
|
M ${n} ${r-30/2}
|
|
4
4
|
L ${n+60-20} ${r-30/2}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{i as e}from"./chunk-DseTPa7n.js";import{n as t}from"./compiler-runtime-DrcePeIl.js";import{r as n}from"./dist-CSDjUb5q.js";import{t as r}from"./createLucideIcon-Wgamzz8_.js";import{Tn as i}from"./dist-
|
|
1
|
+
import{i as e}from"./chunk-DseTPa7n.js";import{n as t}from"./compiler-runtime-DrcePeIl.js";import{r as n}from"./dist-CSDjUb5q.js";import{t as r}from"./createLucideIcon-Wgamzz8_.js";import{Tn as i}from"./dist-z6xoO_FO.js";var a=r(`copy-plus`,[[`line`,{x1:`15`,x2:`15`,y1:`12`,y2:`18`,key:`1p7wdc`}],[`line`,{x1:`12`,x2:`18`,y1:`15`,y2:`15`,key:`1nscbv`}],[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]),o=r(`pencil`,[[`path`,{d:`M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z`,key:`1a8usu`}],[`path`,{d:`m15 5 4 4`,key:`1mk7zo`}]]),s=r(`sparkles`,[[`path`,{d:`M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z`,key:`1s2grr`}],[`path`,{d:`M20 2v4`,key:`1rf3ol`}],[`path`,{d:`M22 4h-4`,key:`gwowj6`}],[`circle`,{cx:`4`,cy:`20`,r:`2`,key:`6kqj1y`}]]),c=[`global`,`project`];function l(e){return{project:new Set(e.filter(e=>e.scope===`project`).map(e=>e.name)),global:new Set(e.filter(e=>e.scope===`global`).map(e=>e.name))}}var u=`open-knowledge-pack-`;function d(e){return e.startsWith(u)?e.slice(20):e}function f(){let{_:e}=n();return{project:e({id:`e0NrBM`}),global:e({id:`2GT3Hf`})}}function p(){let{_:e}=n();return{project:e({id:`HyvSqq`}),global:e({id:`C7XjNB`})}}var m=e(t(),1);function h(){let[e]=(0,m.useState)(g);return e}function g(){return i()!=null}function _(e,t,n){let r=n===`\\`?t.replaceAll(`/`,`\\`):t;return`${e.endsWith(n)?e.slice(0,-1):e}${n}${r}`}var v=/\.(md|mdx)$/i;function y(e){return v.test(e)?e:`${e}.md`}export{d as a,p as c,a as d,c as i,s as l,_ as n,l as o,h as r,f as s,y as t,o as u};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e}from"./chunk-Y2CYZVJY-
|
|
1
|
+
import{n as e}from"./chunk-Y2CYZVJY-C7afl5rZ.js";import{t}from"./src-Bejbc0T8.js";import{D as n,H as r,K as i,U as a,a as o,b as s,c,f as l,v as u,w as d,y as f,z as p}from"./chunk-WYO6CB5R-DDA9TMxs.js";import{t as m}from"./linear-CWEI_5Iw.js";import{t as h}from"./ordinal-DqdsPg4w.js";import{t as g}from"./init-B2r4ykR3.js";import{i as _}from"./chunk-ICXQ74PX-DWIJquJc.js";import{t as v}from"./line-BSndhJaA.js";import{t as y}from"./chunk-VAUOI2AC-ql8j5-ta.js";import"./chunk-HOUHSVGY-3n2-KijJ.js";import{t as b}from"./chunk-Q4XR5HBZ-C3mWTH_s.js";function x(e,t,n){e=+e,t=+t,n=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+n;for(var r=-1,i=Math.max(0,Math.ceil((t-e)/n))|0,a=Array(i);++r<i;)a[r]=e+r*n;return a}function S(){var e=h().unknown(void 0),t=e.domain,n=e.range,r=0,i=1,a,o,s=!1,c=0,l=0,u=.5;delete e.unknown;function d(){var e=t().length,d=i<r,f=d?i:r,p=d?r:i;a=(p-f)/Math.max(1,e-c+l*2),s&&(a=Math.floor(a)),f+=(p-f-a*(e-c))*u,o=a*(1-c),s&&(f=Math.round(f),o=Math.round(o));var m=x(e).map(function(e){return f+a*e});return n(d?m.reverse():m)}return e.domain=function(e){return arguments.length?(t(e),d()):t()},e.range=function(e){return arguments.length?([r,i]=e,r=+r,i=+i,d()):[r,i]},e.rangeRound=function(e){return[r,i]=e,r=+r,i=+i,s=!0,d()},e.bandwidth=function(){return o},e.step=function(){return a},e.round=function(e){return arguments.length?(s=!!e,d()):s},e.padding=function(e){return arguments.length?(c=Math.min(1,l=+e),d()):c},e.paddingInner=function(e){return arguments.length?(c=Math.min(1,e),d()):c},e.paddingOuter=function(e){return arguments.length?(l=+e,d()):l},e.align=function(e){return arguments.length?(u=Math.max(0,Math.min(1,e)),d()):u},e.copy=function(){return S(t(),[r,i]).round(s).paddingInner(c).paddingOuter(l).align(u)},g.apply(d(),arguments)}var C=(function(){var t=e(function(e,t,n,r){for(n||={},r=e.length;r--;n[e[r]]=t);return n},`o`),n=[1,10,12,14,16,18,19,21,23],r=[2,6],i=[1,3],a=[1,5],o=[1,6],s=[1,7],c=[1,5,10,12,14,16,18,19,21,23,36,37,38],l=[1,25],u=[1,26],d=[1,28],f=[1,29],p=[1,30],m=[1,31],h=[1,32],g=[1,33],_=[1,34],v=[1,35],y=[1,36],b=[1,37],x=[1,43],S=[1,42],C=[1,47],w=[1,50],T=[1,10,12,14,16,18,19,21,23,36,37,38],E=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38],D=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38,42,43,44,45,46,47,48,49,50,51],O=[1,65],k=[26,28],A={trace:e(function(){},`trace`),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,dataPoints:25,SQUARE_BRACES_END:26,dataPoint:27,COMMA:28,NUMBER_WITH_DECIMAL:29,STR:30,xAxisData:31,bandData:32,ARROW_DELIMITER:33,commaSeparatedTexts:34,yAxisData:35,NEWLINE:36,SEMI:37,EOF:38,alphaNum:39,MD_STR:40,alphaNumToken:41,AMP:42,NUM:43,ALPHA:44,PLUS:45,EQUALS:46,MULT:47,DOT:48,BRKT:49,MINUS:50,UNDERSCORE:51,$accept:0,$end:1},terminals_:{2:`error`,5:`XYCHART`,8:`CHART_ORIENTATION`,10:`title`,12:`X_AXIS`,14:`Y_AXIS`,16:`LINE`,18:`BAR`,19:`acc_title`,20:`acc_title_value`,21:`acc_descr`,22:`acc_descr_value`,23:`acc_descr_multiline_value`,24:`SQUARE_BRACES_START`,26:`SQUARE_BRACES_END`,28:`COMMA`,29:`NUMBER_WITH_DECIMAL`,30:`STR`,33:`ARROW_DELIMITER`,36:`NEWLINE`,37:`SEMI`,38:`EOF`,40:`MD_STR`,42:`AMP`,43:`NUM`,44:`ALPHA`,45:`PLUS`,46:`EQUALS`,47:`MULT`,48:`DOT`,49:`BRKT`,50:`MINUS`,51:`UNDERSCORE`},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[27,2],[27,1],[13,1],[13,2],[13,1],[31,1],[31,3],[32,3],[34,3],[34,1],[15,1],[15,2],[15,1],[35,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[39,1],[39,2],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1]],performAction:e(function(e,t,n,r,i,a,o){var s=a.length-1;switch(i){case 5:r.setOrientation(a[s]);break;case 9:r.setDiagramTitle(a[s].text.trim());break;case 12:r.setLineData({text:``,type:`text`},a[s]);break;case 13:r.setLineData(a[s-1],a[s]);break;case 14:r.setBarData({text:``,type:`text`},a[s]);break;case 15:r.setBarData(a[s-1],a[s]);break;case 16:this.$=a[s].trim(),r.setAccTitle(this.$);break;case 17:case 18:this.$=a[s].trim(),r.setAccDescription(this.$);break;case 19:this.$=a[s-1];break;case 20:case 30:this.$=[a[s-2],...a[s]];break;case 21:case 31:this.$=[a[s]];break;case 22:this.$={value:Number(a[s-1]),label:a[s]};break;case 23:this.$={value:Number(a[s]),label:``};break;case 24:r.setXAxisTitle(a[s]);break;case 25:r.setXAxisTitle(a[s-1]);break;case 26:r.setXAxisTitle({type:`text`,text:``});break;case 27:r.setXAxisBand(a[s]);break;case 28:r.setXAxisRangeData(Number(a[s-2]),Number(a[s]));break;case 29:this.$=a[s-1];break;case 32:r.setYAxisTitle(a[s]);break;case 33:r.setYAxisTitle(a[s-1]);break;case 34:r.setYAxisTitle({type:`text`,text:``});break;case 35:r.setYAxisRangeData(Number(a[s-2]),Number(a[s]));break;case 39:this.$={text:a[s],type:`text`};break;case 40:this.$={text:a[s],type:`text`};break;case 41:this.$={text:a[s],type:`markdown`};break;case 42:this.$=a[s];break;case 43:this.$=a[s-1]+``+a[s];break}},`anonymous`),table:[t(n,r,{3:1,4:2,7:4,5:i,36:a,37:o,38:s}),{1:[3]},t(n,r,{4:2,7:4,3:8,5:i,36:a,37:o,38:s}),t(n,r,{4:2,7:4,6:9,3:10,5:i,8:[1,11],36:a,37:o,38:s}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},t(c,[2,36]),t(c,[2,37]),t(c,[2,38]),{1:[2,1]},t(n,r,{4:2,7:4,3:21,5:i,36:a,37:o,38:s}),{1:[2,3]},t(c,[2,5]),t(n,[2,7],{4:22,36:a,37:o,38:s}),{11:23,30:l,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},{11:39,13:38,24:x,29:S,30:l,31:40,32:41,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},{11:45,15:44,29:C,30:l,35:46,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},{11:49,17:48,24:w,30:l,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},{11:52,17:51,24:w,30:l,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},{20:[1,53]},{22:[1,54]},t(T,[2,18]),{1:[2,2]},t(T,[2,8]),t(T,[2,9]),t(E,[2,39],{41:55,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b}),t(E,[2,40]),t(E,[2,41]),t(D,[2,42]),t(D,[2,44]),t(D,[2,45]),t(D,[2,46]),t(D,[2,47]),t(D,[2,48]),t(D,[2,49]),t(D,[2,50]),t(D,[2,51]),t(D,[2,52]),t(D,[2,53]),t(T,[2,10]),t(T,[2,24],{32:41,31:56,24:x,29:S}),t(T,[2,26]),t(T,[2,27]),{33:[1,57]},{11:59,30:l,34:58,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},t(T,[2,11]),t(T,[2,32],{35:60,29:C}),t(T,[2,34]),{33:[1,61]},t(T,[2,12]),{17:62,24:w},{25:63,27:64,29:O},t(T,[2,14]),{17:66,24:w},t(T,[2,16]),t(T,[2,17]),t(D,[2,43]),t(T,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},t(T,[2,33]),{29:[1,70]},t(T,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},t(k,[2,23],{30:[1,73]}),t(T,[2,15]),t(T,[2,28]),t(T,[2,29]),{11:59,30:l,34:74,39:24,40:u,41:27,42:d,43:f,44:p,45:m,46:h,47:g,48:_,49:v,50:y,51:b},t(T,[2,35]),t(T,[2,19]),{25:75,27:64,29:O},t(k,[2,22]),{26:[2,30]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],74:[2,30],75:[2,20]},parseError:e(function(e,t){if(t.recoverable)this.trace(e);else{var n=Error(e);throw n.hash=t,n}},`parseError`),parse:e(function(t){var n=this,r=[0],i=[],a=[null],o=[],s=this.table,c=``,l=0,u=0,d=0,f=2,p=1,m=o.slice.call(arguments,1),h=Object.create(this.lexer),g={yy:{}};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(g.yy[_]=this.yy[_]);h.setInput(t,g.yy),g.yy.lexer=h,g.yy.parser=this,h.yylloc===void 0&&(h.yylloc={});var v=h.yylloc;o.push(v);var y=h.options&&h.options.ranges;typeof g.yy.parseError==`function`?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function b(e){r.length-=2*e,a.length-=e,o.length-=e}e(b,`popStack`);function x(){var e=i.pop()||h.lex()||p;return typeof e!=`number`&&(e instanceof Array&&(i=e,e=i.pop()),e=n.symbols_[e]||e),e}e(x,`lex`);for(var S,C,w,T,E,D={},O,k,A,j;;){if(w=r[r.length-1],this.defaultActions[w]?T=this.defaultActions[w]:(S??=x(),T=s[w]&&s[w][S]),T===void 0||!T.length||!T[0]){var M=``;for(O in j=[],s[w])this.terminals_[O]&&O>f&&j.push(`'`+this.terminals_[O]+`'`);M=h.showPosition?`Parse error on line `+(l+1)+`:
|
|
2
2
|
`+h.showPosition()+`
|
|
3
3
|
Expecting `+j.join(`, `)+`, got '`+(this.terminals_[S]||S)+`'`:`Parse error on line `+(l+1)+`: Unexpected `+(S==p?`end of input`:`'`+(this.terminals_[S]||S)+`'`),this.parseError(M,{text:h.match,token:this.terminals_[S]||S,line:h.yylineno,loc:v,expected:j})}if(T[0]instanceof Array&&T.length>1)throw Error(`Parse Error: multiple actions possible at state: `+w+`, token: `+S);switch(T[0]){case 1:r.push(S),a.push(h.yytext),o.push(h.yylloc),r.push(T[1]),S=null,C?(S=C,C=null):(u=h.yyleng,c=h.yytext,l=h.yylineno,v=h.yylloc,d>0&&d--);break;case 2:if(k=this.productions_[T[1]][1],D.$=a[a.length-k],D._$={first_line:o[o.length-(k||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(k||1)].first_column,last_column:o[o.length-1].last_column},y&&(D._$.range=[o[o.length-(k||1)].range[0],o[o.length-1].range[1]]),E=this.performAction.apply(D,[c,u,l,g.yy,T[1],a,o].concat(m)),E!==void 0)return E;k&&(r=r.slice(0,-1*k*2),a=a.slice(0,-1*k),o=o.slice(0,-1*k)),r.push(this.productions_[T[1]][0]),a.push(D.$),o.push(D._$),A=s[r[r.length-2]][r[r.length-1]],r.push(A);break;case 3:return!0}}return!0},`parse`)};A.lexer=(function(){return{EOF:1,parseError:e(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},`parseError`),setInput:e(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match=``,this.conditionStack=[`INITIAL`],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},`setInput`),input:e(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},`input`),unput:e(function(e){var t=e.length,n=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},`unput`),more:e(function(){return this._more=!0,this},`more`),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError(`Lexical error on line `+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:``,token:null,line:this.yylineno});return this},`reject`),less:e(function(e){this.unput(this.match.slice(e))},`less`),pastInput:e(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?`...`:``)+e.substr(-20).replace(/\n/g,``)},`pastInput`),upcomingInput:e(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?`...`:``)).replace(/\n/g,``)},`upcomingInput`),showPosition:e(function(){var e=this.pastInput(),t=Array(e.length+1).join(`-`);return e+this.upcomingInput()+`
|
package/dist/public/index.html
CHANGED
|
@@ -58,52 +58,52 @@
|
|
|
58
58
|
-->
|
|
59
59
|
<script>(() => { let t = 'system'; try { const r = localStorage.getItem('ok-theme-v1'); if (r === 'light' || r === 'dark' || r === 'system') t = r; } catch {} let ct = null; try { const c = localStorage.getItem('ok-color-theme-v1'); if (c && ['dracula', 'catppuccin-frappe', 'catppuccin-latte', 'monokai', 'gruvbox', 'solarized', 'custom'].includes(c)) ct = c; } catch {} let dark = t === 'dark'; if (t === 'system') { try { dark = window.matchMedia('(prefers-color-scheme: dark)').matches; } catch {} } let customCss = null; if (ct === 'custom') { try { const raw = localStorage.getItem('ok-custom-theme-v1'); if (raw) { const o = JSON.parse(raw); if (o?.css) { customCss = o.css; dark = !!o.dark; } } } catch {} if (!customCss) ct = null; } else if (ct) { dark = !['catppuccin-latte'].includes(ct); } if (dark) document.documentElement.classList.add('dark'); if (ct) document.documentElement.setAttribute('data-color-theme', ct); if (customCss) { const s = document.createElement('style'); s.id = 'ok-custom-theme'; s.textContent = customCss; document.head.appendChild(s); } if (window.okDesktop) document.documentElement.classList.add('electron-mode'); })();</script>
|
|
60
60
|
<style>html { background-color: #fafafa } html.dark { background-color: #171717 }</style>
|
|
61
|
-
<script type="module" crossorigin src="./assets/index-
|
|
61
|
+
<script type="module" crossorigin src="./assets/index-DMdt07dO.js"></script>
|
|
62
62
|
<link rel="modulepreload" crossorigin href="./assets/chunk-DseTPa7n.js">
|
|
63
63
|
<link rel="modulepreload" crossorigin href="./assets/preload-helper-2ej06EnG.js">
|
|
64
64
|
<link rel="modulepreload" crossorigin href="./assets/w3c-keyname-CRPBoZED.js">
|
|
65
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
66
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
67
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
68
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
69
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
70
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
71
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
72
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
73
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
74
|
-
<link rel="modulepreload" crossorigin href="./assets/stex-
|
|
65
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-BQhSFgYM.js">
|
|
66
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-CML_8CPx.js">
|
|
67
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-BuhX1ZiW.js">
|
|
68
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-BjlQpfm2.js">
|
|
69
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-Bvng05Ux.js">
|
|
70
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-BiVF6Gdz.js">
|
|
71
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-CCfVhAvJ.js">
|
|
72
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-DXywpqg-.js">
|
|
73
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-D1KI0nTz.js">
|
|
74
|
+
<link rel="modulepreload" crossorigin href="./assets/stex-CLng_sPo.js">
|
|
75
75
|
<link rel="modulepreload" crossorigin href="./assets/floating-ui.dom-B3TJy2Tg.js">
|
|
76
76
|
<link rel="modulepreload" crossorigin href="./assets/trace-api-BIWqyPc9.js">
|
|
77
77
|
<link rel="modulepreload" crossorigin href="./assets/markdownit-DyWy6cMj.js">
|
|
78
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
78
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-z6xoO_FO.js">
|
|
79
79
|
<link rel="modulepreload" crossorigin href="./assets/compiler-runtime-DrcePeIl.js">
|
|
80
80
|
<link rel="modulepreload" crossorigin href="./assets/dist-DGbq0bSp.js">
|
|
81
|
-
<link rel="modulepreload" crossorigin href="./assets/use-apply-config-color-theme-
|
|
82
|
-
<link rel="modulepreload" crossorigin href="./assets/config-context-
|
|
83
|
-
<link rel="modulepreload" crossorigin href="./assets/config-provider-
|
|
84
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
81
|
+
<link rel="modulepreload" crossorigin href="./assets/use-apply-config-color-theme-BHcKd5uB.js">
|
|
82
|
+
<link rel="modulepreload" crossorigin href="./assets/config-context-BaIZpYSb.js">
|
|
83
|
+
<link rel="modulepreload" crossorigin href="./assets/config-provider-CKgTRKRt.js">
|
|
84
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-o9cVHl8Q.js">
|
|
85
85
|
<link rel="modulepreload" crossorigin href="./assets/dist-CSDjUb5q.js">
|
|
86
86
|
<link rel="modulepreload" crossorigin href="./assets/createLucideIcon-Wgamzz8_.js">
|
|
87
87
|
<link rel="modulepreload" crossorigin href="./assets/folder-open-ygPcz1xa.js">
|
|
88
|
-
<link rel="modulepreload" crossorigin href="./assets/trash-2-
|
|
89
|
-
<link rel="modulepreload" crossorigin href="./assets/triangle-alert-
|
|
88
|
+
<link rel="modulepreload" crossorigin href="./assets/trash-2-U9wpS1zc.js">
|
|
89
|
+
<link rel="modulepreload" crossorigin href="./assets/triangle-alert-BaZPlVka.js">
|
|
90
90
|
<link rel="modulepreload" crossorigin href="./assets/react-dom-CMNLH3L-.js">
|
|
91
|
-
<link rel="modulepreload" crossorigin href="./assets/doc-hash-
|
|
92
|
-
<link rel="modulepreload" crossorigin href="./assets/navigation-targets-
|
|
93
|
-
<link rel="modulepreload" crossorigin href="./assets/external-link-
|
|
94
|
-
<link rel="modulepreload" crossorigin href="./assets/documents-fetch-
|
|
95
|
-
<link rel="modulepreload" crossorigin href="./assets/CodeMirrorPropInput-
|
|
96
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
97
|
-
<link rel="modulepreload" crossorigin href="./assets/documents-events-
|
|
98
|
-
<link rel="modulepreload" crossorigin href="./assets/parse-api-error-
|
|
99
|
-
<link rel="modulepreload" crossorigin href="./assets/open-managed-artifact-tab-
|
|
91
|
+
<link rel="modulepreload" crossorigin href="./assets/doc-hash-CR_v-pVy.js">
|
|
92
|
+
<link rel="modulepreload" crossorigin href="./assets/navigation-targets-BW-vH_E0.js">
|
|
93
|
+
<link rel="modulepreload" crossorigin href="./assets/external-link-BUoZ56id.js">
|
|
94
|
+
<link rel="modulepreload" crossorigin href="./assets/documents-fetch-BzTSsuPI.js">
|
|
95
|
+
<link rel="modulepreload" crossorigin href="./assets/CodeMirrorPropInput-D7LKYsQT.js">
|
|
96
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-Byo4jhAQ.js">
|
|
97
|
+
<link rel="modulepreload" crossorigin href="./assets/documents-events-WLCQAftW.js">
|
|
98
|
+
<link rel="modulepreload" crossorigin href="./assets/parse-api-error-DfesE4Y7.js">
|
|
99
|
+
<link rel="modulepreload" crossorigin href="./assets/open-managed-artifact-tab-Mlt2_LRl.js">
|
|
100
100
|
<link rel="modulepreload" crossorigin href="./assets/dist-DivkR5AO.js">
|
|
101
101
|
<link rel="modulepreload" crossorigin href="./assets/dist-DGkUVO6K.js">
|
|
102
102
|
<link rel="modulepreload" crossorigin href="./assets/propagation-api-M_AcuP6N.js">
|
|
103
103
|
<link rel="modulepreload" crossorigin href="./assets/collapsible-UIgt0pSO.js">
|
|
104
104
|
<link rel="modulepreload" crossorigin href="./assets/dist-Bpw_gSUm.js">
|
|
105
|
-
<link rel="modulepreload" crossorigin href="./assets/x-
|
|
106
|
-
<link rel="modulepreload" crossorigin href="./assets/dialog-
|
|
105
|
+
<link rel="modulepreload" crossorigin href="./assets/x-_C6KOlzX.js">
|
|
106
|
+
<link rel="modulepreload" crossorigin href="./assets/dialog-492Ff7fG.js">
|
|
107
107
|
<link rel="modulepreload" crossorigin href="./assets/tooltip-CuKuwVbZ.js">
|
|
108
108
|
<link rel="modulepreload" crossorigin href="./assets/dist-CVCmotds.js">
|
|
109
109
|
<link rel="modulepreload" crossorigin href="./assets/git-branch-CAiKE5bw.js">
|
|
@@ -112,48 +112,50 @@
|
|
|
112
112
|
<link rel="modulepreload" crossorigin href="./assets/chevron-right-B2thM4kG.js">
|
|
113
113
|
<link rel="modulepreload" crossorigin href="./assets/copy-CfDOH9N1.js">
|
|
114
114
|
<link rel="modulepreload" crossorigin href="./assets/CopyButton-B8lE78wK.js">
|
|
115
|
-
<link rel="modulepreload" crossorigin href="./assets/startup-marks-
|
|
116
|
-
<link rel="modulepreload" crossorigin href="./assets/prop-types-
|
|
117
|
-
<link rel="modulepreload" crossorigin href="./assets/workspace-paths-
|
|
115
|
+
<link rel="modulepreload" crossorigin href="./assets/startup-marks-2VTPXUbb.js">
|
|
116
|
+
<link rel="modulepreload" crossorigin href="./assets/prop-types-D0GhY5_m.js">
|
|
117
|
+
<link rel="modulepreload" crossorigin href="./assets/workspace-paths-DTMEcAKi.js">
|
|
118
118
|
<link rel="modulepreload" crossorigin href="./assets/eye-Cq1_8-Tk.js">
|
|
119
119
|
<link rel="modulepreload" crossorigin href="./assets/info-CVuSDi5Y.js">
|
|
120
120
|
<link rel="modulepreload" crossorigin href="./assets/loader-circle-BrJhrTc7.js">
|
|
121
|
-
<link rel="modulepreload" crossorigin href="./assets/dist-
|
|
122
|
-
<link rel="modulepreload" crossorigin href="./assets/file-tree-rename-validation-
|
|
123
|
-
<link rel="modulepreload" crossorigin href="./assets/input-
|
|
124
|
-
<link rel="modulepreload" crossorigin href="./assets/DocumentContext-
|
|
121
|
+
<link rel="modulepreload" crossorigin href="./assets/dist-CAIcun02.js">
|
|
122
|
+
<link rel="modulepreload" crossorigin href="./assets/file-tree-rename-validation-GUkltgNP.js">
|
|
123
|
+
<link rel="modulepreload" crossorigin href="./assets/input-b4FSCbA5.js">
|
|
124
|
+
<link rel="modulepreload" crossorigin href="./assets/DocumentContext-CD-cYy1t.js">
|
|
125
125
|
<link rel="modulepreload" crossorigin href="./assets/checkbox-Ds7GA0j4.js">
|
|
126
126
|
<link rel="modulepreload" crossorigin href="./assets/dist-Ly1ZfY-Y.js">
|
|
127
|
-
<link rel="modulepreload" crossorigin href="./assets/skills-api-
|
|
127
|
+
<link rel="modulepreload" crossorigin href="./assets/skills-api-ej5KW5dn.js">
|
|
128
128
|
<link rel="modulepreload" crossorigin href="./assets/label-CveCqKNR.js">
|
|
129
129
|
<link rel="modulepreload" crossorigin href="./assets/radio-group-D9Wp487Q.js">
|
|
130
|
-
<link rel="modulepreload" crossorigin href="./assets/EnableSyncConfirmDialog-
|
|
130
|
+
<link rel="modulepreload" crossorigin href="./assets/EnableSyncConfirmDialog-BsDontPj.js">
|
|
131
131
|
<link rel="modulepreload" crossorigin href="./assets/arrow-up-right-BnJZWj8r.js">
|
|
132
|
-
<link rel="modulepreload" crossorigin href="./assets/refresh-cw-
|
|
133
|
-
<link rel="modulepreload" crossorigin href="./assets/cursor-
|
|
134
|
-
<link rel="modulepreload" crossorigin href="./assets/clipboard-adapter-
|
|
135
|
-
<link rel="modulepreload" crossorigin href="./assets/skill-actions-
|
|
136
|
-
<link rel="modulepreload" crossorigin href="./assets/lint-config-client-
|
|
137
|
-
<link rel="modulepreload" crossorigin href="./assets/textarea
|
|
138
|
-
<link rel="modulepreload" crossorigin href="./assets/auth-state-cache-
|
|
132
|
+
<link rel="modulepreload" crossorigin href="./assets/refresh-cw-DgVrChIu.js">
|
|
133
|
+
<link rel="modulepreload" crossorigin href="./assets/cursor-jdIvZ4dc.js">
|
|
134
|
+
<link rel="modulepreload" crossorigin href="./assets/clipboard-adapter-CfjsRFpv.js">
|
|
135
|
+
<link rel="modulepreload" crossorigin href="./assets/skill-actions-MlZySxOC.js">
|
|
136
|
+
<link rel="modulepreload" crossorigin href="./assets/lint-config-client-DrncMKpi.js">
|
|
137
|
+
<link rel="modulepreload" crossorigin href="./assets/textarea-D45cTFgp.js">
|
|
138
|
+
<link rel="modulepreload" crossorigin href="./assets/auth-state-cache-CQH-tSHp.js">
|
|
139
139
|
<link rel="modulepreload" crossorigin href="./assets/toggle-group-B30vKHKs.js">
|
|
140
140
|
<link rel="modulepreload" crossorigin href="./assets/panel-BGYdvxEm.js">
|
|
141
|
-
<link rel="modulepreload" crossorigin href="./assets/format-
|
|
142
|
-
<link rel="modulepreload" crossorigin href="./assets/selection-context-
|
|
143
|
-
<link rel="modulepreload" crossorigin href="./assets/PropertyPanel-
|
|
141
|
+
<link rel="modulepreload" crossorigin href="./assets/format-ClWHbKHd.js">
|
|
142
|
+
<link rel="modulepreload" crossorigin href="./assets/selection-context-B8-qhck0.js">
|
|
143
|
+
<link rel="modulepreload" crossorigin href="./assets/PropertyPanel-jcK4Zprh.js">
|
|
144
144
|
<link rel="modulepreload" crossorigin href="./assets/miss-dialog-store-b0Uwu1ZT.js">
|
|
145
|
-
<link rel="modulepreload" crossorigin href="./assets/pending-receive-nav-store-
|
|
145
|
+
<link rel="modulepreload" crossorigin href="./assets/pending-receive-nav-store-VIiKipN9.js">
|
|
146
146
|
<link rel="modulepreload" crossorigin href="./assets/chevron-left-rxhGFFOu.js">
|
|
147
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
148
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
149
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
150
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
151
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
152
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
153
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
154
|
-
<link rel="modulepreload" crossorigin href="./assets/
|
|
147
|
+
<link rel="modulepreload" crossorigin href="./assets/panel-right-open-CBQxOUPX.js">
|
|
148
|
+
<link rel="modulepreload" crossorigin href="./assets/timeline-diff-store-HBj2AFCu.js">
|
|
149
|
+
<link rel="modulepreload" crossorigin href="./assets/typing-burst-detector-3hPuqdYY.js">
|
|
150
|
+
<link rel="modulepreload" crossorigin href="./assets/project-paths-CSBBkRS0.js">
|
|
151
|
+
<link rel="modulepreload" crossorigin href="./assets/file-tree-adapter-BrNRZNNL.js">
|
|
152
|
+
<link rel="modulepreload" crossorigin href="./assets/agent-presence-C7KW4GFN.js">
|
|
153
|
+
<link rel="modulepreload" crossorigin href="./assets/target-navigation-intent-CmDfj84r.js">
|
|
154
|
+
<link rel="modulepreload" crossorigin href="./assets/mcp-consent-store-DL93ger0.js">
|
|
155
|
+
<link rel="modulepreload" crossorigin href="./assets/receive-store-C5i5j6PY.js">
|
|
156
|
+
<link rel="modulepreload" crossorigin href="./assets/worktree-store-Dwj7qwtV.js">
|
|
155
157
|
<link rel="stylesheet" crossorigin href="./assets/DocumentContext-B0sQn39F.css">
|
|
156
|
-
<link rel="stylesheet" crossorigin href="./assets/index-
|
|
158
|
+
<link rel="stylesheet" crossorigin href="./assets/index-C3iemlkC.css">
|
|
157
159
|
</head>
|
|
158
160
|
|
|
159
161
|
<body class="antialiased">
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{t as e}from"./launch-json-removal-
|
|
2
|
-
//# sourceMappingURL=repair-launch-json-
|
|
1
|
+
import{t as e}from"./launch-json-removal-BazOhu5J.mjs";import{join as t}from"node:path";function n(n){let i=n.logger??r,a=t(n.projectDir,`.claude`,`launch.json`);if(n.reclaimDisableEnv===`1`)return i({event:`launch-json-repair-skipped`,reason:`reclaim-disabled`}),{outcome:{configPath:a,outcome:`skipped-reclaim-disabled`},repairedCount:0};let o;try{o=e(n.projectDir)}catch(e){let t=e instanceof Error?e.message:String(e);return i({event:`launch-json-repair-write-failed`,configPath:a}),{outcome:{configPath:a,outcome:`write-failed`,error:t},repairedCount:0}}let s=o.kind===`removed`||o.kind===`removed-file`;return s&&i({event:`launch-json-repair-removed`,configPath:a}),{outcome:{configPath:a,outcome:o.kind},repairedCount:+!!s}}function r(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{n as repairLaunchJson};
|
|
2
|
+
//# sourceMappingURL=repair-launch-json-BRDADYRm.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{d as e,v as t}from"./init-
|
|
2
|
-
//# sourceMappingURL=repair-mcp-configs-
|
|
1
|
+
import{d as e,v as t}from"./init-CCbdbwFE.mjs";import{_ as n,d as r,s as i}from"./write-project-skill-CLggzjLg.mjs";import{t as a}from"./mcp-migrate-event-C35ikoh2.mjs";import{homedir as o}from"node:os";function s(e){let t=e.logger??u,n=e.home??o(),a=[];if(e.reclaimDisableEnv===`1`)return t({event:`mcp-config-repair-skipped`,reason:`reclaim-disabled`}),{outcomes:a,repairedCount:0};for(let o of i){let i=r[o],s=c(()=>i.configPath(``,n));if(s!==null&&a.push(l({scope:`user`,editorId:o,target:i,home:n,cwd:``,configPath:s,configPathOverride:void 0,logger:t})),i.projectConfigPath){let n=i.projectConfigPath,r=c(()=>n(e.projectDir));r!==null&&a.push(l({scope:`project`,editorId:o,target:i,home:void 0,cwd:e.projectDir,configPath:r,configPathOverride:r,logger:t}))}}return{outcomes:a,repairedCount:a.filter(e=>e.outcome===`repaired`).length}}function c(e){try{return e()}catch{return null}}function l(r){let i={scope:r.scope,editorId:r.editorId,configPath:r.configPath},o=e(r.target,r.cwd,r.home,r.configPathOverride);if(o===null)return{...i,outcome:`no-entry`};if(n(o))return{...i,outcome:`canonical`};r.logger(a({scope:r.scope,surface:`cli-repair`,editorId:r.editorId,configPath:r.configPath,priorEntry:o}));let s=t(r.target,r.cwd,{mode:`published`,skipAvailabilityCheck:!0},r.home,r.configPathOverride);if(s.action===`failed`){let e=s.error??`unknown write failure`;return r.logger({event:`mcp-config-repair-write-failed`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,error:e}),{...i,outcome:`write-failed`,error:e}}return s.action===`declined`?(r.logger({event:`mcp-config-repair-declined`,scope:r.scope,editorId:r.editorId,configPath:r.configPath,reason:s.declineReason}),{...i,outcome:`declined`}):{...i,outcome:`repaired`}}function u(e){process.stderr.write(`${JSON.stringify(e)}\n`)}export{s as repairMcpConfigs};
|
|
2
|
+
//# sourceMappingURL=repair-mcp-configs-Be-QiQqq.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./repair-skills-CjpripUK.mjs";export{e as repairSkills};
|