@aggroot-team/aggroot 1.9.8 → 1.9.9
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/index.cjs +944 -941
- package/dist/native/better_sqlite3.node +0 -0
- package/package.json +2 -2
- package/scripts/build-all.mjs +7 -7
- package/share/web/dist/assets/{arc-C6mmQI6r.js → arc-vAbfGHI4.js} +1 -1
- package/share/web/dist/assets/architectureDiagram-3BPJPVTR-Beofs4Vr.js +36 -0
- package/share/web/dist/assets/blockDiagram-GPEHLZMM-BHald0vJ.js +132 -0
- package/share/web/dist/assets/c4Diagram-AAUBKEIU-DdheLyDg.js +10 -0
- package/share/web/dist/assets/channel-RUPVcLbL.js +1 -0
- package/share/web/dist/assets/chunk-2J33WTMH-CqifXJHr.js +1 -0
- package/share/web/dist/assets/chunk-4BX2VUAB-Ct0wiv5k.js +1 -0
- package/share/web/dist/assets/{chunk-55IACEB6-CR3JEwA1.js → chunk-55IACEB6-C3ZOlIck.js} +1 -1
- package/share/web/dist/assets/chunk-727SXJPM-D_-n9Kx7.js +206 -0
- package/share/web/dist/assets/chunk-AQP2D5EJ-Cs0Pzu6B.js +231 -0
- package/share/web/dist/assets/{chunk-FMBD7UC4-C9iK_zJ6.js → chunk-FMBD7UC4-BqU9GOt6.js} +1 -1
- package/share/web/dist/assets/{chunk-ND2GUHAM-Cf0-DaOM.js → chunk-ND2GUHAM-C4XXXRHx.js} +1 -1
- package/share/web/dist/assets/{chunk-QZHKN3VN-BdStKhsc.js → chunk-QZHKN3VN-BQx_T-pw.js} +1 -1
- package/share/web/dist/assets/classDiagram-4FO5ZUOK-BpLeHiQl.js +1 -0
- package/share/web/dist/assets/classDiagram-v2-Q7XG4LA2-BpLeHiQl.js +1 -0
- package/share/web/dist/assets/cose-bilkent-S5V4N54A-Dg4UBnML.js +1 -0
- package/share/web/dist/assets/cytoscape.esm-LDYqcvCF.js +331 -0
- package/share/web/dist/assets/dagre-BM42HDAG-BJ-Bl03N.js +4 -0
- package/share/web/dist/assets/diagram-2AECGRRQ-Copnlt_p.js +43 -0
- package/share/web/dist/assets/{diagram-5GNKFQAL-DCqIh_mb.js → diagram-5GNKFQAL-CMy5CqNk.js} +1 -1
- package/share/web/dist/assets/diagram-KO2AKTUF-AZ4G-26n.js +3 -0
- package/share/web/dist/assets/diagram-LMA3HP47-DdD4VMzH.js +24 -0
- package/share/web/dist/assets/diagram-OG6HWLK6-jDgNtQLg.js +24 -0
- package/share/web/dist/assets/{erDiagram-TEJ5UH35-DWrRY3pY.js → erDiagram-TEJ5UH35-BRKRSsvs.js} +18 -18
- package/share/web/dist/assets/flowDiagram-I6XJVG4X-B-y9L8Rr.js +162 -0
- package/share/web/dist/assets/{ganttDiagram-6RSMTGT7-DnFfa4-K.js → ganttDiagram-6RSMTGT7-9HFj_Xfu.js} +1 -1
- package/share/web/dist/assets/gitGraphDiagram-PVQCEYII-BeEiyKwE.js +106 -0
- package/share/web/dist/assets/graph-BEmEBUp_.js +1 -0
- package/share/web/dist/assets/index-BGVEOJln.js +462 -0
- package/share/web/dist/assets/{infoDiagram-5YYISTIA-BY07mlm3.js → infoDiagram-5YYISTIA-B_xf2BO8.js} +1 -1
- package/share/web/dist/assets/ishikawaDiagram-YF4QCWOH-CnkHvVMc.js +70 -0
- package/share/web/dist/assets/{journeyDiagram-JHISSGLW-DUTH5iJA.js → journeyDiagram-JHISSGLW-BhCKF-L6.js} +1 -1
- package/share/web/dist/assets/kanban-definition-UN3LZRKU-f3ghgA-_.js +89 -0
- package/share/web/dist/assets/{katex-HP8lGamR.js → katex-C5jXJg4s.js} +1 -1
- package/share/web/dist/assets/{layout-UJbxhwF7.js → layout-Bw0msyOw.js} +1 -1
- package/share/web/dist/assets/{linear-C1DMihRv.js → linear-CxTWz0e9.js} +1 -1
- package/share/web/dist/assets/mindmap-definition-RKZ34NQL-AT8F9pYs.js +96 -0
- package/share/web/dist/assets/pieDiagram-4H26LBE5-DdmWKttq.js +30 -0
- package/share/web/dist/assets/quadrantDiagram-W4KKPZXB-CO1Ivpei.js +7 -0
- package/share/web/dist/assets/{requirementDiagram-4Y6WPE33-DNohf4JY.js → requirementDiagram-4Y6WPE33-D6vgvFtL.js} +13 -13
- package/share/web/dist/assets/{sankeyDiagram-5OEKKPKP-C8GlIWqD.js → sankeyDiagram-5OEKKPKP-CzpA03NF.js} +7 -7
- package/share/web/dist/assets/sequenceDiagram-3UESZ5HK-D9p7JlcE.js +162 -0
- package/share/web/dist/assets/{stateDiagram-AJRCARHV-D7KEcCai.js → stateDiagram-AJRCARHV-D5WeiPVB.js} +1 -1
- package/share/web/dist/assets/stateDiagram-v2-BHNVJYJU-DhUy5VW5.js +1 -0
- package/share/web/dist/assets/timeline-definition-PNZ67QCA-c8ZcxVVs.js +120 -0
- package/share/web/dist/assets/vennDiagram-CIIHVFJN-Chtw87Kc.js +34 -0
- package/share/web/dist/assets/wardley-L42UT6IY-BU-MTDCS.js +173 -0
- package/share/web/dist/assets/wardleyDiagram-YWT4CUSO-DphjJCYS.js +78 -0
- package/share/web/dist/assets/{xychartDiagram-2RQKCTM6-Bi2JpQ7J.js → xychartDiagram-2RQKCTM6-DcJv_8WS.js} +1 -1
- package/share/web/dist/index.html +1 -1
- package/share/web/dist/assets/arc-MoXg1d0p.js +0 -1
- package/share/web/dist/assets/arc-foVguWzs.js +0 -1
- package/share/web/dist/assets/architectureDiagram-3BPJPVTR-BZ3BmMWb.js +0 -36
- package/share/web/dist/assets/architectureDiagram-3BPJPVTR-DOSLjLkp.js +0 -36
- package/share/web/dist/assets/architectureDiagram-3BPJPVTR-POoFbIwD.js +0 -36
- package/share/web/dist/assets/blockDiagram-GPEHLZMM-2SlCtuS9.js +0 -132
- package/share/web/dist/assets/blockDiagram-GPEHLZMM-C2gUhwLv.js +0 -132
- package/share/web/dist/assets/blockDiagram-GPEHLZMM-DGI0e92G.js +0 -132
- package/share/web/dist/assets/c4Diagram-AAUBKEIU-BUzmmhxG.js +0 -10
- package/share/web/dist/assets/c4Diagram-AAUBKEIU-Dc9JtzPS.js +0 -10
- package/share/web/dist/assets/c4Diagram-AAUBKEIU-Du9NVD3C.js +0 -10
- package/share/web/dist/assets/channel-C2ua6c7e.js +0 -1
- package/share/web/dist/assets/channel-RhuWyCOn.js +0 -1
- package/share/web/dist/assets/channel-kDWigw7H.js +0 -1
- package/share/web/dist/assets/chunk-2J33WTMH-564mo_tM.js +0 -1
- package/share/web/dist/assets/chunk-2J33WTMH-BMg4ExGP.js +0 -1
- package/share/web/dist/assets/chunk-2J33WTMH-Ci30owWm.js +0 -1
- package/share/web/dist/assets/chunk-4BX2VUAB-B9jaG_QE.js +0 -1
- package/share/web/dist/assets/chunk-4BX2VUAB-BTkmuMjL.js +0 -1
- package/share/web/dist/assets/chunk-4BX2VUAB-ClCdFzK4.js +0 -1
- package/share/web/dist/assets/chunk-55IACEB6-Dul_8Xx4.js +0 -1
- package/share/web/dist/assets/chunk-55IACEB6-Dx0fiG9q.js +0 -1
- package/share/web/dist/assets/chunk-727SXJPM-0IWOks3B.js +0 -206
- package/share/web/dist/assets/chunk-727SXJPM-BmSdyEyO.js +0 -206
- package/share/web/dist/assets/chunk-727SXJPM-zLYsaIFD.js +0 -206
- package/share/web/dist/assets/chunk-AQP2D5EJ-CKL53_sC.js +0 -231
- package/share/web/dist/assets/chunk-AQP2D5EJ-CPGjYv1S.js +0 -231
- package/share/web/dist/assets/chunk-AQP2D5EJ-DyXBBZBO.js +0 -231
- package/share/web/dist/assets/chunk-FMBD7UC4-CKqn3QTP.js +0 -15
- package/share/web/dist/assets/chunk-FMBD7UC4-relLrlnf.js +0 -15
- package/share/web/dist/assets/chunk-ND2GUHAM-D-YV3DlT.js +0 -1
- package/share/web/dist/assets/chunk-ND2GUHAM-DIK8aiyH.js +0 -1
- package/share/web/dist/assets/chunk-QZHKN3VN-CNOTwrb0.js +0 -1
- package/share/web/dist/assets/chunk-QZHKN3VN-GToMNcRQ.js +0 -1
- package/share/web/dist/assets/classDiagram-4FO5ZUOK-BpIpZpbS.js +0 -1
- package/share/web/dist/assets/classDiagram-4FO5ZUOK-BwfLgb5V.js +0 -1
- package/share/web/dist/assets/classDiagram-4FO5ZUOK-iYw5Cpy-.js +0 -1
- package/share/web/dist/assets/classDiagram-v2-Q7XG4LA2-BpIpZpbS.js +0 -1
- package/share/web/dist/assets/classDiagram-v2-Q7XG4LA2-BwfLgb5V.js +0 -1
- package/share/web/dist/assets/classDiagram-v2-Q7XG4LA2-iYw5Cpy-.js +0 -1
- package/share/web/dist/assets/cose-bilkent-S5V4N54A-CPXDOhe6.js +0 -1
- package/share/web/dist/assets/cose-bilkent-S5V4N54A-Cz_EEjbJ.js +0 -1
- package/share/web/dist/assets/cose-bilkent-S5V4N54A-DoyDfnRN.js +0 -1
- package/share/web/dist/assets/cytoscape.esm-CkSuTymj.js +0 -321
- package/share/web/dist/assets/dagre-BM42HDAG-BF-TF-Yz.js +0 -4
- package/share/web/dist/assets/dagre-BM42HDAG-D8k98yee.js +0 -4
- package/share/web/dist/assets/dagre-BM42HDAG-dY4nCbRX.js +0 -4
- package/share/web/dist/assets/diagram-2AECGRRQ-C-3swK4g.js +0 -43
- package/share/web/dist/assets/diagram-2AECGRRQ-D1bMaK6f.js +0 -43
- package/share/web/dist/assets/diagram-2AECGRRQ-Drlj1z6K.js +0 -43
- package/share/web/dist/assets/diagram-5GNKFQAL-DUyqaydI.js +0 -10
- package/share/web/dist/assets/diagram-5GNKFQAL-m7JaaKf6.js +0 -10
- package/share/web/dist/assets/diagram-KO2AKTUF-DOLM9GVq.js +0 -3
- package/share/web/dist/assets/diagram-KO2AKTUF-D_dEKcS6.js +0 -3
- package/share/web/dist/assets/diagram-KO2AKTUF-DiNHmwOH.js +0 -3
- package/share/web/dist/assets/diagram-LMA3HP47-BVlz_lgN.js +0 -24
- package/share/web/dist/assets/diagram-LMA3HP47-CWxd-6HZ.js +0 -24
- package/share/web/dist/assets/diagram-LMA3HP47-DQjh05P_.js +0 -24
- package/share/web/dist/assets/diagram-OG6HWLK6-C395J901.js +0 -24
- package/share/web/dist/assets/diagram-OG6HWLK6-CyAuKYvH.js +0 -24
- package/share/web/dist/assets/diagram-OG6HWLK6-cbK4GNYr.js +0 -24
- package/share/web/dist/assets/erDiagram-TEJ5UH35-D6xjxZ49.js +0 -85
- package/share/web/dist/assets/erDiagram-TEJ5UH35-DvJvvZeG.js +0 -85
- package/share/web/dist/assets/flowDiagram-I6XJVG4X-BQTG7YDk.js +0 -162
- package/share/web/dist/assets/flowDiagram-I6XJVG4X-C-kXeUBi.js +0 -162
- package/share/web/dist/assets/flowDiagram-I6XJVG4X-Uk0pqh1I.js +0 -162
- package/share/web/dist/assets/ganttDiagram-6RSMTGT7-CiAw7QqE.js +0 -292
- package/share/web/dist/assets/ganttDiagram-6RSMTGT7-x6PvlGL2.js +0 -292
- package/share/web/dist/assets/gitGraphDiagram-PVQCEYII-BtfWDOi9.js +0 -106
- package/share/web/dist/assets/gitGraphDiagram-PVQCEYII-CWneBdAY.js +0 -106
- package/share/web/dist/assets/gitGraphDiagram-PVQCEYII-DKTp_HiB.js +0 -106
- package/share/web/dist/assets/graph-D2o_JWn5.js +0 -1
- package/share/web/dist/assets/index-BCGYoU3m.js +0 -407
- package/share/web/dist/assets/index-BvC6gdHx.js +0 -407
- package/share/web/dist/assets/index-DywDZDjz.js +0 -407
- package/share/web/dist/assets/infoDiagram-5YYISTIA-CfjN-5kB.js +0 -2
- package/share/web/dist/assets/infoDiagram-5YYISTIA-Xkl7BU3j.js +0 -2
- package/share/web/dist/assets/ishikawaDiagram-YF4QCWOH-BZE9KXo2.js +0 -70
- package/share/web/dist/assets/ishikawaDiagram-YF4QCWOH-CGr69Mhu.js +0 -70
- package/share/web/dist/assets/ishikawaDiagram-YF4QCWOH-ChhTQzaW.js +0 -70
- package/share/web/dist/assets/journeyDiagram-JHISSGLW-CI2nhO51.js +0 -139
- package/share/web/dist/assets/journeyDiagram-JHISSGLW-DjzjP2Ja.js +0 -139
- package/share/web/dist/assets/kanban-definition-UN3LZRKU-Bs1OUTN5.js +0 -89
- package/share/web/dist/assets/kanban-definition-UN3LZRKU-CsWF2VYE.js +0 -89
- package/share/web/dist/assets/kanban-definition-UN3LZRKU-DtbIxWlr.js +0 -89
- package/share/web/dist/assets/linear-DBgBtQqi.js +0 -1
- package/share/web/dist/assets/linear-vEfB30Tw.js +0 -1
- package/share/web/dist/assets/mindmap-definition-RKZ34NQL-BhesMLkS.js +0 -96
- package/share/web/dist/assets/mindmap-definition-RKZ34NQL-CVMntWDi.js +0 -96
- package/share/web/dist/assets/mindmap-definition-RKZ34NQL-DR2HYGT4.js +0 -96
- package/share/web/dist/assets/pieDiagram-4H26LBE5-CIkAn0kq.js +0 -30
- package/share/web/dist/assets/pieDiagram-4H26LBE5-CRoZ3DSq.js +0 -30
- package/share/web/dist/assets/pieDiagram-4H26LBE5-CfNAD9xR.js +0 -30
- package/share/web/dist/assets/quadrantDiagram-W4KKPZXB-CplSe1Rw.js +0 -7
- package/share/web/dist/assets/quadrantDiagram-W4KKPZXB-UYoPSWi7.js +0 -7
- package/share/web/dist/assets/quadrantDiagram-W4KKPZXB-tSrUuZ0o.js +0 -7
- package/share/web/dist/assets/requirementDiagram-4Y6WPE33-BOhPb8Hp.js +0 -84
- package/share/web/dist/assets/requirementDiagram-4Y6WPE33-DsvsUutE.js +0 -84
- package/share/web/dist/assets/sankeyDiagram-5OEKKPKP-BjF2FKFT.js +0 -40
- package/share/web/dist/assets/sankeyDiagram-5OEKKPKP-CUs-AFSb.js +0 -40
- package/share/web/dist/assets/sequenceDiagram-3UESZ5HK-CHXHwLsz.js +0 -162
- package/share/web/dist/assets/sequenceDiagram-3UESZ5HK-UMs1OM2D.js +0 -162
- package/share/web/dist/assets/sequenceDiagram-3UESZ5HK-g3R6luwj.js +0 -162
- package/share/web/dist/assets/stateDiagram-AJRCARHV-D1MALm7c.js +0 -1
- package/share/web/dist/assets/stateDiagram-AJRCARHV-DueaHzu3.js +0 -1
- package/share/web/dist/assets/stateDiagram-v2-BHNVJYJU-ByTV1cZj.js +0 -1
- package/share/web/dist/assets/stateDiagram-v2-BHNVJYJU-CccWwklg.js +0 -1
- package/share/web/dist/assets/stateDiagram-v2-BHNVJYJU-DQ_K88f1.js +0 -1
- package/share/web/dist/assets/timeline-definition-PNZ67QCA-CiE-WEg8.js +0 -120
- package/share/web/dist/assets/timeline-definition-PNZ67QCA-E8d8s4V0.js +0 -120
- package/share/web/dist/assets/timeline-definition-PNZ67QCA-UU-dHr26.js +0 -120
- package/share/web/dist/assets/vennDiagram-CIIHVFJN-B7_olhnb.js +0 -34
- package/share/web/dist/assets/vennDiagram-CIIHVFJN-CBO1JMsg.js +0 -34
- package/share/web/dist/assets/vennDiagram-CIIHVFJN-DXMfudVV.js +0 -34
- package/share/web/dist/assets/wardley-L42UT6IY-CRpCqUkS.js +0 -161
- package/share/web/dist/assets/wardley-L42UT6IY-CUHy5aYw.js +0 -161
- package/share/web/dist/assets/wardley-L42UT6IY-mTSjCdTo.js +0 -161
- package/share/web/dist/assets/wardleyDiagram-YWT4CUSO-C434ayTK.js +0 -78
- package/share/web/dist/assets/wardleyDiagram-YWT4CUSO-C59oFP6u.js +0 -78
- package/share/web/dist/assets/wardleyDiagram-YWT4CUSO-DS2y4CHZ.js +0 -78
- package/share/web/dist/assets/xychartDiagram-2RQKCTM6-BHpgRwpt.js +0 -7
- package/share/web/dist/assets/xychartDiagram-2RQKCTM6-CZfuL4ig.js +0 -7
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import{b1 as zt,a2 as Lt,a7 as Tt,b4 as At,a3 as Xt,b2 as Et,b as y,ag as Yt,a4 as Ft,t as Q,aF as et,b0 as It,F as Bt,u as Rt,a5 as V}from"./index-BGVEOJln.js";import{p as Ot}from"./chunk-4BX2VUAB-Ct0wiv5k.js";import{p as Wt}from"./wardley-L42UT6IY-BU-MTDCS.js";var G=y((a,o)=>{const e=a<=1?a*100:a;if(e<0||e>100)throw new Error(`${o} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${a}`);return e},"toPercent"),E=y((a,o,e)=>({x:G(o,`${e} evolution`),y:G(a,`${e} visibility`)}),"toCoordinates"),tt=y(a=>{if(a){if(a==="+<>")return"bidirectional";if(a==="+<")return"backward";if(a==="+>")return"forward"}},"getFlowFromPort"),Dt=y(a=>{if(!(a!=null&&a.startsWith("+")))return{};const o=/^\+'([^']*)'/.exec(a),e=o==null?void 0:o[1];return a.includes("<>")?{flow:"bidirectional",label:e}:a.includes("<")?{flow:"backward",label:e}:a.includes(">")?{flow:"forward",label:e}:{label:e}},"extractFlowFromArrow"),Gt=y((a,o)=>{if(Ot(a,o),a.size&&o.setSize(a.size.width,a.size.height),a.evolution){const e=a.evolution.stages.map(r=>r.secondName?`${r.name.trim()} / ${r.secondName.trim()}`:r.name.trim()),p=a.evolution.stages.filter(r=>r.boundary!==void 0).map(r=>r.boundary);o.updateAxes({stages:e,stageBoundaries:p})}if(a.anchors.forEach(e=>{const p=E(e.visibility,e.evolution,`Anchor "${e.name}"`);o.addNode(e.name,e.name,p.x,p.y,"anchor")}),a.components.forEach(e=>{var v;const p=E(e.visibility,e.evolution,`Component "${e.name}"`),r=e.label?(e.label.negX?-1:1)*e.label.offsetX:void 0,d=e.label?(e.label.negY?-1:1)*e.label.offsetY:void 0,m=(v=e.decorator)==null?void 0:v.strategy;o.addNode(e.name,e.name,p.x,p.y,"component",r,d,e.inertia,m)}),a.notes.forEach(e=>{const p=E(e.visibility,e.evolution,`Note "${e.text}"`);o.addNote(e.text,p.x,p.y)}),a.pipelines.forEach(e=>{const p=o.getNode(e.parent);if(!p||typeof p.y!="number")throw new Error(`Pipeline "${e.parent}" must reference an existing component with coordinates.`);const r=p.y;o.startPipeline(e.parent),e.components.forEach(d=>{const m=`${e.parent}_${d.name}`,v=d.label?(d.label.negX?-1:1)*d.label.offsetX:void 0,g=d.label?(d.label.negY?-1:1)*d.label.offsetY:void 0,L=G(d.evolution,`Pipeline component "${d.name}" evolution`);o.addNode(m,d.name,L,r,"pipeline-component",v,g),o.addPipelineComponent(e.parent,m)})}),a.links.forEach(e=>{const p=!!e.arrow&&(e.arrow.includes("-.->")||e.arrow.includes(".-."));let r=tt(e.fromPort)??tt(e.toPort);const{flow:d,label:m}=Dt(e.arrow);!r&&d&&(r=d);const v=e.linkLabel,g=m??v;o.addLink(o.resolveNodeId(e.from),o.resolveNodeId(e.to),p,g,r)}),a.evolves.forEach(e=>{const p=o.getNode(e.component);if((p==null?void 0:p.y)!==void 0){const r=G(e.target,`Evolve target for "${e.component}"`);o.addTrend(e.component,r,p.y)}}),a.annotations.length>0){const e=a.annotations[0],p=E(e.x,e.y,"Annotations box");o.setAnnotationsBox(p.x,p.y)}a.annotation.forEach(e=>{const p=E(e.x,e.y,`Annotation ${e.number}`);o.addAnnotation(e.number,[{x:p.x,y:p.y}],e.text)}),a.accelerators.forEach(e=>{const p=E(e.x,e.y,`Accelerator "${e.name}"`);o.addAccelerator(e.name,p.x,p.y)}),a.deaccelerators.forEach(e=>{const p=E(e.x,e.y,`Deaccelerator "${e.name}"`);o.addDeaccelerator(e.name,p.x,p.y)})},"populateDb"),at={parser:{yy:void 0},parse:y(async a=>{var p;const o=await Wt("wardley",a);et.debug(o);const e=(p=at.parser)==null?void 0:p.yy;if(!e||typeof e.addNode!="function")throw new 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.");Gt(o,e)},"parse")},F,qt=(F=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={}}addNode(o){const e=this.nodes.get(o.id)??{id:o.id,label:o.label},p={...e,...o,className:o.className??e.className,labelOffsetX:o.labelOffsetX??e.labelOffsetX,labelOffsetY:o.labelOffsetY??e.labelOffsetY};this.nodes.set(o.id,p)}addLink(o){this.links.push(o)}addTrend(o){this.trends.set(o.nodeId,o)}startPipeline(o){this.pipelines.set(o,{nodeId:o,componentIds:[]});const e=this.nodes.get(o);e&&(e.isPipelineParent=!0)}addPipelineComponent(o,e){const p=this.pipelines.get(o);p&&p.componentIds.push(e);const r=this.nodes.get(e);r&&(r.inPipeline=!0)}addAnnotation(o){this.annotations.push(o)}addNote(o){this.notes.push(o)}addAccelerator(o){this.accelerators.push(o)}addDeaccelerator(o){this.deaccelerators.push(o)}setAnnotationsBox(o,e){this.annotationsBox={x:o,y:e}}setAxes(o){this.axes={...this.axes,...o}}setSize(o,e){this.size={width:o,height:e}}getNode(o){return this.nodes.get(o)}resolveNodeId(o){if(this.nodes.has(o))return o;for(const[e,p]of this.nodes)if(p.label===o)return e;return o}build(){const o=[];for(const e of this.nodes.values()){if(typeof e.x!="number"||typeof e.y!="number")throw new Error(`Node "${e.label}" is missing coordinates`);o.push(e)}return{nodes:o,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}},y(F,"WardleyBuilder"),F),b=new qt;function rt(){return V()["wardley-beta"]}y(rt,"getConfig");function ot(a,o,e,p,r,d,m,v,g){b.addNode({id:a,label:o,x:e,y:p,className:r,labelOffsetX:d,labelOffsetY:m,inertia:v,sourceStrategy:g})}y(ot,"addNode");function st(a,o,e=!1,p,r){b.addLink({source:a,target:o,dashed:e,label:p,flow:r})}y(st,"addLink");function nt(a,o,e){b.addTrend({nodeId:a,targetX:o,targetY:e})}y(nt,"addTrend");function it(a,o,e){b.addAnnotation({number:a,coordinates:o,text:e})}y(it,"addAnnotation");function dt(a,o,e){b.addNote({text:a,x:o,y:e})}y(dt,"addNote");function lt(a,o,e){b.addAccelerator({name:a,x:o,y:e})}y(lt,"addAccelerator");function ct(a,o,e){b.addDeaccelerator({name:a,x:o,y:e})}y(ct,"addDeaccelerator");function pt(a,o){b.setAnnotationsBox(a,o)}y(pt,"setAnnotationsBox");function ht(a,o){b.setSize(a,o)}y(ht,"setSize");function xt(a){b.startPipeline(a)}y(xt,"startPipeline");function ft(a,o){b.addPipelineComponent(a,o)}y(ft,"addPipelineComponent");function gt(a){b.setAxes(a)}y(gt,"updateAxes");function ut(a){return b.getNode(a)}y(ut,"getNode");function yt(a){return b.resolveNodeId(a)}y(yt,"resolveNodeId");function mt(){return b.build()}y(mt,"getWardleyData");function wt(){b.clear(),Rt()}y(wt,"clear");var Ht={getConfig:rt,addNode:ot,addLink:st,addTrend:nt,addAnnotation:it,addNote:dt,addAccelerator:lt,addDeaccelerator:ct,setAnnotationsBox:pt,setSize:ht,startPipeline:xt,addPipelineComponent:ft,updateAxes:gt,getNode:ut,resolveNodeId:yt,getWardleyData:mt,clear:wt,setAccTitle:Et,getAccTitle:Xt,setDiagramTitle:At,getDiagramTitle:Tt,getAccDescription:Lt,setAccDescription:zt},jt=["Genesis","Custom Built","Product","Commodity"],Vt=y(()=>{var o,e,p,r,d,m,v,g,L,M,k,N;const{themeVariables:a}=V();return{backgroundColor:((o=a.wardley)==null?void 0:o.backgroundColor)??a.background??"#fff",axisColor:((e=a.wardley)==null?void 0:e.axisColor)??"#000",axisTextColor:((p=a.wardley)==null?void 0:p.axisTextColor)??a.primaryTextColor??"#222",gridColor:((r=a.wardley)==null?void 0:r.gridColor)??"rgba(100, 100, 100, 0.2)",componentFill:((d=a.wardley)==null?void 0:d.componentFill)??"#fff",componentStroke:((m=a.wardley)==null?void 0:m.componentStroke)??"#000",componentLabelColor:((v=a.wardley)==null?void 0:v.componentLabelColor)??a.primaryTextColor??"#222",linkStroke:((g=a.wardley)==null?void 0:g.linkStroke)??"#000",evolutionStroke:((L=a.wardley)==null?void 0:L.evolutionStroke)??"#dc3545",annotationStroke:((M=a.wardley)==null?void 0:M.annotationStroke)??"#000",annotationTextColor:((k=a.wardley)==null?void 0:k.annotationTextColor)??a.primaryTextColor??"#222",annotationFill:((N=a.wardley)==null?void 0:N.annotationFill)??a.background??"#fff"}},"getTheme"),_t=y(()=>{const a=V()["wardley-beta"];return{width:(a==null?void 0:a.width)??900,height:(a==null?void 0:a.height)??600,padding:(a==null?void 0:a.padding)??48,nodeRadius:(a==null?void 0:a.nodeRadius)??6,nodeLabelOffset:(a==null?void 0:a.nodeLabelOffset)??8,axisFontSize:(a==null?void 0:a.axisFontSize)??12,labelFontSize:(a==null?void 0:a.labelFontSize)??10,showGrid:(a==null?void 0:a.showGrid)??!1,useMaxWidth:(a==null?void 0:a.useMaxWidth)??!0}},"getConfigValues"),Zt=y((a,o,e,p)=>{var J,K;et.debug(`Rendering Wardley map
|
|
2
|
+
`+a);const r=_t(),d=Vt(),m=r.nodeRadius*1.6,v=p.db,g=v.getWardleyData(),L=v.getDiagramTitle(),M=((J=g.size)==null?void 0:J.width)??r.width,k=((K=g.size)==null?void 0:K.height)??r.height,N=It(o);N.selectAll("*").remove(),Bt(N,k,M,r.useMaxWidth),N.attr("viewBox",`0 0 ${M} ${k}`);const P=N.append("g").attr("class","wardley-map"),q=N.append("defs");q.append("marker").attr("id",`arrow-${o}`).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",d.evolutionStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-end-${o}`).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",d.linkStroke).attr("stroke","none"),q.append("marker").attr("id",`link-arrow-start-${o}`).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",d.linkStroke).attr("stroke","none"),P.append("rect").attr("class","wardley-background").attr("width",M).attr("height",k).attr("fill",d.backgroundColor);const I=M-r.padding*2,B=k-r.padding*2;L&&P.append("text").attr("class","wardley-title").attr("x",M/2).attr("y",r.padding/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize*1.05).attr("font-weight","bold").attr("text-anchor","middle").attr("dominant-baseline","middle").text(L);const T=y(t=>r.padding+t/100*I,"projectX"),A=y(t=>k-r.padding-t/100*B,"projectY"),O=P.append("g").attr("class","wardley-axes");O.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1),O.append("line").attr("x1",r.padding).attr("x2",r.padding).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.axisColor).attr("stroke-width",1);const kt=g.axes.xLabel??"Evolution",bt=g.axes.yLabel??"Visibility";O.append("text").attr("class","wardley-axis-label wardley-axis-label-x").attr("x",r.padding+I/2).attr("y",k-r.padding/4).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").text(kt),O.append("text").attr("class","wardley-axis-label wardley-axis-label-y").attr("x",r.padding/3).attr("y",r.padding+B/2).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("transform",`rotate(-90 ${r.padding/3} ${r.padding+B/2})`).text(bt);const R=g.axes.stages&&g.axes.stages.length>0?g.axes.stages:jt;if(R.length>0){const t=P.append("g").attr("class","wardley-stages"),n=g.axes.stageBoundaries,s=[];if(n&&n.length===R.length){let i=0;n.forEach(h=>{s.push({start:i,end:h}),i=h})}else{const i=1/R.length;R.forEach((h,l)=>{s.push({start:l*i,end:(l+1)*i})})}R.forEach((i,h)=>{const l=s[h],x=r.padding+l.start*I,f=r.padding+l.end*I,u=(x+f)/2;h>0&&t.append("line").attr("x1",x).attr("x2",x).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke","#000").attr("stroke-width",1).attr("stroke-dasharray","5 5").attr("opacity",.8),t.append("text").attr("class","wardley-stage-label").attr("x",u).attr("y",k-r.padding/1.5).attr("fill",d.axisTextColor).attr("font-size",r.axisFontSize-2).attr("text-anchor","middle").text(i)})}if(r.showGrid){const t=P.append("g").attr("class","wardley-grid");for(let n=1;n<4;n++){const s=n/4,i=r.padding+I*s;t.append("line").attr("x1",i).attr("x2",i).attr("y1",r.padding).attr("y2",k-r.padding).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6"),t.append("line").attr("x1",r.padding).attr("x2",M-r.padding).attr("y1",k-r.padding-B*s).attr("y2",k-r.padding-B*s).attr("stroke",d.gridColor).attr("stroke-dasharray","2 6")}}const c=new Map;if(g.nodes.forEach(t=>{c.set(t.id,{x:T(t.x),y:A(t.y),node:t})}),g.pipelines.length>0){const t=P.append("g").attr("class","wardley-pipelines"),n=P.append("g").attr("class","wardley-pipeline-links");g.pipelines.forEach(s=>{if(s.componentIds.length===0)return;const i=s.componentIds.map(f=>({id:f,pos:c.get(f),node:g.nodes.find(u=>u.id===f)})).filter(f=>f.pos&&f.node).sort((f,u)=>f.node.x-u.node.x);for(let f=0;f<i.length-1;f++){const u=i[f],w=i[f+1];n.append("line").attr("class","wardley-pipeline-evolution-link").attr("x1",u.pos.x).attr("y1",u.pos.y).attr("x2",w.pos.x).attr("y2",w.pos.y).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4")}let h=1/0,l=-1/0,x=0;if(s.componentIds.forEach(f=>{const u=c.get(f);u&&(h=Math.min(h,u.x),l=Math.max(l,u.x),x=u.y)}),h!==1/0&&l!==-1/0){const u=r.nodeRadius*4,w=x-u/2,S=c.get(s.nodeId);if(S){const z=(h+l)/2;S.x=z,S.y=w-m/6}t.append("rect").attr("class","wardley-pipeline-box").attr("x",h-15).attr("y",w).attr("width",l-h+30).attr("height",u).attr("fill","none").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}})}const _=P.append("g").attr("class","wardley-links"),Z=new Map;g.pipelines.forEach(t=>{Z.set(t.nodeId,new Set(t.componentIds))});const U=g.links.filter(t=>{if(!c.has(t.source)||!c.has(t.target))return!1;const n=Z.get(t.target);return!(n!=null&&n.has(t.source))});_.selectAll("line").data(U).enter().append("line").attr("class",t=>`wardley-link${t.dashed?" wardley-link--dashed":""}`).attr("x1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.x+l/f*h}).attr("y1",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.source).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x);return n.y+x/f*h}).attr("x2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.x+l/f*h}).attr("y2",t=>{const n=c.get(t.source),s=c.get(t.target),h=g.nodes.find(u=>u.id===t.target).isPipelineParent?m/Math.sqrt(2):r.nodeRadius,l=n.x-s.x,x=n.y-s.y,f=Math.sqrt(l*l+x*x);return s.y+x/f*h}).attr("stroke",d.linkStroke).attr("stroke-width",1).attr("stroke-dasharray",t=>t.dashed?"6 6":null).attr("marker-end",t=>t.flow==="forward"||t.flow==="bidirectional"?`url(#link-arrow-end-${o})`:null).attr("marker-start",t=>t.flow==="backward"||t.flow==="bidirectional"?`url(#link-arrow-start-${o})`:null),_.selectAll("text").data(U.filter(t=>t.label)).enter().append("text").attr("class","wardley-link-label").attr("x",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=s.y-n.y,l=s.x-n.x,x=Math.sqrt(l*l+h*h),f=8,u=h/x;return i+u*f}).attr("y",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.y+s.y)/2,h=s.x-n.x,l=s.y-n.y,x=Math.sqrt(h*h+l*l),f=8,u=-h/x;return i+u*f}).attr("fill",d.axisTextColor).attr("font-size",r.labelFontSize).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("transform",t=>{const n=c.get(t.source),s=c.get(t.target),i=(n.x+s.x)/2,h=(n.y+s.y)/2,l=s.x-n.x,x=s.y-n.y,f=Math.sqrt(l*l+x*x),u=8,w=x/f,S=-l/f,z=i+w*u,W=h+S*u;let Y=Math.atan2(x,l)*180/Math.PI;return(Y>90||Y<-90)&&(Y+=180),`rotate(${Y} ${z} ${W})`}).text(t=>t.label);const $t=P.append("g").attr("class","wardley-trends"),vt=g.trends.map(t=>{const n=c.get(t.nodeId);if(!n)return null;const s=T(t.targetX),i=A(t.targetY),h=s-n.x,l=i-n.y,x=Math.sqrt(h*h+l*l),f=r.nodeRadius+2,u=x>f?s-h/x*f:s,w=x>f?i-l/x*f:i;return{origin:n,targetX:s,targetY:i,adjustedX2:u,adjustedY2:w}}).filter(t=>t!==null);$t.selectAll("line").data(vt).enter().append("line").attr("class","wardley-trend").attr("x1",t=>t.origin.x).attr("y1",t=>t.origin.y).attr("x2",t=>t.adjustedX2).attr("y2",t=>t.adjustedY2).attr("stroke",d.evolutionStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4").attr("marker-end",`url(#arrow-${o})`);const C=P.append("g").attr("class","wardley-nodes").selectAll("g").data(g.nodes).enter().append("g").attr("class",t=>["wardley-node",t.className?`wardley-node--${t.className}`:""].filter(Boolean).join(" "));C.filter(t=>t.sourceStrategy==="outsource").append("circle").attr("class","wardley-outsource-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#666").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="buy").append("circle").attr("class","wardley-buy-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#ccc").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.sourceStrategy==="build").append("circle").attr("class","wardley-build-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","#eee").attr("stroke","#000").attr("stroke-width",1);const X=C.filter(t=>t.sourceStrategy==="market");X.append("circle").attr("class","wardley-market-overlay").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius*2).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>!t.isPipelineParent&&t.sourceStrategy!=="market"&&t.className!=="anchor").append("circle").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y).attr("r",r.nodeRadius).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1);const H=r.nodeRadius*.7,$=r.nodeRadius*1.2;if(X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x).attr("y1",t=>c.get(t.id).y-$).attr("x2",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y2",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("line").attr("class","wardley-market-line").attr("x1",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("y1",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("x2",t=>c.get(t.id).x).attr("y2",t=>c.get(t.id).y-$).attr("stroke",d.componentStroke).attr("stroke-width",1),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x).attr("cy",t=>c.get(t.id).y-$).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x-$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),X.append("circle").attr("class","wardley-market-dot").attr("cx",t=>c.get(t.id).x+$*Math.cos(Math.PI/6)).attr("cy",t=>c.get(t.id).y+$*Math.sin(Math.PI/6)).attr("r",H).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",2),C.filter(t=>t.isPipelineParent===!0).append("rect").attr("x",t=>c.get(t.id).x-m/2).attr("y",t=>c.get(t.id).y-m/2).attr("width",m).attr("height",m).attr("fill",d.componentFill).attr("stroke",d.componentStroke).attr("stroke-width",1),C.filter(t=>t.inertia===!0).append("line").attr("class","wardley-inertia").attr("x1",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y1",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y-s/2}).attr("x2",t=>{const n=c.get(t.id);let s=t.isPipelineParent?m/2+15:r.nodeRadius+15;return t.sourceStrategy&&(s+=r.nodeRadius+10),n.x+s}).attr("y2",t=>{const n=c.get(t.id),s=t.isPipelineParent?m:r.nodeRadius*2;return n.y+s/2}).attr("stroke",d.componentStroke).attr("stroke-width",6),C.append("text").attr("x",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetX!==void 0?n.x+t.labelOffsetX:n.x;let s=r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetX===void 0&&(s+=10);const i=t.labelOffsetX??s;return n.x+i}).attr("y",t=>{const n=c.get(t.id);if(t.className==="anchor")return t.labelOffsetY!==void 0?n.y+t.labelOffsetY:n.y-3;let s=-r.nodeLabelOffset;t.sourceStrategy&&t.labelOffsetY===void 0&&(s-=10);const i=t.labelOffsetY??s;return n.y+i}).attr("class","wardley-node-label").attr("fill",t=>t.className==="evolved"?d.evolutionStroke:t.className==="anchor"?"#000":d.componentLabelColor).attr("font-size",r.labelFontSize).attr("font-weight",t=>t.className==="anchor"?"bold":"normal").attr("text-anchor",t=>t.className==="anchor"?"middle":"start").attr("dominant-baseline",t=>t.className==="anchor"?"middle":"auto").text(t=>t.label),g.annotations.length>0){const t=P.append("g").attr("class","wardley-annotations");if(g.annotations.forEach(n=>{const s=n.coordinates.map(i=>({x:T(i.x),y:A(i.y)}));if(s.length>1)for(let i=0;i<s.length-1;i++)t.append("line").attr("class","wardley-annotation-line").attr("x1",s[i].x).attr("y1",s[i].y).attr("x2",s[i+1].x).attr("y2",s[i+1].y).attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("stroke-dasharray","4 4");s.forEach(i=>{const h=t.append("g").attr("class","wardley-annotation");h.append("circle").attr("cx",i.x).attr("cy",i.y).attr("r",10).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5),h.append("text").attr("x",i.x).attr("y",i.y).attr("text-anchor","middle").attr("dominant-baseline","central").attr("font-size",10).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.number)})}),g.annotationsBox){let n=T(g.annotationsBox.x),s=A(g.annotationsBox.y);const i=10,h=16,l=11,x=t.append("g").attr("class","wardley-annotations-box"),f=[...g.annotations].filter(w=>w.text).sort((w,S)=>w.number-S.number),u=[];if(f.forEach((w,S)=>{const z=x.append("text").attr("x",n+i).attr("y",s+i+(S+1)*h).attr("font-size",l).attr("fill",d.axisTextColor).attr("text-anchor","start").attr("dominant-baseline","middle").text(`${w.number}. ${w.text}`);u.push(z)}),u.length>0){let w=0,S=0;u.forEach(j=>{const D=j.node(),Nt=D.getComputedTextLength();w=Math.max(w,Nt);const Ct=D.getBBox();S=Math.max(S,Ct.height)});const z=w+i*2+105,W=f.length*h+i*2+S/2,Y=r.padding,Pt=M-r.padding-z,St=r.padding,Mt=k-r.padding-W;n=Math.max(Y,Math.min(n,Pt)),s=Math.max(St,Math.min(s,Mt)),u.forEach((j,D)=>{j.attr("x",n+i).attr("y",s+i+(D+1)*h)}),x.insert("rect","text").attr("x",n).attr("y",s).attr("width",z).attr("height",W).attr("fill","white").attr("stroke",d.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}}}if(g.notes.length>0){const t=P.append("g").attr("class","wardley-notes");g.notes.forEach(n=>{const s=T(n.x),i=A(n.y);t.append("text").attr("x",s).attr("y",i).attr("text-anchor","start").attr("font-size",11).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.text)})}if(g.accelerators.length>0){const t=P.append("g").attr("class","wardley-accelerators");g.accelerators.forEach(n=>{const s=T(n.x),i=A(n.y),h=60,l=30,x=20,f=`
|
|
3
|
+
M ${s} ${i-l/2}
|
|
4
|
+
L ${s+h-x} ${i-l/2}
|
|
5
|
+
L ${s+h-x} ${i-l/2-8}
|
|
6
|
+
L ${s+h} ${i}
|
|
7
|
+
L ${s+h-x} ${i+l/2+8}
|
|
8
|
+
L ${s+h-x} ${i+l/2}
|
|
9
|
+
L ${s} ${i+l/2}
|
|
10
|
+
Z
|
|
11
|
+
`;t.append("path").attr("d",f).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),t.append("text").attr("x",s+h/2).attr("y",i+l/2+15).attr("text-anchor","middle").attr("font-size",10).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.name)})}if(g.deaccelerators.length>0){const t=P.append("g").attr("class","wardley-deaccelerators");g.deaccelerators.forEach(n=>{const s=T(n.x),i=A(n.y),h=60,l=30,x=20,f=`
|
|
12
|
+
M ${s+h} ${i-l/2}
|
|
13
|
+
L ${s+x} ${i-l/2}
|
|
14
|
+
L ${s+x} ${i-l/2-8}
|
|
15
|
+
L ${s} ${i}
|
|
16
|
+
L ${s+x} ${i+l/2+8}
|
|
17
|
+
L ${s+x} ${i+l/2}
|
|
18
|
+
L ${s+h} ${i+l/2}
|
|
19
|
+
Z
|
|
20
|
+
`;t.append("path").attr("d",f).attr("fill","white").attr("stroke",d.componentStroke).attr("stroke-width",1),t.append("text").attr("x",s+h/2).attr("y",i+l/2+15).attr("text-anchor","middle").attr("font-size",10).attr("fill",d.axisTextColor).attr("font-weight","bold").text(n.name)})}},"draw"),Ut={draw:Zt},Jt=y(({wardley:a}={})=>{const o=Yt(),e=Ft(),p=Q(o,e.themeVariables),r=Q(p.wardley,a);return`
|
|
21
|
+
.wardley-background {
|
|
22
|
+
fill: ${r.backgroundColor};
|
|
23
|
+
}
|
|
24
|
+
.wardley-axes line, .wardley-axes path {
|
|
25
|
+
stroke: ${r.axisColor};
|
|
26
|
+
}
|
|
27
|
+
.wardley-axis-label {
|
|
28
|
+
fill: ${r.axisTextColor};
|
|
29
|
+
}
|
|
30
|
+
.wardley-stage-label {
|
|
31
|
+
fill: ${r.axisTextColor};
|
|
32
|
+
}
|
|
33
|
+
.wardley-grid line {
|
|
34
|
+
stroke: ${r.gridColor};
|
|
35
|
+
}
|
|
36
|
+
.wardley-node circle {
|
|
37
|
+
fill: ${r.componentFill};
|
|
38
|
+
stroke: ${r.componentStroke};
|
|
39
|
+
}
|
|
40
|
+
.wardley-node-label {
|
|
41
|
+
fill: ${r.componentLabelColor};
|
|
42
|
+
}
|
|
43
|
+
.wardley-link {
|
|
44
|
+
stroke: ${r.linkStroke};
|
|
45
|
+
}
|
|
46
|
+
.wardley-link--dashed {
|
|
47
|
+
stroke-dasharray: 4 4;
|
|
48
|
+
}
|
|
49
|
+
.wardley-link-label {
|
|
50
|
+
fill: ${r.axisTextColor};
|
|
51
|
+
}
|
|
52
|
+
.wardley-trend line {
|
|
53
|
+
stroke: ${r.evolutionStroke};
|
|
54
|
+
}
|
|
55
|
+
.wardley-annotation-line {
|
|
56
|
+
stroke: ${r.annotationStroke};
|
|
57
|
+
}
|
|
58
|
+
.wardley-annotation circle {
|
|
59
|
+
fill: ${r.annotationFill};
|
|
60
|
+
stroke: ${r.annotationStroke};
|
|
61
|
+
}
|
|
62
|
+
.wardley-annotation text {
|
|
63
|
+
fill: ${r.annotationTextColor};
|
|
64
|
+
}
|
|
65
|
+
.wardley-annotations-box rect {
|
|
66
|
+
fill: ${r.annotationFill};
|
|
67
|
+
stroke: ${r.annotationStroke};
|
|
68
|
+
}
|
|
69
|
+
.wardley-annotations-box text {
|
|
70
|
+
fill: ${r.annotationTextColor};
|
|
71
|
+
}
|
|
72
|
+
.wardley-pipeline-box {
|
|
73
|
+
stroke: ${r.componentStroke};
|
|
74
|
+
}
|
|
75
|
+
.wardley-notes text {
|
|
76
|
+
fill: ${r.axisTextColor};
|
|
77
|
+
}
|
|
78
|
+
`},"styles"),ae={parser:at,db:Ht,renderer:Ut,styles:Jt};export{ae as diagram};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{b1 as gi,a2 as xi,a7 as Xt,b4 as di,a3 as fi,b2 as pi,b as a,aF as Yt,b0 as mi,F as yi,u as bi,a4 as _t,a_ as Ai,t as Nt,T as wi,ag as Ci,B as Si,aC as Wt}from"./index-
|
|
1
|
+
import{b1 as gi,a2 as xi,a7 as Xt,b4 as di,a3 as fi,b2 as pi,b as a,aF as Yt,b0 as mi,F as yi,u as bi,a4 as _t,a_ as Ai,t as Nt,T as wi,ag as Ci,B as Si,aC as Wt}from"./index-BGVEOJln.js";import{i as _i}from"./init-Gi6I4Gst.js";import{o as ki}from"./ordinal-Cboi1Yqb.js";import{l as zt}from"./linear-CxTWz0e9.js";import"./defaultLocale-CrowFXzY.js";function Ti(e,t,i){e=+e,t=+t,i=(n=arguments.length)<2?(t=e,e=0,1):n<3?1:+i;for(var s=-1,n=Math.max(0,Math.ceil((t-e)/i))|0,o=new Array(n);++s<n;)o[s]=e+s*i;return o}function bt(){var e=ki().unknown(void 0),t=e.domain,i=e.range,s=0,n=1,o,u,p=!1,f=0,R=0,P=.5;delete e.unknown;function _(){var y=t().length,E=n<s,v=E?n:s,L=E?s:n;o=(L-v)/Math.max(1,y-f+R*2),p&&(o=Math.floor(o)),v+=(L-v-o*(y-f))*P,u=o*(1-f),p&&(v=Math.round(v),u=Math.round(u));var M=Ti(y).map(function(m){return v+o*m});return i(E?M.reverse():M)}return e.domain=function(y){return arguments.length?(t(y),_()):t()},e.range=function(y){return arguments.length?([s,n]=y,s=+s,n=+n,_()):[s,n]},e.rangeRound=function(y){return[s,n]=y,s=+s,n=+n,p=!0,_()},e.bandwidth=function(){return u},e.step=function(){return o},e.round=function(y){return arguments.length?(p=!!y,_()):p},e.padding=function(y){return arguments.length?(f=Math.min(1,R=+y),_()):f},e.paddingInner=function(y){return arguments.length?(f=Math.min(1,y),_()):f},e.paddingOuter=function(y){return arguments.length?(R=+y,_()):R},e.align=function(y){return arguments.length?(P=Math.max(0,Math.min(1,y)),_()):P},e.copy=function(){return bt(t(),[s,n]).round(p).paddingInner(f).paddingOuter(R).align(P)},_i.apply(_(),arguments)}var At=(function(){var e=a(function(F,h,c,g){for(c=c||{},g=F.length;g--;c[F[g]]=h);return c},"o"),t=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],n=[1,5],o=[1,6],u=[1,7],p=[1,5,10,12,14,16,18,19,21,23,34,35,36],f=[1,25],R=[1,26],P=[1,28],_=[1,29],y=[1,30],E=[1,31],v=[1,32],L=[1,33],M=[1,34],m=[1,35],T=[1,36],l=[1,37],W=[1,43],O=[1,42],X=[1,47],Y=[1,50],S=[1,10,12,14,16,18,19,21,23,34,35,36],U=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],b=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],w=[1,64],V={trace:a(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,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$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",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"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],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:a(function(h,c,g,x,C,r,rt){var d=r.length-1;switch(C){case 5:x.setOrientation(r[d]);break;case 9:x.setDiagramTitle(r[d].text.trim());break;case 12:x.setLineData({text:"",type:"text"},r[d]);break;case 13:x.setLineData(r[d-1],r[d]);break;case 14:x.setBarData({text:"",type:"text"},r[d]);break;case 15:x.setBarData(r[d-1],r[d]);break;case 16:this.$=r[d].trim(),x.setAccTitle(this.$);break;case 17:case 18:this.$=r[d].trim(),x.setAccDescription(this.$);break;case 19:this.$=r[d-1];break;case 20:this.$=[Number(r[d-2]),...r[d]];break;case 21:this.$=[Number(r[d])];break;case 22:x.setXAxisTitle(r[d]);break;case 23:x.setXAxisTitle(r[d-1]);break;case 24:x.setXAxisTitle({type:"text",text:""});break;case 25:x.setXAxisBand(r[d]);break;case 26:x.setXAxisRangeData(Number(r[d-2]),Number(r[d]));break;case 27:this.$=r[d-1];break;case 28:this.$=[r[d-2],...r[d]];break;case 29:this.$=[r[d]];break;case 30:x.setYAxisTitle(r[d]);break;case 31:x.setYAxisTitle(r[d-1]);break;case 32:x.setYAxisTitle({type:"text",text:""});break;case 33:x.setYAxisRangeData(Number(r[d-2]),Number(r[d]));break;case 37:this.$={text:r[d],type:"text"};break;case 38:this.$={text:r[d],type:"text"};break;case 39:this.$={text:r[d],type:"markdown"};break;case 40:this.$=r[d];break;case 41:this.$=r[d-1]+""+r[d];break}},"anonymous"),table:[e(t,i,{3:1,4:2,7:4,5:s,34:n,35:o,36:u}),{1:[3]},e(t,i,{4:2,7:4,3:8,5:s,34:n,35:o,36:u}),e(t,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:n,35:o,36:u}),{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]},e(p,[2,34]),e(p,[2,35]),e(p,[2,36]),{1:[2,1]},e(t,i,{4:2,7:4,3:21,5:s,34:n,35:o,36:u}),{1:[2,3]},e(p,[2,5]),e(t,[2,7],{4:22,34:n,35:o,36:u}),{11:23,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},{11:39,13:38,24:W,27:O,29:40,30:41,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},{11:45,15:44,27:X,33:46,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},{11:49,17:48,24:Y,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},{11:52,17:51,24:Y,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},{20:[1,53]},{22:[1,54]},e(S,[2,18]),{1:[2,2]},e(S,[2,8]),e(S,[2,9]),e(U,[2,37],{40:55,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l}),e(U,[2,38]),e(U,[2,39]),e(b,[2,40]),e(b,[2,42]),e(b,[2,43]),e(b,[2,44]),e(b,[2,45]),e(b,[2,46]),e(b,[2,47]),e(b,[2,48]),e(b,[2,49]),e(b,[2,50]),e(b,[2,51]),e(S,[2,10]),e(S,[2,22],{30:41,29:56,24:W,27:O}),e(S,[2,24]),e(S,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},e(S,[2,11]),e(S,[2,30],{33:60,27:X}),e(S,[2,32]),{31:[1,61]},e(S,[2,12]),{17:62,24:Y},{25:63,27:w},e(S,[2,14]),{17:65,24:Y},e(S,[2,16]),e(S,[2,17]),e(b,[2,41]),e(S,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},e(S,[2,31]),{27:[1,69]},e(S,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},e(S,[2,15]),e(S,[2,26]),e(S,[2,27]),{11:59,32:72,37:24,38:f,39:R,40:27,41:P,42:_,43:y,44:E,45:v,46:L,47:M,48:m,49:T,50:l},e(S,[2,33]),e(S,[2,19]),{25:73,27:w},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:a(function(h,c){if(c.recoverable)this.trace(h);else{var g=new Error(h);throw g.hash=c,g}},"parseError"),parse:a(function(h){var c=this,g=[0],x=[],C=[null],r=[],rt=this.table,d="",ct=0,Mt=0,hi=2,It=1,li=r.slice.call(arguments,1),D=Object.create(this.lexer),$={yy:{}};for(var ft in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ft)&&($.yy[ft]=this.yy[ft]);D.setInput(h,$.yy),$.yy.lexer=D,$.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var pt=D.yylloc;r.push(pt);var ci=D.options&&D.options.ranges;typeof $.yy.parseError=="function"?this.parseError=$.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ui(B){g.length=g.length-2*B,C.length=C.length-B,r.length=r.length-B}a(ui,"popStack");function Vt(){var B;return B=x.pop()||D.lex()||It,typeof B!="number"&&(B instanceof Array&&(x=B,B=x.pop()),B=c.symbols_[B]||B),B}a(Vt,"lex");for(var I,q,z,mt,G={},ut,N,Bt,gt;;){if(q=g[g.length-1],this.defaultActions[q]?z=this.defaultActions[q]:((I===null||typeof I>"u")&&(I=Vt()),z=rt[q]&&rt[q][I]),typeof z>"u"||!z.length||!z[0]){var yt="";gt=[];for(ut in rt[q])this.terminals_[ut]&&ut>hi&>.push("'"+this.terminals_[ut]+"'");D.showPosition?yt="Parse error on line "+(ct+1)+`:
|
|
2
2
|
`+D.showPosition()+`
|
|
3
3
|
Expecting `+gt.join(", ")+", got '"+(this.terminals_[I]||I)+"'":yt="Parse error on line "+(ct+1)+": Unexpected "+(I==It?"end of input":"'"+(this.terminals_[I]||I)+"'"),this.parseError(yt,{text:D.match,token:this.terminals_[I]||I,line:D.yylineno,loc:pt,expected:gt})}if(z[0]instanceof Array&&z.length>1)throw new Error("Parse Error: multiple actions possible at state: "+q+", token: "+I);switch(z[0]){case 1:g.push(I),C.push(D.yytext),r.push(D.yylloc),g.push(z[1]),I=null,Mt=D.yyleng,d=D.yytext,ct=D.yylineno,pt=D.yylloc;break;case 2:if(N=this.productions_[z[1]][1],G.$=C[C.length-N],G._$={first_line:r[r.length-(N||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(N||1)].first_column,last_column:r[r.length-1].last_column},ci&&(G._$.range=[r[r.length-(N||1)].range[0],r[r.length-1].range[1]]),mt=this.performAction.apply(G,[d,Mt,ct,$.yy,z[1],C,r].concat(li)),typeof mt<"u")return mt;N&&(g=g.slice(0,-1*N*2),C=C.slice(0,-1*N),r=r.slice(0,-1*N)),g.push(this.productions_[z[1]][0]),C.push(G.$),r.push(G._$),Bt=rt[g[g.length-2]][g[g.length-1]],g.push(Bt);break;case 3:return!0}}return!0},"parse")},k=(function(){var F={EOF:1,parseError:a(function(c,g){if(this.yy.parser)this.yy.parser.parseError(c,g);else throw new Error(c)},"parseError"),setInput:a(function(h,c){return this.yy=c||this.yy||{},this._input=h,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:a(function(){var h=this._input[0];this.yytext+=h,this.yyleng++,this.offset++,this.match+=h,this.matched+=h;var c=h.match(/(?:\r\n?|\n).*/g);return c?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),h},"input"),unput:a(function(h){var c=h.length,g=h.split(/(?:\r\n?|\n)/g);this._input=h+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-c),this.offset-=c;var x=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),g.length-1&&(this.yylineno-=g.length-1);var C=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:g?(g.length===x.length?this.yylloc.first_column:0)+x[x.length-g.length].length-g[0].length:this.yylloc.first_column-c},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-c]),this.yyleng=this.yytext.length,this},"unput"),more:a(function(){return this._more=!0,this},"more"),reject:a(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:a(function(h){this.unput(this.match.slice(h))},"less"),pastInput:a(function(){var h=this.matched.substr(0,this.matched.length-this.match.length);return(h.length>20?"...":"")+h.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:a(function(){var h=this.match;return h.length<20&&(h+=this._input.substr(0,20-h.length)),(h.substr(0,20)+(h.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:a(function(){var h=this.pastInput(),c=new Array(h.length+1).join("-");return h+this.upcomingInput()+`
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
6
|
<title>AggRoot</title>
|
|
7
|
-
<script type="module" crossorigin src="/assets/index-
|
|
7
|
+
<script type="module" crossorigin src="/assets/index-BGVEOJln.js"></script>
|
|
8
8
|
<link rel="stylesheet" crossorigin href="/assets/index-aC35iubs.css">
|
|
9
9
|
</head>
|
|
10
10
|
<body>
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{bm as ln,aj as an,X as y,be as tn,I as z,b9 as b,aJ as _,d as un,aP as rn,ba as F,n as o,G as O,k as sn,e as on,aI as fn}from"./index-BvC6gdHx.js";function cn(l){return l.innerRadius}function yn(l){return l.outerRadius}function gn(l){return l.startAngle}function dn(l){return l.endAngle}function mn(l){return l&&l.padAngle}function pn(l,h,q,w,v,A,S,a){var D=q-l,i=w-h,n=S-v,d=a-A,u=d*D-n*i;if(!(u*u<y))return u=(n*(h-A)-d*(l-v))/u,[l+u*D,h+u*i]}function Q(l,h,q,w,v,A,S){var a=l-q,D=h-w,i=(S?A:-A)/F(a*a+D*D),n=i*D,d=-i*a,u=l+n,s=h+d,f=q+n,c=w+d,X=(u+f)/2,t=(s+c)/2,m=f-u,g=c-s,R=m*m+g*g,T=v-A,P=u*c-f*s,E=(g<0?-1:1)*F(fn(0,T*T*R-P*P)),G=(P*g-m*E)/R,J=(-P*m-g*E)/R,I=(P*g+m*E)/R,p=(-P*m+g*E)/R,x=G-X,e=J-t,r=I-X,k=p-t;return x*x+e*e>r*r+k*k&&(G=I,J=p),{cx:G,cy:J,x01:-n,y01:-d,x11:G*(v/T-1),y11:J*(v/T-1)}}function hn(){var l=cn,h=yn,q=O(0),w=null,v=gn,A=dn,S=mn,a=null,D=ln(i);function i(){var n,d,u=+l.apply(this,arguments),s=+h.apply(this,arguments),f=v.apply(this,arguments)-an,c=A.apply(this,arguments)-an,X=un(c-f),t=c>f;if(a||(a=n=D()),s<u&&(d=s,s=u,u=d),!(s>y))a.moveTo(0,0);else if(X>tn-y)a.moveTo(s*z(f),s*b(f)),a.arc(0,0,s,f,c,!t),u>y&&(a.moveTo(u*z(c),u*b(c)),a.arc(0,0,u,c,f,t));else{var m=f,g=c,R=f,T=c,P=X,E=X,G=S.apply(this,arguments)/2,J=G>y&&(w?+w.apply(this,arguments):F(u*u+s*s)),I=_(un(s-u)/2,+q.apply(this,arguments)),p=I,x=I,e,r;if(J>y){var k=sn(J/u*b(G)),H=sn(J/s*b(G));(P-=k*2)>y?(k*=t?1:-1,R+=k,T-=k):(P=0,R=T=(f+c)/2),(E-=H*2)>y?(H*=t?1:-1,m+=H,g-=H):(E=0,m=g=(f+c)/2)}var B=s*z(m),C=s*b(m),K=u*z(T),L=u*b(T);if(I>y){var M=s*z(g),N=s*b(g),U=u*z(R),V=u*b(R),j;if(X<rn)if(j=pn(B,C,U,V,M,N,K,L)){var W=B-j[0],Y=C-j[1],Z=M-j[0],$=N-j[1],nn=1/b(on((W*Z+Y*$)/(F(W*W+Y*Y)*F(Z*Z+$*$)))/2),en=F(j[0]*j[0]+j[1]*j[1]);p=_(I,(u-en)/(nn-1)),x=_(I,(s-en)/(nn+1))}else p=x=0}E>y?x>y?(e=Q(U,V,B,C,s,x,t),r=Q(M,N,K,L,s,x,t),a.moveTo(e.cx+e.x01,e.cy+e.y01),x<I?a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,s,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),!t),a.arc(r.cx,r.cy,x,o(r.y11,r.x11),o(r.y01,r.x01),!t))):(a.moveTo(B,C),a.arc(0,0,s,m,g,!t)):a.moveTo(B,C),!(u>y)||!(P>y)?a.lineTo(K,L):p>y?(e=Q(K,L,M,N,u,-p,t),r=Q(B,C,U,V,u,-p,t),a.lineTo(e.cx+e.x01,e.cy+e.y01),p<I?a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,u,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),t),a.arc(r.cx,r.cy,p,o(r.y11,r.x11),o(r.y01,r.x01),!t))):a.arc(0,0,u,T,R,t)}if(a.closePath(),n)return a=null,n+""||null}return i.centroid=function(){var n=(+l.apply(this,arguments)+ +h.apply(this,arguments))/2,d=(+v.apply(this,arguments)+ +A.apply(this,arguments))/2-rn/2;return[z(d)*n,b(d)*n]},i.innerRadius=function(n){return arguments.length?(l=typeof n=="function"?n:O(+n),i):l},i.outerRadius=function(n){return arguments.length?(h=typeof n=="function"?n:O(+n),i):h},i.cornerRadius=function(n){return arguments.length?(q=typeof n=="function"?n:O(+n),i):q},i.padRadius=function(n){return arguments.length?(w=n==null?null:typeof n=="function"?n:O(+n),i):w},i.startAngle=function(n){return arguments.length?(v=typeof n=="function"?n:O(+n),i):v},i.endAngle=function(n){return arguments.length?(A=typeof n=="function"?n:O(+n),i):A},i.padAngle=function(n){return arguments.length?(S=typeof n=="function"?n:O(+n),i):S},i.context=function(n){return arguments.length?(a=n??null,i):a},i}export{hn as d};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{bm as ln,aj as an,X as y,be as tn,I as z,b9 as b,aJ as _,d as un,aP as rn,ba as F,n as o,G as O,k as sn,e as on,aI as fn}from"./index-BCGYoU3m.js";function cn(l){return l.innerRadius}function yn(l){return l.outerRadius}function gn(l){return l.startAngle}function dn(l){return l.endAngle}function mn(l){return l&&l.padAngle}function pn(l,h,q,w,v,A,S,a){var D=q-l,i=w-h,n=S-v,d=a-A,u=d*D-n*i;if(!(u*u<y))return u=(n*(h-A)-d*(l-v))/u,[l+u*D,h+u*i]}function Q(l,h,q,w,v,A,S){var a=l-q,D=h-w,i=(S?A:-A)/F(a*a+D*D),n=i*D,d=-i*a,u=l+n,s=h+d,f=q+n,c=w+d,X=(u+f)/2,t=(s+c)/2,m=f-u,g=c-s,R=m*m+g*g,T=v-A,P=u*c-f*s,E=(g<0?-1:1)*F(fn(0,T*T*R-P*P)),G=(P*g-m*E)/R,J=(-P*m-g*E)/R,I=(P*g+m*E)/R,p=(-P*m+g*E)/R,x=G-X,e=J-t,r=I-X,k=p-t;return x*x+e*e>r*r+k*k&&(G=I,J=p),{cx:G,cy:J,x01:-n,y01:-d,x11:G*(v/T-1),y11:J*(v/T-1)}}function hn(){var l=cn,h=yn,q=O(0),w=null,v=gn,A=dn,S=mn,a=null,D=ln(i);function i(){var n,d,u=+l.apply(this,arguments),s=+h.apply(this,arguments),f=v.apply(this,arguments)-an,c=A.apply(this,arguments)-an,X=un(c-f),t=c>f;if(a||(a=n=D()),s<u&&(d=s,s=u,u=d),!(s>y))a.moveTo(0,0);else if(X>tn-y)a.moveTo(s*z(f),s*b(f)),a.arc(0,0,s,f,c,!t),u>y&&(a.moveTo(u*z(c),u*b(c)),a.arc(0,0,u,c,f,t));else{var m=f,g=c,R=f,T=c,P=X,E=X,G=S.apply(this,arguments)/2,J=G>y&&(w?+w.apply(this,arguments):F(u*u+s*s)),I=_(un(s-u)/2,+q.apply(this,arguments)),p=I,x=I,e,r;if(J>y){var k=sn(J/u*b(G)),H=sn(J/s*b(G));(P-=k*2)>y?(k*=t?1:-1,R+=k,T-=k):(P=0,R=T=(f+c)/2),(E-=H*2)>y?(H*=t?1:-1,m+=H,g-=H):(E=0,m=g=(f+c)/2)}var B=s*z(m),C=s*b(m),K=u*z(T),L=u*b(T);if(I>y){var M=s*z(g),N=s*b(g),U=u*z(R),V=u*b(R),j;if(X<rn)if(j=pn(B,C,U,V,M,N,K,L)){var W=B-j[0],Y=C-j[1],Z=M-j[0],$=N-j[1],nn=1/b(on((W*Z+Y*$)/(F(W*W+Y*Y)*F(Z*Z+$*$)))/2),en=F(j[0]*j[0]+j[1]*j[1]);p=_(I,(u-en)/(nn-1)),x=_(I,(s-en)/(nn+1))}else p=x=0}E>y?x>y?(e=Q(U,V,B,C,s,x,t),r=Q(M,N,K,L,s,x,t),a.moveTo(e.cx+e.x01,e.cy+e.y01),x<I?a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,s,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),!t),a.arc(r.cx,r.cy,x,o(r.y11,r.x11),o(r.y01,r.x01),!t))):(a.moveTo(B,C),a.arc(0,0,s,m,g,!t)):a.moveTo(B,C),!(u>y)||!(P>y)?a.lineTo(K,L):p>y?(e=Q(K,L,M,N,u,-p,t),r=Q(B,C,U,V,u,-p,t),a.lineTo(e.cx+e.x01,e.cy+e.y01),p<I?a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,u,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),t),a.arc(r.cx,r.cy,p,o(r.y11,r.x11),o(r.y01,r.x01),!t))):a.arc(0,0,u,T,R,t)}if(a.closePath(),n)return a=null,n+""||null}return i.centroid=function(){var n=(+l.apply(this,arguments)+ +h.apply(this,arguments))/2,d=(+v.apply(this,arguments)+ +A.apply(this,arguments))/2-rn/2;return[z(d)*n,b(d)*n]},i.innerRadius=function(n){return arguments.length?(l=typeof n=="function"?n:O(+n),i):l},i.outerRadius=function(n){return arguments.length?(h=typeof n=="function"?n:O(+n),i):h},i.cornerRadius=function(n){return arguments.length?(q=typeof n=="function"?n:O(+n),i):q},i.padRadius=function(n){return arguments.length?(w=n==null?null:typeof n=="function"?n:O(+n),i):w},i.startAngle=function(n){return arguments.length?(v=typeof n=="function"?n:O(+n),i):v},i.endAngle=function(n){return arguments.length?(A=typeof n=="function"?n:O(+n),i):A},i.padAngle=function(n){return arguments.length?(S=typeof n=="function"?n:O(+n),i):S},i.context=function(n){return arguments.length?(a=n??null,i):a},i}export{hn as d};
|