orbitchat 2.5.0 → 2.5.1
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/assets/_baseUniq-BPMphbq5-Ci3F4c-i.js +1 -0
- package/dist/assets/{api-BBbZ-wzb.js → api-CtfRLc4F.js} +1 -1
- package/dist/assets/arc-D9rhTKV0-CroREmq6.js +1 -0
- package/dist/assets/{architectureDiagram-VXUJARFQ-ZhthiBXw-6jLb3PI4.js → architectureDiagram-VXUJARFQ-BiqZtsDe-DyrE6YO2.js} +1 -1
- package/dist/assets/{blockDiagram-VD42YOAC-2RvSKzzb-CekR3NQa.js → blockDiagram-VD42YOAC-zcRIdFTD-Cs5m0yBo.js} +5 -5
- package/dist/assets/{c4Diagram-YG6GDRKO-iYNAbGgt-BwzskMHt.js → c4Diagram-YG6GDRKO-DYXNcDX4-DN_-dJAG.js} +4 -4
- package/dist/assets/channel-CUIutAfm-J8R0v6QY.js +1 -0
- package/dist/assets/{chunk-4BX2VUAB-BI1eieHX-BcH4s9g3.js → chunk-4BX2VUAB-DAh9ktmY-DJUd7iky.js} +1 -1
- package/dist/assets/chunk-55IACEB6-Cza7pcpr-CsIEdvZL.js +1 -0
- package/dist/assets/{chunk-B4BG7PRW-B_gbgJ8Z-CmKgjHYB.js → chunk-B4BG7PRW-BTUSpeKy-C84_H2ja.js} +3 -3
- package/dist/assets/{chunk-DI55MBZ5-2NtB5tR9-g5uXuUGc.js → chunk-DI55MBZ5-DKt4WII7-DidpEj2B.js} +3 -3
- package/dist/assets/{chunk-FMBD7UC4-RlKniDBQ-B__CYUwz.js → chunk-FMBD7UC4-DdcCR8w3-BfMdoImH.js} +1 -1
- package/dist/assets/chunk-QN33PNHL-v6AkzOl1-BYUBLlie.js +1 -0
- package/dist/assets/{chunk-QZHKN3VN-1GW3GHKe-C9vGZ5SL.js → chunk-QZHKN3VN-DVJOrqBZ-CMUptYKe.js} +1 -1
- package/dist/assets/{chunk-TZMSLE5B-BTJEzWgP-DqiAu4KT.js → chunk-TZMSLE5B-G2jJHqli-DMA5IQKp.js} +1 -1
- package/dist/assets/classDiagram-2ON5EDUG-CxmgTanh-sy4W7YBV.js +1 -0
- package/dist/assets/classDiagram-v2-WZHVMYZB-CxmgTanh-sy4W7YBV.js +1 -0
- package/dist/assets/clone-CsNB4mMi-CjijztFi.js +1 -0
- package/dist/assets/{cose-bilkent-S5V4N54A-LTD5cwdk-BcWDZjn0.js → cose-bilkent-S5V4N54A-BRr2Y6dg-BApR6rBr.js} +1 -1
- package/dist/assets/{dagre-6UL2VRFP-oAHH3NGz-C-dq50GC.js → dagre-6UL2VRFP-DX8gNHmJ-COuhp_WH.js} +2 -2
- package/dist/assets/{diagram-PSM6KHXK-CE9xld4H-mRc14ET5.js → diagram-PSM6KHXK-DNX818To-DZwizlXL.js} +1 -1
- package/dist/assets/diagram-QEK2KX5R-BDO6hKtm-TIVfhOXf.js +43 -0
- package/dist/assets/diagram-S2PKOQOG-IEqaDwzi-CKibEs0x.js +24 -0
- package/dist/assets/{erDiagram-Q2GNP2WA-Cjwgn5O1-_ffXliWU.js → erDiagram-Q2GNP2WA-DbLpN8Jp-Be1aw4xN.js} +5 -5
- package/dist/assets/{flowDiagram-NV44I4VS-DhL_LF5y-DRuINGle.js → flowDiagram-NV44I4VS-pJlHae8Y-DbXF_vZM.js} +6 -6
- package/dist/assets/{ganttDiagram-JELNMOA3-B9BkzPjc-BXIfYkGx.js → ganttDiagram-JELNMOA3-J0Tkq5TR-Dea0K9q1.js} +4 -4
- package/dist/assets/{gitGraphDiagram-NY62KEGX-BMn7vaQV-Bfy7yuMv.js → gitGraphDiagram-NY62KEGX-DgYonpsZ-7lxSMqF0.js} +10 -10
- package/dist/assets/{graph-DO7yB5fn-iHvIIoGD.js → graph-BpcfrHXY-BH81qtTI.js} +1 -1
- package/dist/assets/index-CS9omSqb.js +978 -0
- package/dist/assets/{index-BqpsNXVI-BztRLboM.js → index-DvNpGWs7-Dgb0lDIY.js} +1 -1
- package/dist/assets/infoDiagram-WHAUD3N6-C3JLOAnb-D99rN4Tp.js +2 -0
- package/dist/assets/{journeyDiagram-XKPGCS4Q-CKTjKgpD-DCt-FJ9q.js → journeyDiagram-XKPGCS4Q-CfjB2Qdf-wB3u3y_Q.js} +4 -4
- package/dist/assets/{kanban-definition-3W4ZIXB7-CavBl09t-D5mhKSSQ.js → kanban-definition-3W4ZIXB7-CrW8yVmd-CQRjSMnx.js} +7 -7
- package/dist/assets/{layout-kX0D0crf-x5N-fcnG.js → layout-bsfAhWjc-xFXmwmRe.js} +1 -1
- package/dist/assets/min-C2aDz5ZK-B9D8sW79.js +1 -0
- package/dist/assets/{mindmap-definition-VGOIOE7T-atjBunOF-DuLlAK7g.js → mindmap-definition-VGOIOE7T-Dj37RkY_-DyDCU6bd.js} +5 -5
- package/dist/assets/pieDiagram-ADFJNKIX-BiQvDx8I-Ba7lEuym.js +30 -0
- package/dist/assets/{quadrantDiagram-AYHSOK5B-CDM1Rm_m-CEOhVdQI.js → quadrantDiagram-AYHSOK5B-D4b-YFzI-DdkdBS88.js} +4 -4
- package/dist/assets/{requirementDiagram-UZGBJVZJ-oAoTJrMw-Co7f_Whe.js → requirementDiagram-UZGBJVZJ-km07nlVd-p1bGk1YD.js} +4 -4
- package/dist/assets/sankeyDiagram-TZEHDZUN-LfuSRRbf-CViEN22a.js +10 -0
- package/dist/assets/{sequenceDiagram-WL72ISMW-DfYfiNEc-DAem8LrU.js → sequenceDiagram-WL72ISMW-CQ4J-0_7-BdxRbQ7B.js} +11 -11
- package/dist/assets/stateDiagram-FKZM4ZOC-JtogJwt6-Bwfh0qFf.js +1 -0
- package/dist/assets/stateDiagram-v2-4FDKWEC3-DuQ7UaeU-DOrYQe5I.js +1 -0
- package/dist/assets/{timeline-definition-IT6M3QCI-D-4DkSGs-igqgXYJA.js → timeline-definition-IT6M3QCI-Cs3NnF2M-DkWnrDas.js} +5 -5
- package/dist/assets/{treemap-KMMF4GRG-D_CgoaQq-1cg8_rRW.js → treemap-KMMF4GRG-CkW25-tn-CpmtOl1S.js} +31 -31
- package/dist/assets/{xychartDiagram-PRI3JC2R-Cs63yrks-CcEeZ1Qx.js → xychartDiagram-PRI3JC2R-JzAaXa5z-qm9b5yhA.js} +4 -4
- package/dist/index.html +1 -1
- package/package.json +2 -2
- package/dist/assets/_baseUniq-D5Eo-o17-Dkf2eEoL.js +0 -1
- package/dist/assets/arc-C_KK8p3_-DPqj8zOp.js +0 -1
- package/dist/assets/channel-pHWSbwHm-CxOaJbm2.js +0 -1
- package/dist/assets/chunk-55IACEB6-BpoJKKfJ-bOzouDoX.js +0 -1
- package/dist/assets/chunk-QN33PNHL-DFknLKOq-B_TRwG-U.js +0 -1
- package/dist/assets/classDiagram-2ON5EDUG-dl-fP_NJ-DmLd9UEu.js +0 -1
- package/dist/assets/classDiagram-v2-WZHVMYZB-dl-fP_NJ-DmLd9UEu.js +0 -1
- package/dist/assets/clone-CYv9ip75-CjM9sz61.js +0 -1
- package/dist/assets/diagram-QEK2KX5R-BueFGLn5-BlCxBbOv.js +0 -43
- package/dist/assets/diagram-S2PKOQOG-C1iE4SNs-z2q-4hhl.js +0 -24
- package/dist/assets/index-Ga9tZhFZ.js +0 -1234
- package/dist/assets/infoDiagram-WHAUD3N6-Cb76h7mD-s5ySGBI1.js +0 -2
- package/dist/assets/min-rCpHWDFS-Bpi4dGNR.js +0 -1
- package/dist/assets/pieDiagram-ADFJNKIX-vuHwyssH-CjkF3vHE.js +0 -30
- package/dist/assets/sankeyDiagram-TZEHDZUN-BcBwWOvE-NUCVToCj.js +0 -10
- package/dist/assets/stateDiagram-FKZM4ZOC-Bc8gN8qV-tvcraH7m.js +0 -1
- package/dist/assets/stateDiagram-v2-4FDKWEC3-D_sncagZ-BEb1odG9.js +0 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import{D as d,W as Ne,O as ze,l as He,P as Ve,f as Ge,H as Re,w as lt,t as bt,R as Be,T as Xe,U as qe,u as Ue,Y as je,a0 as q,x as st,a1 as re,a2 as se,a3 as Qe,a4 as Ze,a5 as Je,a6 as Ke,a7 as tn,a8 as en,a9 as nn,aa as ae,ab as oe,ac as ce,ad as le,ae as ue,M as rn,s as sn,y as an,af as Et,k as on,ag as ve,ah as cn,ai as be,aj as xe,ak as Te,al as ln,S as St}from"./index-Ga9tZhFZ.js";function un(t){return t}var Tt=1,At=2,Wt=3,xt=4,de=1e-6;function dn(t){return"translate("+t+",0)"}function hn(t){return"translate(0,"+t+")"}function fn(t){return e=>+t(e)}function mn(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function yn(){return!this.__axis}function we(t,e){var n=[],r=null,s=null,l=6,k=6,$=3,I=typeof window<"u"&&window.devicePixelRatio>1?0:.5,S=t===Tt||t===xt?-1:1,w=t===xt||t===At?"x":"y",O=t===Tt||t===Wt?dn:hn;function _(M){var z=r??(e.ticks?e.ticks.apply(e,n):e.domain()),A=s??(e.tickFormat?e.tickFormat.apply(e,n):un),T=Math.max(l,0)+$,C=e.range(),F=+C[0]+I,L=+C[C.length-1]+I,H=(e.bandwidth?mn:fn)(e.copy(),I),V=M.selection?M.selection():M,Y=V.selectAll(".domain").data([null]),g=V.selectAll(".tick").data(z,e).order(),y=g.exit(),h=g.enter().append("g").attr("class","tick"),b=g.select("line"),v=g.select("text");Y=Y.merge(Y.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),g=g.merge(h),b=b.merge(h.append("line").attr("stroke","currentColor").attr(w+"2",S*l)),v=v.merge(h.append("text").attr("fill","currentColor").attr(w,S*T).attr("dy",t===Tt?"0em":t===Wt?"0.71em":"0.32em")),M!==V&&(Y=Y.transition(M),g=g.transition(M),b=b.transition(M),v=v.transition(M),y=y.transition(M).attr("opacity",de).attr("transform",function(p){return isFinite(p=H(p))?O(p+I):this.getAttribute("transform")}),h.attr("opacity",de).attr("transform",function(p){var m=this.parentNode.__axis;return O((m&&isFinite(m=m(p))?m:H(p))+I)})),y.remove(),Y.attr("d",t===xt||t===At?k?"M"+S*k+","+F+"H"+I+"V"+L+"H"+S*k:"M"+I+","+F+"V"+L:k?"M"+F+","+S*k+"V"+I+"H"+L+"V"+S*k:"M"+F+","+I+"H"+L),g.attr("opacity",1).attr("transform",function(p){return O(H(p)+I)}),b.attr(w+"2",S*l),v.attr(w,S*T).text(A),V.filter(yn).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===At?"start":t===xt?"end":"middle"),V.each(function(){this.__axis=H})}return _.scale=function(M){return arguments.length?(e=M,_):e},_.ticks=function(){return n=Array.from(arguments),_},_.tickArguments=function(M){return arguments.length?(n=M==null?[]:Array.from(M),_):n.slice()},_.tickValues=function(M){return arguments.length?(r=M==null?null:Array.from(M),_):r&&r.slice()},_.tickFormat=function(M){return arguments.length?(s=M,_):s},_.tickSize=function(M){return arguments.length?(l=k=+M,_):l},_.tickSizeInner=function(M){return arguments.length?(l=+M,_):l},_.tickSizeOuter=function(M){return arguments.length?(k=+M,_):k},_.tickPadding=function(M){return arguments.length?($=+M,_):$},_.offset=function(M){return arguments.length?(I=+M,_):I},_}function kn(t){return we(Tt,t)}function pn(t){return we(Wt,t)}const gn=Math.PI/180,vn=180/Math.PI,_t=18,$e=.96422,_e=1,Me=.82521,De=4/29,ut=6/29,Se=3*ut*ut,bn=ut*ut*ut;function Ce(t){if(t instanceof tt)return new tt(t.l,t.a,t.b,t.opacity);if(t instanceof nt)return Ee(t);t instanceof ve||(t=cn(t));var e=Ot(t.r),n=Ot(t.g),r=Ot(t.b),s=Yt((.2225045*e+.7168786*n+.0606169*r)/_e),l,k;return e===n&&n===r?l=k=s:(l=Yt((.4360747*e+.3850649*n+.1430804*r)/$e),k=Yt((.0139322*e+.0971045*n+.7141733*r)/Me)),new tt(116*s-16,500*(l-s),200*(s-k),t.opacity)}function xn(t,e,n,r){return arguments.length===1?Ce(t):new tt(t,e,n,r??1)}function tt(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}be(tt,xn,xe(Te,{brighter(t){return new tt(this.l+_t*(t??1),this.a,this.b,this.opacity)},darker(t){return new tt(this.l-_t*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return e=$e*It(e),t=_e*It(t),n=Me*It(n),new ve(Lt(3.1338561*e-1.6168667*t-.4906146*n),Lt(-.9787684*e+1.9161415*t+.033454*n),Lt(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}}));function Yt(t){return t>bn?Math.pow(t,1/3):t/Se+De}function It(t){return t>ut?t*t*t:Se*(t-De)}function Lt(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Ot(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Tn(t){if(t instanceof nt)return new nt(t.h,t.c,t.l,t.opacity);if(t instanceof tt||(t=Ce(t)),t.a===0&&t.b===0)return new nt(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*vn;return new nt(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function Pt(t,e,n,r){return arguments.length===1?Tn(t):new nt(t,e,n,r??1)}function nt(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}function Ee(t){if(isNaN(t.h))return new tt(t.l,0,0,t.opacity);var e=t.h*gn;return new tt(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}be(nt,Pt,xe(Te,{brighter(t){return new nt(this.h,this.c,this.l+_t*(t??1),this.opacity)},darker(t){return new nt(this.h,this.c,this.l-_t*(t??1),this.opacity)},rgb(){return Ee(this).rgb()}}));function wn(t){return function(e,n){var r=t((e=Pt(e)).h,(n=Pt(n)).h),s=Et(e.c,n.c),l=Et(e.l,n.l),k=Et(e.opacity,n.opacity);return function($){return e.h=r($),e.c=s($),e.l=l($),e.opacity=k($),e+""}}}const $n=wn(ln);var Nt={exports:{}},_n=Nt.exports,he;function Mn(){return he||(he=1,function(t,e){(function(n,r){t.exports=r()})(_n,function(){var n="day";return function(r,s,l){var k=function(S){return S.add(4-S.isoWeekday(),n)},$=s.prototype;$.isoWeekYear=function(){return k(this).year()},$.isoWeek=function(S){if(!this.$utils().u(S))return this.add(7*(S-this.isoWeek()),n);var w,O,_,M,z=k(this),A=(w=this.isoWeekYear(),O=this.$u,_=(O?l.utc:l)().year(w).startOf("year"),M=4-_.isoWeekday(),_.isoWeekday()>4&&(M+=7),_.add(M,n));return z.diff(A,"week")+1},$.isoWeekday=function(S){return this.$utils().u(S)?this.day()||7:this.day(this.day()%7?S:S-7)};var I=$.startOf;$.startOf=function(S,w){var O=this.$utils(),_=!!O.u(w)||w;return O.p(S)==="isoweek"?_?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):I.bind(this)(S,w)}}})}(Nt)),Nt.exports}var Dn=Mn();const Sn=St(Dn);var zt={exports:{}},Cn=zt.exports,fe;function En(){return fe||(fe=1,function(t,e){(function(n,r){t.exports=r()})(Cn,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,s=/\d/,l=/\d\d/,k=/\d\d?/,$=/\d*[^-_:/,()\s\d]+/,I={},S=function(T){return(T=+T)+(T>68?1900:2e3)},w=function(T){return function(C){this[T]=+C}},O=[/[+-]\d\d:?(\d\d)?|Z/,function(T){(this.zone||(this.zone={})).offset=function(C){if(!C||C==="Z")return 0;var F=C.match(/([+-]|\d\d)/g),L=60*F[1]+(+F[2]||0);return L===0?0:F[0]==="+"?-L:L}(T)}],_=function(T){var C=I[T];return C&&(C.indexOf?C:C.s.concat(C.f))},M=function(T,C){var F,L=I.meridiem;if(L){for(var H=1;H<=24;H+=1)if(T.indexOf(L(H,0,C))>-1){F=H>12;break}}else F=T===(C?"pm":"PM");return F},z={A:[$,function(T){this.afternoon=M(T,!1)}],a:[$,function(T){this.afternoon=M(T,!0)}],Q:[s,function(T){this.month=3*(T-1)+1}],S:[s,function(T){this.milliseconds=100*+T}],SS:[l,function(T){this.milliseconds=10*+T}],SSS:[/\d{3}/,function(T){this.milliseconds=+T}],s:[k,w("seconds")],ss:[k,w("seconds")],m:[k,w("minutes")],mm:[k,w("minutes")],H:[k,w("hours")],h:[k,w("hours")],HH:[k,w("hours")],hh:[k,w("hours")],D:[k,w("day")],DD:[l,w("day")],Do:[$,function(T){var C=I.ordinal,F=T.match(/\d+/);if(this.day=F[0],C)for(var L=1;L<=31;L+=1)C(L).replace(/\[|\]/g,"")===T&&(this.day=L)}],w:[k,w("week")],ww:[l,w("week")],M:[k,w("month")],MM:[l,w("month")],MMM:[$,function(T){var C=_("months"),F=(_("monthsShort")||C.map(function(L){return L.slice(0,3)})).indexOf(T)+1;if(F<1)throw new Error;this.month=F%12||F}],MMMM:[$,function(T){var C=_("months").indexOf(T)+1;if(C<1)throw new Error;this.month=C%12||C}],Y:[/[+-]?\d+/,w("year")],YY:[l,function(T){this.year=S(T)}],YYYY:[/\d{4}/,w("year")],Z:O,ZZ:O};function A(T){var C,F;C=T,F=I&&I.formats;for(var L=(T=C.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(b,v,p){var m=p&&p.toUpperCase();return v||F[p]||n[p]||F[m].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(c,f,u){return f||u.slice(1)})})).match(r),H=L.length,V=0;V<H;V+=1){var Y=L[V],g=z[Y],y=g&&g[0],h=g&&g[1];L[V]=h?{regex:y,parser:h}:Y.replace(/^\[|\]$/g,"")}return function(b){for(var v={},p=0,m=0;p<H;p+=1){var c=L[p];if(typeof c=="string")m+=c.length;else{var f=c.regex,u=c.parser,x=b.slice(m),i=f.exec(x)[0];u.call(v,i),b=b.replace(i,"")}}return function(a){var o=a.afternoon;if(o!==void 0){var D=a.hours;o?D<12&&(a.hours+=12):D===12&&(a.hours=0),delete a.afternoon}}(v),v}}return function(T,C,F){F.p.customParseFormat=!0,T&&T.parseTwoDigitYear&&(S=T.parseTwoDigitYear);var L=C.prototype,H=L.parse;L.parse=function(V){var Y=V.date,g=V.utc,y=V.args;this.$u=g;var h=y[1];if(typeof h=="string"){var b=y[2]===!0,v=y[3]===!0,p=b||v,m=y[2];v&&(m=y[2]),I=this.$locale(),!b&&m&&(I=F.Ls[m]),this.$d=function(x,i,a,o){try{if(["x","X"].indexOf(i)>-1)return new Date((i==="X"?1e3:1)*x);var D=A(i)(x),W=D.year,E=D.month,P=D.day,N=D.hours,G=D.minutes,Z=D.seconds,ft=D.milliseconds,ot=D.zone,gt=D.week,mt=new Date,ct=P||(W||E?1:mt.getDate()),B=W||mt.getFullYear(),Q=0;W&&!E||(Q=E>0?E-1:mt.getMonth());var X,rt=N||0,J=G||0,it=Z||0,U=ft||0;return ot?new Date(Date.UTC(B,Q,ct,rt,J,it,U+60*ot.offset*1e3)):a?new Date(Date.UTC(B,Q,ct,rt,J,it,U)):(X=new Date(B,Q,ct,rt,J,it,U),gt&&(X=o(X).week(gt).toDate()),X)}catch{return new Date("")}}(Y,h,g,F),this.init(),m&&m!==!0&&(this.$L=this.locale(m).$L),p&&Y!=this.format(h)&&(this.$d=new Date("")),I={}}else if(h instanceof Array)for(var c=h.length,f=1;f<=c;f+=1){y[1]=h[f-1];var u=F.apply(this,y);if(u.isValid()){this.$d=u.$d,this.$L=u.$L,this.init();break}f===c&&(this.$d=new Date(""))}else H.call(this,V)}}})}(zt)),zt.exports}var An=En();const Yn=St(An);var Ht={exports:{}},In=Ht.exports,me;function Ln(){return me||(me=1,function(t,e){(function(n,r){t.exports=r()})(In,function(){return function(n,r){var s=r.prototype,l=s.format;s.format=function(k){var $=this,I=this.$locale();if(!this.isValid())return l.bind(this)(k);var S=this.$utils(),w=(k||"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(O){switch(O){case"Q":return Math.ceil(($.$M+1)/3);case"Do":return I.ordinal($.$D);case"gggg":return $.weekYear();case"GGGG":return $.isoWeekYear();case"wo":return I.ordinal($.week(),"W");case"w":case"ww":return S.s($.week(),O==="w"?1:2,"0");case"W":case"WW":return S.s($.isoWeek(),O==="W"?1:2,"0");case"k":case"kk":return S.s(String($.$H===0?24:$.$H),O==="k"?1:2,"0");case"X":return Math.floor($.$d.getTime()/1e3);case"x":return $.$d.getTime();case"z":return"["+$.offsetName()+"]";case"zzz":return"["+$.offsetName("long")+"]";default:return O}});return l.bind(this)(w)}}})}(Ht)),Ht.exports}var On=Ln();const Fn=St(On);var Vt={exports:{}},Wn=Vt.exports,ye;function Pn(){return ye||(ye=1,function(t,e){(function(n,r){t.exports=r()})(Wn,function(){var n,r,s=1e3,l=6e4,k=36e5,$=864e5,I=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,S=31536e6,w=2628e6,O=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,_={years:S,months:w,days:$,hours:k,minutes:l,seconds:s,milliseconds:1,weeks:6048e5},M=function(Y){return Y instanceof H},z=function(Y,g,y){return new H(Y,y,g.$l)},A=function(Y){return r.p(Y)+"s"},T=function(Y){return Y<0},C=function(Y){return T(Y)?Math.ceil(Y):Math.floor(Y)},F=function(Y){return Math.abs(Y)},L=function(Y,g){return Y?T(Y)?{negative:!0,format:""+F(Y)+g}:{negative:!1,format:""+Y+g}:{negative:!1,format:""}},H=function(){function Y(y,h,b){var v=this;if(this.$d={},this.$l=b,y===void 0&&(this.$ms=0,this.parseFromMilliseconds()),h)return z(y*_[A(h)],this);if(typeof y=="number")return this.$ms=y,this.parseFromMilliseconds(),this;if(typeof y=="object")return Object.keys(y).forEach(function(c){v.$d[A(c)]=y[c]}),this.calMilliseconds(),this;if(typeof y=="string"){var p=y.match(O);if(p){var m=p.slice(2).map(function(c){return c!=null?Number(c):0});return this.$d.years=m[0],this.$d.months=m[1],this.$d.weeks=m[2],this.$d.days=m[3],this.$d.hours=m[4],this.$d.minutes=m[5],this.$d.seconds=m[6],this.calMilliseconds(),this}}return this}var g=Y.prototype;return g.calMilliseconds=function(){var y=this;this.$ms=Object.keys(this.$d).reduce(function(h,b){return h+(y.$d[b]||0)*_[b]},0)},g.parseFromMilliseconds=function(){var y=this.$ms;this.$d.years=C(y/S),y%=S,this.$d.months=C(y/w),y%=w,this.$d.days=C(y/$),y%=$,this.$d.hours=C(y/k),y%=k,this.$d.minutes=C(y/l),y%=l,this.$d.seconds=C(y/s),y%=s,this.$d.milliseconds=y},g.toISOString=function(){var y=L(this.$d.years,"Y"),h=L(this.$d.months,"M"),b=+this.$d.days||0;this.$d.weeks&&(b+=7*this.$d.weeks);var v=L(b,"D"),p=L(this.$d.hours,"H"),m=L(this.$d.minutes,"M"),c=this.$d.seconds||0;this.$d.milliseconds&&(c+=this.$d.milliseconds/1e3,c=Math.round(1e3*c)/1e3);var f=L(c,"S"),u=y.negative||h.negative||v.negative||p.negative||m.negative||f.negative,x=p.format||m.format||f.format?"T":"",i=(u?"-":"")+"P"+y.format+h.format+v.format+x+p.format+m.format+f.format;return i==="P"||i==="-P"?"P0D":i},g.toJSON=function(){return this.toISOString()},g.format=function(y){var h=y||"YYYY-MM-DDTHH:mm:ss",b={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return h.replace(I,function(v,p){return p||String(b[v])})},g.as=function(y){return this.$ms/_[A(y)]},g.get=function(y){var h=this.$ms,b=A(y);return b==="milliseconds"?h%=1e3:h=b==="weeks"?C(h/_[b]):this.$d[b],h||0},g.add=function(y,h,b){var v;return v=h?y*_[A(h)]:M(y)?y.$ms:z(y,this).$ms,z(this.$ms+v*(b?-1:1),this)},g.subtract=function(y,h){return this.add(y,h,!0)},g.locale=function(y){var h=this.clone();return h.$l=y,h},g.clone=function(){return z(this.$ms,this)},g.humanize=function(y){return n().add(this.$ms,"ms").locale(this.$l).fromNow(!y)},g.valueOf=function(){return this.asMilliseconds()},g.milliseconds=function(){return this.get("milliseconds")},g.asMilliseconds=function(){return this.as("milliseconds")},g.seconds=function(){return this.get("seconds")},g.asSeconds=function(){return this.as("seconds")},g.minutes=function(){return this.get("minutes")},g.asMinutes=function(){return this.as("minutes")},g.hours=function(){return this.get("hours")},g.asHours=function(){return this.as("hours")},g.days=function(){return this.get("days")},g.asDays=function(){return this.as("days")},g.weeks=function(){return this.get("weeks")},g.asWeeks=function(){return this.as("weeks")},g.months=function(){return this.get("months")},g.asMonths=function(){return this.as("months")},g.years=function(){return this.get("years")},g.asYears=function(){return this.as("years")},Y}(),V=function(Y,g,y){return Y.add(g.years()*y,"y").add(g.months()*y,"M").add(g.days()*y,"d").add(g.hours()*y,"h").add(g.minutes()*y,"m").add(g.seconds()*y,"s").add(g.milliseconds()*y,"ms")};return function(Y,g,y){n=y,r=y().$utils(),y.duration=function(v,p){var m=y.locale();return z(v,{$l:m},p)},y.isDuration=M;var h=g.prototype.add,b=g.prototype.subtract;g.prototype.add=function(v,p){return M(v)?V(this,v,1):h.bind(this)(v,p)},g.prototype.subtract=function(v,p){return M(v)?V(this,v,-1):b.bind(this)(v,p)}}})}(Vt)),Vt.exports}var Nn=Pn();const zn=St(Nn);var Gt=function(){var t=d(function(m,c,f,u){for(f=f||{},u=m.length;u--;f[m[u]]=c);return f},"o"),e=[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],s=[1,28],l=[1,29],k=[1,30],$=[1,31],I=[1,32],S=[1,33],w=[1,34],O=[1,9],_=[1,10],M=[1,11],z=[1,12],A=[1,13],T=[1,14],C=[1,15],F=[1,16],L=[1,19],H=[1,20],V=[1,21],Y=[1,22],g=[1,23],y=[1,25],h=[1,35],b={trace:d(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:d(function(m,c,f,u,x,i,a){var o=i.length-1;switch(x){case 1:return i[o-1];case 2:this.$=[];break;case 3:i[o-1].push(i[o]),this.$=i[o-1];break;case 4:case 5:this.$=i[o];break;case 6:case 7:this.$=[];break;case 8:u.setWeekday("monday");break;case 9:u.setWeekday("tuesday");break;case 10:u.setWeekday("wednesday");break;case 11:u.setWeekday("thursday");break;case 12:u.setWeekday("friday");break;case 13:u.setWeekday("saturday");break;case 14:u.setWeekday("sunday");break;case 15:u.setWeekend("friday");break;case 16:u.setWeekend("saturday");break;case 17:u.setDateFormat(i[o].substr(11)),this.$=i[o].substr(11);break;case 18:u.enableInclusiveEndDates(),this.$=i[o].substr(18);break;case 19:u.TopAxis(),this.$=i[o].substr(8);break;case 20:u.setAxisFormat(i[o].substr(11)),this.$=i[o].substr(11);break;case 21:u.setTickInterval(i[o].substr(13)),this.$=i[o].substr(13);break;case 22:u.setExcludes(i[o].substr(9)),this.$=i[o].substr(9);break;case 23:u.setIncludes(i[o].substr(9)),this.$=i[o].substr(9);break;case 24:u.setTodayMarker(i[o].substr(12)),this.$=i[o].substr(12);break;case 27:u.setDiagramTitle(i[o].substr(6)),this.$=i[o].substr(6);break;case 28:this.$=i[o].trim(),u.setAccTitle(this.$);break;case 29:case 30:this.$=i[o].trim(),u.setAccDescription(this.$);break;case 31:u.addSection(i[o].substr(8)),this.$=i[o].substr(8);break;case 33:u.addTask(i[o-1],i[o]),this.$="task";break;case 34:this.$=i[o-1],u.setClickEvent(i[o-1],i[o],null);break;case 35:this.$=i[o-2],u.setClickEvent(i[o-2],i[o-1],i[o]);break;case 36:this.$=i[o-2],u.setClickEvent(i[o-2],i[o-1],null),u.setLink(i[o-2],i[o]);break;case 37:this.$=i[o-3],u.setClickEvent(i[o-3],i[o-2],i[o-1]),u.setLink(i[o-3],i[o]);break;case 38:this.$=i[o-2],u.setClickEvent(i[o-2],i[o],null),u.setLink(i[o-2],i[o-1]);break;case 39:this.$=i[o-3],u.setClickEvent(i[o-3],i[o-1],i[o]),u.setLink(i[o-3],i[o-2]);break;case 40:this.$=i[o-1],u.setLink(i[o-1],i[o]);break;case 41:case 47:this.$=i[o-1]+" "+i[o];break;case 42:case 43:case 45:this.$=i[o-2]+" "+i[o-1]+" "+i[o];break;case 44:case 46:this.$=i[o-3]+" "+i[o-2]+" "+i[o-1]+" "+i[o];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:s,15:l,16:k,17:$,18:I,19:18,20:S,21:w,22:O,23:_,24:M,25:z,26:A,27:T,28:C,29:F,30:L,31:H,33:V,35:Y,36:g,37:24,38:y,40:h},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:n,13:r,14:s,15:l,16:k,17:$,18:I,19:18,20:S,21:w,22:O,23:_,24:M,25:z,26:A,27:T,28:C,29:F,30:L,31:H,33:V,35:Y,36:g,37:24,38:y,40:h},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:d(function(m,c){if(c.recoverable)this.trace(m);else{var f=new Error(m);throw f.hash=c,f}},"parseError"),parse:d(function(m){var c=this,f=[0],u=[],x=[null],i=[],a=this.table,o="",D=0,W=0,E=2,P=1,N=i.slice.call(arguments,1),G=Object.create(this.lexer),Z={yy:{}};for(var ft in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ft)&&(Z.yy[ft]=this.yy[ft]);G.setInput(m,Z.yy),Z.yy.lexer=G,Z.yy.parser=this,typeof G.yylloc>"u"&&(G.yylloc={});var ot=G.yylloc;i.push(ot);var gt=G.options&&G.options.ranges;typeof Z.yy.parseError=="function"?this.parseError=Z.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function mt(j){f.length=f.length-2*j,x.length=x.length-j,i.length=i.length-j}d(mt,"popStack");function ct(){var j;return j=u.pop()||G.lex()||P,typeof j!="number"&&(j instanceof Array&&(u=j,j=u.pop()),j=c.symbols_[j]||j),j}d(ct,"lex");for(var B,Q,X,rt,J={},it,U,ie,vt;;){if(Q=f[f.length-1],this.defaultActions[Q]?X=this.defaultActions[Q]:((B===null||typeof B>"u")&&(B=ct()),X=a[Q]&&a[Q][B]),typeof X>"u"||!X.length||!X[0]){var Ct="";vt=[];for(it in a[Q])this.terminals_[it]&&it>E&&vt.push("'"+this.terminals_[it]+"'");G.showPosition?Ct="Parse error on line "+(D+1)+`:
|
|
1
|
+
import{Q as d,p as Ne,e as ze,E as He,v as Ve,h as Ge,B as Be,k as lt,w as bt,W as Re,U as Xe,V as Qe,f as Ue,Z as qe,a0 as Q,s as st,a1 as re,a2 as se,a3 as je,a4 as Ze,a5 as Je,a6 as Ke,a7 as tn,a8 as en,a9 as nn,aa as ae,ab as oe,ac as ce,ad as le,ae as ue,l as rn,S as sn,F as an,af as Et,O as on,ag as ve,ah as cn,ai as be,aj as xe,ak as Te,al as ln,d as St}from"./index-CS9omSqb.js";function un(t){return t}var Tt=1,At=2,Wt=3,xt=4,de=1e-6;function dn(t){return"translate("+t+",0)"}function hn(t){return"translate(0,"+t+")"}function fn(t){return e=>+t(e)}function mn(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function yn(){return!this.__axis}function we(t,e){var n=[],r=null,s=null,l=6,k=6,$=3,I=typeof window<"u"&&window.devicePixelRatio>1?0:.5,S=t===Tt||t===xt?-1:1,w=t===xt||t===At?"x":"y",L=t===Tt||t===Wt?dn:hn;function _(D){var z=r??(e.ticks?e.ticks.apply(e,n):e.domain()),A=s??(e.tickFormat?e.tickFormat.apply(e,n):un),T=Math.max(l,0)+$,C=e.range(),F=+C[0]+I,O=+C[C.length-1]+I,H=(e.bandwidth?mn:fn)(e.copy(),I),V=D.selection?D.selection():D,Y=V.selectAll(".domain").data([null]),g=V.selectAll(".tick").data(z,e).order(),y=g.exit(),h=g.enter().append("g").attr("class","tick"),b=g.select("line"),v=g.select("text");Y=Y.merge(Y.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),g=g.merge(h),b=b.merge(h.append("line").attr("stroke","currentColor").attr(w+"2",S*l)),v=v.merge(h.append("text").attr("fill","currentColor").attr(w,S*T).attr("dy",t===Tt?"0em":t===Wt?"0.71em":"0.32em")),D!==V&&(Y=Y.transition(D),g=g.transition(D),b=b.transition(D),v=v.transition(D),y=y.transition(D).attr("opacity",de).attr("transform",function(p){return isFinite(p=H(p))?L(p+I):this.getAttribute("transform")}),h.attr("opacity",de).attr("transform",function(p){var m=this.parentNode.__axis;return L((m&&isFinite(m=m(p))?m:H(p))+I)})),y.remove(),Y.attr("d",t===xt||t===At?k?"M"+S*k+","+F+"H"+I+"V"+O+"H"+S*k:"M"+I+","+F+"V"+O:k?"M"+F+","+S*k+"V"+I+"H"+O+"V"+S*k:"M"+F+","+I+"H"+O),g.attr("opacity",1).attr("transform",function(p){return L(H(p)+I)}),b.attr(w+"2",S*l),v.attr(w,S*T).text(A),V.filter(yn).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===At?"start":t===xt?"end":"middle"),V.each(function(){this.__axis=H})}return _.scale=function(D){return arguments.length?(e=D,_):e},_.ticks=function(){return n=Array.from(arguments),_},_.tickArguments=function(D){return arguments.length?(n=D==null?[]:Array.from(D),_):n.slice()},_.tickValues=function(D){return arguments.length?(r=D==null?null:Array.from(D),_):r&&r.slice()},_.tickFormat=function(D){return arguments.length?(s=D,_):s},_.tickSize=function(D){return arguments.length?(l=k=+D,_):l},_.tickSizeInner=function(D){return arguments.length?(l=+D,_):l},_.tickSizeOuter=function(D){return arguments.length?(k=+D,_):k},_.tickPadding=function(D){return arguments.length?($=+D,_):$},_.offset=function(D){return arguments.length?(I=+D,_):I},_}function kn(t){return we(Tt,t)}function pn(t){return we(Wt,t)}const gn=Math.PI/180,vn=180/Math.PI,_t=18,$e=.96422,_e=1,De=.82521,Me=4/29,ut=6/29,Se=3*ut*ut,bn=ut*ut*ut;function Ce(t){if(t instanceof tt)return new tt(t.l,t.a,t.b,t.opacity);if(t instanceof nt)return Ee(t);t instanceof ve||(t=cn(t));var e=Lt(t.r),n=Lt(t.g),r=Lt(t.b),s=Yt((.2225045*e+.7168786*n+.0606169*r)/_e),l,k;return e===n&&n===r?l=k=s:(l=Yt((.4360747*e+.3850649*n+.1430804*r)/$e),k=Yt((.0139322*e+.0971045*n+.7141733*r)/De)),new tt(116*s-16,500*(l-s),200*(s-k),t.opacity)}function xn(t,e,n,r){return arguments.length===1?Ce(t):new tt(t,e,n,r??1)}function tt(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}be(tt,xn,xe(Te,{brighter(t){return new tt(this.l+_t*(t??1),this.a,this.b,this.opacity)},darker(t){return new tt(this.l-_t*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return e=$e*It(e),t=_e*It(t),n=De*It(n),new ve(Ot(3.1338561*e-1.6168667*t-.4906146*n),Ot(-.9787684*e+1.9161415*t+.033454*n),Ot(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}}));function Yt(t){return t>bn?Math.pow(t,1/3):t/Se+Me}function It(t){return t>ut?t*t*t:Se*(t-Me)}function Ot(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Lt(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Tn(t){if(t instanceof nt)return new nt(t.h,t.c,t.l,t.opacity);if(t instanceof tt||(t=Ce(t)),t.a===0&&t.b===0)return new nt(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*vn;return new nt(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function Pt(t,e,n,r){return arguments.length===1?Tn(t):new nt(t,e,n,r??1)}function nt(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}function Ee(t){if(isNaN(t.h))return new tt(t.l,0,0,t.opacity);var e=t.h*gn;return new tt(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}be(nt,Pt,xe(Te,{brighter(t){return new nt(this.h,this.c,this.l+_t*(t??1),this.opacity)},darker(t){return new nt(this.h,this.c,this.l-_t*(t??1),this.opacity)},rgb(){return Ee(this).rgb()}}));function wn(t){return function(e,n){var r=t((e=Pt(e)).h,(n=Pt(n)).h),s=Et(e.c,n.c),l=Et(e.l,n.l),k=Et(e.opacity,n.opacity);return function($){return e.h=r($),e.c=s($),e.l=l($),e.opacity=k($),e+""}}}const $n=wn(ln);var Nt={exports:{}},_n=Nt.exports,he;function Dn(){return he||(he=1,function(t,e){(function(n,r){t.exports=r()})(_n,function(){var n="day";return function(r,s,l){var k=function(S){return S.add(4-S.isoWeekday(),n)},$=s.prototype;$.isoWeekYear=function(){return k(this).year()},$.isoWeek=function(S){if(!this.$utils().u(S))return this.add(7*(S-this.isoWeek()),n);var w,L,_,D,z=k(this),A=(w=this.isoWeekYear(),L=this.$u,_=(L?l.utc:l)().year(w).startOf("year"),D=4-_.isoWeekday(),_.isoWeekday()>4&&(D+=7),_.add(D,n));return z.diff(A,"week")+1},$.isoWeekday=function(S){return this.$utils().u(S)?this.day()||7:this.day(this.day()%7?S:S-7)};var I=$.startOf;$.startOf=function(S,w){var L=this.$utils(),_=!!L.u(w)||w;return L.p(S)==="isoweek"?_?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):I.bind(this)(S,w)}}})}(Nt)),Nt.exports}var Mn=Dn();const Sn=St(Mn);var zt={exports:{}},Cn=zt.exports,fe;function En(){return fe||(fe=1,function(t,e){(function(n,r){t.exports=r()})(Cn,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,s=/\d/,l=/\d\d/,k=/\d\d?/,$=/\d*[^-_:/,()\s\d]+/,I={},S=function(T){return(T=+T)+(T>68?1900:2e3)},w=function(T){return function(C){this[T]=+C}},L=[/[+-]\d\d:?(\d\d)?|Z/,function(T){(this.zone||(this.zone={})).offset=function(C){if(!C||C==="Z")return 0;var F=C.match(/([+-]|\d\d)/g),O=60*F[1]+(+F[2]||0);return O===0?0:F[0]==="+"?-O:O}(T)}],_=function(T){var C=I[T];return C&&(C.indexOf?C:C.s.concat(C.f))},D=function(T,C){var F,O=I.meridiem;if(O){for(var H=1;H<=24;H+=1)if(T.indexOf(O(H,0,C))>-1){F=H>12;break}}else F=T===(C?"pm":"PM");return F},z={A:[$,function(T){this.afternoon=D(T,!1)}],a:[$,function(T){this.afternoon=D(T,!0)}],Q:[s,function(T){this.month=3*(T-1)+1}],S:[s,function(T){this.milliseconds=100*+T}],SS:[l,function(T){this.milliseconds=10*+T}],SSS:[/\d{3}/,function(T){this.milliseconds=+T}],s:[k,w("seconds")],ss:[k,w("seconds")],m:[k,w("minutes")],mm:[k,w("minutes")],H:[k,w("hours")],h:[k,w("hours")],HH:[k,w("hours")],hh:[k,w("hours")],D:[k,w("day")],DD:[l,w("day")],Do:[$,function(T){var C=I.ordinal,F=T.match(/\d+/);if(this.day=F[0],C)for(var O=1;O<=31;O+=1)C(O).replace(/\[|\]/g,"")===T&&(this.day=O)}],w:[k,w("week")],ww:[l,w("week")],M:[k,w("month")],MM:[l,w("month")],MMM:[$,function(T){var C=_("months"),F=(_("monthsShort")||C.map(function(O){return O.slice(0,3)})).indexOf(T)+1;if(F<1)throw new Error;this.month=F%12||F}],MMMM:[$,function(T){var C=_("months").indexOf(T)+1;if(C<1)throw new Error;this.month=C%12||C}],Y:[/[+-]?\d+/,w("year")],YY:[l,function(T){this.year=S(T)}],YYYY:[/\d{4}/,w("year")],Z:L,ZZ:L};function A(T){var C,F;C=T,F=I&&I.formats;for(var O=(T=C.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(b,v,p){var m=p&&p.toUpperCase();return v||F[p]||n[p]||F[m].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(c,f,u){return f||u.slice(1)})})).match(r),H=O.length,V=0;V<H;V+=1){var Y=O[V],g=z[Y],y=g&&g[0],h=g&&g[1];O[V]=h?{regex:y,parser:h}:Y.replace(/^\[|\]$/g,"")}return function(b){for(var v={},p=0,m=0;p<H;p+=1){var c=O[p];if(typeof c=="string")m+=c.length;else{var f=c.regex,u=c.parser,x=b.slice(m),i=f.exec(x)[0];u.call(v,i),b=b.replace(i,"")}}return function(a){var o=a.afternoon;if(o!==void 0){var M=a.hours;o?M<12&&(a.hours+=12):M===12&&(a.hours=0),delete a.afternoon}}(v),v}}return function(T,C,F){F.p.customParseFormat=!0,T&&T.parseTwoDigitYear&&(S=T.parseTwoDigitYear);var O=C.prototype,H=O.parse;O.parse=function(V){var Y=V.date,g=V.utc,y=V.args;this.$u=g;var h=y[1];if(typeof h=="string"){var b=y[2]===!0,v=y[3]===!0,p=b||v,m=y[2];v&&(m=y[2]),I=this.$locale(),!b&&m&&(I=F.Ls[m]),this.$d=function(x,i,a,o){try{if(["x","X"].indexOf(i)>-1)return new Date((i==="X"?1e3:1)*x);var M=A(i)(x),W=M.year,E=M.month,P=M.day,N=M.hours,G=M.minutes,Z=M.seconds,ft=M.milliseconds,ot=M.zone,gt=M.week,mt=new Date,ct=P||(W||E?1:mt.getDate()),R=W||mt.getFullYear(),j=0;W&&!E||(j=E>0?E-1:mt.getMonth());var X,rt=N||0,J=G||0,it=Z||0,U=ft||0;return ot?new Date(Date.UTC(R,j,ct,rt,J,it,U+60*ot.offset*1e3)):a?new Date(Date.UTC(R,j,ct,rt,J,it,U)):(X=new Date(R,j,ct,rt,J,it,U),gt&&(X=o(X).week(gt).toDate()),X)}catch{return new Date("")}}(Y,h,g,F),this.init(),m&&m!==!0&&(this.$L=this.locale(m).$L),p&&Y!=this.format(h)&&(this.$d=new Date("")),I={}}else if(h instanceof Array)for(var c=h.length,f=1;f<=c;f+=1){y[1]=h[f-1];var u=F.apply(this,y);if(u.isValid()){this.$d=u.$d,this.$L=u.$L,this.init();break}f===c&&(this.$d=new Date(""))}else H.call(this,V)}}})}(zt)),zt.exports}var An=En();const Yn=St(An);var Ht={exports:{}},In=Ht.exports,me;function On(){return me||(me=1,function(t,e){(function(n,r){t.exports=r()})(In,function(){return function(n,r){var s=r.prototype,l=s.format;s.format=function(k){var $=this,I=this.$locale();if(!this.isValid())return l.bind(this)(k);var S=this.$utils(),w=(k||"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(L){switch(L){case"Q":return Math.ceil(($.$M+1)/3);case"Do":return I.ordinal($.$D);case"gggg":return $.weekYear();case"GGGG":return $.isoWeekYear();case"wo":return I.ordinal($.week(),"W");case"w":case"ww":return S.s($.week(),L==="w"?1:2,"0");case"W":case"WW":return S.s($.isoWeek(),L==="W"?1:2,"0");case"k":case"kk":return S.s(String($.$H===0?24:$.$H),L==="k"?1:2,"0");case"X":return Math.floor($.$d.getTime()/1e3);case"x":return $.$d.getTime();case"z":return"["+$.offsetName()+"]";case"zzz":return"["+$.offsetName("long")+"]";default:return L}});return l.bind(this)(w)}}})}(Ht)),Ht.exports}var Ln=On();const Fn=St(Ln);var Vt={exports:{}},Wn=Vt.exports,ye;function Pn(){return ye||(ye=1,function(t,e){(function(n,r){t.exports=r()})(Wn,function(){var n,r,s=1e3,l=6e4,k=36e5,$=864e5,I=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,S=31536e6,w=2628e6,L=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,_={years:S,months:w,days:$,hours:k,minutes:l,seconds:s,milliseconds:1,weeks:6048e5},D=function(Y){return Y instanceof H},z=function(Y,g,y){return new H(Y,y,g.$l)},A=function(Y){return r.p(Y)+"s"},T=function(Y){return Y<0},C=function(Y){return T(Y)?Math.ceil(Y):Math.floor(Y)},F=function(Y){return Math.abs(Y)},O=function(Y,g){return Y?T(Y)?{negative:!0,format:""+F(Y)+g}:{negative:!1,format:""+Y+g}:{negative:!1,format:""}},H=function(){function Y(y,h,b){var v=this;if(this.$d={},this.$l=b,y===void 0&&(this.$ms=0,this.parseFromMilliseconds()),h)return z(y*_[A(h)],this);if(typeof y=="number")return this.$ms=y,this.parseFromMilliseconds(),this;if(typeof y=="object")return Object.keys(y).forEach(function(c){v.$d[A(c)]=y[c]}),this.calMilliseconds(),this;if(typeof y=="string"){var p=y.match(L);if(p){var m=p.slice(2).map(function(c){return c!=null?Number(c):0});return this.$d.years=m[0],this.$d.months=m[1],this.$d.weeks=m[2],this.$d.days=m[3],this.$d.hours=m[4],this.$d.minutes=m[5],this.$d.seconds=m[6],this.calMilliseconds(),this}}return this}var g=Y.prototype;return g.calMilliseconds=function(){var y=this;this.$ms=Object.keys(this.$d).reduce(function(h,b){return h+(y.$d[b]||0)*_[b]},0)},g.parseFromMilliseconds=function(){var y=this.$ms;this.$d.years=C(y/S),y%=S,this.$d.months=C(y/w),y%=w,this.$d.days=C(y/$),y%=$,this.$d.hours=C(y/k),y%=k,this.$d.minutes=C(y/l),y%=l,this.$d.seconds=C(y/s),y%=s,this.$d.milliseconds=y},g.toISOString=function(){var y=O(this.$d.years,"Y"),h=O(this.$d.months,"M"),b=+this.$d.days||0;this.$d.weeks&&(b+=7*this.$d.weeks);var v=O(b,"D"),p=O(this.$d.hours,"H"),m=O(this.$d.minutes,"M"),c=this.$d.seconds||0;this.$d.milliseconds&&(c+=this.$d.milliseconds/1e3,c=Math.round(1e3*c)/1e3);var f=O(c,"S"),u=y.negative||h.negative||v.negative||p.negative||m.negative||f.negative,x=p.format||m.format||f.format?"T":"",i=(u?"-":"")+"P"+y.format+h.format+v.format+x+p.format+m.format+f.format;return i==="P"||i==="-P"?"P0D":i},g.toJSON=function(){return this.toISOString()},g.format=function(y){var h=y||"YYYY-MM-DDTHH:mm:ss",b={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return h.replace(I,function(v,p){return p||String(b[v])})},g.as=function(y){return this.$ms/_[A(y)]},g.get=function(y){var h=this.$ms,b=A(y);return b==="milliseconds"?h%=1e3:h=b==="weeks"?C(h/_[b]):this.$d[b],h||0},g.add=function(y,h,b){var v;return v=h?y*_[A(h)]:D(y)?y.$ms:z(y,this).$ms,z(this.$ms+v*(b?-1:1),this)},g.subtract=function(y,h){return this.add(y,h,!0)},g.locale=function(y){var h=this.clone();return h.$l=y,h},g.clone=function(){return z(this.$ms,this)},g.humanize=function(y){return n().add(this.$ms,"ms").locale(this.$l).fromNow(!y)},g.valueOf=function(){return this.asMilliseconds()},g.milliseconds=function(){return this.get("milliseconds")},g.asMilliseconds=function(){return this.as("milliseconds")},g.seconds=function(){return this.get("seconds")},g.asSeconds=function(){return this.as("seconds")},g.minutes=function(){return this.get("minutes")},g.asMinutes=function(){return this.as("minutes")},g.hours=function(){return this.get("hours")},g.asHours=function(){return this.as("hours")},g.days=function(){return this.get("days")},g.asDays=function(){return this.as("days")},g.weeks=function(){return this.get("weeks")},g.asWeeks=function(){return this.as("weeks")},g.months=function(){return this.get("months")},g.asMonths=function(){return this.as("months")},g.years=function(){return this.get("years")},g.asYears=function(){return this.as("years")},Y}(),V=function(Y,g,y){return Y.add(g.years()*y,"y").add(g.months()*y,"M").add(g.days()*y,"d").add(g.hours()*y,"h").add(g.minutes()*y,"m").add(g.seconds()*y,"s").add(g.milliseconds()*y,"ms")};return function(Y,g,y){n=y,r=y().$utils(),y.duration=function(v,p){var m=y.locale();return z(v,{$l:m},p)},y.isDuration=D;var h=g.prototype.add,b=g.prototype.subtract;g.prototype.add=function(v,p){return D(v)?V(this,v,1):h.bind(this)(v,p)},g.prototype.subtract=function(v,p){return D(v)?V(this,v,-1):b.bind(this)(v,p)}}})}(Vt)),Vt.exports}var Nn=Pn();const zn=St(Nn);var Gt=function(){var t=d(function(m,c,f,u){for(f=f||{},u=m.length;u--;f[m[u]]=c);return f},"o"),e=[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],s=[1,28],l=[1,29],k=[1,30],$=[1,31],I=[1,32],S=[1,33],w=[1,34],L=[1,9],_=[1,10],D=[1,11],z=[1,12],A=[1,13],T=[1,14],C=[1,15],F=[1,16],O=[1,19],H=[1,20],V=[1,21],Y=[1,22],g=[1,23],y=[1,25],h=[1,35],b={trace:d(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:d(function(m,c,f,u,x,i,a){var o=i.length-1;switch(x){case 1:return i[o-1];case 2:this.$=[];break;case 3:i[o-1].push(i[o]),this.$=i[o-1];break;case 4:case 5:this.$=i[o];break;case 6:case 7:this.$=[];break;case 8:u.setWeekday("monday");break;case 9:u.setWeekday("tuesday");break;case 10:u.setWeekday("wednesday");break;case 11:u.setWeekday("thursday");break;case 12:u.setWeekday("friday");break;case 13:u.setWeekday("saturday");break;case 14:u.setWeekday("sunday");break;case 15:u.setWeekend("friday");break;case 16:u.setWeekend("saturday");break;case 17:u.setDateFormat(i[o].substr(11)),this.$=i[o].substr(11);break;case 18:u.enableInclusiveEndDates(),this.$=i[o].substr(18);break;case 19:u.TopAxis(),this.$=i[o].substr(8);break;case 20:u.setAxisFormat(i[o].substr(11)),this.$=i[o].substr(11);break;case 21:u.setTickInterval(i[o].substr(13)),this.$=i[o].substr(13);break;case 22:u.setExcludes(i[o].substr(9)),this.$=i[o].substr(9);break;case 23:u.setIncludes(i[o].substr(9)),this.$=i[o].substr(9);break;case 24:u.setTodayMarker(i[o].substr(12)),this.$=i[o].substr(12);break;case 27:u.setDiagramTitle(i[o].substr(6)),this.$=i[o].substr(6);break;case 28:this.$=i[o].trim(),u.setAccTitle(this.$);break;case 29:case 30:this.$=i[o].trim(),u.setAccDescription(this.$);break;case 31:u.addSection(i[o].substr(8)),this.$=i[o].substr(8);break;case 33:u.addTask(i[o-1],i[o]),this.$="task";break;case 34:this.$=i[o-1],u.setClickEvent(i[o-1],i[o],null);break;case 35:this.$=i[o-2],u.setClickEvent(i[o-2],i[o-1],i[o]);break;case 36:this.$=i[o-2],u.setClickEvent(i[o-2],i[o-1],null),u.setLink(i[o-2],i[o]);break;case 37:this.$=i[o-3],u.setClickEvent(i[o-3],i[o-2],i[o-1]),u.setLink(i[o-3],i[o]);break;case 38:this.$=i[o-2],u.setClickEvent(i[o-2],i[o],null),u.setLink(i[o-2],i[o-1]);break;case 39:this.$=i[o-3],u.setClickEvent(i[o-3],i[o-1],i[o]),u.setLink(i[o-3],i[o-2]);break;case 40:this.$=i[o-1],u.setLink(i[o-1],i[o]);break;case 41:case 47:this.$=i[o-1]+" "+i[o];break;case 42:case 43:case 45:this.$=i[o-2]+" "+i[o-1]+" "+i[o];break;case 44:case 46:this.$=i[o-3]+" "+i[o-2]+" "+i[o-1]+" "+i[o];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:s,15:l,16:k,17:$,18:I,19:18,20:S,21:w,22:L,23:_,24:D,25:z,26:A,27:T,28:C,29:F,30:O,31:H,33:V,35:Y,36:g,37:24,38:y,40:h},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:n,13:r,14:s,15:l,16:k,17:$,18:I,19:18,20:S,21:w,22:L,23:_,24:D,25:z,26:A,27:T,28:C,29:F,30:O,31:H,33:V,35:Y,36:g,37:24,38:y,40:h},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:d(function(m,c){if(c.recoverable)this.trace(m);else{var f=new Error(m);throw f.hash=c,f}},"parseError"),parse:d(function(m){var c=this,f=[0],u=[],x=[null],i=[],a=this.table,o="",M=0,W=0,E=2,P=1,N=i.slice.call(arguments,1),G=Object.create(this.lexer),Z={yy:{}};for(var ft in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ft)&&(Z.yy[ft]=this.yy[ft]);G.setInput(m,Z.yy),Z.yy.lexer=G,Z.yy.parser=this,typeof G.yylloc>"u"&&(G.yylloc={});var ot=G.yylloc;i.push(ot);var gt=G.options&&G.options.ranges;typeof Z.yy.parseError=="function"?this.parseError=Z.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function mt(q){f.length=f.length-2*q,x.length=x.length-q,i.length=i.length-q}d(mt,"popStack");function ct(){var q;return q=u.pop()||G.lex()||P,typeof q!="number"&&(q instanceof Array&&(u=q,q=u.pop()),q=c.symbols_[q]||q),q}d(ct,"lex");for(var R,j,X,rt,J={},it,U,ie,vt;;){if(j=f[f.length-1],this.defaultActions[j]?X=this.defaultActions[j]:((R===null||typeof R>"u")&&(R=ct()),X=a[j]&&a[j][R]),typeof X>"u"||!X.length||!X[0]){var Ct="";vt=[];for(it in a[j])this.terminals_[it]&&it>E&&vt.push("'"+this.terminals_[it]+"'");G.showPosition?Ct="Parse error on line "+(M+1)+`:
|
|
2
2
|
`+G.showPosition()+`
|
|
3
|
-
Expecting `+vt.join(", ")+", got '"+(this.terminals_[
|
|
3
|
+
Expecting `+vt.join(", ")+", got '"+(this.terminals_[R]||R)+"'":Ct="Parse error on line "+(M+1)+": Unexpected "+(R==P?"end of input":"'"+(this.terminals_[R]||R)+"'"),this.parseError(Ct,{text:G.match,token:this.terminals_[R]||R,line:G.yylineno,loc:ot,expected:vt})}if(X[0]instanceof Array&&X.length>1)throw new Error("Parse Error: multiple actions possible at state: "+j+", token: "+R);switch(X[0]){case 1:f.push(R),x.push(G.yytext),i.push(G.yylloc),f.push(X[1]),R=null,W=G.yyleng,o=G.yytext,M=G.yylineno,ot=G.yylloc;break;case 2:if(U=this.productions_[X[1]][1],J.$=x[x.length-U],J._$={first_line:i[i.length-(U||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(U||1)].first_column,last_column:i[i.length-1].last_column},gt&&(J._$.range=[i[i.length-(U||1)].range[0],i[i.length-1].range[1]]),rt=this.performAction.apply(J,[o,W,M,Z.yy,X[1],x,i].concat(N)),typeof rt<"u")return rt;U&&(f=f.slice(0,-1*U*2),x=x.slice(0,-1*U),i=i.slice(0,-1*U)),f.push(this.productions_[X[1]][0]),x.push(J.$),i.push(J._$),ie=a[f[f.length-2]][f[f.length-1]],f.push(ie);break;case 3:return!0}}return!0},"parse")},v=function(){var m={EOF:1,parseError:d(function(c,f){if(this.yy.parser)this.yy.parser.parseError(c,f);else throw new Error(c)},"parseError"),setInput:d(function(c,f){return this.yy=f||this.yy||{},this._input=c,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:d(function(){var c=this._input[0];this.yytext+=c,this.yyleng++,this.offset++,this.match+=c,this.matched+=c;var f=c.match(/(?:\r\n?|\n).*/g);return f?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),c},"input"),unput:d(function(c){var f=c.length,u=c.split(/(?:\r\n?|\n)/g);this._input=c+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-f),this.offset-=f;var x=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),u.length-1&&(this.yylineno-=u.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:u?(u.length===x.length?this.yylloc.first_column:0)+x[x.length-u.length].length-u[0].length:this.yylloc.first_column-f},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-f]),this.yyleng=this.yytext.length,this},"unput"),more:d(function(){return this._more=!0,this},"more"),reject:d(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:d(function(c){this.unput(this.match.slice(c))},"less"),pastInput:d(function(){var c=this.matched.substr(0,this.matched.length-this.match.length);return(c.length>20?"...":"")+c.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:d(function(){var c=this.match;return c.length<20&&(c+=this._input.substr(0,20-c.length)),(c.substr(0,20)+(c.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:d(function(){var c=this.pastInput(),f=new Array(c.length+1).join("-");return c+this.upcomingInput()+`
|
|
5
5
|
`+f+"^"},"showPosition"),test_match:d(function(c,f){var u,x,i;if(this.options.backtrack_lexer&&(i={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&&(i.yylloc.range=this.yylloc.range.slice(0))),x=c[0].match(/(?:\r\n?|\n).*/g),x&&(this.yylineno+=x.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:x?x[x.length-1].length-x[x.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+c[0].length},this.yytext+=c[0],this.match+=c[0],this.matches=c,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(c[0].length),this.matched+=c[0],u=this.performAction.call(this,this.yy,this,f,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),u)return u;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},"test_match"),next:d(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var c,f,u,x;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if(u=this._input.match(this.rules[i[a]]),u&&(!f||u[0].length>f[0].length)){if(f=u,x=a,this.options.backtrack_lexer){if(c=this.test_match(u,i[a]),c!==!1)return c;if(this._backtrack){f=!1;continue}else return!1}else if(!this.options.flex)break}return f?(c=this.test_match(f,i[x]),c!==!1?c:!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:d(function(){var c=this.next();return c||this.lex()},"lex"),begin:d(function(c){this.conditionStack.push(c)},"begin"),popState:d(function(){var c=this.conditionStack.length-1;return c>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:d(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:d(function(c){return c=this.conditionStack.length-1-Math.abs(c||0),c>=0?this.conditionStack[c]:"INITIAL"},"topState"),pushState:d(function(c){this.begin(c)},"pushState"),stateStackSize:d(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:d(function(c,f,u,x){switch(u){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 m}();b.lexer=v;function p(){this.yy={}}return d(p,"Parser"),p.prototype=b,b.Parser=p,new p}();Gt.parser=Gt;var Hn=Gt;q.extend(Sn);q.extend(Yn);q.extend(Fn);var ke={friday:5,saturday:6},K="",qt="",Ut=void 0,jt="",yt=[],kt=[],Qt=new Map,Zt=[],Mt=[],ht="",Jt="",Ae=["active","done","crit","milestone","vert"],Kt=[],pt=!1,te=!1,ee="sunday",Dt="saturday",Rt=0,Vn=d(function(){Zt=[],Mt=[],ht="",Kt=[],wt=0,Xt=void 0,$t=void 0,R=[],K="",qt="",Jt="",Ut=void 0,jt="",yt=[],kt=[],pt=!1,te=!1,Rt=0,Qt=new Map,an(),ee="sunday",Dt="saturday"},"clear"),Gn=d(function(t){qt=t},"setAxisFormat"),Rn=d(function(){return qt},"getAxisFormat"),Bn=d(function(t){Ut=t},"setTickInterval"),Xn=d(function(){return Ut},"getTickInterval"),qn=d(function(t){jt=t},"setTodayMarker"),Un=d(function(){return jt},"getTodayMarker"),jn=d(function(t){K=t},"setDateFormat"),Qn=d(function(){pt=!0},"enableInclusiveEndDates"),Zn=d(function(){return pt},"endDatesAreInclusive"),Jn=d(function(){te=!0},"enableTopAxis"),Kn=d(function(){return te},"topAxisEnabled"),ti=d(function(t){Jt=t},"setDisplayMode"),ei=d(function(){return Jt},"getDisplayMode"),ni=d(function(){return K},"getDateFormat"),ii=d(function(t){yt=t.toLowerCase().split(/[\s,]+/)},"setIncludes"),ri=d(function(){return yt},"getIncludes"),si=d(function(t){kt=t.toLowerCase().split(/[\s,]+/)},"setExcludes"),ai=d(function(){return kt},"getExcludes"),oi=d(function(){return Qt},"getLinks"),ci=d(function(t){ht=t,Zt.push(t)},"addSection"),li=d(function(){return Zt},"getSections"),ui=d(function(){let t=pe();const e=10;let n=0;for(;!t&&n<e;)t=pe(),n++;return Mt=R,Mt},"getTasks"),Ye=d(function(t,e,n,r){const s=t.format(e.trim()),l=t.format("YYYY-MM-DD");return r.includes(s)||r.includes(l)?!1:n.includes("weekends")&&(t.isoWeekday()===ke[Dt]||t.isoWeekday()===ke[Dt]+1)||n.includes(t.format("dddd").toLowerCase())?!0:n.includes(s)||n.includes(l)},"isInvalidDate"),di=d(function(t){ee=t},"setWeekday"),hi=d(function(){return ee},"getWeekday"),fi=d(function(t){Dt=t},"setWeekend"),Ie=d(function(t,e,n,r){if(!n.length||t.manualEndTime)return;let s;t.startTime instanceof Date?s=q(t.startTime):s=q(t.startTime,e,!0),s=s.add(1,"d");let l;t.endTime instanceof Date?l=q(t.endTime):l=q(t.endTime,e,!0);const[k,$]=mi(s,l,e,n,r);t.endTime=k.toDate(),t.renderEndTime=$},"checkTaskDates"),mi=d(function(t,e,n,r,s){let l=!1,k=null;for(;t<=e;)l||(k=e.toDate()),l=Ye(t,n,r,s),l&&(e=e.add(1,"d")),t=t.add(1,"d");return[e,k]},"fixTaskDates"),Bt=d(function(t,e,n){if(n=n.trim(),d(l=>{const k=l.trim();return k==="x"||k==="X"},"isTimestampFormat")(e)&&/^\d+$/.test(n))return new Date(Number(n));const r=/^after\s+(?<ids>[\d\w- ]+)/.exec(n);if(r!==null){let l=null;for(const $ of r.groups.ids.split(" ")){let I=at($);I!==void 0&&(!l||I.endTime>l.endTime)&&(l=I)}if(l)return l.endTime;const k=new Date;return k.setHours(0,0,0,0),k}let s=q(n,e.trim(),!0);if(s.isValid())return s.toDate();{st.debug("Invalid date:"+n),st.debug("With date format:"+e.trim());const l=new Date(n);if(l===void 0||isNaN(l.getTime())||l.getFullYear()<-1e4||l.getFullYear()>1e4)throw new Error("Invalid date:"+n);return l}},"getStartDate"),Le=d(function(t){const e=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());return e!==null?[Number.parseFloat(e[1]),e[2]]:[NaN,"ms"]},"parseDuration"),Oe=d(function(t,e,n,r=!1){n=n.trim();const s=/^until\s+(?<ids>[\d\w- ]+)/.exec(n);if(s!==null){let S=null;for(const O of s.groups.ids.split(" ")){let _=at(O);_!==void 0&&(!S||_.startTime<S.startTime)&&(S=_)}if(S)return S.startTime;const w=new Date;return w.setHours(0,0,0,0),w}let l=q(n,e.trim(),!0);if(l.isValid())return r&&(l=l.add(1,"d")),l.toDate();let k=q(t);const[$,I]=Le(n);if(!Number.isNaN($)){const S=k.add($,I);S.isValid()&&(k=S)}return k.toDate()},"getEndDate"),wt=0,dt=d(function(t){return t===void 0?(wt=wt+1,"task"+wt):t},"parseId"),yi=d(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;const r=n.split(","),s={};ne(r,s,Ae);for(let k=0;k<r.length;k++)r[k]=r[k].trim();let l="";switch(r.length){case 1:s.id=dt(),s.startTime=t.endTime,l=r[0];break;case 2:s.id=dt(),s.startTime=Bt(void 0,K,r[0]),l=r[1];break;case 3:s.id=dt(r[0]),s.startTime=Bt(void 0,K,r[1]),l=r[2];break}return l&&(s.endTime=Oe(s.startTime,K,l,pt),s.manualEndTime=q(l,"YYYY-MM-DD",!0).isValid(),Ie(s,K,kt,yt)),s},"compileData"),ki=d(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;const r=n.split(","),s={};ne(r,s,Ae);for(let l=0;l<r.length;l++)r[l]=r[l].trim();switch(r.length){case 1:s.id=dt(),s.startTime={type:"prevTaskEnd",id:t},s.endTime={data:r[0]};break;case 2:s.id=dt(),s.startTime={type:"getStartDate",startData:r[0]},s.endTime={data:r[1]};break;case 3:s.id=dt(r[0]),s.startTime={type:"getStartDate",startData:r[1]},s.endTime={data:r[2]};break}return s},"parseData"),Xt,$t,R=[],Fe={},pi=d(function(t,e){const n={section:ht,type:ht,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:e},task:t,classes:[]},r=ki($t,e);n.raw.startTime=r.startTime,n.raw.endTime=r.endTime,n.id=r.id,n.prevTaskId=$t,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,n.vert=r.vert,n.order=Rt,Rt++;const s=R.push(n);$t=n.id,Fe[n.id]=s-1},"addTask"),at=d(function(t){const e=Fe[t];return R[e]},"findTaskById"),gi=d(function(t,e){const n={section:ht,type:ht,description:t,task:t,classes:[]},r=yi(Xt,e);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,Xt=n,Mt.push(n)},"addTaskOrg"),pe=d(function(){const t=d(function(n){const r=R[n];let s="";switch(R[n].raw.startTime.type){case"prevTaskEnd":{const l=at(r.prevTaskId);r.startTime=l.endTime;break}case"getStartDate":s=Bt(void 0,K,R[n].raw.startTime.startData),s&&(R[n].startTime=s);break}return R[n].startTime&&(R[n].endTime=Oe(R[n].startTime,K,R[n].raw.endTime.data,pt),R[n].endTime&&(R[n].processed=!0,R[n].manualEndTime=q(R[n].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),Ie(R[n],K,kt,yt))),R[n].processed},"compileTask");let e=!0;for(const[n,r]of R.entries())t(n),e=e&&r.processed;return e},"compileTasks"),vi=d(function(t,e){let n=e;lt().securityLevel!=="loose"&&(n=sn.sanitizeUrl(e)),t.split(",").forEach(function(r){at(r)!==void 0&&(Pe(r,()=>{window.open(n,"_self")}),Qt.set(r,n))}),We(t,"clickable")},"setLink"),We=d(function(t,e){t.split(",").forEach(function(n){let r=at(n);r!==void 0&&r.classes.push(e)})},"setClass"),bi=d(function(t,e,n){if(lt().securityLevel!=="loose"||e===void 0)return;let r=[];if(typeof n=="string"){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let s=0;s<r.length;s++){let l=r[s].trim();l.startsWith('"')&&l.endsWith('"')&&(l=l.substr(1,l.length-2)),r[s]=l}}r.length===0&&r.push(t),at(t)!==void 0&&Pe(t,()=>{on.runFunc(e,...r)})},"setClickFun"),Pe=d(function(t,e){Kt.push(function(){const n=document.querySelector(`[id="${t}"]`);n!==null&&n.addEventListener("click",function(){e()})},function(){const n=document.querySelector(`[id="${t}-text"]`);n!==null&&n.addEventListener("click",function(){e()})})},"pushFun"),xi=d(function(t,e,n){t.split(",").forEach(function(r){bi(r,e,n)}),We(t,"clickable")},"setClickEvent"),Ti=d(function(t){Kt.forEach(function(e){e(t)})},"bindFunctions"),wi={getConfig:d(()=>lt().gantt,"getConfig"),clear:Vn,setDateFormat:jn,getDateFormat:ni,enableInclusiveEndDates:Qn,endDatesAreInclusive:Zn,enableTopAxis:Jn,topAxisEnabled:Kn,setAxisFormat:Gn,getAxisFormat:Rn,setTickInterval:Bn,getTickInterval:Xn,setTodayMarker:qn,getTodayMarker:Un,setAccTitle:Re,getAccTitle:Ge,setDiagramTitle:Ve,getDiagramTitle:He,setDisplayMode:ti,getDisplayMode:ei,setAccDescription:ze,getAccDescription:Ne,addSection:ci,getSections:li,getTasks:ui,addTask:pi,findTaskById:at,addTaskOrg:gi,setIncludes:ii,getIncludes:ri,setExcludes:si,getExcludes:ai,setClickEvent:xi,setLink:vi,getLinks:oi,bindFunctions:Ti,parseDuration:Le,isInvalidDate:Ye,setWeekday:di,getWeekday:hi,setWeekend:fi};function ne(t,e,n){let r=!0;for(;r;)r=!1,n.forEach(function(s){const l="^\\s*"+s+"\\s*$",k=new RegExp(l);t[0].match(k)&&(e[s]=!0,t.shift(1),r=!0)})}d(ne,"getTaskTags");q.extend(zn);var $i=d(function(){st.debug("Something is calling, setConf, remove the call")},"setConf"),ge={monday:nn,tuesday:en,wednesday:tn,thursday:Ke,friday:Je,saturday:Ze,sunday:Qe},_i=d((t,e)=>{let n=[...t].map(()=>-1/0),r=[...t].sort((l,k)=>l.startTime-k.startTime||l.order-k.order),s=0;for(const l of r)for(let k=0;k<n.length;k++)if(l.startTime>=n[k]){n[k]=l.endTime,l.order=k+e,k>s&&(s=k);break}return s},"getMaxIntersections"),et,Ft=1e4,Mi=d(function(t,e,n,r){const s=lt().gantt,l=lt().securityLevel;let k;l==="sandbox"&&(k=bt("#i"+e));const $=l==="sandbox"?bt(k.nodes()[0].contentDocument.body):bt("body"),I=l==="sandbox"?k.nodes()[0].contentDocument:document,S=I.getElementById(e);et=S.parentElement.offsetWidth,et===void 0&&(et=1200),s.useWidth!==void 0&&(et=s.useWidth);const w=r.db.getTasks();let O=[];for(const h of w)O.push(h.type);O=y(O);const _={};let M=2*s.topPadding;if(r.db.getDisplayMode()==="compact"||s.displayMode==="compact"){const h={};for(const v of w)h[v.section]===void 0?h[v.section]=[v]:h[v.section].push(v);let b=0;for(const v of Object.keys(h)){const p=_i(h[v],b)+1;b+=p,M+=p*(s.barHeight+s.barGap),_[v]=p}}else{M+=w.length*(s.barHeight+s.barGap);for(const h of O)_[h]=w.filter(b=>b.type===h).length}S.setAttribute("viewBox","0 0 "+et+" "+M);const z=$.select(`[id="${e}"]`),A=Be().domain([Xe(w,function(h){return h.startTime}),qe(w,function(h){return h.endTime})]).rangeRound([0,et-s.leftPadding-s.rightPadding]);function T(h,b){const v=h.startTime,p=b.startTime;let m=0;return v>p?m=1:v<p&&(m=-1),m}d(T,"taskCompare"),w.sort(T),C(w,et,M),Ue(z,M,et,s.useMaxWidth),z.append("text").text(r.db.getDiagramTitle()).attr("x",et/2).attr("y",s.titleTopMargin).attr("class","titleText");function C(h,b,v){const p=s.barHeight,m=p+s.barGap,c=s.topPadding,f=s.leftPadding,u=je().domain([0,O.length]).range(["#00B9FA","#F95002"]).interpolate($n);L(m,c,f,b,v,h,r.db.getExcludes(),r.db.getIncludes()),V(f,c,b,v),F(h,m,c,f,p,u,b),Y(m,c),g(f,c,b,v)}d(C,"makeGantt");function F(h,b,v,p,m,c,f){h.sort((a,o)=>a.vert===o.vert?0:a.vert?1:-1);const u=[...new Set(h.map(a=>a.order))].map(a=>h.find(o=>o.order===a));z.append("g").selectAll("rect").data(u).enter().append("rect").attr("x",0).attr("y",function(a,o){return o=a.order,o*b+v-2}).attr("width",function(){return f-s.rightPadding/2}).attr("height",b).attr("class",function(a){for(const[o,D]of O.entries())if(a.type===D)return"section section"+o%s.numberSectionStyles;return"section section0"}).enter();const x=z.append("g").selectAll("rect").data(h).enter(),i=r.db.getLinks();if(x.append("rect").attr("id",function(a){return a.id}).attr("rx",3).attr("ry",3).attr("x",function(a){return a.milestone?A(a.startTime)+p+.5*(A(a.endTime)-A(a.startTime))-.5*m:A(a.startTime)+p}).attr("y",function(a,o){return o=a.order,a.vert?s.gridLineStartPadding:o*b+v}).attr("width",function(a){return a.milestone?m:a.vert?.08*m:A(a.renderEndTime||a.endTime)-A(a.startTime)}).attr("height",function(a){return a.vert?w.length*(s.barHeight+s.barGap)+s.barHeight*2:m}).attr("transform-origin",function(a,o){return o=a.order,(A(a.startTime)+p+.5*(A(a.endTime)-A(a.startTime))).toString()+"px "+(o*b+v+.5*m).toString()+"px"}).attr("class",function(a){const o="task";let D="";a.classes.length>0&&(D=a.classes.join(" "));let W=0;for(const[P,N]of O.entries())a.type===N&&(W=P%s.numberSectionStyles);let E="";return a.active?a.crit?E+=" activeCrit":E=" active":a.done?a.crit?E=" doneCrit":E=" done":a.crit&&(E+=" crit"),E.length===0&&(E=" task"),a.milestone&&(E=" milestone "+E),a.vert&&(E=" vert "+E),E+=W,E+=" "+D,o+E}),x.append("text").attr("id",function(a){return a.id+"-text"}).text(function(a){return a.task}).attr("font-size",s.fontSize).attr("x",function(a){let o=A(a.startTime),D=A(a.renderEndTime||a.endTime);if(a.milestone&&(o+=.5*(A(a.endTime)-A(a.startTime))-.5*m,D=o+m),a.vert)return A(a.startTime)+p;const W=this.getBBox().width;return W>D-o?D+W+1.5*s.leftPadding>f?o+p-5:D+p+5:(D-o)/2+o+p}).attr("y",function(a,o){return a.vert?s.gridLineStartPadding+w.length*(s.barHeight+s.barGap)+60:(o=a.order,o*b+s.barHeight/2+(s.fontSize/2-2)+v)}).attr("text-height",m).attr("class",function(a){const o=A(a.startTime);let D=A(a.endTime);a.milestone&&(D=o+m);const W=this.getBBox().width;let E="";a.classes.length>0&&(E=a.classes.join(" "));let P=0;for(const[G,Z]of O.entries())a.type===Z&&(P=G%s.numberSectionStyles);let N="";return a.active&&(a.crit?N="activeCritText"+P:N="activeText"+P),a.done?a.crit?N=N+" doneCritText"+P:N=N+" doneText"+P:a.crit&&(N=N+" critText"+P),a.milestone&&(N+=" milestoneText"),a.vert&&(N+=" vertText"),W>D-o?D+W+1.5*s.leftPadding>f?E+" taskTextOutsideLeft taskTextOutside"+P+" "+N:E+" taskTextOutsideRight taskTextOutside"+P+" "+N+" width-"+W:E+" taskText taskText"+P+" "+N+" width-"+W}),lt().securityLevel==="sandbox"){let a;a=bt("#i"+e);const o=a.nodes()[0].contentDocument;x.filter(function(D){return i.has(D.id)}).each(function(D){var W=o.querySelector("#"+D.id),E=o.querySelector("#"+D.id+"-text");const P=W.parentNode;var N=o.createElement("a");N.setAttribute("xlink:href",i.get(D.id)),N.setAttribute("target","_top"),P.appendChild(N),N.appendChild(W),N.appendChild(E)})}}d(F,"drawRects");function L(h,b,v,p,m,c,f,u){if(f.length===0&&u.length===0)return;let x,i;for(const{startTime:E,endTime:P}of c)(x===void 0||E<x)&&(x=E),(i===void 0||P>i)&&(i=P);if(!x||!i)return;if(q(i).diff(q(x),"year")>5){st.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 a=r.db.getDateFormat(),o=[];let D=null,W=q(x);for(;W.valueOf()<=i;)r.db.isInvalidDate(W,a,f,u)?D?D.end=W:D={start:W,end:W}:D&&(o.push(D),D=null),W=W.add(1,"d");z.append("g").selectAll("rect").data(o).enter().append("rect").attr("id",E=>"exclude-"+E.start.format("YYYY-MM-DD")).attr("x",E=>A(E.start.startOf("day"))+v).attr("y",s.gridLineStartPadding).attr("width",E=>A(E.end.endOf("day"))-A(E.start.startOf("day"))).attr("height",m-b-s.gridLineStartPadding).attr("transform-origin",function(E,P){return(A(E.start)+v+.5*(A(E.end)-A(E.start))).toString()+"px "+(P*h+.5*m).toString()+"px"}).attr("class","exclude-range")}d(L,"drawExcludeDays");function H(h,b,v,p){if(v<=0||h>b)return 1/0;const m=b-h,c=q.duration({[p??"day"]:v}).asMilliseconds();return c<=0?1/0:Math.ceil(m/c)}d(H,"getEstimatedTickCount");function V(h,b,v,p){const m=r.db.getDateFormat(),c=r.db.getAxisFormat();let f;c?f=c:m==="D"?f="%d":f=s.axisFormat??"%Y-%m-%d";let u=pn(A).tickSize(-p+b+s.gridLineStartPadding).tickFormat(re(f));const x=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||s.tickInterval);if(x!==null){const i=parseInt(x[1],10);if(isNaN(i)||i<=0)st.warn(`Invalid tick interval value: "${x[1]}". Skipping custom tick interval.`);else{const a=x[2],o=r.db.getWeekday()||s.weekday,D=A.domain(),W=D[0],E=D[1],P=H(W,E,i,a);if(P>Ft)st.warn(`The tick interval "${i}${a}" would generate ${P} ticks, which exceeds the maximum allowed (${Ft}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(a){case"millisecond":u.ticks(ue.every(i));break;case"second":u.ticks(le.every(i));break;case"minute":u.ticks(ce.every(i));break;case"hour":u.ticks(oe.every(i));break;case"day":u.ticks(ae.every(i));break;case"week":u.ticks(ge[o].every(i));break;case"month":u.ticks(se.every(i));break}}}if(z.append("g").attr("class","grid").attr("transform","translate("+h+", "+(p-50)+")").call(u).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),r.db.topAxisEnabled()||s.topAxis){let i=kn(A).tickSize(-p+b+s.gridLineStartPadding).tickFormat(re(f));if(x!==null){const a=parseInt(x[1],10);if(isNaN(a)||a<=0)st.warn(`Invalid tick interval value: "${x[1]}". Skipping custom tick interval.`);else{const o=x[2],D=r.db.getWeekday()||s.weekday,W=A.domain(),E=W[0],P=W[1];if(H(E,P,a,o)<=Ft)switch(o){case"millisecond":i.ticks(ue.every(a));break;case"second":i.ticks(le.every(a));break;case"minute":i.ticks(ce.every(a));break;case"hour":i.ticks(oe.every(a));break;case"day":i.ticks(ae.every(a));break;case"week":i.ticks(ge[D].every(a));break;case"month":i.ticks(se.every(a));break}}}z.append("g").attr("class","grid").attr("transform","translate("+h+", "+b+")").call(i).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}d(V,"makeGrid");function Y(h,b){let v=0;const p=Object.keys(_).map(m=>[m,_[m]]);z.append("g").selectAll("text").data(p).enter().append(function(m){const c=m[0].split(rn.lineBreakRegex),f=-(c.length-1)/2,u=I.createElementNS("http://www.w3.org/2000/svg","text");u.setAttribute("dy",f+"em");for(const[x,i]of c.entries()){const a=I.createElementNS("http://www.w3.org/2000/svg","tspan");a.setAttribute("alignment-baseline","central"),a.setAttribute("x","10"),x>0&&a.setAttribute("dy","1em"),a.textContent=i,u.appendChild(a)}return u}).attr("x",10).attr("y",function(m,c){if(c>0)for(let f=0;f<c;f++)return v+=p[c-1][1],m[1]*h/2+v*h+b;else return m[1]*h/2+b}).attr("font-size",s.sectionFontSize).attr("class",function(m){for(const[c,f]of O.entries())if(m[0]===f)return"sectionTitle sectionTitle"+c%s.numberSectionStyles;return"sectionTitle"})}d(Y,"vertLabels");function g(h,b,v,p){const m=r.db.getTodayMarker();if(m==="off")return;const c=z.append("g").attr("class","today"),f=new Date,u=c.append("line");u.attr("x1",A(f)+h).attr("x2",A(f)+h).attr("y1",s.titleTopMargin).attr("y2",p-s.titleTopMargin).attr("class","today"),m!==""&&u.attr("style",m.replace(/,/g,";"))}d(g,"drawToday");function y(h){const b={},v=[];for(let p=0,m=h.length;p<m;++p)Object.prototype.hasOwnProperty.call(b,h[p])||(b[h[p]]=!0,v.push(h[p]));return v}d(y,"checkUnique")},"draw"),Di={setConf:$i,draw:Mi},Si=d(t=>`
|
|
6
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:d(function(){var c=this.next();return c||this.lex()},"lex"),begin:d(function(c){this.conditionStack.push(c)},"begin"),popState:d(function(){var c=this.conditionStack.length-1;return c>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:d(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:d(function(c){return c=this.conditionStack.length-1-Math.abs(c||0),c>=0?this.conditionStack[c]:"INITIAL"},"topState"),pushState:d(function(c){this.begin(c)},"pushState"),stateStackSize:d(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:d(function(c,f,u,x){switch(u){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 m}();b.lexer=v;function p(){this.yy={}}return d(p,"Parser"),p.prototype=b,b.Parser=p,new p}();Gt.parser=Gt;var Hn=Gt;Q.extend(Sn);Q.extend(Yn);Q.extend(Fn);var ke={friday:5,saturday:6},K="",Qt="",Ut=void 0,qt="",yt=[],kt=[],jt=new Map,Zt=[],Dt=[],ht="",Jt="",Ae=["active","done","crit","milestone","vert"],Kt=[],pt=!1,te=!1,ee="sunday",Mt="saturday",Bt=0,Vn=d(function(){Zt=[],Dt=[],ht="",Kt=[],wt=0,Xt=void 0,$t=void 0,B=[],K="",Qt="",Jt="",Ut=void 0,qt="",yt=[],kt=[],pt=!1,te=!1,Bt=0,jt=new Map,an(),ee="sunday",Mt="saturday"},"clear"),Gn=d(function(t){Qt=t},"setAxisFormat"),Bn=d(function(){return Qt},"getAxisFormat"),Rn=d(function(t){Ut=t},"setTickInterval"),Xn=d(function(){return Ut},"getTickInterval"),Qn=d(function(t){qt=t},"setTodayMarker"),Un=d(function(){return qt},"getTodayMarker"),qn=d(function(t){K=t},"setDateFormat"),jn=d(function(){pt=!0},"enableInclusiveEndDates"),Zn=d(function(){return pt},"endDatesAreInclusive"),Jn=d(function(){te=!0},"enableTopAxis"),Kn=d(function(){return te},"topAxisEnabled"),ti=d(function(t){Jt=t},"setDisplayMode"),ei=d(function(){return Jt},"getDisplayMode"),ni=d(function(){return K},"getDateFormat"),ii=d(function(t){yt=t.toLowerCase().split(/[\s,]+/)},"setIncludes"),ri=d(function(){return yt},"getIncludes"),si=d(function(t){kt=t.toLowerCase().split(/[\s,]+/)},"setExcludes"),ai=d(function(){return kt},"getExcludes"),oi=d(function(){return jt},"getLinks"),ci=d(function(t){ht=t,Zt.push(t)},"addSection"),li=d(function(){return Zt},"getSections"),ui=d(function(){let t=pe();const e=10;let n=0;for(;!t&&n<e;)t=pe(),n++;return Dt=B,Dt},"getTasks"),Ye=d(function(t,e,n,r){const s=t.format(e.trim()),l=t.format("YYYY-MM-DD");return r.includes(s)||r.includes(l)?!1:n.includes("weekends")&&(t.isoWeekday()===ke[Mt]||t.isoWeekday()===ke[Mt]+1)||n.includes(t.format("dddd").toLowerCase())?!0:n.includes(s)||n.includes(l)},"isInvalidDate"),di=d(function(t){ee=t},"setWeekday"),hi=d(function(){return ee},"getWeekday"),fi=d(function(t){Mt=t},"setWeekend"),Ie=d(function(t,e,n,r){if(!n.length||t.manualEndTime)return;let s;t.startTime instanceof Date?s=Q(t.startTime):s=Q(t.startTime,e,!0),s=s.add(1,"d");let l;t.endTime instanceof Date?l=Q(t.endTime):l=Q(t.endTime,e,!0);const[k,$]=mi(s,l,e,n,r);t.endTime=k.toDate(),t.renderEndTime=$},"checkTaskDates"),mi=d(function(t,e,n,r,s){let l=!1,k=null;for(;t<=e;)l||(k=e.toDate()),l=Ye(t,n,r,s),l&&(e=e.add(1,"d")),t=t.add(1,"d");return[e,k]},"fixTaskDates"),Rt=d(function(t,e,n){if(n=n.trim(),d(l=>{const k=l.trim();return k==="x"||k==="X"},"isTimestampFormat")(e)&&/^\d+$/.test(n))return new Date(Number(n));const r=/^after\s+(?<ids>[\d\w- ]+)/.exec(n);if(r!==null){let l=null;for(const $ of r.groups.ids.split(" ")){let I=at($);I!==void 0&&(!l||I.endTime>l.endTime)&&(l=I)}if(l)return l.endTime;const k=new Date;return k.setHours(0,0,0,0),k}let s=Q(n,e.trim(),!0);if(s.isValid())return s.toDate();{st.debug("Invalid date:"+n),st.debug("With date format:"+e.trim());const l=new Date(n);if(l===void 0||isNaN(l.getTime())||l.getFullYear()<-1e4||l.getFullYear()>1e4)throw new Error("Invalid date:"+n);return l}},"getStartDate"),Oe=d(function(t){const e=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());return e!==null?[Number.parseFloat(e[1]),e[2]]:[NaN,"ms"]},"parseDuration"),Le=d(function(t,e,n,r=!1){n=n.trim();const s=/^until\s+(?<ids>[\d\w- ]+)/.exec(n);if(s!==null){let S=null;for(const L of s.groups.ids.split(" ")){let _=at(L);_!==void 0&&(!S||_.startTime<S.startTime)&&(S=_)}if(S)return S.startTime;const w=new Date;return w.setHours(0,0,0,0),w}let l=Q(n,e.trim(),!0);if(l.isValid())return r&&(l=l.add(1,"d")),l.toDate();let k=Q(t);const[$,I]=Oe(n);if(!Number.isNaN($)){const S=k.add($,I);S.isValid()&&(k=S)}return k.toDate()},"getEndDate"),wt=0,dt=d(function(t){return t===void 0?(wt=wt+1,"task"+wt):t},"parseId"),yi=d(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;const r=n.split(","),s={};ne(r,s,Ae);for(let k=0;k<r.length;k++)r[k]=r[k].trim();let l="";switch(r.length){case 1:s.id=dt(),s.startTime=t.endTime,l=r[0];break;case 2:s.id=dt(),s.startTime=Rt(void 0,K,r[0]),l=r[1];break;case 3:s.id=dt(r[0]),s.startTime=Rt(void 0,K,r[1]),l=r[2];break}return l&&(s.endTime=Le(s.startTime,K,l,pt),s.manualEndTime=Q(l,"YYYY-MM-DD",!0).isValid(),Ie(s,K,kt,yt)),s},"compileData"),ki=d(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;const r=n.split(","),s={};ne(r,s,Ae);for(let l=0;l<r.length;l++)r[l]=r[l].trim();switch(r.length){case 1:s.id=dt(),s.startTime={type:"prevTaskEnd",id:t},s.endTime={data:r[0]};break;case 2:s.id=dt(),s.startTime={type:"getStartDate",startData:r[0]},s.endTime={data:r[1]};break;case 3:s.id=dt(r[0]),s.startTime={type:"getStartDate",startData:r[1]},s.endTime={data:r[2]};break}return s},"parseData"),Xt,$t,B=[],Fe={},pi=d(function(t,e){const n={section:ht,type:ht,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:e},task:t,classes:[]},r=ki($t,e);n.raw.startTime=r.startTime,n.raw.endTime=r.endTime,n.id=r.id,n.prevTaskId=$t,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,n.vert=r.vert,n.order=Bt,Bt++;const s=B.push(n);$t=n.id,Fe[n.id]=s-1},"addTask"),at=d(function(t){const e=Fe[t];return B[e]},"findTaskById"),gi=d(function(t,e){const n={section:ht,type:ht,description:t,task:t,classes:[]},r=yi(Xt,e);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,Xt=n,Dt.push(n)},"addTaskOrg"),pe=d(function(){const t=d(function(n){const r=B[n];let s="";switch(B[n].raw.startTime.type){case"prevTaskEnd":{const l=at(r.prevTaskId);r.startTime=l.endTime;break}case"getStartDate":s=Rt(void 0,K,B[n].raw.startTime.startData),s&&(B[n].startTime=s);break}return B[n].startTime&&(B[n].endTime=Le(B[n].startTime,K,B[n].raw.endTime.data,pt),B[n].endTime&&(B[n].processed=!0,B[n].manualEndTime=Q(B[n].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),Ie(B[n],K,kt,yt))),B[n].processed},"compileTask");let e=!0;for(const[n,r]of B.entries())t(n),e=e&&r.processed;return e},"compileTasks"),vi=d(function(t,e){let n=e;lt().securityLevel!=="loose"&&(n=sn.sanitizeUrl(e)),t.split(",").forEach(function(r){at(r)!==void 0&&(Pe(r,()=>{window.open(n,"_self")}),jt.set(r,n))}),We(t,"clickable")},"setLink"),We=d(function(t,e){t.split(",").forEach(function(n){let r=at(n);r!==void 0&&r.classes.push(e)})},"setClass"),bi=d(function(t,e,n){if(lt().securityLevel!=="loose"||e===void 0)return;let r=[];if(typeof n=="string"){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let s=0;s<r.length;s++){let l=r[s].trim();l.startsWith('"')&&l.endsWith('"')&&(l=l.substr(1,l.length-2)),r[s]=l}}r.length===0&&r.push(t),at(t)!==void 0&&Pe(t,()=>{on.runFunc(e,...r)})},"setClickFun"),Pe=d(function(t,e){Kt.push(function(){const n=document.querySelector(`[id="${t}"]`);n!==null&&n.addEventListener("click",function(){e()})},function(){const n=document.querySelector(`[id="${t}-text"]`);n!==null&&n.addEventListener("click",function(){e()})})},"pushFun"),xi=d(function(t,e,n){t.split(",").forEach(function(r){bi(r,e,n)}),We(t,"clickable")},"setClickEvent"),Ti=d(function(t){Kt.forEach(function(e){e(t)})},"bindFunctions"),wi={getConfig:d(()=>lt().gantt,"getConfig"),clear:Vn,setDateFormat:qn,getDateFormat:ni,enableInclusiveEndDates:jn,endDatesAreInclusive:Zn,enableTopAxis:Jn,topAxisEnabled:Kn,setAxisFormat:Gn,getAxisFormat:Bn,setTickInterval:Rn,getTickInterval:Xn,setTodayMarker:Qn,getTodayMarker:Un,setAccTitle:Be,getAccTitle:Ge,setDiagramTitle:Ve,getDiagramTitle:He,setDisplayMode:ti,getDisplayMode:ei,setAccDescription:ze,getAccDescription:Ne,addSection:ci,getSections:li,getTasks:ui,addTask:pi,findTaskById:at,addTaskOrg:gi,setIncludes:ii,getIncludes:ri,setExcludes:si,getExcludes:ai,setClickEvent:xi,setLink:vi,getLinks:oi,bindFunctions:Ti,parseDuration:Oe,isInvalidDate:Ye,setWeekday:di,getWeekday:hi,setWeekend:fi};function ne(t,e,n){let r=!0;for(;r;)r=!1,n.forEach(function(s){const l="^\\s*"+s+"\\s*$",k=new RegExp(l);t[0].match(k)&&(e[s]=!0,t.shift(1),r=!0)})}d(ne,"getTaskTags");Q.extend(zn);var $i=d(function(){st.debug("Something is calling, setConf, remove the call")},"setConf"),ge={monday:nn,tuesday:en,wednesday:tn,thursday:Ke,friday:Je,saturday:Ze,sunday:je},_i=d((t,e)=>{let n=[...t].map(()=>-1/0),r=[...t].sort((l,k)=>l.startTime-k.startTime||l.order-k.order),s=0;for(const l of r)for(let k=0;k<n.length;k++)if(l.startTime>=n[k]){n[k]=l.endTime,l.order=k+e,k>s&&(s=k);break}return s},"getMaxIntersections"),et,Ft=1e4,Di=d(function(t,e,n,r){const s=lt().gantt,l=lt().securityLevel;let k;l==="sandbox"&&(k=bt("#i"+e));const $=l==="sandbox"?bt(k.nodes()[0].contentDocument.body):bt("body"),I=l==="sandbox"?k.nodes()[0].contentDocument:document,S=I.getElementById(e);et=S.parentElement.offsetWidth,et===void 0&&(et=1200),s.useWidth!==void 0&&(et=s.useWidth);const w=r.db.getTasks();let L=[];for(const h of w)L.push(h.type);L=y(L);const _={};let D=2*s.topPadding;if(r.db.getDisplayMode()==="compact"||s.displayMode==="compact"){const h={};for(const v of w)h[v.section]===void 0?h[v.section]=[v]:h[v.section].push(v);let b=0;for(const v of Object.keys(h)){const p=_i(h[v],b)+1;b+=p,D+=p*(s.barHeight+s.barGap),_[v]=p}}else{D+=w.length*(s.barHeight+s.barGap);for(const h of L)_[h]=w.filter(b=>b.type===h).length}S.setAttribute("viewBox","0 0 "+et+" "+D);const z=$.select(`[id="${e}"]`),A=Re().domain([Xe(w,function(h){return h.startTime}),Qe(w,function(h){return h.endTime})]).rangeRound([0,et-s.leftPadding-s.rightPadding]);function T(h,b){const v=h.startTime,p=b.startTime;let m=0;return v>p?m=1:v<p&&(m=-1),m}d(T,"taskCompare"),w.sort(T),C(w,et,D),Ue(z,D,et,s.useMaxWidth),z.append("text").text(r.db.getDiagramTitle()).attr("x",et/2).attr("y",s.titleTopMargin).attr("class","titleText");function C(h,b,v){const p=s.barHeight,m=p+s.barGap,c=s.topPadding,f=s.leftPadding,u=qe().domain([0,L.length]).range(["#00B9FA","#F95002"]).interpolate($n);O(m,c,f,b,v,h,r.db.getExcludes(),r.db.getIncludes()),V(f,c,b,v),F(h,m,c,f,p,u,b),Y(m,c),g(f,c,b,v)}d(C,"makeGantt");function F(h,b,v,p,m,c,f){h.sort((a,o)=>a.vert===o.vert?0:a.vert?1:-1);const u=[...new Set(h.map(a=>a.order))].map(a=>h.find(o=>o.order===a));z.append("g").selectAll("rect").data(u).enter().append("rect").attr("x",0).attr("y",function(a,o){return o=a.order,o*b+v-2}).attr("width",function(){return f-s.rightPadding/2}).attr("height",b).attr("class",function(a){for(const[o,M]of L.entries())if(a.type===M)return"section section"+o%s.numberSectionStyles;return"section section0"}).enter();const x=z.append("g").selectAll("rect").data(h).enter(),i=r.db.getLinks();if(x.append("rect").attr("id",function(a){return a.id}).attr("rx",3).attr("ry",3).attr("x",function(a){return a.milestone?A(a.startTime)+p+.5*(A(a.endTime)-A(a.startTime))-.5*m:A(a.startTime)+p}).attr("y",function(a,o){return o=a.order,a.vert?s.gridLineStartPadding:o*b+v}).attr("width",function(a){return a.milestone?m:a.vert?.08*m:A(a.renderEndTime||a.endTime)-A(a.startTime)}).attr("height",function(a){return a.vert?w.length*(s.barHeight+s.barGap)+s.barHeight*2:m}).attr("transform-origin",function(a,o){return o=a.order,(A(a.startTime)+p+.5*(A(a.endTime)-A(a.startTime))).toString()+"px "+(o*b+v+.5*m).toString()+"px"}).attr("class",function(a){const o="task";let M="";a.classes.length>0&&(M=a.classes.join(" "));let W=0;for(const[P,N]of L.entries())a.type===N&&(W=P%s.numberSectionStyles);let E="";return a.active?a.crit?E+=" activeCrit":E=" active":a.done?a.crit?E=" doneCrit":E=" done":a.crit&&(E+=" crit"),E.length===0&&(E=" task"),a.milestone&&(E=" milestone "+E),a.vert&&(E=" vert "+E),E+=W,E+=" "+M,o+E}),x.append("text").attr("id",function(a){return a.id+"-text"}).text(function(a){return a.task}).attr("font-size",s.fontSize).attr("x",function(a){let o=A(a.startTime),M=A(a.renderEndTime||a.endTime);if(a.milestone&&(o+=.5*(A(a.endTime)-A(a.startTime))-.5*m,M=o+m),a.vert)return A(a.startTime)+p;const W=this.getBBox().width;return W>M-o?M+W+1.5*s.leftPadding>f?o+p-5:M+p+5:(M-o)/2+o+p}).attr("y",function(a,o){return a.vert?s.gridLineStartPadding+w.length*(s.barHeight+s.barGap)+60:(o=a.order,o*b+s.barHeight/2+(s.fontSize/2-2)+v)}).attr("text-height",m).attr("class",function(a){const o=A(a.startTime);let M=A(a.endTime);a.milestone&&(M=o+m);const W=this.getBBox().width;let E="";a.classes.length>0&&(E=a.classes.join(" "));let P=0;for(const[G,Z]of L.entries())a.type===Z&&(P=G%s.numberSectionStyles);let N="";return a.active&&(a.crit?N="activeCritText"+P:N="activeText"+P),a.done?a.crit?N=N+" doneCritText"+P:N=N+" doneText"+P:a.crit&&(N=N+" critText"+P),a.milestone&&(N+=" milestoneText"),a.vert&&(N+=" vertText"),W>M-o?M+W+1.5*s.leftPadding>f?E+" taskTextOutsideLeft taskTextOutside"+P+" "+N:E+" taskTextOutsideRight taskTextOutside"+P+" "+N+" width-"+W:E+" taskText taskText"+P+" "+N+" width-"+W}),lt().securityLevel==="sandbox"){let a;a=bt("#i"+e);const o=a.nodes()[0].contentDocument;x.filter(function(M){return i.has(M.id)}).each(function(M){var W=o.querySelector("#"+M.id),E=o.querySelector("#"+M.id+"-text");const P=W.parentNode;var N=o.createElement("a");N.setAttribute("xlink:href",i.get(M.id)),N.setAttribute("target","_top"),P.appendChild(N),N.appendChild(W),N.appendChild(E)})}}d(F,"drawRects");function O(h,b,v,p,m,c,f,u){if(f.length===0&&u.length===0)return;let x,i;for(const{startTime:E,endTime:P}of c)(x===void 0||E<x)&&(x=E),(i===void 0||P>i)&&(i=P);if(!x||!i)return;if(Q(i).diff(Q(x),"year")>5){st.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 a=r.db.getDateFormat(),o=[];let M=null,W=Q(x);for(;W.valueOf()<=i;)r.db.isInvalidDate(W,a,f,u)?M?M.end=W:M={start:W,end:W}:M&&(o.push(M),M=null),W=W.add(1,"d");z.append("g").selectAll("rect").data(o).enter().append("rect").attr("id",E=>"exclude-"+E.start.format("YYYY-MM-DD")).attr("x",E=>A(E.start.startOf("day"))+v).attr("y",s.gridLineStartPadding).attr("width",E=>A(E.end.endOf("day"))-A(E.start.startOf("day"))).attr("height",m-b-s.gridLineStartPadding).attr("transform-origin",function(E,P){return(A(E.start)+v+.5*(A(E.end)-A(E.start))).toString()+"px "+(P*h+.5*m).toString()+"px"}).attr("class","exclude-range")}d(O,"drawExcludeDays");function H(h,b,v,p){if(v<=0||h>b)return 1/0;const m=b-h,c=Q.duration({[p??"day"]:v}).asMilliseconds();return c<=0?1/0:Math.ceil(m/c)}d(H,"getEstimatedTickCount");function V(h,b,v,p){const m=r.db.getDateFormat(),c=r.db.getAxisFormat();let f;c?f=c:m==="D"?f="%d":f=s.axisFormat??"%Y-%m-%d";let u=pn(A).tickSize(-p+b+s.gridLineStartPadding).tickFormat(re(f));const x=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||s.tickInterval);if(x!==null){const i=parseInt(x[1],10);if(isNaN(i)||i<=0)st.warn(`Invalid tick interval value: "${x[1]}". Skipping custom tick interval.`);else{const a=x[2],o=r.db.getWeekday()||s.weekday,M=A.domain(),W=M[0],E=M[1],P=H(W,E,i,a);if(P>Ft)st.warn(`The tick interval "${i}${a}" would generate ${P} ticks, which exceeds the maximum allowed (${Ft}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(a){case"millisecond":u.ticks(ue.every(i));break;case"second":u.ticks(le.every(i));break;case"minute":u.ticks(ce.every(i));break;case"hour":u.ticks(oe.every(i));break;case"day":u.ticks(ae.every(i));break;case"week":u.ticks(ge[o].every(i));break;case"month":u.ticks(se.every(i));break}}}if(z.append("g").attr("class","grid").attr("transform","translate("+h+", "+(p-50)+")").call(u).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),r.db.topAxisEnabled()||s.topAxis){let i=kn(A).tickSize(-p+b+s.gridLineStartPadding).tickFormat(re(f));if(x!==null){const a=parseInt(x[1],10);if(isNaN(a)||a<=0)st.warn(`Invalid tick interval value: "${x[1]}". Skipping custom tick interval.`);else{const o=x[2],M=r.db.getWeekday()||s.weekday,W=A.domain(),E=W[0],P=W[1];if(H(E,P,a,o)<=Ft)switch(o){case"millisecond":i.ticks(ue.every(a));break;case"second":i.ticks(le.every(a));break;case"minute":i.ticks(ce.every(a));break;case"hour":i.ticks(oe.every(a));break;case"day":i.ticks(ae.every(a));break;case"week":i.ticks(ge[M].every(a));break;case"month":i.ticks(se.every(a));break}}}z.append("g").attr("class","grid").attr("transform","translate("+h+", "+b+")").call(i).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}d(V,"makeGrid");function Y(h,b){let v=0;const p=Object.keys(_).map(m=>[m,_[m]]);z.append("g").selectAll("text").data(p).enter().append(function(m){const c=m[0].split(rn.lineBreakRegex),f=-(c.length-1)/2,u=I.createElementNS("http://www.w3.org/2000/svg","text");u.setAttribute("dy",f+"em");for(const[x,i]of c.entries()){const a=I.createElementNS("http://www.w3.org/2000/svg","tspan");a.setAttribute("alignment-baseline","central"),a.setAttribute("x","10"),x>0&&a.setAttribute("dy","1em"),a.textContent=i,u.appendChild(a)}return u}).attr("x",10).attr("y",function(m,c){if(c>0)for(let f=0;f<c;f++)return v+=p[c-1][1],m[1]*h/2+v*h+b;else return m[1]*h/2+b}).attr("font-size",s.sectionFontSize).attr("class",function(m){for(const[c,f]of L.entries())if(m[0]===f)return"sectionTitle sectionTitle"+c%s.numberSectionStyles;return"sectionTitle"})}d(Y,"vertLabels");function g(h,b,v,p){const m=r.db.getTodayMarker();if(m==="off")return;const c=z.append("g").attr("class","today"),f=new Date,u=c.append("line");u.attr("x1",A(f)+h).attr("x2",A(f)+h).attr("y1",s.titleTopMargin).attr("y2",p-s.titleTopMargin).attr("class","today"),m!==""&&u.attr("style",m.replace(/,/g,";"))}d(g,"drawToday");function y(h){const b={},v=[];for(let p=0,m=h.length;p<m;++p)Object.prototype.hasOwnProperty.call(b,h[p])||(b[h[p]]=!0,v.push(h[p]));return v}d(y,"checkUnique")},"draw"),Mi={setConf:$i,draw:Di},Si=d(t=>`
|
|
7
7
|
.mermaid-main-font {
|
|
8
8
|
font-family: ${t.fontFamily};
|
|
9
9
|
}
|
|
@@ -264,4 +264,4 @@ Expecting `+vt.join(", ")+", got '"+(this.terminals_[B]||B)+"'":Ct="Parse error
|
|
|
264
264
|
fill: ${t.titleColor||t.textColor};
|
|
265
265
|
font-family: ${t.fontFamily};
|
|
266
266
|
}
|
|
267
|
-
`,"getStyles"),Ci=Si,Ai={parser:Hn,db:wi,renderer:
|
|
267
|
+
`,"getStyles"),Ci=Si,Ai={parser:Hn,db:wi,renderer:Mi,styles:Ci};export{Ai as diagram};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import{m as X}from"./chunk-4BX2VUAB-BI1eieHX-BcH4s9g3.js";import{e as Q}from"./chunk-QZHKN3VN-1GW3GHKe-C9vGZ5SL.js";import{D as m,l as Z,P as rr,O as tr,W as er,f as or,H as nr,x as w,w as ar,t as cr,k as sr,C as ir,y as dr,M as C,E as hr,F as $r,G as mr,N as lr}from"./index-Ga9tZhFZ.js";import{j as yr}from"./treemap-KMMF4GRG-D_CgoaQq-1cg8_rRW.js";import"./min-rCpHWDFS-Bpi4dGNR.js";import"./_baseUniq-D5Eo-o17-Dkf2eEoL.js";var u={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},gr=mr.gitGraph,O=m(()=>hr({...gr,...$r().gitGraph}),"getConfig"),i=new Q(()=>{const t=O(),r=t.mainBranchName,e=t.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:e}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function S(){return lr({length:7})}m(S,"getID");function K(t,r){const e=Object.create(null);return t.reduce((a,c)=>{const s=r(c);return e[s]||(e[s]=!0,a.push(c)),a},[])}m(K,"uniqBy");var pr=m(function(t){i.records.direction=t},"setDirection"),fr=m(function(t){w.debug("options str",t),t=t==null?void 0:t.trim(),t=t||"{}";try{i.records.options=JSON.parse(t)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),xr=m(function(){return i.records.options},"getOptions"),ur=m(function(t){let r=t.msg,e=t.id;const a=t.type;let c=t.tags;w.info("commit",r,e,a,c),w.debug("Entering commit:",r,e,a,c);const s=O();e=C.sanitizeText(e,s),r=C.sanitizeText(r,s),c=c==null?void 0:c.map(h=>C.sanitizeText(h,s));const d={id:e||i.records.seq+"-"+S(),message:r,seq:i.records.seq++,type:a??u.NORMAL,tags:c??[],parents:i.records.head==null?[]:[i.records.head.id],branch:i.records.currBranch};i.records.head=d,w.info("main branch",s.mainBranchName),i.records.commits.has(d.id)&&w.warn(`Commit ID ${d.id} already exists`),i.records.commits.set(d.id,d),i.records.branches.set(i.records.currBranch,d.id),w.debug("in pushCommit "+d.id)},"commit"),br=m(function(t){let r=t.name;const e=t.order;if(r=C.sanitizeText(r,O()),i.records.branches.has(r))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 ${r}")`);i.records.branches.set(r,i.records.head!=null?i.records.head.id:null),i.records.branchConfig.set(r,{name:r,order:e}),_(r),w.debug("in createBranch")},"branch"),wr=m(t=>{let r=t.branch,e=t.id;const a=t.type,c=t.tags,s=O();r=C.sanitizeText(r,s),e&&(e=C.sanitizeText(e,s));const d=i.records.branches.get(i.records.currBranch),h=i.records.branches.get(r),l=d?i.records.commits.get(d):void 0,o=h?i.records.commits.get(h):void 0;if(l&&o&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(i.records.currBranch===r){const $=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},$}if(l===void 0||!l){const $=new Error(`Incorrect usage of "merge". Current branch (${i.records.currBranch})has no commits`);throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},$}if(!i.records.branches.has(r)){const $=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},$}if(o===void 0||!o){const $=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},$}if(l===o){const $=new Error('Incorrect usage of "merge". Both branches have same head');throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},$}if(e&&i.records.commits.has(e)){const $=new Error('Incorrect usage of "merge". Commit with id:'+e+" already exists, use different custom id");throw $.hash={text:`merge ${r} ${e} ${a} ${c==null?void 0:c.join(" ")}`,token:`merge ${r} ${e} ${a} ${c==null?void 0:c.join(" ")}`,expected:[`merge ${r} ${e}_UNIQUE ${a} ${c==null?void 0:c.join(" ")}`]},$}const n=h||"",x={id:e||`${i.records.seq}-${S()}`,message:`merged branch ${r} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,n],branch:i.records.currBranch,type:u.MERGE,customType:a,customId:!!e,tags:c??[]};i.records.head=x,i.records.commits.set(x.id,x),i.records.branches.set(i.records.currBranch,x.id),w.debug(i.records.branches),w.debug("in mergeBranch")},"merge"),Br=m(function(t){let r=t.id,e=t.targetId,a=t.tags,c=t.parent;w.debug("Entering cherryPick:",r,e,a);const s=O();if(r=C.sanitizeText(r,s),e=C.sanitizeText(e,s),a=a==null?void 0:a.map(l=>C.sanitizeText(l,s)),c=C.sanitizeText(c,s),!r||!i.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},l}const d=i.records.commits.get(r);if(d===void 0||!d)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(c&&!(Array.isArray(d.parents)&&d.parents.includes(c)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const h=d.branch;if(d.type===u.MERGE&&!c)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!e||!i.records.commits.has(e)){if(h===i.records.currBranch){const x=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw x.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},x}const l=i.records.branches.get(i.records.currBranch);if(l===void 0||!l){const x=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw x.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},x}const o=i.records.commits.get(l);if(o===void 0||!o){const x=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw x.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},x}const n={id:i.records.seq+"-"+S(),message:`cherry-picked ${d==null?void 0:d.message} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,d.id],branch:i.records.currBranch,type:u.CHERRY_PICK,tags:a?a.filter(Boolean):[`cherry-pick:${d.id}${d.type===u.MERGE?`|parent:${c}`:""}`]};i.records.head=n,i.records.commits.set(n.id,n),i.records.branches.set(i.records.currBranch,n.id),w.debug(i.records.branches),w.debug("in cherryPick")}},"cherryPick"),_=m(function(t){if(t=C.sanitizeText(t,O()),i.records.branches.has(t)){i.records.currBranch=t;const r=i.records.branches.get(i.records.currBranch);r===void 0||!r?i.records.head=null:i.records.head=i.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw r.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},r}},"checkout");function W(t,r,e){const a=t.indexOf(r);a===-1?t.push(e):t.splice(a,1,e)}m(W,"upsert");function N(t){const r=t.reduce((c,s)=>c.seq>s.seq?c:s,t[0]);let e="";t.forEach(function(c){c===r?e+=" *":e+=" |"});const a=[e,r.id,r.seq];for(const c in i.records.branches)i.records.branches.get(c)===r.id&&a.push(c);if(w.debug(a.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const c=i.records.commits.get(r.parents[0]);W(t,r,c),r.parents[1]&&t.push(i.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const c=i.records.commits.get(r.parents[0]);W(t,r,c)}}t=K(t,c=>c.id),N(t)}m(N,"prettyPrintCommitHistory");var Er=m(function(){w.debug(i.records.commits);const t=Y()[0];N([t])},"prettyPrint"),vr=m(function(){i.reset(),dr()},"clear"),kr=m(function(){return[...i.records.branchConfig.values()].map((t,r)=>t.order!==null&&t.order!==void 0?t:{...t,order:parseFloat(`0.${r}`)}).sort((t,r)=>(t.order??0)-(r.order??0)).map(({name:t})=>({name:t}))},"getBranchesAsObjArray"),Cr=m(function(){return i.records.branches},"getBranches"),Lr=m(function(){return i.records.commits},"getCommits"),Y=m(function(){const t=[...i.records.commits.values()];return t.forEach(function(r){w.debug(r.id)}),t.sort((r,e)=>r.seq-e.seq),t},"getCommitsArray"),Tr=m(function(){return i.records.currBranch},"getCurrentBranch"),Mr=m(function(){return i.records.direction},"getDirection"),Pr=m(function(){return i.records.head},"getHead"),J={commitType:u,getConfig:O,setDirection:pr,setOptions:fr,getOptions:xr,commit:ur,branch:br,merge:wr,cherryPick:Br,checkout:_,prettyPrint:Er,clear:vr,getBranchesAsObjArray:kr,getBranches:Cr,getCommits:Lr,getCommitsArray:Y,getCurrentBranch:Tr,getDirection:Mr,getHead:Pr,setAccTitle:nr,getAccTitle:or,getAccDescription:er,setAccDescription:tr,setDiagramTitle:rr,getDiagramTitle:Z},Rr=m((t,r)=>{X(t,r),t.dir&&r.setDirection(t.dir);for(const e of t.statements)Ar(e,r)},"populate"),Ar=m((t,r)=>{const e={Commit:m(a=>r.commit(Ir(a)),"Commit"),Branch:m(a=>r.branch(Gr(a)),"Branch"),Merge:m(a=>r.merge(Or(a)),"Merge"),Checkout:m(a=>r.checkout(qr(a)),"Checkout"),CherryPicking:m(a=>r.cherryPick(Hr(a)),"CherryPicking")}[t.$type];e?e(t):w.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),Ir=m(t=>({id:t.id,msg:t.message??"",type:t.type!==void 0?u[t.type]:u.NORMAL,tags:t.tags??void 0}),"parseCommit"),Gr=m(t=>({name:t.name,order:t.order??0}),"parseBranch"),Or=m(t=>({branch:t.branch,id:t.id??"",type:t.type!==void 0?u[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),qr=m(t=>t.branch,"parseCheckout"),Hr=m(t=>{var r;return{id:t.id,targetId:"",tags:((r=t.tags)==null?void 0:r.length)===0?void 0:t.tags,parent:t.parent}},"parseCherryPicking"),zr={parse:m(async t=>{const r=await yr("gitGraph",t);w.debug(r),Rr(r,J)},"parse")},j=ar(),E=j==null?void 0:j.gitGraph,A=10,I=40,L=4,M=2,G=8,v=new Map,k=new Map,z=30,q=new Map,D=[],R=0,f="LR",Dr=m(()=>{v.clear(),k.clear(),q.clear(),R=0,D=[],f="LR"},"clear"),V=m(t=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof t=="string"?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(e=>{const a=document.createElementNS("http://www.w3.org/2000/svg","tspan");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),a.setAttribute("dy","1em"),a.setAttribute("x","0"),a.setAttribute("class","row"),a.textContent=e.trim(),r.appendChild(a)}),r},"drawText"),U=m(t=>{let r,e,a;return f==="BT"?(e=m((c,s)=>c<=s,"comparisonFunc"),a=1/0):(e=m((c,s)=>c>=s,"comparisonFunc"),a=0),t.forEach(c=>{var s,d;const h=f==="TB"||f=="BT"?(s=k.get(c))==null?void 0:s.y:(d=k.get(c))==null?void 0:d.x;h!==void 0&&e(h,a)&&(r=c,a=h)}),r},"findClosestParent"),Sr=m(t=>{let r="",e=1/0;return t.forEach(a=>{const c=k.get(a).y;c<=e&&(r=a,e=c)}),r||void 0},"findClosestParentBT"),Wr=m((t,r,e)=>{let a=e,c=e;const s=[];t.forEach(d=>{const h=r.get(d);if(!h)throw new Error(`Commit not found for key ${d}`);h.parents.length?(a=jr(h),c=Math.max(a,c)):s.push(h),Fr(h,a)}),a=c,s.forEach(d=>{Kr(d,a,e)}),t.forEach(d=>{const h=r.get(d);if(h!=null&&h.parents.length){const l=Sr(h.parents);a=k.get(l).y-I,a<=c&&(c=a);const o=v.get(h.branch).pos,n=a-A;k.set(h.id,{x:o,y:n})}})},"setParallelBTPos"),Nr=m(t=>{var r;const e=U(t.parents.filter(c=>c!==null));if(!e)throw new Error(`Closest parent not found for commit ${t.id}`);const a=(r=k.get(e))==null?void 0:r.y;if(a===void 0)throw new Error(`Closest parent position not found for commit ${t.id}`);return a},"findClosestParentPos"),jr=m(t=>Nr(t)+I,"calculateCommitPosition"),Fr=m((t,r)=>{const e=v.get(t.branch);if(!e)throw new Error(`Branch not found for commit ${t.id}`);const a=e.pos,c=r+A;return k.set(t.id,{x:a,y:c}),{x:a,y:c}},"setCommitPosition"),Kr=m((t,r,e)=>{const a=v.get(t.branch);if(!a)throw new Error(`Branch not found for commit ${t.id}`);const c=r+e,s=a.pos;k.set(t.id,{x:s,y:c})},"setRootPosition"),_r=m((t,r,e,a,c,s)=>{if(s===u.HIGHLIGHT)t.append("rect").attr("x",e.x-10).attr("y",e.y-10).attr("width",20).attr("height",20).attr("class",`commit ${r.id} commit-highlight${c%G} ${a}-outer`),t.append("rect").attr("x",e.x-6).attr("y",e.y-6).attr("width",12).attr("height",12).attr("class",`commit ${r.id} commit${c%G} ${a}-inner`);else if(s===u.CHERRY_PICK)t.append("circle").attr("cx",e.x).attr("cy",e.y).attr("r",10).attr("class",`commit ${r.id} ${a}`),t.append("circle").attr("cx",e.x-3).attr("cy",e.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${r.id} ${a}`),t.append("circle").attr("cx",e.x+3).attr("cy",e.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${r.id} ${a}`),t.append("line").attr("x1",e.x+3).attr("y1",e.y+1).attr("x2",e.x).attr("y2",e.y-5).attr("stroke","#fff").attr("class",`commit ${r.id} ${a}`),t.append("line").attr("x1",e.x-3).attr("y1",e.y+1).attr("x2",e.x).attr("y2",e.y-5).attr("stroke","#fff").attr("class",`commit ${r.id} ${a}`);else{const d=t.append("circle");if(d.attr("cx",e.x),d.attr("cy",e.y),d.attr("r",r.type===u.MERGE?9:10),d.attr("class",`commit ${r.id} commit${c%G}`),s===u.MERGE){const h=t.append("circle");h.attr("cx",e.x),h.attr("cy",e.y),h.attr("r",6),h.attr("class",`commit ${a} ${r.id} commit${c%G}`)}s===u.REVERSE&&t.append("path").attr("d",`M ${e.x-5},${e.y-5}L${e.x+5},${e.y+5}M${e.x-5},${e.y+5}L${e.x+5},${e.y-5}`).attr("class",`commit ${a} ${r.id} commit${c%G}`)}},"drawCommitBullet"),Yr=m((t,r,e,a)=>{var c;if(r.type!==u.CHERRY_PICK&&(r.customId&&r.type===u.MERGE||r.type!==u.MERGE)&&E!=null&&E.showCommitLabel){const s=t.append("g"),d=s.insert("rect").attr("class","commit-label-bkg"),h=s.append("text").attr("x",a).attr("y",e.y+25).attr("class","commit-label").text(r.id),l=(c=h.node())==null?void 0:c.getBBox();if(l&&(d.attr("x",e.posWithOffset-l.width/2-M).attr("y",e.y+13.5).attr("width",l.width+2*M).attr("height",l.height+2*M),f==="TB"||f==="BT"?(d.attr("x",e.x-(l.width+4*L+5)).attr("y",e.y-12),h.attr("x",e.x-(l.width+4*L)).attr("y",e.y+l.height-12)):h.attr("x",e.posWithOffset-l.width/2),E.rotateCommitLabel))if(f==="TB"||f==="BT")h.attr("transform","rotate(-45, "+e.x+", "+e.y+")"),d.attr("transform","rotate(-45, "+e.x+", "+e.y+")");else{const o=-7.5-(l.width+10)/25*9.5,n=10+l.width/25*8.5;s.attr("transform","translate("+o+", "+n+") rotate(-45, "+a+", "+e.y+")")}}},"drawCommitLabel"),Jr=m((t,r,e,a)=>{var c;if(r.tags.length>0){let s=0,d=0,h=0;const l=[];for(const o of r.tags.reverse()){const n=t.insert("polygon"),x=t.append("circle"),$=t.append("text").attr("y",e.y-16-s).attr("class","tag-label").text(o),y=(c=$.node())==null?void 0:c.getBBox();if(!y)throw new Error("Tag bbox not found");d=Math.max(d,y.width),h=Math.max(h,y.height),$.attr("x",e.posWithOffset-y.width/2),l.push({tag:$,hole:x,rect:n,yOffset:s}),s+=20}for(const{tag:o,hole:n,rect:x,yOffset:$}of l){const y=h/2,p=e.y-19.2-$;if(x.attr("class","tag-label-bkg").attr("points",`
|
|
2
|
-
${
|
|
3
|
-
${
|
|
1
|
+
import{m as J}from"./chunk-4BX2VUAB-DAh9ktmY-DJUd7iky.js";import{e as U}from"./chunk-QZHKN3VN-DVJOrqBZ-CMUptYKe.js";import{Q as m,E as Z,v as rr,e as tr,p as er,h as or,B as nr,s as w,k as cr,w as ar,O as sr,K as ir,F as dr,l as C,X as hr,L as $r,T as mr,R as lr}from"./index-CS9omSqb.js";import{j as yr}from"./treemap-KMMF4GRG-CkW25-tn-CpmtOl1S.js";import"./min-C2aDz5ZK-B9D8sW79.js";import"./_baseUniq-BPMphbq5-Ci3F4c-i.js";var u={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},gr=mr.gitGraph,O=m(()=>hr({...gr,...$r().gitGraph}),"getConfig"),i=new U(()=>{const t=O(),r=t.mainBranchName,e=t.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:e}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function D(){return lr({length:7})}m(D,"getID");function F(t,r){const e=Object.create(null);return t.reduce((c,a)=>{const s=r(a);return e[s]||(e[s]=!0,c.push(a)),c},[])}m(F,"uniqBy");var pr=m(function(t){i.records.direction=t},"setDirection"),xr=m(function(t){w.debug("options str",t),t=t==null?void 0:t.trim(),t=t||"{}";try{i.records.options=JSON.parse(t)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),fr=m(function(){return i.records.options},"getOptions"),ur=m(function(t){let r=t.msg,e=t.id;const c=t.type;let a=t.tags;w.info("commit",r,e,c,a),w.debug("Entering commit:",r,e,c,a);const s=O();e=C.sanitizeText(e,s),r=C.sanitizeText(r,s),a=a==null?void 0:a.map(h=>C.sanitizeText(h,s));const d={id:e||i.records.seq+"-"+D(),message:r,seq:i.records.seq++,type:c??u.NORMAL,tags:a??[],parents:i.records.head==null?[]:[i.records.head.id],branch:i.records.currBranch};i.records.head=d,w.info("main branch",s.mainBranchName),i.records.commits.has(d.id)&&w.warn(`Commit ID ${d.id} already exists`),i.records.commits.set(d.id,d),i.records.branches.set(i.records.currBranch,d.id),w.debug("in pushCommit "+d.id)},"commit"),br=m(function(t){let r=t.name;const e=t.order;if(r=C.sanitizeText(r,O()),i.records.branches.has(r))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 ${r}")`);i.records.branches.set(r,i.records.head!=null?i.records.head.id:null),i.records.branchConfig.set(r,{name:r,order:e}),_(r),w.debug("in createBranch")},"branch"),wr=m(t=>{let r=t.branch,e=t.id;const c=t.type,a=t.tags,s=O();r=C.sanitizeText(r,s),e&&(e=C.sanitizeText(e,s));const d=i.records.branches.get(i.records.currBranch),h=i.records.branches.get(r),l=d?i.records.commits.get(d):void 0,o=h?i.records.commits.get(h):void 0;if(l&&o&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(i.records.currBranch===r){const $=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},$}if(l===void 0||!l){const $=new Error(`Incorrect usage of "merge". Current branch (${i.records.currBranch})has no commits`);throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},$}if(!i.records.branches.has(r)){const $=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},$}if(o===void 0||!o){const $=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},$}if(l===o){const $=new Error('Incorrect usage of "merge". Both branches have same head');throw $.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},$}if(e&&i.records.commits.has(e)){const $=new Error('Incorrect usage of "merge". Commit with id:'+e+" already exists, use different custom id");throw $.hash={text:`merge ${r} ${e} ${c} ${a==null?void 0:a.join(" ")}`,token:`merge ${r} ${e} ${c} ${a==null?void 0:a.join(" ")}`,expected:[`merge ${r} ${e}_UNIQUE ${c} ${a==null?void 0:a.join(" ")}`]},$}const n=h||"",f={id:e||`${i.records.seq}-${D()}`,message:`merged branch ${r} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,n],branch:i.records.currBranch,type:u.MERGE,customType:c,customId:!!e,tags:a??[]};i.records.head=f,i.records.commits.set(f.id,f),i.records.branches.set(i.records.currBranch,f.id),w.debug(i.records.branches),w.debug("in mergeBranch")},"merge"),Br=m(function(t){let r=t.id,e=t.targetId,c=t.tags,a=t.parent;w.debug("Entering cherryPick:",r,e,c);const s=O();if(r=C.sanitizeText(r,s),e=C.sanitizeText(e,s),c=c==null?void 0:c.map(l=>C.sanitizeText(l,s)),a=C.sanitizeText(a,s),!r||!i.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},l}const d=i.records.commits.get(r);if(d===void 0||!d)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(a&&!(Array.isArray(d.parents)&&d.parents.includes(a)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const h=d.branch;if(d.type===u.MERGE&&!a)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!e||!i.records.commits.has(e)){if(h===i.records.currBranch){const f=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw f.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},f}const l=i.records.branches.get(i.records.currBranch);if(l===void 0||!l){const f=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw f.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},f}const o=i.records.commits.get(l);if(o===void 0||!o){const f=new Error(`Incorrect usage of "cherry-pick". Current branch (${i.records.currBranch})has no commits`);throw f.hash={text:`cherryPick ${r} ${e}`,token:`cherryPick ${r} ${e}`,expected:["cherry-pick abc"]},f}const n={id:i.records.seq+"-"+D(),message:`cherry-picked ${d==null?void 0:d.message} into ${i.records.currBranch}`,seq:i.records.seq++,parents:i.records.head==null?[]:[i.records.head.id,d.id],branch:i.records.currBranch,type:u.CHERRY_PICK,tags:c?c.filter(Boolean):[`cherry-pick:${d.id}${d.type===u.MERGE?`|parent:${a}`:""}`]};i.records.head=n,i.records.commits.set(n.id,n),i.records.branches.set(i.records.currBranch,n.id),w.debug(i.records.branches),w.debug("in cherryPick")}},"cherryPick"),_=m(function(t){if(t=C.sanitizeText(t,O()),i.records.branches.has(t)){i.records.currBranch=t;const r=i.records.branches.get(i.records.currBranch);r===void 0||!r?i.records.head=null:i.records.head=i.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw r.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},r}},"checkout");function N(t,r,e){const c=t.indexOf(r);c===-1?t.push(e):t.splice(c,1,e)}m(N,"upsert");function j(t){const r=t.reduce((a,s)=>a.seq>s.seq?a:s,t[0]);let e="";t.forEach(function(a){a===r?e+=" *":e+=" |"});const c=[e,r.id,r.seq];for(const a in i.records.branches)i.records.branches.get(a)===r.id&&c.push(a);if(w.debug(c.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const a=i.records.commits.get(r.parents[0]);N(t,r,a),r.parents[1]&&t.push(i.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const a=i.records.commits.get(r.parents[0]);N(t,r,a)}}t=F(t,a=>a.id),j(t)}m(j,"prettyPrintCommitHistory");var Er=m(function(){w.debug(i.records.commits);const t=Y()[0];j([t])},"prettyPrint"),vr=m(function(){i.reset(),dr()},"clear"),kr=m(function(){return[...i.records.branchConfig.values()].map((t,r)=>t.order!==null&&t.order!==void 0?t:{...t,order:parseFloat(`0.${r}`)}).sort((t,r)=>(t.order??0)-(r.order??0)).map(({name:t})=>({name:t}))},"getBranchesAsObjArray"),Cr=m(function(){return i.records.branches},"getBranches"),Lr=m(function(){return i.records.commits},"getCommits"),Y=m(function(){const t=[...i.records.commits.values()];return t.forEach(function(r){w.debug(r.id)}),t.sort((r,e)=>r.seq-e.seq),t},"getCommitsArray"),Tr=m(function(){return i.records.currBranch},"getCurrentBranch"),Mr=m(function(){return i.records.direction},"getDirection"),Pr=m(function(){return i.records.head},"getHead"),Q={commitType:u,getConfig:O,setDirection:pr,setOptions:xr,getOptions:fr,commit:ur,branch:br,merge:wr,cherryPick:Br,checkout:_,prettyPrint:Er,clear:vr,getBranchesAsObjArray:kr,getBranches:Cr,getCommits:Lr,getCommitsArray:Y,getCurrentBranch:Tr,getDirection:Mr,getHead:Pr,setAccTitle:nr,getAccTitle:or,getAccDescription:er,setAccDescription:tr,setDiagramTitle:rr,getDiagramTitle:Z},Rr=m((t,r)=>{J(t,r),t.dir&&r.setDirection(t.dir);for(const e of t.statements)Ir(e,r)},"populate"),Ir=m((t,r)=>{const e={Commit:m(c=>r.commit(Ar(c)),"Commit"),Branch:m(c=>r.branch(Gr(c)),"Branch"),Merge:m(c=>r.merge(Or(c)),"Merge"),Checkout:m(c=>r.checkout(qr(c)),"Checkout"),CherryPicking:m(c=>r.cherryPick(Hr(c)),"CherryPicking")}[t.$type];e?e(t):w.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),Ar=m(t=>({id:t.id,msg:t.message??"",type:t.type!==void 0?u[t.type]:u.NORMAL,tags:t.tags??void 0}),"parseCommit"),Gr=m(t=>({name:t.name,order:t.order??0}),"parseBranch"),Or=m(t=>({branch:t.branch,id:t.id??"",type:t.type!==void 0?u[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),qr=m(t=>t.branch,"parseCheckout"),Hr=m(t=>{var r;return{id:t.id,targetId:"",tags:((r=t.tags)==null?void 0:r.length)===0?void 0:t.tags,parent:t.parent}},"parseCherryPicking"),zr={parse:m(async t=>{const r=await yr("gitGraph",t);w.debug(r),Rr(r,Q)},"parse")},W=cr(),E=W==null?void 0:W.gitGraph,I=10,A=40,L=4,M=2,G=8,v=new Map,k=new Map,z=30,q=new Map,S=[],R=0,x="LR",Sr=m(()=>{v.clear(),k.clear(),q.clear(),R=0,S=[],x="LR"},"clear"),V=m(t=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof t=="string"?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(e=>{const c=document.createElementNS("http://www.w3.org/2000/svg","tspan");c.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),c.setAttribute("dy","1em"),c.setAttribute("x","0"),c.setAttribute("class","row"),c.textContent=e.trim(),r.appendChild(c)}),r},"drawText"),X=m(t=>{let r,e,c;return x==="BT"?(e=m((a,s)=>a<=s,"comparisonFunc"),c=1/0):(e=m((a,s)=>a>=s,"comparisonFunc"),c=0),t.forEach(a=>{var s,d;const h=x==="TB"||x=="BT"?(s=k.get(a))==null?void 0:s.y:(d=k.get(a))==null?void 0:d.x;h!==void 0&&e(h,c)&&(r=a,c=h)}),r},"findClosestParent"),Dr=m(t=>{let r="",e=1/0;return t.forEach(c=>{const a=k.get(c).y;a<=e&&(r=c,e=a)}),r||void 0},"findClosestParentBT"),Nr=m((t,r,e)=>{let c=e,a=e;const s=[];t.forEach(d=>{const h=r.get(d);if(!h)throw new Error(`Commit not found for key ${d}`);h.parents.length?(c=Wr(h),a=Math.max(c,a)):s.push(h),Kr(h,c)}),c=a,s.forEach(d=>{Fr(d,c,e)}),t.forEach(d=>{const h=r.get(d);if(h!=null&&h.parents.length){const l=Dr(h.parents);c=k.get(l).y-A,c<=a&&(a=c);const o=v.get(h.branch).pos,n=c-I;k.set(h.id,{x:o,y:n})}})},"setParallelBTPos"),jr=m(t=>{var r;const e=X(t.parents.filter(a=>a!==null));if(!e)throw new Error(`Closest parent not found for commit ${t.id}`);const c=(r=k.get(e))==null?void 0:r.y;if(c===void 0)throw new Error(`Closest parent position not found for commit ${t.id}`);return c},"findClosestParentPos"),Wr=m(t=>jr(t)+A,"calculateCommitPosition"),Kr=m((t,r)=>{const e=v.get(t.branch);if(!e)throw new Error(`Branch not found for commit ${t.id}`);const c=e.pos,a=r+I;return k.set(t.id,{x:c,y:a}),{x:c,y:a}},"setCommitPosition"),Fr=m((t,r,e)=>{const c=v.get(t.branch);if(!c)throw new Error(`Branch not found for commit ${t.id}`);const a=r+e,s=c.pos;k.set(t.id,{x:s,y:a})},"setRootPosition"),_r=m((t,r,e,c,a,s)=>{if(s===u.HIGHLIGHT)t.append("rect").attr("x",e.x-10).attr("y",e.y-10).attr("width",20).attr("height",20).attr("class",`commit ${r.id} commit-highlight${a%G} ${c}-outer`),t.append("rect").attr("x",e.x-6).attr("y",e.y-6).attr("width",12).attr("height",12).attr("class",`commit ${r.id} commit${a%G} ${c}-inner`);else if(s===u.CHERRY_PICK)t.append("circle").attr("cx",e.x).attr("cy",e.y).attr("r",10).attr("class",`commit ${r.id} ${c}`),t.append("circle").attr("cx",e.x-3).attr("cy",e.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${r.id} ${c}`),t.append("circle").attr("cx",e.x+3).attr("cy",e.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${r.id} ${c}`),t.append("line").attr("x1",e.x+3).attr("y1",e.y+1).attr("x2",e.x).attr("y2",e.y-5).attr("stroke","#fff").attr("class",`commit ${r.id} ${c}`),t.append("line").attr("x1",e.x-3).attr("y1",e.y+1).attr("x2",e.x).attr("y2",e.y-5).attr("stroke","#fff").attr("class",`commit ${r.id} ${c}`);else{const d=t.append("circle");if(d.attr("cx",e.x),d.attr("cy",e.y),d.attr("r",r.type===u.MERGE?9:10),d.attr("class",`commit ${r.id} commit${a%G}`),s===u.MERGE){const h=t.append("circle");h.attr("cx",e.x),h.attr("cy",e.y),h.attr("r",6),h.attr("class",`commit ${c} ${r.id} commit${a%G}`)}s===u.REVERSE&&t.append("path").attr("d",`M ${e.x-5},${e.y-5}L${e.x+5},${e.y+5}M${e.x-5},${e.y+5}L${e.x+5},${e.y-5}`).attr("class",`commit ${c} ${r.id} commit${a%G}`)}},"drawCommitBullet"),Yr=m((t,r,e,c)=>{var a;if(r.type!==u.CHERRY_PICK&&(r.customId&&r.type===u.MERGE||r.type!==u.MERGE)&&E!=null&&E.showCommitLabel){const s=t.append("g"),d=s.insert("rect").attr("class","commit-label-bkg"),h=s.append("text").attr("x",c).attr("y",e.y+25).attr("class","commit-label").text(r.id),l=(a=h.node())==null?void 0:a.getBBox();if(l&&(d.attr("x",e.posWithOffset-l.width/2-M).attr("y",e.y+13.5).attr("width",l.width+2*M).attr("height",l.height+2*M),x==="TB"||x==="BT"?(d.attr("x",e.x-(l.width+4*L+5)).attr("y",e.y-12),h.attr("x",e.x-(l.width+4*L)).attr("y",e.y+l.height-12)):h.attr("x",e.posWithOffset-l.width/2),E.rotateCommitLabel))if(x==="TB"||x==="BT")h.attr("transform","rotate(-45, "+e.x+", "+e.y+")"),d.attr("transform","rotate(-45, "+e.x+", "+e.y+")");else{const o=-7.5-(l.width+10)/25*9.5,n=10+l.width/25*8.5;s.attr("transform","translate("+o+", "+n+") rotate(-45, "+c+", "+e.y+")")}}},"drawCommitLabel"),Qr=m((t,r,e,c)=>{var a;if(r.tags.length>0){let s=0,d=0,h=0;const l=[];for(const o of r.tags.reverse()){const n=t.insert("polygon"),f=t.append("circle"),$=t.append("text").attr("y",e.y-16-s).attr("class","tag-label").text(o),y=(a=$.node())==null?void 0:a.getBBox();if(!y)throw new Error("Tag bbox not found");d=Math.max(d,y.width),h=Math.max(h,y.height),$.attr("x",e.posWithOffset-y.width/2),l.push({tag:$,hole:f,rect:n,yOffset:s}),s+=20}for(const{tag:o,hole:n,rect:f,yOffset:$}of l){const y=h/2,p=e.y-19.2-$;if(f.attr("class","tag-label-bkg").attr("points",`
|
|
2
|
+
${c-d/2-L/2},${p+M}
|
|
3
|
+
${c-d/2-L/2},${p-M}
|
|
4
4
|
${e.posWithOffset-d/2-L},${p-y-M}
|
|
5
5
|
${e.posWithOffset+d/2+L},${p-y-M}
|
|
6
6
|
${e.posWithOffset+d/2+L},${p+y+M}
|
|
7
|
-
${e.posWithOffset-d/2-L},${p+y+M}`),n.attr("cy",p).attr("cx",
|
|
7
|
+
${e.posWithOffset-d/2-L},${p+y+M}`),n.attr("cy",p).attr("cx",c-d/2+L/2).attr("r",1.5).attr("class","tag-hole"),x==="TB"||x==="BT"){const g=c+$;f.attr("class","tag-label-bkg").attr("points",`
|
|
8
8
|
${e.x},${g+2}
|
|
9
9
|
${e.x},${g-2}
|
|
10
|
-
${e.x+
|
|
11
|
-
${e.x+
|
|
12
|
-
${e.x+
|
|
13
|
-
${e.x+
|
|
14
|
-
`,"id:",r,e),!E)throw new Error("GitGraph config not found");const
|
|
10
|
+
${e.x+I},${g-y-2}
|
|
11
|
+
${e.x+I+d+4},${g-y-2}
|
|
12
|
+
${e.x+I+d+4},${g+y+2}
|
|
13
|
+
${e.x+I},${g+y+2}`).attr("transform","translate(12,12) rotate(45, "+e.x+","+c+")"),n.attr("cx",e.x+L/2).attr("cy",g).attr("transform","translate(12,12) rotate(45, "+e.x+","+c+")"),o.attr("x",e.x+5).attr("y",g+3).attr("transform","translate(14,14) rotate(45, "+e.x+","+c+")")}}}},"drawCommitTags"),Vr=m(t=>{switch(t.customType??t.type){case u.NORMAL:return"commit-normal";case u.REVERSE:return"commit-reverse";case u.HIGHLIGHT:return"commit-highlight";case u.MERGE:return"commit-merge";case u.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}},"getCommitClassType"),Xr=m((t,r,e,c)=>{const a={x:0,y:0};if(t.parents.length>0){const s=X(t.parents);if(s){const d=c.get(s)??a;return r==="TB"?d.y+A:r==="BT"?(c.get(t.id)??a).y-A:d.x+A}}else return r==="TB"?z:r==="BT"?(c.get(t.id)??a).y-A:0;return 0},"calculatePosition"),Jr=m((t,r,e)=>{var c,a;const s=x==="BT"&&e?r:r+I,d=x==="TB"||x==="BT"?s:(c=v.get(t.branch))==null?void 0:c.pos,h=x==="TB"||x==="BT"?(a=v.get(t.branch))==null?void 0:a.pos:s;if(h===void 0||d===void 0)throw new Error(`Position were undefined for commit ${t.id}`);return{x:h,y:d,posWithOffset:s}},"getCommitPosition"),K=m((t,r,e)=>{if(!E)throw new Error("GitGraph config not found");const c=t.append("g").attr("class","commit-bullets"),a=t.append("g").attr("class","commit-labels");let s=x==="TB"||x==="BT"?z:0;const d=[...r.keys()],h=(E==null?void 0:E.parallelCommits)??!1,l=m((n,f)=>{var $,y;const p=($=r.get(n))==null?void 0:$.seq,g=(y=r.get(f))==null?void 0:y.seq;return p!==void 0&&g!==void 0?p-g:0},"sortKeys");let o=d.sort(l);x==="BT"&&(h&&Nr(o,r,s),o=o.reverse()),o.forEach(n=>{var f;const $=r.get(n);if(!$)throw new Error(`Commit not found for key ${n}`);h&&(s=Xr($,x,s,k));const y=Jr($,s,h);if(e){const p=Vr($),g=$.customType??$.type,T=((f=v.get($.branch))==null?void 0:f.index)??0;_r(c,$,y,p,T,g),Yr(a,$,y,s),Qr(a,$,y,s)}x==="TB"||x==="BT"?k.set($.id,{x:y.x,y:y.posWithOffset}):k.set($.id,{x:y.posWithOffset,y:y.y}),s=x==="BT"&&h?s+A:s+A+I,s>R&&(R=s)})},"drawCommits"),Ur=m((t,r,e,c,a)=>{const s=(x==="TB"||x==="BT"?e.x<c.x:e.y<c.y)?r.branch:t.branch,d=m(l=>l.branch===s,"isOnBranchToGetCurve"),h=m(l=>l.seq>t.seq&&l.seq<r.seq,"isBetweenCommits");return[...a.values()].some(l=>h(l)&&d(l))},"shouldRerouteArrow"),H=m((t,r,e=0)=>{const c=t+Math.abs(t-r)/2;if(e>5)return c;if(S.every(s=>Math.abs(s-c)>=10))return S.push(c),c;const a=Math.abs(t-r);return H(t,r-a/5,e+1)},"findLane"),Zr=m((t,r,e,c)=>{var a,s,d,h,l;const o=k.get(r.id),n=k.get(e.id);if(o===void 0||n===void 0)throw new Error(`Commit positions not found for commits ${r.id} and ${e.id}`);const f=Ur(r,e,o,n,c);let $="",y="",p=0,g=0,T=(a=v.get(e.branch))==null?void 0:a.index;e.type===u.MERGE&&r.id!==e.parents[0]&&(T=(s=v.get(r.branch))==null?void 0:s.index);let b;if(f){$="A 10 10, 0, 0, 0,",y="A 10 10, 0, 0, 1,",p=10,g=10;const P=o.y<n.y?H(o.y,n.y):H(n.y,o.y),B=o.x<n.x?H(o.x,n.x):H(n.x,o.x);x==="TB"?o.x<n.x?b=`M ${o.x} ${o.y} L ${B-p} ${o.y} ${y} ${B} ${o.y+g} L ${B} ${n.y-p} ${$} ${B+g} ${n.y} L ${n.x} ${n.y}`:(T=(d=v.get(r.branch))==null?void 0:d.index,b=`M ${o.x} ${o.y} L ${B+p} ${o.y} ${$} ${B} ${o.y+g} L ${B} ${n.y-p} ${y} ${B-g} ${n.y} L ${n.x} ${n.y}`):x==="BT"?o.x<n.x?b=`M ${o.x} ${o.y} L ${B-p} ${o.y} ${$} ${B} ${o.y-g} L ${B} ${n.y+p} ${y} ${B+g} ${n.y} L ${n.x} ${n.y}`:(T=(h=v.get(r.branch))==null?void 0:h.index,b=`M ${o.x} ${o.y} L ${B+p} ${o.y} ${y} ${B} ${o.y-g} L ${B} ${n.y+p} ${$} ${B-g} ${n.y} L ${n.x} ${n.y}`):o.y<n.y?b=`M ${o.x} ${o.y} L ${o.x} ${P-p} ${$} ${o.x+g} ${P} L ${n.x-p} ${P} ${y} ${n.x} ${P+g} L ${n.x} ${n.y}`:(T=(l=v.get(r.branch))==null?void 0:l.index,b=`M ${o.x} ${o.y} L ${o.x} ${P+p} ${y} ${o.x+g} ${P} L ${n.x-p} ${P} ${$} ${n.x} ${P-g} L ${n.x} ${n.y}`)}else $="A 20 20, 0, 0, 0,",y="A 20 20, 0, 0, 1,",p=20,g=20,x==="TB"?(o.x<n.x&&(e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${o.x} ${n.y-p} ${$} ${o.x+g} ${n.y} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${n.x-p} ${o.y} ${y} ${n.x} ${o.y+g} L ${n.x} ${n.y}`),o.x>n.x&&($="A 20 20, 0, 0, 0,",y="A 20 20, 0, 0, 1,",p=20,g=20,e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${o.x} ${n.y-p} ${y} ${o.x-g} ${n.y} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${n.x+p} ${o.y} ${$} ${n.x} ${o.y+g} L ${n.x} ${n.y}`),o.x===n.x&&(b=`M ${o.x} ${o.y} L ${n.x} ${n.y}`)):x==="BT"?(o.x<n.x&&(e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${o.x} ${n.y+p} ${y} ${o.x+g} ${n.y} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${n.x-p} ${o.y} ${$} ${n.x} ${o.y-g} L ${n.x} ${n.y}`),o.x>n.x&&($="A 20 20, 0, 0, 0,",y="A 20 20, 0, 0, 1,",p=20,g=20,e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${o.x} ${n.y+p} ${$} ${o.x-g} ${n.y} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${n.x-p} ${o.y} ${$} ${n.x} ${o.y-g} L ${n.x} ${n.y}`),o.x===n.x&&(b=`M ${o.x} ${o.y} L ${n.x} ${n.y}`)):(o.y<n.y&&(e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${n.x-p} ${o.y} ${y} ${n.x} ${o.y+g} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${o.x} ${n.y-p} ${$} ${o.x+g} ${n.y} L ${n.x} ${n.y}`),o.y>n.y&&(e.type===u.MERGE&&r.id!==e.parents[0]?b=`M ${o.x} ${o.y} L ${n.x-p} ${o.y} ${$} ${n.x} ${o.y-g} L ${n.x} ${n.y}`:b=`M ${o.x} ${o.y} L ${o.x} ${n.y+p} ${y} ${o.x+g} ${n.y} L ${n.x} ${n.y}`),o.y===n.y&&(b=`M ${o.x} ${o.y} L ${n.x} ${n.y}`));if(b===void 0)throw new Error("Line definition not found");t.append("path").attr("d",b).attr("class","arrow arrow"+T%G)},"drawArrow"),rt=m((t,r)=>{const e=t.append("g").attr("class","commit-arrows");[...r.keys()].forEach(c=>{const a=r.get(c);a.parents&&a.parents.length>0&&a.parents.forEach(s=>{Zr(e,r.get(s),a,r)})})},"drawArrows"),tt=m((t,r)=>{const e=t.append("g");r.forEach((c,a)=>{var s;const d=a%G,h=(s=v.get(c.name))==null?void 0:s.pos;if(h===void 0)throw new Error(`Position not found for branch ${c.name}`);const l=e.append("line");l.attr("x1",0),l.attr("y1",h),l.attr("x2",R),l.attr("y2",h),l.attr("class","branch branch"+d),x==="TB"?(l.attr("y1",z),l.attr("x1",h),l.attr("y2",R),l.attr("x2",h)):x==="BT"&&(l.attr("y1",R),l.attr("x1",h),l.attr("y2",z),l.attr("x2",h)),S.push(h);const o=c.name,n=V(o),f=e.insert("rect"),$=e.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+d);$.node().appendChild(n);const y=n.getBBox();f.attr("class","branchLabelBkg label"+d).attr("rx",4).attr("ry",4).attr("x",-y.width-4-((E==null?void 0:E.rotateCommitLabel)===!0?30:0)).attr("y",-y.height/2+8).attr("width",y.width+18).attr("height",y.height+4),$.attr("transform","translate("+(-y.width-14-((E==null?void 0:E.rotateCommitLabel)===!0?30:0))+", "+(h-y.height/2-1)+")"),x==="TB"?(f.attr("x",h-y.width/2-10).attr("y",0),$.attr("transform","translate("+(h-y.width/2-5)+", 0)")):x==="BT"?(f.attr("x",h-y.width/2-10).attr("y",R),$.attr("transform","translate("+(h-y.width/2-5)+", "+R+")")):f.attr("transform","translate(-19, "+(h-y.height/2)+")")})},"drawBranches"),et=m(function(t,r,e,c,a){return v.set(t,{pos:r,index:e}),r+=50+(a?40:0)+(x==="TB"||x==="BT"?c.width/2:0),r},"setBranchPosition"),ot=m(function(t,r,e,c){if(Sr(),w.debug("in gitgraph renderer",t+`
|
|
14
|
+
`,"id:",r,e),!E)throw new Error("GitGraph config not found");const a=E.rotateCommitLabel??!1,s=c.db;q=s.getCommits();const d=s.getBranchesAsObjArray();x=s.getDirection();const h=ar(`[id="${r}"]`);let l=0;d.forEach((o,n)=>{var f;const $=V(o.name),y=h.append("g"),p=y.insert("g").attr("class","branchLabel"),g=p.insert("g").attr("class","label branch-label");(f=g.node())==null||f.appendChild($);const T=$.getBBox();l=et(o.name,l,n,T,a),g.remove(),p.remove(),y.remove()}),K(h,q,!1),E.showBranches&&tt(h,d),rt(h,q),K(h,q,!0),sr.insertTitle(h,"gitTitleText",E.titleTopMargin??0,s.getDiagramTitle()),ir(void 0,h,E.diagramPadding,E.useMaxWidth)},"draw"),nt={draw:ot},ct=m(t=>`
|
|
15
15
|
.commit-id,
|
|
16
16
|
.commit-msg,
|
|
17
17
|
.branch-label {
|
|
@@ -62,4 +62,4 @@ import{m as X}from"./chunk-4BX2VUAB-BI1eieHX-BcH4s9g3.js";import{e as Q}from"./c
|
|
|
62
62
|
font-size: 18px;
|
|
63
63
|
fill: ${t.textColor};
|
|
64
64
|
}
|
|
65
|
-
`,"getStyles"),ct
|
|
65
|
+
`,"getStyles"),at=ct,lt={parser:zr,db:Q,renderer:nt,styles:at};export{lt as diagram};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{aP as v,bm as
|
|
1
|
+
import{aP as v,bm as F,aE as V,aQ as W,bn as ee,bo as E,bp as te,bq as re,br as se,bs as ne,aN as Y,aS as ie,aL as oe,bt as y,aG as A,bu as ae,bv as $,bw as m,bx as k,by as ue,bz as M,bA as he,bB as x}from"./index-CS9omSqb.js";import{M as c,Z as j,q as _,Y as ce,J as de,B as le,v as _e,d as be,E as pe,K as fe,e as z,r as ge,f as ve}from"./_baseUniq-BPMphbq5-Ci3F4c-i.js";function je(t,e){return t&&y(e,c(e),t)}function me(t,e){return t&&y(e,A(e),t)}function ye(t,e){return y(t,z(t),e)}var we=Object.getOwnPropertySymbols,J=we?function(t){for(var e=[];t;)ge(e,z(t)),t=ue(t);return e}:fe;function Ce(t,e){return y(t,J(t),e)}function Oe(t){return ve(t,A,J)}var Ee=Object.prototype,Ae=Ee.hasOwnProperty;function Ne(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&Ae.call(t,"index")&&(r.index=t.index,r.input=t.input),r}function Le(t,e){var r=e?$(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}var Pe=/\w*$/;function De(t){var e=new t.constructor(t.source,Pe.exec(t));return e.lastIndex=t.lastIndex,e}var S=M?M.prototype:void 0,B=S?S.valueOf:void 0;function Fe(t){return B?Object(B.call(t)):{}}var Me="[object Boolean]",xe="[object Date]",Se="[object Map]",Be="[object Number]",Ie="[object RegExp]",Ue="[object Set]",Ge="[object String]",Ze="[object Symbol]",qe="[object ArrayBuffer]",Ye="[object DataView]",$e="[object Float32Array]",ke="[object Float64Array]",ze="[object Int8Array]",Je="[object Int16Array]",Te="[object Int32Array]",Xe="[object Uint8Array]",He="[object Uint8ClampedArray]",Ke="[object Uint16Array]",Qe="[object Uint32Array]";function Re(t,e,r){var s=t.constructor;switch(e){case qe:return $(t);case Me:case xe:return new s(+t);case Ye:return Le(t,r);case $e:case ke:case ze:case Je:case Te:case Xe:case He:case Ke:case Qe:return ae(t,r);case Se:return new s;case Be:case Ge:return new s(t);case Ie:return De(t);case Ue:return new s;case Ze:return Fe(t)}}var Ve="[object Map]";function We(t){return k(t)&&E(t)==Ve}var I=m&&m.isMap,et=I?Y(I):We,tt="[object Set]";function rt(t){return k(t)&&E(t)==tt}var U=m&&m.isSet,st=U?Y(U):rt,nt=1,it=2,ot=4,T="[object Arguments]",at="[object Array]",ut="[object Boolean]",ht="[object Date]",ct="[object Error]",X="[object Function]",dt="[object GeneratorFunction]",lt="[object Map]",_t="[object Number]",H="[object Object]",bt="[object RegExp]",pt="[object Set]",ft="[object String]",gt="[object Symbol]",vt="[object WeakMap]",jt="[object ArrayBuffer]",mt="[object DataView]",yt="[object Float32Array]",wt="[object Float64Array]",Ct="[object Int8Array]",Ot="[object Int16Array]",Et="[object Int32Array]",At="[object Uint8Array]",Nt="[object Uint8ClampedArray]",Lt="[object Uint16Array]",Pt="[object Uint32Array]",a={};a[T]=a[at]=a[jt]=a[mt]=a[ut]=a[ht]=a[yt]=a[wt]=a[Ct]=a[Ot]=a[Et]=a[lt]=a[_t]=a[H]=a[bt]=a[pt]=a[ft]=a[gt]=a[At]=a[Nt]=a[Lt]=a[Pt]=!0;a[ct]=a[X]=a[vt]=!1;function w(t,e,r,s,n,o){var i,u=e&nt,h=e&it,Q=e&ot;if(i!==void 0)return i;if(!W(t))return t;var N=oe(t);if(N){if(i=Ne(t),!u)return ee(t,i)}else{var p=E(t),L=p==X||p==dt;if(te(t))return re(t,u);if(p==H||p==T||L&&!n){if(i=h||L?{}:se(t),!u)return h?Ce(t,me(i,t)):ye(t,je(i,t))}else{if(!a[p])return n?t:{};i=Re(t,p,u)}}o||(o=new ne);var P=o.get(t);if(P)return P;o.set(t,i),st(t)?t.forEach(function(d){i.add(w(d,e,r,d,t,o))}):et(t)&&t.forEach(function(d,l){i.set(l,w(d,e,r,l,t,o))});var R=Q?h?Oe:be:h?A:c,D=N?void 0:R(t);return pe(D||t,function(d,l){D&&(l=d,d=t[l]),ie(i,l,w(d,e,r,l,t,o))}),i}function Dt(t,e){return _e(e,function(r){return t[r]})}function C(t){return t==null?[]:Dt(t,c(t))}function f(t){return t===void 0}var Ft=V(function(t){return de(le(t,1,he,!0))}),Mt="\0",b="\0",G="";class K{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=v(void 0),this._defaultEdgeLabelFn=v(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[b]={}),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 F(e)||(e=v(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return c(this._nodes)}sources(){var e=this;return j(this.nodes(),function(r){return x(e._in[r])})}sinks(){var e=this;return j(this.nodes(),function(r){return x(e._out[r])})}setNodes(e,r){var s=arguments,n=this;return _(e,function(o){s.length>1?n.setNode(o,r):n.setNode(o)}),this}setNode(e,r){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=r),this):(this._nodes[e]=arguments.length>1?r:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=b,this._children[e]={},this._children[b][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 r=s=>this.removeEdge(this._edgeObjs[s]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],_(this.children(e),s=>{this.setParent(s)}),delete this._children[e]),_(c(this._in[e]),r),delete this._in[e],delete this._preds[e],_(c(this._out[e]),r),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,r){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(f(r))r=b;else{r+="";for(var s=r;!f(s);s=this.parent(s))if(s===e)throw new Error("Setting "+r+" as parent of "+e+" would create a cycle");this.setNode(r)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=r,this._children[r][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var r=this._parent[e];if(r!==b)return r}}children(e){if(f(e)&&(e=b),this._isCompound){var r=this._children[e];if(r)return c(r)}else{if(e===b)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var r=this._preds[e];if(r)return c(r)}successors(e){var r=this._sucs[e];if(r)return c(r)}neighbors(e){var r=this.predecessors(e);if(r)return Ft(r,this.successors(e))}isLeaf(e){var r;return this.isDirected()?r=this.successors(e):r=this.neighbors(e),r.length===0}filterNodes(e){var r=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});r.setGraph(this.graph());var s=this;_(this._nodes,function(i,u){e(u)&&r.setNode(u,i)}),_(this._edgeObjs,function(i){r.hasNode(i.v)&&r.hasNode(i.w)&&r.setEdge(i,s.edge(i))});var n={};function o(i){var u=s.parent(i);return u===void 0||r.hasNode(u)?(n[i]=u,u):u in n?n[u]:o(u)}return this._isCompound&&_(r.nodes(),function(i){r.setParent(i,o(i))}),r}setDefaultEdgeLabel(e){return F(e)||(e=v(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return C(this._edgeObjs)}setPath(e,r){var s=this,n=arguments;return ce(e,function(o,i){return n.length>1?s.setEdge(o,i,r):s.setEdge(o,i),i}),this}setEdge(){var e,r,s,n,o=!1,i=arguments[0];typeof i=="object"&&i!==null&&"v"in i?(e=i.v,r=i.w,s=i.name,arguments.length===2&&(n=arguments[1],o=!0)):(e=i,r=arguments[1],s=arguments[3],arguments.length>2&&(n=arguments[2],o=!0)),e=""+e,r=""+r,f(s)||(s=""+s);var u=g(this._isDirected,e,r,s);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,u))return o&&(this._edgeLabels[u]=n),this;if(!f(s)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(r),this._edgeLabels[u]=o?n:this._defaultEdgeLabelFn(e,r,s);var h=xt(this._isDirected,e,r,s);return e=h.v,r=h.w,Object.freeze(h),this._edgeObjs[u]=h,Z(this._preds[r],e),Z(this._sucs[e],r),this._in[r][u]=h,this._out[e][u]=h,this._edgeCount++,this}edge(e,r,s){var n=arguments.length===1?O(this._isDirected,arguments[0]):g(this._isDirected,e,r,s);return this._edgeLabels[n]}hasEdge(e,r,s){var n=arguments.length===1?O(this._isDirected,arguments[0]):g(this._isDirected,e,r,s);return Object.prototype.hasOwnProperty.call(this._edgeLabels,n)}removeEdge(e,r,s){var n=arguments.length===1?O(this._isDirected,arguments[0]):g(this._isDirected,e,r,s),o=this._edgeObjs[n];return o&&(e=o.v,r=o.w,delete this._edgeLabels[n],delete this._edgeObjs[n],q(this._preds[r],e),q(this._sucs[e],r),delete this._in[r][n],delete this._out[e][n],this._edgeCount--),this}inEdges(e,r){var s=this._in[e];if(s){var n=C(s);return r?j(n,function(o){return o.v===r}):n}}outEdges(e,r){var s=this._out[e];if(s){var n=C(s);return r?j(n,function(o){return o.w===r}):n}}nodeEdges(e,r){var s=this.inEdges(e,r);if(s)return s.concat(this.outEdges(e,r))}}K.prototype._nodeCount=0;K.prototype._edgeCount=0;function Z(t,e){t[e]?t[e]++:t[e]=1}function q(t,e){--t[e]||delete t[e]}function g(t,e,r,s){var n=""+e,o=""+r;if(!t&&n>o){var i=n;n=o,o=i}return n+G+o+G+(f(s)?Mt:s)}function xt(t,e,r,s){var n=""+e,o=""+r;if(!t&&n>o){var i=n;n=o,o=i}var u={v:n,w:o};return s&&(u.name=s),u}function O(t,e){return g(t,e.v,e.w,e.name)}export{C as A,w as O,K as Q,f as _};
|