mio-previewer 0.1.2 → 0.1.4
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/AlertPlugin-B74_-nlo.cjs +3 -0
- package/dist/AlertPlugin-DUG0ldg_.js +66 -0
- package/dist/{MdRenderer.vue_vue_type_style_index_0_lang-ClzqKjX4.js → MdRenderer.vue_vue_type_style_index_0_lang-B26E5SLd.js} +1 -1
- package/dist/{MdRenderer.vue_vue_type_style_index_0_lang-Dpnz3CdM.cjs → MdRenderer.vue_vue_type_style_index_0_lang-CT8VuqF6.cjs} +1 -1
- package/dist/{_basePickBy-nvL1-X4h.js → _basePickBy-ClXR16YL.js} +11 -11
- package/dist/_basePickBy-wjzVR2ZI.cjs +1 -0
- package/dist/_baseUniq-BtmrXn_-.cjs +1 -0
- package/dist/{_baseUniq-Cwhfu1XM.js → _baseUniq-BvAvxwqe.js} +13 -13
- package/dist/arc-CBMtpv9r.cjs +1 -0
- package/dist/{arc-C9I4pYLv.js → arc-Hx3N9DvE.js} +1 -1
- package/dist/{architecture-O4VJ6CD3-dKuizgWO.cjs → architecture-O4VJ6CD3-BNArGrzK.cjs} +1 -1
- package/dist/{architecture-O4VJ6CD3-D00QJU0o.js → architecture-O4VJ6CD3-xCUefH5y.js} +1 -1
- package/dist/{architectureDiagram-VXUJARFQ-VWr1UuPv.js → architectureDiagram-VXUJARFQ-B6mJb2i9.js} +20 -21
- package/dist/architectureDiagram-VXUJARFQ-BJuzZIv9.cjs +36 -0
- package/dist/{blockDiagram-VD42YOAC-DuC96I2Q.js → blockDiagram-VD42YOAC-BGxFHnMs.js} +5 -5
- package/dist/{blockDiagram-VD42YOAC-EC2x5LwN.cjs → blockDiagram-VD42YOAC-CG3089Xu.cjs} +1 -1
- package/dist/{c4Diagram-YG6GDRKO-Dm5d0BWL.cjs → c4Diagram-YG6GDRKO-Cmg_2WS3.cjs} +1 -1
- package/dist/{c4Diagram-YG6GDRKO-OB8wIuF8.js → c4Diagram-YG6GDRKO-Rr7zONcv.js} +2 -2
- package/dist/channel-BleEicRr.cjs +1 -0
- package/dist/{channel-C-uR528Z.js → channel-DgGKpNRA.js} +1 -1
- package/dist/{chunk-4BX2VUAB-j8LeaMvy.js → chunk-4BX2VUAB-BbICN0Ec.js} +1 -1
- package/dist/chunk-4BX2VUAB-Bt9zCVip.cjs +1 -0
- package/dist/chunk-55IACEB6-CBJvnwMn.cjs +1 -0
- package/dist/{chunk-55IACEB6-IYAIzfR4.js → chunk-55IACEB6-DYOSrdgH.js} +1 -1
- package/dist/{chunk-B4BG7PRW-DB5df3Iz.js → chunk-B4BG7PRW-TxrPoDdp.js} +4 -4
- package/dist/{chunk-B4BG7PRW-CpqTB0S5.cjs → chunk-B4BG7PRW-l7q-a31H.cjs} +1 -1
- package/dist/{chunk-DI55MBZ5-wqsoqtNw.cjs → chunk-DI55MBZ5-Bp0pNyM4.cjs} +1 -1
- package/dist/{chunk-DI55MBZ5-BoFZpvY3.js → chunk-DI55MBZ5-CsB2AXBx.js} +3 -3
- package/dist/{chunk-FMBD7UC4-BZS_4hun.cjs → chunk-FMBD7UC4-BcpCv0n4.cjs} +1 -1
- package/dist/{chunk-FMBD7UC4-CdmoYYnM.js → chunk-FMBD7UC4-D5PKNbki.js} +1 -1
- package/dist/chunk-QN33PNHL-B1Px0282.cjs +1 -0
- package/dist/{chunk-QN33PNHL-BuyP9RXS.js → chunk-QN33PNHL-B5zdVrte.js} +1 -1
- package/dist/{chunk-QZHKN3VN-15dJyQk0.js → chunk-QZHKN3VN-C-Vfb6xz.js} +1 -1
- package/dist/chunk-QZHKN3VN-Dg1DeAnJ.cjs +1 -0
- package/dist/chunk-TZMSLE5B-Bd4ivTqX.cjs +1 -0
- package/dist/{chunk-TZMSLE5B-BgFWf03M.js → chunk-TZMSLE5B-xm8uzxSg.js} +1 -1
- package/dist/{classDiagram-2ON5EDUG-BQz3UzKi.js → classDiagram-2ON5EDUG-CK_iHiNY.js} +2 -2
- package/dist/classDiagram-2ON5EDUG-DaNkCwSZ.cjs +1 -0
- package/dist/{classDiagram-v2-WZHVMYZB-BQz3UzKi.js → classDiagram-v2-WZHVMYZB-CK_iHiNY.js} +2 -2
- package/dist/classDiagram-v2-WZHVMYZB-DaNkCwSZ.cjs +1 -0
- package/dist/{clone-D6h_cwF4.js → clone-Bha0jTOw.js} +1 -1
- package/dist/clone-C1QAYyzI.cjs +1 -0
- package/dist/cose-bilkent-S5V4N54A-CV1wgztW.cjs +1 -0
- package/dist/{cose-bilkent-S5V4N54A-D2q7jBXB.js → cose-bilkent-S5V4N54A-hCsgqyKM.js} +5 -6
- package/dist/{plugin-mermaid-y4lbJ7sL.js → custom-B4yTjcNy.js} +8845 -5380
- package/dist/custom-DUStvHau.cjs +263 -0
- package/dist/{dagre-6UL2VRFP-Cfh4UdSr.js → dagre-6UL2VRFP-DgeWg1SE.js} +108 -108
- package/dist/dagre-6UL2VRFP-yXKAxpPT.cjs +4 -0
- package/dist/{diagram-PSM6KHXK-BZDEX43o.js → diagram-PSM6KHXK-Cvtq1BMM.js} +16 -16
- package/dist/diagram-PSM6KHXK-D8-R7SoU.cjs +24 -0
- package/dist/diagram-QEK2KX5R-BJwfOJRv.cjs +43 -0
- package/dist/{diagram-QEK2KX5R-Dda_FEDc.js → diagram-QEK2KX5R-Bk1U0LhS.js} +3 -3
- package/dist/{diagram-S2PKOQOG-Cnw4b7LB.js → diagram-S2PKOQOG-C1GhQvXr.js} +3 -3
- package/dist/diagram-S2PKOQOG-CrU1lFAd.cjs +24 -0
- package/dist/entries/md.cjs.js +1 -1
- package/dist/entries/md.es.js +1 -1
- package/dist/{erDiagram-Q2GNP2WA-qAdA8fbE.js → erDiagram-Q2GNP2WA-BW644HGe.js} +4 -4
- package/dist/{erDiagram-Q2GNP2WA-DE4JLeNF.cjs → erDiagram-Q2GNP2WA-DwCMcLlJ.cjs} +1 -1
- package/dist/{flowDiagram-NV44I4VS-j3dB-fjF.cjs → flowDiagram-NV44I4VS-CwBt-lqk.cjs} +1 -1
- package/dist/{flowDiagram-NV44I4VS-C7YBx4JP.js → flowDiagram-NV44I4VS-wXa2zQjd.js} +5 -5
- package/dist/ganttDiagram-LVOFAZNH-CFZ-PmU5.cjs +267 -0
- package/dist/{ganttDiagram-LVOFAZNH-BL-Yjadx.js → ganttDiagram-LVOFAZNH-DEQvlmR2.js} +55 -56
- package/dist/{gitGraph-ZV4HHKMB-Dr9sn7R3.js → gitGraph-ZV4HHKMB-Bd_PHDMp.js} +1 -1
- package/dist/{gitGraph-ZV4HHKMB-DyXW77WY.cjs → gitGraph-ZV4HHKMB-CbfGP-N9.cjs} +1 -1
- package/dist/gitGraphDiagram-NY62KEGX-j4D9jXL4.cjs +65 -0
- package/dist/{gitGraphDiagram-NY62KEGX-DFn7h5BH.js → gitGraphDiagram-NY62KEGX-xl70htLN.js} +4 -4
- package/dist/graph-6iViBDku.cjs +1 -0
- package/dist/{graph-DiGqaw_6.js → graph-D6yOZd92.js} +7 -7
- package/dist/info-63CPKGFF-du1jd1Lv.js +5 -0
- package/dist/{info-63CPKGFF-BGxbI0Qv.cjs → info-63CPKGFF-gOwyweiZ.cjs} +1 -1
- package/dist/{infoDiagram-F6ZHWCRC-DOtGa28U.js → infoDiagram-F6ZHWCRC-BfGS0mg6.js} +2 -2
- package/dist/infoDiagram-F6ZHWCRC-Vx_DX2z8.cjs +2 -0
- package/dist/{journeyDiagram-XKPGCS4Q-bJncB3oe.js → journeyDiagram-XKPGCS4Q-C74m57vy.js} +4 -4
- package/dist/{journeyDiagram-XKPGCS4Q-h-CtcfbS.cjs → journeyDiagram-XKPGCS4Q-Cwfm3gkE.cjs} +1 -1
- package/dist/{kanban-definition-3W4ZIXB7-C3y0C_bw.cjs → kanban-definition-3W4ZIXB7-CgUhoGem.cjs} +3 -3
- package/dist/{kanban-definition-3W4ZIXB7-nMPCi8GW.js → kanban-definition-3W4ZIXB7-Zs307aAz.js} +2 -2
- package/dist/{layout-CHaNS4g6.js → layout-BVJXml4k.js} +33 -33
- package/dist/layout-DiSbzXpp.cjs +1 -0
- package/dist/{linear-CPFNaVnw.js → linear-BE7L7Wq8.js} +5 -5
- package/dist/linear-CF8o0osj.cjs +1 -0
- package/dist/{mermaid-parser.core-CkQKh-yb.js → mermaid-parser.core-CvS4VcbX.js} +11 -11
- package/dist/{mermaid-parser.core-CR8Rcyps.cjs → mermaid-parser.core-D8AljRep.cjs} +2 -2
- package/dist/{mindmap-definition-VGOIOE7T-C63AEIdU.js → mindmap-definition-VGOIOE7T-BAXsNT0n.js} +3 -3
- package/dist/{mindmap-definition-VGOIOE7T-CHI9UFtA.cjs → mindmap-definition-VGOIOE7T-BidsJOPm.cjs} +1 -1
- package/dist/mio-previewer.cjs.js +2 -2
- package/dist/mio-previewer.css +1 -1
- package/dist/mio-previewer.es.js +12 -4
- package/dist/{packet-HUATNLJX-dnmrn2-l.js → packet-HUATNLJX-B1eLognS.js} +1 -1
- package/dist/{packet-HUATNLJX-BeAGxpDF.cjs → packet-HUATNLJX-CgY4KC5-.cjs} +1 -1
- package/dist/{pie-WTHONI2E-BifrFKgo.cjs → pie-WTHONI2E-DBm7_2Ma.cjs} +1 -1
- package/dist/pie-WTHONI2E-RplLoGbc.js +5 -0
- package/dist/{pieDiagram-ADFJNKIX-CEMFAt9B.js → pieDiagram-ADFJNKIX-CWK1C9xc.js} +4 -4
- package/dist/{pieDiagram-ADFJNKIX-B9OONHi_.cjs → pieDiagram-ADFJNKIX-DTKW3svv.cjs} +1 -1
- package/dist/plugins/custom.cjs.js +1 -0
- package/dist/plugins/custom.es.js +6 -0
- package/dist/plugins/markdown-it.cjs.js +1 -0
- package/dist/{entries/plugin-katex.es.js → plugins/markdown-it.es.js} +20 -7
- package/dist/{quadrantDiagram-AYHSOK5B-DobvzsAU.js → quadrantDiagram-AYHSOK5B-BNrGATyu.js} +2 -2
- package/dist/{quadrantDiagram-AYHSOK5B-DqXDgyBD.cjs → quadrantDiagram-AYHSOK5B-qLZyIHgG.cjs} +3 -3
- package/dist/radar-NJJJXTRR-DRmyBDWp.js +5 -0
- package/dist/{radar-NJJJXTRR-BPN19Spv.cjs → radar-NJJJXTRR-EpcDInzR.cjs} +1 -1
- package/dist/{requirementDiagram-UZGBJVZJ-CVbmNF7M.cjs → requirementDiagram-UZGBJVZJ-BTCSXGaW.cjs} +1 -1
- package/dist/{requirementDiagram-UZGBJVZJ-M-MPvTnX.js → requirementDiagram-UZGBJVZJ-CkxxLi7P.js} +3 -3
- package/dist/sankeyDiagram-TZEHDZUN-BNlI2aP-.cjs +10 -0
- package/dist/{sankeyDiagram-TZEHDZUN-Czsin99f.js → sankeyDiagram-TZEHDZUN-DJ1q5E3K.js} +1 -1
- package/dist/{sequenceDiagram-WL72ISMW-DApIQwP-.cjs → sequenceDiagram-WL72ISMW-CjMzI1c2.cjs} +1 -1
- package/dist/{sequenceDiagram-WL72ISMW-BJByNQsK.js → sequenceDiagram-WL72ISMW-nQ6UBL1y.js} +3 -3
- package/dist/stateDiagram-FKZM4ZOC-BBEPk90z.cjs +1 -0
- package/dist/{stateDiagram-FKZM4ZOC-jAiBDhVn.js → stateDiagram-FKZM4ZOC-Dr_-m8dE.js} +4 -4
- package/dist/{stateDiagram-v2-4FDKWEC3-umSVoFht.js → stateDiagram-v2-4FDKWEC3-CG--f0tc.js} +2 -2
- package/dist/stateDiagram-v2-4FDKWEC3-D7NtOxif.cjs +1 -0
- package/dist/{timeline-definition-IT6M3QCI-BfAvK0gf.cjs → timeline-definition-IT6M3QCI-2DClSZLV.cjs} +3 -3
- package/dist/{timeline-definition-IT6M3QCI-I--lBLTi.js → timeline-definition-IT6M3QCI-d0F8eBhC.js} +2 -2
- package/dist/{treemap-75Q7IDZK-bjql9DgL.js → treemap-75Q7IDZK-BBuuvHE0.js} +1 -1
- package/dist/{treemap-75Q7IDZK-DNt-zuL8.cjs → treemap-75Q7IDZK-CI86AmBT.cjs} +1 -1
- package/dist/types/entries/plugins/custom.d.ts +3 -0
- package/dist/types/entries/plugins/markdown-it.d.ts +2 -0
- package/dist/types/helpers/containerHelpers.d.ts +11 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/types/plugins/AlertPlugin.d.ts +10 -8
- package/dist/{xychartDiagram-PRI3JC2R-BN9e47xe.cjs → xychartDiagram-PRI3JC2R-BkUjTJNu.cjs} +1 -1
- package/dist/{xychartDiagram-PRI3JC2R-XrOK_egj.js → xychartDiagram-PRI3JC2R-DLXTvnDG.js} +2 -2
- package/package.json +12 -32
- package/dist/_basePickBy-CZxbwAvt.cjs +0 -1
- package/dist/_baseUniq-DunUk-cd.cjs +0 -1
- package/dist/_commonjsHelpers-DKOUU3wS.cjs +0 -1
- package/dist/_commonjsHelpers-DaMA6jEr.js +0 -8
- package/dist/arc-fCflz0gB.cjs +0 -1
- package/dist/architectureDiagram-VXUJARFQ-DQ-YD3RX.cjs +0 -36
- package/dist/channel-YfH5CBV-.cjs +0 -1
- package/dist/chunk-4BX2VUAB-3Liht_XN.cjs +0 -1
- package/dist/chunk-55IACEB6-Dm3mi3ha.cjs +0 -1
- package/dist/chunk-QN33PNHL-CHI_-zix.cjs +0 -1
- package/dist/chunk-QZHKN3VN-DfH9qQ3T.cjs +0 -1
- package/dist/chunk-TZMSLE5B-qIo1h7Gz.cjs +0 -1
- package/dist/classDiagram-2ON5EDUG-CZWeacVd.cjs +0 -1
- package/dist/classDiagram-v2-WZHVMYZB-CZWeacVd.cjs +0 -1
- package/dist/clone-ByeQKKoW.cjs +0 -1
- package/dist/cose-bilkent-S5V4N54A-5dO3qpr4.cjs +0 -1
- package/dist/dagre-6UL2VRFP-DS2Ki9Dv.cjs +0 -4
- package/dist/diagram-PSM6KHXK-CTsP6f2a.cjs +0 -24
- package/dist/diagram-QEK2KX5R-BDKMNi97.cjs +0 -43
- package/dist/diagram-S2PKOQOG-CmfsKOvs.cjs +0 -24
- package/dist/entries/plugin-alert.cjs.js +0 -1
- package/dist/entries/plugin-alert.es.js +0 -27
- package/dist/entries/plugin-codeblock.cjs.js +0 -9
- package/dist/entries/plugin-codeblock.es.js +0 -3441
- package/dist/entries/plugin-emoji.cjs.js +0 -1
- package/dist/entries/plugin-emoji.es.js +0 -28
- package/dist/entries/plugin-katex.cjs.js +0 -1
- package/dist/entries/plugin-mermaid.cjs.js +0 -1
- package/dist/entries/plugin-mermaid.es.js +0 -4
- package/dist/ganttDiagram-LVOFAZNH-CBhzET57.cjs +0 -267
- package/dist/gitGraphDiagram-NY62KEGX-DDklxVnY.cjs +0 -65
- package/dist/graph-CHoeKkVR.cjs +0 -1
- package/dist/info-63CPKGFF-xflgSxfH.js +0 -5
- package/dist/infoDiagram-F6ZHWCRC-Duylo4r7.cjs +0 -2
- package/dist/layout-BG4AbhIW.cjs +0 -1
- package/dist/linear-Bqd4C_Yb.cjs +0 -1
- package/dist/pie-WTHONI2E-BKoHQt0i.js +0 -5
- package/dist/plugin-mermaid-FTki7cN8.cjs +0 -255
- package/dist/radar-NJJJXTRR-Bj9rI8mr.js +0 -5
- package/dist/sankeyDiagram-TZEHDZUN-C-ESiLJA.cjs +0 -10
- package/dist/stateDiagram-FKZM4ZOC-BuKL2w66.cjs +0 -1
- package/dist/stateDiagram-v2-4FDKWEC3-Ct5PFxdd.cjs +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a={name:"emoji",priority:10,test:e=>e.type==="text"&&/:\w+:/g.test(e.data||""),render:(e,o,c)=>{const r=e.data||"",i={":smile:":"😊",":heart:":"❤️",":fire:":"🔥",":rocket:":"🚀",":star:":"⭐",":thumbsup:":"👍",":tada:":"🎉",":check:":"✅",":cross:":"❌",":eyes:":"👀",":thinking:":"🤔",":100:":"💯"};let t=r;return Object.entries(i).forEach(([n,s])=>{t=t.replace(new RegExp(n,"g"),s)}),t}};exports.EmojiPlugin=a;
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
const o = {
|
|
2
|
-
name: "emoji",
|
|
3
|
-
priority: 10,
|
|
4
|
-
test: (e) => e.type === "text" && /:\w+:/g.test(e.data || ""),
|
|
5
|
-
render: (e, i, c) => {
|
|
6
|
-
const r = e.data || "", n = {
|
|
7
|
-
":smile:": "😊",
|
|
8
|
-
":heart:": "❤️",
|
|
9
|
-
":fire:": "🔥",
|
|
10
|
-
":rocket:": "🚀",
|
|
11
|
-
":star:": "⭐",
|
|
12
|
-
":thumbsup:": "👍",
|
|
13
|
-
":tada:": "🎉",
|
|
14
|
-
":check:": "✅",
|
|
15
|
-
":cross:": "❌",
|
|
16
|
-
":eyes:": "👀",
|
|
17
|
-
":thinking:": "🤔",
|
|
18
|
-
":100:": "💯"
|
|
19
|
-
};
|
|
20
|
-
let t = r;
|
|
21
|
-
return Object.entries(n).forEach(([s, a]) => {
|
|
22
|
-
t = t.replace(new RegExp(s, "g"), a);
|
|
23
|
-
}), t;
|
|
24
|
-
}
|
|
25
|
-
};
|
|
26
|
-
export {
|
|
27
|
-
o as EmojiPlugin
|
|
28
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const x=require("../katex-DEiiRhcn.cjs");function M(p){return $(p)}function $(p){const h=[{open:"$$",close:"$$",display:!0},{open:"\\[",close:"\\]",display:!0},{open:"\\(",close:"\\)",display:!1},{open:"$",close:"$",display:!1}],m=(e,r)=>{const c=e.src;for(const t of h){if(!c.startsWith(t.open,e.pos))continue;const n=e.pos+t.open.length;let l=n,i=-1;for(;(l=c.indexOf(t.close,l))!==-1;){let o=l-1,f=0;for(;o>=0&&c[o]==="\\";)f++,o--;if(f%2===0){i=l;break}l+=t.close.length}if(i===-1)return r||(e.pending+=t.open),e.pos+=t.open.length,!0;const u=c.slice(n,i);if(!r){const o=e.push("math","math",0);o.content=u,o.markup=t.open,o.meta={display:t.display}}return e.pos=i+t.close.length,!0}return!1},k=(e,r)=>{const c=e[r],t=c.meta?.display||!1;try{const n=x.default.renderToString(c.content,{displayMode:t,throwOnError:!1});return t?`<div class="katex-block">${n}</div>`:n}catch(n){const l=n instanceof Error?n.message:String(n),i=p.utils?p.utils.escapeHtml(c.content):c.content;return`<span class="katex-error" title="${p.utils?p.utils.escapeHtml(l):l}">${i}</span>`}};p.inline.ruler.before("escape","math",m),p.renderer.rules.math=k;const g=(e,r,c,t)=>{for(const n of h){if(!n.display)continue;let l=e.bMarks[r]+e.tShift[r],i=e.eMarks[r];if(l+n.open.length>i||e.src.slice(l,l+n.open.length)!==n.open)continue;l+=n.open.length;const u=e.src.slice(l,i);if(u.trim().endsWith(n.close)){const s=u.trim().slice(0,-n.close.length);if(!t){const a=e.push("math","math",0);a.block=!0,a.content=s,a.markup=n.open,a.meta={display:n.display},a.map=[r,r+1]}return e.line=r+1,!0}let o=r,f=!1;for(;o<c&&(o++,!(o>=c||(l=e.bMarks[o]+e.tShift[o],i=e.eMarks[o],l<i&&e.tShift[o]<e.blkIndent)));)if(e.src.slice(l,i).trim()===n.close){f=!0;break}if(!f)continue;const y=e.parentType,b=e.lineMax;e.parentType="math";let d="";for(let s=r+1;s<o;s++){const a=e.getLines(s,s+1,e.tShift[r],!1);d+=a}if(!t){const s=e.push("math","math",0);s.block=!0,s.content=d.trim(),s.markup=n.open,s.meta={display:n.display},s.map=[r,o+1]}return e.parentType=y,e.lineMax=b,e.line=o+1,!0}return!1};p.block.ruler.before("fence","math_block",g)}exports.katexPlugin=M;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../plugin-mermaid-FTki7cN8.cjs");exports.mermaidPlugin=e.mermaidPlugin;
|
|
@@ -1,267 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("./plugin-mermaid-FTki7cN8.cjs"),vt=require("./_commonjsHelpers-DKOUU3wS.cjs"),Ce=require("./linear-Bqd4C_Yb.cjs"),wn=require("./init-CHZsXQcr.cjs");function Dn(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n<r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let a of e)(a=t(a,++r,e))!=null&&(n<a||n===void 0&&a>=a)&&(n=a)}return n}function Cn(e,t){let n;if(t===void 0)for(const r of e)r!=null&&(n>r||n===void 0&&r>=r)&&(n=r);else{let r=-1;for(let a of e)(a=t(a,++r,e))!=null&&(n>a||n===void 0&&a>=a)&&(n=a)}return n}function Mn(e){return e}var qe=1,rt=2,ht=3,je=4,At=1e-6;function Sn(e){return"translate("+e+",0)"}function Fn(e){return"translate(0,"+e+")"}function Yn(e){return t=>+e(t)}function Un(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function En(){return!this.__axis}function Qt(e,t){var n=[],r=null,a=null,i=6,o=6,y=3,M=typeof window<"u"&&window.devicePixelRatio>1?0:.5,p=e===qe||e===je?-1:1,g=e===je||e===rt?"x":"y",E=e===qe||e===ht?Sn:Fn;function D(_){var Z=r??(t.ticks?t.ticks.apply(t,n):t.domain()),O=a??(t.tickFormat?t.tickFormat.apply(t,n):Mn),C=Math.max(i,0)+y,I=t.range(),P=+I[0]+M,W=+I[I.length-1]+M,q=(t.bandwidth?Un:Yn)(t.copy(),M),$=_.selection?_.selection():_,w=$.selectAll(".domain").data([null]),H=$.selectAll(".tick").data(Z,t).order(),x=H.exit(),Y=H.enter().append("g").attr("class","tick"),F=H.select("line"),S=H.select("text");w=w.merge(w.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),H=H.merge(Y),F=F.merge(Y.append("line").attr("stroke","currentColor").attr(g+"2",p*i)),S=S.merge(Y.append("text").attr("fill","currentColor").attr(g,p*C).attr("dy",e===qe?"0em":e===ht?"0.71em":"0.32em")),_!==$&&(w=w.transition(_),H=H.transition(_),F=F.transition(_),S=S.transition(_),x=x.transition(_).attr("opacity",At).attr("transform",function(v){return isFinite(v=q(v))?E(v+M):this.getAttribute("transform")}),Y.attr("opacity",At).attr("transform",function(v){var U=this.parentNode.__axis;return E((U&&isFinite(U=U(v))?U:q(v))+M)})),x.remove(),w.attr("d",e===je||e===rt?o?"M"+p*o+","+P+"H"+M+"V"+W+"H"+p*o:"M"+M+","+P+"V"+W:o?"M"+P+","+p*o+"V"+M+"H"+W+"V"+p*o:"M"+P+","+M+"H"+W),H.attr("opacity",1).attr("transform",function(v){return E(q(v)+M)}),F.attr(g+"2",p*i),S.attr(g,p*C).text(O),$.filter(En).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===rt?"start":e===je?"end":"middle"),$.each(function(){this.__axis=q})}return D.scale=function(_){return arguments.length?(t=_,D):t},D.ticks=function(){return n=Array.from(arguments),D},D.tickArguments=function(_){return arguments.length?(n=_==null?[]:Array.from(_),D):n.slice()},D.tickValues=function(_){return arguments.length?(r=_==null?null:Array.from(_),D):r&&r.slice()},D.tickFormat=function(_){return arguments.length?(a=_,D):a},D.tickSize=function(_){return arguments.length?(i=o=+_,D):i},D.tickSizeInner=function(_){return arguments.length?(i=+_,D):i},D.tickSizeOuter=function(_){return arguments.length?(o=+_,D):o},D.tickPadding=function(_){return arguments.length?(y=+_,D):y},D.offset=function(_){return arguments.length?(M=+_,D):M},D}function An(e){return Qt(qe,e)}function Ln(e){return Qt(ht,e)}const In=Math.PI/180,Wn=180/Math.PI,Qe=18,Jt=.96422,Kt=1,en=.82521,tn=4/29,Me=6/29,nn=3*Me*Me,On=Me*Me*Me;function rn(e){if(e instanceof le)return new le(e.l,e.a,e.b,e.opacity);if(e instanceof de)return an(e);e instanceof s.Rgb||(e=s.rgbConvert(e));var t=ot(e.r),n=ot(e.g),r=ot(e.b),a=at((.2225045*t+.7168786*n+.0606169*r)/Kt),i,o;return t===n&&n===r?i=o=a:(i=at((.4360747*t+.3850649*n+.1430804*r)/Jt),o=at((.0139322*t+.0971045*n+.7141733*r)/en)),new le(116*a-16,500*(i-a),200*(a-o),e.opacity)}function Hn(e,t,n,r){return arguments.length===1?rn(e):new le(e,t,n,r??1)}function le(e,t,n,r){this.l=+e,this.a=+t,this.b=+n,this.opacity=+r}s.define(le,Hn,s.extend(s.Color$1,{brighter(e){return new le(this.l+Qe*(e??1),this.a,this.b,this.opacity)},darker(e){return new le(this.l-Qe*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=Jt*it(t),e=Kt*it(e),n=en*it(n),new s.Rgb(st(3.1338561*t-1.6168667*e-.4906146*n),st(-.9787684*t+1.9161415*e+.033454*n),st(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function at(e){return e>On?Math.pow(e,1/3):e/nn+tn}function it(e){return e>Me?e*e*e:nn*(e-tn)}function st(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function ot(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function Nn(e){if(e instanceof de)return new de(e.h,e.c,e.l,e.opacity);if(e instanceof le||(e=rn(e)),e.a===0&&e.b===0)return new de(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*Wn;return new de(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function mt(e,t,n,r){return arguments.length===1?Nn(e):new de(e,t,n,r??1)}function de(e,t,n,r){this.h=+e,this.c=+t,this.l=+n,this.opacity=+r}function an(e){if(isNaN(e.h))return new le(e.l,0,0,e.opacity);var t=e.h*In;return new le(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}s.define(de,mt,s.extend(s.Color$1,{brighter(e){return new de(this.h,this.c,this.l+Qe*(e??1),this.opacity)},darker(e){return new de(this.h,this.c,this.l-Qe*(e??1),this.opacity)},rgb(){return an(this).rgb()}}));function Pn(e){return function(t,n){var r=e((t=mt(t)).h,(n=mt(n)).h),a=s.nogamma(t.c,n.c),i=s.nogamma(t.l,n.l),o=s.nogamma(t.opacity,n.opacity);return function(y){return t.h=r(y),t.c=a(y),t.l=i(y),t.opacity=o(y),t+""}}}const Vn=Pn(s.hue);function zn(e,t){e=e.slice();var n=0,r=e.length-1,a=e[n],i=e[r],o;return i<a&&(o=n,n=r,r=o,o=a,a=i,i=o),e[n]=t.floor(a),e[r]=t.ceil(i),e}const ct=new Date,ut=new Date;function te(e,t,n,r){function a(i){return e(i=arguments.length===0?new Date:new Date(+i)),i}return a.floor=i=>(e(i=new Date(+i)),i),a.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),a.round=i=>{const o=a(i),y=a.ceil(i);return i-o<y-i?o:y},a.offset=(i,o)=>(t(i=new Date(+i),o==null?1:Math.floor(o)),i),a.range=(i,o,y)=>{const M=[];if(i=a.ceil(i),y=y==null?1:Math.floor(y),!(i<o)||!(y>0))return M;let p;do M.push(p=new Date(+i)),t(i,y),e(i);while(p<i&&i<o);return M},a.filter=i=>te(o=>{if(o>=o)for(;e(o),!i(o);)o.setTime(o-1)},(o,y)=>{if(o>=o)if(y<0)for(;++y<=0;)for(;t(o,-1),!i(o););else for(;--y>=0;)for(;t(o,1),!i(o););}),n&&(a.count=(i,o)=>(ct.setTime(+i),ut.setTime(+o),e(ct),e(ut),Math.floor(n(ct,ut))),a.every=i=>(i=Math.floor(i),!isFinite(i)||!(i>0)?null:i>1?a.filter(r?o=>r(o)%i===0:o=>a.count(0,o)%i===0):a)),a}const Fe=te(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Fe.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?te(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Fe);Fe.range;const he=1e3,oe=he*60,me=oe*60,ge=me*24,Tt=ge*7,Lt=ge*30,lt=ge*365,pe=te(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*he)},(e,t)=>(t-e)/he,e=>e.getUTCSeconds());pe.range;const Ie=te(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*he)},(e,t)=>{e.setTime(+e+t*oe)},(e,t)=>(t-e)/oe,e=>e.getMinutes());Ie.range;const Rn=te(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*oe)},(e,t)=>(t-e)/oe,e=>e.getUTCMinutes());Rn.range;const We=te(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*he-e.getMinutes()*oe)},(e,t)=>{e.setTime(+e+t*me)},(e,t)=>(t-e)/me,e=>e.getHours());We.range;const jn=te(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*me)},(e,t)=>(t-e)/me,e=>e.getUTCHours());jn.range;const ve=te(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*oe)/ge,e=>e.getDate()-1);ve.range;const _t=te(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ge,e=>e.getUTCDate()-1);_t.range;const qn=te(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/ge,e=>Math.floor(e/ge));qn.range;function xe(e){return te(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*oe)/Tt)}const Ne=xe(0),Oe=xe(1),sn=xe(2),on=xe(3),Te=xe(4),cn=xe(5),un=xe(6);Ne.range;Oe.range;sn.range;on.range;Te.range;cn.range;un.range;function be(e){return te(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/Tt)}const ln=be(0),Je=be(1),Bn=be(2),Zn=be(3),Ye=be(4),Xn=be(5),Gn=be(6);ln.range;Je.range;Bn.range;Zn.range;Ye.range;Xn.range;Gn.range;const He=te(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());He.range;const $n=te(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());$n.range;const ye=te(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());ye.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:te(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});ye.range;const _e=te(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());_e.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:te(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});_e.range;function Qn(e,t,n,r,a,i){const o=[[pe,1,he],[pe,5,5*he],[pe,15,15*he],[pe,30,30*he],[i,1,oe],[i,5,5*oe],[i,15,15*oe],[i,30,30*oe],[a,1,me],[a,3,3*me],[a,6,6*me],[a,12,12*me],[r,1,ge],[r,2,2*ge],[n,1,Tt],[t,1,Lt],[t,3,3*Lt],[e,1,lt]];function y(p,g,E){const D=g<p;D&&([p,g]=[g,p]);const _=E&&typeof E.range=="function"?E:M(p,g,E),Z=_?_.range(p,+g+1):[];return D?Z.reverse():Z}function M(p,g,E){const D=Math.abs(g-p)/E,_=Ce.bisector(([,,C])=>C).right(o,D);if(_===o.length)return e.every(Ce.tickStep(p/lt,g/lt,E));if(_===0)return Fe.every(Math.max(Ce.tickStep(p,g,E),1));const[Z,O]=o[D/o[_-1][2]<o[_][2]/D?_-1:_];return Z.every(O)}return[y,M]}const[Jn,Kn]=Qn(ye,He,Ne,ve,We,Ie);function ft(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function dt(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function Ee(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function er(e){var t=e.dateTime,n=e.date,r=e.time,a=e.periods,i=e.days,o=e.shortDays,y=e.months,M=e.shortMonths,p=Ae(a),g=Le(a),E=Ae(i),D=Le(i),_=Ae(o),Z=Le(o),O=Ae(y),C=Le(y),I=Ae(M),P=Le(M),W={a:h,A:b,b:u,B:l,c:null,d:Pt,e:Pt,f:br,g:Ar,G:Ir,H:Tr,I:_r,j:xr,L:fn,m:wr,M:Dr,p:c,q:z,Q:Rt,s:jt,S:Cr,u:Mr,U:Sr,V:Fr,w:Yr,W:Ur,x:null,X:null,y:Er,Y:Lr,Z:Wr,"%":zt},q={a:V,A:R,b:K,B:X,c:null,d:Vt,e:Vt,f:Pr,g:$r,G:Jr,H:Or,I:Hr,j:Nr,L:hn,m:Vr,M:zr,p:Q,q:ae,Q:Rt,s:jt,S:Rr,u:jr,U:qr,V:Br,w:Zr,W:Xr,x:null,X:null,y:Gr,Y:Qr,Z:Kr,"%":zt},$={a:F,A:S,b:v,B:U,c:f,d:Ht,e:Ht,f:yr,g:Ot,G:Wt,H:Nt,I:Nt,j:dr,L:gr,m:fr,M:hr,p:Y,q:lr,Q:pr,s:vr,S:mr,u:ir,U:sr,V:or,w:ar,W:cr,x:m,X:T,y:Ot,Y:Wt,Z:ur,"%":kr};W.x=w(n,W),W.X=w(r,W),W.c=w(t,W),q.x=w(n,q),q.X=w(r,q),q.c=w(t,q);function w(k,L){return function(N){var d=[],J=-1,A=0,G=k.length,B,re,ie;for(N instanceof Date||(N=new Date(+N));++J<G;)k.charCodeAt(J)===37&&(d.push(k.slice(A,J)),(re=It[B=k.charAt(++J)])!=null?B=k.charAt(++J):re=B==="e"?" ":"0",(ie=L[B])&&(B=ie(N,re)),d.push(B),A=J+1);return d.push(k.slice(A,J)),d.join("")}}function H(k,L){return function(N){var d=Ee(1900,void 0,1),J=x(d,k,N+="",0),A,G;if(J!=N.length)return null;if("Q"in d)return new Date(d.Q);if("s"in d)return new Date(d.s*1e3+("L"in d?d.L:0));if(L&&!("Z"in d)&&(d.Z=0),"p"in d&&(d.H=d.H%12+d.p*12),d.m===void 0&&(d.m="q"in d?d.q:0),"V"in d){if(d.V<1||d.V>53)return null;"w"in d||(d.w=1),"Z"in d?(A=dt(Ee(d.y,0,1)),G=A.getUTCDay(),A=G>4||G===0?Je.ceil(A):Je(A),A=_t.offset(A,(d.V-1)*7),d.y=A.getUTCFullYear(),d.m=A.getUTCMonth(),d.d=A.getUTCDate()+(d.w+6)%7):(A=ft(Ee(d.y,0,1)),G=A.getDay(),A=G>4||G===0?Oe.ceil(A):Oe(A),A=ve.offset(A,(d.V-1)*7),d.y=A.getFullYear(),d.m=A.getMonth(),d.d=A.getDate()+(d.w+6)%7)}else("W"in d||"U"in d)&&("w"in d||(d.w="u"in d?d.u%7:"W"in d?1:0),G="Z"in d?dt(Ee(d.y,0,1)).getUTCDay():ft(Ee(d.y,0,1)).getDay(),d.m=0,d.d="W"in d?(d.w+6)%7+d.W*7-(G+5)%7:d.w+d.U*7-(G+6)%7);return"Z"in d?(d.H+=d.Z/100|0,d.M+=d.Z%100,dt(d)):ft(d)}}function x(k,L,N,d){for(var J=0,A=L.length,G=N.length,B,re;J<A;){if(d>=G)return-1;if(B=L.charCodeAt(J++),B===37){if(B=L.charAt(J++),re=$[B in It?L.charAt(J++):B],!re||(d=re(k,N,d))<0)return-1}else if(B!=N.charCodeAt(d++))return-1}return d}function Y(k,L,N){var d=p.exec(L.slice(N));return d?(k.p=g.get(d[0].toLowerCase()),N+d[0].length):-1}function F(k,L,N){var d=_.exec(L.slice(N));return d?(k.w=Z.get(d[0].toLowerCase()),N+d[0].length):-1}function S(k,L,N){var d=E.exec(L.slice(N));return d?(k.w=D.get(d[0].toLowerCase()),N+d[0].length):-1}function v(k,L,N){var d=I.exec(L.slice(N));return d?(k.m=P.get(d[0].toLowerCase()),N+d[0].length):-1}function U(k,L,N){var d=O.exec(L.slice(N));return d?(k.m=C.get(d[0].toLowerCase()),N+d[0].length):-1}function f(k,L,N){return x(k,t,L,N)}function m(k,L,N){return x(k,n,L,N)}function T(k,L,N){return x(k,r,L,N)}function h(k){return o[k.getDay()]}function b(k){return i[k.getDay()]}function u(k){return M[k.getMonth()]}function l(k){return y[k.getMonth()]}function c(k){return a[+(k.getHours()>=12)]}function z(k){return 1+~~(k.getMonth()/3)}function V(k){return o[k.getUTCDay()]}function R(k){return i[k.getUTCDay()]}function K(k){return M[k.getUTCMonth()]}function X(k){return y[k.getUTCMonth()]}function Q(k){return a[+(k.getUTCHours()>=12)]}function ae(k){return 1+~~(k.getUTCMonth()/3)}return{format:function(k){var L=w(k+="",W);return L.toString=function(){return k},L},parse:function(k){var L=H(k+="",!1);return L.toString=function(){return k},L},utcFormat:function(k){var L=w(k+="",q);return L.toString=function(){return k},L},utcParse:function(k){var L=H(k+="",!0);return L.toString=function(){return k},L}}}var It={"-":"",_:" ",0:"0"},ne=/^\s*\d+/,tr=/^%/,nr=/[\\^$*+?|[\]().{}]/g;function j(e,t,n){var r=e<0?"-":"",a=(r?-e:e)+"",i=a.length;return r+(i<n?new Array(n-i+1).join(t)+a:a)}function rr(e){return e.replace(nr,"\\$&")}function Ae(e){return new RegExp("^(?:"+e.map(rr).join("|")+")","i")}function Le(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function ar(e,t,n){var r=ne.exec(t.slice(n,n+1));return r?(e.w=+r[0],n+r[0].length):-1}function ir(e,t,n){var r=ne.exec(t.slice(n,n+1));return r?(e.u=+r[0],n+r[0].length):-1}function sr(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.U=+r[0],n+r[0].length):-1}function or(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.V=+r[0],n+r[0].length):-1}function cr(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.W=+r[0],n+r[0].length):-1}function Wt(e,t,n){var r=ne.exec(t.slice(n,n+4));return r?(e.y=+r[0],n+r[0].length):-1}function Ot(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function ur(e,t,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return r?(e.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function lr(e,t,n){var r=ne.exec(t.slice(n,n+1));return r?(e.q=r[0]*3-3,n+r[0].length):-1}function fr(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.m=r[0]-1,n+r[0].length):-1}function Ht(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.d=+r[0],n+r[0].length):-1}function dr(e,t,n){var r=ne.exec(t.slice(n,n+3));return r?(e.m=0,e.d=+r[0],n+r[0].length):-1}function Nt(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.H=+r[0],n+r[0].length):-1}function hr(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.M=+r[0],n+r[0].length):-1}function mr(e,t,n){var r=ne.exec(t.slice(n,n+2));return r?(e.S=+r[0],n+r[0].length):-1}function gr(e,t,n){var r=ne.exec(t.slice(n,n+3));return r?(e.L=+r[0],n+r[0].length):-1}function yr(e,t,n){var r=ne.exec(t.slice(n,n+6));return r?(e.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function kr(e,t,n){var r=tr.exec(t.slice(n,n+1));return r?n+r[0].length:-1}function pr(e,t,n){var r=ne.exec(t.slice(n));return r?(e.Q=+r[0],n+r[0].length):-1}function vr(e,t,n){var r=ne.exec(t.slice(n));return r?(e.s=+r[0],n+r[0].length):-1}function Pt(e,t){return j(e.getDate(),t,2)}function Tr(e,t){return j(e.getHours(),t,2)}function _r(e,t){return j(e.getHours()%12||12,t,2)}function xr(e,t){return j(1+ve.count(ye(e),e),t,3)}function fn(e,t){return j(e.getMilliseconds(),t,3)}function br(e,t){return fn(e,t)+"000"}function wr(e,t){return j(e.getMonth()+1,t,2)}function Dr(e,t){return j(e.getMinutes(),t,2)}function Cr(e,t){return j(e.getSeconds(),t,2)}function Mr(e){var t=e.getDay();return t===0?7:t}function Sr(e,t){return j(Ne.count(ye(e)-1,e),t,2)}function dn(e){var t=e.getDay();return t>=4||t===0?Te(e):Te.ceil(e)}function Fr(e,t){return e=dn(e),j(Te.count(ye(e),e)+(ye(e).getDay()===4),t,2)}function Yr(e){return e.getDay()}function Ur(e,t){return j(Oe.count(ye(e)-1,e),t,2)}function Er(e,t){return j(e.getFullYear()%100,t,2)}function Ar(e,t){return e=dn(e),j(e.getFullYear()%100,t,2)}function Lr(e,t){return j(e.getFullYear()%1e4,t,4)}function Ir(e,t){var n=e.getDay();return e=n>=4||n===0?Te(e):Te.ceil(e),j(e.getFullYear()%1e4,t,4)}function Wr(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+j(t/60|0,"0",2)+j(t%60,"0",2)}function Vt(e,t){return j(e.getUTCDate(),t,2)}function Or(e,t){return j(e.getUTCHours(),t,2)}function Hr(e,t){return j(e.getUTCHours()%12||12,t,2)}function Nr(e,t){return j(1+_t.count(_e(e),e),t,3)}function hn(e,t){return j(e.getUTCMilliseconds(),t,3)}function Pr(e,t){return hn(e,t)+"000"}function Vr(e,t){return j(e.getUTCMonth()+1,t,2)}function zr(e,t){return j(e.getUTCMinutes(),t,2)}function Rr(e,t){return j(e.getUTCSeconds(),t,2)}function jr(e){var t=e.getUTCDay();return t===0?7:t}function qr(e,t){return j(ln.count(_e(e)-1,e),t,2)}function mn(e){var t=e.getUTCDay();return t>=4||t===0?Ye(e):Ye.ceil(e)}function Br(e,t){return e=mn(e),j(Ye.count(_e(e),e)+(_e(e).getUTCDay()===4),t,2)}function Zr(e){return e.getUTCDay()}function Xr(e,t){return j(Je.count(_e(e)-1,e),t,2)}function Gr(e,t){return j(e.getUTCFullYear()%100,t,2)}function $r(e,t){return e=mn(e),j(e.getUTCFullYear()%100,t,2)}function Qr(e,t){return j(e.getUTCFullYear()%1e4,t,4)}function Jr(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Ye(e):Ye.ceil(e),j(e.getUTCFullYear()%1e4,t,4)}function Kr(){return"+0000"}function zt(){return"%"}function Rt(e){return+e}function jt(e){return Math.floor(+e/1e3)}var De,Ke;ea({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function ea(e){return De=er(e),Ke=De.format,De.parse,De.utcFormat,De.utcParse,De}function ta(e){return new Date(e)}function na(e){return e instanceof Date?+e:+new Date(+e)}function gn(e,t,n,r,a,i,o,y,M,p){var g=Ce.continuous(),E=g.invert,D=g.domain,_=p(".%L"),Z=p(":%S"),O=p("%I:%M"),C=p("%I %p"),I=p("%a %d"),P=p("%b %d"),W=p("%B"),q=p("%Y");function $(w){return(M(w)<w?_:y(w)<w?Z:o(w)<w?O:i(w)<w?C:r(w)<w?a(w)<w?I:P:n(w)<w?W:q)(w)}return g.invert=function(w){return new Date(E(w))},g.domain=function(w){return arguments.length?D(Array.from(w,na)):D().map(ta)},g.ticks=function(w){var H=D();return e(H[0],H[H.length-1],w??10)},g.tickFormat=function(w,H){return H==null?$:p(H)},g.nice=function(w){var H=D();return(!w||typeof w.range!="function")&&(w=t(H[0],H[H.length-1],w??10)),w?D(zn(H,w)):g},g.copy=function(){return Ce.copy(g,gn(e,t,n,r,a,i,o,y,M,p))},g}function ra(){return wn.initRange.apply(gn(Jn,Kn,ye,He,Ne,ve,We,Ie,pe,Ke).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var Be={exports:{}},aa=Be.exports,qt;function ia(){return qt||(qt=1,(function(e,t){(function(n,r){e.exports=r()})(aa,(function(){var n="day";return function(r,a,i){var o=function(p){return p.add(4-p.isoWeekday(),n)},y=a.prototype;y.isoWeekYear=function(){return o(this).year()},y.isoWeek=function(p){if(!this.$utils().u(p))return this.add(7*(p-this.isoWeek()),n);var g,E,D,_,Z=o(this),O=(g=this.isoWeekYear(),E=this.$u,D=(E?i.utc:i)().year(g).startOf("year"),_=4-D.isoWeekday(),D.isoWeekday()>4&&(_+=7),D.add(_,n));return Z.diff(O,"week")+1},y.isoWeekday=function(p){return this.$utils().u(p)?this.day()||7:this.day(this.day()%7?p:p-7)};var M=y.startOf;y.startOf=function(p,g){var E=this.$utils(),D=!!E.u(g)||g;return E.p(p)==="isoweek"?D?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):M.bind(this)(p,g)}}}))})(Be)),Be.exports}var sa=ia();const oa=vt.getDefaultExportFromCjs(sa);var Ze={exports:{}},ca=Ze.exports,Bt;function ua(){return Bt||(Bt=1,(function(e,t){(function(n,r){e.exports=r()})(ca,(function(){var n={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,a=/\d/,i=/\d\d/,o=/\d\d?/,y=/\d*[^-_:/,()\s\d]+/,M={},p=function(C){return(C=+C)+(C>68?1900:2e3)},g=function(C){return function(I){this[C]=+I}},E=[/[+-]\d\d:?(\d\d)?|Z/,function(C){(this.zone||(this.zone={})).offset=(function(I){if(!I||I==="Z")return 0;var P=I.match(/([+-]|\d\d)/g),W=60*P[1]+(+P[2]||0);return W===0?0:P[0]==="+"?-W:W})(C)}],D=function(C){var I=M[C];return I&&(I.indexOf?I:I.s.concat(I.f))},_=function(C,I){var P,W=M.meridiem;if(W){for(var q=1;q<=24;q+=1)if(C.indexOf(W(q,0,I))>-1){P=q>12;break}}else P=C===(I?"pm":"PM");return P},Z={A:[y,function(C){this.afternoon=_(C,!1)}],a:[y,function(C){this.afternoon=_(C,!0)}],Q:[a,function(C){this.month=3*(C-1)+1}],S:[a,function(C){this.milliseconds=100*+C}],SS:[i,function(C){this.milliseconds=10*+C}],SSS:[/\d{3}/,function(C){this.milliseconds=+C}],s:[o,g("seconds")],ss:[o,g("seconds")],m:[o,g("minutes")],mm:[o,g("minutes")],H:[o,g("hours")],h:[o,g("hours")],HH:[o,g("hours")],hh:[o,g("hours")],D:[o,g("day")],DD:[i,g("day")],Do:[y,function(C){var I=M.ordinal,P=C.match(/\d+/);if(this.day=P[0],I)for(var W=1;W<=31;W+=1)I(W).replace(/\[|\]/g,"")===C&&(this.day=W)}],w:[o,g("week")],ww:[i,g("week")],M:[o,g("month")],MM:[i,g("month")],MMM:[y,function(C){var I=D("months"),P=(D("monthsShort")||I.map((function(W){return W.slice(0,3)}))).indexOf(C)+1;if(P<1)throw new Error;this.month=P%12||P}],MMMM:[y,function(C){var I=D("months").indexOf(C)+1;if(I<1)throw new Error;this.month=I%12||I}],Y:[/[+-]?\d+/,g("year")],YY:[i,function(C){this.year=p(C)}],YYYY:[/\d{4}/,g("year")],Z:E,ZZ:E};function O(C){var I,P;I=C,P=M&&M.formats;for(var W=(C=I.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(F,S,v){var U=v&&v.toUpperCase();return S||P[v]||n[v]||P[U].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(f,m,T){return m||T.slice(1)}))}))).match(r),q=W.length,$=0;$<q;$+=1){var w=W[$],H=Z[w],x=H&&H[0],Y=H&&H[1];W[$]=Y?{regex:x,parser:Y}:w.replace(/^\[|\]$/g,"")}return function(F){for(var S={},v=0,U=0;v<q;v+=1){var f=W[v];if(typeof f=="string")U+=f.length;else{var m=f.regex,T=f.parser,h=F.slice(U),b=m.exec(h)[0];T.call(S,b),F=F.replace(b,"")}}return(function(u){var l=u.afternoon;if(l!==void 0){var c=u.hours;l?c<12&&(u.hours+=12):c===12&&(u.hours=0),delete u.afternoon}})(S),S}}return function(C,I,P){P.p.customParseFormat=!0,C&&C.parseTwoDigitYear&&(p=C.parseTwoDigitYear);var W=I.prototype,q=W.parse;W.parse=function($){var w=$.date,H=$.utc,x=$.args;this.$u=H;var Y=x[1];if(typeof Y=="string"){var F=x[2]===!0,S=x[3]===!0,v=F||S,U=x[2];S&&(U=x[2]),M=this.$locale(),!F&&U&&(M=P.Ls[U]),this.$d=(function(h,b,u,l){try{if(["x","X"].indexOf(b)>-1)return new Date((b==="X"?1e3:1)*h);var c=O(b)(h),z=c.year,V=c.month,R=c.day,K=c.hours,X=c.minutes,Q=c.seconds,ae=c.milliseconds,k=c.zone,L=c.week,N=new Date,d=R||(z||V?1:N.getDate()),J=z||N.getFullYear(),A=0;z&&!V||(A=V>0?V-1:N.getMonth());var G,B=K||0,re=X||0,ie=Q||0,ke=ae||0;return k?new Date(Date.UTC(J,A,d,B,re,ie,ke+60*k.offset*1e3)):u?new Date(Date.UTC(J,A,d,B,re,ie,ke)):(G=new Date(J,A,d,B,re,ie,ke),L&&(G=l(G).week(L).toDate()),G)}catch{return new Date("")}})(w,Y,H,P),this.init(),U&&U!==!0&&(this.$L=this.locale(U).$L),v&&w!=this.format(Y)&&(this.$d=new Date("")),M={}}else if(Y instanceof Array)for(var f=Y.length,m=1;m<=f;m+=1){x[1]=Y[m-1];var T=P.apply(this,x);if(T.isValid()){this.$d=T.$d,this.$L=T.$L,this.init();break}m===f&&(this.$d=new Date(""))}else q.call(this,$)}}}))})(Ze)),Ze.exports}var la=ua();const fa=vt.getDefaultExportFromCjs(la);var Xe={exports:{}},da=Xe.exports,Zt;function ha(){return Zt||(Zt=1,(function(e,t){(function(n,r){e.exports=r()})(da,(function(){return function(n,r){var a=r.prototype,i=a.format;a.format=function(o){var y=this,M=this.$locale();if(!this.isValid())return i.bind(this)(o);var p=this.$utils(),g=(o||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(E){switch(E){case"Q":return Math.ceil((y.$M+1)/3);case"Do":return M.ordinal(y.$D);case"gggg":return y.weekYear();case"GGGG":return y.isoWeekYear();case"wo":return M.ordinal(y.week(),"W");case"w":case"ww":return p.s(y.week(),E==="w"?1:2,"0");case"W":case"WW":return p.s(y.isoWeek(),E==="W"?1:2,"0");case"k":case"kk":return p.s(String(y.$H===0?24:y.$H),E==="k"?1:2,"0");case"X":return Math.floor(y.$d.getTime()/1e3);case"x":return y.$d.getTime();case"z":return"["+y.offsetName()+"]";case"zzz":return"["+y.offsetName("long")+"]";default:return E}}));return i.bind(this)(g)}}}))})(Xe)),Xe.exports}var ma=ha();const ga=vt.getDefaultExportFromCjs(ma);var gt=(function(){var e=s.__name(function(U,f,m,T){for(m=m||{},T=U.length;T--;m[U[T]]=f);return m},"o"),t=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],n=[1,26],r=[1,27],a=[1,28],i=[1,29],o=[1,30],y=[1,31],M=[1,32],p=[1,33],g=[1,34],E=[1,9],D=[1,10],_=[1,11],Z=[1,12],O=[1,13],C=[1,14],I=[1,15],P=[1,16],W=[1,19],q=[1,20],$=[1,21],w=[1,22],H=[1,23],x=[1,25],Y=[1,35],F={trace:s.__name(function(){},"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:s.__name(function(f,m,T,h,b,u,l){var c=u.length-1;switch(b){case 1:return u[c-1];case 2:this.$=[];break;case 3:u[c-1].push(u[c]),this.$=u[c-1];break;case 4:case 5:this.$=u[c];break;case 6:case 7:this.$=[];break;case 8:h.setWeekday("monday");break;case 9:h.setWeekday("tuesday");break;case 10:h.setWeekday("wednesday");break;case 11:h.setWeekday("thursday");break;case 12:h.setWeekday("friday");break;case 13:h.setWeekday("saturday");break;case 14:h.setWeekday("sunday");break;case 15:h.setWeekend("friday");break;case 16:h.setWeekend("saturday");break;case 17:h.setDateFormat(u[c].substr(11)),this.$=u[c].substr(11);break;case 18:h.enableInclusiveEndDates(),this.$=u[c].substr(18);break;case 19:h.TopAxis(),this.$=u[c].substr(8);break;case 20:h.setAxisFormat(u[c].substr(11)),this.$=u[c].substr(11);break;case 21:h.setTickInterval(u[c].substr(13)),this.$=u[c].substr(13);break;case 22:h.setExcludes(u[c].substr(9)),this.$=u[c].substr(9);break;case 23:h.setIncludes(u[c].substr(9)),this.$=u[c].substr(9);break;case 24:h.setTodayMarker(u[c].substr(12)),this.$=u[c].substr(12);break;case 27:h.setDiagramTitle(u[c].substr(6)),this.$=u[c].substr(6);break;case 28:this.$=u[c].trim(),h.setAccTitle(this.$);break;case 29:case 30:this.$=u[c].trim(),h.setAccDescription(this.$);break;case 31:h.addSection(u[c].substr(8)),this.$=u[c].substr(8);break;case 33:h.addTask(u[c-1],u[c]),this.$="task";break;case 34:this.$=u[c-1],h.setClickEvent(u[c-1],u[c],null);break;case 35:this.$=u[c-2],h.setClickEvent(u[c-2],u[c-1],u[c]);break;case 36:this.$=u[c-2],h.setClickEvent(u[c-2],u[c-1],null),h.setLink(u[c-2],u[c]);break;case 37:this.$=u[c-3],h.setClickEvent(u[c-3],u[c-2],u[c-1]),h.setLink(u[c-3],u[c]);break;case 38:this.$=u[c-2],h.setClickEvent(u[c-2],u[c],null),h.setLink(u[c-2],u[c-1]);break;case 39:this.$=u[c-3],h.setClickEvent(u[c-3],u[c-1],u[c]),h.setLink(u[c-3],u[c-2]);break;case 40:this.$=u[c-1],h.setLink(u[c-1],u[c]);break;case 41:case 47:this.$=u[c-1]+" "+u[c];break;case 42:case 43:case 45:this.$=u[c-2]+" "+u[c-1]+" "+u[c];break;case 44:case 46:this.$=u[c-3]+" "+u[c-2]+" "+u[c-1]+" "+u[c];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},e(t,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:a,15:i,16:o,17:y,18:M,19:18,20:p,21:g,22:E,23:D,24:_,25:Z,26:O,27:C,28:I,29:P,30:W,31:q,33:$,35:w,36:H,37:24,38:x,40:Y},e(t,[2,7],{1:[2,1]}),e(t,[2,3]),{9:36,11:17,12:n,13:r,14:a,15:i,16:o,17:y,18:M,19:18,20:p,21:g,22:E,23:D,24:_,25:Z,26:O,27:C,28:I,29:P,30:W,31:q,33:$,35:w,36:H,37:24,38:x,40:Y},e(t,[2,5]),e(t,[2,6]),e(t,[2,17]),e(t,[2,18]),e(t,[2,19]),e(t,[2,20]),e(t,[2,21]),e(t,[2,22]),e(t,[2,23]),e(t,[2,24]),e(t,[2,25]),e(t,[2,26]),e(t,[2,27]),{32:[1,37]},{34:[1,38]},e(t,[2,30]),e(t,[2,31]),e(t,[2,32]),{39:[1,39]},e(t,[2,8]),e(t,[2,9]),e(t,[2,10]),e(t,[2,11]),e(t,[2,12]),e(t,[2,13]),e(t,[2,14]),e(t,[2,15]),e(t,[2,16]),{41:[1,40],43:[1,41]},e(t,[2,4]),e(t,[2,28]),e(t,[2,29]),e(t,[2,33]),e(t,[2,34],{42:[1,42],43:[1,43]}),e(t,[2,40],{41:[1,44]}),e(t,[2,35],{43:[1,45]}),e(t,[2,36]),e(t,[2,38],{42:[1,46]}),e(t,[2,37]),e(t,[2,39])],defaultActions:{},parseError:s.__name(function(f,m){if(m.recoverable)this.trace(f);else{var T=new Error(f);throw T.hash=m,T}},"parseError"),parse:s.__name(function(f){var m=this,T=[0],h=[],b=[null],u=[],l=this.table,c="",z=0,V=0,R=2,K=1,X=u.slice.call(arguments,1),Q=Object.create(this.lexer),ae={yy:{}};for(var k in this.yy)Object.prototype.hasOwnProperty.call(this.yy,k)&&(ae.yy[k]=this.yy[k]);Q.setInput(f,ae.yy),ae.yy.lexer=Q,ae.yy.parser=this,typeof Q.yylloc>"u"&&(Q.yylloc={});var L=Q.yylloc;u.push(L);var N=Q.options&&Q.options.ranges;typeof ae.yy.parseError=="function"?this.parseError=ae.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function d(se){T.length=T.length-2*se,b.length=b.length-se,u.length=u.length-se}s.__name(d,"popStack");function J(){var se;return se=h.pop()||Q.lex()||K,typeof se!="number"&&(se instanceof Array&&(h=se,se=h.pop()),se=m.symbols_[se]||se),se}s.__name(J,"lex");for(var A,G,B,re,ie={},ke,ce,Et,Re;;){if(G=T[T.length-1],this.defaultActions[G]?B=this.defaultActions[G]:((A===null||typeof A>"u")&&(A=J()),B=l[G]&&l[G][A]),typeof B>"u"||!B.length||!B[0]){var nt="";Re=[];for(ke in l[G])this.terminals_[ke]&&ke>R&&Re.push("'"+this.terminals_[ke]+"'");Q.showPosition?nt="Parse error on line "+(z+1)+`:
|
|
2
|
-
`+Q.showPosition()+`
|
|
3
|
-
Expecting `+Re.join(", ")+", got '"+(this.terminals_[A]||A)+"'":nt="Parse error on line "+(z+1)+": Unexpected "+(A==K?"end of input":"'"+(this.terminals_[A]||A)+"'"),this.parseError(nt,{text:Q.match,token:this.terminals_[A]||A,line:Q.yylineno,loc:L,expected:Re})}if(B[0]instanceof Array&&B.length>1)throw new Error("Parse Error: multiple actions possible at state: "+G+", token: "+A);switch(B[0]){case 1:T.push(A),b.push(Q.yytext),u.push(Q.yylloc),T.push(B[1]),A=null,V=Q.yyleng,c=Q.yytext,z=Q.yylineno,L=Q.yylloc;break;case 2:if(ce=this.productions_[B[1]][1],ie.$=b[b.length-ce],ie._$={first_line:u[u.length-(ce||1)].first_line,last_line:u[u.length-1].last_line,first_column:u[u.length-(ce||1)].first_column,last_column:u[u.length-1].last_column},N&&(ie._$.range=[u[u.length-(ce||1)].range[0],u[u.length-1].range[1]]),re=this.performAction.apply(ie,[c,V,z,ae.yy,B[1],b,u].concat(X)),typeof re<"u")return re;ce&&(T=T.slice(0,-1*ce*2),b=b.slice(0,-1*ce),u=u.slice(0,-1*ce)),T.push(this.productions_[B[1]][0]),b.push(ie.$),u.push(ie._$),Et=l[T[T.length-2]][T[T.length-1]],T.push(Et);break;case 3:return!0}}return!0},"parse")},S=(function(){var U={EOF:1,parseError:s.__name(function(m,T){if(this.yy.parser)this.yy.parser.parseError(m,T);else throw new Error(m)},"parseError"),setInput:s.__name(function(f,m){return this.yy=m||this.yy||{},this._input=f,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:s.__name(function(){var f=this._input[0];this.yytext+=f,this.yyleng++,this.offset++,this.match+=f,this.matched+=f;var m=f.match(/(?:\r\n?|\n).*/g);return m?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),f},"input"),unput:s.__name(function(f){var m=f.length,T=f.split(/(?:\r\n?|\n)/g);this._input=f+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-m),this.offset-=m;var h=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),T.length-1&&(this.yylineno-=T.length-1);var b=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:T?(T.length===h.length?this.yylloc.first_column:0)+h[h.length-T.length].length-T[0].length:this.yylloc.first_column-m},this.options.ranges&&(this.yylloc.range=[b[0],b[0]+this.yyleng-m]),this.yyleng=this.yytext.length,this},"unput"),more:s.__name(function(){return this._more=!0,this},"more"),reject:s.__name(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
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:s.__name(function(f){this.unput(this.match.slice(f))},"less"),pastInput:s.__name(function(){var f=this.matched.substr(0,this.matched.length-this.match.length);return(f.length>20?"...":"")+f.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:s.__name(function(){var f=this.match;return f.length<20&&(f+=this._input.substr(0,20-f.length)),(f.substr(0,20)+(f.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:s.__name(function(){var f=this.pastInput(),m=new Array(f.length+1).join("-");return f+this.upcomingInput()+`
|
|
5
|
-
`+m+"^"},"showPosition"),test_match:s.__name(function(f,m){var T,h,b;if(this.options.backtrack_lexer&&(b={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(b.yylloc.range=this.yylloc.range.slice(0))),h=f[0].match(/(?:\r\n?|\n).*/g),h&&(this.yylineno+=h.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:h?h[h.length-1].length-h[h.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+f[0].length},this.yytext+=f[0],this.match+=f[0],this.matches=f,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(f[0].length),this.matched+=f[0],T=this.performAction.call(this,this.yy,this,m,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),T)return T;if(this._backtrack){for(var u in b)this[u]=b[u];return!1}return!1},"test_match"),next:s.__name(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var f,m,T,h;this._more||(this.yytext="",this.match="");for(var b=this._currentRules(),u=0;u<b.length;u++)if(T=this._input.match(this.rules[b[u]]),T&&(!m||T[0].length>m[0].length)){if(m=T,h=u,this.options.backtrack_lexer){if(f=this.test_match(T,b[u]),f!==!1)return f;if(this._backtrack){m=!1;continue}else return!1}else if(!this.options.flex)break}return m?(f=this.test_match(m,b[h]),f!==!1?f:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:s.__name(function(){var m=this.next();return m||this.lex()},"lex"),begin:s.__name(function(m){this.conditionStack.push(m)},"begin"),popState:s.__name(function(){var m=this.conditionStack.length-1;return m>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:s.__name(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:s.__name(function(m){return m=this.conditionStack.length-1-Math.abs(m||0),m>=0?this.conditionStack[m]:"INITIAL"},"topState"),pushState:s.__name(function(m){this.begin(m)},"pushState"),stateStackSize:s.__name(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:s.__name(function(m,T,h,b){switch(h){case 0:return this.begin("open_directive"),"open_directive";case 1:return this.begin("acc_title"),31;case 2:return this.popState(),"acc_title_value";case 3:return this.begin("acc_descr"),33;case 4:return this.popState(),"acc_descr_value";case 5:this.begin("acc_descr_multiline");break;case 6:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:break;case 9:break;case 10:break;case 11:return 10;case 12:break;case 13:break;case 14:this.begin("href");break;case 15:this.popState();break;case 16:return 43;case 17:this.begin("callbackname");break;case 18:this.popState();break;case 19:this.popState(),this.begin("callbackargs");break;case 20:return 41;case 21:this.popState();break;case 22:return 42;case 23:this.begin("click");break;case 24:this.popState();break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return"date";case 45:return 30;case 46:return"accDescription";case 47:return 36;case 48:return 38;case 49:return 39;case 50:return":";case 51:return 6;case 52:return"INVALID"}},"anonymous"),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}};return U})();F.lexer=S;function v(){this.yy={}}return s.__name(v,"Parser"),v.prototype=F,F.Parser=v,new v})();gt.parser=gt;var ya=gt;s.dayjs2.extend(oa);s.dayjs2.extend(fa);s.dayjs2.extend(ga);var Xt={friday:5,saturday:6},ue="",xt="",bt=void 0,wt="",Pe=[],Ve=[],Dt=new Map,Ct=[],et=[],Ue="",Mt="",yn=["active","done","crit","milestone","vert"],St=[],ze=!1,Ft=!1,Yt="sunday",tt="saturday",yt=0,ka=s.__name(function(){Ct=[],et=[],Ue="",St=[],Ge=0,pt=void 0,$e=void 0,ee=[],ue="",xt="",Mt="",bt=void 0,wt="",Pe=[],Ve=[],ze=!1,Ft=!1,yt=0,Dt=new Map,s.clear(),Yt="sunday",tt="saturday"},"clear"),pa=s.__name(function(e){xt=e},"setAxisFormat"),va=s.__name(function(){return xt},"getAxisFormat"),Ta=s.__name(function(e){bt=e},"setTickInterval"),_a=s.__name(function(){return bt},"getTickInterval"),xa=s.__name(function(e){wt=e},"setTodayMarker"),ba=s.__name(function(){return wt},"getTodayMarker"),wa=s.__name(function(e){ue=e},"setDateFormat"),Da=s.__name(function(){ze=!0},"enableInclusiveEndDates"),Ca=s.__name(function(){return ze},"endDatesAreInclusive"),Ma=s.__name(function(){Ft=!0},"enableTopAxis"),Sa=s.__name(function(){return Ft},"topAxisEnabled"),Fa=s.__name(function(e){Mt=e},"setDisplayMode"),Ya=s.__name(function(){return Mt},"getDisplayMode"),Ua=s.__name(function(){return ue},"getDateFormat"),Ea=s.__name(function(e){Pe=e.toLowerCase().split(/[\s,]+/)},"setIncludes"),Aa=s.__name(function(){return Pe},"getIncludes"),La=s.__name(function(e){Ve=e.toLowerCase().split(/[\s,]+/)},"setExcludes"),Ia=s.__name(function(){return Ve},"getExcludes"),Wa=s.__name(function(){return Dt},"getLinks"),Oa=s.__name(function(e){Ue=e,Ct.push(e)},"addSection"),Ha=s.__name(function(){return Ct},"getSections"),Na=s.__name(function(){let e=Gt();const t=10;let n=0;for(;!e&&n<t;)e=Gt(),n++;return et=ee,et},"getTasks"),kn=s.__name(function(e,t,n,r){const a=e.format(t.trim()),i=e.format("YYYY-MM-DD");return r.includes(a)||r.includes(i)?!1:n.includes("weekends")&&(e.isoWeekday()===Xt[tt]||e.isoWeekday()===Xt[tt]+1)||n.includes(e.format("dddd").toLowerCase())?!0:n.includes(a)||n.includes(i)},"isInvalidDate"),Pa=s.__name(function(e){Yt=e},"setWeekday"),Va=s.__name(function(){return Yt},"getWeekday"),za=s.__name(function(e){tt=e},"setWeekend"),pn=s.__name(function(e,t,n,r){if(!n.length||e.manualEndTime)return;let a;e.startTime instanceof Date?a=s.dayjs2(e.startTime):a=s.dayjs2(e.startTime,t,!0),a=a.add(1,"d");let i;e.endTime instanceof Date?i=s.dayjs2(e.endTime):i=s.dayjs2(e.endTime,t,!0);const[o,y]=Ra(a,i,t,n,r);e.endTime=o.toDate(),e.renderEndTime=y},"checkTaskDates"),Ra=s.__name(function(e,t,n,r,a){let i=!1,o=null;for(;e<=t;)i||(o=t.toDate()),i=kn(e,n,r,a),i&&(t=t.add(1,"d")),e=e.add(1,"d");return[t,o]},"fixTaskDates"),kt=s.__name(function(e,t,n){if(n=n.trim(),(t.trim()==="x"||t.trim()==="X")&&/^\d+$/.test(n))return new Date(Number(n));const a=/^after\s+(?<ids>[\d\w- ]+)/.exec(n);if(a!==null){let o=null;for(const M of a.groups.ids.split(" ")){let p=we(M);p!==void 0&&(!o||p.endTime>o.endTime)&&(o=p)}if(o)return o.endTime;const y=new Date;return y.setHours(0,0,0,0),y}let i=s.dayjs2(n,t.trim(),!0);if(i.isValid())return i.toDate();{s.log.debug("Invalid date:"+n),s.log.debug("With date format:"+t.trim());const o=new Date(n);if(o===void 0||isNaN(o.getTime())||o.getFullYear()<-1e4||o.getFullYear()>1e4)throw new Error("Invalid date:"+n);return o}},"getStartDate"),vn=s.__name(function(e){const t=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(e.trim());return t!==null?[Number.parseFloat(t[1]),t[2]]:[NaN,"ms"]},"parseDuration"),Tn=s.__name(function(e,t,n,r=!1){n=n.trim();const i=/^until\s+(?<ids>[\d\w- ]+)/.exec(n);if(i!==null){let g=null;for(const D of i.groups.ids.split(" ")){let _=we(D);_!==void 0&&(!g||_.startTime<g.startTime)&&(g=_)}if(g)return g.startTime;const E=new Date;return E.setHours(0,0,0,0),E}let o=s.dayjs2(n,t.trim(),!0);if(o.isValid())return r&&(o=o.add(1,"d")),o.toDate();let y=s.dayjs2(e);const[M,p]=vn(n);if(!Number.isNaN(M)){const g=y.add(M,p);g.isValid()&&(y=g)}return y.toDate()},"getEndDate"),Ge=0,Se=s.__name(function(e){return e===void 0?(Ge=Ge+1,"task"+Ge):e},"parseId"),ja=s.__name(function(e,t){let n;t.substr(0,1)===":"?n=t.substr(1,t.length):n=t;const r=n.split(","),a={};Ut(r,a,yn);for(let o=0;o<r.length;o++)r[o]=r[o].trim();let i="";switch(r.length){case 1:a.id=Se(),a.startTime=e.endTime,i=r[0];break;case 2:a.id=Se(),a.startTime=kt(void 0,ue,r[0]),i=r[1];break;case 3:a.id=Se(r[0]),a.startTime=kt(void 0,ue,r[1]),i=r[2];break}return i&&(a.endTime=Tn(a.startTime,ue,i,ze),a.manualEndTime=s.dayjs2(i,"YYYY-MM-DD",!0).isValid(),pn(a,ue,Ve,Pe)),a},"compileData"),qa=s.__name(function(e,t){let n;t.substr(0,1)===":"?n=t.substr(1,t.length):n=t;const r=n.split(","),a={};Ut(r,a,yn);for(let i=0;i<r.length;i++)r[i]=r[i].trim();switch(r.length){case 1:a.id=Se(),a.startTime={type:"prevTaskEnd",id:e},a.endTime={data:r[0]};break;case 2:a.id=Se(),a.startTime={type:"getStartDate",startData:r[0]},a.endTime={data:r[1]};break;case 3:a.id=Se(r[0]),a.startTime={type:"getStartDate",startData:r[1]},a.endTime={data:r[2]};break}return a},"parseData"),pt,$e,ee=[],_n={},Ba=s.__name(function(e,t){const n={section:Ue,type:Ue,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:t},task:e,classes:[]},r=qa($e,t);n.raw.startTime=r.startTime,n.raw.endTime=r.endTime,n.id=r.id,n.prevTaskId=$e,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,n.vert=r.vert,n.order=yt,yt++;const a=ee.push(n);$e=n.id,_n[n.id]=a-1},"addTask"),we=s.__name(function(e){const t=_n[e];return ee[t]},"findTaskById"),Za=s.__name(function(e,t){const n={section:Ue,type:Ue,description:e,task:e,classes:[]},r=ja(pt,t);n.startTime=r.startTime,n.endTime=r.endTime,n.id=r.id,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,n.vert=r.vert,pt=n,et.push(n)},"addTaskOrg"),Gt=s.__name(function(){const e=s.__name(function(n){const r=ee[n];let a="";switch(ee[n].raw.startTime.type){case"prevTaskEnd":{const i=we(r.prevTaskId);r.startTime=i.endTime;break}case"getStartDate":a=kt(void 0,ue,ee[n].raw.startTime.startData),a&&(ee[n].startTime=a);break}return ee[n].startTime&&(ee[n].endTime=Tn(ee[n].startTime,ue,ee[n].raw.endTime.data,ze),ee[n].endTime&&(ee[n].processed=!0,ee[n].manualEndTime=s.dayjs2(ee[n].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),pn(ee[n],ue,Ve,Pe))),ee[n].processed},"compileTask");let t=!0;for(const[n,r]of ee.entries())e(n),t=t&&r.processed;return t},"compileTasks"),Xa=s.__name(function(e,t){let n=t;s.getConfig2().securityLevel!=="loose"&&(n=s.distExports.sanitizeUrl(t)),e.split(",").forEach(function(r){we(r)!==void 0&&(bn(r,()=>{window.open(n,"_self")}),Dt.set(r,n))}),xn(e,"clickable")},"setLink"),xn=s.__name(function(e,t){e.split(",").forEach(function(n){let r=we(n);r!==void 0&&r.classes.push(t)})},"setClass"),Ga=s.__name(function(e,t,n){if(s.getConfig2().securityLevel!=="loose"||t===void 0)return;let r=[];if(typeof n=="string"){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let i=0;i<r.length;i++){let o=r[i].trim();o.startsWith('"')&&o.endsWith('"')&&(o=o.substr(1,o.length-2)),r[i]=o}}r.length===0&&r.push(e),we(e)!==void 0&&bn(e,()=>{s.utils_default.runFunc(t,...r)})},"setClickFun"),bn=s.__name(function(e,t){St.push(function(){const n=document.querySelector(`[id="${e}"]`);n!==null&&n.addEventListener("click",function(){t()})},function(){const n=document.querySelector(`[id="${e}-text"]`);n!==null&&n.addEventListener("click",function(){t()})})},"pushFun"),$a=s.__name(function(e,t,n){e.split(",").forEach(function(r){Ga(r,t,n)}),xn(e,"clickable")},"setClickEvent"),Qa=s.__name(function(e){St.forEach(function(t){t(e)})},"bindFunctions"),Ja={getConfig:s.__name(()=>s.getConfig2().gantt,"getConfig"),clear:ka,setDateFormat:wa,getDateFormat:Ua,enableInclusiveEndDates:Da,endDatesAreInclusive:Ca,enableTopAxis:Ma,topAxisEnabled:Sa,setAxisFormat:pa,getAxisFormat:va,setTickInterval:Ta,getTickInterval:_a,setTodayMarker:xa,getTodayMarker:ba,setAccTitle:s.setAccTitle,getAccTitle:s.getAccTitle,setDiagramTitle:s.setDiagramTitle,getDiagramTitle:s.getDiagramTitle,setDisplayMode:Fa,getDisplayMode:Ya,setAccDescription:s.setAccDescription,getAccDescription:s.getAccDescription,addSection:Oa,getSections:Ha,getTasks:Na,addTask:Ba,findTaskById:we,addTaskOrg:Za,setIncludes:Ea,getIncludes:Aa,setExcludes:La,getExcludes:Ia,setClickEvent:$a,setLink:Xa,getLinks:Wa,bindFunctions:Qa,parseDuration:vn,isInvalidDate:kn,setWeekday:Pa,getWeekday:Va,setWeekend:za};function Ut(e,t,n){let r=!0;for(;r;)r=!1,n.forEach(function(a){const i="^\\s*"+a+"\\s*$",o=new RegExp(i);e[0].match(o)&&(t[a]=!0,e.shift(1),r=!0)})}s.__name(Ut,"getTaskTags");var Ka=s.__name(function(){s.log.debug("Something is calling, setConf, remove the call")},"setConf"),$t={monday:Oe,tuesday:sn,wednesday:on,thursday:Te,friday:cn,saturday:un,sunday:Ne},ei=s.__name((e,t)=>{let n=[...e].map(()=>-1/0),r=[...e].sort((i,o)=>i.startTime-o.startTime||i.order-o.order),a=0;for(const i of r)for(let o=0;o<n.length;o++)if(i.startTime>=n[o]){n[o]=i.endTime,i.order=o+t,o>a&&(a=o);break}return a},"getMaxIntersections"),fe,ti=s.__name(function(e,t,n,r){const a=s.getConfig2().gantt,i=s.getConfig2().securityLevel;let o;i==="sandbox"&&(o=s.select("#i"+t));const y=i==="sandbox"?s.select(o.nodes()[0].contentDocument.body):s.select("body"),M=i==="sandbox"?o.nodes()[0].contentDocument:document,p=M.getElementById(t);fe=p.parentElement.offsetWidth,fe===void 0&&(fe=1200),a.useWidth!==void 0&&(fe=a.useWidth);const g=r.db.getTasks();let E=[];for(const x of g)E.push(x.type);E=H(E);const D={};let _=2*a.topPadding;if(r.db.getDisplayMode()==="compact"||a.displayMode==="compact"){const x={};for(const F of g)x[F.section]===void 0?x[F.section]=[F]:x[F.section].push(F);let Y=0;for(const F of Object.keys(x)){const S=ei(x[F],Y)+1;Y+=S,_+=S*(a.barHeight+a.barGap),D[F]=S}}else{_+=g.length*(a.barHeight+a.barGap);for(const x of E)D[x]=g.filter(Y=>Y.type===x).length}p.setAttribute("viewBox","0 0 "+fe+" "+_);const Z=y.select(`[id="${t}"]`),O=ra().domain([Cn(g,function(x){return x.startTime}),Dn(g,function(x){return x.endTime})]).rangeRound([0,fe-a.leftPadding-a.rightPadding]);function C(x,Y){const F=x.startTime,S=Y.startTime;let v=0;return F>S?v=1:F<S&&(v=-1),v}s.__name(C,"taskCompare"),g.sort(C),I(g,fe,_),s.configureSvgSize(Z,_,fe,a.useMaxWidth),Z.append("text").text(r.db.getDiagramTitle()).attr("x",fe/2).attr("y",a.titleTopMargin).attr("class","titleText");function I(x,Y,F){const S=a.barHeight,v=S+a.barGap,U=a.topPadding,f=a.leftPadding,m=Ce.linear().domain([0,E.length]).range(["#00B9FA","#F95002"]).interpolate(Vn);W(v,U,f,Y,F,x,r.db.getExcludes(),r.db.getIncludes()),q(f,U,Y,F),P(x,v,U,f,S,m,Y),$(v,U),w(f,U,Y,F)}s.__name(I,"makeGantt");function P(x,Y,F,S,v,U,f){x.sort((l,c)=>l.vert===c.vert?0:l.vert?1:-1);const T=[...new Set(x.map(l=>l.order))].map(l=>x.find(c=>c.order===l));Z.append("g").selectAll("rect").data(T).enter().append("rect").attr("x",0).attr("y",function(l,c){return c=l.order,c*Y+F-2}).attr("width",function(){return f-a.rightPadding/2}).attr("height",Y).attr("class",function(l){for(const[c,z]of E.entries())if(l.type===z)return"section section"+c%a.numberSectionStyles;return"section section0"}).enter();const h=Z.append("g").selectAll("rect").data(x).enter(),b=r.db.getLinks();if(h.append("rect").attr("id",function(l){return l.id}).attr("rx",3).attr("ry",3).attr("x",function(l){return l.milestone?O(l.startTime)+S+.5*(O(l.endTime)-O(l.startTime))-.5*v:O(l.startTime)+S}).attr("y",function(l,c){return c=l.order,l.vert?a.gridLineStartPadding:c*Y+F}).attr("width",function(l){return l.milestone?v:l.vert?.08*v:O(l.renderEndTime||l.endTime)-O(l.startTime)}).attr("height",function(l){return l.vert?g.length*(a.barHeight+a.barGap)+a.barHeight*2:v}).attr("transform-origin",function(l,c){return c=l.order,(O(l.startTime)+S+.5*(O(l.endTime)-O(l.startTime))).toString()+"px "+(c*Y+F+.5*v).toString()+"px"}).attr("class",function(l){const c="task";let z="";l.classes.length>0&&(z=l.classes.join(" "));let V=0;for(const[K,X]of E.entries())l.type===X&&(V=K%a.numberSectionStyles);let R="";return l.active?l.crit?R+=" activeCrit":R=" active":l.done?l.crit?R=" doneCrit":R=" done":l.crit&&(R+=" crit"),R.length===0&&(R=" task"),l.milestone&&(R=" milestone "+R),l.vert&&(R=" vert "+R),R+=V,R+=" "+z,c+R}),h.append("text").attr("id",function(l){return l.id+"-text"}).text(function(l){return l.task}).attr("font-size",a.fontSize).attr("x",function(l){let c=O(l.startTime),z=O(l.renderEndTime||l.endTime);if(l.milestone&&(c+=.5*(O(l.endTime)-O(l.startTime))-.5*v,z=c+v),l.vert)return O(l.startTime)+S;const V=this.getBBox().width;return V>z-c?z+V+1.5*a.leftPadding>f?c+S-5:z+S+5:(z-c)/2+c+S}).attr("y",function(l,c){return l.vert?a.gridLineStartPadding+g.length*(a.barHeight+a.barGap)+60:(c=l.order,c*Y+a.barHeight/2+(a.fontSize/2-2)+F)}).attr("text-height",v).attr("class",function(l){const c=O(l.startTime);let z=O(l.endTime);l.milestone&&(z=c+v);const V=this.getBBox().width;let R="";l.classes.length>0&&(R=l.classes.join(" "));let K=0;for(const[Q,ae]of E.entries())l.type===ae&&(K=Q%a.numberSectionStyles);let X="";return l.active&&(l.crit?X="activeCritText"+K:X="activeText"+K),l.done?l.crit?X=X+" doneCritText"+K:X=X+" doneText"+K:l.crit&&(X=X+" critText"+K),l.milestone&&(X+=" milestoneText"),l.vert&&(X+=" vertText"),V>z-c?z+V+1.5*a.leftPadding>f?R+" taskTextOutsideLeft taskTextOutside"+K+" "+X:R+" taskTextOutsideRight taskTextOutside"+K+" "+X+" width-"+V:R+" taskText taskText"+K+" "+X+" width-"+V}),s.getConfig2().securityLevel==="sandbox"){let l;l=s.select("#i"+t);const c=l.nodes()[0].contentDocument;h.filter(function(z){return b.has(z.id)}).each(function(z){var V=c.querySelector("#"+z.id),R=c.querySelector("#"+z.id+"-text");const K=V.parentNode;var X=c.createElement("a");X.setAttribute("xlink:href",b.get(z.id)),X.setAttribute("target","_top"),K.appendChild(X),X.appendChild(V),X.appendChild(R)})}}s.__name(P,"drawRects");function W(x,Y,F,S,v,U,f,m){if(f.length===0&&m.length===0)return;let T,h;for(const{startTime:V,endTime:R}of U)(T===void 0||V<T)&&(T=V),(h===void 0||R>h)&&(h=R);if(!T||!h)return;if(s.dayjs2(h).diff(s.dayjs2(T),"year")>5){s.log.warn("The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.");return}const b=r.db.getDateFormat(),u=[];let l=null,c=s.dayjs2(T);for(;c.valueOf()<=h;)r.db.isInvalidDate(c,b,f,m)?l?l.end=c:l={start:c,end:c}:l&&(u.push(l),l=null),c=c.add(1,"d");Z.append("g").selectAll("rect").data(u).enter().append("rect").attr("id",V=>"exclude-"+V.start.format("YYYY-MM-DD")).attr("x",V=>O(V.start.startOf("day"))+F).attr("y",a.gridLineStartPadding).attr("width",V=>O(V.end.endOf("day"))-O(V.start.startOf("day"))).attr("height",v-Y-a.gridLineStartPadding).attr("transform-origin",function(V,R){return(O(V.start)+F+.5*(O(V.end)-O(V.start))).toString()+"px "+(R*x+.5*v).toString()+"px"}).attr("class","exclude-range")}s.__name(W,"drawExcludeDays");function q(x,Y,F,S){const v=r.db.getDateFormat(),U=r.db.getAxisFormat();let f;U?f=U:v==="D"?f="%d":f=a.axisFormat??"%Y-%m-%d";let m=Ln(O).tickSize(-S+Y+a.gridLineStartPadding).tickFormat(Ke(f));const h=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||a.tickInterval);if(h!==null){const b=h[1],u=h[2],l=r.db.getWeekday()||a.weekday;switch(u){case"millisecond":m.ticks(Fe.every(b));break;case"second":m.ticks(pe.every(b));break;case"minute":m.ticks(Ie.every(b));break;case"hour":m.ticks(We.every(b));break;case"day":m.ticks(ve.every(b));break;case"week":m.ticks($t[l].every(b));break;case"month":m.ticks(He.every(b));break}}if(Z.append("g").attr("class","grid").attr("transform","translate("+x+", "+(S-50)+")").call(m).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),r.db.topAxisEnabled()||a.topAxis){let b=An(O).tickSize(-S+Y+a.gridLineStartPadding).tickFormat(Ke(f));if(h!==null){const u=h[1],l=h[2],c=r.db.getWeekday()||a.weekday;switch(l){case"millisecond":b.ticks(Fe.every(u));break;case"second":b.ticks(pe.every(u));break;case"minute":b.ticks(Ie.every(u));break;case"hour":b.ticks(We.every(u));break;case"day":b.ticks(ve.every(u));break;case"week":b.ticks($t[c].every(u));break;case"month":b.ticks(He.every(u));break}}Z.append("g").attr("class","grid").attr("transform","translate("+x+", "+Y+")").call(b).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}s.__name(q,"makeGrid");function $(x,Y){let F=0;const S=Object.keys(D).map(v=>[v,D[v]]);Z.append("g").selectAll("text").data(S).enter().append(function(v){const U=v[0].split(s.common_default.lineBreakRegex),f=-(U.length-1)/2,m=M.createElementNS("http://www.w3.org/2000/svg","text");m.setAttribute("dy",f+"em");for(const[T,h]of U.entries()){const b=M.createElementNS("http://www.w3.org/2000/svg","tspan");b.setAttribute("alignment-baseline","central"),b.setAttribute("x","10"),T>0&&b.setAttribute("dy","1em"),b.textContent=h,m.appendChild(b)}return m}).attr("x",10).attr("y",function(v,U){if(U>0)for(let f=0;f<U;f++)return F+=S[U-1][1],v[1]*x/2+F*x+Y;else return v[1]*x/2+Y}).attr("font-size",a.sectionFontSize).attr("class",function(v){for(const[U,f]of E.entries())if(v[0]===f)return"sectionTitle sectionTitle"+U%a.numberSectionStyles;return"sectionTitle"})}s.__name($,"vertLabels");function w(x,Y,F,S){const v=r.db.getTodayMarker();if(v==="off")return;const U=Z.append("g").attr("class","today"),f=new Date,m=U.append("line");m.attr("x1",O(f)+x).attr("x2",O(f)+x).attr("y1",a.titleTopMargin).attr("y2",S-a.titleTopMargin).attr("class","today"),v!==""&&m.attr("style",v.replace(/,/g,";"))}s.__name(w,"drawToday");function H(x){const Y={},F=[];for(let S=0,v=x.length;S<v;++S)Object.prototype.hasOwnProperty.call(Y,x[S])||(Y[x[S]]=!0,F.push(x[S]));return F}s.__name(H,"checkUnique")},"draw"),ni={setConf:Ka,draw:ti},ri=s.__name(e=>`
|
|
7
|
-
.mermaid-main-font {
|
|
8
|
-
font-family: ${e.fontFamily};
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.exclude-range {
|
|
12
|
-
fill: ${e.excludeBkgColor};
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
.section {
|
|
16
|
-
stroke: none;
|
|
17
|
-
opacity: 0.2;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
.section0 {
|
|
21
|
-
fill: ${e.sectionBkgColor};
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
.section2 {
|
|
25
|
-
fill: ${e.sectionBkgColor2};
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.section1,
|
|
29
|
-
.section3 {
|
|
30
|
-
fill: ${e.altSectionBkgColor};
|
|
31
|
-
opacity: 0.2;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
.sectionTitle0 {
|
|
35
|
-
fill: ${e.titleColor};
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
.sectionTitle1 {
|
|
39
|
-
fill: ${e.titleColor};
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.sectionTitle2 {
|
|
43
|
-
fill: ${e.titleColor};
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.sectionTitle3 {
|
|
47
|
-
fill: ${e.titleColor};
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
.sectionTitle {
|
|
51
|
-
text-anchor: start;
|
|
52
|
-
font-family: ${e.fontFamily};
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
/* Grid and axis */
|
|
57
|
-
|
|
58
|
-
.grid .tick {
|
|
59
|
-
stroke: ${e.gridColor};
|
|
60
|
-
opacity: 0.8;
|
|
61
|
-
shape-rendering: crispEdges;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
.grid .tick text {
|
|
65
|
-
font-family: ${e.fontFamily};
|
|
66
|
-
fill: ${e.textColor};
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
.grid path {
|
|
70
|
-
stroke-width: 0;
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
/* Today line */
|
|
75
|
-
|
|
76
|
-
.today {
|
|
77
|
-
fill: none;
|
|
78
|
-
stroke: ${e.todayLineColor};
|
|
79
|
-
stroke-width: 2px;
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
/* Task styling */
|
|
84
|
-
|
|
85
|
-
/* Default task */
|
|
86
|
-
|
|
87
|
-
.task {
|
|
88
|
-
stroke-width: 2;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
.taskText {
|
|
92
|
-
text-anchor: middle;
|
|
93
|
-
font-family: ${e.fontFamily};
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.taskTextOutsideRight {
|
|
97
|
-
fill: ${e.taskTextDarkColor};
|
|
98
|
-
text-anchor: start;
|
|
99
|
-
font-family: ${e.fontFamily};
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
.taskTextOutsideLeft {
|
|
103
|
-
fill: ${e.taskTextDarkColor};
|
|
104
|
-
text-anchor: end;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
/* Special case clickable */
|
|
109
|
-
|
|
110
|
-
.task.clickable {
|
|
111
|
-
cursor: pointer;
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
.taskText.clickable {
|
|
115
|
-
cursor: pointer;
|
|
116
|
-
fill: ${e.taskTextClickableColor} !important;
|
|
117
|
-
font-weight: bold;
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
.taskTextOutsideLeft.clickable {
|
|
121
|
-
cursor: pointer;
|
|
122
|
-
fill: ${e.taskTextClickableColor} !important;
|
|
123
|
-
font-weight: bold;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.taskTextOutsideRight.clickable {
|
|
127
|
-
cursor: pointer;
|
|
128
|
-
fill: ${e.taskTextClickableColor} !important;
|
|
129
|
-
font-weight: bold;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
/* Specific task settings for the sections*/
|
|
134
|
-
|
|
135
|
-
.taskText0,
|
|
136
|
-
.taskText1,
|
|
137
|
-
.taskText2,
|
|
138
|
-
.taskText3 {
|
|
139
|
-
fill: ${e.taskTextColor};
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
.task0,
|
|
143
|
-
.task1,
|
|
144
|
-
.task2,
|
|
145
|
-
.task3 {
|
|
146
|
-
fill: ${e.taskBkgColor};
|
|
147
|
-
stroke: ${e.taskBorderColor};
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
.taskTextOutside0,
|
|
151
|
-
.taskTextOutside2
|
|
152
|
-
{
|
|
153
|
-
fill: ${e.taskTextOutsideColor};
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.taskTextOutside1,
|
|
157
|
-
.taskTextOutside3 {
|
|
158
|
-
fill: ${e.taskTextOutsideColor};
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
/* Active task */
|
|
163
|
-
|
|
164
|
-
.active0,
|
|
165
|
-
.active1,
|
|
166
|
-
.active2,
|
|
167
|
-
.active3 {
|
|
168
|
-
fill: ${e.activeTaskBkgColor};
|
|
169
|
-
stroke: ${e.activeTaskBorderColor};
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
.activeText0,
|
|
173
|
-
.activeText1,
|
|
174
|
-
.activeText2,
|
|
175
|
-
.activeText3 {
|
|
176
|
-
fill: ${e.taskTextDarkColor} !important;
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
/* Completed task */
|
|
181
|
-
|
|
182
|
-
.done0,
|
|
183
|
-
.done1,
|
|
184
|
-
.done2,
|
|
185
|
-
.done3 {
|
|
186
|
-
stroke: ${e.doneTaskBorderColor};
|
|
187
|
-
fill: ${e.doneTaskBkgColor};
|
|
188
|
-
stroke-width: 2;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
.doneText0,
|
|
192
|
-
.doneText1,
|
|
193
|
-
.doneText2,
|
|
194
|
-
.doneText3 {
|
|
195
|
-
fill: ${e.taskTextDarkColor} !important;
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
/* Tasks on the critical line */
|
|
200
|
-
|
|
201
|
-
.crit0,
|
|
202
|
-
.crit1,
|
|
203
|
-
.crit2,
|
|
204
|
-
.crit3 {
|
|
205
|
-
stroke: ${e.critBorderColor};
|
|
206
|
-
fill: ${e.critBkgColor};
|
|
207
|
-
stroke-width: 2;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
.activeCrit0,
|
|
211
|
-
.activeCrit1,
|
|
212
|
-
.activeCrit2,
|
|
213
|
-
.activeCrit3 {
|
|
214
|
-
stroke: ${e.critBorderColor};
|
|
215
|
-
fill: ${e.activeTaskBkgColor};
|
|
216
|
-
stroke-width: 2;
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
.doneCrit0,
|
|
220
|
-
.doneCrit1,
|
|
221
|
-
.doneCrit2,
|
|
222
|
-
.doneCrit3 {
|
|
223
|
-
stroke: ${e.critBorderColor};
|
|
224
|
-
fill: ${e.doneTaskBkgColor};
|
|
225
|
-
stroke-width: 2;
|
|
226
|
-
cursor: pointer;
|
|
227
|
-
shape-rendering: crispEdges;
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
.milestone {
|
|
231
|
-
transform: rotate(45deg) scale(0.8,0.8);
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
.milestoneText {
|
|
235
|
-
font-style: italic;
|
|
236
|
-
}
|
|
237
|
-
.doneCritText0,
|
|
238
|
-
.doneCritText1,
|
|
239
|
-
.doneCritText2,
|
|
240
|
-
.doneCritText3 {
|
|
241
|
-
fill: ${e.taskTextDarkColor} !important;
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
.vert {
|
|
245
|
-
stroke: ${e.vertLineColor};
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
.vertText {
|
|
249
|
-
font-size: 15px;
|
|
250
|
-
text-anchor: middle;
|
|
251
|
-
fill: ${e.vertLineColor} !important;
|
|
252
|
-
}
|
|
253
|
-
|
|
254
|
-
.activeCritText0,
|
|
255
|
-
.activeCritText1,
|
|
256
|
-
.activeCritText2,
|
|
257
|
-
.activeCritText3 {
|
|
258
|
-
fill: ${e.taskTextDarkColor} !important;
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
.titleText {
|
|
262
|
-
text-anchor: middle;
|
|
263
|
-
font-size: 18px;
|
|
264
|
-
fill: ${e.titleColor||e.textColor};
|
|
265
|
-
font-family: ${e.fontFamily};
|
|
266
|
-
}
|
|
267
|
-
`,"getStyles"),ai=ri,ii={parser:ya,db:Ja,renderer:ni,styles:ai};exports.diagram=ii;
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("./chunk-4BX2VUAB-3Liht_XN.cjs"),j=require("./chunk-QZHKN3VN-DfH9qQ3T.cjs"),s=require("./plugin-mermaid-FTki7cN8.cjs"),K=require("./mermaid-parser.core-CR8Rcyps.cjs");var x={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},U=s.defaultConfig_default.gitGraph,L=s.__name(()=>s.cleanAndMerge({...U,...s.getConfig().gitGraph}),"getConfig"),i=new j.ImperativeState(()=>{const t=L(),e=t.mainBranchName,n=t.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:n}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function G(){return s.random({length:7})}s.__name(G,"getID");function H(t,e){const n=Object.create(null);return t.reduce((o,r)=>{const a=e(r);return n[a]||(n[a]=!0,o.push(r)),o},[])}s.__name(H,"uniqBy");var Y=s.__name(function(t){i.records.direction=t},"setDirection"),V=s.__name(function(t){s.log.debug("options str",t),t=t?.trim(),t=t||"{}";try{i.records.options=JSON.parse(t)}catch(e){s.log.error("error while parsing gitGraph options",e.message)}},"setOptions"),X=s.__name(function(){return i.records.options},"getOptions"),Q=s.__name(function(t){let e=t.msg,n=t.id;const o=t.type;let r=t.tags;s.log.info("commit",e,n,o,r),s.log.debug("Entering commit:",e,n,o,r);const a=L();n=s.common_default.sanitizeText(n,a),e=s.common_default.sanitizeText(e,a),r=r?.map(c=>s.common_default.sanitizeText(c,a));const l={id:n||i.records.seq+"-"+G(),message:e,seq:i.records.seq++,type:o??x.NORMAL,tags:r??[],parents:i.records.head==null?[]:[i.records.head.id],branch:i.records.currBranch};i.records.head=l,s.log.info("main branch",a.mainBranchName),i.records.commits.has(l.id)&&s.log.warn(`Commit ID ${l.id} already exists`),i.records.commits.set(l.id,l),i.records.branches.set(i.records.currBranch,l.id),s.log.debug("in pushCommit "+l.id)},"commit"),J=s.__name(function(t){let e=t.name;const n=t.order;if(e=s.common_default.sanitizeText(e,L()),i.records.branches.has(e))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${e}")`);i.records.branches.set(e,i.records.head!=null?i.records.head.id:null),i.records.branchConfig.set(e,{name:e,order:n}),D(e),s.log.debug("in createBranch")},"branch"),Z=s.__name(t=>{let e=t.branch,n=t.id;const o=t.type,r=t.tags,a=L();e=s.common_default.sanitizeText(e,a),n&&(n=s.common_default.sanitizeText(n,a));const l=i.records.branches.get(i.records.currBranch),c=i.records.branches.get(e),f=l?i.records.commits.get(l):void 0,h=c?i.records.commits.get(c):void 0;if(f&&h&&f.branch===e)throw new Error(`Cannot merge branch '${e}' into itself.`);if(i.records.currBranch===e){const d=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},d}if(f===void 0||!f){const d=new Error(`Incorrect usage of "merge". Current branch (${i.records.currBranch})has no commits`);throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},d}if(!i.records.branches.has(e)){const d=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},d}if(h===void 0||!h){const d=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},d}if(f===h){const d=new Error('Incorrect usage of "merge". Both branches have same head');throw d.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},d}if(n&&i.records.commits.has(n)){const d=new Error('Incorrect usage of "merge". Commit with id:'+n+" already exists, use different custom id");throw d.hash={text:`merge ${e} ${n} ${o} ${r?.join(" ")}`,token:`merge ${e} ${n} ${o} ${r?.join(" ")}`,expected:[`merge ${e} ${n}_UNIQUE ${o} ${r?.join(" ")}`]},d}const $=c||"",g={id:n||`${i.records.seq}-${G()}`,message:`merged branch ${e} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,$],branch:i.records.currBranch,type:x.MERGE,customType:o,customId:!!n,tags:r??[]};i.records.head=g,i.records.commits.set(g.id,g),i.records.branches.set(i.records.currBranch,g.id),s.log.debug(i.records.branches),s.log.debug("in mergeBranch")},"merge"),ee=s.__name(function(t){let e=t.id,n=t.targetId,o=t.tags,r=t.parent;s.log.debug("Entering cherryPick:",e,n,o);const a=L();if(e=s.common_default.sanitizeText(e,a),n=s.common_default.sanitizeText(n,a),o=o?.map(f=>s.common_default.sanitizeText(f,a)),r=s.common_default.sanitizeText(r,a),!e||!i.records.commits.has(e)){const f=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw f.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},f}const l=i.records.commits.get(e);if(l===void 0||!l)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(r&&!(Array.isArray(l.parents)&&l.parents.includes(r)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const c=l.branch;if(l.type===x.MERGE&&!r)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!n||!i.records.commits.has(n)){if(c===i.records.currBranch){const g=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const f=i.records.branches.get(i.records.currBranch);if(f===void 0||!f){const g=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const h=i.records.commits.get(f);if(h===void 0||!h){const g=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw g.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},g}const $={id:i.records.seq+"-"+G(),message:`cherry-picked ${l?.message} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,l.id],branch:i.records.currBranch,type:x.CHERRY_PICK,tags:o?o.filter(Boolean):[`cherry-pick:${l.id}${l.type===x.MERGE?`|parent:${r}`:""}`]};i.records.head=$,i.records.commits.set($.id,$),i.records.branches.set(i.records.currBranch,$.id),s.log.debug(i.records.branches),s.log.debug("in cherryPick")}},"cherryPick"),D=s.__name(function(t){if(t=s.common_default.sanitizeText(t,L()),i.records.branches.has(t)){i.records.currBranch=t;const e=i.records.branches.get(i.records.currBranch);e===void 0||!e?i.records.head=null:i.records.head=i.records.commits.get(e)??null}else{const e=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw e.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},e}},"checkout");function A(t,e,n){const o=t.indexOf(e);o===-1?t.push(n):t.splice(o,1,n)}s.__name(A,"upsert");function q(t){const e=t.reduce((r,a)=>r.seq>a.seq?r:a,t[0]);let n="";t.forEach(function(r){r===e?n+=" *":n+=" |"});const o=[n,e.id,e.seq];for(const r in i.records.branches)i.records.branches.get(r)===e.id&&o.push(r);if(s.log.debug(o.join(" ")),e.parents&&e.parents.length==2&&e.parents[0]&&e.parents[1]){const r=i.records.commits.get(e.parents[0]);A(t,e,r),e.parents[1]&&t.push(i.records.commits.get(e.parents[1]))}else{if(e.parents.length==0)return;if(e.parents[0]){const r=i.records.commits.get(e.parents[0]);A(t,e,r)}}t=H(t,r=>r.id),q(t)}s.__name(q,"prettyPrintCommitHistory");var re=s.__name(function(){s.log.debug(i.records.commits);const t=N()[0];q([t])},"prettyPrint"),te=s.__name(function(){i.reset(),s.clear()},"clear"),ae=s.__name(function(){return[...i.records.branchConfig.values()].map((e,n)=>e.order!==null&&e.order!==void 0?e:{...e,order:parseFloat(`0.${n}`)}).sort((e,n)=>(e.order??0)-(n.order??0)).map(({name:e})=>({name:e}))},"getBranchesAsObjArray"),ne=s.__name(function(){return i.records.branches},"getBranches"),se=s.__name(function(){return i.records.commits},"getCommits"),N=s.__name(function(){const t=[...i.records.commits.values()];return t.forEach(function(e){s.log.debug(e.id)}),t.sort((e,n)=>e.seq-n.seq),t},"getCommitsArray"),oe=s.__name(function(){return i.records.currBranch},"getCurrentBranch"),ce=s.__name(function(){return i.records.direction},"getDirection"),ie=s.__name(function(){return i.records.head},"getHead"),z={commitType:x,getConfig:L,setDirection:Y,setOptions:V,getOptions:X,commit:Q,branch:J,merge:Z,cherryPick:ee,checkout:D,prettyPrint:re,clear:te,getBranchesAsObjArray:ae,getBranches:ne,getCommits:se,getCommitsArray:N,getCurrentBranch:oe,getDirection:ce,getHead:ie,setAccTitle:s.setAccTitle,getAccTitle:s.getAccTitle,getAccDescription:s.getAccDescription,setAccDescription:s.setAccDescription,setDiagramTitle:s.setDiagramTitle,getDiagramTitle:s.getDiagramTitle},de=s.__name((t,e)=>{W.populateCommonDb(t,e),t.dir&&e.setDirection(t.dir);for(const n of t.statements)le(n,e)},"populate"),le=s.__name((t,e)=>{const o={Commit:s.__name(r=>e.commit(he(r)),"Commit"),Branch:s.__name(r=>e.branch($e(r)),"Branch"),Merge:s.__name(r=>e.merge(fe(r)),"Merge"),Checkout:s.__name(r=>e.checkout(ge(r)),"Checkout"),CherryPicking:s.__name(r=>e.cherryPick(ye(r)),"CherryPicking")}[t.$type];o?o(t):s.log.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),he=s.__name(t=>({id:t.id,msg:t.message??"",type:t.type!==void 0?x[t.type]:x.NORMAL,tags:t.tags??void 0}),"parseCommit"),$e=s.__name(t=>({name:t.name,order:t.order??0}),"parseBranch"),fe=s.__name(t=>({branch:t.branch,id:t.id??"",type:t.type!==void 0?x[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),ge=s.__name(t=>t.branch,"parseCheckout"),ye=s.__name(t=>({id:t.id,targetId:"",tags:t.tags?.length===0?void 0:t.tags,parent:t.parent}),"parseCherryPicking"),ue={parse:s.__name(async t=>{const e=await K.parse("gitGraph",t);s.log.debug(e),de(e,z)},"parse")},me=s.getConfig2(),_=me?.gitGraph,E=10,T=40,w=4,v=2,B=8,p=new Map,b=new Map,I=30,k=new Map,R=[],C=0,u="LR",xe=s.__name(()=>{p.clear(),b.clear(),k.clear(),C=0,R=[],u="LR"},"clear"),F=s.__name(t=>{const e=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof t=="string"?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(o=>{const r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),r.setAttribute("class","row"),r.textContent=o.trim(),e.appendChild(r)}),e},"drawText"),S=s.__name(t=>{let e,n,o;return u==="BT"?(n=s.__name((r,a)=>r<=a,"comparisonFunc"),o=1/0):(n=s.__name((r,a)=>r>=a,"comparisonFunc"),o=0),t.forEach(r=>{const a=u==="TB"||u=="BT"?b.get(r)?.y:b.get(r)?.x;a!==void 0&&n(a,o)&&(e=r,o=a)}),e},"findClosestParent"),pe=s.__name(t=>{let e="",n=1/0;return t.forEach(o=>{const r=b.get(o).y;r<=n&&(e=o,n=r)}),e||void 0},"findClosestParentBT"),be=s.__name((t,e,n)=>{let o=n,r=n;const a=[];t.forEach(l=>{const c=e.get(l);if(!c)throw new Error(`Commit not found for key ${l}`);c.parents.length?(o=we(c),r=Math.max(o,r)):a.push(c),ve(c,o)}),o=r,a.forEach(l=>{Ce(l,o,n)}),t.forEach(l=>{const c=e.get(l);if(c?.parents.length){const f=pe(c.parents);o=b.get(f).y-T,o<=r&&(r=o);const h=p.get(c.branch).pos,$=o-E;b.set(c.id,{x:h,y:$})}})},"setParallelBTPos"),_e=s.__name(t=>{const e=S(t.parents.filter(o=>o!==null));if(!e)throw new Error(`Closest parent not found for commit ${t.id}`);const n=b.get(e)?.y;if(n===void 0)throw new Error(`Closest parent position not found for commit ${t.id}`);return n},"findClosestParentPos"),we=s.__name(t=>_e(t)+T,"calculateCommitPosition"),ve=s.__name((t,e)=>{const n=p.get(t.branch);if(!n)throw new Error(`Branch not found for commit ${t.id}`);const o=n.pos,r=e+E;return b.set(t.id,{x:o,y:r}),{x:o,y:r}},"setCommitPosition"),Ce=s.__name((t,e,n)=>{const o=p.get(t.branch);if(!o)throw new Error(`Branch not found for commit ${t.id}`);const r=e+n,a=o.pos;b.set(t.id,{x:a,y:r})},"setRootPosition"),Ee=s.__name((t,e,n,o,r,a)=>{if(a===x.HIGHLIGHT)t.append("rect").attr("x",n.x-10).attr("y",n.y-10).attr("width",20).attr("height",20).attr("class",`commit ${e.id} commit-highlight${r%B} ${o}-outer`),t.append("rect").attr("x",n.x-6).attr("y",n.y-6).attr("width",12).attr("height",12).attr("class",`commit ${e.id} commit${r%B} ${o}-inner`);else if(a===x.CHERRY_PICK)t.append("circle").attr("cx",n.x).attr("cy",n.y).attr("r",10).attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",n.x-3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",n.x+3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",n.x+3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",n.x-3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${o}`);else{const l=t.append("circle");if(l.attr("cx",n.x),l.attr("cy",n.y),l.attr("r",e.type===x.MERGE?9:10),l.attr("class",`commit ${e.id} commit${r%B}`),a===x.MERGE){const c=t.append("circle");c.attr("cx",n.x),c.attr("cy",n.y),c.attr("r",6),c.attr("class",`commit ${o} ${e.id} commit${r%B}`)}a===x.REVERSE&&t.append("path").attr("d",`M ${n.x-5},${n.y-5}L${n.x+5},${n.y+5}M${n.x-5},${n.y+5}L${n.x+5},${n.y-5}`).attr("class",`commit ${o} ${e.id} commit${r%B}`)}},"drawCommitBullet"),Te=s.__name((t,e,n,o)=>{if(e.type!==x.CHERRY_PICK&&(e.customId&&e.type===x.MERGE||e.type!==x.MERGE)&&_?.showCommitLabel){const r=t.append("g"),a=r.insert("rect").attr("class","commit-label-bkg"),l=r.append("text").attr("x",o).attr("y",n.y+25).attr("class","commit-label").text(e.id),c=l.node()?.getBBox();if(c&&(a.attr("x",n.posWithOffset-c.width/2-v).attr("y",n.y+13.5).attr("width",c.width+2*v).attr("height",c.height+2*v),u==="TB"||u==="BT"?(a.attr("x",n.x-(c.width+4*w+5)).attr("y",n.y-12),l.attr("x",n.x-(c.width+4*w)).attr("y",n.y+c.height-12)):l.attr("x",n.posWithOffset-c.width/2),_.rotateCommitLabel))if(u==="TB"||u==="BT")l.attr("transform","rotate(-45, "+n.x+", "+n.y+")"),a.attr("transform","rotate(-45, "+n.x+", "+n.y+")");else{const f=-7.5-(c.width+10)/25*9.5,h=10+c.width/25*8.5;r.attr("transform","translate("+f+", "+h+") rotate(-45, "+o+", "+n.y+")")}}},"drawCommitLabel"),Be=s.__name((t,e,n,o)=>{if(e.tags.length>0){let r=0,a=0,l=0;const c=[];for(const f of e.tags.reverse()){const h=t.insert("polygon"),$=t.append("circle"),g=t.append("text").attr("y",n.y-16-r).attr("class","tag-label").text(f),d=g.node()?.getBBox();if(!d)throw new Error("Tag bbox not found");a=Math.max(a,d.width),l=Math.max(l,d.height),g.attr("x",n.posWithOffset-d.width/2),c.push({tag:g,hole:$,rect:h,yOffset:r}),r+=20}for(const{tag:f,hole:h,rect:$,yOffset:g}of c){const d=l/2,y=n.y-19.2-g;if($.attr("class","tag-label-bkg").attr("points",`
|
|
2
|
-
${o-a/2-w/2},${y+v}
|
|
3
|
-
${o-a/2-w/2},${y-v}
|
|
4
|
-
${n.posWithOffset-a/2-w},${y-d-v}
|
|
5
|
-
${n.posWithOffset+a/2+w},${y-d-v}
|
|
6
|
-
${n.posWithOffset+a/2+w},${y+d+v}
|
|
7
|
-
${n.posWithOffset-a/2-w},${y+d+v}`),h.attr("cy",y).attr("cx",o-a/2+w/2).attr("r",1.5).attr("class","tag-hole"),u==="TB"||u==="BT"){const m=o+g;$.attr("class","tag-label-bkg").attr("points",`
|
|
8
|
-
${n.x},${m+2}
|
|
9
|
-
${n.x},${m-2}
|
|
10
|
-
${n.x+E},${m-d-2}
|
|
11
|
-
${n.x+E+a+4},${m-d-2}
|
|
12
|
-
${n.x+E+a+4},${m+d+2}
|
|
13
|
-
${n.x+E},${m+d+2}`).attr("transform","translate(12,12) rotate(45, "+n.x+","+o+")"),h.attr("cx",n.x+w/2).attr("cy",m).attr("transform","translate(12,12) rotate(45, "+n.x+","+o+")"),f.attr("x",n.x+5).attr("y",m+3).attr("transform","translate(14,14) rotate(45, "+n.x+","+o+")")}}}},"drawCommitTags"),Le=s.__name(t=>{switch(t.customType??t.type){case x.NORMAL:return"commit-normal";case x.REVERSE:return"commit-reverse";case x.HIGHLIGHT:return"commit-highlight";case x.MERGE:return"commit-merge";case x.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}},"getCommitClassType"),ke=s.__name((t,e,n,o)=>{const r={x:0,y:0};if(t.parents.length>0){const a=S(t.parents);if(a){const l=o.get(a)??r;return e==="TB"?l.y+T:e==="BT"?(o.get(t.id)??r).y-T:l.x+T}}else return e==="TB"?I:e==="BT"?(o.get(t.id)??r).y-T:0;return 0},"calculatePosition"),Me=s.__name((t,e,n)=>{const o=u==="BT"&&n?e:e+E,r=u==="TB"||u==="BT"?o:p.get(t.branch)?.pos,a=u==="TB"||u==="BT"?p.get(t.branch)?.pos:o;if(a===void 0||r===void 0)throw new Error(`Position were undefined for commit ${t.id}`);return{x:a,y:r,posWithOffset:o}},"getCommitPosition"),P=s.__name((t,e,n)=>{if(!_)throw new Error("GitGraph config not found");const o=t.append("g").attr("class","commit-bullets"),r=t.append("g").attr("class","commit-labels");let a=u==="TB"||u==="BT"?I:0;const l=[...e.keys()],c=_?.parallelCommits??!1,f=s.__name(($,g)=>{const d=e.get($)?.seq,y=e.get(g)?.seq;return d!==void 0&&y!==void 0?d-y:0},"sortKeys");let h=l.sort(f);u==="BT"&&(c&&be(h,e,a),h=h.reverse()),h.forEach($=>{const g=e.get($);if(!g)throw new Error(`Commit not found for key ${$}`);c&&(a=ke(g,u,a,b));const d=Me(g,a,c);if(n){const y=Le(g),m=g.customType??g.type,O=p.get(g.branch)?.index??0;Ee(o,g,d,y,O,m),Te(r,g,d,a),Be(r,g,d,a)}u==="TB"||u==="BT"?b.set(g.id,{x:d.x,y:d.posWithOffset}):b.set(g.id,{x:d.posWithOffset,y:d.y}),a=u==="BT"&&c?a+T:a+T+E,a>C&&(C=a)})},"drawCommits"),Ie=s.__name((t,e,n,o,r)=>{const l=(u==="TB"||u==="BT"?n.x<o.x:n.y<o.y)?e.branch:t.branch,c=s.__name(h=>h.branch===l,"isOnBranchToGetCurve"),f=s.__name(h=>h.seq>t.seq&&h.seq<e.seq,"isBetweenCommits");return[...r.values()].some(h=>f(h)&&c(h))},"shouldRerouteArrow"),M=s.__name((t,e,n=0)=>{const o=t+Math.abs(t-e)/2;if(n>5)return o;if(R.every(l=>Math.abs(l-o)>=10))return R.push(o),o;const a=Math.abs(t-e);return M(t,e-a/5,n+1)},"findLane"),Re=s.__name((t,e,n,o)=>{const r=b.get(e.id),a=b.get(n.id);if(r===void 0||a===void 0)throw new Error(`Commit positions not found for commits ${e.id} and ${n.id}`);const l=Ie(e,n,r,a,o);let c="",f="",h=0,$=0,g=p.get(n.branch)?.index;n.type===x.MERGE&&e.id!==n.parents[0]&&(g=p.get(e.branch)?.index);let d;if(l){c="A 10 10, 0, 0, 0,",f="A 10 10, 0, 0, 1,",h=10,$=10;const y=r.y<a.y?M(r.y,a.y):M(a.y,r.y),m=r.x<a.x?M(r.x,a.x):M(a.x,r.x);u==="TB"?r.x<a.x?d=`M ${r.x} ${r.y} L ${m-h} ${r.y} ${f} ${m} ${r.y+$} L ${m} ${a.y-h} ${c} ${m+$} ${a.y} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${m+h} ${r.y} ${c} ${m} ${r.y+$} L ${m} ${a.y-h} ${f} ${m-$} ${a.y} L ${a.x} ${a.y}`):u==="BT"?r.x<a.x?d=`M ${r.x} ${r.y} L ${m-h} ${r.y} ${c} ${m} ${r.y-$} L ${m} ${a.y+h} ${f} ${m+$} ${a.y} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${m+h} ${r.y} ${f} ${m} ${r.y-$} L ${m} ${a.y+h} ${c} ${m-$} ${a.y} L ${a.x} ${a.y}`):r.y<a.y?d=`M ${r.x} ${r.y} L ${r.x} ${y-h} ${c} ${r.x+$} ${y} L ${a.x-h} ${y} ${f} ${a.x} ${y+$} L ${a.x} ${a.y}`:(g=p.get(e.branch)?.index,d=`M ${r.x} ${r.y} L ${r.x} ${y+h} ${f} ${r.x+$} ${y} L ${a.x-h} ${y} ${c} ${a.x} ${y-$} L ${a.x} ${a.y}`)}else c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,u==="TB"?(r.x<a.x&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${c} ${r.x+$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${f} ${a.x} ${r.y+$} L ${a.x} ${a.y}`),r.x>a.x&&(c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${f} ${r.x-$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x+h} ${r.y} ${c} ${a.x} ${r.y+$} L ${a.x} ${a.y}`),r.x===a.x&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`)):u==="BT"?(r.x<a.x&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${f} ${r.x+$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`),r.x>a.x&&(c="A 20 20, 0, 0, 0,",f="A 20 20, 0, 0, 1,",h=20,$=20,n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${c} ${r.x-$} ${a.y} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`),r.x===a.x&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`)):(r.y<a.y&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${f} ${a.x} ${r.y+$} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${r.x} ${a.y-h} ${c} ${r.x+$} ${a.y} L ${a.x} ${a.y}`),r.y>a.y&&(n.type===x.MERGE&&e.id!==n.parents[0]?d=`M ${r.x} ${r.y} L ${a.x-h} ${r.y} ${c} ${a.x} ${r.y-$} L ${a.x} ${a.y}`:d=`M ${r.x} ${r.y} L ${r.x} ${a.y+h} ${f} ${r.x+$} ${a.y} L ${a.x} ${a.y}`),r.y===a.y&&(d=`M ${r.x} ${r.y} L ${a.x} ${a.y}`));if(d===void 0)throw new Error("Line definition not found");t.append("path").attr("d",d).attr("class","arrow arrow"+g%B)},"drawArrow"),Ge=s.__name((t,e)=>{const n=t.append("g").attr("class","commit-arrows");[...e.keys()].forEach(o=>{const r=e.get(o);r.parents&&r.parents.length>0&&r.parents.forEach(a=>{Re(n,e.get(a),r,e)})})},"drawArrows"),Oe=s.__name((t,e)=>{const n=t.append("g");e.forEach((o,r)=>{const a=r%B,l=p.get(o.name)?.pos;if(l===void 0)throw new Error(`Position not found for branch ${o.name}`);const c=n.append("line");c.attr("x1",0),c.attr("y1",l),c.attr("x2",C),c.attr("y2",l),c.attr("class","branch branch"+a),u==="TB"?(c.attr("y1",I),c.attr("x1",l),c.attr("y2",C),c.attr("x2",l)):u==="BT"&&(c.attr("y1",C),c.attr("x1",l),c.attr("y2",I),c.attr("x2",l)),R.push(l);const f=o.name,h=F(f),$=n.insert("rect"),d=n.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+a);d.node().appendChild(h);const y=h.getBBox();$.attr("class","branchLabelBkg label"+a).attr("rx",4).attr("ry",4).attr("x",-y.width-4-(_?.rotateCommitLabel===!0?30:0)).attr("y",-y.height/2+8).attr("width",y.width+18).attr("height",y.height+4),d.attr("transform","translate("+(-y.width-14-(_?.rotateCommitLabel===!0?30:0))+", "+(l-y.height/2-1)+")"),u==="TB"?($.attr("x",l-y.width/2-10).attr("y",0),d.attr("transform","translate("+(l-y.width/2-5)+", 0)")):u==="BT"?($.attr("x",l-y.width/2-10).attr("y",C),d.attr("transform","translate("+(l-y.width/2-5)+", "+C+")")):$.attr("transform","translate(-19, "+(l-y.height/2)+")")})},"drawBranches"),Ae=s.__name(function(t,e,n,o,r){return p.set(t,{pos:e,index:n}),e+=50+(r?40:0)+(u==="TB"||u==="BT"?o.width/2:0),e},"setBranchPosition"),qe=s.__name(function(t,e,n,o){if(xe(),s.log.debug("in gitgraph renderer",t+`
|
|
14
|
-
`,"id:",e,n),!_)throw new Error("GitGraph config not found");const r=_.rotateCommitLabel??!1,a=o.db;k=a.getCommits();const l=a.getBranchesAsObjArray();u=a.getDirection();const c=s.select(`[id="${e}"]`);let f=0;l.forEach((h,$)=>{const g=F(h.name),d=c.append("g"),y=d.insert("g").attr("class","branchLabel"),m=y.insert("g").attr("class","label branch-label");m.node()?.appendChild(g);const O=g.getBBox();f=Ae(h.name,f,$,O,r),m.remove(),y.remove(),d.remove()}),P(c,k,!1),_.showBranches&&Oe(c,l),Ge(c,k),P(c,k,!0),s.utils_default.insertTitle(c,"gitTitleText",_.titleTopMargin??0,a.getDiagramTitle()),s.setupGraphViewbox2(void 0,c,_.diagramPadding,_.useMaxWidth)},"draw"),Pe={draw:qe},He=s.__name(t=>`
|
|
15
|
-
.commit-id,
|
|
16
|
-
.commit-msg,
|
|
17
|
-
.branch-label {
|
|
18
|
-
fill: lightgrey;
|
|
19
|
-
color: lightgrey;
|
|
20
|
-
font-family: 'trebuchet ms', verdana, arial, sans-serif;
|
|
21
|
-
font-family: var(--mermaid-font-family);
|
|
22
|
-
}
|
|
23
|
-
${[0,1,2,3,4,5,6,7].map(e=>`
|
|
24
|
-
.branch-label${e} { fill: ${t["gitBranchLabel"+e]}; }
|
|
25
|
-
.commit${e} { stroke: ${t["git"+e]}; fill: ${t["git"+e]}; }
|
|
26
|
-
.commit-highlight${e} { stroke: ${t["gitInv"+e]}; fill: ${t["gitInv"+e]}; }
|
|
27
|
-
.label${e} { fill: ${t["git"+e]}; }
|
|
28
|
-
.arrow${e} { stroke: ${t["git"+e]}; }
|
|
29
|
-
`).join(`
|
|
30
|
-
`)}
|
|
31
|
-
|
|
32
|
-
.branch {
|
|
33
|
-
stroke-width: 1;
|
|
34
|
-
stroke: ${t.lineColor};
|
|
35
|
-
stroke-dasharray: 2;
|
|
36
|
-
}
|
|
37
|
-
.commit-label { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelColor};}
|
|
38
|
-
.commit-label-bkg { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelBackground}; opacity: 0.5; }
|
|
39
|
-
.tag-label { font-size: ${t.tagLabelFontSize}; fill: ${t.tagLabelColor};}
|
|
40
|
-
.tag-label-bkg { fill: ${t.tagLabelBackground}; stroke: ${t.tagLabelBorder}; }
|
|
41
|
-
.tag-hole { fill: ${t.textColor}; }
|
|
42
|
-
|
|
43
|
-
.commit-merge {
|
|
44
|
-
stroke: ${t.primaryColor};
|
|
45
|
-
fill: ${t.primaryColor};
|
|
46
|
-
}
|
|
47
|
-
.commit-reverse {
|
|
48
|
-
stroke: ${t.primaryColor};
|
|
49
|
-
fill: ${t.primaryColor};
|
|
50
|
-
stroke-width: 3;
|
|
51
|
-
}
|
|
52
|
-
.commit-highlight-outer {
|
|
53
|
-
}
|
|
54
|
-
.commit-highlight-inner {
|
|
55
|
-
stroke: ${t.primaryColor};
|
|
56
|
-
fill: ${t.primaryColor};
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.arrow { stroke-width: 8; stroke-linecap: round; fill: none}
|
|
60
|
-
.gitTitleText {
|
|
61
|
-
text-anchor: middle;
|
|
62
|
-
font-size: 18px;
|
|
63
|
-
fill: ${t.textColor};
|
|
64
|
-
}
|
|
65
|
-
`,"getStyles"),De=He,Ne={parser:ue,db:z,renderer:Pe,styles:De};exports.diagram=Ne;
|
package/dist/graph-CHoeKkVR.cjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const u=require("./plugin-mermaid-FTki7cN8.cjs"),n=require("./_baseUniq-DunUk-cd.cjs");var b=u.baseRest(function(o){return n.baseUniq(n.baseFlatten(o,1,u.isArrayLikeObject,!0))}),E="\0",a="\0",g="";class f{constructor(e={}){this._isDirected=Object.prototype.hasOwnProperty.call(e,"directed")?e.directed:!0,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,"compound")?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=u.constant$1(void 0),this._defaultEdgeLabelFn=u.constant$1(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[a]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return u.isFunction(e)||(e=u.constant$1(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return n.keys(this._nodes)}sources(){var e=this;return n.filter(this.nodes(),function(t){return u.isEmpty(e._in[t])})}sinks(){var e=this;return n.filter(this.nodes(),function(t){return u.isEmpty(e._out[t])})}setNodes(e,t){var s=arguments,i=this;return n.forEach(e,function(r){s.length>1?i.setNode(r,t):i.setNode(r)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=a,this._children[e]={},this._children[a][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=s=>this.removeEdge(this._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],n.forEach(this.children(e),s=>{this.setParent(s)}),delete this._children[e]),n.forEach(n.keys(this._in[e]),t),delete this._in[e],delete this._preds[e],n.forEach(n.keys(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(n.isUndefined(t))t=a;else{t+="";for(var s=t;!n.isUndefined(s);s=this.parent(s))if(s===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==a)return t}}children(e){if(n.isUndefined(e)&&(e=a),this._isCompound){var t=this._children[e];if(t)return n.keys(t)}else{if(e===a)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return n.keys(t)}successors(e){var t=this._sucs[e];if(t)return n.keys(t)}neighbors(e){var t=this.predecessors(e);if(t)return b(t,this.successors(e))}isLeaf(e){var t;return this.isDirected()?t=this.successors(e):t=this.neighbors(e),t.length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var s=this;n.forEach(this._nodes,function(h,d){e(d)&&t.setNode(d,h)}),n.forEach(this._edgeObjs,function(h){t.hasNode(h.v)&&t.hasNode(h.w)&&t.setEdge(h,s.edge(h))});var i={};function r(h){var d=s.parent(h);return d===void 0||t.hasNode(d)?(i[h]=d,d):d in i?i[d]:r(d)}return this._isCompound&&n.forEach(t.nodes(),function(h){t.setParent(h,r(h))}),t}setDefaultEdgeLabel(e){return u.isFunction(e)||(e=u.constant$1(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return n.values(this._edgeObjs)}setPath(e,t){var s=this,i=arguments;return n.reduce(e,function(r,h){return i.length>1?s.setEdge(r,h,t):s.setEdge(r,h),h}),this}setEdge(){var e,t,s,i,r=!1,h=arguments[0];typeof h=="object"&&h!==null&&"v"in h?(e=h.v,t=h.w,s=h.name,arguments.length===2&&(i=arguments[1],r=!0)):(e=h,t=arguments[1],s=arguments[3],arguments.length>2&&(i=arguments[2],r=!0)),e=""+e,t=""+t,n.isUndefined(s)||(s=""+s);var d=_(this._isDirected,e,t,s);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,d))return r&&(this._edgeLabels[d]=i),this;if(!n.isUndefined(s)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[d]=r?i:this._defaultEdgeLabelFn(e,t,s);var l=y(this._isDirected,e,t,s);return e=l.v,t=l.w,Object.freeze(l),this._edgeObjs[d]=l,p(this._preds[t],e),p(this._sucs[e],t),this._in[t][d]=l,this._out[e][d]=l,this._edgeCount++,this}edge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):_(this._isDirected,e,t,s);return this._edgeLabels[i]}hasEdge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):_(this._isDirected,e,t,s);return Object.prototype.hasOwnProperty.call(this._edgeLabels,i)}removeEdge(e,t,s){var i=arguments.length===1?c(this._isDirected,arguments[0]):_(this._isDirected,e,t,s),r=this._edgeObjs[i];return r&&(e=r.v,t=r.w,delete this._edgeLabels[i],delete this._edgeObjs[i],m(this._preds[t],e),m(this._sucs[e],t),delete this._in[t][i],delete this._out[e][i],this._edgeCount--),this}inEdges(e,t){var s=this._in[e];if(s){var i=n.values(s);return t?n.filter(i,function(r){return r.v===t}):i}}outEdges(e,t){var s=this._out[e];if(s){var i=n.values(s);return t?n.filter(i,function(r){return r.w===t}):i}}nodeEdges(e,t){var s=this.inEdges(e,t);if(s)return s.concat(this.outEdges(e,t))}}f.prototype._nodeCount=0;f.prototype._edgeCount=0;function p(o,e){o[e]?o[e]++:o[e]=1}function m(o,e){--o[e]||delete o[e]}function _(o,e,t,s){var i=""+e,r=""+t;if(!o&&i>r){var h=i;i=r,r=h}return i+g+r+g+(n.isUndefined(s)?E:s)}function y(o,e,t,s){var i=""+e,r=""+t;if(!o&&i>r){var h=i;i=r,r=h}var d={v:i,w:r};return s&&(d.name=s),d}function c(o,e){return _(o,e.v,e.w,e.name)}exports.Graph=f;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./plugin-mermaid-FTki7cN8.cjs"),s=require("./mermaid-parser.core-CR8Rcyps.cjs");var i={parse:e.__name(async r=>{const a=await s.parse("info",r);e.log.debug(a)},"parse")},o={version:e.package_default.version+""},g=e.__name(()=>o.version,"getVersion"),d={getVersion:g},v=e.__name((r,a,n)=>{e.log.debug(`rendering info diagram
|
|
2
|
-
`+r);const t=e.selectSvgElement(a);e.configureSvgSize(t,100,400,!0),t.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${n}`)},"draw"),c={draw:v},p={parser:i,db:d,renderer:c};exports.diagram=p;
|