@1agents/dsh-a2a 0.0.0-stage → 0.1.0

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.
Files changed (144) hide show
  1. package/README.md +57 -2
  2. package/cordis.patch.yml +10 -0
  3. package/dist/approvals.js +49 -0
  4. package/dist/cli.js +15 -0
  5. package/dist/executor.js +121 -0
  6. package/dist/index.js +18 -0
  7. package/dist/sdk-runtime.js +116 -0
  8. package/dist/server.js +46 -0
  9. package/dist/shared/a2a/workbench-ui.js +182 -0
  10. package/dist/workbench-ui/app.css +453 -0
  11. package/dist/workbench-ui/app.js +13 -0
  12. package/dist/workbench-ui/chunk-23JHGYT3.js +1 -0
  13. package/dist/workbench-ui/chunk-3H6STGPV.js +1 -0
  14. package/dist/workbench-ui/chunk-3SNBBMGH.js +1 -0
  15. package/dist/workbench-ui/chunk-3XJZ6DIE.js +1 -0
  16. package/dist/workbench-ui/chunk-44KDLLKJ.js +1 -0
  17. package/dist/workbench-ui/chunk-46H7FU5Y.js +7 -0
  18. package/dist/workbench-ui/chunk-4N44QPL7.js +1 -0
  19. package/dist/workbench-ui/chunk-4YN4BS7I.js +1 -0
  20. package/dist/workbench-ui/chunk-53EG4IVQ.js +96 -0
  21. package/dist/workbench-ui/chunk-5FIPUNR4.js +1 -0
  22. package/dist/workbench-ui/chunk-6DWWYA6G.js +2 -0
  23. package/dist/workbench-ui/chunk-6FU3T633.js +99 -0
  24. package/dist/workbench-ui/chunk-6XKIHRA4.js +1 -0
  25. package/dist/workbench-ui/chunk-7GIX43Y5.js +1 -0
  26. package/dist/workbench-ui/chunk-7Q4WBGX6.js +4 -0
  27. package/dist/workbench-ui/chunk-A3BQM7HR.js +1 -0
  28. package/dist/workbench-ui/chunk-AFCFDDOP.js +24 -0
  29. package/dist/workbench-ui/chunk-AG67EUYD.js +89 -0
  30. package/dist/workbench-ui/chunk-AGJHMMTN.js +1 -0
  31. package/dist/workbench-ui/chunk-AO6JUBV6.js +41 -0
  32. package/dist/workbench-ui/chunk-AUSLTP43.js +72 -0
  33. package/dist/workbench-ui/chunk-AVZL46TT.js +1 -0
  34. package/dist/workbench-ui/chunk-AZRIGIV2.js +168 -0
  35. package/dist/workbench-ui/chunk-B2LIVH37.js +1 -0
  36. package/dist/workbench-ui/chunk-B7YX5TR5.js +1 -0
  37. package/dist/workbench-ui/chunk-BCB4X4XX.js +1 -0
  38. package/dist/workbench-ui/chunk-BCRQUL2A.js +88 -0
  39. package/dist/workbench-ui/chunk-BI6UHHQP.js +1 -0
  40. package/dist/workbench-ui/chunk-BLSLQ4AQ.js +120 -0
  41. package/dist/workbench-ui/chunk-C3QSRS6E.js +1 -0
  42. package/dist/workbench-ui/chunk-CK7M2PJ3.js +62 -0
  43. package/dist/workbench-ui/chunk-CM6LZ7TU.js +1 -0
  44. package/dist/workbench-ui/chunk-CP63H27F.js +36 -0
  45. package/dist/workbench-ui/chunk-CPUMMIS2.js +70 -0
  46. package/dist/workbench-ui/chunk-CSEIBI5U.js +2 -0
  47. package/dist/workbench-ui/chunk-CUS65DKZ.js +161 -0
  48. package/dist/workbench-ui/chunk-CVQY7TNC.js +1 -0
  49. package/dist/workbench-ui/chunk-D6S3XBIX.js +106 -0
  50. package/dist/workbench-ui/chunk-E253Y562.js +1 -0
  51. package/dist/workbench-ui/chunk-EADDJUDC.js +1 -0
  52. package/dist/workbench-ui/chunk-EBGJ3YXG.js +206 -0
  53. package/dist/workbench-ui/chunk-EKPVZ3WY.js +8 -0
  54. package/dist/workbench-ui/chunk-EQDCEAFY.js +1 -0
  55. package/dist/workbench-ui/chunk-ES3SSDJY.js +40 -0
  56. package/dist/workbench-ui/chunk-ESFD2H7N.js +231 -0
  57. package/dist/workbench-ui/chunk-FVOHPMS6.js +1 -0
  58. package/dist/workbench-ui/chunk-FXMQAGVT.js +1 -0
  59. package/dist/workbench-ui/chunk-GGTADRXD.js +24 -0
  60. package/dist/workbench-ui/chunk-GHIVPGNQ.js +1 -0
  61. package/dist/workbench-ui/chunk-GLU2YQV2.js +1 -0
  62. package/dist/workbench-ui/chunk-GOCKBYSM.js +1 -0
  63. package/dist/workbench-ui/chunk-H2KMMTJB.js +1 -0
  64. package/dist/workbench-ui/chunk-HGVLDNPP.js +39 -0
  65. package/dist/workbench-ui/chunk-HSAVC5GY.js +1 -0
  66. package/dist/workbench-ui/chunk-HSEAD2JH.js +1 -0
  67. package/dist/workbench-ui/chunk-HSIHOBTY.js +1 -0
  68. package/dist/workbench-ui/chunk-IZXOKUGG.js +67 -0
  69. package/dist/workbench-ui/chunk-JFT2LC2T.js +1 -0
  70. package/dist/workbench-ui/chunk-JHL3ZDYK.js +3 -0
  71. package/dist/workbench-ui/chunk-JMORLCZG.js +257 -0
  72. package/dist/workbench-ui/chunk-JR4SIX7A.js +1 -0
  73. package/dist/workbench-ui/chunk-K23HAGEH.js +30 -0
  74. package/dist/workbench-ui/chunk-K43JDCBH.js +1 -0
  75. package/dist/workbench-ui/chunk-KINKFJY7.js +1 -0
  76. package/dist/workbench-ui/chunk-KKQSA4LI.js +2 -0
  77. package/dist/workbench-ui/chunk-KOUZX3UX.js +1 -0
  78. package/dist/workbench-ui/chunk-KR4DRHW2.js +78 -0
  79. package/dist/workbench-ui/chunk-KT4DJNOR.js +1 -0
  80. package/dist/workbench-ui/chunk-KTPNKRRZ.js +292 -0
  81. package/dist/workbench-ui/chunk-LFHIPGSU.js +7 -0
  82. package/dist/workbench-ui/chunk-LWDL4HZB.js +125 -0
  83. package/dist/workbench-ui/chunk-MVYC3CY4.js +1 -0
  84. package/dist/workbench-ui/chunk-NWUPALCY.js +129 -0
  85. package/dist/workbench-ui/chunk-NY7C662Z.js +1 -0
  86. package/dist/workbench-ui/chunk-O76WTHWP.js +1 -0
  87. package/dist/workbench-ui/chunk-OTF7YHRE.js +162 -0
  88. package/dist/workbench-ui/chunk-P6TKKRKP.js +1 -0
  89. package/dist/workbench-ui/chunk-PFHOOWV3.js +1 -0
  90. package/dist/workbench-ui/chunk-PUQLANIM.js +1 -0
  91. package/dist/workbench-ui/chunk-PZCGBYVO.js +1 -0
  92. package/dist/workbench-ui/chunk-QOHUZGP4.js +1 -0
  93. package/dist/workbench-ui/chunk-QSEG3OFF.js +1 -0
  94. package/dist/workbench-ui/chunk-QYPOXZIA.js +84 -0
  95. package/dist/workbench-ui/chunk-R6SOF3JC.js +1 -0
  96. package/dist/workbench-ui/chunk-RCLOYU5F.js +1 -0
  97. package/dist/workbench-ui/chunk-RSRUP64S.js +1 -0
  98. package/dist/workbench-ui/chunk-RVAIT6JW.js +1 -0
  99. package/dist/workbench-ui/chunk-S2CCN3II.js +1 -0
  100. package/dist/workbench-ui/chunk-S2Q52W46.js +1 -0
  101. package/dist/workbench-ui/chunk-S2W5THJ5.js +1 -0
  102. package/dist/workbench-ui/chunk-S6ZQZNOX.js +1 -0
  103. package/dist/workbench-ui/chunk-S74PLMMS.js +1 -0
  104. package/dist/workbench-ui/chunk-S7C4HKEY.js +1 -0
  105. package/dist/workbench-ui/chunk-SDTB3Q65.js +1 -0
  106. package/dist/workbench-ui/chunk-SLPRGYUV.js +32 -0
  107. package/dist/workbench-ui/chunk-SQE76S5B.js +1 -0
  108. package/dist/workbench-ui/chunk-SSDZPVPW.js +1 -0
  109. package/dist/workbench-ui/chunk-SVI7DGIE.js +1 -0
  110. package/dist/workbench-ui/chunk-T6QKLZ4H.js +62 -0
  111. package/dist/workbench-ui/chunk-TJNRPTFL.js +1 -0
  112. package/dist/workbench-ui/chunk-TP6U4EDH.js +2 -0
  113. package/dist/workbench-ui/chunk-TYAAT3GQ.js +1 -0
  114. package/dist/workbench-ui/chunk-U6OCY4ZH.js +1 -0
  115. package/dist/workbench-ui/chunk-UAN3NLRF.js +1 -0
  116. package/dist/workbench-ui/chunk-UMLU3FIX.js +1 -0
  117. package/dist/workbench-ui/chunk-URIY2OTM.js +1 -0
  118. package/dist/workbench-ui/chunk-V2NUKAA7.js +38 -0
  119. package/dist/workbench-ui/chunk-V4QLL4TE.js +139 -0
  120. package/dist/workbench-ui/chunk-VASHXUK4.js +2 -0
  121. package/dist/workbench-ui/chunk-VJLIWNIU.js +1 -0
  122. package/dist/workbench-ui/chunk-VQNQFBID.js +1 -0
  123. package/dist/workbench-ui/chunk-VSIWU7XA.js +3 -0
  124. package/dist/workbench-ui/chunk-VSJASPUZ.js +321 -0
  125. package/dist/workbench-ui/chunk-VXPNUNUX.js +3 -0
  126. package/dist/workbench-ui/chunk-WBKLDCV6.js +1 -0
  127. package/dist/workbench-ui/chunk-WOKJM3FY.js +1 -0
  128. package/dist/workbench-ui/chunk-X3U3NA3X.js +34 -0
  129. package/dist/workbench-ui/chunk-XBYU7M4J.js +1 -0
  130. package/dist/workbench-ui/chunk-XBZAO4ID.js +10 -0
  131. package/dist/workbench-ui/chunk-XLLPZ2WO.js +1 -0
  132. package/dist/workbench-ui/chunk-YFVL4NJL.js +1 -0
  133. package/dist/workbench-ui/chunk-YRFQENM4.js +1 -0
  134. package/dist/workbench-ui/chunk-YUADQVB2.js +1 -0
  135. package/dist/workbench-ui/chunk-Z3TCAKM5.js +1 -0
  136. package/dist/workbench-ui/chunk-Z6QR6FRE.js +10 -0
  137. package/dist/workbench-ui/chunk-ZJPSORPP.js +3 -0
  138. package/dist/workbench-ui/chunk-ZLGCSTR2.js +15 -0
  139. package/dist/workbench-ui/chunk-ZLR4SG5X.js +1 -0
  140. package/dist/workbench-ui/chunk-ZND3TTGF.js +1 -0
  141. package/dist/workbench-ui/chunk-ZOP3ZYH7.js +2 -0
  142. package/dist/workbench-ui/index.html +14 -0
  143. package/dist/workbench.js +53 -0
  144. package/package.json +25 -4
@@ -0,0 +1,292 @@
1
+ import{p as Ye}from"./chunk-6DWWYA6G.js";import{a as Je}from"./chunk-VJLIWNIU.js";import{M as ce,N as le,S as ue,T as de,U as fe,V as he,W as me,X as ke,Y as ye,Z as ot}from"./chunk-LWDL4HZB.js";import"./chunk-VXPNUNUX.js";import{A as Ee,B as Ft,C as Ot,D as Ie,a as oe,b as rt,d as ge,e as pe,f as ve,g as Te,h as vt,i as be,o as xe,p as It,q as Yt,r as $t,s as Lt,t as At,u as we,v as _e,w as De,x as Se,y as Ce,z as Me}from"./chunk-JR4SIX7A.js";import{a as l}from"./chunk-5FIPUNR4.js";import{a as wt,b as at}from"./chunk-SQE76S5B.js";var $e=wt((Wt,Vt)=>{(function(t,e){typeof Wt=="object"&&typeof Vt<"u"?Vt.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_isoWeek=e()})(Wt,(function(){"use strict";var t="day";return function(e,n,s){var r=function(w){return w.add(4-w.isoWeekday(),t)},f=n.prototype;f.isoWeekYear=function(){return r(this).year()},f.isoWeek=function(w){if(!this.$utils().u(w))return this.add(7*(w-this.isoWeek()),t);var S,N,Y,z,R=r(this),H=(S=this.isoWeekYear(),N=this.$u,Y=(N?s.utc:s)().year(S).startOf("year"),z=4-Y.isoWeekday(),Y.isoWeekday()>4&&(z+=7),Y.add(z,t));return R.diff(H,"week")+1},f.isoWeekday=function(w){return this.$utils().u(w)?this.day()||7:this.day(this.day()%7?w:w-7)};var y=f.startOf;f.startOf=function(w,S){var N=this.$utils(),Y=!!N.u(S)||S;return N.p(w)==="isoweek"?Y?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):y.bind(this)(w,S)}}}))});var Le=wt((Pt,Nt)=>{(function(t,e){typeof Pt=="object"&&typeof Nt<"u"?Nt.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_customParseFormat=e()})(Pt,(function(){"use strict";var t={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"},e=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n=/\d/,s=/\d\d/,r=/\d\d?/,f=/\d*[^-_:/,()\s\d]+/,y={},w=function(x){return(x=+x)+(x>68?1900:2e3)},S=function(x){return function(_){this[x]=+_}},N=[/[+-]\d\d:?(\d\d)?|Z/,function(x){(this.zone||(this.zone={})).offset=(function(_){if(!_||_==="Z")return 0;var b=_.match(/([+-]|\d\d)/g),A=60*b[1]+(+b[2]||0);return A===0?0:b[0]==="+"?-A:A})(x)}],Y=function(x){var _=y[x];return _&&(_.indexOf?_:_.s.concat(_.f))},z=function(x,_){var b,A=y.meridiem;if(A){for(var X=1;X<=24;X+=1)if(x.indexOf(A(X,0,_))>-1){b=X>12;break}}else b=x===(_?"pm":"PM");return b},R={A:[f,function(x){this.afternoon=z(x,!1)}],a:[f,function(x){this.afternoon=z(x,!0)}],Q:[n,function(x){this.month=3*(x-1)+1}],S:[n,function(x){this.milliseconds=100*+x}],SS:[s,function(x){this.milliseconds=10*+x}],SSS:[/\d{3}/,function(x){this.milliseconds=+x}],s:[r,S("seconds")],ss:[r,S("seconds")],m:[r,S("minutes")],mm:[r,S("minutes")],H:[r,S("hours")],h:[r,S("hours")],HH:[r,S("hours")],hh:[r,S("hours")],D:[r,S("day")],DD:[s,S("day")],Do:[f,function(x){var _=y.ordinal,b=x.match(/\d+/);if(this.day=b[0],_)for(var A=1;A<=31;A+=1)_(A).replace(/\[|\]/g,"")===x&&(this.day=A)}],w:[r,S("week")],ww:[s,S("week")],M:[r,S("month")],MM:[s,S("month")],MMM:[f,function(x){var _=Y("months"),b=(Y("monthsShort")||_.map((function(A){return A.slice(0,3)}))).indexOf(x)+1;if(b<1)throw new Error;this.month=b%12||b}],MMMM:[f,function(x){var _=Y("months").indexOf(x)+1;if(_<1)throw new Error;this.month=_%12||_}],Y:[/[+-]?\d+/,S("year")],YY:[s,function(x){this.year=w(x)}],YYYY:[/\d{4}/,S("year")],Z:N,ZZ:N};function H(x){var _,b;_=x,b=y&&y.formats;for(var A=(x=_.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(W,F,k){var p=k&&k.toUpperCase();return F||b[k]||t[k]||b[p].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(v,T,a){return T||a.slice(1)}))}))).match(e),X=A.length,U=0;U<X;U+=1){var $=A[U],g=R[$],m=g&&g[0],I=g&&g[1];A[U]=I?{regex:m,parser:I}:$.replace(/^\[|\]$/g,"")}return function(W){for(var F={},k=0,p=0;k<X;k+=1){var v=A[k];if(typeof v=="string")p+=v.length;else{var T=v.regex,a=v.parser,h=W.slice(p),d=T.exec(h)[0];a.call(F,d),W=W.replace(d,"")}}return(function(u){var C=u.afternoon;if(C!==void 0){var i=u.hours;C?i<12&&(u.hours+=12):i===12&&(u.hours=0),delete u.afternoon}})(F),F}}return function(x,_,b){b.p.customParseFormat=!0,x&&x.parseTwoDigitYear&&(w=x.parseTwoDigitYear);var A=_.prototype,X=A.parse;A.parse=function(U){var $=U.date,g=U.utc,m=U.args;this.$u=g;var I=m[1];if(typeof I=="string"){var W=m[2]===!0,F=m[3]===!0,k=W||F,p=m[2];F&&(p=m[2]),y=this.$locale(),!W&&p&&(y=b.Ls[p]),this.$d=(function(h,d,u,C){try{if(["x","X"].indexOf(d)>-1)return new Date((d==="X"?1e3:1)*h);var i=H(d)(h),M=i.year,c=i.month,B=i.day,o=i.hours,D=i.minutes,E=i.seconds,V=i.milliseconds,P=i.zone,L=i.week,O=new Date,tt=B||(M||c?1:O.getDate()),et=M||O.getFullYear(),lt=0;M&&!c||(lt=c>0?c-1:O.getMonth());var ut,dt=o||0,j=D||0,nt=E||0,K=V||0;return P?new Date(Date.UTC(et,lt,tt,dt,j,nt,K+60*P.offset*1e3)):u?new Date(Date.UTC(et,lt,tt,dt,j,nt,K)):(ut=new Date(et,lt,tt,dt,j,nt,K),L&&(ut=C(ut).week(L).toDate()),ut)}catch{return new Date("")}})($,I,g,b),this.init(),p&&p!==!0&&(this.$L=this.locale(p).$L),k&&$!=this.format(I)&&(this.$d=new Date("")),y={}}else if(I instanceof Array)for(var v=I.length,T=1;T<=v;T+=1){m[1]=I[T-1];var a=b.apply(this,m);if(a.isValid()){this.$d=a.$d,this.$L=a.$L,this.init();break}T===v&&(this.$d=new Date(""))}else X.call(this,U)}}}))});var Ae=wt((Rt,zt)=>{(function(t,e){typeof Rt=="object"&&typeof zt<"u"?zt.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_advancedFormat=e()})(Rt,(function(){"use strict";return function(t,e){var n=e.prototype,s=n.format;n.format=function(r){var f=this,y=this.$locale();if(!this.isValid())return s.bind(this)(r);var w=this.$utils(),S=(r||"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(N){switch(N){case"Q":return Math.ceil((f.$M+1)/3);case"Do":return y.ordinal(f.$D);case"gggg":return f.weekYear();case"GGGG":return f.isoWeekYear();case"wo":return y.ordinal(f.week(),"W");case"w":case"ww":return w.s(f.week(),N==="w"?1:2,"0");case"W":case"WW":return w.s(f.isoWeek(),N==="W"?1:2,"0");case"k":case"kk":return w.s(String(f.$H===0?24:f.$H),N==="k"?1:2,"0");case"X":return Math.floor(f.$d.getTime()/1e3);case"x":return f.$d.getTime();case"z":return"["+f.offsetName()+"]";case"zzz":return"["+f.offsetName("long")+"]";default:return N}}));return s.bind(this)(S)}}}))});var Fe=wt((Ht,Bt)=>{(function(t,e){typeof Ht=="object"&&typeof Bt<"u"?Bt.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs_plugin_duration=e()})(Ht,(function(){"use strict";var t,e,n=1e3,s=6e4,r=36e5,f=864e5,y=31536e6,w=2628e6,S=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,N=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,Y={years:y,months:w,days:f,hours:r,minutes:s,seconds:n,milliseconds:1,weeks:6048e5},z=function($){return $ instanceof X},R=function($,g,m){return new X($,m,g.$l)},H=function($){return e.p($)+"s"},x=function($){return $<0},_=function($){return x($)?Math.ceil($):Math.floor($)},b=function($){return Math.abs($)},A=function($,g){return $?x($)?{negative:!0,format:""+b($)+g}:{negative:!1,format:""+$+g}:{negative:!1,format:""}},X=(function(){function $(m,I,W){var F=this;if(this.$d={},this.$l=W,m===void 0&&(this.$ms=0,this.parseFromMilliseconds()),I)return R(m*Y[H(I)],this);if(typeof m=="number")return this.$ms=m,this.parseFromMilliseconds(),this;if(typeof m=="object")return Object.keys(m).forEach((function(v){F.$d[H(v)]=m[v]})),this.calMilliseconds(),this;if(typeof m=="string"){var k=m.match(S);if(k){var p=k.slice(2).map((function(v){return v!=null?Number(v):0}));return this.$d.years=p[0],this.$d.months=p[1],this.$d.weeks=p[2],this.$d.days=p[3],this.$d.hours=p[4],this.$d.minutes=p[5],this.$d.seconds=p[6],this.calMilliseconds(),this}}return this}var g=$.prototype;return g.calMilliseconds=function(){var m=this;this.$ms=Object.keys(this.$d).reduce((function(I,W){return I+(m.$d[W]||0)*Y[W]}),0)},g.parseFromMilliseconds=function(){var m=this.$ms;this.$d.years=_(m/y),m%=y,this.$d.months=_(m/w),m%=w,this.$d.days=_(m/f),m%=f,this.$d.hours=_(m/r),m%=r,this.$d.minutes=_(m/s),m%=s,this.$d.seconds=_(m/n),m%=n,this.$d.milliseconds=m},g.toISOString=function(){var m=A(this.$d.years,"Y"),I=A(this.$d.months,"M"),W=+this.$d.days||0;this.$d.weeks&&(W+=7*this.$d.weeks);var F=A(W,"D"),k=A(this.$d.hours,"H"),p=A(this.$d.minutes,"M"),v=this.$d.seconds||0;this.$d.milliseconds&&(v+=this.$d.milliseconds/1e3,v=Math.round(1e3*v)/1e3);var T=A(v,"S"),a=m.negative||I.negative||F.negative||k.negative||p.negative||T.negative,h=k.format||p.format||T.format?"T":"",d=(a?"-":"")+"P"+m.format+I.format+F.format+h+k.format+p.format+T.format;return d==="P"||d==="-P"?"P0D":d},g.toJSON=function(){return this.toISOString()},g.format=function(m){var I=m||"YYYY-MM-DDTHH:mm:ss",W={Y:this.$d.years,YY:e.s(this.$d.years,2,"0"),YYYY:e.s(this.$d.years,4,"0"),M:this.$d.months,MM:e.s(this.$d.months,2,"0"),D:this.$d.days,DD:e.s(this.$d.days,2,"0"),H:this.$d.hours,HH:e.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:e.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:e.s(this.$d.seconds,2,"0"),SSS:e.s(this.$d.milliseconds,3,"0")};return I.replace(N,(function(F,k){return k||String(W[F])}))},g.as=function(m){return this.$ms/Y[H(m)]},g.get=function(m){var I=this.$ms,W=H(m);return W==="milliseconds"?I%=1e3:I=W==="weeks"?_(I/Y[W]):this.$d[W],I||0},g.add=function(m,I,W){var F;return F=I?m*Y[H(I)]:z(m)?m.$ms:R(m,this).$ms,R(this.$ms+F*(W?-1:1),this)},g.subtract=function(m,I){return this.add(m,I,!0)},g.locale=function(m){var I=this.clone();return I.$l=m,I},g.clone=function(){return R(this.$ms,this)},g.humanize=function(m){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!m)},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")},$})(),U=function($,g,m){return $.add(g.years()*m,"y").add(g.months()*m,"M").add(g.days()*m,"d").add(g.hours()*m,"h").add(g.minutes()*m,"m").add(g.seconds()*m,"s").add(g.milliseconds()*m,"ms")};return function($,g,m){t=m,e=m().$utils(),m.duration=function(F,k){var p=m.locale();return R(F,{$l:p},k)},m.isDuration=z;var I=g.prototype.add,W=g.prototype.subtract;g.prototype.add=function(F,k){return z(F)?U(this,F,1):I.bind(this)(F,k)},g.prototype.subtract=function(F,k){return z(F)?U(this,F,-1):W.bind(this)(F,k)}}}))});var Pe=at(Je(),1),Q=at(oe(),1),Ne=at($e(),1),Re=at(Le(),1),ze=at(Ae(),1),mt=at(oe(),1),Ke=at(Fe(),1);var Gt=(function(){var t=l(function(T,a,h,d){for(h=h||{},d=T.length;d--;h[T[d]]=a);return h},"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],s=[1,27],r=[1,28],f=[1,29],y=[1,30],w=[1,31],S=[1,32],N=[1,33],Y=[1,34],z=[1,9],R=[1,10],H=[1,11],x=[1,12],_=[1,13],b=[1,14],A=[1,15],X=[1,16],U=[1,19],$=[1,20],g=[1,21],m=[1,22],I=[1,23],W=[1,25],F=[1,35],k={trace:l(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:l(function(a,h,d,u,C,i,M){var c=i.length-1;switch(C){case 1:return i[c-1];case 2:this.$=[];break;case 3:i[c-1].push(i[c]),this.$=i[c-1];break;case 4:case 5:this.$=i[c];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[c].substr(11)),this.$=i[c].substr(11);break;case 18:u.enableInclusiveEndDates(),this.$=i[c].substr(18);break;case 19:u.TopAxis(),this.$=i[c].substr(8);break;case 20:u.setAxisFormat(i[c].substr(11)),this.$=i[c].substr(11);break;case 21:u.setTickInterval(i[c].substr(13)),this.$=i[c].substr(13);break;case 22:u.setExcludes(i[c].substr(9)),this.$=i[c].substr(9);break;case 23:u.setIncludes(i[c].substr(9)),this.$=i[c].substr(9);break;case 24:u.setTodayMarker(i[c].substr(12)),this.$=i[c].substr(12);break;case 27:u.setDiagramTitle(i[c].substr(6)),this.$=i[c].substr(6);break;case 28:this.$=i[c].trim(),u.setAccTitle(this.$);break;case 29:case 30:this.$=i[c].trim(),u.setAccDescription(this.$);break;case 31:u.addSection(i[c].substr(8)),this.$=i[c].substr(8);break;case 33:u.addTask(i[c-1],i[c]),this.$="task";break;case 34:this.$=i[c-1],u.setClickEvent(i[c-1],i[c],null);break;case 35:this.$=i[c-2],u.setClickEvent(i[c-2],i[c-1],i[c]);break;case 36:this.$=i[c-2],u.setClickEvent(i[c-2],i[c-1],null),u.setLink(i[c-2],i[c]);break;case 37:this.$=i[c-3],u.setClickEvent(i[c-3],i[c-2],i[c-1]),u.setLink(i[c-3],i[c]);break;case 38:this.$=i[c-2],u.setClickEvent(i[c-2],i[c],null),u.setLink(i[c-2],i[c-1]);break;case 39:this.$=i[c-3],u.setClickEvent(i[c-3],i[c-1],i[c]),u.setLink(i[c-3],i[c-2]);break;case 40:this.$=i[c-1],u.setLink(i[c-1],i[c]);break;case 41:case 47:this.$=i[c-1]+" "+i[c];break;case 42:case 43:case 45:this.$=i[c-2]+" "+i[c-1]+" "+i[c];break;case 44:case 46:this.$=i[c-3]+" "+i[c-2]+" "+i[c-1]+" "+i[c];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:s,14:r,15:f,16:y,17:w,18:S,19:18,20:N,21:Y,22:z,23:R,24:H,25:x,26:_,27:b,28:A,29:X,30:U,31:$,33:g,35:m,36:I,37:24,38:W,40:F},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:n,13:s,14:r,15:f,16:y,17:w,18:S,19:18,20:N,21:Y,22:z,23:R,24:H,25:x,26:_,27:b,28:A,29:X,30:U,31:$,33:g,35:m,36:I,37:24,38:W,40:F},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:l(function(a,h){if(h.recoverable)this.trace(a);else{var d=new Error(a);throw d.hash=h,d}},"parseError"),parse:l(function(a){var h=this,d=[0],u=[],C=[null],i=[],M=this.table,c="",B=0,o=0,D=0,E=2,V=1,P=i.slice.call(arguments,1),L=Object.create(this.lexer),O={yy:{}};for(var tt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,tt)&&(O.yy[tt]=this.yy[tt]);L.setInput(a,O.yy),O.yy.lexer=L,O.yy.parser=this,typeof L.yylloc>"u"&&(L.yylloc={});var et=L.yylloc;i.push(et);var lt=L.options&&L.options.ranges;typeof O.yy.parseError=="function"?this.parseError=O.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ut(Z){d.length=d.length-2*Z,C.length=C.length-Z,i.length=i.length-Z}l(ut,"popStack");function dt(){var Z;return Z=u.pop()||L.lex()||V,typeof Z!="number"&&(Z instanceof Array&&(u=Z,Z=u.pop()),Z=h.symbols_[Z]||Z),Z}l(dt,"lex");for(var j,nt,K,q,Bi,Mt,ft={},bt,it,ae,xt;;){if(K=d[d.length-1],this.defaultActions[K]?q=this.defaultActions[K]:((j===null||typeof j>"u")&&(j=dt()),q=M[K]&&M[K][j]),typeof q>"u"||!q.length||!q[0]){var Et="";xt=[];for(bt in M[K])this.terminals_[bt]&&bt>E&&xt.push("'"+this.terminals_[bt]+"'");L.showPosition?Et="Parse error on line "+(B+1)+`:
2
+ `+L.showPosition()+`
3
+ Expecting `+xt.join(", ")+", got '"+(this.terminals_[j]||j)+"'":Et="Parse error on line "+(B+1)+": Unexpected "+(j==V?"end of input":"'"+(this.terminals_[j]||j)+"'"),this.parseError(Et,{text:L.match,token:this.terminals_[j]||j,line:L.yylineno,loc:et,expected:xt})}if(q[0]instanceof Array&&q.length>1)throw new Error("Parse Error: multiple actions possible at state: "+K+", token: "+j);switch(q[0]){case 1:d.push(j),C.push(L.yytext),i.push(L.yylloc),d.push(q[1]),j=null,nt?(j=nt,nt=null):(o=L.yyleng,c=L.yytext,B=L.yylineno,et=L.yylloc,D>0&&D--);break;case 2:if(it=this.productions_[q[1]][1],ft.$=C[C.length-it],ft._$={first_line:i[i.length-(it||1)].first_line,last_line:i[i.length-1].last_line,first_column:i[i.length-(it||1)].first_column,last_column:i[i.length-1].last_column},lt&&(ft._$.range=[i[i.length-(it||1)].range[0],i[i.length-1].range[1]]),Mt=this.performAction.apply(ft,[c,o,B,O.yy,q[1],C,i].concat(P)),typeof Mt<"u")return Mt;it&&(d=d.slice(0,-1*it*2),C=C.slice(0,-1*it),i=i.slice(0,-1*it)),d.push(this.productions_[q[1]][0]),C.push(ft.$),i.push(ft._$),ae=M[d[d.length-2]][d[d.length-1]],d.push(ae);break;case 3:return!0}}return!0},"parse")},p=(function(){var T={EOF:1,parseError:l(function(h,d){if(this.yy.parser)this.yy.parser.parseError(h,d);else throw new Error(h)},"parseError"),setInput:l(function(a,h){return this.yy=h||this.yy||{},this._input=a,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:l(function(){var a=this._input[0];this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a;var h=a.match(/(?:\r\n?|\n).*/g);return h?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},"input"),unput:l(function(a){var h=a.length,d=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-h),this.offset-=h;var u=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),d.length-1&&(this.yylineno-=d.length-1);var C=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:d?(d.length===u.length?this.yylloc.first_column:0)+u[u.length-d.length].length-d[0].length:this.yylloc.first_column-h},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-h]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(a){this.unput(this.match.slice(a))},"less"),pastInput:l(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var a=this.pastInput(),h=new Array(a.length+1).join("-");return a+this.upcomingInput()+`
5
+ `+h+"^"},"showPosition"),test_match:l(function(a,h){var d,u,C;if(this.options.backtrack_lexer&&(C={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&&(C.yylloc.range=this.yylloc.range.slice(0))),u=a[0].match(/(?:\r\n?|\n).*/g),u&&(this.yylineno+=u.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:u?u[u.length-1].length-u[u.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+a[0].length},this.yytext+=a[0],this.match+=a[0],this.matches=a,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(a[0].length),this.matched+=a[0],d=this.performAction.call(this,this.yy,this,h,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),d)return d;if(this._backtrack){for(var i in C)this[i]=C[i];return!1}return!1},"test_match"),next:l(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var a,h,d,u;this._more||(this.yytext="",this.match="");for(var C=this._currentRules(),i=0;i<C.length;i++)if(d=this._input.match(this.rules[C[i]]),d&&(!h||d[0].length>h[0].length)){if(h=d,u=i,this.options.backtrack_lexer){if(a=this.test_match(d,C[i]),a!==!1)return a;if(this._backtrack){h=!1;continue}else return!1}else if(!this.options.flex)break}return h?(a=this.test_match(h,C[u]),a!==!1?a:!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:l(function(){var h=this.next();return h||this.lex()},"lex"),begin:l(function(h){this.conditionStack.push(h)},"begin"),popState:l(function(){var h=this.conditionStack.length-1;return h>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:l(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:l(function(h){return h=this.conditionStack.length-1-Math.abs(h||0),h>=0?this.conditionStack[h]:"INITIAL"},"topState"),pushState:l(function(h){this.begin(h)},"pushState"),stateStackSize:l(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:l(function(h,d,u,C){var i=C;switch(u){case 0:return this.begin("open_directive"),"open_directive";break;case 1:return this.begin("acc_title"),31;break;case 2:return this.popState(),"acc_title_value";break;case 3:return this.begin("acc_descr"),33;break;case 4:return this.popState(),"acc_descr_value";break;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 T})();k.lexer=p;function v(){this.yy={}}return l(v,"Parser"),v.prototype=k,k.Parser=v,new v})();Gt.parser=Gt;var ti=Gt;Q.default.extend(Ne.default);Q.default.extend(Re.default);Q.default.extend(ze.default);var Oe={friday:5,saturday:6},J="",Zt="",Qt=void 0,Kt="",yt=[],gt=[],Jt=new Map,te=[],St=[],pt="",ee="",He=["active","done","crit","milestone","vert"],ie=[],ht="",Tt=!1,se=!1,re="sunday",Ct="saturday",Xt=0,ei=l(function(){te=[],St=[],pt="",ie=[],_t=0,qt=void 0,Dt=void 0,G=[],J="",Zt="",ee="",Qt=void 0,Kt="",yt=[],gt=[],Tt=!1,se=!1,Xt=0,Jt=new Map,ht="",ue(),re="sunday",Ct="saturday"},"clear"),ii=l(function(t){ht=t},"setDiagramId"),si=l(function(t){Zt=t},"setAxisFormat"),ri=l(function(){return Zt},"getAxisFormat"),ni=l(function(t){Qt=t},"setTickInterval"),ai=l(function(){return Qt},"getTickInterval"),oi=l(function(t){Kt=t},"setTodayMarker"),ci=l(function(){return Kt},"getTodayMarker"),li=l(function(t){J=t},"setDateFormat"),ui=l(function(){Tt=!0},"enableInclusiveEndDates"),di=l(function(){return Tt},"endDatesAreInclusive"),fi=l(function(){se=!0},"enableTopAxis"),hi=l(function(){return se},"topAxisEnabled"),mi=l(function(t){ee=t},"setDisplayMode"),ki=l(function(){return ee},"getDisplayMode"),yi=l(function(){return J},"getDateFormat"),Be=l((t,e)=>{let n=e.toLowerCase().split(/[\s,]+/).filter(s=>s!=="");return[...new Set([...t,...n])]},"mergeTokens"),gi=l(function(t){yt=Be(yt,t)},"setIncludes"),pi=l(function(){return yt},"getIncludes"),vi=l(function(t){gt=Be(gt,t)},"setExcludes"),Ti=l(function(){return gt},"getExcludes"),bi=l(function(){return Jt},"getLinks"),xi=l(function(t){pt=t,te.push(t)},"addSection"),wi=l(function(){return te},"getSections"),_i=l(function(){let t=We(),e=10,n=0;for(;!t&&n<e;)t=We(),n++;return St=G,St},"getTasks"),je=l(function(t,e,n,s){let r=t.format(e.trim()),f=t.format("YYYY-MM-DD");return s.includes(r)||s.includes(f)?!1:n.includes("weekends")&&(t.isoWeekday()===Oe[Ct]||t.isoWeekday()===Oe[Ct]+1)||n.includes(t.format("dddd").toLowerCase())?!0:n.includes(r)||n.includes(f)},"isInvalidDate"),Di=l(function(t){re=t},"setWeekday"),Si=l(function(){return re},"getWeekday"),Ci=l(function(t){Ct=t},"setWeekend"),Ge=l(function(t,e,n,s){if(!n.length||t.manualEndTime)return;let r;t.startTime instanceof Date?r=(0,Q.default)(t.startTime):r=(0,Q.default)(t.startTime,e,!0),r=r.add(1,"d");let f;t.endTime instanceof Date?f=(0,Q.default)(t.endTime):f=(0,Q.default)(t.endTime,e,!0);let[y,w]=Mi(r,f,e,n,s);t.endTime=y.toDate(),t.renderEndTime=w},"checkTaskDates"),Mi=l(function(t,e,n,s,r){let f=!1,y=null,w=e.add(1e4,"d");for(;t<=e;){if(f||(y=e.toDate()),f=je(t,n,s,r),f&&(e=e.add(1,"d"),e>w))throw new Error("Failed to find a valid date that was not excluded by `excludes` after 10,000 iterations.");t=t.add(1,"d")}return[e,y]},"fixTaskDates"),Ut=l(function(t,e,n){if(n=n.trim(),l(w=>{let S=w.trim();return S==="x"||S==="X"},"isTimestampFormat")(e)&&/^\d+$/.test(n))return new Date(Number(n));let f=/^after\s+(?<ids>[\d\w- ]+)/.exec(n);if(f!==null){let w=null;for(let N of f.groups.ids.split(" ")){let Y=ct(N);Y!==void 0&&(!w||Y.endTime>w.endTime)&&(w=Y)}if(w)return w.endTime;let S=new Date;return S.setHours(0,0,0,0),S}let y=(0,Q.default)(n,e.trim(),!0);if(y.isValid())return y.toDate();{rt.debug("Invalid date:"+n),rt.debug("With date format:"+e.trim());let w=new Date(n);if(w===void 0||isNaN(w.getTime())||w.getFullYear()<-1e4||w.getFullYear()>1e4)throw new Error("Invalid date:"+n);return w}},"getStartDate"),Xe=l(function(t){let e=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());return e!==null?[Number.parseFloat(e[1]),e[2]]:[NaN,"ms"]},"parseDuration"),Ue=l(function(t,e,n,s=!1){n=n.trim();let f=/^until\s+(?<ids>[\d\w- ]+)/.exec(n);if(f!==null){let Y=null;for(let R of f.groups.ids.split(" ")){let H=ct(R);H!==void 0&&(!Y||H.startTime<Y.startTime)&&(Y=H)}if(Y)return Y.startTime;let z=new Date;return z.setHours(0,0,0,0),z}let y=(0,Q.default)(n,e.trim(),!0);if(y.isValid())return s&&(y=y.add(1,"d")),y.toDate();let w=(0,Q.default)(t),[S,N]=Xe(n);if(!Number.isNaN(S)){let Y=w.add(S,N);Y.isValid()&&(w=Y)}return w.toDate()},"getEndDate"),_t=0,kt=l(function(t){return t===void 0?(_t=_t+1,"task"+_t):t},"parseId"),Ei=l(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;let s=n.split(","),r={};ne(s,r,He);for(let y=0;y<s.length;y++)s[y]=s[y].trim();let f="";switch(s.length){case 1:r.id=kt(),r.startTime=t.endTime,f=s[0];break;case 2:r.id=kt(),r.startTime=Ut(void 0,J,s[0]),f=s[1];break;case 3:r.id=kt(s[0]),r.startTime=Ut(void 0,J,s[1]),f=s[2];break;default:}return f&&(r.endTime=Ue(r.startTime,J,f,Tt),r.manualEndTime=(0,Q.default)(f,"YYYY-MM-DD",!0).isValid(),Ge(r,J,gt,yt)),r},"compileData"),Ii=l(function(t,e){let n;e.substr(0,1)===":"?n=e.substr(1,e.length):n=e;let s=n.split(","),r={};ne(s,r,He);for(let f=0;f<s.length;f++)s[f]=s[f].trim();switch(s.length){case 1:r.id=kt(),r.startTime={type:"prevTaskEnd",id:t},r.endTime={data:s[0]};break;case 2:r.id=kt(),r.startTime={type:"getStartDate",startData:s[0]},r.endTime={data:s[1]};break;case 3:r.id=kt(s[0]),r.startTime={type:"getStartDate",startData:s[1]},r.endTime={data:s[2]};break;default:}return r},"parseData"),qt,Dt,G=[],qe={},Yi=l(function(t,e){let n={section:pt,type:pt,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:e},task:t,classes:[]},s=Ii(Dt,e);n.raw.startTime=s.startTime,n.raw.endTime=s.endTime,n.id=s.id,n.prevTaskId=Dt,n.active=s.active,n.done=s.done,n.crit=s.crit,n.milestone=s.milestone,n.vert=s.vert,n.vert?n.order=-1:(n.order=Xt,Xt++);let r=G.push(n);Dt=n.id,qe[n.id]=r-1},"addTask"),ct=l(function(t){let e=qe[t];return G[e]},"findTaskById"),$i=l(function(t,e){let n={section:pt,type:pt,description:t,task:t,classes:[]},s=Ei(qt,e);n.startTime=s.startTime,n.endTime=s.endTime,n.id=s.id,n.active=s.active,n.done=s.done,n.crit=s.crit,n.milestone=s.milestone,n.vert=s.vert,qt=n,St.push(n)},"addTaskOrg"),We=l(function(){let t=l(function(n){let s=G[n],r="";switch(G[n].raw.startTime.type){case"prevTaskEnd":{let f=ct(s.prevTaskId);s.startTime=f.endTime;break}case"getStartDate":r=Ut(void 0,J,G[n].raw.startTime.startData),r&&(G[n].startTime=r);break}return G[n].startTime&&(G[n].endTime=Ue(G[n].startTime,J,G[n].raw.endTime.data,Tt),G[n].endTime&&(G[n].processed=!0,G[n].manualEndTime=(0,Q.default)(G[n].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),Ge(G[n],J,gt,yt))),G[n].processed},"compileTask"),e=!0;for(let[n,s]of G.entries())t(n),e=e&&s.processed;return e},"compileTasks"),Li=l(function(t,e){let n=e;ot().securityLevel!=="loose"&&(n=(0,Pe.sanitizeUrl)(e)),t.split(",").forEach(function(s){ct(s)!==void 0&&(Qe(s,()=>{window.open(n,"_self")}),Jt.set(s,n))}),Ze(t,"clickable")},"setLink"),Ze=l(function(t,e){t.split(",").forEach(function(n){let s=ct(n);s!==void 0&&s.classes.push(e)})},"setClass"),Ai=l(function(t,e,n){if(ot().securityLevel!=="loose"||e===void 0)return;let s=[];if(typeof n=="string"){s=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let f=0;f<s.length;f++){let y=s[f].trim();y.startsWith('"')&&y.endsWith('"')&&(y=y.substr(1,y.length-2)),s[f]=y}}s.length===0&&s.push(t),ct(t)!==void 0&&Qe(t,()=>{Ye.runFunc(e,...s)})},"setClickFun"),Qe=l(function(t,e){ie.push(function(){let n=ht?`${ht}-${t}`:t,s=document.querySelector(`[id="${n}"]`);s!==null&&s.addEventListener("click",function(){e()})},function(){let n=ht?`${ht}-${t}`:t,s=document.querySelector(`[id="${n}-text"]`);s!==null&&s.addEventListener("click",function(){e()})})},"pushFun"),Fi=l(function(t,e,n){t.split(",").forEach(function(s){Ai(s,e,n)}),Ze(t,"clickable")},"setClickEvent"),Oi=l(function(t){ie.forEach(function(e){e(t)})},"bindFunctions"),Wi={getConfig:l(()=>ot().gantt,"getConfig"),clear:ei,setDateFormat:li,getDateFormat:yi,enableInclusiveEndDates:ui,endDatesAreInclusive:di,enableTopAxis:fi,topAxisEnabled:hi,setAxisFormat:si,getAxisFormat:ri,setTickInterval:ni,getTickInterval:ai,setTodayMarker:oi,getTodayMarker:ci,setAccTitle:de,getAccTitle:fe,setDiagramTitle:ke,getDiagramTitle:ye,setDiagramId:ii,setDisplayMode:mi,getDisplayMode:ki,setAccDescription:he,getAccDescription:me,addSection:xi,getSections:wi,getTasks:_i,addTask:Yi,findTaskById:ct,addTaskOrg:$i,setIncludes:gi,getIncludes:pi,setExcludes:vi,getExcludes:Ti,setClickEvent:Fi,setLink:Li,getLinks:bi,bindFunctions:Oi,parseDuration:Xe,isInvalidDate:je,setWeekday:Di,getWeekday:Si,setWeekend:Ci};function ne(t,e,n){let s=!0;for(;s;)s=!1,n.forEach(function(r){let f="^\\s*"+r+"\\s*$",y=new RegExp(f);t[0].match(y)&&(e[r]=!0,t.shift(1),s=!0)})}l(ne,"getTaskTags");mt.default.extend(Ke.default);var Vi=l(function(){rt.debug("Something is calling, setConf, remove the call")},"setConf"),Ve={monday:_e,tuesday:De,wednesday:Se,thursday:Ce,friday:Me,saturday:Ee,sunday:we},Pi=l((t,e)=>{let n=[...t].map(()=>-1/0),s=[...t].sort((f,y)=>f.startTime-y.startTime||f.order-y.order),r=0;for(let f of s)for(let y=0;y<n.length;y++)if(f.startTime>=n[y]){n[y]=f.endTime,f.order=y+e,y>r&&(r=y);break}return r},"getMaxIntersections"),st,jt=1e4,Ni=l(function(t,e,n,s){let r=ot().gantt;s.db.setDiagramId(e);let f=ot().securityLevel,y;f==="sandbox"&&(y=vt("#i"+e));let w=f==="sandbox"?vt(y.nodes()[0].contentDocument.body):vt("body"),S=f==="sandbox"?y.nodes()[0].contentDocument:document,N=S.getElementById(e);st=N.parentElement.offsetWidth,st===void 0&&(st=1200),r.useWidth!==void 0&&(st=r.useWidth);let Y=s.db.getTasks(),z=Y.filter(k=>!k.vert),R=[];for(let k of z)R.push(k.type);R=F(R);let H={},x=2*r.topPadding;if(s.db.getDisplayMode()==="compact"||r.displayMode==="compact"){let k={};for(let v of z)k[v.section]===void 0?k[v.section]=[v]:k[v.section].push(v);let p=0;for(let v of Object.keys(k)){let T=Pi(k[v],p)+1;p+=T,x+=T*(r.barHeight+r.barGap),H[v]=T}}else{x+=z.length*(r.barHeight+r.barGap);for(let k of R)H[k]=z.filter(p=>p.type===k).length}N.setAttribute("viewBox","0 0 "+st+" "+x);let _=w.select(`[id="${e}"]`),b=Ie().domain([pe(Y,function(k){return k.startTime}),ge(Y,function(k){return k.endTime})]).rangeRound([0,st-r.leftPadding-r.rightPadding]);function A(k,p){let v=k.startTime,T=p.startTime,a=0;return v>T?a=1:v<T&&(a=-1),a}l(A,"taskCompare"),Y.sort(A),X(Y,st,x),le(_,x,st,r.useMaxWidth),_.append("text").text(s.db.getDiagramTitle()).attr("x",st/2).attr("y",r.titleTopMargin).attr("class","titleText");function X(k,p,v){let T=r.barHeight,a=T+r.barGap,h=r.topPadding,d=r.leftPadding,u=xe().domain([0,R.length]).range(["#00B9FA","#F95002"]).interpolate(be);$(a,h,d,p,v,k,s.db.getExcludes(),s.db.getIncludes()),m(d,h,p,v),U(k,a,h,d,T,u,p,v),I(a,h,d,T,u),W(d,h,p,v)}l(X,"makeGantt");function U(k,p,v,T,a,h,d){k.sort((o,D)=>o.vert===D.vert?0:o.vert?1:-1);let u=k.filter(o=>!o.vert),i=[...new Set(u.map(o=>o.order))].map(o=>u.find(D=>D.order===o));_.append("g").selectAll("rect").data(i).enter().append("rect").attr("x",0).attr("y",function(o,D){return D=o.order,D*p+v-2}).attr("width",function(){return d-r.rightPadding/2}).attr("height",p).attr("class",function(o){for(let[D,E]of R.entries())if(o.type===E)return"section section"+D%r.numberSectionStyles;return"section section0"}).enter();let M=_.append("g").selectAll("rect").data(k).enter(),c=s.db.getLinks();if(M.append("rect").attr("id",function(o){return e+"-"+o.id}).attr("rx",3).attr("ry",3).attr("x",function(o){return o.milestone?b(o.startTime)+T+.5*(b(o.endTime)-b(o.startTime))-.5*a:b(o.startTime)+T}).attr("y",function(o,D){return D=o.order,o.vert?r.gridLineStartPadding:D*p+v}).attr("width",function(o){return o.milestone?a:o.vert?.08*a:b(o.renderEndTime||o.endTime)-b(o.startTime)}).attr("height",function(o){return o.vert?u.length*(r.barHeight+r.barGap)+r.barHeight*2:a}).attr("transform-origin",function(o,D){return D=o.order,(b(o.startTime)+T+.5*(b(o.endTime)-b(o.startTime))).toString()+"px "+(D*p+v+.5*a).toString()+"px"}).attr("class",function(o){let D="task",E="";o.classes.length>0&&(E=o.classes.join(" "));let V=0;for(let[L,O]of R.entries())o.type===O&&(V=L%r.numberSectionStyles);let P="";return o.active?o.crit?P+=" activeCrit":P=" active":o.done?o.crit?P=" doneCrit":P=" done":o.crit&&(P+=" crit"),P.length===0&&(P=" task"),o.milestone&&(P=" milestone "+P),o.vert&&(P=" vert "+P),P+=V,P+=" "+E,D+P}),M.append("text").attr("id",function(o){return e+"-"+o.id+"-text"}).text(function(o){return o.task}).attr("font-size",r.fontSize).attr("x",function(o){let D=b(o.startTime),E=b(o.renderEndTime||o.endTime);if(o.milestone&&(D+=.5*(b(o.endTime)-b(o.startTime))-.5*a,E=D+a),o.vert)return b(o.startTime)+T;let V=this.getBBox().width;return V>E-D?E+V+1.5*r.leftPadding>d?D+T-5:E+T+5:(E-D)/2+D+T}).attr("y",function(o,D){return o.vert?r.gridLineStartPadding+u.length*(r.barHeight+r.barGap)+60:(D=o.order,D*p+r.barHeight/2+(r.fontSize/2-2)+v)}).attr("text-height",a).attr("class",function(o){let D=b(o.startTime),E=b(o.endTime);o.milestone&&(E=D+a);let V=this.getBBox().width,P="";o.classes.length>0&&(P=o.classes.join(" "));let L=0;for(let[tt,et]of R.entries())o.type===et&&(L=tt%r.numberSectionStyles);let O="";return o.active&&(o.crit?O="activeCritText"+L:O="activeText"+L),o.done?o.crit?O=O+" doneCritText"+L:O=O+" doneText"+L:o.crit&&(O=O+" critText"+L),o.milestone&&(O+=" milestoneText"),o.vert&&(O+=" vertText"),V>E-D?E+V+1.5*r.leftPadding>d?P+" taskTextOutsideLeft taskTextOutside"+L+" "+O:P+" taskTextOutsideRight taskTextOutside"+L+" "+O+" width-"+V:P+" taskText taskText"+L+" "+O+" width-"+V}),ot().securityLevel==="sandbox"){let o;o=vt("#i"+e);let D=o.nodes()[0].contentDocument;M.filter(function(E){return c.has(E.id)}).each(function(E){var V=D.querySelector("#"+CSS.escape(e+"-"+E.id)),P=D.querySelector("#"+CSS.escape(e+"-"+E.id+"-text"));let L=V.parentNode;var O=D.createElement("a");O.setAttribute("xlink:href",c.get(E.id)),O.setAttribute("target","_top"),L.appendChild(O),O.appendChild(V),O.appendChild(P)})}}l(U,"drawRects");function $(k,p,v,T,a,h,d,u){if(d.length===0&&u.length===0)return;let C,i;for(let{startTime:E,endTime:V}of h)(C===void 0||E<C)&&(C=E),(i===void 0||V>i)&&(i=V);if(!C||!i)return;if((0,mt.default)(i).diff((0,mt.default)(C),"year")>5){rt.warn("The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.");return}let M=s.db.getDateFormat(),c=[],B=null,o=(0,mt.default)(C);for(;o.valueOf()<=i;)s.db.isInvalidDate(o,M,d,u)?B?B.end=o:B={start:o,end:o}:B&&(c.push(B),B=null),o=o.add(1,"d");_.append("g").selectAll("rect").data(c).enter().append("rect").attr("id",E=>e+"-exclude-"+E.start.format("YYYY-MM-DD")).attr("x",E=>b(E.start.startOf("day"))+v).attr("y",r.gridLineStartPadding).attr("width",E=>b(E.end.endOf("day"))-b(E.start.startOf("day"))).attr("height",a-p-r.gridLineStartPadding).attr("transform-origin",function(E,V){return(b(E.start)+v+.5*(b(E.end)-b(E.start))).toString()+"px "+(V*k+.5*a).toString()+"px"}).attr("class","exclude-range")}l($,"drawExcludeDays");function g(k,p,v,T){if(v<=0||k>p)return 1/0;let a=p-k,h=mt.default.duration({[T??"day"]:v}).asMilliseconds();return h<=0?1/0:Math.ceil(a/h)}l(g,"getEstimatedTickCount");function m(k,p,v,T){let a=s.db.getDateFormat(),h=s.db.getAxisFormat(),d;h?d=h:a==="D"?d="%d":d=r.axisFormat??"%Y-%m-%d";let u=Te(b).tickSize(-T+p+r.gridLineStartPadding).tickFormat(Ot(d)),i=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(s.db.getTickInterval()||r.tickInterval);if(i!==null){let M=parseInt(i[1],10);if(isNaN(M)||M<=0)rt.warn(`Invalid tick interval value: "${i[1]}". Skipping custom tick interval.`);else{let c=i[2],B=s.db.getWeekday()||r.weekday,o=b.domain(),D=o[0],E=o[1],V=g(D,E,M,c);if(V>jt)rt.warn(`The tick interval "${M}${c}" would generate ${V} ticks, which exceeds the maximum allowed (${jt}). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(c){case"millisecond":u.ticks(It.every(M));break;case"second":u.ticks(Yt.every(M));break;case"minute":u.ticks($t.every(M));break;case"hour":u.ticks(Lt.every(M));break;case"day":u.ticks(At.every(M));break;case"week":u.ticks(Ve[B].every(M));break;case"month":u.ticks(Ft.every(M));break}}}if(_.append("g").attr("class","grid").attr("transform","translate("+k+", "+(T-50)+")").call(u).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),s.db.topAxisEnabled()||r.topAxis){let M=ve(b).tickSize(-T+p+r.gridLineStartPadding).tickFormat(Ot(d));if(i!==null){let c=parseInt(i[1],10);if(isNaN(c)||c<=0)rt.warn(`Invalid tick interval value: "${i[1]}". Skipping custom tick interval.`);else{let B=i[2],o=s.db.getWeekday()||r.weekday,D=b.domain(),E=D[0],V=D[1];if(g(E,V,c,B)<=jt)switch(B){case"millisecond":M.ticks(It.every(c));break;case"second":M.ticks(Yt.every(c));break;case"minute":M.ticks($t.every(c));break;case"hour":M.ticks(Lt.every(c));break;case"day":M.ticks(At.every(c));break;case"week":M.ticks(Ve[o].every(c));break;case"month":M.ticks(Ft.every(c));break}}}_.append("g").attr("class","grid").attr("transform","translate("+k+", "+p+")").call(M).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}l(m,"makeGrid");function I(k,p){let v=0,T=Object.keys(H).map(a=>[a,H[a]]);_.append("g").selectAll("text").data(T).enter().append(function(a){let h=a[0].split(ce.lineBreakRegex),d=-(h.length-1)/2,u=S.createElementNS("http://www.w3.org/2000/svg","text");u.setAttribute("dy",d+"em");for(let[C,i]of h.entries()){let M=S.createElementNS("http://www.w3.org/2000/svg","tspan");M.setAttribute("alignment-baseline","central"),M.setAttribute("x","10"),C>0&&M.setAttribute("dy","1em"),M.textContent=i,u.appendChild(M)}return u}).attr("x",10).attr("y",function(a,h){if(h>0)for(let d=0;d<h;d++)return v+=T[h-1][1],a[1]*k/2+v*k+p;else return a[1]*k/2+p}).attr("font-size",r.sectionFontSize).attr("class",function(a){for(let[h,d]of R.entries())if(a[0]===d)return"sectionTitle sectionTitle"+h%r.numberSectionStyles;return"sectionTitle"})}l(I,"vertLabels");function W(k,p,v,T){let a=s.db.getTodayMarker();if(a==="off")return;let h=_.append("g").attr("class","today"),d=new Date,u=h.append("line");u.attr("x1",b(d)+k).attr("x2",b(d)+k).attr("y1",r.titleTopMargin).attr("y2",T-r.titleTopMargin).attr("class","today"),a!==""&&u.attr("style",a.replace(/,/g,";"))}l(W,"drawToday");function F(k){let p={},v=[];for(let T=0,a=k.length;T<a;++T)Object.prototype.hasOwnProperty.call(p,k[T])||(p[k[T]]=!0,v.push(k[T]));return v}l(F,"checkUnique")},"draw"),Ri={setConf:Vi,draw:Ni},zi=l(t=>`
7
+ .mermaid-main-font {
8
+ font-family: ${t.fontFamily};
9
+ }
10
+
11
+ .exclude-range {
12
+ fill: ${t.excludeBkgColor};
13
+ }
14
+
15
+ .section {
16
+ stroke: none;
17
+ opacity: 0.2;
18
+ }
19
+
20
+ .section0 {
21
+ fill: ${t.sectionBkgColor};
22
+ }
23
+
24
+ .section2 {
25
+ fill: ${t.sectionBkgColor2};
26
+ }
27
+
28
+ .section1,
29
+ .section3 {
30
+ fill: ${t.altSectionBkgColor};
31
+ opacity: 0.2;
32
+ }
33
+
34
+ .sectionTitle0 {
35
+ fill: ${t.titleColor};
36
+ }
37
+
38
+ .sectionTitle1 {
39
+ fill: ${t.titleColor};
40
+ }
41
+
42
+ .sectionTitle2 {
43
+ fill: ${t.titleColor};
44
+ }
45
+
46
+ .sectionTitle3 {
47
+ fill: ${t.titleColor};
48
+ }
49
+
50
+ .sectionTitle {
51
+ text-anchor: start;
52
+ font-family: ${t.fontFamily};
53
+ }
54
+
55
+
56
+ /* Grid and axis */
57
+
58
+ .grid .tick {
59
+ stroke: ${t.gridColor};
60
+ opacity: 0.8;
61
+ shape-rendering: crispEdges;
62
+ }
63
+
64
+ .grid .tick text {
65
+ font-family: ${t.fontFamily};
66
+ fill: ${t.textColor};
67
+ }
68
+
69
+ .grid path {
70
+ stroke-width: 0;
71
+ }
72
+
73
+
74
+ /* Today line */
75
+
76
+ .today {
77
+ fill: none;
78
+ stroke: ${t.todayLineColor};
79
+ stroke-width: 2px;
80
+ }
81
+
82
+
83
+ /* Task styling */
84
+
85
+ /* Default task */
86
+
87
+ .task {
88
+ stroke-width: 2;
89
+ }
90
+
91
+ .taskText {
92
+ text-anchor: middle;
93
+ font-family: ${t.fontFamily};
94
+ }
95
+
96
+ .taskTextOutsideRight {
97
+ fill: ${t.taskTextDarkColor};
98
+ text-anchor: start;
99
+ font-family: ${t.fontFamily};
100
+ }
101
+
102
+ .taskTextOutsideLeft {
103
+ fill: ${t.taskTextDarkColor};
104
+ text-anchor: end;
105
+ }
106
+
107
+
108
+ /* Special case clickable */
109
+
110
+ .task.clickable {
111
+ cursor: pointer;
112
+ }
113
+
114
+ .taskText.clickable {
115
+ cursor: pointer;
116
+ fill: ${t.taskTextClickableColor} !important;
117
+ font-weight: bold;
118
+ }
119
+
120
+ .taskTextOutsideLeft.clickable {
121
+ cursor: pointer;
122
+ fill: ${t.taskTextClickableColor} !important;
123
+ font-weight: bold;
124
+ }
125
+
126
+ .taskTextOutsideRight.clickable {
127
+ cursor: pointer;
128
+ fill: ${t.taskTextClickableColor} !important;
129
+ font-weight: bold;
130
+ }
131
+
132
+
133
+ /* Specific task settings for the sections*/
134
+
135
+ .taskText0,
136
+ .taskText1,
137
+ .taskText2,
138
+ .taskText3 {
139
+ fill: ${t.taskTextColor};
140
+ }
141
+
142
+ .task0,
143
+ .task1,
144
+ .task2,
145
+ .task3 {
146
+ fill: ${t.taskBkgColor};
147
+ stroke: ${t.taskBorderColor};
148
+ }
149
+
150
+ .taskTextOutside0,
151
+ .taskTextOutside2
152
+ {
153
+ fill: ${t.taskTextOutsideColor};
154
+ }
155
+
156
+ .taskTextOutside1,
157
+ .taskTextOutside3 {
158
+ fill: ${t.taskTextOutsideColor};
159
+ }
160
+
161
+
162
+ /* Active task */
163
+
164
+ .active0,
165
+ .active1,
166
+ .active2,
167
+ .active3 {
168
+ fill: ${t.activeTaskBkgColor};
169
+ stroke: ${t.activeTaskBorderColor};
170
+ }
171
+
172
+ .activeText0,
173
+ .activeText1,
174
+ .activeText2,
175
+ .activeText3 {
176
+ fill: ${t.taskTextDarkColor} !important;
177
+ }
178
+
179
+
180
+ /* Completed task */
181
+
182
+ .done0,
183
+ .done1,
184
+ .done2,
185
+ .done3 {
186
+ stroke: ${t.doneTaskBorderColor};
187
+ fill: ${t.doneTaskBkgColor};
188
+ stroke-width: 2;
189
+ }
190
+
191
+ .doneText0,
192
+ .doneText1,
193
+ .doneText2,
194
+ .doneText3 {
195
+ fill: ${t.taskTextDarkColor} !important;
196
+ }
197
+
198
+ /* Done task text displayed outside the bar sits against the diagram background,
199
+ not against the done-task bar, so it must use the outside/contrast color. */
200
+ .doneText0.taskTextOutsideLeft,
201
+ .doneText0.taskTextOutsideRight,
202
+ .doneText1.taskTextOutsideLeft,
203
+ .doneText1.taskTextOutsideRight,
204
+ .doneText2.taskTextOutsideLeft,
205
+ .doneText2.taskTextOutsideRight,
206
+ .doneText3.taskTextOutsideLeft,
207
+ .doneText3.taskTextOutsideRight {
208
+ fill: ${t.taskTextOutsideColor} !important;
209
+ }
210
+
211
+
212
+ /* Tasks on the critical line */
213
+
214
+ .crit0,
215
+ .crit1,
216
+ .crit2,
217
+ .crit3 {
218
+ stroke: ${t.critBorderColor};
219
+ fill: ${t.critBkgColor};
220
+ stroke-width: 2;
221
+ }
222
+
223
+ .activeCrit0,
224
+ .activeCrit1,
225
+ .activeCrit2,
226
+ .activeCrit3 {
227
+ stroke: ${t.critBorderColor};
228
+ fill: ${t.activeTaskBkgColor};
229
+ stroke-width: 2;
230
+ }
231
+
232
+ .doneCrit0,
233
+ .doneCrit1,
234
+ .doneCrit2,
235
+ .doneCrit3 {
236
+ stroke: ${t.critBorderColor};
237
+ fill: ${t.doneTaskBkgColor};
238
+ stroke-width: 2;
239
+ cursor: pointer;
240
+ shape-rendering: crispEdges;
241
+ }
242
+
243
+ .milestone {
244
+ transform: rotate(45deg) scale(0.8,0.8);
245
+ }
246
+
247
+ .milestoneText {
248
+ font-style: italic;
249
+ }
250
+ .doneCritText0,
251
+ .doneCritText1,
252
+ .doneCritText2,
253
+ .doneCritText3 {
254
+ fill: ${t.taskTextDarkColor} !important;
255
+ }
256
+
257
+ /* Done-crit task text outside the bar \u2014 same reasoning as doneText above. */
258
+ .doneCritText0.taskTextOutsideLeft,
259
+ .doneCritText0.taskTextOutsideRight,
260
+ .doneCritText1.taskTextOutsideLeft,
261
+ .doneCritText1.taskTextOutsideRight,
262
+ .doneCritText2.taskTextOutsideLeft,
263
+ .doneCritText2.taskTextOutsideRight,
264
+ .doneCritText3.taskTextOutsideLeft,
265
+ .doneCritText3.taskTextOutsideRight {
266
+ fill: ${t.taskTextOutsideColor} !important;
267
+ }
268
+
269
+ .vert {
270
+ stroke: ${t.vertLineColor};
271
+ }
272
+
273
+ .vertText {
274
+ font-size: 15px;
275
+ text-anchor: middle;
276
+ fill: ${t.vertLineColor} !important;
277
+ }
278
+
279
+ .activeCritText0,
280
+ .activeCritText1,
281
+ .activeCritText2,
282
+ .activeCritText3 {
283
+ fill: ${t.taskTextDarkColor} !important;
284
+ }
285
+
286
+ .titleText {
287
+ text-anchor: middle;
288
+ font-size: 18px;
289
+ fill: ${t.titleColor||t.textColor};
290
+ font-family: ${t.fontFamily};
291
+ }
292
+ `,"getStyles"),Hi=zi,Zi={parser:ti,db:Wi,renderer:Ri,styles:Hi};export{Zi as diagram};
@@ -0,0 +1,7 @@
1
+ import{a as Gt}from"./chunk-B7YX5TR5.js";import{c as qt}from"./chunk-AUSLTP43.js";import"./chunk-GLU2YQV2.js";import{o as yt}from"./chunk-6DWWYA6G.js";import"./chunk-VJLIWNIU.js";import{G as Ft,N as Wt,S as Xt,T as Nt,U as Yt,V as Ht,W as $t,X as Ut,Y as ft,h as Ot,j as Vt,t as nt}from"./chunk-LWDL4HZB.js";import"./chunk-VXPNUNUX.js";import{H as bt,b as dt,n as pt,o as mt}from"./chunk-JR4SIX7A.js";import{a}from"./chunk-5FIPUNR4.js";import"./chunk-SQE76S5B.js";var At=(function(){var t=a(function(z,r,h,g){for(h=h||{},g=z.length;g--;h[z[g]]=r);return h},"o"),e=[1,10,12,14,16,18,19,21,23],i=[2,6],s=[1,3],n=[1,5],u=[1,6],l=[1,7],d=[1,5,10,12,14,16,18,19,21,23,36,37,38],p=[1,25],S=[1,26],R=[1,28],T=[1,29],B=[1,30],W=[1,31],X=[1,32],v=[1,33],V=[1,34],N=[1,35],Y=[1,36],b=[1,37],E=[1,43],c=[1,42],L=[1,47],I=[1,50],A=[1,10,12,14,16,18,19,21,23,36,37,38],$=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38],D=[1,10,12,14,16,18,19,21,23,24,26,28,29,36,37,38,42,43,44,45,46,47,48,49,50,51],Q=[1,65],C=[26,28],y={trace:a(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,dataPoints:25,SQUARE_BRACES_END:26,dataPoint:27,COMMA:28,NUMBER_WITH_DECIMAL:29,STR:30,xAxisData:31,bandData:32,ARROW_DELIMITER:33,commaSeparatedTexts:34,yAxisData:35,NEWLINE:36,SEMI:37,EOF:38,alphaNum:39,MD_STR:40,alphaNumToken:41,AMP:42,NUM:43,ALPHA:44,PLUS:45,EQUALS:46,MULT:47,DOT:48,BRKT:49,MINUS:50,UNDERSCORE:51,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",28:"COMMA",29:"NUMBER_WITH_DECIMAL",30:"STR",33:"ARROW_DELIMITER",36:"NEWLINE",37:"SEMI",38:"EOF",40:"MD_STR",42:"AMP",43:"NUM",44:"ALPHA",45:"PLUS",46:"EQUALS",47:"MULT",48:"DOT",49:"BRKT",50:"MINUS",51:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[27,2],[27,1],[13,1],[13,2],[13,1],[31,1],[31,3],[32,3],[34,3],[34,1],[15,1],[15,2],[15,1],[35,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[39,1],[39,2],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1],[41,1]],performAction:a(function(r,h,g,x,k,o,U){var f=o.length-1;switch(k){case 5:x.setOrientation(o[f]);break;case 9:x.setDiagramTitle(o[f].text.trim());break;case 12:x.setLineData({text:"",type:"text"},o[f]);break;case 13:x.setLineData(o[f-1],o[f]);break;case 14:x.setBarData({text:"",type:"text"},o[f]);break;case 15:x.setBarData(o[f-1],o[f]);break;case 16:this.$=o[f].trim(),x.setAccTitle(this.$);break;case 17:case 18:this.$=o[f].trim(),x.setAccDescription(this.$);break;case 19:this.$=o[f-1];break;case 20:case 30:this.$=[o[f-2],...o[f]];break;case 21:case 31:this.$=[o[f]];break;case 22:this.$={value:Number(o[f-1]),label:o[f]};break;case 23:this.$={value:Number(o[f]),label:""};break;case 24:x.setXAxisTitle(o[f]);break;case 25:x.setXAxisTitle(o[f-1]);break;case 26:x.setXAxisTitle({type:"text",text:""});break;case 27:x.setXAxisBand(o[f]);break;case 28:x.setXAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 29:this.$=o[f-1];break;case 32:x.setYAxisTitle(o[f]);break;case 33:x.setYAxisTitle(o[f-1]);break;case 34:x.setYAxisTitle({type:"text",text:""});break;case 35:x.setYAxisRangeData(Number(o[f-2]),Number(o[f]));break;case 39:this.$={text:o[f],type:"text"};break;case 40:this.$={text:o[f],type:"text"};break;case 41:this.$={text:o[f],type:"markdown"};break;case 42:this.$=o[f];break;case 43:this.$=o[f-1]+""+o[f];break}},"anonymous"),table:[t(e,i,{3:1,4:2,7:4,5:s,36:n,37:u,38:l}),{1:[3]},t(e,i,{4:2,7:4,3:8,5:s,36:n,37:u,38:l}),t(e,i,{4:2,7:4,6:9,3:10,5:s,8:[1,11],36:n,37:u,38:l}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},t(d,[2,36]),t(d,[2,37]),t(d,[2,38]),{1:[2,1]},t(e,i,{4:2,7:4,3:21,5:s,36:n,37:u,38:l}),{1:[2,3]},t(d,[2,5]),t(e,[2,7],{4:22,36:n,37:u,38:l}),{11:23,30:p,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},{11:39,13:38,24:E,29:c,30:p,31:40,32:41,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},{11:45,15:44,29:L,30:p,35:46,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},{11:49,17:48,24:I,30:p,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},{11:52,17:51,24:I,30:p,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},{20:[1,53]},{22:[1,54]},t(A,[2,18]),{1:[2,2]},t(A,[2,8]),t(A,[2,9]),t($,[2,39],{41:55,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b}),t($,[2,40]),t($,[2,41]),t(D,[2,42]),t(D,[2,44]),t(D,[2,45]),t(D,[2,46]),t(D,[2,47]),t(D,[2,48]),t(D,[2,49]),t(D,[2,50]),t(D,[2,51]),t(D,[2,52]),t(D,[2,53]),t(A,[2,10]),t(A,[2,24],{32:41,31:56,24:E,29:c}),t(A,[2,26]),t(A,[2,27]),{33:[1,57]},{11:59,30:p,34:58,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},t(A,[2,11]),t(A,[2,32],{35:60,29:L}),t(A,[2,34]),{33:[1,61]},t(A,[2,12]),{17:62,24:I},{25:63,27:64,29:Q},t(A,[2,14]),{17:66,24:I},t(A,[2,16]),t(A,[2,17]),t(D,[2,43]),t(A,[2,25]),{29:[1,67]},{26:[1,68]},{26:[2,31],28:[1,69]},t(A,[2,33]),{29:[1,70]},t(A,[2,13]),{26:[1,71]},{26:[2,21],28:[1,72]},t(C,[2,23],{30:[1,73]}),t(A,[2,15]),t(A,[2,28]),t(A,[2,29]),{11:59,30:p,34:74,39:24,40:S,41:27,42:R,43:T,44:B,45:W,46:X,47:v,48:V,49:N,50:Y,51:b},t(A,[2,35]),t(A,[2,19]),{25:75,27:64,29:Q},t(C,[2,22]),{26:[2,30]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],74:[2,30],75:[2,20]},parseError:a(function(r,h){if(h.recoverable)this.trace(r);else{var g=new Error(r);throw g.hash=h,g}},"parseError"),parse:a(function(r){var h=this,g=[0],x=[],k=[null],o=[],U=this.table,f="",it=0,Et=0,It=0,fe=2,Mt=1,pe=o.slice.call(arguments,1),_=Object.create(this.lexer),G={yy:{}};for(var lt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,lt)&&(G.yy[lt]=this.yy[lt]);_.setInput(r,G.yy),G.yy.lexer=_,G.yy.parser=this,typeof _.yylloc>"u"&&(_.yylloc={});var ct=_.yylloc;o.push(ct);var me=_.options&&_.options.ranges;typeof G.yy.parseError=="function"?this.parseError=G.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function be(M){g.length=g.length-2*M,k.length=k.length-M,o.length=o.length-M}a(be,"popStack");function Bt(){var M;return M=x.pop()||_.lex()||Mt,typeof M!="number"&&(M instanceof Array&&(x=M,M=x.pop()),M=h.symbols_[M]||M),M}a(Bt,"lex");for(var P,gt,q,O,ze,ut,K={},st,H,zt,at;;){if(q=g[g.length-1],this.defaultActions[q]?O=this.defaultActions[q]:((P===null||typeof P>"u")&&(P=Bt()),O=U[q]&&U[q][P]),typeof O>"u"||!O.length||!O[0]){var xt="";at=[];for(st in U[q])this.terminals_[st]&&st>fe&&at.push("'"+this.terminals_[st]+"'");_.showPosition?xt="Parse error on line "+(it+1)+`:
2
+ `+_.showPosition()+`
3
+ Expecting `+at.join(", ")+", got '"+(this.terminals_[P]||P)+"'":xt="Parse error on line "+(it+1)+": Unexpected "+(P==Mt?"end of input":"'"+(this.terminals_[P]||P)+"'"),this.parseError(xt,{text:_.match,token:this.terminals_[P]||P,line:_.yylineno,loc:ct,expected:at})}if(O[0]instanceof Array&&O.length>1)throw new Error("Parse Error: multiple actions possible at state: "+q+", token: "+P);switch(O[0]){case 1:g.push(P),k.push(_.yytext),o.push(_.yylloc),g.push(O[1]),P=null,gt?(P=gt,gt=null):(Et=_.yyleng,f=_.yytext,it=_.yylineno,ct=_.yylloc,It>0&&It--);break;case 2:if(H=this.productions_[O[1]][1],K.$=k[k.length-H],K._$={first_line:o[o.length-(H||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(H||1)].first_column,last_column:o[o.length-1].last_column},me&&(K._$.range=[o[o.length-(H||1)].range[0],o[o.length-1].range[1]]),ut=this.performAction.apply(K,[f,Et,it,G.yy,O[1],k,o].concat(pe)),typeof ut<"u")return ut;H&&(g=g.slice(0,-1*H*2),k=k.slice(0,-1*H),o=o.slice(0,-1*H)),g.push(this.productions_[O[1]][0]),k.push(K.$),o.push(K._$),zt=U[g[g.length-2]][g[g.length-1]],g.push(zt);break;case 3:return!0}}return!0},"parse")},F=(function(){var z={EOF:1,parseError:a(function(h,g){if(this.yy.parser)this.yy.parser.parseError(h,g);else throw new Error(h)},"parseError"),setInput:a(function(r,h){return this.yy=h||this.yy||{},this._input=r,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:a(function(){var r=this._input[0];this.yytext+=r,this.yyleng++,this.offset++,this.match+=r,this.matched+=r;var h=r.match(/(?:\r\n?|\n).*/g);return h?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),r},"input"),unput:a(function(r){var h=r.length,g=r.split(/(?:\r\n?|\n)/g);this._input=r+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-h),this.offset-=h;var x=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),g.length-1&&(this.yylineno-=g.length-1);var k=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:g?(g.length===x.length?this.yylloc.first_column:0)+x[x.length-g.length].length-g[0].length:this.yylloc.first_column-h},this.options.ranges&&(this.yylloc.range=[k[0],k[0]+this.yyleng-h]),this.yyleng=this.yytext.length,this},"unput"),more:a(function(){return this._more=!0,this},"more"),reject:a(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:a(function(r){this.unput(this.match.slice(r))},"less"),pastInput:a(function(){var r=this.matched.substr(0,this.matched.length-this.match.length);return(r.length>20?"...":"")+r.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:a(function(){var r=this.match;return r.length<20&&(r+=this._input.substr(0,20-r.length)),(r.substr(0,20)+(r.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:a(function(){var r=this.pastInput(),h=new Array(r.length+1).join("-");return r+this.upcomingInput()+`
5
+ `+h+"^"},"showPosition"),test_match:a(function(r,h){var g,x,k;if(this.options.backtrack_lexer&&(k={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&&(k.yylloc.range=this.yylloc.range.slice(0))),x=r[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+r[0].length},this.yytext+=r[0],this.match+=r[0],this.matches=r,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(r[0].length),this.matched+=r[0],g=this.performAction.call(this,this.yy,this,h,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),g)return g;if(this._backtrack){for(var o in k)this[o]=k[o];return!1}return!1},"test_match"),next:a(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var r,h,g,x;this._more||(this.yytext="",this.match="");for(var k=this._currentRules(),o=0;o<k.length;o++)if(g=this._input.match(this.rules[k[o]]),g&&(!h||g[0].length>h[0].length)){if(h=g,x=o,this.options.backtrack_lexer){if(r=this.test_match(g,k[o]),r!==!1)return r;if(this._backtrack){h=!1;continue}else return!1}else if(!this.options.flex)break}return h?(r=this.test_match(h,k[x]),r!==!1?r:!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:a(function(){var h=this.next();return h||this.lex()},"lex"),begin:a(function(h){this.conditionStack.push(h)},"begin"),popState:a(function(){var h=this.conditionStack.length-1;return h>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:a(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:a(function(h){return h=this.conditionStack.length-1-Math.abs(h||0),h>=0?this.conditionStack[h]:"INITIAL"},"topState"),pushState:a(function(h){this.begin(h)},"pushState"),stateStackSize:a(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:a(function(h,g,x,k){var o=k;switch(x){case 0:break;case 1:break;case 2:return this.popState(),36;break;case 3:return this.popState(),36;break;case 4:return 36;case 5:break;case 6:return 10;case 7:return this.pushState("acc_title"),19;break;case 8:return this.popState(),"acc_title_value";break;case 9:return this.pushState("acc_descr"),21;break;case 10:return this.popState(),"acc_descr_value";break;case 11:this.pushState("acc_descr_multiline");break;case 12:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:return 5;case 15:return 5;case 16:return 8;case 17:return this.pushState("axis_data"),"X_AXIS";break;case 18:return this.pushState("axis_data"),"Y_AXIS";break;case 19:return this.pushState("axis_band_data"),24;break;case 20:return 33;case 21:return this.pushState("data"),16;break;case 22:return this.pushState("data"),18;break;case 23:return this.pushState("data_inner"),24;break;case 24:return 29;case 25:return this.popState(),26;break;case 26:this.popState();break;case 27:this.pushState("string");break;case 28:this.popState();break;case 29:return"STR";case 30:return 24;case 31:return 26;case 32:return 44;case 33:return"COLON";case 34:return 45;case 35:return 28;case 36:return 46;case 37:return 47;case 38:return 49;case 39:return 51;case 40:return 48;case 41:return 42;case 42:return 50;case 43:return 43;case 44:break;case 45:return 37;case 46:return 38}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}};return z})();y.lexer=F;function w(){this.yy={}}return a(w,"Parser"),w.prototype=y,y.Parser=w,new w})();At.parser=At;var ye=At;function ot(t){return t.type==="bar"}a(ot,"isBarPlot");function rt(t){return t.type==="band"}a(rt,"isBandAxisData");function Z(t){return t.type==="linear"}a(Z,"isLinearAxisData");var St=class{constructor(t){this.parentGroup=t}static{a(this,"TextDimensionCalculatorWithFont")}getMaxDimension(t,e){if(!this.parentGroup)return{width:t.reduce((n,u)=>Math.max(u.length,n),0)*e,height:e};let i={width:0,height:0},s=this.parentGroup.append("g").attr("visibility","hidden").attr("font-size",e);for(let n of t){let u=qt(s,1,n),l=u?u.width:n.length*e,d=u?u.height:e;i.width=Math.max(i.width,l),i.height=Math.max(i.height,d)}return s.remove(),i}},jt=.7,Qt=.2,Kt=class{constructor(t,e,i,s){this.axisConfig=t,this.title=e,this.textDimensionCalculator=i,this.axisThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.normalizedLabelRotationInRad=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.normalizedLabelRotationInRad=this.axisConfig.labelRotation>=-90&&this.axisConfig.labelRotation<=90?this.axisConfig.labelRotation*Math.PI/180:0}static{a(this,"BaseAxis")}setRange(t){this.range=t,this.axisPosition==="left"||this.axisPosition==="right"?this.boundingRect.height=t[1]-t[0]:this.boundingRect.width=t[1]-t[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(t){this.axisPosition=t,this.setRange(this.range)}getTickDistance(){let t=this.getRange();return Math.abs(t[0]-t[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(t=>t.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){jt*this.getTickDistance()>this.outerPadding*2&&(this.outerPadding=Math.floor(jt*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(t){let e=t.height;if(this.axisConfig.showAxisLine&&e>this.axisConfig.axisLineWidth&&(e-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let i=this.getLabelDimension(),s=Qt*t.width;this.outerPadding=Math.min(i.width/2,s);let n=i.height;this.axisPosition==="bottom"&&this.normalizedLabelRotationInRad!==0&&(n=Math.max(n,Math.abs(Math.sin(this.normalizedLabelRotationInRad)*i.width)+Math.abs(Math.cos(this.normalizedLabelRotationInRad)*i.height))),n+=this.axisConfig.labelPadding*2,this.labelTextHeight=i.height,n<=e&&(e-=n,this.showLabel=!0)}if(this.axisConfig.showTick&&e>=this.axisConfig.tickLength&&(this.showTick=!0,e-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let i=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),s=i.height+this.axisConfig.titlePadding*2;this.titleTextHeight=i.height,s<=e&&(e-=s,this.showTitle=!0)}this.boundingRect.width=t.width,this.boundingRect.height=t.height-e}calculateSpaceIfDrawnVertical(t){let e=t.width;if(this.axisConfig.showAxisLine&&e>this.axisConfig.axisLineWidth&&(e-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let i=this.getLabelDimension(),s=Qt*t.height;this.outerPadding=Math.min(i.height/2,s);let n=i.width+this.axisConfig.labelPadding*2;n<=e&&(e-=n,this.showLabel=!0)}if(this.axisConfig.showTick&&e>=this.axisConfig.tickLength&&(this.showTick=!0,e-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let i=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),s=i.height+this.axisConfig.titlePadding*2;this.titleTextHeight=i.height,s<=e&&(e-=s,this.showTitle=!0)}this.boundingRect.width=t.width-e,this.boundingRect.height=t.height}calculateSpace(t){return this.axisPosition==="left"||this.axisPosition==="right"?this.calculateSpaceIfDrawnVertical(t):this.calculateSpaceIfDrawnHorizontally(t),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateOffsetByRotation(t){let e=this.normalizedLabelRotationInRad;return e===0?0:Math.sin(e)*this.getLabelDimension()[t]/2}getDrawableElementsForLeftAxis(){let t=[];if(this.showAxisLine){let e=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["left-axis","axisl-line"],data:[{path:`M ${e},${this.boundingRect.y} L ${e},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["left-axis","label"],data:this.getTickValues().map(e=>({text:e.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(e),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"middle",horizontalPos:"right"}))}),this.showTick){let e=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["left-axis","ticks"],data:this.getTickValues().map(i=>({path:`M ${e},${this.getScaleValue(i)} L ${e-this.axisConfig.tickLength},${this.getScaleValue(i)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["left-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForBottomAxis(){let t=[];if(this.showAxisLine){let e=this.boundingRect.y+this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["bottom-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${e} L ${this.boundingRect.x+this.boundingRect.width},${e}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["bottom-axis","label"],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e)+this.calculateOffsetByRotation("height"),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0)+Math.abs(this.calculateOffsetByRotation("width")),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:this.normalizedLabelRotationInRad*180/Math.PI,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let e=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["bottom-axis","ticks"],data:this.getTickValues().map(i=>({path:`M ${this.getScaleValue(i)},${e} L ${this.getScaleValue(i)},${e+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["bottom-axis","title"],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForTopAxis(){let t=[];if(this.showAxisLine){let e=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["top-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${e} L ${this.boundingRect.x+this.boundingRect.width},${e}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["top-axis","label"],data:this.getTickValues().map(e=>({text:e.toString(),x:this.getScaleValue(e),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+this.axisConfig.titlePadding*2:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let e=this.boundingRect.y;t.push({type:"path",groupTexts:["top-axis","ticks"],data:this.getTickValues().map(i=>({path:`M ${this.getScaleValue(i)},${e+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(i)},${e+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["top-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElements(){if(this.axisPosition==="left")return this.getDrawableElementsForLeftAxis();if(this.axisPosition==="right")throw Error("Drawing of right axis is not implemented");return this.axisPosition==="bottom"?this.getDrawableElementsForBottomAxis():this.axisPosition==="top"?this.getDrawableElementsForTopAxis():[]}},Ae=class extends Kt{static{a(this,"BandAxis")}constructor(t,e,i,s,n){super(t,s,n,e),this.categories=i,this.scale=pt().domain(this.categories).range(this.getRange())}setRange(t){super.setRange(t)}recalculateScale(){this.scale=pt().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),dt.trace("BandAxis axis final categories, range: ",this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(t){return this.scale(t)??this.getRange()[0]}},ke=class extends Kt{static{a(this,"LinearAxis")}constructor(t,e,i,s,n){super(t,s,n,e),this.domain=i,this.scale=mt().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){let t=[...this.domain];this.axisPosition==="left"&&t.reverse(),this.scale=mt().domain(t).range(this.getRange())}getScaleValue(t){return this.scale(t)}};function kt(t,e,i,s){let n=new St(s);return rt(t)?new Ae(e,i,t.categories,t.title,n):new ke(e,i,[t.min,t.max],t.title,n)}a(kt,"getAxis");var we=class{constructor(t,e,i,s){this.textDimensionCalculator=t,this.chartConfig=e,this.chartData=i,this.chartThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{a(this,"ChartTitle")}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){let e=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),i=Math.max(e.width,t.width),s=e.height+2*this.chartConfig.titlePadding;return e.width<=i&&e.height<=s&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=i,this.boundingRect.height=s,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){let t=[];return this.showChartTitle&&t.push({groupTexts:["chart-title"],type:"text",data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:"middle",horizontalPos:"center",x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),t}};function Zt(t,e,i,s){let n=new St(s);return new we(n,t,e,i)}a(Zt,"getChartTitleComponent");var Ce=.75,Se=.5,Re=.35;function wt(t){return{fontSize:t,markerSize:t*Ce,markerSpacing:t*Re,itemSpacing:t*Se}}a(wt,"getLegendLayout");var _e=class{constructor(t,e,i,s){this.textDimensionCalculator=t,this.chartConfig=e,this.chartData=i,this.chartThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.visiblePlots=[]}static{a(this,"ChartLegend")}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){if(this.visiblePlots=this.chartConfig.showLegend?this.chartData.plots.filter(p=>p.title):[],this.visiblePlots.length===0)return this.boundingRect.width=0,this.boundingRect.height=0,{width:0,height:0};let{fontSize:e,markerSize:i,markerSpacing:s,itemSpacing:n}=wt(this.chartConfig.legendFontSize),u=this.textDimensionCalculator.getMaxDimension(this.visiblePlots.map(p=>p.title),e),l=this.chartConfig.legendPadding*2+i+s+u.width,d=this.chartConfig.legendPadding*2+this.visiblePlots.length*e+(this.visiblePlots.length-1)*n;return l<=t.width&&d<=t.height?(this.boundingRect.width=l,this.boundingRect.height=d):(this.visiblePlots=[],this.boundingRect.width=0,this.boundingRect.height=0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(this.visiblePlots.length===0)return[];let{fontSize:t,markerSize:e,markerSpacing:i,itemSpacing:s}=wt(this.chartConfig.legendFontSize),n=t+s,u=this.boundingRect.x+this.chartConfig.legendPadding,l=this.boundingRect.y+this.chartConfig.legendPadding,d=[],p=[];for(let[S,R]of this.visiblePlots.entries())if(ot(R))d.push({x:u,y:l+S*n,width:e,height:e,fill:R.fill,strokeFill:R.fill,strokeWidth:0});else{let T=l+S*n+e/2;p.push({path:`M ${u},${T} L ${u+e},${T}`,strokeFill:R.strokeFill,strokeWidth:R.strokeWidth})}return[{groupTexts:["legend","markers"],type:"rect",data:d},{groupTexts:["legend","markers"],type:"path",data:p},{groupTexts:["legend","label"],type:"text",data:this.visiblePlots.map((S,R)=>({text:S.title,x:u+e+i,y:l+R*n+e/2,fill:this.chartThemeConfig.legendTextColor,fontSize:t,rotation:0,verticalPos:"middle",horizontalPos:"left"}))}]}};function Jt(t,e,i,s){let n=new St(s);return new _e(n,t,e,i)}a(Jt,"getChartLegendComponent");var Te=class{constructor(t,e,i,s,n){this.plotData=t,this.xAxis=e,this.yAxis=i,this.orientation=s,this.plotIndex=n}static{a(this,"LinePlot")}getDrawableElement(){let t=this.plotData.data.map(s=>[this.xAxis.getScaleValue(s[0]),this.yAxis.getScaleValue(s[1])]),e;if(this.orientation==="horizontal"?e=bt().y(s=>s[0]).x(s=>s[1])(t):e=bt().x(s=>s[0]).y(s=>s[1])(t),!e)return[];let i=[{groupTexts:["plot",`line-plot-${this.plotIndex}`],type:"path",data:[{path:e,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}];if(this.plotData.pointLabels&&this.plotData.pointLabels.length>0){let u=[];for(let[l,[d,p]]of t.entries()){let S=this.plotData.pointLabels[l];S&&(this.orientation==="horizontal"?u.push({x:p+10,y:d,text:S,fill:this.plotData.strokeFill,verticalPos:"middle",horizontalPos:"left",fontSize:12,rotation:0}):u.push({x:d,y:p-10,text:S,fill:this.plotData.strokeFill,verticalPos:"middle",horizontalPos:"center",fontSize:12,rotation:0}))}u.length>0&&i.push({groupTexts:["plot",`line-plot-${this.plotIndex}`,"labels"],type:"text",data:u})}return i}},De=class{constructor(t,e,i,s,n,u){this.barData=t,this.boundingRect=e,this.xAxis=i,this.yAxis=s,this.orientation=n,this.plotIndex=u}static{a(this,"BarPlot")}getDrawableElement(){let t=this.barData.data.map(n=>[this.xAxis.getScaleValue(n[0]),this.yAxis.getScaleValue(n[1])]),i=Math.min(this.xAxis.getAxisOuterPadding()*2,this.xAxis.getTickDistance())*(1-.05),s=i/2;return this.orientation==="horizontal"?[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(n=>({x:this.boundingRect.x,y:n[0]-s,height:i,width:n[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(n=>({x:n[0]-s,y:n[1],width:i,height:this.boundingRect.y+this.boundingRect.height-n[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},Pe=class{constructor(t,e,i){this.chartConfig=t,this.chartData=e,this.chartThemeConfig=i,this.boundingRect={x:0,y:0,width:0,height:0}}static{a(this,"BasePlot")}setAxes(t,e){this.xAxis=t,this.yAxis=e}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){return this.boundingRect.width=t.width,this.boundingRect.height=t.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error("Axes must be passed to render Plots");let t=[];for(let[e,i]of this.chartData.plots.entries())switch(i.type){case"line":{let s=new Te(i,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,e);t.push(...s.getDrawableElement())}break;case"bar":{let s=new De(i,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,e);t.push(...s.getDrawableElement())}break}return t}};function te(t,e,i){return new Pe(t,e,i)}a(te,"getPlotComponent");var Le=class{constructor(t,e,i,s){this.chartConfig=t,this.chartData=e,this.componentStore={title:Zt(t,e,i,s),plot:te(t,e,i),legend:Jt(t,e,i,s),xAxis:kt(e.xAxis,t.xAxis,{titleColor:i.xAxisTitleColor,labelColor:i.xAxisLabelColor,tickColor:i.xAxisTickColor,axisLineColor:i.xAxisLineColor},s),yAxis:kt(e.yAxis,t.yAxis,{titleColor:i.yAxisTitleColor,labelColor:i.yAxisLabelColor,tickColor:i.yAxisTickColor,axisLineColor:i.yAxisLineColor},s)}}static{a(this,"Orchestrator")}calculateVerticalSpace(){let t=this.chartConfig.width,e=this.chartConfig.height,i=0,s=0,n={width:0,height:0},u=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),l=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),d=this.componentStore.plot.calculateSpace({width:u,height:l});t-=d.width,e-=d.height,d=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:e}),s=d.height,e-=d.height,this.componentStore.xAxis.setAxisPosition("bottom"),d=this.componentStore.xAxis.calculateSpace({width:t,height:e}),e-=d.height,this.componentStore.yAxis.setAxisPosition("left"),d=this.componentStore.yAxis.calculateSpace({width:t,height:e}),i=d.width,t-=d.width,n=this.componentStore.legend.calculateSpace({width:t,height:l}),t-=n.width,t>0&&(u+=t,t=0),e>0&&(l+=e,e=0),this.componentStore.plot.calculateSpace({width:u,height:l}),this.componentStore.plot.setBoundingBoxXY({x:i,y:s}),this.componentStore.legend.setBoundingBoxXY({x:i+u,y:s+Math.max((l-n.height)/2,0)}),this.componentStore.xAxis.setRange([i,i+u]),this.componentStore.xAxis.setBoundingBoxXY({x:i,y:s+l}),this.componentStore.yAxis.setRange([s,s+l]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:s}),this.chartData.plots.some(p=>ot(p))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let t=this.chartConfig.width,e=this.chartConfig.height,i=0,s=0,n=0,u={width:0,height:0},l=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),d=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),p=this.componentStore.plot.calculateSpace({width:l,height:d});t-=p.width,e-=p.height,p=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:e}),i=p.height,e-=p.height,this.componentStore.xAxis.setAxisPosition("left"),p=this.componentStore.xAxis.calculateSpace({width:t,height:e}),t-=p.width,s=p.width,this.componentStore.yAxis.setAxisPosition("top"),p=this.componentStore.yAxis.calculateSpace({width:t,height:e}),e-=p.height,n=i+p.height,u=this.componentStore.legend.calculateSpace({width:t,height:d}),t-=u.width,t>0&&(l+=t,t=0),e>0&&(d+=e,e=0),this.componentStore.plot.calculateSpace({width:l,height:d}),this.componentStore.plot.setBoundingBoxXY({x:s,y:n}),this.componentStore.legend.setBoundingBoxXY({x:s+l,y:n+Math.max((d-u.height)/2,0)}),this.componentStore.yAxis.setRange([s,s+l]),this.componentStore.yAxis.setBoundingBoxXY({x:s,y:i}),this.componentStore.xAxis.setRange([n,n+d]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:n}),this.chartData.plots.some(S=>ot(S))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){this.chartConfig.chartOrientation==="horizontal"?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();let t=[];this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis);for(let e of Object.values(this.componentStore))t.push(...e.getDrawableElements());return t}},ve=class{static{a(this,"XYChartBuilder")}static build(t,e,i,s){return new Le(t,e,i,s).getDrawableElement()}},J=0,ee,tt=Tt(),et=_t(),m=Dt(),Ct=et.plotColorPalette.split(",").map(t=>t.trim()),ht=!1,Rt=!1;function _t(){let t=Ot(),e=nt();return yt(t.xyChart,e.themeVariables.xyChart)}a(_t,"getChartDefaultThemeConfig");function Tt(){let t=nt();return yt(Vt.xyChart,t.xyChart)}a(Tt,"getChartDefaultConfig");function Dt(){return{yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]}}a(Dt,"getChartDefaultData");function j(t){let e=nt();return Ft(t.trim(),e)}a(j,"textSanitizer");function ie(t){ee=t}a(ie,"setTmpSVGG");function se(t){t==="horizontal"?tt.chartOrientation="horizontal":tt.chartOrientation="vertical"}a(se,"setOrientation");function ae(t){m.xAxis.title=j(t.text)}a(ae,"setXAxisTitle");function Pt(t,e){m.xAxis={type:"linear",title:m.xAxis.title,min:t,max:e},ht=!0}a(Pt,"setXAxisRangeData");function ne(t){m.xAxis={type:"band",title:m.xAxis.title,categories:t.map(e=>j(e.text))},ht=!0}a(ne,"setXAxisBand");function oe(t){m.yAxis.title=j(t.text)}a(oe,"setYAxisTitle");function re(t,e){m.yAxis={type:"linear",title:m.yAxis.title,min:t,max:e},Rt=!0}a(re,"setYAxisRangeData");function he(t){let e=Math.min(...t),i=Math.max(...t),s=Z(m.yAxis)?m.yAxis.min:1/0,n=Z(m.yAxis)?m.yAxis.max:-1/0;m.yAxis={type:"linear",title:m.yAxis.title,min:Math.min(s,e),max:Math.max(n,i)}}a(he,"setYAxisRangeFromPlotData");function Lt(t){let e=[];if(t.length===0)return e;if(!ht){let i=Z(m.xAxis)?m.xAxis.min:1/0,s=Z(m.xAxis)?m.xAxis.max:-1/0;Pt(Math.min(i,1),Math.max(s,t.length))}if(rt(m.xAxis)&&t.length>m.xAxis.categories.length&&(t=t.slice(0,m.xAxis.categories.length)),Rt||he(t),rt(m.xAxis)&&(e=m.xAxis.categories.map((i,s)=>[i,t[s]])),Z(m.xAxis)){let i=m.xAxis.min,s=m.xAxis.max;if(t.length===1)e=[[`${i}`,t[0]]];else{let n=(s-i)/(t.length-1);e=t.map((u,l)=>[`${i+l*n}`,u])}}return e}a(Lt,"transformDataWithoutCategory");function vt(t){return Ct[t===0?0:t%Ct.length]}a(vt,"getPlotColorFromPalette");function le(t,e){let i=e.map(l=>l.value),s=e.map(l=>l.label?j(l.label):""),n=Lt(i),u=s.some(l=>l!=="");m.plots.push({type:"line",title:j(t.text),strokeFill:vt(J),strokeWidth:2,data:n,...u?{pointLabels:s}:{}}),J++}a(le,"setLineData");function ce(t,e){let i=e.map(n=>n.value),s=Lt(i);m.plots.push({type:"bar",title:j(t.text),fill:vt(J),data:s}),J++}a(ce,"setBarData");function ge(){if(m.plots.length===0)throw Error("No Plot to render, please provide a plot with some data");return m.title=ft(),ve.build(tt,m,et,ee)}a(ge,"getDrawableElem");function ue(){return et}a(ue,"getChartThemeConfig");function xe(){return tt}a(xe,"getChartConfig");function de(){return m}a(de,"getXYChartData");var Ee=a(function(){Xt(),J=0,tt=Tt(),m=Dt(),et=_t(),Ct=et.plotColorPalette.split(",").map(t=>t.trim()),ht=!1,Rt=!1},"clear"),Ie={getDrawableElem:ge,clear:Ee,setAccTitle:Nt,getAccTitle:Yt,setDiagramTitle:Ut,getDiagramTitle:ft,getAccDescription:$t,setAccDescription:Ht,setOrientation:se,setXAxisTitle:ae,setXAxisRangeData:Pt,setXAxisBand:ne,setYAxisTitle:oe,setYAxisRangeData:re,setLineData:le,setBarData:ce,setTmpSVGG:ie,getChartThemeConfig:ue,getChartConfig:xe,getXYChartData:de},Me=a((t,e,i,s)=>{let n=s.db,u=n.getChartThemeConfig(),l=n.getChartConfig(),d=n.getXYChartData().plots[0].data.map(b=>b[1]);function p(b){return b==="top"?"text-before-edge":"middle"}a(p,"getDominantBaseLine");function S(b){return b==="left"?"start":b==="right"?"end":"middle"}a(S,"getTextAnchor");function R(b){return`translate(${b.x}, ${b.y}) rotate(${b.rotation||0})`}a(R,"getTextTransformation"),dt.debug(`Rendering xychart chart
7
+ `+t);let T=Gt(e),B=T.append("g").attr("class","main"),W=B.append("rect").attr("width",l.width).attr("height",l.height).attr("class","background");Wt(T,l.height,l.width,!0),T.attr("viewBox",`0 0 ${l.width} ${l.height}`),W.attr("fill",u.backgroundColor),n.setTmpSVGG(T.append("g").attr("class","mermaid-tmp-group"));let X=n.getDrawableElem(),v={};function V(b){let E=B,c="";for(let[L]of b.entries()){let I=B;L>0&&v[c]&&(I=v[c]),c+=b[L],E=v[c],E||(E=v[c]=I.append("g").attr("class",b[L]))}return E}a(V,"getGroup");for(let b of X){if(b.data.length===0)continue;let E=V(b.groupTexts);switch(b.type){case"rect":if(E.selectAll("rect").data(b.data).enter().append("rect").attr("x",c=>c.x).attr("y",c=>c.y).attr("width",c=>c.width).attr("height",c=>c.height).attr("fill",c=>c.fill).attr("stroke",c=>c.strokeFill).attr("stroke-width",c=>c.strokeWidth),l.showDataLabel){let c=l.showDataLabelOutsideBar;if(l.chartOrientation==="horizontal"){let L=function(y,F){let{data:w,label:z}=y;return F*z.length*I<=w.width-A};var N=L;a(L,"fitsHorizontally");let I=.7,A=10,$=b.data.map((y,F)=>({data:y,label:d[F].toString()})).filter(y=>y.data.width>0&&y.data.height>0),D=$.map(y=>{let{data:F}=y,w=F.height*.7;for(;!L(y,w)&&w>0;)w-=1;return w}),Q=Math.floor(Math.min(...D)),C=a(y=>c?y.data.x+y.data.width+A:y.data.x+y.data.width-A,"determineLabelXPosition");E.selectAll("text").data($).enter().append("text").attr("x",C).attr("y",y=>y.data.y+y.data.height/2).attr("text-anchor",c?"start":"end").attr("dominant-baseline","middle").attr("fill",u.dataLabelColor).attr("font-size",`${Q}px`).text(y=>y.label)}else{let L=function(C,y,F){let{data:w,label:z}=C,h=y*z.length*.7,g=w.x+w.width/2,x=g-h/2,k=g+h/2,o=x>=w.x&&k<=w.x+w.width,U=w.y+F+y<=w.y+w.height;return o&&U};var Y=L;a(L,"fitsInBar");let I=10,A=b.data.map((C,y)=>({data:C,label:d[y].toString()})).filter(C=>C.data.width>0&&C.data.height>0),$=A.map(C=>{let{data:y,label:F}=C,w=y.width/(F.length*.7);for(;!L(C,w,I)&&w>0;)w-=1;return w}),D=Math.floor(Math.min(...$)),Q=a(C=>c?C.data.y-I:C.data.y+I,"determineLabelYPosition");E.selectAll("text").data(A).enter().append("text").attr("x",C=>C.data.x+C.data.width/2).attr("y",Q).attr("text-anchor","middle").attr("dominant-baseline",c?"auto":"hanging").attr("fill",u.dataLabelColor).attr("font-size",`${D}px`).text(C=>C.label)}}break;case"text":E.selectAll("text").data(b.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",c=>c.fill).attr("font-size",c=>c.fontSize).attr("dominant-baseline",c=>p(c.verticalPos)).attr("text-anchor",c=>S(c.horizontalPos)).attr("transform",c=>R(c)).text(c=>c.text);break;case"path":E.selectAll("path").data(b.data).enter().append("path").attr("d",c=>c.path).attr("fill",c=>c.fill?c.fill:"none").attr("stroke",c=>c.strokeFill).attr("stroke-width",c=>c.strokeWidth);break}}},"draw"),Be={draw:Me},Ge={parser:ye,db:Ie,renderer:Be};export{Ge as diagram};