Skip to content

Instantly share code, notes, and snippets.

@jaybuidl
Created October 7, 2021 12:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jaybuidl/710045b9306bcb233914f43690fa32b6 to your computer and use it in GitHub Desktop.
Save jaybuidl/710045b9306bcb233914f43690fa32b6 to your computer and use it in GitHub Desktop.
drawio_mermaid_plugin
This file has been truncated, but you can view the full file.
/*! For license information please see mermaid-plugin.webpack.js.LICENSE.txt */
(()=>{var t={9609:t=>{"use strict";var e=/^(%20|\s)*(javascript|data)/im,n=/[^\x20-\x7E]/gim,r=/^([^:]+):/gm,i=[".","/"];t.exports={sanitizeUrl:function(t){if(!t)return"about:blank";var a,o,s=t.replace(n,"").trim();return function(t){return i.indexOf(t[0])>-1}(s)?s:(o=s.match(r))?(a=o[0],e.test(a)?"about:blank":s):"about:blank"}}},4949:(t,e,n)=>{t.exports={graphlib:n(6614),dagre:n(6478),intersect:n(8114),render:n(5787),util:n(8355),version:n(5689)}},9144:(t,e,n)=>{var r=n(8355);function i(t,e,n,i){var a=t.append("marker").attr("id",e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","strokeWidth").attr("markerWidth",8).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").style("stroke-width",1).style("stroke-dasharray","1,0");r.applyStyle(a,n[i+"Style"]),n[i+"Class"]&&a.attr("class",n[i+"Class"])}t.exports={default:i,normal:i,vee:function(t,e,n,i){var a=t.append("marker").attr("id",e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","strokeWidth").attr("markerWidth",8).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 L 4 5 z").style("stroke-width",1).style("stroke-dasharray","1,0");r.applyStyle(a,n[i+"Style"]),n[i+"Class"]&&a.attr("class",n[i+"Class"])},undirected:function(t,e,n,i){var a=t.append("marker").attr("id",e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","strokeWidth").attr("markerWidth",8).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");r.applyStyle(a,n[i+"Style"]),n[i+"Class"]&&a.attr("class",n[i+"Class"])}}},5632:(t,e,n)=>{var r=n(8355),i=n(4322),a=n(1322);t.exports=function(t,e){var n,o=e.nodes().filter((function(t){return r.isSubgraph(e,t)})),s=t.selectAll("g.cluster").data(o,(function(t){return t}));return s.selectAll("*").remove(),s.enter().append("g").attr("class","cluster").attr("id",(function(t){return e.node(t).id})).style("opacity",0),s=t.selectAll("g.cluster"),r.applyTransition(s,e).style("opacity",1),s.each((function(t){var n=e.node(t),r=i.select(this);i.select(this).append("rect");var o=r.append("g").attr("class","label");a(o,n,n.clusterLabelPos)})),s.selectAll("rect").each((function(t){var n=e.node(t),a=i.select(this);r.applyStyle(a,n.style)})),n=s.exit?s.exit():s.selectAll(null),r.applyTransition(n,e).style("opacity",0).remove(),s}},6315:(t,e,n)=>{"use strict";var r=n(1034),i=n(1322),a=n(8355),o=n(4322);t.exports=function(t,e){var n,s=t.selectAll("g.edgeLabel").data(e.edges(),(function(t){return a.edgeToId(t)})).classed("update",!0);return s.exit().remove(),s.enter().append("g").classed("edgeLabel",!0).style("opacity",0),(s=t.selectAll("g.edgeLabel")).each((function(t){var n=o.select(this);n.select(".label").remove();var a=e.edge(t),s=i(n,e.edge(t),0,0).classed("label",!0),c=s.node().getBBox();a.labelId&&s.attr("id",a.labelId),r.has(a,"width")||(a.width=c.width),r.has(a,"height")||(a.height=c.height)})),n=s.exit?s.exit():s.selectAll(null),a.applyTransition(n,e).style("opacity",0).remove(),s}},940:(t,e,n)=>{"use strict";var r=n(1034),i=n(3042),a=n(8355),o=n(4322);function s(t,e){var n=(o.line||o.svg.line)().x((function(t){return t.x})).y((function(t){return t.y}));return(n.curve||n.interpolate)(t.curve),n(e)}t.exports=function(t,e,n){var c=t.selectAll("g.edgePath").data(e.edges(),(function(t){return a.edgeToId(t)})).classed("update",!0),u=function(t,e){var n=t.enter().append("g").attr("class","edgePath").style("opacity",0);return n.append("path").attr("class","path").attr("d",(function(t){var n=e.edge(t),i=e.node(t.v).elem;return s(n,r.range(n.points.length).map((function(){return e=(t=i).getBBox(),{x:(n=t.ownerSVGElement.getScreenCTM().inverse().multiply(t.getScreenCTM()).translate(e.width/2,e.height/2)).e,y:n.f};var t,e,n})))})),n.append("defs"),n}(c,e);!function(t,e){var n=t.exit();a.applyTransition(n,e).style("opacity",0).remove()}(c,e);var l=void 0!==c.merge?c.merge(u):c;return a.applyTransition(l,e).style("opacity",1),l.each((function(t){var n=o.select(this),r=e.edge(t);r.elem=this,r.id&&n.attr("id",r.id),a.applyClass(n,r.class,(n.classed("update")?"update ":"")+"edgePath")})),l.selectAll("path.path").each((function(t){var n=e.edge(t);n.arrowheadId=r.uniqueId("arrowhead");var c=o.select(this).attr("marker-end",(function(){return"url("+(t=location.href,e=n.arrowheadId,t.split("#")[0]+"#"+e+")");var t,e})).style("fill","none");a.applyTransition(c,e).attr("d",(function(t){return function(t,e){var n=t.edge(e),r=t.node(e.v),a=t.node(e.w),o=n.points.slice(1,n.points.length-1);return o.unshift(i(r,o[0])),o.push(i(a,o[o.length-1])),s(n,o)}(e,t)})),a.applyStyle(c,n.style)})),l.selectAll("defs *").remove(),l.selectAll("defs").each((function(t){var r=e.edge(t);(0,n[r.arrowhead])(o.select(this),r.arrowheadId,r,"arrowhead")})),l}},607:(t,e,n)=>{"use strict";var r=n(1034),i=n(1322),a=n(8355),o=n(4322);t.exports=function(t,e,n){var s,c=e.nodes().filter((function(t){return!a.isSubgraph(e,t)})),u=t.selectAll("g.node").data(c,(function(t){return t})).classed("update",!0);return u.exit().remove(),u.enter().append("g").attr("class","node").style("opacity",0),(u=t.selectAll("g.node")).each((function(t){var s=e.node(t),c=o.select(this);a.applyClass(c,s.class,(c.classed("update")?"update ":"")+"node"),c.select("g.label").remove();var u=c.append("g").attr("class","label"),l=i(u,s),f=n[s.shape],h=r.pick(l.node().getBBox(),"width","height");s.elem=this,s.id&&c.attr("id",s.id),s.labelId&&u.attr("id",s.labelId),r.has(s,"width")&&(h.width=s.width),r.has(s,"height")&&(h.height=s.height),h.width+=s.paddingLeft+s.paddingRight,h.height+=s.paddingTop+s.paddingBottom,u.attr("transform","translate("+(s.paddingLeft-s.paddingRight)/2+","+(s.paddingTop-s.paddingBottom)/2+")");var d=o.select(this);d.select(".label-container").remove();var p=f(d,h,s).classed("label-container",!0);a.applyStyle(p,s.style);var g=p.node().getBBox();s.width=g.width,s.height=g.height})),s=u.exit?u.exit():u.selectAll(null),a.applyTransition(s,e).style("opacity",0).remove(),u}},4322:(t,e,n)=>{var r;if(!r)try{r=n(8811)}catch(t){}r||(r=window.d3),t.exports=r},6478:(t,e,n)=>{var r;try{r=n(681)}catch(t){}r||(r=window.dagre),t.exports=r},6614:(t,e,n)=>{var r;try{r=n(8282)}catch(t){}r||(r=window.graphlib),t.exports=r},8114:(t,e,n)=>{t.exports={node:n(3042),circle:n(6587),ellipse:n(3260),polygon:n(5337),rect:n(8049)}},6587:(t,e,n)=>{var r=n(3260);t.exports=function(t,e,n){return r(t,e,e,n)}},3260:t=>{t.exports=function(t,e,n,r){var i=t.x,a=t.y,o=i-r.x,s=a-r.y,c=Math.sqrt(e*e*s*s+n*n*o*o),u=Math.abs(e*n*o/c);r.x<i&&(u=-u);var l=Math.abs(e*n*s/c);return r.y<a&&(l=-l),{x:i+u,y:a+l}}},6808:t=>{function e(t,e){return t*e>0}t.exports=function(t,n,r,i){var a,o,s,c,u,l,f,h,d,p,g,y,m;if(!(a=n.y-t.y,s=t.x-n.x,u=n.x*t.y-t.x*n.y,d=a*r.x+s*r.y+u,p=a*i.x+s*i.y+u,0!==d&&0!==p&&e(d,p)||(o=i.y-r.y,c=r.x-i.x,l=i.x*r.y-r.x*i.y,f=o*t.x+c*t.y+l,h=o*n.x+c*n.y+l,0!==f&&0!==h&&e(f,h)||0==(g=a*c-o*s))))return y=Math.abs(g/2),{x:(m=s*l-c*u)<0?(m-y)/g:(m+y)/g,y:(m=o*u-a*l)<0?(m-y)/g:(m+y)/g}}},3042:t=>{t.exports=function(t,e){return t.intersect(e)}},5337:(t,e,n)=>{var r=n(6808);t.exports=function(t,e,n){var i=t.x,a=t.y,o=[],s=Number.POSITIVE_INFINITY,c=Number.POSITIVE_INFINITY;e.forEach((function(t){s=Math.min(s,t.x),c=Math.min(c,t.y)}));for(var u=i-t.width/2-s,l=a-t.height/2-c,f=0;f<e.length;f++){var h=e[f],d=e[f<e.length-1?f+1:0],p=r(t,n,{x:u+h.x,y:l+h.y},{x:u+d.x,y:l+d.y});p&&o.push(p)}return o.length?(o.length>1&&o.sort((function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),o=e.x-n.x,s=e.y-n.y,c=Math.sqrt(o*o+s*s);return a<c?-1:a===c?0:1})),o[0]):(console.log("NO INTERSECTION FOUND, RETURN NODE CENTER",t),t)}},8049:t=>{t.exports=function(t,e){var n,r,i=t.x,a=t.y,o=e.x-i,s=e.y-a,c=t.width/2,u=t.height/2;return Math.abs(s)*c>Math.abs(o)*u?(s<0&&(u=-u),n=0===s?0:u*o/s,r=u):(o<0&&(c=-c),n=c,r=0===o?0:c*s/o),{x:i+n,y:a+r}}},8284:(t,e,n)=>{var r=n(8355);t.exports=function(t,e){var n=t.append("foreignObject").attr("width","100000"),i=n.append("xhtml:div");i.attr("xmlns","http://www.w3.org/1999/xhtml");var a=e.label;switch(typeof a){case"function":i.insert(a);break;case"object":i.insert((function(){return a}));break;default:i.html(a)}r.applyStyle(i,e.labelStyle),i.style("display","inline-block"),i.style("white-space","nowrap");var o=i.node().getBoundingClientRect();return n.attr("width",o.width).attr("height",o.height),n}},1322:(t,e,n)=>{var r=n(7318),i=n(8284),a=n(8287);t.exports=function(t,e,n){var o=e.label,s=t.append("g");"svg"===e.labelType?a(s,e):"string"!=typeof o||"html"===e.labelType?i(s,e):r(s,e);var c,u=s.node().getBBox();switch(n){case"top":c=-e.height/2;break;case"bottom":c=e.height/2-u.height;break;default:c=-u.height/2}return s.attr("transform","translate("+-u.width/2+","+c+")"),s}},8287:(t,e,n)=>{var r=n(8355);t.exports=function(t,e){var n=t;return n.node().appendChild(e.label),r.applyStyle(n,e.labelStyle),n}},7318:(t,e,n)=>{var r=n(8355);t.exports=function(t,e){for(var n=t.append("text"),i=function(t){for(var e,n="",r=!1,i=0;i<t.length;++i)e=t[i],r?(n+="n"===e?"\n":e,r=!1):"\\"===e?r=!0:n+=e;return n}(e.label).split("\n"),a=0;a<i.length;a++)n.append("tspan").attr("xml:space","preserve").attr("dy","1em").attr("x","1").text(i[a]);return r.applyStyle(n,e.labelStyle),n}},1034:(t,e,n)=>{var r;try{r={defaults:n(1747),each:n(6073),isFunction:n(3560),isPlainObject:n(8630),pick:n(9722),has:n(8721),range:n(6026),uniqueId:n(3955)}}catch(t){}r||(r=window._),t.exports=r},6381:(t,e,n)=>{"use strict";var r=n(8355),i=n(4322);t.exports=function(t,e){var n=t.filter((function(){return!i.select(this).classed("update")}));function a(t){var n=e.node(t);return"translate("+n.x+","+n.y+")"}n.attr("transform",a),r.applyTransition(t,e).style("opacity",1).attr("transform",a),r.applyTransition(n.selectAll("rect"),e).attr("width",(function(t){return e.node(t).width})).attr("height",(function(t){return e.node(t).height})).attr("x",(function(t){return-e.node(t).width/2})).attr("y",(function(t){return-e.node(t).height/2}))}},4577:(t,e,n)=>{"use strict";var r=n(8355),i=n(4322),a=n(1034);t.exports=function(t,e){function n(t){var n=e.edge(t);return a.has(n,"x")?"translate("+n.x+","+n.y+")":""}t.filter((function(){return!i.select(this).classed("update")})).attr("transform",n),r.applyTransition(t,e).style("opacity",1).attr("transform",n)}},4849:(t,e,n)=>{"use strict";var r=n(8355),i=n(4322);t.exports=function(t,e){function n(t){var n=e.node(t);return"translate("+n.x+","+n.y+")"}t.filter((function(){return!i.select(this).classed("update")})).attr("transform",n),r.applyTransition(t,e).style("opacity",1).attr("transform",n)}},5787:(t,e,n)=>{var r=n(1034),i=n(4322),a=n(6478).layout;t.exports=function(){var t=n(607),e=n(5632),i=n(6315),u=n(940),l=n(4849),f=n(4577),h=n(6381),d=n(4418),p=n(9144),g=function(n,g){!function(t){t.nodes().forEach((function(e){var n=t.node(e);r.has(n,"label")||t.children(e).length||(n.label=e),r.has(n,"paddingX")&&r.defaults(n,{paddingLeft:n.paddingX,paddingRight:n.paddingX}),r.has(n,"paddingY")&&r.defaults(n,{paddingTop:n.paddingY,paddingBottom:n.paddingY}),r.has(n,"padding")&&r.defaults(n,{paddingLeft:n.padding,paddingRight:n.padding,paddingTop:n.padding,paddingBottom:n.padding}),r.defaults(n,o),r.each(["paddingLeft","paddingRight","paddingTop","paddingBottom"],(function(t){n[t]=Number(n[t])})),r.has(n,"width")&&(n._prevWidth=n.width),r.has(n,"height")&&(n._prevHeight=n.height)})),t.edges().forEach((function(e){var n=t.edge(e);r.has(n,"label")||(n.label=""),r.defaults(n,s)}))}(g);var y=c(n,"output"),m=c(y,"clusters"),v=c(y,"edgePaths"),b=i(c(y,"edgeLabels"),g),_=t(c(y,"nodes"),g,d);a(g),l(_,g),f(b,g),u(v,g,p);var x=e(m,g);h(x,g),function(t){r.each(t.nodes(),(function(e){var n=t.node(e);r.has(n,"_prevWidth")?n.width=n._prevWidth:delete n.width,r.has(n,"_prevHeight")?n.height=n._prevHeight:delete n.height,delete n._prevWidth,delete n._prevHeight}))}(g)};return g.createNodes=function(e){return arguments.length?(t=e,g):t},g.createClusters=function(t){return arguments.length?(e=t,g):e},g.createEdgeLabels=function(t){return arguments.length?(i=t,g):i},g.createEdgePaths=function(t){return arguments.length?(u=t,g):u},g.shapes=function(t){return arguments.length?(d=t,g):d},g.arrows=function(t){return arguments.length?(p=t,g):p},g};var o={paddingLeft:10,paddingRight:10,paddingTop:10,paddingBottom:10,rx:0,ry:0,shape:"rect"},s={arrowhead:"normal",curve:i.curveLinear};function c(t,e){var n=t.select("g."+e);return n.empty()&&(n=t.append("g").attr("class",e)),n}},4418:(t,e,n)=>{"use strict";var r=n(8049),i=n(3260),a=n(6587),o=n(5337);t.exports={rect:function(t,e,n){var i=t.insert("rect",":first-child").attr("rx",n.rx).attr("ry",n.ry).attr("x",-e.width/2).attr("y",-e.height/2).attr("width",e.width).attr("height",e.height);return n.intersect=function(t){return r(n,t)},i},ellipse:function(t,e,n){var r=e.width/2,a=e.height/2,o=t.insert("ellipse",":first-child").attr("x",-e.width/2).attr("y",-e.height/2).attr("rx",r).attr("ry",a);return n.intersect=function(t){return i(n,r,a,t)},o},circle:function(t,e,n){var r=Math.max(e.width,e.height)/2,i=t.insert("circle",":first-child").attr("x",-e.width/2).attr("y",-e.height/2).attr("r",r);return n.intersect=function(t){return a(n,r,t)},i},diamond:function(t,e,n){var r=e.width*Math.SQRT2/2,i=e.height*Math.SQRT2/2,a=[{x:0,y:-i},{x:-r,y:0},{x:0,y:i},{x:r,y:0}],s=t.insert("polygon",":first-child").attr("points",a.map((function(t){return t.x+","+t.y})).join(" "));return n.intersect=function(t){return o(n,a,t)},s}}},8355:(t,e,n)=>{var r=n(1034);t.exports={isSubgraph:function(t,e){return!!t.children(e).length},edgeToId:function(t){return a(t.v)+":"+a(t.w)+":"+a(t.name)},applyStyle:function(t,e){e&&t.attr("style",e)},applyClass:function(t,e,n){e&&t.attr("class",e).attr("class",n+" "+t.attr("class"))},applyTransition:function(t,e){var n=e.graph();if(r.isPlainObject(n)){var i=n.transition;if(r.isFunction(i))return i(t)}return t}};var i=/:/g;function a(t){return t?String(t).replace(i,"\\:"):""}},5689:t=>{t.exports="0.6.4"},8811:(t,e,n)=>{"use strict";n.r(e),n.d(e,{FormatSpecifier:()=>uc,active:()=>Jr,arc:()=>hx,area:()=>vx,areaRadial:()=>Sx,ascending:()=>i,autoType:()=>Ro,axisBottom:()=>it,axisLeft:()=>at,axisRight:()=>rt,axisTop:()=>nt,bisect:()=>u,bisectLeft:()=>c,bisectRight:()=>s,bisector:()=>a,blob:()=>ms,brush:()=>Mi,brushSelection:()=>Ei,brushX:()=>Ci,brushY:()=>Si,buffer:()=>bs,chord:()=>Ri,clientPoint:()=>Nn,cluster:()=>Sd,color:()=>$e,contourDensity:()=>oo,contours:()=>to,create:()=>F_,creator:()=>ie,cross:()=>h,csv:()=>Ts,csvFormat:()=>To,csvFormatBody:()=>Eo,csvFormatRow:()=>So,csvFormatRows:()=>Co,csvFormatValue:()=>Mo,csvParse:()=>wo,csvParseRows:()=>ko,cubehelix:()=>Va,curveBasis:()=>sw,curveBasisClosed:()=>uw,curveBasisOpen:()=>fw,curveBundle:()=>dw,curveCardinal:()=>yw,curveCardinalClosed:()=>vw,curveCardinalOpen:()=>_w,curveCatmullRom:()=>kw,curveCatmullRomClosed:()=>Ew,curveCatmullRomOpen:()=>Sw,curveLinear:()=>px,curveLinearClosed:()=>Aw,curveMonotoneX:()=>Rw,curveMonotoneY:()=>Pw,curveNatural:()=>Yw,curveStep:()=>Uw,curveStepAfter:()=>Ww,curveStepBefore:()=>Vw,customEvent:()=>ye,descending:()=>d,deviation:()=>y,dispatch:()=>ht,drag:()=>po,dragDisable:()=>Se,dragEnable:()=>Me,dsv:()=>ks,dsvFormat:()=>_o,easeBack:()=>fs,easeBackIn:()=>us,easeBackInOut:()=>fs,easeBackOut:()=>ls,easeBounce:()=>os,easeBounceIn:()=>as,easeBounceInOut:()=>ss,easeBounceOut:()=>os,easeCircle:()=>rs,easeCircleIn:()=>es,easeCircleInOut:()=>rs,easeCircleOut:()=>ns,easeCubic:()=>Xr,easeCubicIn:()=>$r,easeCubicInOut:()=>Xr,easeCubicOut:()=>Gr,easeElastic:()=>ps,easeElasticIn:()=>ds,easeElasticInOut:()=>gs,easeElasticOut:()=>ps,easeExp:()=>ts,easeExpIn:()=>Qo,easeExpInOut:()=>ts,easeExpOut:()=>Jo,easeLinear:()=>Fo,easePoly:()=>Wo,easePolyIn:()=>Uo,easePolyInOut:()=>Wo,easePolyOut:()=>Vo,easeQuad:()=>qo,easeQuadIn:()=>zo,easeQuadInOut:()=>qo,easeQuadOut:()=>Yo,easeSin:()=>Zo,easeSinIn:()=>Go,easeSinInOut:()=>Zo,easeSinOut:()=>Xo,entries:()=>pa,event:()=>le,extent:()=>m,forceCenter:()=>Ds,forceCollide:()=>Hs,forceLink:()=>Xs,forceManyBody:()=>tc,forceRadial:()=>ec,forceSimulation:()=>Js,forceX:()=>nc,forceY:()=>rc,format:()=>pc,formatDefaultLocale:()=>bc,formatLocale:()=>vc,formatPrefix:()=>gc,formatSpecifier:()=>cc,geoAlbers:()=>qh,geoAlbersUsa:()=>Uh,geoArea:()=>gu,geoAzimuthalEqualArea:()=>$h,geoAzimuthalEqualAreaRaw:()=>Hh,geoAzimuthalEquidistant:()=>Xh,geoAzimuthalEquidistantRaw:()=>Gh,geoBounds:()=>sl,geoCentroid:()=>bl,geoCircle:()=>Ol,geoClipAntimeridian:()=>ql,geoClipCircle:()=>Ul,geoClipExtent:()=>$l,geoClipRectangle:()=>Hl,geoConicConformal:()=>ed,geoConicConformalRaw:()=>td,geoConicEqualArea:()=>Yh,geoConicEqualAreaRaw:()=>zh,geoConicEquidistant:()=>ad,geoConicEquidistantRaw:()=>id,geoContains:()=>gf,geoDistance:()=>of,geoEqualEarth:()=>hd,geoEqualEarthRaw:()=>fd,geoEquirectangular:()=>rd,geoEquirectangularRaw:()=>nd,geoGnomonic:()=>pd,geoGnomonicRaw:()=>dd,geoGraticule:()=>vf,geoGraticule10:()=>bf,geoIdentity:()=>gd,geoInterpolate:()=>_f,geoLength:()=>nf,geoMercator:()=>Kh,geoMercatorRaw:()=>Zh,geoNaturalEarth1:()=>md,geoNaturalEarth1Raw:()=>yd,geoOrthographic:()=>bd,geoOrthographicRaw:()=>vd,geoPath:()=>kh,geoProjection:()=>Rh,geoProjectionMutator:()=>Ph,geoRotation:()=>Sl,geoStereographic:()=>xd,geoStereographicRaw:()=>_d,geoStream:()=>nu,geoTransform:()=>Th,geoTransverseMercator:()=>kd,geoTransverseMercatorRaw:()=>wd,gray:()=>ka,hcl:()=>ja,hierarchy:()=>Ad,histogram:()=>N,hsl:()=>an,html:()=>Ns,image:()=>Cs,interpolate:()=>An,interpolateArray:()=>xn,interpolateBasis:()=>un,interpolateBasisClosed:()=>ln,interpolateBlues:()=>h_,interpolateBrBG:()=>Tb,interpolateBuGn:()=>qb,interpolateBuPu:()=>Vb,interpolateCividis:()=>k_,interpolateCool:()=>C_,interpolateCubehelix:()=>Yp,interpolateCubehelixDefault:()=>T_,interpolateCubehelixLong:()=>qp,interpolateDate:()=>kn,interpolateDiscrete:()=>Sp,interpolateGnBu:()=>Hb,interpolateGreens:()=>p_,interpolateGreys:()=>y_,interpolateHcl:()=>Pp,interpolateHclLong:()=>Fp,interpolateHsl:()=>Bp,interpolateHslLong:()=>Lp,interpolateHue:()=>Mp,interpolateInferno:()=>R_,interpolateLab:()=>Ip,interpolateMagma:()=>I_,interpolateNumber:()=>Tn,interpolateNumberArray:()=>bn,interpolateObject:()=>En,interpolateOrRd:()=>Gb,interpolateOranges:()=>w_,interpolatePRGn:()=>Cb,interpolatePiYG:()=>Mb,interpolatePlasma:()=>P_,interpolatePuBu:()=>Qb,interpolatePuBuGn:()=>Zb,interpolatePuOr:()=>Ob,interpolatePuRd:()=>t_,interpolatePurples:()=>v_,interpolateRainbow:()=>M_,interpolateRdBu:()=>jb,interpolateRdGy:()=>Bb,interpolateRdPu:()=>n_,interpolateRdYlBu:()=>Ib,interpolateRdYlGn:()=>Pb,interpolateReds:()=>__,interpolateRgb:()=>gn,interpolateRgbBasis:()=>mn,interpolateRgbBasisClosed:()=>vn,interpolateRound:()=>Ap,interpolateSinebow:()=>j_,interpolateSpectral:()=>zb,interpolateString:()=>Mn,interpolateTransformCss:()=>pr,interpolateTransformSvg:()=>gr,interpolateTurbo:()=>D_,interpolateViridis:()=>L_,interpolateWarm:()=>E_,interpolateYlGn:()=>o_,interpolateYlGnBu:()=>i_,interpolateYlOrBr:()=>c_,interpolateYlOrRd:()=>l_,interpolateZoom:()=>jp,interrupt:()=>ar,interval:()=>hk,isoFormat:()=>uk,isoParse:()=>fk,json:()=>Ms,keys:()=>ha,lab:()=>Ta,lch:()=>Na,line:()=>mx,lineRadial:()=>Cx,linkHorizontal:()=>Ix,linkRadial:()=>Px,linkVertical:()=>Rx,local:()=>Y_,map:()=>na,matcher:()=>mt,max:()=>L,mean:()=>I,median:()=>R,merge:()=>P,min:()=>F,mouse:()=>Dn,namespace:()=>Et,namespaces:()=>Tt,nest:()=>ra,now:()=>Vn,pack:()=>tp,packEnclose:()=>Ld,packSiblings:()=>Gd,pairs:()=>l,partition:()=>op,path:()=>Hi,permute:()=>z,pie:()=>xx,piecewise:()=>Up,pointRadial:()=>Mx,polygonArea:()=>Wp,polygonCentroid:()=>Hp,polygonContains:()=>Kp,polygonHull:()=>Zp,polygonLength:()=>Qp,precisionFixed:()=>_c,precisionPrefix:()=>xc,precisionRound:()=>wc,quadtree:()=>zs,quantile:()=>j,quantize:()=>Vp,radialArea:()=>Sx,radialLine:()=>Cx,randomBates:()=>ig,randomExponential:()=>ag,randomIrwinHall:()=>rg,randomLogNormal:()=>ng,randomNormal:()=>eg,randomUniform:()=>tg,range:()=>k,rgb:()=>Ke,ribbon:()=>Qi,scaleBand:()=>dg,scaleDiverging:()=>ob,scaleDivergingLog:()=>sb,scaleDivergingPow:()=>ub,scaleDivergingSqrt:()=>lb,scaleDivergingSymlog:()=>cb,scaleIdentity:()=>Ag,scaleImplicit:()=>fg,scaleLinear:()=>Mg,scaleLog:()=>Pg,scaleOrdinal:()=>hg,scalePoint:()=>gg,scalePow:()=>$g,scaleQuantile:()=>Xg,scaleQuantize:()=>Zg,scaleSequential:()=>Jv,scaleSequentialLog:()=>tb,scaleSequentialPow:()=>nb,scaleSequentialQuantile:()=>ib,scaleSequentialSqrt:()=>rb,scaleSequentialSymlog:()=>eb,scaleSqrt:()=>Gg,scaleSymlog:()=>qg,scaleThreshold:()=>Kg,scaleTime:()=>zv,scaleUtc:()=>Zv,scan:()=>Y,schemeAccent:()=>db,schemeBlues:()=>f_,schemeBrBG:()=>kb,schemeBuGn:()=>Yb,schemeBuPu:()=>Ub,schemeCategory10:()=>hb,schemeDark2:()=>pb,schemeGnBu:()=>Wb,schemeGreens:()=>d_,schemeGreys:()=>g_,schemeOrRd:()=>$b,schemeOranges:()=>x_,schemePRGn:()=>Eb,schemePaired:()=>gb,schemePastel1:()=>yb,schemePastel2:()=>mb,schemePiYG:()=>Sb,schemePuBu:()=>Kb,schemePuBuGn:()=>Xb,schemePuOr:()=>Ab,schemePuRd:()=>Jb,schemePurples:()=>m_,schemeRdBu:()=>Nb,schemeRdGy:()=>Db,schemeRdPu:()=>e_,schemeRdYlBu:()=>Lb,schemeRdYlGn:()=>Rb,schemeReds:()=>b_,schemeSet1:()=>vb,schemeSet2:()=>bb,schemeSet3:()=>_b,schemeSpectral:()=>Fb,schemeTableau10:()=>xb,schemeYlGn:()=>a_,schemeYlGnBu:()=>r_,schemeYlOrBr:()=>s_,schemeYlOrRd:()=>u_,select:()=>Te,selectAll:()=>U_,selection:()=>ke,selector:()=>pt,selectorAll:()=>yt,set:()=>fa,shuffle:()=>q,stack:()=>Xw,stackOffsetDiverging:()=>Kw,stackOffsetExpand:()=>Zw,stackOffsetNone:()=>Hw,stackOffsetSilhouette:()=>Qw,stackOffsetWiggle:()=>Jw,stackOrderAppearance:()=>tk,stackOrderAscending:()=>nk,stackOrderDescending:()=>ik,stackOrderInsideOut:()=>ak,stackOrderNone:()=>$w,stackOrderReverse:()=>ok,stratify:()=>fp,style:()=>It,sum:()=>U,svg:()=>js,symbol:()=>rw,symbolCircle:()=>Fx,symbolCross:()=>zx,symbolDiamond:()=>Ux,symbolSquare:()=>Gx,symbolStar:()=>$x,symbolTriangle:()=>Zx,symbolWye:()=>ew,symbols:()=>nw,text:()=>xs,thresholdFreedmanDiaconis:()=>D,thresholdScott:()=>B,thresholdSturges:()=>O,tickFormat:()=>Cg,tickIncrement:()=>M,tickStep:()=>A,ticks:()=>S,timeDay:()=>My,timeDays:()=>Ay,timeFormat:()=>pm,timeFormatDefaultLocale:()=>Lv,timeFormatLocale:()=>hm,timeFriday:()=>vy,timeFridays:()=>Ey,timeHour:()=>Ny,timeHours:()=>jy,timeInterval:()=>ty,timeMillisecond:()=>zy,timeMilliseconds:()=>Yy,timeMinute:()=>By,timeMinutes:()=>Ly,timeMonday:()=>py,timeMondays:()=>xy,timeMonth:()=>ay,timeMonths:()=>oy,timeParse:()=>gm,timeSaturday:()=>by,timeSaturdays:()=>Cy,timeSecond:()=>Ry,timeSeconds:()=>Py,timeSunday:()=>dy,timeSundays:()=>_y,timeThursday:()=>my,timeThursdays:()=>Ty,timeTuesday:()=>gy,timeTuesdays:()=>wy,timeWednesday:()=>yy,timeWednesdays:()=>ky,timeWeek:()=>dy,timeWeeks:()=>_y,timeYear:()=>ny,timeYears:()=>ry,timeout:()=>Qn,timer:()=>$n,timerFlush:()=>Gn,touch:()=>jn,touches:()=>V_,transition:()=>Vr,transpose:()=>V,tree:()=>vp,treemap:()=>kp,treemapBinary:()=>Tp,treemapDice:()=>ap,treemapResquarify:()=>Cp,treemapSlice:()=>bp,treemapSliceDice:()=>Ep,treemapSquarify:()=>wp,tsv:()=>Es,tsvFormat:()=>jo,tsvFormatBody:()=>Do,tsvFormatRow:()=>Lo,tsvFormatRows:()=>Bo,tsvFormatValue:()=>Io,tsvParse:()=>Oo,tsvParseRows:()=>No,utcDay:()=>im,utcDays:()=>am,utcFormat:()=>ym,utcFriday:()=>Gy,utcFridays:()=>em,utcHour:()=>Wv,utcHours:()=>Hv,utcMillisecond:()=>zy,utcMilliseconds:()=>Yy,utcMinute:()=>Gv,utcMinutes:()=>Xv,utcMonday:()=>Vy,utcMondays:()=>Ky,utcMonth:()=>qv,utcMonths:()=>Uv,utcParse:()=>mm,utcSaturday:()=>Xy,utcSaturdays:()=>nm,utcSecond:()=>Ry,utcSeconds:()=>Py,utcSunday:()=>Uy,utcSundays:()=>Zy,utcThursday:()=>$y,utcThursdays:()=>tm,utcTuesday:()=>Wy,utcTuesdays:()=>Qy,utcWednesday:()=>Hy,utcWednesdays:()=>Jy,utcWeek:()=>Uy,utcWeeks:()=>Zy,utcYear:()=>sm,utcYears:()=>cm,values:()=>da,variance:()=>g,version:()=>r,voronoi:()=>Qk,window:()=>jt,xml:()=>Os,zip:()=>H,zoom:()=>hT,zoomIdentity:()=>nT,zoomTransform:()=>rT});var r="5.16.0";function i(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}function a(t){var e;return 1===t.length&&(e=t,t=function(t,n){return i(e(t),n)}),{left:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var a=r+i>>>1;t(e[a],n)<0?r=a+1:i=a}return r},right:function(e,n,r,i){for(null==r&&(r=0),null==i&&(i=e.length);r<i;){var a=r+i>>>1;t(e[a],n)>0?i=a:r=a+1}return r}}}var o=a(i),s=o.right,c=o.left;const u=s;function l(t,e){null==e&&(e=f);for(var n=0,r=t.length-1,i=t[0],a=new Array(r<0?0:r);n<r;)a[n]=e(i,i=t[++n]);return a}function f(t,e){return[t,e]}function h(t,e,n){var r,i,a,o,s=t.length,c=e.length,u=new Array(s*c);for(null==n&&(n=f),r=a=0;r<s;++r)for(o=t[r],i=0;i<c;++i,++a)u[a]=n(o,e[i]);return u}function d(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function p(t){return null===t?NaN:+t}function g(t,e){var n,r,i=t.length,a=0,o=-1,s=0,c=0;if(null==e)for(;++o<i;)isNaN(n=p(t[o]))||(c+=(r=n-s)*(n-(s+=r/++a)));else for(;++o<i;)isNaN(n=p(e(t[o],o,t)))||(c+=(r=n-s)*(n-(s+=r/++a)));if(a>1)return c/(a-1)}function y(t,e){var n=g(t,e);return n?Math.sqrt(n):n}function m(t,e){var n,r,i,a=t.length,o=-1;if(null==e){for(;++o<a;)if(null!=(n=t[o])&&n>=n)for(r=i=n;++o<a;)null!=(n=t[o])&&(r>n&&(r=n),i<n&&(i=n))}else for(;++o<a;)if(null!=(n=e(t[o],o,t))&&n>=n)for(r=i=n;++o<a;)null!=(n=e(t[o],o,t))&&(r>n&&(r=n),i<n&&(i=n));return[r,i]}var v=Array.prototype,b=v.slice,_=v.map;function x(t){return function(){return t}}function w(t){return t}function k(t,e,n){t=+t,e=+e,n=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+n;for(var r=-1,i=0|Math.max(0,Math.ceil((e-t)/n)),a=new Array(i);++r<i;)a[r]=t+r*n;return a}var T=Math.sqrt(50),E=Math.sqrt(10),C=Math.sqrt(2);function S(t,e,n){var r,i,a,o,s=-1;if(n=+n,(t=+t)==(e=+e)&&n>0)return[t];if((r=e<t)&&(i=t,t=e,e=i),0===(o=M(t,e,n))||!isFinite(o))return[];if(o>0)for(t=Math.ceil(t/o),e=Math.floor(e/o),a=new Array(i=Math.ceil(e-t+1));++s<i;)a[s]=(t+s)*o;else for(t=Math.floor(t*o),e=Math.ceil(e*o),a=new Array(i=Math.ceil(t-e+1));++s<i;)a[s]=(t-s)/o;return r&&a.reverse(),a}function M(t,e,n){var r=(e-t)/Math.max(0,n),i=Math.floor(Math.log(r)/Math.LN10),a=r/Math.pow(10,i);return i>=0?(a>=T?10:a>=E?5:a>=C?2:1)*Math.pow(10,i):-Math.pow(10,-i)/(a>=T?10:a>=E?5:a>=C?2:1)}function A(t,e,n){var r=Math.abs(e-t)/Math.max(0,n),i=Math.pow(10,Math.floor(Math.log(r)/Math.LN10)),a=r/i;return a>=T?i*=10:a>=E?i*=5:a>=C&&(i*=2),e<t?-i:i}function O(t){return Math.ceil(Math.log(t.length)/Math.LN2)+1}function N(){var t=w,e=m,n=O;function r(r){var i,a,o=r.length,s=new Array(o);for(i=0;i<o;++i)s[i]=t(r[i],i,r);var c=e(s),l=c[0],f=c[1],h=n(s,l,f);Array.isArray(h)||(h=A(l,f,h),h=k(Math.ceil(l/h)*h,f,h));for(var d=h.length;h[0]<=l;)h.shift(),--d;for(;h[d-1]>f;)h.pop(),--d;var p,g=new Array(d+1);for(i=0;i<=d;++i)(p=g[i]=[]).x0=i>0?h[i-1]:l,p.x1=i<d?h[i]:f;for(i=0;i<o;++i)l<=(a=s[i])&&a<=f&&g[u(h,a,0,d)].push(r[i]);return g}return r.value=function(e){return arguments.length?(t="function"==typeof e?e:x(e),r):t},r.domain=function(t){return arguments.length?(e="function"==typeof t?t:x([t[0],t[1]]),r):e},r.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?x(b.call(t)):x(t),r):n},r}function j(t,e,n){if(null==n&&(n=p),r=t.length){if((e=+e)<=0||r<2)return+n(t[0],0,t);if(e>=1)return+n(t[r-1],r-1,t);var r,i=(r-1)*e,a=Math.floor(i),o=+n(t[a],a,t);return o+(+n(t[a+1],a+1,t)-o)*(i-a)}}function D(t,e,n){return t=_.call(t,p).sort(i),Math.ceil((n-e)/(2*(j(t,.75)-j(t,.25))*Math.pow(t.length,-1/3)))}function B(t,e,n){return Math.ceil((n-e)/(3.5*y(t)*Math.pow(t.length,-1/3)))}function L(t,e){var n,r,i=t.length,a=-1;if(null==e){for(;++a<i;)if(null!=(n=t[a])&&n>=n)for(r=n;++a<i;)null!=(n=t[a])&&n>r&&(r=n)}else for(;++a<i;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=n;++a<i;)null!=(n=e(t[a],a,t))&&n>r&&(r=n);return r}function I(t,e){var n,r=t.length,i=r,a=-1,o=0;if(null==e)for(;++a<r;)isNaN(n=p(t[a]))?--i:o+=n;else for(;++a<r;)isNaN(n=p(e(t[a],a,t)))?--i:o+=n;if(i)return o/i}function R(t,e){var n,r=t.length,a=-1,o=[];if(null==e)for(;++a<r;)isNaN(n=p(t[a]))||o.push(n);else for(;++a<r;)isNaN(n=p(e(t[a],a,t)))||o.push(n);return j(o.sort(i),.5)}function P(t){for(var e,n,r,i=t.length,a=-1,o=0;++a<i;)o+=t[a].length;for(n=new Array(o);--i>=0;)for(e=(r=t[i]).length;--e>=0;)n[--o]=r[e];return n}function F(t,e){var n,r,i=t.length,a=-1;if(null==e){for(;++a<i;)if(null!=(n=t[a])&&n>=n)for(r=n;++a<i;)null!=(n=t[a])&&r>n&&(r=n)}else for(;++a<i;)if(null!=(n=e(t[a],a,t))&&n>=n)for(r=n;++a<i;)null!=(n=e(t[a],a,t))&&r>n&&(r=n);return r}function z(t,e){for(var n=e.length,r=new Array(n);n--;)r[n]=t[e[n]];return r}function Y(t,e){if(n=t.length){var n,r,a=0,o=0,s=t[o];for(null==e&&(e=i);++a<n;)(e(r=t[a],s)<0||0!==e(s,s))&&(s=r,o=a);return 0===e(s,s)?o:void 0}}function q(t,e,n){for(var r,i,a=(null==n?t.length:n)-(e=null==e?0:+e);a;)i=Math.random()*a--|0,r=t[a+e],t[a+e]=t[i+e],t[i+e]=r;return t}function U(t,e){var n,r=t.length,i=-1,a=0;if(null==e)for(;++i<r;)(n=+t[i])&&(a+=n);else for(;++i<r;)(n=+e(t[i],i,t))&&(a+=n);return a}function V(t){if(!(i=t.length))return[];for(var e=-1,n=F(t,W),r=new Array(n);++e<n;)for(var i,a=-1,o=r[e]=new Array(i);++a<i;)o[a]=t[a][e];return r}function W(t){return t.length}function H(){return V(arguments)}var $=Array.prototype.slice;function G(t){return t}var X=1e-6;function Z(t){return"translate("+(t+.5)+",0)"}function K(t){return"translate(0,"+(t+.5)+")"}function Q(t){return function(e){return+t(e)}}function J(t){var e=Math.max(0,t.bandwidth()-1)/2;return t.round()&&(e=Math.round(e)),function(n){return+t(n)+e}}function tt(){return!this.__axis}function et(t,e){var n=[],r=null,i=null,a=6,o=6,s=3,c=1===t||4===t?-1:1,u=4===t||2===t?"x":"y",l=1===t||3===t?Z:K;function f(f){var h=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,d=null==i?e.tickFormat?e.tickFormat.apply(e,n):G:i,p=Math.max(a,0)+s,g=e.range(),y=+g[0]+.5,m=+g[g.length-1]+.5,v=(e.bandwidth?J:Q)(e.copy()),b=f.selection?f.selection():f,_=b.selectAll(".domain").data([null]),x=b.selectAll(".tick").data(h,e).order(),w=x.exit(),k=x.enter().append("g").attr("class","tick"),T=x.select("line"),E=x.select("text");_=_.merge(_.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),x=x.merge(k),T=T.merge(k.append("line").attr("stroke","currentColor").attr(u+"2",c*a)),E=E.merge(k.append("text").attr("fill","currentColor").attr(u,c*p).attr("dy",1===t?"0em":3===t?"0.71em":"0.32em")),f!==b&&(_=_.transition(f),x=x.transition(f),T=T.transition(f),E=E.transition(f),w=w.transition(f).attr("opacity",X).attr("transform",(function(t){return isFinite(t=v(t))?l(t):this.getAttribute("transform")})),k.attr("opacity",X).attr("transform",(function(t){var e=this.parentNode.__axis;return l(e&&isFinite(e=e(t))?e:v(t))}))),w.remove(),_.attr("d",4===t||2==t?o?"M"+c*o+","+y+"H0.5V"+m+"H"+c*o:"M0.5,"+y+"V"+m:o?"M"+y+","+c*o+"V0.5H"+m+"V"+c*o:"M"+y+",0.5H"+m),x.attr("opacity",1).attr("transform",(function(t){return l(v(t))})),T.attr(u+"2",c*a),E.attr(u,c*p).text(d),b.filter(tt).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",2===t?"start":4===t?"end":"middle"),b.each((function(){this.__axis=v}))}return f.scale=function(t){return arguments.length?(e=t,f):e},f.ticks=function(){return n=$.call(arguments),f},f.tickArguments=function(t){return arguments.length?(n=null==t?[]:$.call(t),f):n.slice()},f.tickValues=function(t){return arguments.length?(r=null==t?null:$.call(t),f):r&&r.slice()},f.tickFormat=function(t){return arguments.length?(i=t,f):i},f.tickSize=function(t){return arguments.length?(a=o=+t,f):a},f.tickSizeInner=function(t){return arguments.length?(a=+t,f):a},f.tickSizeOuter=function(t){return arguments.length?(o=+t,f):o},f.tickPadding=function(t){return arguments.length?(s=+t,f):s},f}function nt(t){return et(1,t)}function rt(t){return et(2,t)}function it(t){return et(3,t)}function at(t){return et(4,t)}var ot={value:function(){}};function st(){for(var t,e=0,n=arguments.length,r={};e<n;++e){if(!(t=arguments[e]+"")||t in r||/[\s.]/.test(t))throw new Error("illegal type: "+t);r[t]=[]}return new ct(r)}function ct(t){this._=t}function ut(t,e){return t.trim().split(/^|\s+/).map((function(t){var n="",r=t.indexOf(".");if(r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),t&&!e.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:n}}))}function lt(t,e){for(var n,r=0,i=t.length;r<i;++r)if((n=t[r]).name===e)return n.value}function ft(t,e,n){for(var r=0,i=t.length;r<i;++r)if(t[r].name===e){t[r]=ot,t=t.slice(0,r).concat(t.slice(r+1));break}return null!=n&&t.push({name:e,value:n}),t}ct.prototype=st.prototype={constructor:ct,on:function(t,e){var n,r=this._,i=ut(t+"",r),a=-1,o=i.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++a<o;)if(n=(t=i[a]).type)r[n]=ft(r[n],t.name,e);else if(null==e)for(n in r)r[n]=ft(r[n],t.name,null);return this}for(;++a<o;)if((n=(t=i[a]).type)&&(n=lt(r[n],t.name)))return n},copy:function(){var t={},e=this._;for(var n in e)t[n]=e[n].slice();return new ct(t)},call:function(t,e){if((n=arguments.length-2)>0)for(var n,r,i=new Array(n),a=0;a<n;++a)i[a]=arguments[a+2];if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(a=0,n=(r=this._[t]).length;a<n;++a)r[a].value.apply(e,i)},apply:function(t,e,n){if(!this._.hasOwnProperty(t))throw new Error("unknown type: "+t);for(var r=this._[t],i=0,a=r.length;i<a;++i)r[i].value.apply(e,n)}};const ht=st;function dt(){}function pt(t){return null==t?dt:function(){return this.querySelector(t)}}function gt(){return[]}function yt(t){return null==t?gt:function(){return this.querySelectorAll(t)}}function mt(t){return function(){return this.matches(t)}}function vt(t){return new Array(t.length)}function bt(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function _t(t,e,n,r,i,a){for(var o,s=0,c=e.length,u=a.length;s<u;++s)(o=e[s])?(o.__data__=a[s],r[s]=o):n[s]=new bt(t,a[s]);for(;s<c;++s)(o=e[s])&&(i[s]=o)}function xt(t,e,n,r,i,a,o){var s,c,u,l={},f=e.length,h=a.length,d=new Array(f);for(s=0;s<f;++s)(c=e[s])&&(d[s]=u="$"+o.call(c,c.__data__,s,e),u in l?i[s]=c:l[u]=c);for(s=0;s<h;++s)(c=l[u="$"+o.call(t,a[s],s,a)])?(r[s]=c,c.__data__=a[s],l[u]=null):n[s]=new bt(t,a[s]);for(s=0;s<f;++s)(c=e[s])&&l[d[s]]===c&&(i[s]=c)}function wt(t,e){return t<e?-1:t>e?1:t>=e?0:NaN}bt.prototype={constructor:bt,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var kt="http://www.w3.org/1999/xhtml";const Tt={svg:"http://www.w3.org/2000/svg",xhtml:kt,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Et(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),Tt.hasOwnProperty(e)?{space:Tt[e],local:t}:t}function Ct(t){return function(){this.removeAttribute(t)}}function St(t){return function(){this.removeAttributeNS(t.space,t.local)}}function Mt(t,e){return function(){this.setAttribute(t,e)}}function At(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Ot(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function Nt(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function jt(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function Dt(t){return function(){this.style.removeProperty(t)}}function Bt(t,e,n){return function(){this.style.setProperty(t,e,n)}}function Lt(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function It(t,e){return t.style.getPropertyValue(e)||jt(t).getComputedStyle(t,null).getPropertyValue(e)}function Rt(t){return function(){delete this[t]}}function Pt(t,e){return function(){this[t]=e}}function Ft(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function zt(t){return t.trim().split(/^|\s+/)}function Yt(t){return t.classList||new qt(t)}function qt(t){this._node=t,this._names=zt(t.getAttribute("class")||"")}function Ut(t,e){for(var n=Yt(t),r=-1,i=e.length;++r<i;)n.add(e[r])}function Vt(t,e){for(var n=Yt(t),r=-1,i=e.length;++r<i;)n.remove(e[r])}function Wt(t){return function(){Ut(this,t)}}function Ht(t){return function(){Vt(this,t)}}function $t(t,e){return function(){(e.apply(this,arguments)?Ut:Vt)(this,t)}}function Gt(){this.textContent=""}function Xt(t){return function(){this.textContent=t}}function Zt(t){return function(){var e=t.apply(this,arguments);this.textContent=null==e?"":e}}function Kt(){this.innerHTML=""}function Qt(t){return function(){this.innerHTML=t}}function Jt(t){return function(){var e=t.apply(this,arguments);this.innerHTML=null==e?"":e}}function te(){this.nextSibling&&this.parentNode.appendChild(this)}function ee(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function ne(t){return function(){var e=this.ownerDocument,n=this.namespaceURI;return n===kt&&e.documentElement.namespaceURI===kt?e.createElement(t):e.createElementNS(n,t)}}function re(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function ie(t){var e=Et(t);return(e.local?re:ne)(e)}function ae(){return null}function oe(){var t=this.parentNode;t&&t.removeChild(this)}function se(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function ce(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}qt.prototype={add:function(t){this._names.indexOf(t)<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var ue={},le=null;function fe(t,e,n){return t=he(t,e,n),function(e){var n=e.relatedTarget;n&&(n===this||8&n.compareDocumentPosition(this))||t.call(this,e)}}function he(t,e,n){return function(r){var i=le;le=r;try{t.call(this,this.__data__,e,n)}finally{le=i}}}function de(t){return t.trim().split(/^|\s+/).map((function(t){var e="",n=t.indexOf(".");return n>=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}function pe(t){return function(){var e=this.__on;if(e){for(var n,r=0,i=-1,a=e.length;r<a;++r)n=e[r],t.type&&n.type!==t.type||n.name!==t.name?e[++i]=n:this.removeEventListener(n.type,n.listener,n.capture);++i?e.length=i:delete this.__on}}}function ge(t,e,n){var r=ue.hasOwnProperty(t.type)?fe:he;return function(i,a,o){var s,c=this.__on,u=r(e,a,o);if(c)for(var l=0,f=c.length;l<f;++l)if((s=c[l]).type===t.type&&s.name===t.name)return this.removeEventListener(s.type,s.listener,s.capture),this.addEventListener(s.type,s.listener=u,s.capture=n),void(s.value=e);this.addEventListener(t.type,u,n),s={type:t.type,name:t.name,value:e,listener:u,capture:n},c?c.push(s):this.__on=[s]}}function ye(t,e,n,r){var i=le;t.sourceEvent=le,le=t;try{return e.apply(n,r)}finally{le=i}}function me(t,e,n){var r=jt(t),i=r.CustomEvent;"function"==typeof i?i=new i(e,n):(i=r.document.createEvent("Event"),n?(i.initEvent(e,n.bubbles,n.cancelable),i.detail=n.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function ve(t,e){return function(){return me(this,t,e)}}function be(t,e){return function(){return me(this,t,e.apply(this,arguments))}}"undefined"!=typeof document&&("onmouseenter"in document.documentElement||(ue={mouseenter:"mouseover",mouseleave:"mouseout"}));var _e=[null];function xe(t,e){this._groups=t,this._parents=e}function we(){return new xe([[document.documentElement]],_e)}xe.prototype=we.prototype={constructor:xe,select:function(t){"function"!=typeof t&&(t=pt(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var a,o,s=e[i],c=s.length,u=r[i]=new Array(c),l=0;l<c;++l)(a=s[l])&&(o=t.call(a,a.__data__,l,s))&&("__data__"in a&&(o.__data__=a.__data__),u[l]=o);return new xe(r,this._parents)},selectAll:function(t){"function"!=typeof t&&(t=yt(t));for(var e=this._groups,n=e.length,r=[],i=[],a=0;a<n;++a)for(var o,s=e[a],c=s.length,u=0;u<c;++u)(o=s[u])&&(r.push(t.call(o,o.__data__,u,s)),i.push(o));return new xe(r,i)},filter:function(t){"function"!=typeof t&&(t=mt(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var a,o=e[i],s=o.length,c=r[i]=[],u=0;u<s;++u)(a=o[u])&&t.call(a,a.__data__,u,o)&&c.push(a);return new xe(r,this._parents)},data:function(t,e){if(!t)return p=new Array(this.size()),l=-1,this.each((function(t){p[++l]=t})),p;var n,r=e?xt:_t,i=this._parents,a=this._groups;"function"!=typeof t&&(n=t,t=function(){return n});for(var o=a.length,s=new Array(o),c=new Array(o),u=new Array(o),l=0;l<o;++l){var f=i[l],h=a[l],d=h.length,p=t.call(f,f&&f.__data__,l,i),g=p.length,y=c[l]=new Array(g),m=s[l]=new Array(g);r(f,h,y,m,u[l]=new Array(d),p,e);for(var v,b,_=0,x=0;_<g;++_)if(v=y[_]){for(_>=x&&(x=_+1);!(b=m[x])&&++x<g;);v._next=b||null}}return(s=new xe(s,i))._enter=c,s._exit=u,s},enter:function(){return new xe(this._enter||this._groups.map(vt),this._parents)},exit:function(){return new xe(this._exit||this._groups.map(vt),this._parents)},join:function(t,e,n){var r=this.enter(),i=this,a=this.exit();return r="function"==typeof t?t(r):r.append(t+""),null!=e&&(i=e(i)),null==n?a.remove():n(a),r&&i?r.merge(i).order():i},merge:function(t){for(var e=this._groups,n=t._groups,r=e.length,i=n.length,a=Math.min(r,i),o=new Array(r),s=0;s<a;++s)for(var c,u=e[s],l=n[s],f=u.length,h=o[s]=new Array(f),d=0;d<f;++d)(c=u[d]||l[d])&&(h[d]=c);for(;s<r;++s)o[s]=e[s];return new xe(o,this._parents)},order:function(){for(var t=this._groups,e=-1,n=t.length;++e<n;)for(var r,i=t[e],a=i.length-1,o=i[a];--a>=0;)(r=i[a])&&(o&&4^r.compareDocumentPosition(o)&&o.parentNode.insertBefore(r,o),o=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=wt);for(var n=this._groups,r=n.length,i=new Array(r),a=0;a<r;++a){for(var o,s=n[a],c=s.length,u=i[a]=new Array(c),l=0;l<c;++l)(o=s[l])&&(u[l]=o);u.sort(e)}return new xe(i,this._parents).order()},call:function(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this},nodes:function(){var t=new Array(this.size()),e=-1;return this.each((function(){t[++e]=this})),t},node:function(){for(var t=this._groups,e=0,n=t.length;e<n;++e)for(var r=t[e],i=0,a=r.length;i<a;++i){var o=r[i];if(o)return o}return null},size:function(){var t=0;return this.each((function(){++t})),t},empty:function(){return!this.node()},each:function(t){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var i,a=e[n],o=0,s=a.length;o<s;++o)(i=a[o])&&t.call(i,i.__data__,o,a);return this},attr:function(t,e){var n=Et(t);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((null==e?n.local?St:Ct:"function"==typeof e?n.local?Nt:Ot:n.local?At:Mt)(n,e))},style:function(t,e,n){return arguments.length>1?this.each((null==e?Dt:"function"==typeof e?Lt:Bt)(t,e,null==n?"":n)):It(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?Rt:"function"==typeof e?Ft:Pt)(t,e)):this.node()[t]},classed:function(t,e){var n=zt(t+"");if(arguments.length<2){for(var r=Yt(this.node()),i=-1,a=n.length;++i<a;)if(!r.contains(n[i]))return!1;return!0}return this.each(("function"==typeof e?$t:e?Wt:Ht)(n,e))},text:function(t){return arguments.length?this.each(null==t?Gt:("function"==typeof t?Zt:Xt)(t)):this.node().textContent},html:function(t){return arguments.length?this.each(null==t?Kt:("function"==typeof t?Jt:Qt)(t)):this.node().innerHTML},raise:function(){return this.each(te)},lower:function(){return this.each(ee)},append:function(t){var e="function"==typeof t?t:ie(t);return this.select((function(){return this.appendChild(e.apply(this,arguments))}))},insert:function(t,e){var n="function"==typeof t?t:ie(t),r=null==e?ae:"function"==typeof e?e:pt(e);return this.select((function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)}))},remove:function(){return this.each(oe)},clone:function(t){return this.select(t?ce:se)},datum:function(t){return arguments.length?this.property("__data__",t):this.node().__data__},on:function(t,e,n){var r,i,a=de(t+""),o=a.length;if(!(arguments.length<2)){for(s=e?ge:pe,null==n&&(n=!1),r=0;r<o;++r)this.each(s(a[r],e,n));return this}var s=this.node().__on;if(s)for(var c,u=0,l=s.length;u<l;++u)for(r=0,c=s[u];r<o;++r)if((i=a[r]).type===c.type&&i.name===c.name)return c.value},dispatch:function(t,e){return this.each(("function"==typeof e?be:ve)(t,e))}};const ke=we;function Te(t){return"string"==typeof t?new xe([[document.querySelector(t)]],[document.documentElement]):new xe([[t]],_e)}function Ee(){le.stopImmediatePropagation()}function Ce(){le.preventDefault(),le.stopImmediatePropagation()}function Se(t){var e=t.document.documentElement,n=Te(t).on("dragstart.drag",Ce,!0);"onselectstart"in e?n.on("selectstart.drag",Ce,!0):(e.__noselect=e.style.MozUserSelect,e.style.MozUserSelect="none")}function Me(t,e){var n=t.document.documentElement,r=Te(t).on("dragstart.drag",null);e&&(r.on("click.drag",Ce,!0),setTimeout((function(){r.on("click.drag",null)}),0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}function Ae(t,e,n){t.prototype=e.prototype=n,n.constructor=t}function Oe(t,e){var n=Object.create(t.prototype);for(var r in e)n[r]=e[r];return n}function Ne(){}var je=.7,De=1/je,Be="\\s*([+-]?\\d+)\\s*",Le="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ie="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Re=/^#([0-9a-f]{3,8})$/,Pe=new RegExp("^rgb\\("+[Be,Be,Be]+"\\)$"),Fe=new RegExp("^rgb\\("+[Ie,Ie,Ie]+"\\)$"),ze=new RegExp("^rgba\\("+[Be,Be,Be,Le]+"\\)$"),Ye=new RegExp("^rgba\\("+[Ie,Ie,Ie,Le]+"\\)$"),qe=new RegExp("^hsl\\("+[Le,Ie,Ie]+"\\)$"),Ue=new RegExp("^hsla\\("+[Le,Ie,Ie,Le]+"\\)$"),Ve={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function We(){return this.rgb().formatHex()}function He(){return this.rgb().formatRgb()}function $e(t){var e,n;return t=(t+"").trim().toLowerCase(),(e=Re.exec(t))?(n=e[1].length,e=parseInt(e[1],16),6===n?Ge(e):3===n?new Qe(e>>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?Xe(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?Xe(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=Pe.exec(t))?new Qe(e[1],e[2],e[3],1):(e=Fe.exec(t))?new Qe(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=ze.exec(t))?Xe(e[1],e[2],e[3],e[4]):(e=Ye.exec(t))?Xe(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=qe.exec(t))?nn(e[1],e[2]/100,e[3]/100,1):(e=Ue.exec(t))?nn(e[1],e[2]/100,e[3]/100,e[4]):Ve.hasOwnProperty(t)?Ge(Ve[t]):"transparent"===t?new Qe(NaN,NaN,NaN,0):null}function Ge(t){return new Qe(t>>16&255,t>>8&255,255&t,1)}function Xe(t,e,n,r){return r<=0&&(t=e=n=NaN),new Qe(t,e,n,r)}function Ze(t){return t instanceof Ne||(t=$e(t)),t?new Qe((t=t.rgb()).r,t.g,t.b,t.opacity):new Qe}function Ke(t,e,n,r){return 1===arguments.length?Ze(t):new Qe(t,e,n,null==r?1:r)}function Qe(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function Je(){return"#"+en(this.r)+en(this.g)+en(this.b)}function tn(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function en(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function nn(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new on(t,e,n,r)}function rn(t){if(t instanceof on)return new on(t.h,t.s,t.l,t.opacity);if(t instanceof Ne||(t=$e(t)),!t)return new on;if(t instanceof on)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),a=Math.max(e,n,r),o=NaN,s=a-i,c=(a+i)/2;return s?(o=e===a?(n-r)/s+6*(n<r):n===a?(r-e)/s+2:(e-n)/s+4,s/=c<.5?a+i:2-a-i,o*=60):s=c>0&&c<1?0:o,new on(o,s,c,t.opacity)}function an(t,e,n,r){return 1===arguments.length?rn(t):new on(t,e,n,null==r?1:r)}function on(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function sn(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function cn(t,e,n,r,i){var a=t*t,o=a*t;return((1-3*t+3*a-o)*e+(4-6*a+3*o)*n+(1+3*t+3*a-3*o)*r+o*i)/6}function un(t){var e=t.length-1;return function(n){var r=n<=0?n=0:n>=1?(n=1,e-1):Math.floor(n*e),i=t[r],a=t[r+1],o=r>0?t[r-1]:2*i-a,s=r<e-1?t[r+2]:2*a-i;return cn((n-r/e)*e,o,i,a,s)}}function ln(t){var e=t.length;return function(n){var r=Math.floor(((n%=1)<0?++n:n)*e),i=t[(r+e-1)%e],a=t[r%e],o=t[(r+1)%e],s=t[(r+2)%e];return cn((n-r/e)*e,i,a,o,s)}}function fn(t){return function(){return t}}function hn(t,e){return function(n){return t+n*e}}function dn(t,e){var n=e-t;return n?hn(t,n>180||n<-180?n-360*Math.round(n/360):n):fn(isNaN(t)?e:t)}function pn(t,e){var n=e-t;return n?hn(t,n):fn(isNaN(t)?e:t)}Ae(Ne,$e,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:We,formatHex:We,formatHsl:function(){return rn(this).formatHsl()},formatRgb:He,toString:He}),Ae(Qe,Ke,Oe(Ne,{brighter:function(t){return t=null==t?De:Math.pow(De,t),new Qe(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?je:Math.pow(je,t),new Qe(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Je,formatHex:Je,formatRgb:tn,toString:tn})),Ae(on,an,Oe(Ne,{brighter:function(t){return t=null==t?De:Math.pow(De,t),new on(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?je:Math.pow(je,t),new on(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new Qe(sn(t>=240?t-240:t+120,i,r),sn(t,i,r),sn(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));const gn=function t(e){var n=function(t){return 1==(t=+t)?pn:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):fn(isNaN(e)?n:e)}}(e);function r(t,e){var r=n((t=Ke(t)).r,(e=Ke(e)).r),i=n(t.g,e.g),a=n(t.b,e.b),o=pn(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=a(e),t.opacity=o(e),t+""}}return r.gamma=t,r}(1);function yn(t){return function(e){var n,r,i=e.length,a=new Array(i),o=new Array(i),s=new Array(i);for(n=0;n<i;++n)r=Ke(e[n]),a[n]=r.r||0,o[n]=r.g||0,s[n]=r.b||0;return a=t(a),o=t(o),s=t(s),r.opacity=1,function(t){return r.r=a(t),r.g=o(t),r.b=s(t),r+""}}}var mn=yn(un),vn=yn(ln);function bn(t,e){e||(e=[]);var n,r=t?Math.min(e.length,t.length):0,i=e.slice();return function(a){for(n=0;n<r;++n)i[n]=t[n]*(1-a)+e[n]*a;return i}}function _n(t){return ArrayBuffer.isView(t)&&!(t instanceof DataView)}function xn(t,e){return(_n(e)?bn:wn)(t,e)}function wn(t,e){var n,r=e?e.length:0,i=t?Math.min(r,t.length):0,a=new Array(i),o=new Array(r);for(n=0;n<i;++n)a[n]=An(t[n],e[n]);for(;n<r;++n)o[n]=e[n];return function(t){for(n=0;n<i;++n)o[n]=a[n](t);return o}}function kn(t,e){var n=new Date;return t=+t,e=+e,function(r){return n.setTime(t*(1-r)+e*r),n}}function Tn(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}function En(t,e){var n,r={},i={};for(n in null!==t&&"object"==typeof t||(t={}),null!==e&&"object"==typeof e||(e={}),e)n in t?r[n]=An(t[n],e[n]):i[n]=e[n];return function(t){for(n in r)i[n]=r[n](t);return i}}var Cn=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Sn=new RegExp(Cn.source,"g");function Mn(t,e){var n,r,i,a=Cn.lastIndex=Sn.lastIndex=0,o=-1,s=[],c=[];for(t+="",e+="";(n=Cn.exec(t))&&(r=Sn.exec(e));)(i=r.index)>a&&(i=e.slice(a,i),s[o]?s[o]+=i:s[++o]=i),(n=n[0])===(r=r[0])?s[o]?s[o]+=r:s[++o]=r:(s[++o]=null,c.push({i:o,x:Tn(n,r)})),a=Sn.lastIndex;return a<e.length&&(i=e.slice(a),s[o]?s[o]+=i:s[++o]=i),s.length<2?c[0]?function(t){return function(e){return t(e)+""}}(c[0].x):function(t){return function(){return t}}(e):(e=c.length,function(t){for(var n,r=0;r<e;++r)s[(n=c[r]).i]=n.x(t);return s.join("")})}function An(t,e){var n,r=typeof e;return null==e||"boolean"===r?fn(e):("number"===r?Tn:"string"===r?(n=$e(e))?(e=n,gn):Mn:e instanceof $e?gn:e instanceof Date?kn:_n(e)?bn:Array.isArray(e)?wn:"function"!=typeof e.valueOf&&"function"!=typeof e.toString||isNaN(e)?En:Tn)(t,e)}function On(){for(var t,e=le;t=e.sourceEvent;)e=t;return e}function Nn(t,e){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}var i=t.getBoundingClientRect();return[e.clientX-i.left-t.clientLeft,e.clientY-i.top-t.clientTop]}function jn(t,e,n){arguments.length<3&&(n=e,e=On().changedTouches);for(var r,i=0,a=e?e.length:0;i<a;++i)if((r=e[i]).identifier===n)return Nn(t,r);return null}function Dn(t){var e=On();return e.changedTouches&&(e=e.changedTouches[0]),Nn(t,e)}var Bn,Ln,In=0,Rn=0,Pn=0,Fn=0,zn=0,Yn=0,qn="object"==typeof performance&&performance.now?performance:Date,Un="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function Vn(){return zn||(Un(Wn),zn=qn.now()+Yn)}function Wn(){zn=0}function Hn(){this._call=this._time=this._next=null}function $n(t,e,n){var r=new Hn;return r.restart(t,e,n),r}function Gn(){Vn(),++In;for(var t,e=Bn;e;)(t=zn-e._time)>=0&&e._call.call(null,t),e=e._next;--In}function Xn(){zn=(Fn=qn.now())+Yn,In=Rn=0;try{Gn()}finally{In=0,function(){for(var t,e,n=Bn,r=1/0;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:Bn=e);Ln=t,Kn(r)}(),zn=0}}function Zn(){var t=qn.now(),e=t-Fn;e>1e3&&(Yn-=e,Fn=t)}function Kn(t){In||(Rn&&(Rn=clearTimeout(Rn)),t-zn>24?(t<1/0&&(Rn=setTimeout(Xn,t-qn.now()-Yn)),Pn&&(Pn=clearInterval(Pn))):(Pn||(Fn=qn.now(),Pn=setInterval(Zn,1e3)),In=1,Un(Xn)))}function Qn(t,e,n){var r=new Hn;return e=null==e?0:+e,r.restart((function(n){r.stop(),t(n+e)}),e,n),r}Hn.prototype=$n.prototype={constructor:Hn,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?Vn():+n)+(null==e?0:+e),this._next||Ln===this||(Ln?Ln._next=this:Bn=this,Ln=this),this._call=t,this._time=n,Kn()},stop:function(){this._call&&(this._call=null,this._time=1/0,Kn())}};var Jn=ht("start","end","cancel","interrupt"),tr=[];function er(t,e,n,r,i,a){var o=t.__transition;if(o){if(n in o)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function a(c){var u,l,f,h;if(1!==n.state)return s();for(u in i)if((h=i[u]).name===n.name){if(3===h.state)return Qn(a);4===h.state?(h.state=6,h.timer.stop(),h.on.call("interrupt",t,t.__data__,h.index,h.group),delete i[u]):+u<e&&(h.state=6,h.timer.stop(),h.on.call("cancel",t,t.__data__,h.index,h.group),delete i[u])}if(Qn((function(){3===n.state&&(n.state=4,n.timer.restart(o,n.delay,n.time),o(c))})),n.state=2,n.on.call("start",t,t.__data__,n.index,n.group),2===n.state){for(n.state=3,r=new Array(f=n.tween.length),u=0,l=-1;u<f;++u)(h=n.tween[u].value.call(t,t.__data__,n.index,n.group))&&(r[++l]=h);r.length=l+1}}function o(e){for(var i=e<n.duration?n.ease.call(null,e/n.duration):(n.timer.restart(s),n.state=5,1),a=-1,o=r.length;++a<o;)r[a].call(t,i);5===n.state&&(n.on.call("end",t,t.__data__,n.index,n.group),s())}function s(){for(var r in n.state=6,n.timer.stop(),delete i[e],i)return;delete t.__transition}i[e]=n,n.timer=$n((function(t){n.state=1,n.timer.restart(a,n.delay,n.time),n.delay<=t&&a(t-n.delay)}),0,n.time)}(t,n,{name:e,index:r,group:i,on:Jn,tween:tr,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:0})}function nr(t,e){var n=ir(t,e);if(n.state>0)throw new Error("too late; already scheduled");return n}function rr(t,e){var n=ir(t,e);if(n.state>3)throw new Error("too late; already running");return n}function ir(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function ar(t,e){var n,r,i,a=t.__transition,o=!0;if(a){for(i in e=null==e?null:e+"",a)(n=a[i]).name===e?(r=n.state>2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete a[i]):o=!1;o&&delete t.__transition}}var or,sr,cr,ur,lr=180/Math.PI,fr={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function hr(t,e,n,r,i,a){var o,s,c;return(o=Math.sqrt(t*t+e*e))&&(t/=o,e/=o),(c=t*n+e*r)&&(n-=t*c,r-=e*c),(s=Math.sqrt(n*n+r*r))&&(n/=s,r/=s,c/=s),t*r<e*n&&(t=-t,e=-e,c=-c,o=-o),{translateX:i,translateY:a,rotate:Math.atan2(e,t)*lr,skewX:Math.atan(c)*lr,scaleX:o,scaleY:s}}function dr(t,e,n,r){function i(t){return t.length?t.pop()+" ":""}return function(a,o){var s=[],c=[];return a=t(a),o=t(o),function(t,r,i,a,o,s){if(t!==i||r!==a){var c=o.push("translate(",null,e,null,n);s.push({i:c-4,x:Tn(t,i)},{i:c-2,x:Tn(r,a)})}else(i||a)&&o.push("translate("+i+e+a+n)}(a.translateX,a.translateY,o.translateX,o.translateY,s,c),function(t,e,n,a){t!==e?(t-e>180?e+=360:e-t>180&&(t+=360),a.push({i:n.push(i(n)+"rotate(",null,r)-2,x:Tn(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(a.rotate,o.rotate,s,c),function(t,e,n,a){t!==e?a.push({i:n.push(i(n)+"skewX(",null,r)-2,x:Tn(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(a.skewX,o.skewX,s,c),function(t,e,n,r,a,o){if(t!==n||e!==r){var s=a.push(i(a)+"scale(",null,",",null,")");o.push({i:s-4,x:Tn(t,n)},{i:s-2,x:Tn(e,r)})}else 1===n&&1===r||a.push(i(a)+"scale("+n+","+r+")")}(a.scaleX,a.scaleY,o.scaleX,o.scaleY,s,c),a=o=null,function(t){for(var e,n=-1,r=c.length;++n<r;)s[(e=c[n]).i]=e.x(t);return s.join("")}}}var pr=dr((function(t){return"none"===t?fr:(or||(or=document.createElement("DIV"),sr=document.documentElement,cr=document.defaultView),or.style.transform=t,t=cr.getComputedStyle(sr.appendChild(or),null).getPropertyValue("transform"),sr.removeChild(or),hr(+(t=t.slice(7,-1).split(","))[0],+t[1],+t[2],+t[3],+t[4],+t[5]))}),"px, ","px)","deg)"),gr=dr((function(t){return null==t?fr:(ur||(ur=document.createElementNS("http://www.w3.org/2000/svg","g")),ur.setAttribute("transform",t),(t=ur.transform.baseVal.consolidate())?hr((t=t.matrix).a,t.b,t.c,t.d,t.e,t.f):fr)}),", ",")",")");function yr(t,e){var n,r;return function(){var i=rr(this,t),a=i.tween;if(a!==n)for(var o=0,s=(r=n=a).length;o<s;++o)if(r[o].name===e){(r=r.slice()).splice(o,1);break}i.tween=r}}function mr(t,e,n){var r,i;if("function"!=typeof n)throw new Error;return function(){var a=rr(this,t),o=a.tween;if(o!==r){i=(r=o).slice();for(var s={name:e,value:n},c=0,u=i.length;c<u;++c)if(i[c].name===e){i[c]=s;break}c===u&&i.push(s)}a.tween=i}}function vr(t,e,n){var r=t._id;return t.each((function(){var t=rr(this,r);(t.value||(t.value={}))[e]=n.apply(this,arguments)})),function(t){return ir(t,r).value[e]}}function br(t,e){var n;return("number"==typeof e?Tn:e instanceof $e?gn:(n=$e(e))?(e=n,gn):Mn)(t,e)}function _r(t){return function(){this.removeAttribute(t)}}function xr(t){return function(){this.removeAttributeNS(t.space,t.local)}}function wr(t,e,n){var r,i,a=n+"";return function(){var o=this.getAttribute(t);return o===a?null:o===r?i:i=e(r=o,n)}}function kr(t,e,n){var r,i,a=n+"";return function(){var o=this.getAttributeNS(t.space,t.local);return o===a?null:o===r?i:i=e(r=o,n)}}function Tr(t,e,n){var r,i,a;return function(){var o,s,c=n(this);if(null!=c)return(o=this.getAttribute(t))===(s=c+"")?null:o===r&&s===i?a:(i=s,a=e(r=o,c));this.removeAttribute(t)}}function Er(t,e,n){var r,i,a;return function(){var o,s,c=n(this);if(null!=c)return(o=this.getAttributeNS(t.space,t.local))===(s=c+"")?null:o===r&&s===i?a:(i=s,a=e(r=o,c));this.removeAttributeNS(t.space,t.local)}}function Cr(t,e){return function(n){this.setAttribute(t,e.call(this,n))}}function Sr(t,e){return function(n){this.setAttributeNS(t.space,t.local,e.call(this,n))}}function Mr(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Sr(t,i)),n}return i._value=e,i}function Ar(t,e){var n,r;function i(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Cr(t,i)),n}return i._value=e,i}function Or(t,e){return function(){nr(this,t).delay=+e.apply(this,arguments)}}function Nr(t,e){return e=+e,function(){nr(this,t).delay=e}}function jr(t,e){return function(){rr(this,t).duration=+e.apply(this,arguments)}}function Dr(t,e){return e=+e,function(){rr(this,t).duration=e}}function Br(t,e){if("function"!=typeof e)throw new Error;return function(){rr(this,t).ease=e}}function Lr(t,e,n){var r,i,a=function(t){return(t+"").trim().split(/^|\s+/).every((function(t){var e=t.indexOf(".");return e>=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?nr:rr;return function(){var o=a(this,t),s=o.on;s!==r&&(i=(r=s).copy()).on(e,n),o.on=i}}var Ir=ke.prototype.constructor;function Rr(t){return function(){this.style.removeProperty(t)}}function Pr(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}function Fr(t,e,n){var r,i;function a(){var a=e.apply(this,arguments);return a!==i&&(r=(i=a)&&Pr(t,a,n)),r}return a._value=e,a}function zr(t){return function(e){this.textContent=t.call(this,e)}}function Yr(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&zr(r)),e}return r._value=t,r}var qr=0;function Ur(t,e,n,r){this._groups=t,this._parents=e,this._name=n,this._id=r}function Vr(t){return ke().transition(t)}function Wr(){return++qr}var Hr=ke.prototype;function $r(t){return t*t*t}function Gr(t){return--t*t*t+1}function Xr(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}Ur.prototype=Vr.prototype={constructor:Ur,select:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=pt(t));for(var r=this._groups,i=r.length,a=new Array(i),o=0;o<i;++o)for(var s,c,u=r[o],l=u.length,f=a[o]=new Array(l),h=0;h<l;++h)(s=u[h])&&(c=t.call(s,s.__data__,h,u))&&("__data__"in s&&(c.__data__=s.__data__),f[h]=c,er(f[h],e,n,h,f,ir(s,n)));return new Ur(a,this._parents,e,n)},selectAll:function(t){var e=this._name,n=this._id;"function"!=typeof t&&(t=yt(t));for(var r=this._groups,i=r.length,a=[],o=[],s=0;s<i;++s)for(var c,u=r[s],l=u.length,f=0;f<l;++f)if(c=u[f]){for(var h,d=t.call(c,c.__data__,f,u),p=ir(c,n),g=0,y=d.length;g<y;++g)(h=d[g])&&er(h,e,n,g,d,p);a.push(d),o.push(c)}return new Ur(a,o,e,n)},filter:function(t){"function"!=typeof t&&(t=mt(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i<n;++i)for(var a,o=e[i],s=o.length,c=r[i]=[],u=0;u<s;++u)(a=o[u])&&t.call(a,a.__data__,u,o)&&c.push(a);return new Ur(r,this._parents,this._name,this._id)},merge:function(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,n=t._groups,r=e.length,i=n.length,a=Math.min(r,i),o=new Array(r),s=0;s<a;++s)for(var c,u=e[s],l=n[s],f=u.length,h=o[s]=new Array(f),d=0;d<f;++d)(c=u[d]||l[d])&&(h[d]=c);for(;s<r;++s)o[s]=e[s];return new Ur(o,this._parents,this._name,this._id)},selection:function(){return new Ir(this._groups,this._parents)},transition:function(){for(var t=this._name,e=this._id,n=Wr(),r=this._groups,i=r.length,a=0;a<i;++a)for(var o,s=r[a],c=s.length,u=0;u<c;++u)if(o=s[u]){var l=ir(o,e);er(o,t,n,u,s,{time:l.time+l.delay+l.duration,delay:0,duration:l.duration,ease:l.ease})}return new Ur(r,this._parents,t,n)},call:Hr.call,nodes:Hr.nodes,node:Hr.node,size:Hr.size,empty:Hr.empty,each:Hr.each,on:function(t,e){var n=this._id;return arguments.length<2?ir(this.node(),n).on.on(t):this.each(Lr(n,t,e))},attr:function(t,e){var n=Et(t),r="transform"===n?gr:br;return this.attrTween(t,"function"==typeof e?(n.local?Er:Tr)(n,r,vr(this,"attr."+t,e)):null==e?(n.local?xr:_r)(n):(n.local?kr:wr)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=Et(t);return this.tween(n,(r.local?Mr:Ar)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?pr:br;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var a=It(this,t),o=(this.style.removeProperty(t),It(this,t));return a===o?null:a===n&&o===r?i:i=e(n=a,r=o)}}(t,r)).on("end.style."+t,Rr(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,a;return function(){var o=It(this,t),s=n(this),c=s+"";return null==s&&(this.style.removeProperty(t),c=s=It(this,t)),o===c?null:o===r&&c===i?a:(i=c,a=e(r=o,s))}}(t,r,vr(this,"style."+t,e))).each(function(t,e){var n,r,i,a,o="style."+e,s="end."+o;return function(){var c=rr(this,t),u=c.on,l=null==c.value[o]?a||(a=Rr(e)):void 0;u===n&&i===l||(r=(n=u).copy()).on(s,i=l),c.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,a=n+"";return function(){var o=It(this,t);return o===a?null:o===r?i:i=e(r=o,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,Fr(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(vr(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,Yr(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=ir(this.node(),n).tween,a=0,o=i.length;a<o;++a)if((r=i[a]).name===t)return r.value;return null}return this.each((null==e?yr:mr)(n,t,e))},delay:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?Or:Nr)(e,t)):ir(this.node(),e).delay},duration:function(t){var e=this._id;return arguments.length?this.each(("function"==typeof t?jr:Dr)(e,t)):ir(this.node(),e).duration},ease:function(t){var e=this._id;return arguments.length?this.each(Br(e,t)):ir(this.node(),e).ease},end:function(){var t,e,n=this,r=n._id,i=n.size();return new Promise((function(a,o){var s={value:o},c={value:function(){0==--i&&a()}};n.each((function(){var n=rr(this,r),i=n.on;i!==t&&((e=(t=i).copy())._.cancel.push(s),e._.interrupt.push(s),e._.end.push(c)),n.on=e}))}))}};var Zr={time:null,delay:0,duration:250,ease:Xr};function Kr(t,e){for(var n;!(n=t.__transition)||!(n=n[e]);)if(!(t=t.parentNode))return Zr.time=Vn(),Zr;return n}ke.prototype.interrupt=function(t){return this.each((function(){ar(this,t)}))},ke.prototype.transition=function(t){var e,n;t instanceof Ur?(e=t._id,t=t._name):(e=Wr(),(n=Zr).time=Vn(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,a=0;a<i;++a)for(var o,s=r[a],c=s.length,u=0;u<c;++u)(o=s[u])&&er(o,t,e,u,s,n||Kr(o,e));return new Ur(r,this._parents,t,e)};var Qr=[null];function Jr(t,e){var n,r,i=t.__transition;if(i)for(r in e=null==e?null:e+"",i)if((n=i[r]).state>1&&n.name===e)return new Ur([[t]],Qr,e,+r);return null}function ti(t){return function(){return t}}function ei(t,e,n){this.target=t,this.type=e,this.selection=n}function ni(){le.stopImmediatePropagation()}function ri(){le.preventDefault(),le.stopImmediatePropagation()}var ii={name:"drag"},ai={name:"space"},oi={name:"handle"},si={name:"center"};function ci(t){return[+t[0],+t[1]]}function ui(t){return[ci(t[0]),ci(t[1])]}function li(t){return function(e){return jn(e,le.touches,t)}}var fi={name:"x",handles:["w","e"].map(bi),input:function(t,e){return null==t?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},hi={name:"y",handles:["n","s"].map(bi),input:function(t,e){return null==t?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},di={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(bi),input:function(t){return null==t?null:ui(t)},output:function(t){return t}},pi={overlay:"crosshair",selection:"move",n:"ns-resize",e:"ew-resize",s:"ns-resize",w:"ew-resize",nw:"nwse-resize",ne:"nesw-resize",se:"nwse-resize",sw:"nesw-resize"},gi={e:"w",w:"e",nw:"ne",ne:"nw",se:"sw",sw:"se"},yi={n:"s",s:"n",nw:"sw",ne:"se",se:"ne",sw:"nw"},mi={overlay:1,selection:1,n:null,e:1,s:null,w:-1,nw:-1,ne:1,se:1,sw:-1},vi={overlay:1,selection:1,n:-1,e:null,s:1,w:null,nw:-1,ne:-1,se:1,sw:1};function bi(t){return{type:t}}function _i(){return!le.ctrlKey&&!le.button}function xi(){var t=this.ownerSVGElement||this;return t.hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]}function wi(){return navigator.maxTouchPoints||"ontouchstart"in this}function ki(t){for(;!t.__brush;)if(!(t=t.parentNode))return;return t.__brush}function Ti(t){return t[0][0]===t[1][0]||t[0][1]===t[1][1]}function Ei(t){var e=t.__brush;return e?e.dim.output(e.selection):null}function Ci(){return Ai(fi)}function Si(){return Ai(hi)}function Mi(){return Ai(di)}function Ai(t){var e,n=xi,r=_i,i=wi,a=!0,o=ht("start","brush","end"),s=6;function c(e){var n=e.property("__brush",g).selectAll(".overlay").data([bi("overlay")]);n.enter().append("rect").attr("class","overlay").attr("pointer-events","all").attr("cursor",pi.overlay).merge(n).each((function(){var t=ki(this).extent;Te(this).attr("x",t[0][0]).attr("y",t[0][1]).attr("width",t[1][0]-t[0][0]).attr("height",t[1][1]-t[0][1])})),e.selectAll(".selection").data([bi("selection")]).enter().append("rect").attr("class","selection").attr("cursor",pi.selection).attr("fill","#777").attr("fill-opacity",.3).attr("stroke","#fff").attr("shape-rendering","crispEdges");var r=e.selectAll(".handle").data(t.handles,(function(t){return t.type}));r.exit().remove(),r.enter().append("rect").attr("class",(function(t){return"handle handle--"+t.type})).attr("cursor",(function(t){return pi[t.type]})),e.each(u).attr("fill","none").attr("pointer-events","all").on("mousedown.brush",h).filter(i).on("touchstart.brush",h).on("touchmove.brush",d).on("touchend.brush touchcancel.brush",p).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function u(){var t=Te(this),e=ki(this).selection;e?(t.selectAll(".selection").style("display",null).attr("x",e[0][0]).attr("y",e[0][1]).attr("width",e[1][0]-e[0][0]).attr("height",e[1][1]-e[0][1]),t.selectAll(".handle").style("display",null).attr("x",(function(t){return"e"===t.type[t.type.length-1]?e[1][0]-s/2:e[0][0]-s/2})).attr("y",(function(t){return"s"===t.type[0]?e[1][1]-s/2:e[0][1]-s/2})).attr("width",(function(t){return"n"===t.type||"s"===t.type?e[1][0]-e[0][0]+s:s})).attr("height",(function(t){return"e"===t.type||"w"===t.type?e[1][1]-e[0][1]+s:s}))):t.selectAll(".selection,.handle").style("display","none").attr("x",null).attr("y",null).attr("width",null).attr("height",null)}function l(t,e,n){var r=t.__brush.emitter;return!r||n&&r.clean?new f(t,e,n):r}function f(t,e,n){this.that=t,this.args=e,this.state=t.__brush,this.active=0,this.clean=n}function h(){if((!e||le.touches)&&r.apply(this,arguments)){var n,i,o,s,c,f,h,d,p,g,y,m=this,v=le.target.__data__.type,b="selection"===(a&&le.metaKey?v="overlay":v)?ii:a&&le.altKey?si:oi,_=t===hi?null:mi[v],x=t===fi?null:vi[v],w=ki(m),k=w.extent,T=w.selection,E=k[0][0],C=k[0][1],S=k[1][0],M=k[1][1],A=0,O=0,N=_&&x&&a&&le.shiftKey,j=le.touches?li(le.changedTouches[0].identifier):Dn,D=j(m),B=D,L=l(m,arguments,!0).beforestart();"overlay"===v?(T&&(p=!0),w.selection=T=[[n=t===hi?E:D[0],o=t===fi?C:D[1]],[c=t===hi?S:n,h=t===fi?M:o]]):(n=T[0][0],o=T[0][1],c=T[1][0],h=T[1][1]),i=n,s=o,f=c,d=h;var I=Te(m).attr("pointer-events","none"),R=I.selectAll(".overlay").attr("cursor",pi[v]);if(le.touches)L.moved=F,L.ended=Y;else{var P=Te(le.view).on("mousemove.brush",F,!0).on("mouseup.brush",Y,!0);a&&P.on("keydown.brush",q,!0).on("keyup.brush",U,!0),Se(le.view)}ni(),ar(m),u.call(m),L.start()}function F(){var t=j(m);!N||g||y||(Math.abs(t[0]-B[0])>Math.abs(t[1]-B[1])?y=!0:g=!0),B=t,p=!0,ri(),z()}function z(){var t;switch(A=B[0]-D[0],O=B[1]-D[1],b){case ai:case ii:_&&(A=Math.max(E-n,Math.min(S-c,A)),i=n+A,f=c+A),x&&(O=Math.max(C-o,Math.min(M-h,O)),s=o+O,d=h+O);break;case oi:_<0?(A=Math.max(E-n,Math.min(S-n,A)),i=n+A,f=c):_>0&&(A=Math.max(E-c,Math.min(S-c,A)),i=n,f=c+A),x<0?(O=Math.max(C-o,Math.min(M-o,O)),s=o+O,d=h):x>0&&(O=Math.max(C-h,Math.min(M-h,O)),s=o,d=h+O);break;case si:_&&(i=Math.max(E,Math.min(S,n-A*_)),f=Math.max(E,Math.min(S,c+A*_))),x&&(s=Math.max(C,Math.min(M,o-O*x)),d=Math.max(C,Math.min(M,h+O*x)))}f<i&&(_*=-1,t=n,n=c,c=t,t=i,i=f,f=t,v in gi&&R.attr("cursor",pi[v=gi[v]])),d<s&&(x*=-1,t=o,o=h,h=t,t=s,s=d,d=t,v in yi&&R.attr("cursor",pi[v=yi[v]])),w.selection&&(T=w.selection),g&&(i=T[0][0],f=T[1][0]),y&&(s=T[0][1],d=T[1][1]),T[0][0]===i&&T[0][1]===s&&T[1][0]===f&&T[1][1]===d||(w.selection=[[i,s],[f,d]],u.call(m),L.brush())}function Y(){if(ni(),le.touches){if(le.touches.length)return;e&&clearTimeout(e),e=setTimeout((function(){e=null}),500)}else Me(le.view,p),P.on("keydown.brush keyup.brush mousemove.brush mouseup.brush",null);I.attr("pointer-events","all"),R.attr("cursor",pi.overlay),w.selection&&(T=w.selection),Ti(T)&&(w.selection=null,u.call(m)),L.end()}function q(){switch(le.keyCode){case 16:N=_&&x;break;case 18:b===oi&&(_&&(c=f-A*_,n=i+A*_),x&&(h=d-O*x,o=s+O*x),b=si,z());break;case 32:b!==oi&&b!==si||(_<0?c=f-A:_>0&&(n=i-A),x<0?h=d-O:x>0&&(o=s-O),b=ai,R.attr("cursor",pi.selection),z());break;default:return}ri()}function U(){switch(le.keyCode){case 16:N&&(g=y=N=!1,z());break;case 18:b===si&&(_<0?c=f:_>0&&(n=i),x<0?h=d:x>0&&(o=s),b=oi,z());break;case 32:b===ai&&(le.altKey?(_&&(c=f-A*_,n=i+A*_),x&&(h=d-O*x,o=s+O*x),b=si):(_<0?c=f:_>0&&(n=i),x<0?h=d:x>0&&(o=s),b=oi),R.attr("cursor",pi[v]),z());break;default:return}ri()}}function d(){l(this,arguments).moved()}function p(){l(this,arguments).ended()}function g(){var e=this.__brush||{selection:null};return e.extent=ui(n.apply(this,arguments)),e.dim=t,e}return c.move=function(e,n){e.selection?e.on("start.brush",(function(){l(this,arguments).beforestart().start()})).on("interrupt.brush end.brush",(function(){l(this,arguments).end()})).tween("brush",(function(){var e=this,r=e.__brush,i=l(e,arguments),a=r.selection,o=t.input("function"==typeof n?n.apply(this,arguments):n,r.extent),s=An(a,o);function c(t){r.selection=1===t&&null===o?null:s(t),u.call(e),i.brush()}return null!==a&&null!==o?c:c(1)})):e.each((function(){var e=this,r=arguments,i=e.__brush,a=t.input("function"==typeof n?n.apply(e,r):n,i.extent),o=l(e,r).beforestart();ar(e),i.selection=null===a?null:a,u.call(e),o.start().brush().end()}))},c.clear=function(t){c.move(t,null)},f.prototype={beforestart:function(){return 1==++this.active&&(this.state.emitter=this,this.starting=!0),this},start:function(){return this.starting?(this.starting=!1,this.emit("start")):this.emit("brush"),this},brush:function(){return this.emit("brush"),this},end:function(){return 0==--this.active&&(delete this.state.emitter,this.emit("end")),this},emit:function(e){ye(new ei(c,e,t.output(this.state.selection)),o.apply,o,[e,this.that,this.args])}},c.extent=function(t){return arguments.length?(n="function"==typeof t?t:ti(ui(t)),c):n},c.filter=function(t){return arguments.length?(r="function"==typeof t?t:ti(!!t),c):r},c.touchable=function(t){return arguments.length?(i="function"==typeof t?t:ti(!!t),c):i},c.handleSize=function(t){return arguments.length?(s=+t,c):s},c.keyModifiers=function(t){return arguments.length?(a=!!t,c):a},c.on=function(){var t=o.on.apply(o,arguments);return t===o?c:t},c}var Oi=Math.cos,Ni=Math.sin,ji=Math.PI,Di=ji/2,Bi=2*ji,Li=Math.max;function Ii(t){return function(e,n){return t(e.source.value+e.target.value,n.source.value+n.target.value)}}function Ri(){var t=0,e=null,n=null,r=null;function i(i){var a,o,s,c,u,l,f=i.length,h=[],d=k(f),p=[],g=[],y=g.groups=new Array(f),m=new Array(f*f);for(a=0,u=-1;++u<f;){for(o=0,l=-1;++l<f;)o+=i[u][l];h.push(o),p.push(k(f)),a+=o}for(e&&d.sort((function(t,n){return e(h[t],h[n])})),n&&p.forEach((function(t,e){t.sort((function(t,r){return n(i[e][t],i[e][r])}))})),c=(a=Li(0,Bi-t*f)/a)?t:Bi/f,o=0,u=-1;++u<f;){for(s=o,l=-1;++l<f;){var v=d[u],b=p[v][l],_=i[v][b],x=o,w=o+=_*a;m[b*f+v]={index:v,subindex:b,startAngle:x,endAngle:w,value:_}}y[v]={index:v,startAngle:s,endAngle:o,value:h[v]},o+=c}for(u=-1;++u<f;)for(l=u-1;++l<f;){var T=m[l*f+u],E=m[u*f+l];(T.value||E.value)&&g.push(T.value<E.value?{source:E,target:T}:{source:T,target:E})}return r?g.sort(r):g}return i.padAngle=function(e){return arguments.length?(t=Li(0,e),i):t},i.sortGroups=function(t){return arguments.length?(e=t,i):e},i.sortSubgroups=function(t){return arguments.length?(n=t,i):n},i.sortChords=function(t){return arguments.length?(null==t?r=null:(r=Ii(t))._=t,i):r&&r._},i}var Pi=Array.prototype.slice;function Fi(t){return function(){return t}}var zi=Math.PI,Yi=2*zi,qi=1e-6,Ui=Yi-qi;function Vi(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function Wi(){return new Vi}Vi.prototype=Wi.prototype={constructor:Vi,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,a){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+a)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var a=this._x1,o=this._y1,s=n-t,c=r-e,u=a-t,l=o-e,f=u*u+l*l;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(f>qi)if(Math.abs(l*s-c*u)>qi&&i){var h=n-a,d=r-o,p=s*s+c*c,g=h*h+d*d,y=Math.sqrt(p),m=Math.sqrt(f),v=i*Math.tan((zi-Math.acos((p+f-g)/(2*y*m)))/2),b=v/m,_=v/y;Math.abs(b-1)>qi&&(this._+="L"+(t+b*u)+","+(e+b*l)),this._+="A"+i+","+i+",0,0,"+ +(l*h>u*d)+","+(this._x1=t+_*s)+","+(this._y1=e+_*c)}else this._+="L"+(this._x1=t)+","+(this._y1=e)},arc:function(t,e,n,r,i,a){t=+t,e=+e,a=!!a;var o=(n=+n)*Math.cos(r),s=n*Math.sin(r),c=t+o,u=e+s,l=1^a,f=a?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+c+","+u:(Math.abs(this._x1-c)>qi||Math.abs(this._y1-u)>qi)&&(this._+="L"+c+","+u),n&&(f<0&&(f=f%Yi+Yi),f>Ui?this._+="A"+n+","+n+",0,1,"+l+","+(t-o)+","+(e-s)+"A"+n+","+n+",0,1,"+l+","+(this._x1=c)+","+(this._y1=u):f>qi&&(this._+="A"+n+","+n+",0,"+ +(f>=zi)+","+l+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};const Hi=Wi;function $i(t){return t.source}function Gi(t){return t.target}function Xi(t){return t.radius}function Zi(t){return t.startAngle}function Ki(t){return t.endAngle}function Qi(){var t=$i,e=Gi,n=Xi,r=Zi,i=Ki,a=null;function o(){var o,s=Pi.call(arguments),c=t.apply(this,s),u=e.apply(this,s),l=+n.apply(this,(s[0]=c,s)),f=r.apply(this,s)-Di,h=i.apply(this,s)-Di,d=l*Oi(f),p=l*Ni(f),g=+n.apply(this,(s[0]=u,s)),y=r.apply(this,s)-Di,m=i.apply(this,s)-Di;if(a||(a=o=Hi()),a.moveTo(d,p),a.arc(0,0,l,f,h),f===y&&h===m||(a.quadraticCurveTo(0,0,g*Oi(y),g*Ni(y)),a.arc(0,0,g,y,m)),a.quadraticCurveTo(0,0,d,p),a.closePath(),o)return a=null,o+""||null}return o.radius=function(t){return arguments.length?(n="function"==typeof t?t:Fi(+t),o):n},o.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:Fi(+t),o):r},o.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:Fi(+t),o):i},o.source=function(e){return arguments.length?(t=e,o):t},o.target=function(t){return arguments.length?(e=t,o):e},o.context=function(t){return arguments.length?(a=null==t?null:t,o):a},o}var Ji="$";function ta(){}function ea(t,e){var n=new ta;if(t instanceof ta)t.each((function(t,e){n.set(e,t)}));else if(Array.isArray(t)){var r,i=-1,a=t.length;if(null==e)for(;++i<a;)n.set(i,t[i]);else for(;++i<a;)n.set(e(r=t[i],i,t),r)}else if(t)for(var o in t)n.set(o,t[o]);return n}ta.prototype=ea.prototype={constructor:ta,has:function(t){return Ji+t in this},get:function(t){return this[Ji+t]},set:function(t,e){return this[Ji+t]=e,this},remove:function(t){var e=Ji+t;return e in this&&delete this[e]},clear:function(){for(var t in this)t[0]===Ji&&delete this[t]},keys:function(){var t=[];for(var e in this)e[0]===Ji&&t.push(e.slice(1));return t},values:function(){var t=[];for(var e in this)e[0]===Ji&&t.push(this[e]);return t},entries:function(){var t=[];for(var e in this)e[0]===Ji&&t.push({key:e.slice(1),value:this[e]});return t},size:function(){var t=0;for(var e in this)e[0]===Ji&&++t;return t},empty:function(){for(var t in this)if(t[0]===Ji)return!1;return!0},each:function(t){for(var e in this)e[0]===Ji&&t(this[e],e.slice(1),this)}};const na=ea;function ra(){var t,e,n,r=[],i=[];function a(n,i,o,s){if(i>=r.length)return null!=t&&n.sort(t),null!=e?e(n):n;for(var c,u,l,f=-1,h=n.length,d=r[i++],p=na(),g=o();++f<h;)(l=p.get(c=d(u=n[f])+""))?l.push(u):p.set(c,[u]);return p.each((function(t,e){s(g,e,a(t,i,o,s))})),g}function o(t,n){if(++n>r.length)return t;var a,s=i[n-1];return null!=e&&n>=r.length?a=t.entries():(a=[],t.each((function(t,e){a.push({key:e,values:o(t,n)})}))),null!=s?a.sort((function(t,e){return s(t.key,e.key)})):a}return n={object:function(t){return a(t,0,ia,aa)},map:function(t){return a(t,0,oa,sa)},entries:function(t){return o(a(t,0,oa,sa),0)},key:function(t){return r.push(t),n},sortKeys:function(t){return i[r.length-1]=t,n},sortValues:function(e){return t=e,n},rollup:function(t){return e=t,n}}}function ia(){return{}}function aa(t,e,n){t[e]=n}function oa(){return na()}function sa(t,e,n){t.set(e,n)}function ca(){}var ua=na.prototype;function la(t,e){var n=new ca;if(t instanceof ca)t.each((function(t){n.add(t)}));else if(t){var r=-1,i=t.length;if(null==e)for(;++r<i;)n.add(t[r]);else for(;++r<i;)n.add(e(t[r],r,t))}return n}ca.prototype=la.prototype={constructor:ca,has:ua.has,add:function(t){return this[Ji+(t+="")]=t,this},remove:ua.remove,clear:ua.clear,values:ua.keys,size:ua.size,empty:ua.empty,each:ua.each};const fa=la;function ha(t){var e=[];for(var n in t)e.push(n);return e}function da(t){var e=[];for(var n in t)e.push(t[n]);return e}function pa(t){var e=[];for(var n in t)e.push({key:n,value:t[n]});return e}var ga=Math.PI/180,ya=180/Math.PI,ma=.96422,va=.82521,ba=4/29,_a=6/29,xa=3*_a*_a;function wa(t){if(t instanceof Ea)return new Ea(t.l,t.a,t.b,t.opacity);if(t instanceof Da)return Ba(t);t instanceof Qe||(t=Ze(t));var e,n,r=Aa(t.r),i=Aa(t.g),a=Aa(t.b),o=Ca((.2225045*r+.7168786*i+.0606169*a)/1);return r===i&&i===a?e=n=o:(e=Ca((.4360747*r+.3850649*i+.1430804*a)/ma),n=Ca((.0139322*r+.0971045*i+.7141733*a)/va)),new Ea(116*o-16,500*(e-o),200*(o-n),t.opacity)}function ka(t,e){return new Ea(t,0,0,null==e?1:e)}function Ta(t,e,n,r){return 1===arguments.length?wa(t):new Ea(t,e,n,null==r?1:r)}function Ea(t,e,n,r){this.l=+t,this.a=+e,this.b=+n,this.opacity=+r}function Ca(t){return t>.008856451679035631?Math.pow(t,1/3):t/xa+ba}function Sa(t){return t>_a?t*t*t:xa*(t-ba)}function Ma(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Aa(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Oa(t){if(t instanceof Da)return new Da(t.h,t.c,t.l,t.opacity);if(t instanceof Ea||(t=wa(t)),0===t.a&&0===t.b)return new Da(NaN,0<t.l&&t.l<100?0:NaN,t.l,t.opacity);var e=Math.atan2(t.b,t.a)*ya;return new Da(e<0?e+360:e,Math.sqrt(t.a*t.a+t.b*t.b),t.l,t.opacity)}function Na(t,e,n,r){return 1===arguments.length?Oa(t):new Da(n,e,t,null==r?1:r)}function ja(t,e,n,r){return 1===arguments.length?Oa(t):new Da(t,e,n,null==r?1:r)}function Da(t,e,n,r){this.h=+t,this.c=+e,this.l=+n,this.opacity=+r}function Ba(t){if(isNaN(t.h))return new Ea(t.l,0,0,t.opacity);var e=t.h*ga;return new Ea(t.l,Math.cos(e)*t.c,Math.sin(e)*t.c,t.opacity)}Ae(Ea,Ta,Oe(Ne,{brighter:function(t){return new Ea(this.l+18*(null==t?1:t),this.a,this.b,this.opacity)},darker:function(t){return new Ea(this.l-18*(null==t?1:t),this.a,this.b,this.opacity)},rgb:function(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,n=isNaN(this.b)?t:t-this.b/200;return new Qe(Ma(3.1338561*(e=ma*Sa(e))-1.6168667*(t=1*Sa(t))-.4906146*(n=va*Sa(n))),Ma(-.9787684*e+1.9161415*t+.033454*n),Ma(.0719453*e-.2289914*t+1.4052427*n),this.opacity)}})),Ae(Da,ja,Oe(Ne,{brighter:function(t){return new Da(this.h,this.c,this.l+18*(null==t?1:t),this.opacity)},darker:function(t){return new Da(this.h,this.c,this.l-18*(null==t?1:t),this.opacity)},rgb:function(){return Ba(this).rgb()}}));var La=-.14861,Ia=1.78277,Ra=-.29227,Pa=-.90649,Fa=1.97294,za=Fa*Pa,Ya=Fa*Ia,qa=Ia*Ra-Pa*La;function Ua(t){if(t instanceof Wa)return new Wa(t.h,t.s,t.l,t.opacity);t instanceof Qe||(t=Ze(t));var e=t.r/255,n=t.g/255,r=t.b/255,i=(qa*r+za*e-Ya*n)/(qa+za-Ya),a=r-i,o=(Fa*(n-i)-Ra*a)/Pa,s=Math.sqrt(o*o+a*a)/(Fa*i*(1-i)),c=s?Math.atan2(o,a)*ya-120:NaN;return new Wa(c<0?c+360:c,s,i,t.opacity)}function Va(t,e,n,r){return 1===arguments.length?Ua(t):new Wa(t,e,n,null==r?1:r)}function Wa(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}Ae(Wa,Va,Oe(Ne,{brighter:function(t){return t=null==t?De:Math.pow(De,t),new Wa(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?je:Math.pow(je,t),new Wa(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=isNaN(this.h)?0:(this.h+120)*ga,e=+this.l,n=isNaN(this.s)?0:this.s*e*(1-e),r=Math.cos(t),i=Math.sin(t);return new Qe(255*(e+n*(La*r+Ia*i)),255*(e+n*(Ra*r+Pa*i)),255*(e+n*(Fa*r)),this.opacity)}}));var Ha=Array.prototype.slice;function $a(t,e){return t-e}function Ga(t){return function(){return t}}function Xa(t,e){for(var n,r=-1,i=e.length;++r<i;)if(n=Za(t,e[r]))return n;return 0}function Za(t,e){for(var n=e[0],r=e[1],i=-1,a=0,o=t.length,s=o-1;a<o;s=a++){var c=t[a],u=c[0],l=c[1],f=t[s],h=f[0],d=f[1];if(Ka(c,f,e))return 0;l>r!=d>r&&n<(h-u)*(r-l)/(d-l)+u&&(i=-i)}return i}function Ka(t,e,n){var r,i,a,o;return function(t,e,n){return(e[0]-t[0])*(n[1]-t[1])==(n[0]-t[0])*(e[1]-t[1])}(t,e,n)&&(i=t[r=+(t[0]===e[0])],a=n[r],o=e[r],i<=a&&a<=o||o<=a&&a<=i)}function Qa(){}var Ja=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]];function to(){var t=1,e=1,n=O,r=s;function i(t){var e=n(t);if(Array.isArray(e))e=e.slice().sort($a);else{var r=m(t),i=r[0],o=r[1];e=A(i,o,e),e=k(Math.floor(i/e)*e,Math.floor(o/e)*e,e)}return e.map((function(e){return a(t,e)}))}function a(n,i){var a=[],s=[];return function(n,r,i){var a,s,c,u,l,f,h=new Array,d=new Array;for(a=s=-1,u=n[0]>=r,Ja[u<<1].forEach(p);++a<t-1;)c=u,u=n[a+1]>=r,Ja[c|u<<1].forEach(p);for(Ja[u<<0].forEach(p);++s<e-1;){for(a=-1,u=n[s*t+t]>=r,l=n[s*t]>=r,Ja[u<<1|l<<2].forEach(p);++a<t-1;)c=u,u=n[s*t+t+a+1]>=r,f=l,l=n[s*t+a+1]>=r,Ja[c|u<<1|l<<2|f<<3].forEach(p);Ja[u|l<<3].forEach(p)}for(a=-1,l=n[s*t]>=r,Ja[l<<2].forEach(p);++a<t-1;)f=l,l=n[s*t+a+1]>=r,Ja[l<<2|f<<3].forEach(p);function p(t){var e,n,r=[t[0][0]+a,t[0][1]+s],c=[t[1][0]+a,t[1][1]+s],u=o(r),l=o(c);(e=d[u])?(n=h[l])?(delete d[e.end],delete h[n.start],e===n?(e.ring.push(c),i(e.ring)):h[e.start]=d[n.end]={start:e.start,end:n.end,ring:e.ring.concat(n.ring)}):(delete d[e.end],e.ring.push(c),d[e.end=l]=e):(e=h[l])?(n=d[u])?(delete h[e.start],delete d[n.end],e===n?(e.ring.push(c),i(e.ring)):h[n.start]=d[e.end]={start:n.start,end:e.end,ring:n.ring.concat(e.ring)}):(delete h[e.start],e.ring.unshift(r),h[e.start=u]=e):h[u]=d[l]={start:u,end:l,ring:[r,c]}}Ja[l<<3].forEach(p)}(n,i,(function(t){r(t,n,i),function(t){for(var e=0,n=t.length,r=t[n-1][1]*t[0][0]-t[n-1][0]*t[0][1];++e<n;)r+=t[e-1][1]*t[e][0]-t[e-1][0]*t[e][1];return r}(t)>0?a.push([t]):s.push(t)})),s.forEach((function(t){for(var e,n=0,r=a.length;n<r;++n)if(-1!==Xa((e=a[n])[0],t))return void e.push(t)})),{type:"MultiPolygon",value:i,coordinates:a}}function o(e){return 2*e[0]+e[1]*(t+1)*4}function s(n,r,i){n.forEach((function(n){var a,o=n[0],s=n[1],c=0|o,u=0|s,l=r[u*t+c];o>0&&o<t&&c===o&&(a=r[u*t+c-1],n[0]=o+(i-a)/(l-a)-.5),s>0&&s<e&&u===s&&(a=r[(u-1)*t+c],n[1]=s+(i-a)/(l-a)-.5)}))}return i.contour=a,i.size=function(n){if(!arguments.length)return[t,e];var r=Math.ceil(n[0]),a=Math.ceil(n[1]);if(!(r>0&&a>0))throw new Error("invalid size");return t=r,e=a,i},i.thresholds=function(t){return arguments.length?(n="function"==typeof t?t:Array.isArray(t)?Ga(Ha.call(t)):Ga(t),i):n},i.smooth=function(t){return arguments.length?(r=t?s:Qa,i):r===s},i}function eo(t,e,n){for(var r=t.width,i=t.height,a=1+(n<<1),o=0;o<i;++o)for(var s=0,c=0;s<r+n;++s)s<r&&(c+=t.data[s+o*r]),s>=n&&(s>=a&&(c-=t.data[s-a+o*r]),e.data[s-n+o*r]=c/Math.min(s+1,r-1+a-s,a))}function no(t,e,n){for(var r=t.width,i=t.height,a=1+(n<<1),o=0;o<r;++o)for(var s=0,c=0;s<i+n;++s)s<i&&(c+=t.data[o+s*r]),s>=n&&(s>=a&&(c-=t.data[o+(s-a)*r]),e.data[o+(s-n)*r]=c/Math.min(s+1,i-1+a-s,a))}function ro(t){return t[0]}function io(t){return t[1]}function ao(){return 1}function oo(){var t=ro,e=io,n=ao,r=960,i=500,a=20,o=2,s=3*a,c=r+2*s>>o,u=i+2*s>>o,l=Ga(20);function f(r){var i=new Float32Array(c*u),f=new Float32Array(c*u);r.forEach((function(r,a,l){var f=+t(r,a,l)+s>>o,h=+e(r,a,l)+s>>o,d=+n(r,a,l);f>=0&&f<c&&h>=0&&h<u&&(i[f+h*c]+=d)})),eo({width:c,height:u,data:i},{width:c,height:u,data:f},a>>o),no({width:c,height:u,data:f},{width:c,height:u,data:i},a>>o),eo({width:c,height:u,data:i},{width:c,height:u,data:f},a>>o),no({width:c,height:u,data:f},{width:c,height:u,data:i},a>>o),eo({width:c,height:u,data:i},{width:c,height:u,data:f},a>>o),no({width:c,height:u,data:f},{width:c,height:u,data:i},a>>o);var d=l(i);if(!Array.isArray(d)){var p=L(i);d=A(0,p,d),(d=k(0,Math.floor(p/d)*d,d)).shift()}return to().thresholds(d).size([c,u])(i).map(h)}function h(t){return t.value*=Math.pow(2,-2*o),t.coordinates.forEach(d),t}function d(t){t.forEach(p)}function p(t){t.forEach(g)}function g(t){t[0]=t[0]*Math.pow(2,o)-s,t[1]=t[1]*Math.pow(2,o)-s}function y(){return c=r+2*(s=3*a)>>o,u=i+2*s>>o,f}return f.x=function(e){return arguments.length?(t="function"==typeof e?e:Ga(+e),f):t},f.y=function(t){return arguments.length?(e="function"==typeof t?t:Ga(+t),f):e},f.weight=function(t){return arguments.length?(n="function"==typeof t?t:Ga(+t),f):n},f.size=function(t){if(!arguments.length)return[r,i];var e=Math.ceil(t[0]),n=Math.ceil(t[1]);if(!(e>=0||e>=0))throw new Error("invalid size");return r=e,i=n,y()},f.cellSize=function(t){if(!arguments.length)return 1<<o;if(!((t=+t)>=1))throw new Error("invalid cell size");return o=Math.floor(Math.log(t)/Math.LN2),y()},f.thresholds=function(t){return arguments.length?(l="function"==typeof t?t:Array.isArray(t)?Ga(Ha.call(t)):Ga(t),f):l},f.bandwidth=function(t){if(!arguments.length)return Math.sqrt(a*(a+1));if(!((t=+t)>=0))throw new Error("invalid bandwidth");return a=Math.round((Math.sqrt(4*t*t+1)-1)/2),y()},f}function so(t){return function(){return t}}function co(t,e,n,r,i,a,o,s,c,u){this.target=t,this.type=e,this.subject=n,this.identifier=r,this.active=i,this.x=a,this.y=o,this.dx=s,this.dy=c,this._=u}function uo(){return!le.ctrlKey&&!le.button}function lo(){return this.parentNode}function fo(t){return null==t?{x:le.x,y:le.y}:t}function ho(){return navigator.maxTouchPoints||"ontouchstart"in this}function po(){var t,e,n,r,i=uo,a=lo,o=fo,s=ho,c={},u=ht("start","drag","end"),l=0,f=0;function h(t){t.on("mousedown.drag",d).filter(s).on("touchstart.drag",y).on("touchmove.drag",m).on("touchend.drag touchcancel.drag",v).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function d(){if(!r&&i.apply(this,arguments)){var o=b("mouse",a.apply(this,arguments),Dn,this,arguments);o&&(Te(le.view).on("mousemove.drag",p,!0).on("mouseup.drag",g,!0),Se(le.view),Ee(),n=!1,t=le.clientX,e=le.clientY,o("start"))}}function p(){if(Ce(),!n){var r=le.clientX-t,i=le.clientY-e;n=r*r+i*i>f}c.mouse("drag")}function g(){Te(le.view).on("mousemove.drag mouseup.drag",null),Me(le.view,n),Ce(),c.mouse("end")}function y(){if(i.apply(this,arguments)){var t,e,n=le.changedTouches,r=a.apply(this,arguments),o=n.length;for(t=0;t<o;++t)(e=b(n[t].identifier,r,jn,this,arguments))&&(Ee(),e("start"))}}function m(){var t,e,n=le.changedTouches,r=n.length;for(t=0;t<r;++t)(e=c[n[t].identifier])&&(Ce(),e("drag"))}function v(){var t,e,n=le.changedTouches,i=n.length;for(r&&clearTimeout(r),r=setTimeout((function(){r=null}),500),t=0;t<i;++t)(e=c[n[t].identifier])&&(Ee(),e("end"))}function b(t,e,n,r,i){var a,s,f,d=n(e,t),p=u.copy();if(ye(new co(h,"beforestart",a,t,l,d[0],d[1],0,0,p),(function(){return null!=(le.subject=a=o.apply(r,i))&&(s=a.x-d[0]||0,f=a.y-d[1]||0,!0)})))return function o(u){var g,y=d;switch(u){case"start":c[t]=o,g=l++;break;case"end":delete c[t],--l;case"drag":d=n(e,t),g=l}ye(new co(h,u,a,t,g,d[0]+s,d[1]+f,d[0]-y[0],d[1]-y[1],p),p.apply,p,[u,r,i])}}return h.filter=function(t){return arguments.length?(i="function"==typeof t?t:so(!!t),h):i},h.container=function(t){return arguments.length?(a="function"==typeof t?t:so(t),h):a},h.subject=function(t){return arguments.length?(o="function"==typeof t?t:so(t),h):o},h.touchable=function(t){return arguments.length?(s="function"==typeof t?t:so(!!t),h):s},h.on=function(){var t=u.on.apply(u,arguments);return t===u?h:t},h.clickDistance=function(t){return arguments.length?(f=(t=+t)*t,h):Math.sqrt(f)},h}co.prototype.on=function(){var t=this._.on.apply(this._,arguments);return t===this._?this:t};var go={},yo={};function mo(t){return new Function("d","return {"+t.map((function(t,e){return JSON.stringify(t)+": d["+e+'] || ""'})).join(",")+"}")}function vo(t){var e=Object.create(null),n=[];return t.forEach((function(t){for(var r in t)r in e||n.push(e[r]=r)})),n}function bo(t,e){var n=t+"",r=n.length;return r<e?new Array(e-r+1).join(0)+n:n}function _o(t){var e=new RegExp('["'+t+"\n\r]"),n=t.charCodeAt(0);function r(t,e){var r,i=[],a=t.length,o=0,s=0,c=a<=0,u=!1;function l(){if(c)return yo;if(u)return u=!1,go;var e,r,i=o;if(34===t.charCodeAt(i)){for(;o++<a&&34!==t.charCodeAt(o)||34===t.charCodeAt(++o););return(e=o)>=a?c=!0:10===(r=t.charCodeAt(o++))?u=!0:13===r&&(u=!0,10===t.charCodeAt(o)&&++o),t.slice(i+1,e-1).replace(/""/g,'"')}for(;o<a;){if(10===(r=t.charCodeAt(e=o++)))u=!0;else if(13===r)u=!0,10===t.charCodeAt(o)&&++o;else if(r!==n)continue;return t.slice(i,e)}return c=!0,t.slice(i,a)}for(10===t.charCodeAt(a-1)&&--a,13===t.charCodeAt(a-1)&&--a;(r=l())!==yo;){for(var f=[];r!==go&&r!==yo;)f.push(r),r=l();e&&null==(f=e(f,s++))||i.push(f)}return i}function i(e,n){return e.map((function(e){return n.map((function(t){return o(e[t])})).join(t)}))}function a(e){return e.map(o).join(t)}function o(t){return null==t?"":t instanceof Date?function(t){var e=t.getUTCHours(),n=t.getUTCMinutes(),r=t.getUTCSeconds(),i=t.getUTCMilliseconds();return isNaN(t)?"Invalid Date":function(t){return t<0?"-"+bo(-t,6):t>9999?"+"+bo(t,6):bo(t,4)}(t.getUTCFullYear())+"-"+bo(t.getUTCMonth()+1,2)+"-"+bo(t.getUTCDate(),2)+(i?"T"+bo(e,2)+":"+bo(n,2)+":"+bo(r,2)+"."+bo(i,3)+"Z":r?"T"+bo(e,2)+":"+bo(n,2)+":"+bo(r,2)+"Z":n||e?"T"+bo(e,2)+":"+bo(n,2)+"Z":"")}(t):e.test(t+="")?'"'+t.replace(/"/g,'""')+'"':t}return{parse:function(t,e){var n,i,a=r(t,(function(t,r){if(n)return n(t,r-1);i=t,n=e?function(t,e){var n=mo(t);return function(r,i){return e(n(r),i,t)}}(t,e):mo(t)}));return a.columns=i||[],a},parseRows:r,format:function(e,n){return null==n&&(n=vo(e)),[n.map(o).join(t)].concat(i(e,n)).join("\n")},formatBody:function(t,e){return null==e&&(e=vo(t)),i(t,e).join("\n")},formatRows:function(t){return t.map(a).join("\n")},formatRow:a,formatValue:o}}var xo=_o(","),wo=xo.parse,ko=xo.parseRows,To=xo.format,Eo=xo.formatBody,Co=xo.formatRows,So=xo.formatRow,Mo=xo.formatValue,Ao=_o("\t"),Oo=Ao.parse,No=Ao.parseRows,jo=Ao.format,Do=Ao.formatBody,Bo=Ao.formatRows,Lo=Ao.formatRow,Io=Ao.formatValue;function Ro(t){for(var e in t){var n,r,i=t[e].trim();if(i)if("true"===i)i=!0;else if("false"===i)i=!1;else if("NaN"===i)i=NaN;else if(isNaN(n=+i)){if(!(r=i.match(/^([-+]\d{2})?\d{4}(-\d{2}(-\d{2})?)?(T\d{2}:\d{2}(:\d{2}(\.\d{3})?)?(Z|[-+]\d{2}:\d{2})?)?$/)))continue;Po&&r[4]&&!r[7]&&(i=i.replace(/-/g,"/").replace(/T/," ")),i=new Date(i)}else i=n;else i=null;t[e]=i}return t}var Po=new Date("2019-01-01T00:00").getHours()||new Date("2019-07-01T00:00").getHours();function Fo(t){return+t}function zo(t){return t*t}function Yo(t){return t*(2-t)}function qo(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}var Uo=function t(e){function n(t){return Math.pow(t,e)}return e=+e,n.exponent=t,n}(3),Vo=function t(e){function n(t){return 1-Math.pow(1-t,e)}return e=+e,n.exponent=t,n}(3),Wo=function t(e){function n(t){return((t*=2)<=1?Math.pow(t,e):2-Math.pow(2-t,e))/2}return e=+e,n.exponent=t,n}(3),Ho=Math.PI,$o=Ho/2;function Go(t){return 1==+t?1:1-Math.cos(t*$o)}function Xo(t){return Math.sin(t*$o)}function Zo(t){return(1-Math.cos(Ho*t))/2}function Ko(t){return 1.0009775171065494*(Math.pow(2,-10*t)-.0009765625)}function Qo(t){return Ko(1-+t)}function Jo(t){return 1-Ko(t)}function ts(t){return((t*=2)<=1?Ko(1-t):2-Ko(t-1))/2}function es(t){return 1-Math.sqrt(1-t*t)}function ns(t){return Math.sqrt(1- --t*t)}function rs(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var is=7.5625;function as(t){return 1-os(1-t)}function os(t){return(t=+t)<.36363636363636365?is*t*t:t<.7272727272727273?is*(t-=.5454545454545454)*t+.75:t<.9090909090909091?is*(t-=.8181818181818182)*t+.9375:is*(t-=.9545454545454546)*t+.984375}function ss(t){return((t*=2)<=1?1-os(1-t):os(t-1)+1)/2}var cs=1.70158,us=function t(e){function n(t){return(t=+t)*t*(e*(t-1)+t)}return e=+e,n.overshoot=t,n}(cs),ls=function t(e){function n(t){return--t*t*((t+1)*e+t)+1}return e=+e,n.overshoot=t,n}(cs),fs=function t(e){function n(t){return((t*=2)<1?t*t*((e+1)*t-e):(t-=2)*t*((e+1)*t+e)+2)/2}return e=+e,n.overshoot=t,n}(cs),hs=2*Math.PI,ds=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=hs);function i(t){return e*Ko(- --t)*Math.sin((r-t)/n)}return i.amplitude=function(e){return t(e,n*hs)},i.period=function(n){return t(e,n)},i}(1,.3),ps=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=hs);function i(t){return 1-e*Ko(t=+t)*Math.sin((t+r)/n)}return i.amplitude=function(e){return t(e,n*hs)},i.period=function(n){return t(e,n)},i}(1,.3),gs=function t(e,n){var r=Math.asin(1/(e=Math.max(1,e)))*(n/=hs);function i(t){return((t=2*t-1)<0?e*Ko(-t)*Math.sin((r-t)/n):2-e*Ko(t)*Math.sin((r+t)/n))/2}return i.amplitude=function(e){return t(e,n*hs)},i.period=function(n){return t(e,n)},i}(1,.3);function ys(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.blob()}function ms(t,e){return fetch(t,e).then(ys)}function vs(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.arrayBuffer()}function bs(t,e){return fetch(t,e).then(vs)}function _s(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);return t.text()}function xs(t,e){return fetch(t,e).then(_s)}function ws(t){return function(e,n,r){return 2===arguments.length&&"function"==typeof n&&(r=n,n=void 0),xs(e,n).then((function(e){return t(e,r)}))}}function ks(t,e,n,r){3===arguments.length&&"function"==typeof n&&(r=n,n=void 0);var i=_o(t);return xs(e,n).then((function(t){return i.parse(t,r)}))}var Ts=ws(wo),Es=ws(Oo);function Cs(t,e){return new Promise((function(n,r){var i=new Image;for(var a in e)i[a]=e[a];i.onerror=r,i.onload=function(){n(i)},i.src=t}))}function Ss(t){if(!t.ok)throw new Error(t.status+" "+t.statusText);if(204!==t.status&&205!==t.status)return t.json()}function Ms(t,e){return fetch(t,e).then(Ss)}function As(t){return function(e,n){return xs(e,n).then((function(e){return(new DOMParser).parseFromString(e,t)}))}}const Os=As("application/xml");var Ns=As("text/html"),js=As("image/svg+xml");function Ds(t,e){var n;function r(){var r,i,a=n.length,o=0,s=0;for(r=0;r<a;++r)o+=(i=n[r]).x,s+=i.y;for(o=o/a-t,s=s/a-e,r=0;r<a;++r)(i=n[r]).x-=o,i.y-=s}return null==t&&(t=0),null==e&&(e=0),r.initialize=function(t){n=t},r.x=function(e){return arguments.length?(t=+e,r):t},r.y=function(t){return arguments.length?(e=+t,r):e},r}function Bs(t){return function(){return t}}function Ls(){return 1e-6*(Math.random()-.5)}function Is(t,e,n,r){if(isNaN(e)||isNaN(n))return t;var i,a,o,s,c,u,l,f,h,d=t._root,p={data:r},g=t._x0,y=t._y0,m=t._x1,v=t._y1;if(!d)return t._root=p,t;for(;d.length;)if((u=e>=(a=(g+m)/2))?g=a:m=a,(l=n>=(o=(y+v)/2))?y=o:v=o,i=d,!(d=d[f=l<<1|u]))return i[f]=p,t;if(s=+t._x.call(null,d.data),c=+t._y.call(null,d.data),e===s&&n===c)return p.next=d,i?i[f]=p:t._root=p,t;do{i=i?i[f]=new Array(4):t._root=new Array(4),(u=e>=(a=(g+m)/2))?g=a:m=a,(l=n>=(o=(y+v)/2))?y=o:v=o}while((f=l<<1|u)==(h=(c>=o)<<1|s>=a));return i[h]=d,i[f]=p,t}function Rs(t,e,n,r,i){this.node=t,this.x0=e,this.y0=n,this.x1=r,this.y1=i}function Ps(t){return t[0]}function Fs(t){return t[1]}function zs(t,e,n){var r=new Ys(null==e?Ps:e,null==n?Fs:n,NaN,NaN,NaN,NaN);return null==t?r:r.addAll(t)}function Ys(t,e,n,r,i,a){this._x=t,this._y=e,this._x0=n,this._y0=r,this._x1=i,this._y1=a,this._root=void 0}function qs(t){for(var e={data:t.data},n=e;t=t.next;)n=n.next={data:t.data};return e}var Us=zs.prototype=Ys.prototype;function Vs(t){return t.x+t.vx}function Ws(t){return t.y+t.vy}function Hs(t){var e,n,r=1,i=1;function a(){for(var t,a,s,c,u,l,f,h=e.length,d=0;d<i;++d)for(a=zs(e,Vs,Ws).visitAfter(o),t=0;t<h;++t)s=e[t],l=n[s.index],f=l*l,c=s.x+s.vx,u=s.y+s.vy,a.visit(p);function p(t,e,n,i,a){var o=t.data,h=t.r,d=l+h;if(!o)return e>c+d||i<c-d||n>u+d||a<u-d;if(o.index>s.index){var p=c-o.x-o.vx,g=u-o.y-o.vy,y=p*p+g*g;y<d*d&&(0===p&&(y+=(p=Ls())*p),0===g&&(y+=(g=Ls())*g),y=(d-(y=Math.sqrt(y)))/y*r,s.vx+=(p*=y)*(d=(h*=h)/(f+h)),s.vy+=(g*=y)*d,o.vx-=p*(d=1-d),o.vy-=g*d)}}}function o(t){if(t.data)return t.r=n[t.data.index];for(var e=t.r=0;e<4;++e)t[e]&&t[e].r>t.r&&(t.r=t[e].r)}function s(){if(e){var r,i,a=e.length;for(n=new Array(a),r=0;r<a;++r)i=e[r],n[i.index]=+t(i,r,e)}}return"function"!=typeof t&&(t=Bs(null==t?1:+t)),a.initialize=function(t){e=t,s()},a.iterations=function(t){return arguments.length?(i=+t,a):i},a.strength=function(t){return arguments.length?(r=+t,a):r},a.radius=function(e){return arguments.length?(t="function"==typeof e?e:Bs(+e),s(),a):t},a}function $s(t){return t.index}function Gs(t,e){var n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function Xs(t){var e,n,r,i,a,o=$s,s=function(t){return 1/Math.min(i[t.source.index],i[t.target.index])},c=Bs(30),u=1;function l(r){for(var i=0,o=t.length;i<u;++i)for(var s,c,l,f,h,d,p,g=0;g<o;++g)c=(s=t[g]).source,f=(l=s.target).x+l.vx-c.x-c.vx||Ls(),h=l.y+l.vy-c.y-c.vy||Ls(),f*=d=((d=Math.sqrt(f*f+h*h))-n[g])/d*r*e[g],h*=d,l.vx-=f*(p=a[g]),l.vy-=h*p,c.vx+=f*(p=1-p),c.vy+=h*p}function f(){if(r){var s,c,u=r.length,l=t.length,f=na(r,o);for(s=0,i=new Array(u);s<l;++s)(c=t[s]).index=s,"object"!=typeof c.source&&(c.source=Gs(f,c.source)),"object"!=typeof c.target&&(c.target=Gs(f,c.target)),i[c.source.index]=(i[c.source.index]||0)+1,i[c.target.index]=(i[c.target.index]||0)+1;for(s=0,a=new Array(l);s<l;++s)c=t[s],a[s]=i[c.source.index]/(i[c.source.index]+i[c.target.index]);e=new Array(l),h(),n=new Array(l),d()}}function h(){if(r)for(var n=0,i=t.length;n<i;++n)e[n]=+s(t[n],n,t)}function d(){if(r)for(var e=0,i=t.length;e<i;++e)n[e]=+c(t[e],e,t)}return null==t&&(t=[]),l.initialize=function(t){r=t,f()},l.links=function(e){return arguments.length?(t=e,f(),l):t},l.id=function(t){return arguments.length?(o=t,l):o},l.iterations=function(t){return arguments.length?(u=+t,l):u},l.strength=function(t){return arguments.length?(s="function"==typeof t?t:Bs(+t),h(),l):s},l.distance=function(t){return arguments.length?(c="function"==typeof t?t:Bs(+t),d(),l):c},l}function Zs(t){return t.x}function Ks(t){return t.y}Us.copy=function(){var t,e,n=new Ys(this._x,this._y,this._x0,this._y0,this._x1,this._y1),r=this._root;if(!r)return n;if(!r.length)return n._root=qs(r),n;for(t=[{source:r,target:n._root=new Array(4)}];r=t.pop();)for(var i=0;i<4;++i)(e=r.source[i])&&(e.length?t.push({source:e,target:r.target[i]=new Array(4)}):r.target[i]=qs(e));return n},Us.add=function(t){var e=+this._x.call(null,t),n=+this._y.call(null,t);return Is(this.cover(e,n),e,n,t)},Us.addAll=function(t){var e,n,r,i,a=t.length,o=new Array(a),s=new Array(a),c=1/0,u=1/0,l=-1/0,f=-1/0;for(n=0;n<a;++n)isNaN(r=+this._x.call(null,e=t[n]))||isNaN(i=+this._y.call(null,e))||(o[n]=r,s[n]=i,r<c&&(c=r),r>l&&(l=r),i<u&&(u=i),i>f&&(f=i));if(c>l||u>f)return this;for(this.cover(c,u).cover(l,f),n=0;n<a;++n)Is(this,o[n],s[n],t[n]);return this},Us.cover=function(t,e){if(isNaN(t=+t)||isNaN(e=+e))return this;var n=this._x0,r=this._y0,i=this._x1,a=this._y1;if(isNaN(n))i=(n=Math.floor(t))+1,a=(r=Math.floor(e))+1;else{for(var o,s,c=i-n,u=this._root;n>t||t>=i||r>e||e>=a;)switch(s=(e<r)<<1|t<n,(o=new Array(4))[s]=u,u=o,c*=2,s){case 0:i=n+c,a=r+c;break;case 1:n=i-c,a=r+c;break;case 2:i=n+c,r=a-c;break;case 3:n=i-c,r=a-c}this._root&&this._root.length&&(this._root=u)}return this._x0=n,this._y0=r,this._x1=i,this._y1=a,this},Us.data=function(){var t=[];return this.visit((function(e){if(!e.length)do{t.push(e.data)}while(e=e.next)})),t},Us.extent=function(t){return arguments.length?this.cover(+t[0][0],+t[0][1]).cover(+t[1][0],+t[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]},Us.find=function(t,e,n){var r,i,a,o,s,c,u,l=this._x0,f=this._y0,h=this._x1,d=this._y1,p=[],g=this._root;for(g&&p.push(new Rs(g,l,f,h,d)),null==n?n=1/0:(l=t-n,f=e-n,h=t+n,d=e+n,n*=n);c=p.pop();)if(!(!(g=c.node)||(i=c.x0)>h||(a=c.y0)>d||(o=c.x1)<l||(s=c.y1)<f))if(g.length){var y=(i+o)/2,m=(a+s)/2;p.push(new Rs(g[3],y,m,o,s),new Rs(g[2],i,m,y,s),new Rs(g[1],y,a,o,m),new Rs(g[0],i,a,y,m)),(u=(e>=m)<<1|t>=y)&&(c=p[p.length-1],p[p.length-1]=p[p.length-1-u],p[p.length-1-u]=c)}else{var v=t-+this._x.call(null,g.data),b=e-+this._y.call(null,g.data),_=v*v+b*b;if(_<n){var x=Math.sqrt(n=_);l=t-x,f=e-x,h=t+x,d=e+x,r=g.data}}return r},Us.remove=function(t){if(isNaN(a=+this._x.call(null,t))||isNaN(o=+this._y.call(null,t)))return this;var e,n,r,i,a,o,s,c,u,l,f,h,d=this._root,p=this._x0,g=this._y0,y=this._x1,m=this._y1;if(!d)return this;if(d.length)for(;;){if((u=a>=(s=(p+y)/2))?p=s:y=s,(l=o>=(c=(g+m)/2))?g=c:m=c,e=d,!(d=d[f=l<<1|u]))return this;if(!d.length)break;(e[f+1&3]||e[f+2&3]||e[f+3&3])&&(n=e,h=f)}for(;d.data!==t;)if(r=d,!(d=d.next))return this;return(i=d.next)&&delete d.next,r?(i?r.next=i:delete r.next,this):e?(i?e[f]=i:delete e[f],(d=e[0]||e[1]||e[2]||e[3])&&d===(e[3]||e[2]||e[1]||e[0])&&!d.length&&(n?n[h]=d:this._root=d),this):(this._root=i,this)},Us.removeAll=function(t){for(var e=0,n=t.length;e<n;++e)this.remove(t[e]);return this},Us.root=function(){return this._root},Us.size=function(){var t=0;return this.visit((function(e){if(!e.length)do{++t}while(e=e.next)})),t},Us.visit=function(t){var e,n,r,i,a,o,s=[],c=this._root;for(c&&s.push(new Rs(c,this._x0,this._y0,this._x1,this._y1));e=s.pop();)if(!t(c=e.node,r=e.x0,i=e.y0,a=e.x1,o=e.y1)&&c.length){var u=(r+a)/2,l=(i+o)/2;(n=c[3])&&s.push(new Rs(n,u,l,a,o)),(n=c[2])&&s.push(new Rs(n,r,l,u,o)),(n=c[1])&&s.push(new Rs(n,u,i,a,l)),(n=c[0])&&s.push(new Rs(n,r,i,u,l))}return this},Us.visitAfter=function(t){var e,n=[],r=[];for(this._root&&n.push(new Rs(this._root,this._x0,this._y0,this._x1,this._y1));e=n.pop();){var i=e.node;if(i.length){var a,o=e.x0,s=e.y0,c=e.x1,u=e.y1,l=(o+c)/2,f=(s+u)/2;(a=i[0])&&n.push(new Rs(a,o,s,l,f)),(a=i[1])&&n.push(new Rs(a,l,s,c,f)),(a=i[2])&&n.push(new Rs(a,o,f,l,u)),(a=i[3])&&n.push(new Rs(a,l,f,c,u))}r.push(e)}for(;e=r.pop();)t(e.node,e.x0,e.y0,e.x1,e.y1);return this},Us.x=function(t){return arguments.length?(this._x=t,this):this._x},Us.y=function(t){return arguments.length?(this._y=t,this):this._y};var Qs=Math.PI*(3-Math.sqrt(5));function Js(t){var e,n=1,r=.001,i=1-Math.pow(r,1/300),a=0,o=.6,s=na(),c=$n(l),u=ht("tick","end");function l(){f(),u.call("tick",e),n<r&&(c.stop(),u.call("end",e))}function f(r){var c,u,l=t.length;void 0===r&&(r=1);for(var f=0;f<r;++f)for(n+=(a-n)*i,s.each((function(t){t(n)})),c=0;c<l;++c)null==(u=t[c]).fx?u.x+=u.vx*=o:(u.x=u.fx,u.vx=0),null==u.fy?u.y+=u.vy*=o:(u.y=u.fy,u.vy=0);return e}function h(){for(var e,n=0,r=t.length;n<r;++n){if((e=t[n]).index=n,null!=e.fx&&(e.x=e.fx),null!=e.fy&&(e.y=e.fy),isNaN(e.x)||isNaN(e.y)){var i=10*Math.sqrt(n),a=n*Qs;e.x=i*Math.cos(a),e.y=i*Math.sin(a)}(isNaN(e.vx)||isNaN(e.vy))&&(e.vx=e.vy=0)}}function d(e){return e.initialize&&e.initialize(t),e}return null==t&&(t=[]),h(),e={tick:f,restart:function(){return c.restart(l),e},stop:function(){return c.stop(),e},nodes:function(n){return arguments.length?(t=n,h(),s.each(d),e):t},alpha:function(t){return arguments.length?(n=+t,e):n},alphaMin:function(t){return arguments.length?(r=+t,e):r},alphaDecay:function(t){return arguments.length?(i=+t,e):+i},alphaTarget:function(t){return arguments.length?(a=+t,e):a},velocityDecay:function(t){return arguments.length?(o=1-t,e):1-o},force:function(t,n){return arguments.length>1?(null==n?s.remove(t):s.set(t,d(n)),e):s.get(t)},find:function(e,n,r){var i,a,o,s,c,u=0,l=t.length;for(null==r?r=1/0:r*=r,u=0;u<l;++u)(o=(i=e-(s=t[u]).x)*i+(a=n-s.y)*a)<r&&(c=s,r=o);return c},on:function(t,n){return arguments.length>1?(u.on(t,n),e):u.on(t)}}}function tc(){var t,e,n,r,i=Bs(-30),a=1,o=1/0,s=.81;function c(r){var i,a=t.length,o=zs(t,Zs,Ks).visitAfter(l);for(n=r,i=0;i<a;++i)e=t[i],o.visit(f)}function u(){if(t){var e,n,a=t.length;for(r=new Array(a),e=0;e<a;++e)n=t[e],r[n.index]=+i(n,e,t)}}function l(t){var e,n,i,a,o,s=0,c=0;if(t.length){for(i=a=o=0;o<4;++o)(e=t[o])&&(n=Math.abs(e.value))&&(s+=e.value,c+=n,i+=n*e.x,a+=n*e.y);t.x=i/c,t.y=a/c}else{(e=t).x=e.data.x,e.y=e.data.y;do{s+=r[e.data.index]}while(e=e.next)}t.value=s}function f(t,i,c,u){if(!t.value)return!0;var l=t.x-e.x,f=t.y-e.y,h=u-i,d=l*l+f*f;if(h*h/s<d)return d<o&&(0===l&&(d+=(l=Ls())*l),0===f&&(d+=(f=Ls())*f),d<a&&(d=Math.sqrt(a*d)),e.vx+=l*t.value*n/d,e.vy+=f*t.value*n/d),!0;if(!(t.length||d>=o)){(t.data!==e||t.next)&&(0===l&&(d+=(l=Ls())*l),0===f&&(d+=(f=Ls())*f),d<a&&(d=Math.sqrt(a*d)));do{t.data!==e&&(h=r[t.data.index]*n/d,e.vx+=l*h,e.vy+=f*h)}while(t=t.next)}}return c.initialize=function(e){t=e,u()},c.strength=function(t){return arguments.length?(i="function"==typeof t?t:Bs(+t),u(),c):i},c.distanceMin=function(t){return arguments.length?(a=t*t,c):Math.sqrt(a)},c.distanceMax=function(t){return arguments.length?(o=t*t,c):Math.sqrt(o)},c.theta=function(t){return arguments.length?(s=t*t,c):Math.sqrt(s)},c}function ec(t,e,n){var r,i,a,o=Bs(.1);function s(t){for(var o=0,s=r.length;o<s;++o){var c=r[o],u=c.x-e||1e-6,l=c.y-n||1e-6,f=Math.sqrt(u*u+l*l),h=(a[o]-f)*i[o]*t/f;c.vx+=u*h,c.vy+=l*h}}function c(){if(r){var e,n=r.length;for(i=new Array(n),a=new Array(n),e=0;e<n;++e)a[e]=+t(r[e],e,r),i[e]=isNaN(a[e])?0:+o(r[e],e,r)}}return"function"!=typeof t&&(t=Bs(+t)),null==e&&(e=0),null==n&&(n=0),s.initialize=function(t){r=t,c()},s.strength=function(t){return arguments.length?(o="function"==typeof t?t:Bs(+t),c(),s):o},s.radius=function(e){return arguments.length?(t="function"==typeof e?e:Bs(+e),c(),s):t},s.x=function(t){return arguments.length?(e=+t,s):e},s.y=function(t){return arguments.length?(n=+t,s):n},s}function nc(t){var e,n,r,i=Bs(.1);function a(t){for(var i,a=0,o=e.length;a<o;++a)(i=e[a]).vx+=(r[a]-i.x)*n[a]*t}function o(){if(e){var a,o=e.length;for(n=new Array(o),r=new Array(o),a=0;a<o;++a)n[a]=isNaN(r[a]=+t(e[a],a,e))?0:+i(e[a],a,e)}}return"function"!=typeof t&&(t=Bs(null==t?0:+t)),a.initialize=function(t){e=t,o()},a.strength=function(t){return arguments.length?(i="function"==typeof t?t:Bs(+t),o(),a):i},a.x=function(e){return arguments.length?(t="function"==typeof e?e:Bs(+e),o(),a):t},a}function rc(t){var e,n,r,i=Bs(.1);function a(t){for(var i,a=0,o=e.length;a<o;++a)(i=e[a]).vy+=(r[a]-i.y)*n[a]*t}function o(){if(e){var a,o=e.length;for(n=new Array(o),r=new Array(o),a=0;a<o;++a)n[a]=isNaN(r[a]=+t(e[a],a,e))?0:+i(e[a],a,e)}}return"function"!=typeof t&&(t=Bs(null==t?0:+t)),a.initialize=function(t){e=t,o()},a.strength=function(t){return arguments.length?(i="function"==typeof t?t:Bs(+t),o(),a):i},a.y=function(e){return arguments.length?(t="function"==typeof e?e:Bs(+e),o(),a):t},a}function ic(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function ac(t){return(t=ic(Math.abs(t)))?t[1]:NaN}var oc,sc=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function cc(t){if(!(e=sc.exec(t)))throw new Error("invalid format: "+t);var e;return new uc({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function uc(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function lc(t,e){var n=ic(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}cc.prototype=uc.prototype,uc.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const fc={"%":function(t,e){return(100*t).toFixed(e)},b:function(t){return Math.round(t).toString(2)},c:function(t){return t+""},d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:function(t,e){return t.toExponential(e)},f:function(t,e){return t.toFixed(e)},g:function(t,e){return t.toPrecision(e)},o:function(t){return Math.round(t).toString(8)},p:function(t,e){return lc(100*t,e)},r:lc,s:function(t,e){var n=ic(t,e);if(!n)return t+"";var r=n[0],i=n[1],a=i-(oc=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,o=r.length;return a===o?r:a>o?r+new Array(a-o+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+ic(t,Math.max(0,e+a-1))[0]},X:function(t){return Math.round(t).toString(16).toUpperCase()},x:function(t){return Math.round(t).toString(16)}};function hc(t){return t}var dc,pc,gc,yc=Array.prototype.map,mc=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function vc(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?hc:(e=yc.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,a=[],o=0,s=e[0],c=0;i>0&&s>0&&(c+s+1>r&&(s=Math.max(1,r-c)),a.push(t.substring(i-=s,i+s)),!((c+=s+1)>r));)s=e[o=(o+1)%e.length];return a.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",a=void 0===t.currency?"":t.currency[1]+"",o=void 0===t.decimal?".":t.decimal+"",s=void 0===t.numerals?hc:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(yc.call(t.numerals,String)),c=void 0===t.percent?"%":t.percent+"",u=void 0===t.minus?"-":t.minus+"",l=void 0===t.nan?"NaN":t.nan+"";function f(t){var e=(t=cc(t)).fill,n=t.align,f=t.sign,h=t.symbol,d=t.zero,p=t.width,g=t.comma,y=t.precision,m=t.trim,v=t.type;"n"===v?(g=!0,v="g"):fc[v]||(void 0===y&&(y=12),m=!0,v="g"),(d||"0"===e&&"="===n)&&(d=!0,e="0",n="=");var b="$"===h?i:"#"===h&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",_="$"===h?a:/[%p]/.test(v)?c:"",x=fc[v],w=/[defgprs%]/.test(v);function k(t){var i,a,c,h=b,k=_;if("c"===v)k=x(t)+k,t="";else{var T=(t=+t)<0||1/t<0;if(t=isNaN(t)?l:x(Math.abs(t),y),m&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r<n;++r)switch(t[r]){case".":i=e=r;break;case"0":0===i&&(i=r),e=r;break;default:if(!+t[r])break t;i>0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),T&&0==+t&&"+"!==f&&(T=!1),h=(T?"("===f?f:u:"-"===f||"("===f?"":f)+h,k=("s"===v?mc[8+oc/3]:"")+k+(T&&"("===f?")":""),w)for(i=-1,a=t.length;++i<a;)if(48>(c=t.charCodeAt(i))||c>57){k=(46===c?o+t.slice(i+1):t.slice(i))+k,t=t.slice(0,i);break}}g&&!d&&(t=r(t,1/0));var E=h.length+t.length+k.length,C=E<p?new Array(p-E+1).join(e):"";switch(g&&d&&(t=r(C+t,C.length?p-k.length:1/0),C=""),n){case"<":t=h+t+k+C;break;case"=":t=h+C+t+k;break;case"^":t=C.slice(0,E=C.length>>1)+h+t+k+C.slice(E);break;default:t=C+h+t+k}return s(t)}return y=void 0===y?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y)),k.toString=function(){return t+""},k}return{format:f,formatPrefix:function(t,e){var n=f(((t=cc(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(ac(e)/3))),i=Math.pow(10,-r),a=mc[8+r/3];return function(t){return n(i*t)+a}}}}function bc(t){return dc=vc(t),pc=dc.format,gc=dc.formatPrefix,dc}function _c(t){return Math.max(0,-ac(Math.abs(t)))}function xc(t,e){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(ac(e)/3)))-ac(Math.abs(t)))}function wc(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,ac(e)-ac(t))+1}function kc(){return new Tc}function Tc(){this.reset()}bc({decimal:".",thousands:",",grouping:[3],currency:["$",""],minus:"-"}),Tc.prototype={constructor:Tc,reset:function(){this.s=this.t=0},add:function(t){Cc(Ec,t,this.t),Cc(this,Ec.s,this.s),this.s?this.t+=Ec.t:this.s=Ec.t},valueOf:function(){return this.s}};var Ec=new Tc;function Cc(t,e,n){var r=t.s=e+n,i=r-e,a=r-i;t.t=e-a+(n-i)}var Sc=1e-6,Mc=1e-12,Ac=Math.PI,Oc=Ac/2,Nc=Ac/4,jc=2*Ac,Dc=180/Ac,Bc=Ac/180,Lc=Math.abs,Ic=Math.atan,Rc=Math.atan2,Pc=Math.cos,Fc=Math.ceil,zc=Math.exp,Yc=(Math.floor,Math.log),qc=Math.pow,Uc=Math.sin,Vc=Math.sign||function(t){return t>0?1:t<0?-1:0},Wc=Math.sqrt,Hc=Math.tan;function $c(t){return t>1?0:t<-1?Ac:Math.acos(t)}function Gc(t){return t>1?Oc:t<-1?-Oc:Math.asin(t)}function Xc(t){return(t=Uc(t/2))*t}function Zc(){}function Kc(t,e){t&&Jc.hasOwnProperty(t.type)&&Jc[t.type](t,e)}var Qc={Feature:function(t,e){Kc(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)Kc(n[r].geometry,e)}},Jc={Sphere:function(t,e){e.sphere()},Point:function(t,e){t=t.coordinates,e.point(t[0],t[1],t[2])},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)t=n[r],e.point(t[0],t[1],t[2])},LineString:function(t,e){tu(t.coordinates,e,0)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)tu(n[r],e,0)},Polygon:function(t,e){eu(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)eu(n[r],e)},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)Kc(n[r],e)}};function tu(t,e,n){var r,i=-1,a=t.length-n;for(e.lineStart();++i<a;)r=t[i],e.point(r[0],r[1],r[2]);e.lineEnd()}function eu(t,e){var n=-1,r=t.length;for(e.polygonStart();++n<r;)tu(t[n],e,1);e.polygonEnd()}function nu(t,e){t&&Qc.hasOwnProperty(t.type)?Qc[t.type](t,e):Kc(t,e)}var ru,iu,au,ou,su,cu=kc(),uu=kc(),lu={point:Zc,lineStart:Zc,lineEnd:Zc,polygonStart:function(){cu.reset(),lu.lineStart=fu,lu.lineEnd=hu},polygonEnd:function(){var t=+cu;uu.add(t<0?jc+t:t),this.lineStart=this.lineEnd=this.point=Zc},sphere:function(){uu.add(jc)}};function fu(){lu.point=du}function hu(){pu(ru,iu)}function du(t,e){lu.point=pu,ru=t,iu=e,au=t*=Bc,ou=Pc(e=(e*=Bc)/2+Nc),su=Uc(e)}function pu(t,e){var n=(t*=Bc)-au,r=n>=0?1:-1,i=r*n,a=Pc(e=(e*=Bc)/2+Nc),o=Uc(e),s=su*o,c=ou*a+s*Pc(i),u=s*r*Uc(i);cu.add(Rc(u,c)),au=t,ou=a,su=o}function gu(t){return uu.reset(),nu(t,lu),2*uu}function yu(t){return[Rc(t[1],t[0]),Gc(t[2])]}function mu(t){var e=t[0],n=t[1],r=Pc(n);return[r*Pc(e),r*Uc(e),Uc(n)]}function vu(t,e){return t[0]*e[0]+t[1]*e[1]+t[2]*e[2]}function bu(t,e){return[t[1]*e[2]-t[2]*e[1],t[2]*e[0]-t[0]*e[2],t[0]*e[1]-t[1]*e[0]]}function _u(t,e){t[0]+=e[0],t[1]+=e[1],t[2]+=e[2]}function xu(t,e){return[t[0]*e,t[1]*e,t[2]*e]}function wu(t){var e=Wc(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]);t[0]/=e,t[1]/=e,t[2]/=e}var ku,Tu,Eu,Cu,Su,Mu,Au,Ou,Nu,ju,Du,Bu,Lu,Iu,Ru,Pu,Fu,zu,Yu,qu,Uu,Vu,Wu,Hu,$u,Gu,Xu=kc(),Zu={point:Ku,lineStart:Ju,lineEnd:tl,polygonStart:function(){Zu.point=el,Zu.lineStart=nl,Zu.lineEnd=rl,Xu.reset(),lu.polygonStart()},polygonEnd:function(){lu.polygonEnd(),Zu.point=Ku,Zu.lineStart=Ju,Zu.lineEnd=tl,cu<0?(ku=-(Eu=180),Tu=-(Cu=90)):Xu>Sc?Cu=90:Xu<-1e-6&&(Tu=-90),ju[0]=ku,ju[1]=Eu},sphere:function(){ku=-(Eu=180),Tu=-(Cu=90)}};function Ku(t,e){Nu.push(ju=[ku=t,Eu=t]),e<Tu&&(Tu=e),e>Cu&&(Cu=e)}function Qu(t,e){var n=mu([t*Bc,e*Bc]);if(Ou){var r=bu(Ou,n),i=bu([r[1],-r[0],0],r);wu(i),i=yu(i);var a,o=t-Su,s=o>0?1:-1,c=i[0]*Dc*s,u=Lc(o)>180;u^(s*Su<c&&c<s*t)?(a=i[1]*Dc)>Cu&&(Cu=a):u^(s*Su<(c=(c+360)%360-180)&&c<s*t)?(a=-i[1]*Dc)<Tu&&(Tu=a):(e<Tu&&(Tu=e),e>Cu&&(Cu=e)),u?t<Su?il(ku,t)>il(ku,Eu)&&(Eu=t):il(t,Eu)>il(ku,Eu)&&(ku=t):Eu>=ku?(t<ku&&(ku=t),t>Eu&&(Eu=t)):t>Su?il(ku,t)>il(ku,Eu)&&(Eu=t):il(t,Eu)>il(ku,Eu)&&(ku=t)}else Nu.push(ju=[ku=t,Eu=t]);e<Tu&&(Tu=e),e>Cu&&(Cu=e),Ou=n,Su=t}function Ju(){Zu.point=Qu}function tl(){ju[0]=ku,ju[1]=Eu,Zu.point=Ku,Ou=null}function el(t,e){if(Ou){var n=t-Su;Xu.add(Lc(n)>180?n+(n>0?360:-360):n)}else Mu=t,Au=e;lu.point(t,e),Qu(t,e)}function nl(){lu.lineStart()}function rl(){el(Mu,Au),lu.lineEnd(),Lc(Xu)>Sc&&(ku=-(Eu=180)),ju[0]=ku,ju[1]=Eu,Ou=null}function il(t,e){return(e-=t)<0?e+360:e}function al(t,e){return t[0]-e[0]}function ol(t,e){return t[0]<=t[1]?t[0]<=e&&e<=t[1]:e<t[0]||t[1]<e}function sl(t){var e,n,r,i,a,o,s;if(Cu=Eu=-(ku=Tu=1/0),Nu=[],nu(t,Zu),n=Nu.length){for(Nu.sort(al),e=1,a=[r=Nu[0]];e<n;++e)ol(r,(i=Nu[e])[0])||ol(r,i[1])?(il(r[0],i[1])>il(r[0],r[1])&&(r[1]=i[1]),il(i[0],r[1])>il(r[0],r[1])&&(r[0]=i[0])):a.push(r=i);for(o=-1/0,e=0,r=a[n=a.length-1];e<=n;r=i,++e)i=a[e],(s=il(r[1],i[0]))>o&&(o=s,ku=i[0],Eu=r[1])}return Nu=ju=null,ku===1/0||Tu===1/0?[[NaN,NaN],[NaN,NaN]]:[[ku,Tu],[Eu,Cu]]}var cl={sphere:Zc,point:ul,lineStart:fl,lineEnd:pl,polygonStart:function(){cl.lineStart=gl,cl.lineEnd=yl},polygonEnd:function(){cl.lineStart=fl,cl.lineEnd=pl}};function ul(t,e){t*=Bc;var n=Pc(e*=Bc);ll(n*Pc(t),n*Uc(t),Uc(e))}function ll(t,e,n){++Du,Lu+=(t-Lu)/Du,Iu+=(e-Iu)/Du,Ru+=(n-Ru)/Du}function fl(){cl.point=hl}function hl(t,e){t*=Bc;var n=Pc(e*=Bc);Hu=n*Pc(t),$u=n*Uc(t),Gu=Uc(e),cl.point=dl,ll(Hu,$u,Gu)}function dl(t,e){t*=Bc;var n=Pc(e*=Bc),r=n*Pc(t),i=n*Uc(t),a=Uc(e),o=Rc(Wc((o=$u*a-Gu*i)*o+(o=Gu*r-Hu*a)*o+(o=Hu*i-$u*r)*o),Hu*r+$u*i+Gu*a);Bu+=o,Pu+=o*(Hu+(Hu=r)),Fu+=o*($u+($u=i)),zu+=o*(Gu+(Gu=a)),ll(Hu,$u,Gu)}function pl(){cl.point=ul}function gl(){cl.point=ml}function yl(){vl(Vu,Wu),cl.point=ul}function ml(t,e){Vu=t,Wu=e,t*=Bc,e*=Bc,cl.point=vl;var n=Pc(e);Hu=n*Pc(t),$u=n*Uc(t),Gu=Uc(e),ll(Hu,$u,Gu)}function vl(t,e){t*=Bc;var n=Pc(e*=Bc),r=n*Pc(t),i=n*Uc(t),a=Uc(e),o=$u*a-Gu*i,s=Gu*r-Hu*a,c=Hu*i-$u*r,u=Wc(o*o+s*s+c*c),l=Gc(u),f=u&&-l/u;Yu+=f*o,qu+=f*s,Uu+=f*c,Bu+=l,Pu+=l*(Hu+(Hu=r)),Fu+=l*($u+($u=i)),zu+=l*(Gu+(Gu=a)),ll(Hu,$u,Gu)}function bl(t){Du=Bu=Lu=Iu=Ru=Pu=Fu=zu=Yu=qu=Uu=0,nu(t,cl);var e=Yu,n=qu,r=Uu,i=e*e+n*n+r*r;return i<Mc&&(e=Pu,n=Fu,r=zu,Bu<Sc&&(e=Lu,n=Iu,r=Ru),(i=e*e+n*n+r*r)<Mc)?[NaN,NaN]:[Rc(n,e)*Dc,Gc(r/Wc(i))*Dc]}function _l(t){return function(){return t}}function xl(t,e){function n(n,r){return n=t(n,r),e(n[0],n[1])}return t.invert&&e.invert&&(n.invert=function(n,r){return(n=e.invert(n,r))&&t.invert(n[0],n[1])}),n}function wl(t,e){return[Lc(t)>Ac?t+Math.round(-t/jc)*jc:t,e]}function kl(t,e,n){return(t%=jc)?e||n?xl(El(t),Cl(e,n)):El(t):e||n?Cl(e,n):wl}function Tl(t){return function(e,n){return[(e+=t)>Ac?e-jc:e<-Ac?e+jc:e,n]}}function El(t){var e=Tl(t);return e.invert=Tl(-t),e}function Cl(t,e){var n=Pc(t),r=Uc(t),i=Pc(e),a=Uc(e);function o(t,e){var o=Pc(e),s=Pc(t)*o,c=Uc(t)*o,u=Uc(e),l=u*n+s*r;return[Rc(c*i-l*a,s*n-u*r),Gc(l*i+c*a)]}return o.invert=function(t,e){var o=Pc(e),s=Pc(t)*o,c=Uc(t)*o,u=Uc(e),l=u*i-c*a;return[Rc(c*i+u*a,s*n+l*r),Gc(l*n-s*r)]},o}function Sl(t){function e(e){return(e=t(e[0]*Bc,e[1]*Bc))[0]*=Dc,e[1]*=Dc,e}return t=kl(t[0]*Bc,t[1]*Bc,t.length>2?t[2]*Bc:0),e.invert=function(e){return(e=t.invert(e[0]*Bc,e[1]*Bc))[0]*=Dc,e[1]*=Dc,e},e}function Ml(t,e,n,r,i,a){if(n){var o=Pc(e),s=Uc(e),c=r*n;null==i?(i=e+r*jc,a=e-c/2):(i=Al(o,i),a=Al(o,a),(r>0?i<a:i>a)&&(i+=r*jc));for(var u,l=i;r>0?l>a:l<a;l-=c)u=yu([o,-s*Pc(l),-s*Uc(l)]),t.point(u[0],u[1])}}function Al(t,e){(e=mu(e))[0]-=t,wu(e);var n=$c(-e[1]);return((-e[2]<0?-n:n)+jc-Sc)%jc}function Ol(){var t,e,n=_l([0,0]),r=_l(90),i=_l(6),a={point:function(n,r){t.push(n=e(n,r)),n[0]*=Dc,n[1]*=Dc}};function o(){var o=n.apply(this,arguments),s=r.apply(this,arguments)*Bc,c=i.apply(this,arguments)*Bc;return t=[],e=kl(-o[0]*Bc,-o[1]*Bc,0).invert,Ml(a,s,c,1),o={type:"Polygon",coordinates:[t]},t=e=null,o}return o.center=function(t){return arguments.length?(n="function"==typeof t?t:_l([+t[0],+t[1]]),o):n},o.radius=function(t){return arguments.length?(r="function"==typeof t?t:_l(+t),o):r},o.precision=function(t){return arguments.length?(i="function"==typeof t?t:_l(+t),o):i},o}function Nl(){var t,e=[];return{point:function(e,n,r){t.push([e,n,r])},lineStart:function(){e.push(t=[])},lineEnd:Zc,rejoin:function(){e.length>1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function jl(t,e){return Lc(t[0]-e[0])<Sc&&Lc(t[1]-e[1])<Sc}function Dl(t,e,n,r){this.x=t,this.z=e,this.o=n,this.e=r,this.v=!1,this.n=this.p=null}function Bl(t,e,n,r,i){var a,o,s=[],c=[];if(t.forEach((function(t){if(!((e=t.length-1)<=0)){var e,n,r=t[0],o=t[e];if(jl(r,o)){if(!r[2]&&!o[2]){for(i.lineStart(),a=0;a<e;++a)i.point((r=t[a])[0],r[1]);return void i.lineEnd()}o[0]+=2e-6}s.push(n=new Dl(r,t,null,!0)),c.push(n.o=new Dl(r,null,n,!1)),s.push(n=new Dl(o,t,null,!1)),c.push(n.o=new Dl(o,null,n,!0))}})),s.length){for(c.sort(e),Ll(s),Ll(c),a=0,o=c.length;a<o;++a)c[a].e=n=!n;for(var u,l,f=s[0];;){for(var h=f,d=!0;h.v;)if((h=h.n)===f)return;u=h.z,i.lineStart();do{if(h.v=h.o.v=!0,h.e){if(d)for(a=0,o=u.length;a<o;++a)i.point((l=u[a])[0],l[1]);else r(h.x,h.n.x,1,i);h=h.n}else{if(d)for(u=h.p.z,a=u.length-1;a>=0;--a)i.point((l=u[a])[0],l[1]);else r(h.x,h.p.x,-1,i);h=h.p}u=(h=h.o).z,d=!d}while(!h.v);i.lineEnd()}}}function Ll(t){if(e=t.length){for(var e,n,r=0,i=t[0];++r<e;)i.n=n=t[r],n.p=i,i=n;i.n=n=t[0],n.p=i}}wl.invert=wl;var Il=kc();function Rl(t){return Lc(t[0])<=Ac?t[0]:Vc(t[0])*((Lc(t[0])+Ac)%jc-Ac)}function Pl(t,e){var n=Rl(e),r=e[1],i=Uc(r),a=[Uc(n),-Pc(n),0],o=0,s=0;Il.reset(),1===i?r=Oc+Sc:-1===i&&(r=-Oc-Sc);for(var c=0,u=t.length;c<u;++c)if(f=(l=t[c]).length)for(var l,f,h=l[f-1],d=Rl(h),p=h[1]/2+Nc,g=Uc(p),y=Pc(p),m=0;m<f;++m,d=b,g=x,y=w,h=v){var v=l[m],b=Rl(v),_=v[1]/2+Nc,x=Uc(_),w=Pc(_),k=b-d,T=k>=0?1:-1,E=T*k,C=E>Ac,S=g*x;if(Il.add(Rc(S*T*Uc(E),y*w+S*Pc(E))),o+=C?k+T*jc:k,C^d>=n^b>=n){var M=bu(mu(h),mu(v));wu(M);var A=bu(a,M);wu(A);var O=(C^k>=0?-1:1)*Gc(A[2]);(r>O||r===O&&(M[0]||M[1]))&&(s+=C^k>=0?1:-1)}}return(o<-1e-6||o<Sc&&Il<-1e-6)^1&s}function Fl(t,e,n,r){return function(i){var a,o,s,c=e(i),u=Nl(),l=e(u),f=!1,h={point:d,lineStart:g,lineEnd:y,polygonStart:function(){h.point=m,h.lineStart=v,h.lineEnd=b,o=[],a=[]},polygonEnd:function(){h.point=d,h.lineStart=g,h.lineEnd=y,o=P(o);var t=Pl(a,r);o.length?(f||(i.polygonStart(),f=!0),Bl(o,Yl,t,n,i)):t&&(f||(i.polygonStart(),f=!0),i.lineStart(),n(null,null,1,i),i.lineEnd()),f&&(i.polygonEnd(),f=!1),o=a=null},sphere:function(){i.polygonStart(),i.lineStart(),n(null,null,1,i),i.lineEnd(),i.polygonEnd()}};function d(e,n){t(e,n)&&i.point(e,n)}function p(t,e){c.point(t,e)}function g(){h.point=p,c.lineStart()}function y(){h.point=d,c.lineEnd()}function m(t,e){s.push([t,e]),l.point(t,e)}function v(){l.lineStart(),s=[]}function b(){m(s[0][0],s[0][1]),l.lineEnd();var t,e,n,r,c=l.clean(),h=u.result(),d=h.length;if(s.pop(),a.push(s),s=null,d)if(1&c){if((e=(n=h[0]).length-1)>0){for(f||(i.polygonStart(),f=!0),i.lineStart(),t=0;t<e;++t)i.point((r=n[t])[0],r[1]);i.lineEnd()}}else d>1&&2&c&&h.push(h.pop().concat(h.shift())),o.push(h.filter(zl))}return h}}function zl(t){return t.length>1}function Yl(t,e){return((t=t.x)[0]<0?t[1]-Oc-Sc:Oc-t[1])-((e=e.x)[0]<0?e[1]-Oc-Sc:Oc-e[1])}const ql=Fl((function(){return!0}),(function(t){var e,n=NaN,r=NaN,i=NaN;return{lineStart:function(){t.lineStart(),e=1},point:function(a,o){var s=a>0?Ac:-Ac,c=Lc(a-n);Lc(c-Ac)<Sc?(t.point(n,r=(r+o)/2>0?Oc:-Oc),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),t.point(a,r),e=0):i!==s&&c>=Ac&&(Lc(n-i)<Sc&&(n-=i*Sc),Lc(a-s)<Sc&&(a-=s*Sc),r=function(t,e,n,r){var i,a,o=Uc(t-n);return Lc(o)>Sc?Ic((Uc(e)*(a=Pc(r))*Uc(n)-Uc(r)*(i=Pc(e))*Uc(t))/(i*a*o)):(e+r)/2}(n,r,a,o),t.point(i,r),t.lineEnd(),t.lineStart(),t.point(s,r),e=0),t.point(n=a,r=o),i=s},lineEnd:function(){t.lineEnd(),n=r=NaN},clean:function(){return 2-e}}}),(function(t,e,n,r){var i;if(null==t)i=n*Oc,r.point(-Ac,i),r.point(0,i),r.point(Ac,i),r.point(Ac,0),r.point(Ac,-i),r.point(0,-i),r.point(-Ac,-i),r.point(-Ac,0),r.point(-Ac,i);else if(Lc(t[0]-e[0])>Sc){var a=t[0]<e[0]?Ac:-Ac;i=n*a/2,r.point(-a,i),r.point(0,i),r.point(a,i)}else r.point(e[0],e[1])}),[-Ac,-Oc]);function Ul(t){var e=Pc(t),n=6*Bc,r=e>0,i=Lc(e)>Sc;function a(t,n){return Pc(t)*Pc(n)>e}function o(t,n,r){var i=[1,0,0],a=bu(mu(t),mu(n)),o=vu(a,a),s=a[0],c=o-s*s;if(!c)return!r&&t;var u=e*o/c,l=-e*s/c,f=bu(i,a),h=xu(i,u);_u(h,xu(a,l));var d=f,p=vu(h,d),g=vu(d,d),y=p*p-g*(vu(h,h)-1);if(!(y<0)){var m=Wc(y),v=xu(d,(-p-m)/g);if(_u(v,h),v=yu(v),!r)return v;var b,_=t[0],x=n[0],w=t[1],k=n[1];x<_&&(b=_,_=x,x=b);var T=x-_,E=Lc(T-Ac)<Sc;if(!E&&k<w&&(b=w,w=k,k=b),E||T<Sc?E?w+k>0^v[1]<(Lc(v[0]-_)<Sc?w:k):w<=v[1]&&v[1]<=k:T>Ac^(_<=v[0]&&v[0]<=x)){var C=xu(d,(-p+m)/g);return _u(C,h),[v,yu(C)]}}}function s(e,n){var i=r?t:Ac-t,a=0;return e<-i?a|=1:e>i&&(a|=2),n<-i?a|=4:n>i&&(a|=8),a}return Fl(a,(function(t){var e,n,c,u,l;return{lineStart:function(){u=c=!1,l=1},point:function(f,h){var d,p=[f,h],g=a(f,h),y=r?g?0:s(f,h):g?s(f+(f<0?Ac:-Ac),h):0;if(!e&&(u=c=g)&&t.lineStart(),g!==c&&(!(d=o(e,p))||jl(e,d)||jl(p,d))&&(p[2]=1),g!==c)l=0,g?(t.lineStart(),d=o(p,e),t.point(d[0],d[1])):(d=o(e,p),t.point(d[0],d[1],2),t.lineEnd()),e=d;else if(i&&e&&r^g){var m;y&n||!(m=o(p,e,!0))||(l=0,r?(t.lineStart(),t.point(m[0][0],m[0][1]),t.point(m[1][0],m[1][1]),t.lineEnd()):(t.point(m[1][0],m[1][1]),t.lineEnd(),t.lineStart(),t.point(m[0][0],m[0][1],3)))}!g||e&&jl(e,p)||t.point(p[0],p[1]),e=p,c=g,n=y},lineEnd:function(){c&&t.lineEnd(),e=null},clean:function(){return l|(u&&c)<<1}}}),(function(e,r,i,a){Ml(a,t,n,i,e,r)}),r?[0,-t]:[-Ac,t-Ac])}var Vl=1e9,Wl=-Vl;function Hl(t,e,n,r){function i(i,a){return t<=i&&i<=n&&e<=a&&a<=r}function a(i,a,s,u){var l=0,f=0;if(null==i||(l=o(i,s))!==(f=o(a,s))||c(i,a)<0^s>0)do{u.point(0===l||3===l?t:n,l>1?r:e)}while((l=(l+s+4)%4)!==f);else u.point(a[0],a[1])}function o(r,i){return Lc(r[0]-t)<Sc?i>0?0:3:Lc(r[0]-n)<Sc?i>0?2:1:Lc(r[1]-e)<Sc?i>0?1:0:i>0?3:2}function s(t,e){return c(t.x,e.x)}function c(t,e){var n=o(t,1),r=o(e,1);return n!==r?n-r:0===n?e[1]-t[1]:1===n?t[0]-e[0]:2===n?t[1]-e[1]:e[0]-t[0]}return function(o){var c,u,l,f,h,d,p,g,y,m,v,b=o,_=Nl(),x={point:w,lineStart:function(){x.point=k,u&&u.push(l=[]),m=!0,y=!1,p=g=NaN},lineEnd:function(){c&&(k(f,h),d&&y&&_.rejoin(),c.push(_.result())),x.point=w,y&&b.lineEnd()},polygonStart:function(){b=_,c=[],u=[],v=!0},polygonEnd:function(){var e=function(){for(var e=0,n=0,i=u.length;n<i;++n)for(var a,o,s=u[n],c=1,l=s.length,f=s[0],h=f[0],d=f[1];c<l;++c)a=h,o=d,h=(f=s[c])[0],d=f[1],o<=r?d>r&&(h-a)*(r-o)>(d-o)*(t-a)&&++e:d<=r&&(h-a)*(r-o)<(d-o)*(t-a)&&--e;return e}(),n=v&&e,i=(c=P(c)).length;(n||i)&&(o.polygonStart(),n&&(o.lineStart(),a(null,null,1,o),o.lineEnd()),i&&Bl(c,s,e,a,o),o.polygonEnd()),b=o,c=u=l=null}};function w(t,e){i(t,e)&&b.point(t,e)}function k(a,o){var s=i(a,o);if(u&&l.push([a,o]),m)f=a,h=o,d=s,m=!1,s&&(b.lineStart(),b.point(a,o));else if(s&&y)b.point(a,o);else{var c=[p=Math.max(Wl,Math.min(Vl,p)),g=Math.max(Wl,Math.min(Vl,g))],_=[a=Math.max(Wl,Math.min(Vl,a)),o=Math.max(Wl,Math.min(Vl,o))];!function(t,e,n,r,i,a){var o,s=t[0],c=t[1],u=0,l=1,f=e[0]-s,h=e[1]-c;if(o=n-s,f||!(o>0)){if(o/=f,f<0){if(o<u)return;o<l&&(l=o)}else if(f>0){if(o>l)return;o>u&&(u=o)}if(o=i-s,f||!(o<0)){if(o/=f,f<0){if(o>l)return;o>u&&(u=o)}else if(f>0){if(o<u)return;o<l&&(l=o)}if(o=r-c,h||!(o>0)){if(o/=h,h<0){if(o<u)return;o<l&&(l=o)}else if(h>0){if(o>l)return;o>u&&(u=o)}if(o=a-c,h||!(o<0)){if(o/=h,h<0){if(o>l)return;o>u&&(u=o)}else if(h>0){if(o<u)return;o<l&&(l=o)}return u>0&&(t[0]=s+u*f,t[1]=c+u*h),l<1&&(e[0]=s+l*f,e[1]=c+l*h),!0}}}}}(c,_,t,e,n,r)?s&&(b.lineStart(),b.point(a,o),v=!1):(y||(b.lineStart(),b.point(c[0],c[1])),b.point(_[0],_[1]),s||b.lineEnd(),v=!1)}p=a,g=o,y=s}return x}}function $l(){var t,e,n,r=0,i=0,a=960,o=500;return n={stream:function(n){return t&&e===n?t:t=Hl(r,i,a,o)(e=n)},extent:function(s){return arguments.length?(r=+s[0][0],i=+s[0][1],a=+s[1][0],o=+s[1][1],t=e=null,n):[[r,i],[a,o]]}}}var Gl,Xl,Zl,Kl=kc(),Ql={sphere:Zc,point:Zc,lineStart:function(){Ql.point=tf,Ql.lineEnd=Jl},lineEnd:Zc,polygonStart:Zc,polygonEnd:Zc};function Jl(){Ql.point=Ql.lineEnd=Zc}function tf(t,e){Gl=t*=Bc,Xl=Uc(e*=Bc),Zl=Pc(e),Ql.point=ef}function ef(t,e){t*=Bc;var n=Uc(e*=Bc),r=Pc(e),i=Lc(t-Gl),a=Pc(i),o=r*Uc(i),s=Zl*n-Xl*r*a,c=Xl*n+Zl*r*a;Kl.add(Rc(Wc(o*o+s*s),c)),Gl=t,Xl=n,Zl=r}function nf(t){return Kl.reset(),nu(t,Ql),+Kl}var rf=[null,null],af={type:"LineString",coordinates:rf};function of(t,e){return rf[0]=t,rf[1]=e,nf(af)}var sf={Feature:function(t,e){return uf(t.geometry,e)},FeatureCollection:function(t,e){for(var n=t.features,r=-1,i=n.length;++r<i;)if(uf(n[r].geometry,e))return!0;return!1}},cf={Sphere:function(){return!0},Point:function(t,e){return lf(t.coordinates,e)},MultiPoint:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(lf(n[r],e))return!0;return!1},LineString:function(t,e){return ff(t.coordinates,e)},MultiLineString:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(ff(n[r],e))return!0;return!1},Polygon:function(t,e){return hf(t.coordinates,e)},MultiPolygon:function(t,e){for(var n=t.coordinates,r=-1,i=n.length;++r<i;)if(hf(n[r],e))return!0;return!1},GeometryCollection:function(t,e){for(var n=t.geometries,r=-1,i=n.length;++r<i;)if(uf(n[r],e))return!0;return!1}};function uf(t,e){return!(!t||!cf.hasOwnProperty(t.type))&&cf[t.type](t,e)}function lf(t,e){return 0===of(t,e)}function ff(t,e){for(var n,r,i,a=0,o=t.length;a<o;a++){if(0===(r=of(t[a],e)))return!0;if(a>0&&(i=of(t[a],t[a-1]))>0&&n<=i&&r<=i&&(n+r-i)*(1-Math.pow((n-r)/i,2))<Mc*i)return!0;n=r}return!1}function hf(t,e){return!!Pl(t.map(df),pf(e))}function df(t){return(t=t.map(pf)).pop(),t}function pf(t){return[t[0]*Bc,t[1]*Bc]}function gf(t,e){return(t&&sf.hasOwnProperty(t.type)?sf[t.type]:uf)(t,e)}function yf(t,e,n){var r=k(t,e-Sc,n).concat(e);return function(t){return r.map((function(e){return[t,e]}))}}function mf(t,e,n){var r=k(t,e-Sc,n).concat(e);return function(t){return r.map((function(e){return[e,t]}))}}function vf(){var t,e,n,r,i,a,o,s,c,u,l,f,h=10,d=h,p=90,g=360,y=2.5;function m(){return{type:"MultiLineString",coordinates:v()}}function v(){return k(Fc(r/p)*p,n,p).map(l).concat(k(Fc(s/g)*g,o,g).map(f)).concat(k(Fc(e/h)*h,t,h).filter((function(t){return Lc(t%p)>Sc})).map(c)).concat(k(Fc(a/d)*d,i,d).filter((function(t){return Lc(t%g)>Sc})).map(u))}return m.lines=function(){return v().map((function(t){return{type:"LineString",coordinates:t}}))},m.outline=function(){return{type:"Polygon",coordinates:[l(r).concat(f(o).slice(1),l(n).reverse().slice(1),f(s).reverse().slice(1))]}},m.extent=function(t){return arguments.length?m.extentMajor(t).extentMinor(t):m.extentMinor()},m.extentMajor=function(t){return arguments.length?(r=+t[0][0],n=+t[1][0],s=+t[0][1],o=+t[1][1],r>n&&(t=r,r=n,n=t),s>o&&(t=s,s=o,o=t),m.precision(y)):[[r,s],[n,o]]},m.extentMinor=function(n){return arguments.length?(e=+n[0][0],t=+n[1][0],a=+n[0][1],i=+n[1][1],e>t&&(n=e,e=t,t=n),a>i&&(n=a,a=i,i=n),m.precision(y)):[[e,a],[t,i]]},m.step=function(t){return arguments.length?m.stepMajor(t).stepMinor(t):m.stepMinor()},m.stepMajor=function(t){return arguments.length?(p=+t[0],g=+t[1],m):[p,g]},m.stepMinor=function(t){return arguments.length?(h=+t[0],d=+t[1],m):[h,d]},m.precision=function(h){return arguments.length?(y=+h,c=yf(a,i,90),u=mf(e,t,y),l=yf(s,o,90),f=mf(r,n,y),m):y},m.extentMajor([[-180,-89.999999],[180,89.999999]]).extentMinor([[-180,-80.000001],[180,80.000001]])}function bf(){return vf()()}function _f(t,e){var n=t[0]*Bc,r=t[1]*Bc,i=e[0]*Bc,a=e[1]*Bc,o=Pc(r),s=Uc(r),c=Pc(a),u=Uc(a),l=o*Pc(n),f=o*Uc(n),h=c*Pc(i),d=c*Uc(i),p=2*Gc(Wc(Xc(a-r)+o*c*Xc(i-n))),g=Uc(p),y=p?function(t){var e=Uc(t*=p)/g,n=Uc(p-t)/g,r=n*l+e*h,i=n*f+e*d,a=n*s+e*u;return[Rc(i,r)*Dc,Rc(a,Wc(r*r+i*i))*Dc]}:function(){return[n*Dc,r*Dc]};return y.distance=p,y}function xf(t){return t}var wf,kf,Tf,Ef,Cf=kc(),Sf=kc(),Mf={point:Zc,lineStart:Zc,lineEnd:Zc,polygonStart:function(){Mf.lineStart=Af,Mf.lineEnd=jf},polygonEnd:function(){Mf.lineStart=Mf.lineEnd=Mf.point=Zc,Cf.add(Lc(Sf)),Sf.reset()},result:function(){var t=Cf/2;return Cf.reset(),t}};function Af(){Mf.point=Of}function Of(t,e){Mf.point=Nf,wf=Tf=t,kf=Ef=e}function Nf(t,e){Sf.add(Ef*t-Tf*e),Tf=t,Ef=e}function jf(){Nf(wf,kf)}const Df=Mf;var Bf=1/0,Lf=Bf,If=-Bf,Rf=If,Pf={point:function(t,e){t<Bf&&(Bf=t),t>If&&(If=t),e<Lf&&(Lf=e),e>Rf&&(Rf=e)},lineStart:Zc,lineEnd:Zc,polygonStart:Zc,polygonEnd:Zc,result:function(){var t=[[Bf,Lf],[If,Rf]];return If=Rf=-(Lf=Bf=1/0),t}};const Ff=Pf;var zf,Yf,qf,Uf,Vf=0,Wf=0,Hf=0,$f=0,Gf=0,Xf=0,Zf=0,Kf=0,Qf=0,Jf={point:th,lineStart:eh,lineEnd:ih,polygonStart:function(){Jf.lineStart=ah,Jf.lineEnd=oh},polygonEnd:function(){Jf.point=th,Jf.lineStart=eh,Jf.lineEnd=ih},result:function(){var t=Qf?[Zf/Qf,Kf/Qf]:Xf?[$f/Xf,Gf/Xf]:Hf?[Vf/Hf,Wf/Hf]:[NaN,NaN];return Vf=Wf=Hf=$f=Gf=Xf=Zf=Kf=Qf=0,t}};function th(t,e){Vf+=t,Wf+=e,++Hf}function eh(){Jf.point=nh}function nh(t,e){Jf.point=rh,th(qf=t,Uf=e)}function rh(t,e){var n=t-qf,r=e-Uf,i=Wc(n*n+r*r);$f+=i*(qf+t)/2,Gf+=i*(Uf+e)/2,Xf+=i,th(qf=t,Uf=e)}function ih(){Jf.point=th}function ah(){Jf.point=sh}function oh(){ch(zf,Yf)}function sh(t,e){Jf.point=ch,th(zf=qf=t,Yf=Uf=e)}function ch(t,e){var n=t-qf,r=e-Uf,i=Wc(n*n+r*r);$f+=i*(qf+t)/2,Gf+=i*(Uf+e)/2,Xf+=i,Zf+=(i=Uf*t-qf*e)*(qf+t),Kf+=i*(Uf+e),Qf+=3*i,th(qf=t,Uf=e)}const uh=Jf;function lh(t){this._context=t}lh.prototype={_radius:4.5,pointRadius:function(t){return this._radius=t,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._context.closePath(),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._context.moveTo(t,e),this._point=1;break;case 1:this._context.lineTo(t,e);break;default:this._context.moveTo(t+this._radius,e),this._context.arc(t,e,this._radius,0,jc)}},result:Zc};var fh,hh,dh,ph,gh,yh=kc(),mh={point:Zc,lineStart:function(){mh.point=vh},lineEnd:function(){fh&&bh(hh,dh),mh.point=Zc},polygonStart:function(){fh=!0},polygonEnd:function(){fh=null},result:function(){var t=+yh;return yh.reset(),t}};function vh(t,e){mh.point=bh,hh=ph=t,dh=gh=e}function bh(t,e){ph-=t,gh-=e,yh.add(Wc(ph*ph+gh*gh)),ph=t,gh=e}const _h=mh;function xh(){this._string=[]}function wh(t){return"m0,"+t+"a"+t+","+t+" 0 1,1 0,"+-2*t+"a"+t+","+t+" 0 1,1 0,"+2*t+"z"}function kh(t,e){var n,r,i=4.5;function a(t){return t&&("function"==typeof i&&r.pointRadius(+i.apply(this,arguments)),nu(t,n(r))),r.result()}return a.area=function(t){return nu(t,n(Df)),Df.result()},a.measure=function(t){return nu(t,n(_h)),_h.result()},a.bounds=function(t){return nu(t,n(Ff)),Ff.result()},a.centroid=function(t){return nu(t,n(uh)),uh.result()},a.projection=function(e){return arguments.length?(n=null==e?(t=null,xf):(t=e).stream,a):t},a.context=function(t){return arguments.length?(r=null==t?(e=null,new xh):new lh(e=t),"function"!=typeof i&&r.pointRadius(i),a):e},a.pointRadius=function(t){return arguments.length?(i="function"==typeof t?t:(r.pointRadius(+t),+t),a):i},a.projection(t).context(e)}function Th(t){return{stream:Eh(t)}}function Eh(t){return function(e){var n=new Ch;for(var r in t)n[r]=t[r];return n.stream=e,n}}function Ch(){}function Sh(t,e,n){var r=t.clipExtent&&t.clipExtent();return t.scale(150).translate([0,0]),null!=r&&t.clipExtent(null),nu(n,t.stream(Ff)),e(Ff.result()),null!=r&&t.clipExtent(r),t}function Mh(t,e,n){return Sh(t,(function(n){var r=e[1][0]-e[0][0],i=e[1][1]-e[0][1],a=Math.min(r/(n[1][0]-n[0][0]),i/(n[1][1]-n[0][1])),o=+e[0][0]+(r-a*(n[1][0]+n[0][0]))/2,s=+e[0][1]+(i-a*(n[1][1]+n[0][1]))/2;t.scale(150*a).translate([o,s])}),n)}function Ah(t,e,n){return Mh(t,[[0,0],e],n)}function Oh(t,e,n){return Sh(t,(function(n){var r=+e,i=r/(n[1][0]-n[0][0]),a=(r-i*(n[1][0]+n[0][0]))/2,o=-i*n[0][1];t.scale(150*i).translate([a,o])}),n)}function Nh(t,e,n){return Sh(t,(function(n){var r=+e,i=r/(n[1][1]-n[0][1]),a=-i*n[0][0],o=(r-i*(n[1][1]+n[0][1]))/2;t.scale(150*i).translate([a,o])}),n)}xh.prototype={_radius:4.5,_circle:wh(4.5),pointRadius:function(t){return(t=+t)!==this._radius&&(this._radius=t,this._circle=null),this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){0===this._line&&this._string.push("Z"),this._point=NaN},point:function(t,e){switch(this._point){case 0:this._string.push("M",t,",",e),this._point=1;break;case 1:this._string.push("L",t,",",e);break;default:null==this._circle&&(this._circle=wh(this._radius)),this._string.push("M",t,",",e,this._circle)}},result:function(){if(this._string.length){var t=this._string.join("");return this._string=[],t}return null}},Ch.prototype={constructor:Ch,point:function(t,e){this.stream.point(t,e)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};var jh=Pc(30*Bc);function Dh(t,e){return+e?function(t,e){function n(r,i,a,o,s,c,u,l,f,h,d,p,g,y){var m=u-r,v=l-i,b=m*m+v*v;if(b>4*e&&g--){var _=o+h,x=s+d,w=c+p,k=Wc(_*_+x*x+w*w),T=Gc(w/=k),E=Lc(Lc(w)-1)<Sc||Lc(a-f)<Sc?(a+f)/2:Rc(x,_),C=t(E,T),S=C[0],M=C[1],A=S-r,O=M-i,N=v*A-m*O;(N*N/b>e||Lc((m*A+v*O)/b-.5)>.3||o*h+s*d+c*p<jh)&&(n(r,i,a,o,s,c,S,M,E,_/=k,x/=k,w,g,y),y.point(S,M),n(S,M,E,_,x,w,u,l,f,h,d,p,g,y))}}return function(e){var r,i,a,o,s,c,u,l,f,h,d,p,g={point:y,lineStart:m,lineEnd:b,polygonStart:function(){e.polygonStart(),g.lineStart=_},polygonEnd:function(){e.polygonEnd(),g.lineStart=m}};function y(n,r){n=t(n,r),e.point(n[0],n[1])}function m(){l=NaN,g.point=v,e.lineStart()}function v(r,i){var a=mu([r,i]),o=t(r,i);n(l,f,u,h,d,p,l=o[0],f=o[1],u=r,h=a[0],d=a[1],p=a[2],16,e),e.point(l,f)}function b(){g.point=y,e.lineEnd()}function _(){m(),g.point=x,g.lineEnd=w}function x(t,e){v(r=t,e),i=l,a=f,o=h,s=d,c=p,g.point=v}function w(){n(l,f,u,h,d,p,i,a,r,o,s,c,16,e),g.lineEnd=b,b()}return g}}(t,e):function(t){return Eh({point:function(e,n){e=t(e,n),this.stream.point(e[0],e[1])}})}(t)}var Bh=Eh({point:function(t,e){this.stream.point(t*Bc,e*Bc)}});function Lh(t,e,n,r,i){function a(a,o){return[e+t*(a*=r),n-t*(o*=i)]}return a.invert=function(a,o){return[(a-e)/t*r,(n-o)/t*i]},a}function Ih(t,e,n,r,i,a){var o=Pc(a),s=Uc(a),c=o*t,u=s*t,l=o/t,f=s/t,h=(s*n-o*e)/t,d=(s*e+o*n)/t;function p(t,a){return[c*(t*=r)-u*(a*=i)+e,n-u*t-c*a]}return p.invert=function(t,e){return[r*(l*t-f*e+h),i*(d-f*t-l*e)]},p}function Rh(t){return Ph((function(){return t}))()}function Ph(t){var e,n,r,i,a,o,s,c,u,l,f=150,h=480,d=250,p=0,g=0,y=0,m=0,v=0,b=0,_=1,x=1,w=null,k=ql,T=null,E=xf,C=.5;function S(t){return c(t[0]*Bc,t[1]*Bc)}function M(t){return(t=c.invert(t[0],t[1]))&&[t[0]*Dc,t[1]*Dc]}function A(){var t=Ih(f,0,0,_,x,b).apply(null,e(p,g)),r=(b?Ih:Lh)(f,h-t[0],d-t[1],_,x,b);return n=kl(y,m,v),s=xl(e,r),c=xl(n,s),o=Dh(s,C),O()}function O(){return u=l=null,S}return S.stream=function(t){return u&&l===t?u:u=Bh(function(t){return Eh({point:function(e,n){var r=t(e,n);return this.stream.point(r[0],r[1])}})}(n)(k(o(E(l=t)))))},S.preclip=function(t){return arguments.length?(k=t,w=void 0,O()):k},S.postclip=function(t){return arguments.length?(E=t,T=r=i=a=null,O()):E},S.clipAngle=function(t){return arguments.length?(k=+t?Ul(w=t*Bc):(w=null,ql),O()):w*Dc},S.clipExtent=function(t){return arguments.length?(E=null==t?(T=r=i=a=null,xf):Hl(T=+t[0][0],r=+t[0][1],i=+t[1][0],a=+t[1][1]),O()):null==T?null:[[T,r],[i,a]]},S.scale=function(t){return arguments.length?(f=+t,A()):f},S.translate=function(t){return arguments.length?(h=+t[0],d=+t[1],A()):[h,d]},S.center=function(t){return arguments.length?(p=t[0]%360*Bc,g=t[1]%360*Bc,A()):[p*Dc,g*Dc]},S.rotate=function(t){return arguments.length?(y=t[0]%360*Bc,m=t[1]%360*Bc,v=t.length>2?t[2]%360*Bc:0,A()):[y*Dc,m*Dc,v*Dc]},S.angle=function(t){return arguments.length?(b=t%360*Bc,A()):b*Dc},S.reflectX=function(t){return arguments.length?(_=t?-1:1,A()):_<0},S.reflectY=function(t){return arguments.length?(x=t?-1:1,A()):x<0},S.precision=function(t){return arguments.length?(o=Dh(s,C=t*t),O()):Wc(C)},S.fitExtent=function(t,e){return Mh(S,t,e)},S.fitSize=function(t,e){return Ah(S,t,e)},S.fitWidth=function(t,e){return Oh(S,t,e)},S.fitHeight=function(t,e){return Nh(S,t,e)},function(){return e=t.apply(this,arguments),S.invert=e.invert&&M,A()}}function Fh(t){var e=0,n=Ac/3,r=Ph(t),i=r(e,n);return i.parallels=function(t){return arguments.length?r(e=t[0]*Bc,n=t[1]*Bc):[e*Dc,n*Dc]},i}function zh(t,e){var n=Uc(t),r=(n+Uc(e))/2;if(Lc(r)<Sc)return function(t){var e=Pc(t);function n(t,n){return[t*e,Uc(n)/e]}return n.invert=function(t,n){return[t/e,Gc(n*e)]},n}(t);var i=1+n*(2*r-n),a=Wc(i)/r;function o(t,e){var n=Wc(i-2*r*Uc(e))/r;return[n*Uc(t*=r),a-n*Pc(t)]}return o.invert=function(t,e){var n=a-e,o=Rc(t,Lc(n))*Vc(n);return n*r<0&&(o-=Ac*Vc(t)*Vc(n)),[o/r,Gc((i-(t*t+n*n)*r*r)/(2*r))]},o}function Yh(){return Fh(zh).scale(155.424).center([0,33.6442])}function qh(){return Yh().parallels([29.5,45.5]).scale(1070).translate([480,250]).rotate([96,0]).center([-.6,38.7])}function Uh(){var t,e,n,r,i,a,o=qh(),s=Yh().rotate([154,0]).center([-2,58.5]).parallels([55,65]),c=Yh().rotate([157,0]).center([-3,19.9]).parallels([8,18]),u={point:function(t,e){a=[t,e]}};function l(t){var e=t[0],o=t[1];return a=null,n.point(e,o),a||(r.point(e,o),a)||(i.point(e,o),a)}function f(){return t=e=null,l}return l.invert=function(t){var e=o.scale(),n=o.translate(),r=(t[0]-n[0])/e,i=(t[1]-n[1])/e;return(i>=.12&&i<.234&&r>=-.425&&r<-.214?s:i>=.166&&i<.234&&r>=-.214&&r<-.115?c:o).invert(t)},l.stream=function(n){return t&&e===n?t:(r=[o.stream(e=n),s.stream(n),c.stream(n)],i=r.length,t={point:function(t,e){for(var n=-1;++n<i;)r[n].point(t,e)},sphere:function(){for(var t=-1;++t<i;)r[t].sphere()},lineStart:function(){for(var t=-1;++t<i;)r[t].lineStart()},lineEnd:function(){for(var t=-1;++t<i;)r[t].lineEnd()},polygonStart:function(){for(var t=-1;++t<i;)r[t].polygonStart()},polygonEnd:function(){for(var t=-1;++t<i;)r[t].polygonEnd()}});var r,i},l.precision=function(t){return arguments.length?(o.precision(t),s.precision(t),c.precision(t),f()):o.precision()},l.scale=function(t){return arguments.length?(o.scale(t),s.scale(.35*t),c.scale(t),l.translate(o.translate())):o.scale()},l.translate=function(t){if(!arguments.length)return o.translate();var e=o.scale(),a=+t[0],l=+t[1];return n=o.translate(t).clipExtent([[a-.455*e,l-.238*e],[a+.455*e,l+.238*e]]).stream(u),r=s.translate([a-.307*e,l+.201*e]).clipExtent([[a-.425*e+Sc,l+.12*e+Sc],[a-.214*e-Sc,l+.234*e-Sc]]).stream(u),i=c.translate([a-.205*e,l+.212*e]).clipExtent([[a-.214*e+Sc,l+.166*e+Sc],[a-.115*e-Sc,l+.234*e-Sc]]).stream(u),f()},l.fitExtent=function(t,e){return Mh(l,t,e)},l.fitSize=function(t,e){return Ah(l,t,e)},l.fitWidth=function(t,e){return Oh(l,t,e)},l.fitHeight=function(t,e){return Nh(l,t,e)},l.scale(1070)}function Vh(t){return function(e,n){var r=Pc(e),i=Pc(n),a=t(r*i);return[a*i*Uc(e),a*Uc(n)]}}function Wh(t){return function(e,n){var r=Wc(e*e+n*n),i=t(r),a=Uc(i),o=Pc(i);return[Rc(e*a,r*o),Gc(r&&n*a/r)]}}var Hh=Vh((function(t){return Wc(2/(1+t))}));function $h(){return Rh(Hh).scale(124.75).clipAngle(179.999)}Hh.invert=Wh((function(t){return 2*Gc(t/2)}));var Gh=Vh((function(t){return(t=$c(t))&&t/Uc(t)}));function Xh(){return Rh(Gh).scale(79.4188).clipAngle(179.999)}function Zh(t,e){return[t,Yc(Hc((Oc+e)/2))]}function Kh(){return Qh(Zh).scale(961/jc)}function Qh(t){var e,n,r,i=Rh(t),a=i.center,o=i.scale,s=i.translate,c=i.clipExtent,u=null;function l(){var a=Ac*o(),s=i(Sl(i.rotate()).invert([0,0]));return c(null==u?[[s[0]-a,s[1]-a],[s[0]+a,s[1]+a]]:t===Zh?[[Math.max(s[0]-a,u),e],[Math.min(s[0]+a,n),r]]:[[u,Math.max(s[1]-a,e)],[n,Math.min(s[1]+a,r)]])}return i.scale=function(t){return arguments.length?(o(t),l()):o()},i.translate=function(t){return arguments.length?(s(t),l()):s()},i.center=function(t){return arguments.length?(a(t),l()):a()},i.clipExtent=function(t){return arguments.length?(null==t?u=e=n=r=null:(u=+t[0][0],e=+t[0][1],n=+t[1][0],r=+t[1][1]),l()):null==u?null:[[u,e],[n,r]]},l()}function Jh(t){return Hc((Oc+t)/2)}function td(t,e){var n=Pc(t),r=t===e?Uc(t):Yc(n/Pc(e))/Yc(Jh(e)/Jh(t)),i=n*qc(Jh(t),r)/r;if(!r)return Zh;function a(t,e){i>0?e<-Oc+Sc&&(e=-Oc+Sc):e>Oc-Sc&&(e=Oc-Sc);var n=i/qc(Jh(e),r);return[n*Uc(r*t),i-n*Pc(r*t)]}return a.invert=function(t,e){var n=i-e,a=Vc(r)*Wc(t*t+n*n),o=Rc(t,Lc(n))*Vc(n);return n*r<0&&(o-=Ac*Vc(t)*Vc(n)),[o/r,2*Ic(qc(i/a,1/r))-Oc]},a}function ed(){return Fh(td).scale(109.5).parallels([30,30])}function nd(t,e){return[t,e]}function rd(){return Rh(nd).scale(152.63)}function id(t,e){var n=Pc(t),r=t===e?Uc(t):(n-Pc(e))/(e-t),i=n/r+t;if(Lc(r)<Sc)return nd;function a(t,e){var n=i-e,a=r*t;return[n*Uc(a),i-n*Pc(a)]}return a.invert=function(t,e){var n=i-e,a=Rc(t,Lc(n))*Vc(n);return n*r<0&&(a-=Ac*Vc(t)*Vc(n)),[a/r,i-Vc(r)*Wc(t*t+n*n)]},a}function ad(){return Fh(id).scale(131.154).center([0,13.9389])}Gh.invert=Wh((function(t){return t})),Zh.invert=function(t,e){return[t,2*Ic(zc(e))-Oc]},nd.invert=nd;var od=1.340264,sd=-.081106,cd=893e-6,ud=.003796,ld=Wc(3)/2;function fd(t,e){var n=Gc(ld*Uc(e)),r=n*n,i=r*r*r;return[t*Pc(n)/(ld*(od+3*sd*r+i*(7*cd+9*ud*r))),n*(od+sd*r+i*(cd+ud*r))]}function hd(){return Rh(fd).scale(177.158)}function dd(t,e){var n=Pc(e),r=Pc(t)*n;return[n*Uc(t)/r,Uc(e)/r]}function pd(){return Rh(dd).scale(144.049).clipAngle(60)}function gd(){var t,e,n,r,i,a,o,s=1,c=0,u=0,l=1,f=1,h=0,d=null,p=1,g=1,y=Eh({point:function(t,e){var n=b([t,e]);this.stream.point(n[0],n[1])}}),m=xf;function v(){return p=s*l,g=s*f,a=o=null,b}function b(n){var r=n[0]*p,i=n[1]*g;if(h){var a=i*t-r*e;r=r*t+i*e,i=a}return[r+c,i+u]}return b.invert=function(n){var r=n[0]-c,i=n[1]-u;if(h){var a=i*t+r*e;r=r*t-i*e,i=a}return[r/p,i/g]},b.stream=function(t){return a&&o===t?a:a=y(m(o=t))},b.postclip=function(t){return arguments.length?(m=t,d=n=r=i=null,v()):m},b.clipExtent=function(t){return arguments.length?(m=null==t?(d=n=r=i=null,xf):Hl(d=+t[0][0],n=+t[0][1],r=+t[1][0],i=+t[1][1]),v()):null==d?null:[[d,n],[r,i]]},b.scale=function(t){return arguments.length?(s=+t,v()):s},b.translate=function(t){return arguments.length?(c=+t[0],u=+t[1],v()):[c,u]},b.angle=function(n){return arguments.length?(e=Uc(h=n%360*Bc),t=Pc(h),v()):h*Dc},b.reflectX=function(t){return arguments.length?(l=t?-1:1,v()):l<0},b.reflectY=function(t){return arguments.length?(f=t?-1:1,v()):f<0},b.fitExtent=function(t,e){return Mh(b,t,e)},b.fitSize=function(t,e){return Ah(b,t,e)},b.fitWidth=function(t,e){return Oh(b,t,e)},b.fitHeight=function(t,e){return Nh(b,t,e)},b}function yd(t,e){var n=e*e,r=n*n;return[t*(.8707-.131979*n+r*(r*(.003971*n-.001529*r)-.013791)),e*(1.007226+n*(.015085+r*(.028874*n-.044475-.005916*r)))]}function md(){return Rh(yd).scale(175.295)}function vd(t,e){return[Pc(e)*Uc(t),Uc(e)]}function bd(){return Rh(vd).scale(249.5).clipAngle(90.000001)}function _d(t,e){var n=Pc(e),r=1+Pc(t)*n;return[n*Uc(t)/r,Uc(e)/r]}function xd(){return Rh(_d).scale(250).clipAngle(142)}function wd(t,e){return[Yc(Hc((Oc+e)/2)),-t]}function kd(){var t=Qh(wd),e=t.center,n=t.rotate;return t.center=function(t){return arguments.length?e([-t[1],t[0]]):[(t=e())[1],-t[0]]},t.rotate=function(t){return arguments.length?n([t[0],t[1],t.length>2?t[2]+90:90]):[(t=n())[0],t[1],t[2]-90]},n([0,0,90]).scale(159.155)}function Td(t,e){return t.parent===e.parent?1:2}function Ed(t,e){return t+e.x}function Cd(t,e){return Math.max(t,e.y)}function Sd(){var t=Td,e=1,n=1,r=!1;function i(i){var a,o=0;i.eachAfter((function(e){var n=e.children;n?(e.x=function(t){return t.reduce(Ed,0)/t.length}(n),e.y=function(t){return 1+t.reduce(Cd,0)}(n)):(e.x=a?o+=t(e,a):0,e.y=0,a=e)}));var s=function(t){for(var e;e=t.children;)t=e[0];return t}(i),c=function(t){for(var e;e=t.children;)t=e[e.length-1];return t}(i),u=s.x-t(s,c)/2,l=c.x+t(c,s)/2;return i.eachAfter(r?function(t){t.x=(t.x-i.x)*e,t.y=(i.y-t.y)*n}:function(t){t.x=(t.x-u)/(l-u)*e,t.y=(1-(i.y?t.y/i.y:1))*n})}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function Md(t){var e=0,n=t.children,r=n&&n.length;if(r)for(;--r>=0;)e+=n[r].value;else e=1;t.value=e}function Ad(t,e){var n,r,i,a,o,s=new Dd(t),c=+t.value&&(s.value=t.value),u=[s];for(null==e&&(e=Od);n=u.pop();)if(c&&(n.value=+n.data.value),(i=e(n.data))&&(o=i.length))for(n.children=new Array(o),a=o-1;a>=0;--a)u.push(r=n.children[a]=new Dd(i[a])),r.parent=n,r.depth=n.depth+1;return s.eachBefore(jd)}function Od(t){return t.children}function Nd(t){t.data=t.data.data}function jd(t){var e=0;do{t.height=e}while((t=t.parent)&&t.height<++e)}function Dd(t){this.data=t,this.depth=this.height=0,this.parent=null}fd.invert=function(t,e){for(var n,r=e,i=r*r,a=i*i*i,o=0;o<12&&(a=(i=(r-=n=(r*(od+sd*i+a*(cd+ud*i))-e)/(od+3*sd*i+a*(7*cd+9*ud*i)))*r)*i*i,!(Lc(n)<Mc));++o);return[ld*t*(od+3*sd*i+a*(7*cd+9*ud*i))/Pc(r),Gc(Uc(r)/ld)]},dd.invert=Wh(Ic),yd.invert=function(t,e){var n,r=e,i=25;do{var a=r*r,o=a*a;r-=n=(r*(1.007226+a*(.015085+o*(.028874*a-.044475-.005916*o)))-e)/(1.007226+a*(.045255+o*(.259866*a-.311325-.005916*11*o)))}while(Lc(n)>Sc&&--i>0);return[t/(.8707+(a=r*r)*(a*(a*a*a*(.003971-.001529*a)-.013791)-.131979)),r]},vd.invert=Wh(Gc),_d.invert=Wh((function(t){return 2*Ic(t)})),wd.invert=function(t,e){return[-e,2*Ic(zc(t))-Oc]},Dd.prototype=Ad.prototype={constructor:Dd,count:function(){return this.eachAfter(Md)},each:function(t){var e,n,r,i,a=this,o=[a];do{for(e=o.reverse(),o=[];a=e.pop();)if(t(a),n=a.children)for(r=0,i=n.length;r<i;++r)o.push(n[r])}while(o.length);return this},eachAfter:function(t){for(var e,n,r,i=this,a=[i],o=[];i=a.pop();)if(o.push(i),e=i.children)for(n=0,r=e.length;n<r;++n)a.push(e[n]);for(;i=o.pop();)t(i);return this},eachBefore:function(t){for(var e,n,r=this,i=[r];r=i.pop();)if(t(r),e=r.children)for(n=e.length-1;n>=0;--n)i.push(e[n]);return this},sum:function(t){return this.eachAfter((function(e){for(var n=+t(e.data)||0,r=e.children,i=r&&r.length;--i>=0;)n+=r[i].value;e.value=n}))},sort:function(t){return this.eachBefore((function(e){e.children&&e.children.sort(t)}))},path:function(t){for(var e=this,n=function(t,e){if(t===e)return t;var n=t.ancestors(),r=e.ancestors(),i=null;for(t=n.pop(),e=r.pop();t===e;)i=t,t=n.pop(),e=r.pop();return i}(e,t),r=[e];e!==n;)e=e.parent,r.push(e);for(var i=r.length;t!==n;)r.splice(i,0,t),t=t.parent;return r},ancestors:function(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e},descendants:function(){var t=[];return this.each((function(e){t.push(e)})),t},leaves:function(){var t=[];return this.eachBefore((function(e){e.children||t.push(e)})),t},links:function(){var t=this,e=[];return t.each((function(n){n!==t&&e.push({source:n.parent,target:n})})),e},copy:function(){return Ad(this).eachBefore(Nd)}};var Bd=Array.prototype.slice;function Ld(t){for(var e,n,r=0,i=(t=function(t){for(var e,n,r=t.length;r;)n=Math.random()*r--|0,e=t[r],t[r]=t[n],t[n]=e;return t}(Bd.call(t))).length,a=[];r<i;)e=t[r],n&&Pd(n,e)?++r:(n=zd(a=Id(a,e)),r=0);return n}function Id(t,e){var n,r;if(Fd(e,t))return[e];for(n=0;n<t.length;++n)if(Rd(e,t[n])&&Fd(Yd(t[n],e),t))return[t[n],e];for(n=0;n<t.length-1;++n)for(r=n+1;r<t.length;++r)if(Rd(Yd(t[n],t[r]),e)&&Rd(Yd(t[n],e),t[r])&&Rd(Yd(t[r],e),t[n])&&Fd(qd(t[n],t[r],e),t))return[t[n],t[r],e];throw new Error}function Rd(t,e){var n=t.r-e.r,r=e.x-t.x,i=e.y-t.y;return n<0||n*n<r*r+i*i}function Pd(t,e){var n=t.r-e.r+1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function Fd(t,e){for(var n=0;n<e.length;++n)if(!Pd(t,e[n]))return!1;return!0}function zd(t){switch(t.length){case 1:return function(t){return{x:t.x,y:t.y,r:t.r}}(t[0]);case 2:return Yd(t[0],t[1]);case 3:return qd(t[0],t[1],t[2])}}function Yd(t,e){var n=t.x,r=t.y,i=t.r,a=e.x,o=e.y,s=e.r,c=a-n,u=o-r,l=s-i,f=Math.sqrt(c*c+u*u);return{x:(n+a+c/f*l)/2,y:(r+o+u/f*l)/2,r:(f+i+s)/2}}function qd(t,e,n){var r=t.x,i=t.y,a=t.r,o=e.x,s=e.y,c=e.r,u=n.x,l=n.y,f=n.r,h=r-o,d=r-u,p=i-s,g=i-l,y=c-a,m=f-a,v=r*r+i*i-a*a,b=v-o*o-s*s+c*c,_=v-u*u-l*l+f*f,x=d*p-h*g,w=(p*_-g*b)/(2*x)-r,k=(g*y-p*m)/x,T=(d*b-h*_)/(2*x)-i,E=(h*m-d*y)/x,C=k*k+E*E-1,S=2*(a+w*k+T*E),M=w*w+T*T-a*a,A=-(C?(S+Math.sqrt(S*S-4*C*M))/(2*C):M/S);return{x:r+w+k*A,y:i+T+E*A,r:A}}function Ud(t,e,n){var r,i,a,o,s=t.x-e.x,c=t.y-e.y,u=s*s+c*c;u?(i=e.r+n.r,i*=i,o=t.r+n.r,i>(o*=o)?(r=(u+o-i)/(2*u),a=Math.sqrt(Math.max(0,o/u-r*r)),n.x=t.x-r*s-a*c,n.y=t.y-r*c+a*s):(r=(u+i-o)/(2*u),a=Math.sqrt(Math.max(0,i/u-r*r)),n.x=e.x+r*s-a*c,n.y=e.y+r*c+a*s)):(n.x=e.x+n.r,n.y=e.y)}function Vd(t,e){var n=t.r+e.r-1e-6,r=e.x-t.x,i=e.y-t.y;return n>0&&n*n>r*r+i*i}function Wd(t){var e=t._,n=t.next._,r=e.r+n.r,i=(e.x*n.r+n.x*e.r)/r,a=(e.y*n.r+n.y*e.r)/r;return i*i+a*a}function Hd(t){this._=t,this.next=null,this.previous=null}function $d(t){if(!(i=t.length))return 0;var e,n,r,i,a,o,s,c,u,l,f;if((e=t[0]).x=0,e.y=0,!(i>1))return e.r;if(n=t[1],e.x=-n.r,n.x=e.r,n.y=0,!(i>2))return e.r+n.r;Ud(n,e,r=t[2]),e=new Hd(e),n=new Hd(n),r=new Hd(r),e.next=r.previous=n,n.next=e.previous=r,r.next=n.previous=e;t:for(s=3;s<i;++s){Ud(e._,n._,r=t[s]),r=new Hd(r),c=n.next,u=e.previous,l=n._.r,f=e._.r;do{if(l<=f){if(Vd(c._,r._)){n=c,e.next=n,n.previous=e,--s;continue t}l+=c._.r,c=c.next}else{if(Vd(u._,r._)){(e=u).next=n,n.previous=e,--s;continue t}f+=u._.r,u=u.previous}}while(c!==u.next);for(r.previous=e,r.next=n,e.next=n.previous=n=r,a=Wd(e);(r=r.next)!==n;)(o=Wd(r))<a&&(e=r,a=o);n=e.next}for(e=[n._],r=n;(r=r.next)!==n;)e.push(r._);for(r=Ld(e),s=0;s<i;++s)(e=t[s]).x-=r.x,e.y-=r.y;return r.r}function Gd(t){return $d(t),t}function Xd(t){return null==t?null:Zd(t)}function Zd(t){if("function"!=typeof t)throw new Error;return t}function Kd(){return 0}function Qd(t){return function(){return t}}function Jd(t){return Math.sqrt(t.value)}function tp(){var t=null,e=1,n=1,r=Kd;function i(i){return i.x=e/2,i.y=n/2,t?i.eachBefore(ep(t)).eachAfter(np(r,.5)).eachBefore(rp(1)):i.eachBefore(ep(Jd)).eachAfter(np(Kd,1)).eachAfter(np(r,i.r/Math.min(e,n))).eachBefore(rp(Math.min(e,n)/(2*i.r))),i}return i.radius=function(e){return arguments.length?(t=Xd(e),i):t},i.size=function(t){return arguments.length?(e=+t[0],n=+t[1],i):[e,n]},i.padding=function(t){return arguments.length?(r="function"==typeof t?t:Qd(+t),i):r},i}function ep(t){return function(e){e.children||(e.r=Math.max(0,+t(e)||0))}}function np(t,e){return function(n){if(r=n.children){var r,i,a,o=r.length,s=t(n)*e||0;if(s)for(i=0;i<o;++i)r[i].r+=s;if(a=$d(r),s)for(i=0;i<o;++i)r[i].r-=s;n.r=a+s}}}function rp(t){return function(e){var n=e.parent;e.r*=t,n&&(e.x=n.x+t*e.x,e.y=n.y+t*e.y)}}function ip(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}function ap(t,e,n,r,i){for(var a,o=t.children,s=-1,c=o.length,u=t.value&&(r-e)/t.value;++s<c;)(a=o[s]).y0=n,a.y1=i,a.x0=e,a.x1=e+=a.value*u}function op(){var t=1,e=1,n=0,r=!1;function i(i){var a=i.height+1;return i.x0=i.y0=n,i.x1=t,i.y1=e/a,i.eachBefore(function(t,e){return function(r){r.children&&ap(r,r.x0,t*(r.depth+1)/e,r.x1,t*(r.depth+2)/e);var i=r.x0,a=r.y0,o=r.x1-n,s=r.y1-n;o<i&&(i=o=(i+o)/2),s<a&&(a=s=(a+s)/2),r.x0=i,r.y0=a,r.x1=o,r.y1=s}}(e,a)),r&&i.eachBefore(ip),i}return i.round=function(t){return arguments.length?(r=!!t,i):r},i.size=function(n){return arguments.length?(t=+n[0],e=+n[1],i):[t,e]},i.padding=function(t){return arguments.length?(n=+t,i):n},i}var sp={depth:-1},cp={};function up(t){return t.id}function lp(t){return t.parentId}function fp(){var t=up,e=lp;function n(n){var r,i,a,o,s,c,u,l=n.length,f=new Array(l),h={};for(i=0;i<l;++i)r=n[i],s=f[i]=new Dd(r),null!=(c=t(r,i,n))&&(c+="")&&(h[u="$"+(s.id=c)]=u in h?cp:s);for(i=0;i<l;++i)if(s=f[i],null!=(c=e(n[i],i,n))&&(c+="")){if(!(o=h["$"+c]))throw new Error("missing: "+c);if(o===cp)throw new Error("ambiguous: "+c);o.children?o.children.push(s):o.children=[s],s.parent=o}else{if(a)throw new Error("multiple roots");a=s}if(!a)throw new Error("no root");if(a.parent=sp,a.eachBefore((function(t){t.depth=t.parent.depth+1,--l})).eachBefore(jd),a.parent=null,l>0)throw new Error("cycle");return a}return n.id=function(e){return arguments.length?(t=Zd(e),n):t},n.parentId=function(t){return arguments.length?(e=Zd(t),n):e},n}function hp(t,e){return t.parent===e.parent?1:2}function dp(t){var e=t.children;return e?e[0]:t.t}function pp(t){var e=t.children;return e?e[e.length-1]:t.t}function gp(t,e,n){var r=n/(e.i-t.i);e.c-=r,e.s+=n,t.c+=r,e.z+=n,e.m+=n}function yp(t,e,n){return t.a.parent===e.parent?t.a:n}function mp(t,e){this._=t,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=e}function vp(){var t=hp,e=1,n=1,r=null;function i(i){var c=function(t){for(var e,n,r,i,a,o=new mp(t,0),s=[o];e=s.pop();)if(r=e._.children)for(e.children=new Array(a=r.length),i=a-1;i>=0;--i)s.push(n=e.children[i]=new mp(r[i],i)),n.parent=e;return(o.parent=new mp(null,0)).children=[o],o}(i);if(c.eachAfter(a),c.parent.m=-c.z,c.eachBefore(o),r)i.eachBefore(s);else{var u=i,l=i,f=i;i.eachBefore((function(t){t.x<u.x&&(u=t),t.x>l.x&&(l=t),t.depth>f.depth&&(f=t)}));var h=u===l?1:t(u,l)/2,d=h-u.x,p=e/(l.x+h+d),g=n/(f.depth||1);i.eachBefore((function(t){t.x=(t.x+d)*p,t.y=t.depth*g}))}return i}function a(e){var n=e.children,r=e.parent.children,i=e.i?r[e.i-1]:null;if(n){!function(t){for(var e,n=0,r=0,i=t.children,a=i.length;--a>=0;)(e=i[a]).z+=n,e.m+=n,n+=e.s+(r+=e.c)}(e);var a=(n[0].z+n[n.length-1].z)/2;i?(e.z=i.z+t(e._,i._),e.m=e.z-a):e.z=a}else i&&(e.z=i.z+t(e._,i._));e.parent.A=function(e,n,r){if(n){for(var i,a=e,o=e,s=n,c=a.parent.children[0],u=a.m,l=o.m,f=s.m,h=c.m;s=pp(s),a=dp(a),s&&a;)c=dp(c),(o=pp(o)).a=e,(i=s.z+f-a.z-u+t(s._,a._))>0&&(gp(yp(s,e,r),e,i),u+=i,l+=i),f+=s.m,u+=a.m,h+=c.m,l+=o.m;s&&!pp(o)&&(o.t=s,o.m+=f-l),a&&!dp(c)&&(c.t=a,c.m+=u-h,r=e)}return r}(e,i,e.parent.A||r[0])}function o(t){t._.x=t.z+t.parent.m,t.m+=t.parent.m}function s(t){t.x*=e,t.y=t.depth*n}return i.separation=function(e){return arguments.length?(t=e,i):t},i.size=function(t){return arguments.length?(r=!1,e=+t[0],n=+t[1],i):r?null:[e,n]},i.nodeSize=function(t){return arguments.length?(r=!0,e=+t[0],n=+t[1],i):r?[e,n]:null},i}function bp(t,e,n,r,i){for(var a,o=t.children,s=-1,c=o.length,u=t.value&&(i-n)/t.value;++s<c;)(a=o[s]).x0=e,a.x1=r,a.y0=n,a.y1=n+=a.value*u}mp.prototype=Object.create(Dd.prototype);var _p=(1+Math.sqrt(5))/2;function xp(t,e,n,r,i,a){for(var o,s,c,u,l,f,h,d,p,g,y,m=[],v=e.children,b=0,_=0,x=v.length,w=e.value;b<x;){c=i-n,u=a-r;do{l=v[_++].value}while(!l&&_<x);for(f=h=l,y=l*l*(g=Math.max(u/c,c/u)/(w*t)),p=Math.max(h/y,y/f);_<x;++_){if(l+=s=v[_].value,s<f&&(f=s),s>h&&(h=s),y=l*l*g,(d=Math.max(h/y,y/f))>p){l-=s;break}p=d}m.push(o={value:l,dice:c<u,children:v.slice(b,_)}),o.dice?ap(o,n,r,i,w?r+=u*l/w:a):bp(o,n,r,w?n+=c*l/w:i,a),w-=l,b=_}return m}const wp=function t(e){function n(t,n,r,i,a){xp(e,t,n,r,i,a)}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(_p);function kp(){var t=wp,e=!1,n=1,r=1,i=[0],a=Kd,o=Kd,s=Kd,c=Kd,u=Kd;function l(t){return t.x0=t.y0=0,t.x1=n,t.y1=r,t.eachBefore(f),i=[0],e&&t.eachBefore(ip),t}function f(e){var n=i[e.depth],r=e.x0+n,l=e.y0+n,f=e.x1-n,h=e.y1-n;f<r&&(r=f=(r+f)/2),h<l&&(l=h=(l+h)/2),e.x0=r,e.y0=l,e.x1=f,e.y1=h,e.children&&(n=i[e.depth+1]=a(e)/2,r+=u(e)-n,l+=o(e)-n,(f-=s(e)-n)<r&&(r=f=(r+f)/2),(h-=c(e)-n)<l&&(l=h=(l+h)/2),t(e,r,l,f,h))}return l.round=function(t){return arguments.length?(e=!!t,l):e},l.size=function(t){return arguments.length?(n=+t[0],r=+t[1],l):[n,r]},l.tile=function(e){return arguments.length?(t=Zd(e),l):t},l.padding=function(t){return arguments.length?l.paddingInner(t).paddingOuter(t):l.paddingInner()},l.paddingInner=function(t){return arguments.length?(a="function"==typeof t?t:Qd(+t),l):a},l.paddingOuter=function(t){return arguments.length?l.paddingTop(t).paddingRight(t).paddingBottom(t).paddingLeft(t):l.paddingTop()},l.paddingTop=function(t){return arguments.length?(o="function"==typeof t?t:Qd(+t),l):o},l.paddingRight=function(t){return arguments.length?(s="function"==typeof t?t:Qd(+t),l):s},l.paddingBottom=function(t){return arguments.length?(c="function"==typeof t?t:Qd(+t),l):c},l.paddingLeft=function(t){return arguments.length?(u="function"==typeof t?t:Qd(+t),l):u},l}function Tp(t,e,n,r,i){var a,o,s=t.children,c=s.length,u=new Array(c+1);for(u[0]=o=a=0;a<c;++a)u[a+1]=o+=s[a].value;!function t(e,n,r,i,a,o,c){if(e>=n-1){var l=s[e];return l.x0=i,l.y0=a,l.x1=o,void(l.y1=c)}for(var f=u[e],h=r/2+f,d=e+1,p=n-1;d<p;){var g=d+p>>>1;u[g]<h?d=g+1:p=g}h-u[d-1]<u[d]-h&&e+1<d&&--d;var y=u[d]-f,m=r-y;if(o-i>c-a){var v=(i*m+o*y)/r;t(e,d,y,i,a,v,c),t(d,n,m,v,a,o,c)}else{var b=(a*m+c*y)/r;t(e,d,y,i,a,o,b),t(d,n,m,i,b,o,c)}}(0,c,t.value,e,n,r,i)}function Ep(t,e,n,r,i){(1&t.depth?bp:ap)(t,e,n,r,i)}const Cp=function t(e){function n(t,n,r,i,a){if((o=t._squarify)&&o.ratio===e)for(var o,s,c,u,l,f=-1,h=o.length,d=t.value;++f<h;){for(c=(s=o[f]).children,u=s.value=0,l=c.length;u<l;++u)s.value+=c[u].value;s.dice?ap(s,n,r,i,r+=(a-r)*s.value/d):bp(s,n,r,n+=(i-n)*s.value/d,a),d-=s.value}else t._squarify=o=xp(e,t,n,r,i,a),o.ratio=e}return n.ratio=function(e){return t((e=+e)>1?e:1)},n}(_p);function Sp(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}function Mp(t,e){var n=dn(+t,+e);return function(t){var e=n(t);return e-360*Math.floor(e/360)}}function Ap(t,e){return t=+t,e=+e,function(n){return Math.round(t*(1-n)+e*n)}}var Op=Math.SQRT2;function Np(t){return((t=Math.exp(t))+1/t)/2}function jp(t,e){var n,r,i=t[0],a=t[1],o=t[2],s=e[0],c=e[1],u=e[2],l=s-i,f=c-a,h=l*l+f*f;if(h<1e-12)r=Math.log(u/o)/Op,n=function(t){return[i+t*l,a+t*f,o*Math.exp(Op*t*r)]};else{var d=Math.sqrt(h),p=(u*u-o*o+4*h)/(2*o*2*d),g=(u*u-o*o-4*h)/(2*u*2*d),y=Math.log(Math.sqrt(p*p+1)-p),m=Math.log(Math.sqrt(g*g+1)-g);r=(m-y)/Op,n=function(t){var e,n=t*r,s=Np(y),c=o/(2*d)*(s*(e=Op*n+y,((e=Math.exp(2*e))-1)/(e+1))-function(t){return((t=Math.exp(t))-1/t)/2}(y));return[i+c*l,a+c*f,o*s/Np(Op*n+y)]}}return n.duration=1e3*r,n}function Dp(t){return function(e,n){var r=t((e=an(e)).h,(n=an(n)).h),i=pn(e.s,n.s),a=pn(e.l,n.l),o=pn(e.opacity,n.opacity);return function(t){return e.h=r(t),e.s=i(t),e.l=a(t),e.opacity=o(t),e+""}}}const Bp=Dp(dn);var Lp=Dp(pn);function Ip(t,e){var n=pn((t=Ta(t)).l,(e=Ta(e)).l),r=pn(t.a,e.a),i=pn(t.b,e.b),a=pn(t.opacity,e.opacity);return function(e){return t.l=n(e),t.a=r(e),t.b=i(e),t.opacity=a(e),t+""}}function Rp(t){return function(e,n){var r=t((e=ja(e)).h,(n=ja(n)).h),i=pn(e.c,n.c),a=pn(e.l,n.l),o=pn(e.opacity,n.opacity);return function(t){return e.h=r(t),e.c=i(t),e.l=a(t),e.opacity=o(t),e+""}}}const Pp=Rp(dn);var Fp=Rp(pn);function zp(t){return function e(n){function r(e,r){var i=t((e=Va(e)).h,(r=Va(r)).h),a=pn(e.s,r.s),o=pn(e.l,r.l),s=pn(e.opacity,r.opacity);return function(t){return e.h=i(t),e.s=a(t),e.l=o(Math.pow(t,n)),e.opacity=s(t),e+""}}return n=+n,r.gamma=e,r}(1)}const Yp=zp(dn);var qp=zp(pn);function Up(t,e){for(var n=0,r=e.length-1,i=e[0],a=new Array(r<0?0:r);n<r;)a[n]=t(i,i=e[++n]);return function(t){var e=Math.max(0,Math.min(r-1,Math.floor(t*=r)));return a[e](t-e)}}function Vp(t,e){for(var n=new Array(e),r=0;r<e;++r)n[r]=t(r/(e-1));return n}function Wp(t){for(var e,n=-1,r=t.length,i=t[r-1],a=0;++n<r;)e=i,i=t[n],a+=e[1]*i[0]-e[0]*i[1];return a/2}function Hp(t){for(var e,n,r=-1,i=t.length,a=0,o=0,s=t[i-1],c=0;++r<i;)e=s,s=t[r],c+=n=e[0]*s[1]-s[0]*e[1],a+=(e[0]+s[0])*n,o+=(e[1]+s[1])*n;return[a/(c*=3),o/c]}function $p(t,e,n){return(e[0]-t[0])*(n[1]-t[1])-(e[1]-t[1])*(n[0]-t[0])}function Gp(t,e){return t[0]-e[0]||t[1]-e[1]}function Xp(t){for(var e=t.length,n=[0,1],r=2,i=2;i<e;++i){for(;r>1&&$p(t[n[r-2]],t[n[r-1]],t[i])<=0;)--r;n[r++]=i}return n.slice(0,r)}function Zp(t){if((n=t.length)<3)return null;var e,n,r=new Array(n),i=new Array(n);for(e=0;e<n;++e)r[e]=[+t[e][0],+t[e][1],e];for(r.sort(Gp),e=0;e<n;++e)i[e]=[r[e][0],-r[e][1]];var a=Xp(r),o=Xp(i),s=o[0]===a[0],c=o[o.length-1]===a[a.length-1],u=[];for(e=a.length-1;e>=0;--e)u.push(t[r[a[e]][2]]);for(e=+s;e<o.length-c;++e)u.push(t[r[o[e]][2]]);return u}function Kp(t,e){for(var n,r,i=t.length,a=t[i-1],o=e[0],s=e[1],c=a[0],u=a[1],l=!1,f=0;f<i;++f)n=(a=t[f])[0],(r=a[1])>s!=u>s&&o<(c-n)*(s-r)/(u-r)+n&&(l=!l),c=n,u=r;return l}function Qp(t){for(var e,n,r=-1,i=t.length,a=t[i-1],o=a[0],s=a[1],c=0;++r<i;)e=o,n=s,e-=o=(a=t[r])[0],n-=s=a[1],c+=Math.sqrt(e*e+n*n);return c}function Jp(){return Math.random()}const tg=function t(e){function n(t,n){return t=null==t?0:+t,n=null==n?1:+n,1===arguments.length?(n=t,t=0):n-=t,function(){return e()*n+t}}return n.source=t,n}(Jp),eg=function t(e){function n(t,n){var r,i;return t=null==t?0:+t,n=null==n?1:+n,function(){var a;if(null!=r)a=r,r=null;else do{r=2*e()-1,a=2*e()-1,i=r*r+a*a}while(!i||i>1);return t+n*a*Math.sqrt(-2*Math.log(i)/i)}}return n.source=t,n}(Jp),ng=function t(e){function n(){var t=eg.source(e).apply(this,arguments);return function(){return Math.exp(t())}}return n.source=t,n}(Jp),rg=function t(e){function n(t){return function(){for(var n=0,r=0;r<t;++r)n+=e();return n}}return n.source=t,n}(Jp),ig=function t(e){function n(t){var n=rg.source(e)(t);return function(){return n()/t}}return n.source=t,n}(Jp),ag=function t(e){function n(t){return function(){return-Math.log(1-e())/t}}return n.source=t,n}(Jp);function og(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}function sg(t,e){switch(arguments.length){case 0:break;case 1:this.interpolator(t);break;default:this.interpolator(e).domain(t)}return this}var cg=Array.prototype,ug=cg.map,lg=cg.slice,fg={name:"implicit"};function hg(){var t=na(),e=[],n=[],r=fg;function i(i){var a=i+"",o=t.get(a);if(!o){if(r!==fg)return r;t.set(a,o=e.push(i))}return n[(o-1)%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=na();for(var r,a,o=-1,s=n.length;++o<s;)t.has(a=(r=n[o])+"")||t.set(a,e.push(r));return i},i.range=function(t){return arguments.length?(n=lg.call(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return hg(e,n).unknown(r)},og.apply(i,arguments),i}function dg(){var t,e,n=hg().unknown(void 0),r=n.domain,i=n.range,a=[0,1],o=!1,s=0,c=0,u=.5;function l(){var n=r().length,l=a[1]<a[0],f=a[l-0],h=a[1-l];t=(h-f)/Math.max(1,n-s+2*c),o&&(t=Math.floor(t)),f+=(h-f-t*(n-s))*u,e=t*(1-s),o&&(f=Math.round(f),e=Math.round(e));var d=k(n).map((function(e){return f+t*e}));return i(l?d.reverse():d)}return delete n.unknown,n.domain=function(t){return arguments.length?(r(t),l()):r()},n.range=function(t){return arguments.length?(a=[+t[0],+t[1]],l()):a.slice()},n.rangeRound=function(t){return a=[+t[0],+t[1]],o=!0,l()},n.bandwidth=function(){return e},n.step=function(){return t},n.round=function(t){return arguments.length?(o=!!t,l()):o},n.padding=function(t){return arguments.length?(s=Math.min(1,c=+t),l()):s},n.paddingInner=function(t){return arguments.length?(s=Math.min(1,t),l()):s},n.paddingOuter=function(t){return arguments.length?(c=+t,l()):c},n.align=function(t){return arguments.length?(u=Math.max(0,Math.min(1,t)),l()):u},n.copy=function(){return dg(r(),a).round(o).paddingInner(s).paddingOuter(c).align(u)},og.apply(l(),arguments)}function pg(t){var e=t.copy;return t.padding=t.paddingOuter,delete t.paddingInner,delete t.paddingOuter,t.copy=function(){return pg(e())},t}function gg(){return pg(dg.apply(null,arguments).paddingInner(1))}function yg(t){return+t}var mg=[0,1];function vg(t){return t}function bg(t,e){return(e-=t=+t)?function(n){return(n-t)/e}:(n=isNaN(e)?NaN:.5,function(){return n});var n}function _g(t){var e,n=t[0],r=t[t.length-1];return n>r&&(e=n,n=r,r=e),function(t){return Math.max(n,Math.min(r,t))}}function xg(t,e,n){var r=t[0],i=t[1],a=e[0],o=e[1];return i<r?(r=bg(i,r),a=n(o,a)):(r=bg(r,i),a=n(a,o)),function(t){return a(r(t))}}function wg(t,e,n){var r=Math.min(t.length,e.length)-1,i=new Array(r),a=new Array(r),o=-1;for(t[r]<t[0]&&(t=t.slice().reverse(),e=e.slice().reverse());++o<r;)i[o]=bg(t[o],t[o+1]),a[o]=n(e[o],e[o+1]);return function(e){var n=u(t,e,1,r)-1;return a[n](i[n](e))}}function kg(t,e){return e.domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())}function Tg(){var t,e,n,r,i,a,o=mg,s=mg,c=An,u=vg;function l(){return r=Math.min(o.length,s.length)>2?wg:xg,i=a=null,f}function f(e){return isNaN(e=+e)?n:(i||(i=r(o.map(t),s,c)))(t(u(e)))}return f.invert=function(n){return u(e((a||(a=r(s,o.map(t),Tn)))(n)))},f.domain=function(t){return arguments.length?(o=ug.call(t,yg),u===vg||(u=_g(o)),l()):o.slice()},f.range=function(t){return arguments.length?(s=lg.call(t),l()):s.slice()},f.rangeRound=function(t){return s=lg.call(t),c=Ap,l()},f.clamp=function(t){return arguments.length?(u=t?_g(o):vg,f):u!==vg},f.interpolate=function(t){return arguments.length?(c=t,l()):c},f.unknown=function(t){return arguments.length?(n=t,f):n},function(n,r){return t=n,e=r,l()}}function Eg(t,e){return Tg()(t,e)}function Cg(t,e,n,r){var i,a=A(t,e,n);switch((r=cc(null==r?",f":r)).type){case"s":var o=Math.max(Math.abs(t),Math.abs(e));return null!=r.precision||isNaN(i=xc(a,o))||(r.precision=i),gc(r,o);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(i=wc(a,Math.max(Math.abs(t),Math.abs(e))))||(r.precision=i-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(i=_c(a))||(r.precision=i-2*("%"===r.type))}return pc(r)}function Sg(t){var e=t.domain;return t.ticks=function(t){var n=e();return S(n[0],n[n.length-1],null==t?10:t)},t.tickFormat=function(t,n){var r=e();return Cg(r[0],r[r.length-1],null==t?10:t,n)},t.nice=function(n){null==n&&(n=10);var r,i=e(),a=0,o=i.length-1,s=i[a],c=i[o];return c<s&&(r=s,s=c,c=r,r=a,a=o,o=r),(r=M(s,c,n))>0?r=M(s=Math.floor(s/r)*r,c=Math.ceil(c/r)*r,n):r<0&&(r=M(s=Math.ceil(s*r)/r,c=Math.floor(c*r)/r,n)),r>0?(i[a]=Math.floor(s/r)*r,i[o]=Math.ceil(c/r)*r,e(i)):r<0&&(i[a]=Math.ceil(s*r)/r,i[o]=Math.floor(c*r)/r,e(i)),t},t}function Mg(){var t=Eg(vg,vg);return t.copy=function(){return kg(t,Mg())},og.apply(t,arguments),Sg(t)}function Ag(t){var e;function n(t){return isNaN(t=+t)?e:t}return n.invert=n,n.domain=n.range=function(e){return arguments.length?(t=ug.call(e,yg),n):t.slice()},n.unknown=function(t){return arguments.length?(e=t,n):e},n.copy=function(){return Ag(t).unknown(e)},t=arguments.length?ug.call(t,yg):[0,1],Sg(n)}function Og(t,e){var n,r=0,i=(t=t.slice()).length-1,a=t[r],o=t[i];return o<a&&(n=r,r=i,i=n,n=a,a=o,o=n),t[r]=e.floor(a),t[i]=e.ceil(o),t}function Ng(t){return Math.log(t)}function jg(t){return Math.exp(t)}function Dg(t){return-Math.log(-t)}function Bg(t){return-Math.exp(-t)}function Lg(t){return isFinite(t)?+("1e"+t):t<0?0:t}function Ig(t){return function(e){return-t(-e)}}function Rg(t){var e,n,r=t(Ng,jg),i=r.domain,a=10;function o(){return e=function(t){return t===Math.E?Math.log:10===t&&Math.log10||2===t&&Math.log2||(t=Math.log(t),function(e){return Math.log(e)/t})}(a),n=function(t){return 10===t?Lg:t===Math.E?Math.exp:function(e){return Math.pow(t,e)}}(a),i()[0]<0?(e=Ig(e),n=Ig(n),t(Dg,Bg)):t(Ng,jg),r}return r.base=function(t){return arguments.length?(a=+t,o()):a},r.domain=function(t){return arguments.length?(i(t),o()):i()},r.ticks=function(t){var r,o=i(),s=o[0],c=o[o.length-1];(r=c<s)&&(h=s,s=c,c=h);var u,l,f,h=e(s),d=e(c),p=null==t?10:+t,g=[];if(!(a%1)&&d-h<p){if(h=Math.round(h)-1,d=Math.round(d)+1,s>0){for(;h<d;++h)for(l=1,u=n(h);l<a;++l)if(!((f=u*l)<s)){if(f>c)break;g.push(f)}}else for(;h<d;++h)for(l=a-1,u=n(h);l>=1;--l)if(!((f=u*l)<s)){if(f>c)break;g.push(f)}}else g=S(h,d,Math.min(d-h,p)).map(n);return r?g.reverse():g},r.tickFormat=function(t,i){if(null==i&&(i=10===a?".0e":","),"function"!=typeof i&&(i=pc(i)),t===1/0)return i;null==t&&(t=10);var o=Math.max(1,a*t/r.ticks().length);return function(t){var r=t/n(Math.round(e(t)));return r*a<a-.5&&(r*=a),r<=o?i(t):""}},r.nice=function(){return i(Og(i(),{floor:function(t){return n(Math.floor(e(t)))},ceil:function(t){return n(Math.ceil(e(t)))}}))},r}function Pg(){var t=Rg(Tg()).domain([1,10]);return t.copy=function(){return kg(t,Pg()).base(t.base())},og.apply(t,arguments),t}function Fg(t){return function(e){return Math.sign(e)*Math.log1p(Math.abs(e/t))}}function zg(t){return function(e){return Math.sign(e)*Math.expm1(Math.abs(e))*t}}function Yg(t){var e=1,n=t(Fg(e),zg(e));return n.constant=function(n){return arguments.length?t(Fg(e=+n),zg(e)):e},Sg(n)}function qg(){var t=Yg(Tg());return t.copy=function(){return kg(t,qg()).constant(t.constant())},og.apply(t,arguments)}function Ug(t){return function(e){return e<0?-Math.pow(-e,t):Math.pow(e,t)}}function Vg(t){return t<0?-Math.sqrt(-t):Math.sqrt(t)}function Wg(t){return t<0?-t*t:t*t}function Hg(t){var e=t(vg,vg),n=1;function r(){return 1===n?t(vg,vg):.5===n?t(Vg,Wg):t(Ug(n),Ug(1/n))}return e.exponent=function(t){return arguments.length?(n=+t,r()):n},Sg(e)}function $g(){var t=Hg(Tg());return t.copy=function(){return kg(t,$g()).exponent(t.exponent())},og.apply(t,arguments),t}function Gg(){return $g.apply(null,arguments).exponent(.5)}function Xg(){var t,e=[],n=[],r=[];function a(){var t=0,i=Math.max(1,n.length);for(r=new Array(i-1);++t<i;)r[t-1]=j(e,t/i);return o}function o(e){return isNaN(e=+e)?t:n[u(r,e)]}return o.invertExtent=function(t){var i=n.indexOf(t);return i<0?[NaN,NaN]:[i>0?r[i-1]:e[0],i<r.length?r[i]:e[e.length-1]]},o.domain=function(t){if(!arguments.length)return e.slice();e=[];for(var n,r=0,o=t.length;r<o;++r)null==(n=t[r])||isNaN(n=+n)||e.push(n);return e.sort(i),a()},o.range=function(t){return arguments.length?(n=lg.call(t),a()):n.slice()},o.unknown=function(e){return arguments.length?(t=e,o):t},o.quantiles=function(){return r.slice()},o.copy=function(){return Xg().domain(e).range(n).unknown(t)},og.apply(o,arguments)}function Zg(){var t,e=0,n=1,r=1,i=[.5],a=[0,1];function o(e){return e<=e?a[u(i,e,0,r)]:t}function s(){var t=-1;for(i=new Array(r);++t<r;)i[t]=((t+1)*n-(t-r)*e)/(r+1);return o}return o.domain=function(t){return arguments.length?(e=+t[0],n=+t[1],s()):[e,n]},o.range=function(t){return arguments.length?(r=(a=lg.call(t)).length-1,s()):a.slice()},o.invertExtent=function(t){var o=a.indexOf(t);return o<0?[NaN,NaN]:o<1?[e,i[0]]:o>=r?[i[r-1],n]:[i[o-1],i[o]]},o.unknown=function(e){return arguments.length?(t=e,o):o},o.thresholds=function(){return i.slice()},o.copy=function(){return Zg().domain([e,n]).range(a).unknown(t)},og.apply(Sg(o),arguments)}function Kg(){var t,e=[.5],n=[0,1],r=1;function i(i){return i<=i?n[u(e,i,0,r)]:t}return i.domain=function(t){return arguments.length?(e=lg.call(t),r=Math.min(e.length,n.length-1),i):e.slice()},i.range=function(t){return arguments.length?(n=lg.call(t),r=Math.min(e.length,n.length-1),i):n.slice()},i.invertExtent=function(t){var r=n.indexOf(t);return[e[r-1],e[r]]},i.unknown=function(e){return arguments.length?(t=e,i):t},i.copy=function(){return Kg().domain(e).range(n).unknown(t)},og.apply(i,arguments)}var Qg=new Date,Jg=new Date;function ty(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=function(e){return t(e=new Date(+e)),e},i.ceil=function(n){return t(n=new Date(n-1)),e(n,1),t(n),n},i.round=function(t){var e=i(t),n=i.ceil(t);return t-e<n-t?e:n},i.offset=function(t,n){return e(t=new Date(+t),null==n?1:Math.floor(n)),t},i.range=function(n,r,a){var o,s=[];if(n=i.ceil(n),a=null==a?1:Math.floor(a),!(n<r&&a>0))return s;do{s.push(o=new Date(+n)),e(n,a),t(n)}while(o<n&&n<r);return s},i.filter=function(n){return ty((function(e){if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),(function(t,r){if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););}))},n&&(i.count=function(e,r){return Qg.setTime(+e),Jg.setTime(+r),t(Qg),t(Jg),Math.floor(n(Qg,Jg))},i.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?function(e){return r(e)%t==0}:function(e){return i.count(0,e)%t==0}):i:null}),i}var ey=ty((function(t){t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,e){t.setFullYear(t.getFullYear()+e)}),(function(t,e){return e.getFullYear()-t.getFullYear()}),(function(t){return t.getFullYear()}));ey.every=function(t){return isFinite(t=Math.floor(t))&&t>0?ty((function(e){e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,n){e.setFullYear(e.getFullYear()+n*t)})):null};const ny=ey;var ry=ey.range,iy=ty((function(t){t.setDate(1),t.setHours(0,0,0,0)}),(function(t,e){t.setMonth(t.getMonth()+e)}),(function(t,e){return e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())}),(function(t){return t.getMonth()}));const ay=iy;var oy=iy.range,sy=1e3,cy=6e4,uy=36e5,ly=864e5,fy=6048e5;function hy(t){return ty((function(e){e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+7*e)}),(function(t,e){return(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*cy)/fy}))}var dy=hy(0),py=hy(1),gy=hy(2),yy=hy(3),my=hy(4),vy=hy(5),by=hy(6),_y=dy.range,xy=py.range,wy=gy.range,ky=yy.range,Ty=my.range,Ey=vy.range,Cy=by.range,Sy=ty((function(t){t.setHours(0,0,0,0)}),(function(t,e){t.setDate(t.getDate()+e)}),(function(t,e){return(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*cy)/ly}),(function(t){return t.getDate()-1}));const My=Sy;var Ay=Sy.range,Oy=ty((function(t){t.setTime(t-t.getMilliseconds()-t.getSeconds()*sy-t.getMinutes()*cy)}),(function(t,e){t.setTime(+t+e*uy)}),(function(t,e){return(e-t)/uy}),(function(t){return t.getHours()}));const Ny=Oy;var jy=Oy.range,Dy=ty((function(t){t.setTime(t-t.getMilliseconds()-t.getSeconds()*sy)}),(function(t,e){t.setTime(+t+e*cy)}),(function(t,e){return(e-t)/cy}),(function(t){return t.getMinutes()}));const By=Dy;var Ly=Dy.range,Iy=ty((function(t){t.setTime(t-t.getMilliseconds())}),(function(t,e){t.setTime(+t+e*sy)}),(function(t,e){return(e-t)/sy}),(function(t){return t.getUTCSeconds()}));const Ry=Iy;var Py=Iy.range,Fy=ty((function(){}),(function(t,e){t.setTime(+t+e)}),(function(t,e){return e-t}));Fy.every=function(t){return t=Math.floor(t),isFinite(t)&&t>0?t>1?ty((function(e){e.setTime(Math.floor(e/t)*t)}),(function(e,n){e.setTime(+e+n*t)}),(function(e,n){return(n-e)/t})):Fy:null};const zy=Fy;var Yy=Fy.range;function qy(t){return ty((function(e){e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+7*e)}),(function(t,e){return(e-t)/fy}))}var Uy=qy(0),Vy=qy(1),Wy=qy(2),Hy=qy(3),$y=qy(4),Gy=qy(5),Xy=qy(6),Zy=Uy.range,Ky=Vy.range,Qy=Wy.range,Jy=Hy.range,tm=$y.range,em=Gy.range,nm=Xy.range,rm=ty((function(t){t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCDate(t.getUTCDate()+e)}),(function(t,e){return(e-t)/ly}),(function(t){return t.getUTCDate()-1}));const im=rm;var am=rm.range,om=ty((function(t){t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCFullYear(t.getUTCFullYear()+e)}),(function(t,e){return e.getUTCFullYear()-t.getUTCFullYear()}),(function(t){return t.getUTCFullYear()}));om.every=function(t){return isFinite(t=Math.floor(t))&&t>0?ty((function(e){e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,n){e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null};const sm=om;var cm=om.range;function um(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function lm(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function fm(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}function hm(t){var e=t.dateTime,n=t.date,r=t.time,i=t.periods,a=t.days,o=t.shortDays,s=t.months,c=t.shortMonths,u=Tm(i),l=Em(i),f=Tm(a),h=Em(a),d=Tm(o),p=Em(o),g=Tm(s),y=Em(s),m=Tm(c),v=Em(c),b={a:function(t){return o[t.getDay()]},A:function(t){return a[t.getDay()]},b:function(t){return c[t.getMonth()]},B:function(t){return s[t.getMonth()]},c:null,d:Hm,e:Hm,f:Km,g:cv,G:lv,H:$m,I:Gm,j:Xm,L:Zm,m:Qm,M:Jm,p:function(t){return i[+(t.getHours()>=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:Dv,s:Bv,S:tv,u:ev,U:nv,V:iv,w:av,W:ov,x:null,X:null,y:sv,Y:uv,Z:fv,"%":jv},_={a:function(t){return o[t.getUTCDay()]},A:function(t){return a[t.getUTCDay()]},b:function(t){return c[t.getUTCMonth()]},B:function(t){return s[t.getUTCMonth()]},c:null,d:hv,e:hv,f:mv,g:Mv,G:Ov,H:dv,I:pv,j:gv,L:yv,m:vv,M:bv,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:Dv,s:Bv,S:_v,u:xv,U:wv,V:Tv,w:Ev,W:Cv,x:null,X:null,y:Sv,Y:Av,Z:Nv,"%":jv},x={a:function(t,e,n){var r=d.exec(e.slice(n));return r?(t.w=p[r[0].toLowerCase()],n+r[0].length):-1},A:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.w=h[r[0].toLowerCase()],n+r[0].length):-1},b:function(t,e,n){var r=m.exec(e.slice(n));return r?(t.m=v[r[0].toLowerCase()],n+r[0].length):-1},B:function(t,e,n){var r=g.exec(e.slice(n));return r?(t.m=y[r[0].toLowerCase()],n+r[0].length):-1},c:function(t,n,r){return T(t,e,n,r)},d:Im,e:Im,f:qm,g:jm,G:Nm,H:Pm,I:Pm,j:Rm,L:Ym,m:Lm,M:Fm,p:function(t,e,n){var r=u.exec(e.slice(n));return r?(t.p=l[r[0].toLowerCase()],n+r[0].length):-1},q:Bm,Q:Vm,s:Wm,S:zm,u:Sm,U:Mm,V:Am,w:Cm,W:Om,x:function(t,e,r){return T(t,n,e,r)},X:function(t,e,n){return T(t,r,e,n)},y:jm,Y:Nm,Z:Dm,"%":Um};function w(t,e){return function(n){var r,i,a,o=[],s=-1,c=0,u=t.length;for(n instanceof Date||(n=new Date(+n));++s<u;)37===t.charCodeAt(s)&&(o.push(t.slice(c,s)),null!=(i=vm[r=t.charAt(++s)])?r=t.charAt(++s):i="e"===r?" ":"0",(a=e[r])&&(r=a(n,i)),o.push(r),c=s+1);return o.push(t.slice(c,s)),o.join("")}}function k(t,e){return function(n){var r,i,a=fm(1900,void 0,1);if(T(a,t,n+="",0)!=n.length)return null;if("Q"in a)return new Date(a.Q);if("s"in a)return new Date(1e3*a.s+("L"in a?a.L:0));if(e&&!("Z"in a)&&(a.Z=0),"p"in a&&(a.H=a.H%12+12*a.p),void 0===a.m&&(a.m="q"in a?a.q:0),"V"in a){if(a.V<1||a.V>53)return null;"w"in a||(a.w=1),"Z"in a?(i=(r=lm(fm(a.y,0,1))).getUTCDay(),r=i>4||0===i?Vy.ceil(r):Vy(r),r=im.offset(r,7*(a.V-1)),a.y=r.getUTCFullYear(),a.m=r.getUTCMonth(),a.d=r.getUTCDate()+(a.w+6)%7):(i=(r=um(fm(a.y,0,1))).getDay(),r=i>4||0===i?py.ceil(r):py(r),r=My.offset(r,7*(a.V-1)),a.y=r.getFullYear(),a.m=r.getMonth(),a.d=r.getDate()+(a.w+6)%7)}else("W"in a||"U"in a)&&("w"in a||(a.w="u"in a?a.u%7:"W"in a?1:0),i="Z"in a?lm(fm(a.y,0,1)).getUTCDay():um(fm(a.y,0,1)).getDay(),a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(i+5)%7:a.w+7*a.U-(i+6)%7);return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,lm(a)):um(a)}}function T(t,e,n,r){for(var i,a,o=0,s=e.length,c=n.length;o<s;){if(r>=c)return-1;if(37===(i=e.charCodeAt(o++))){if(i=e.charAt(o++),!(a=x[i in vm?e.charAt(o++):i])||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return b.x=w(n,b),b.X=w(r,b),b.c=w(e,b),_.x=w(n,_),_.X=w(r,_),_.c=w(e,_),{format:function(t){var e=w(t+="",b);return e.toString=function(){return t},e},parse:function(t){var e=k(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=w(t+="",_);return e.toString=function(){return t},e},utcParse:function(t){var e=k(t+="",!0);return e.toString=function(){return t},e}}}var dm,pm,gm,ym,mm,vm={"-":"",_:" ",0:"0"},bm=/^\s*\d+/,_m=/^%/,xm=/[\\^$*+?|[\]().{}]/g;function wm(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",a=i.length;return r+(a<n?new Array(n-a+1).join(e)+i:i)}function km(t){return t.replace(xm,"\\$&")}function Tm(t){return new RegExp("^(?:"+t.map(km).join("|")+")","i")}function Em(t){for(var e={},n=-1,r=t.length;++n<r;)e[t[n].toLowerCase()]=n;return e}function Cm(t,e,n){var r=bm.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function Sm(t,e,n){var r=bm.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function Mm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function Am(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function Om(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function Nm(t,e,n){var r=bm.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function jm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function Dm(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function Bm(t,e,n){var r=bm.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function Lm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function Im(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function Rm(t,e,n){var r=bm.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function Pm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function Fm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function zm(t,e,n){var r=bm.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function Ym(t,e,n){var r=bm.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function qm(t,e,n){var r=bm.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function Um(t,e,n){var r=_m.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function Vm(t,e,n){var r=bm.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function Wm(t,e,n){var r=bm.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function Hm(t,e){return wm(t.getDate(),e,2)}function $m(t,e){return wm(t.getHours(),e,2)}function Gm(t,e){return wm(t.getHours()%12||12,e,2)}function Xm(t,e){return wm(1+My.count(ny(t),t),e,3)}function Zm(t,e){return wm(t.getMilliseconds(),e,3)}function Km(t,e){return Zm(t,e)+"000"}function Qm(t,e){return wm(t.getMonth()+1,e,2)}function Jm(t,e){return wm(t.getMinutes(),e,2)}function tv(t,e){return wm(t.getSeconds(),e,2)}function ev(t){var e=t.getDay();return 0===e?7:e}function nv(t,e){return wm(dy.count(ny(t)-1,t),e,2)}function rv(t){var e=t.getDay();return e>=4||0===e?my(t):my.ceil(t)}function iv(t,e){return t=rv(t),wm(my.count(ny(t),t)+(4===ny(t).getDay()),e,2)}function av(t){return t.getDay()}function ov(t,e){return wm(py.count(ny(t)-1,t),e,2)}function sv(t,e){return wm(t.getFullYear()%100,e,2)}function cv(t,e){return wm((t=rv(t)).getFullYear()%100,e,2)}function uv(t,e){return wm(t.getFullYear()%1e4,e,4)}function lv(t,e){var n=t.getDay();return wm((t=n>=4||0===n?my(t):my.ceil(t)).getFullYear()%1e4,e,4)}function fv(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+wm(e/60|0,"0",2)+wm(e%60,"0",2)}function hv(t,e){return wm(t.getUTCDate(),e,2)}function dv(t,e){return wm(t.getUTCHours(),e,2)}function pv(t,e){return wm(t.getUTCHours()%12||12,e,2)}function gv(t,e){return wm(1+im.count(sm(t),t),e,3)}function yv(t,e){return wm(t.getUTCMilliseconds(),e,3)}function mv(t,e){return yv(t,e)+"000"}function vv(t,e){return wm(t.getUTCMonth()+1,e,2)}function bv(t,e){return wm(t.getUTCMinutes(),e,2)}function _v(t,e){return wm(t.getUTCSeconds(),e,2)}function xv(t){var e=t.getUTCDay();return 0===e?7:e}function wv(t,e){return wm(Uy.count(sm(t)-1,t),e,2)}function kv(t){var e=t.getUTCDay();return e>=4||0===e?$y(t):$y.ceil(t)}function Tv(t,e){return t=kv(t),wm($y.count(sm(t),t)+(4===sm(t).getUTCDay()),e,2)}function Ev(t){return t.getUTCDay()}function Cv(t,e){return wm(Vy.count(sm(t)-1,t),e,2)}function Sv(t,e){return wm(t.getUTCFullYear()%100,e,2)}function Mv(t,e){return wm((t=kv(t)).getUTCFullYear()%100,e,2)}function Av(t,e){return wm(t.getUTCFullYear()%1e4,e,4)}function Ov(t,e){var n=t.getUTCDay();return wm((t=n>=4||0===n?$y(t):$y.ceil(t)).getUTCFullYear()%1e4,e,4)}function Nv(){return"+0000"}function jv(){return"%"}function Dv(t){return+t}function Bv(t){return Math.floor(+t/1e3)}function Lv(t){return dm=hm(t),pm=dm.format,gm=dm.parse,ym=dm.utcFormat,mm=dm.utcParse,dm}Lv({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});var Iv=31536e6;function Rv(t){return new Date(t)}function Pv(t){return t instanceof Date?+t:+new Date(+t)}function Fv(t,e,n,r,i,o,s,c,u){var l=Eg(vg,vg),f=l.invert,h=l.domain,d=u(".%L"),p=u(":%S"),g=u("%I:%M"),y=u("%I %p"),m=u("%a %d"),v=u("%b %d"),b=u("%B"),_=u("%Y"),x=[[s,1,1e3],[s,5,5e3],[s,15,15e3],[s,30,3e4],[o,1,6e4],[o,5,3e5],[o,15,9e5],[o,30,18e5],[i,1,36e5],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,864e5],[r,2,1728e5],[n,1,6048e5],[e,1,2592e6],[e,3,7776e6],[t,1,Iv]];function w(a){return(s(a)<a?d:o(a)<a?p:i(a)<a?g:r(a)<a?y:e(a)<a?n(a)<a?m:v:t(a)<a?b:_)(a)}function k(e,n,r,i){if(null==e&&(e=10),"number"==typeof e){var o=Math.abs(r-n)/e,s=a((function(t){return t[2]})).right(x,o);s===x.length?(i=A(n/Iv,r/Iv,e),e=t):s?(i=(s=x[o/x[s-1][2]<x[s][2]/o?s-1:s])[1],e=s[0]):(i=Math.max(A(n,r,e),1),e=c)}return null==i?e:e.every(i)}return l.invert=function(t){return new Date(f(t))},l.domain=function(t){return arguments.length?h(ug.call(t,Pv)):h().map(Rv)},l.ticks=function(t,e){var n,r=h(),i=r[0],a=r[r.length-1],o=a<i;return o&&(n=i,i=a,a=n),n=(n=k(t,i,a,e))?n.range(i,a+1):[],o?n.reverse():n},l.tickFormat=function(t,e){return null==e?w:u(e)},l.nice=function(t,e){var n=h();return(t=k(t,n[0],n[n.length-1],e))?h(Og(n,t)):l},l.copy=function(){return kg(l,Fv(t,e,n,r,i,o,s,c,u))},l}function zv(){return og.apply(Fv(ny,ay,dy,My,Ny,By,Ry,zy,pm).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}var Yv=ty((function(t){t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),(function(t,e){t.setUTCMonth(t.getUTCMonth()+e)}),(function(t,e){return e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())}),(function(t){return t.getUTCMonth()}));const qv=Yv;var Uv=Yv.range,Vv=ty((function(t){t.setUTCMinutes(0,0,0)}),(function(t,e){t.setTime(+t+e*uy)}),(function(t,e){return(e-t)/uy}),(function(t){return t.getUTCHours()}));const Wv=Vv;var Hv=Vv.range,$v=ty((function(t){t.setUTCSeconds(0,0)}),(function(t,e){t.setTime(+t+e*cy)}),(function(t,e){return(e-t)/cy}),(function(t){return t.getUTCMinutes()}));const Gv=$v;var Xv=$v.range;function Zv(){return og.apply(Fv(sm,qv,Uy,im,Wv,Gv,Ry,zy,ym).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Kv(){var t,e,n,r,i,a=0,o=1,s=vg,c=!1;function u(e){return isNaN(e=+e)?i:s(0===n?.5:(e=(r(e)-t)*n,c?Math.max(0,Math.min(1,e)):e))}return u.domain=function(i){return arguments.length?(t=r(a=+i[0]),e=r(o=+i[1]),n=t===e?0:1/(e-t),u):[a,o]},u.clamp=function(t){return arguments.length?(c=!!t,u):c},u.interpolator=function(t){return arguments.length?(s=t,u):s},u.unknown=function(t){return arguments.length?(i=t,u):i},function(i){return r=i,t=i(a),e=i(o),n=t===e?0:1/(e-t),u}}function Qv(t,e){return e.domain(t.domain()).interpolator(t.interpolator()).clamp(t.clamp()).unknown(t.unknown())}function Jv(){var t=Sg(Kv()(vg));return t.copy=function(){return Qv(t,Jv())},sg.apply(t,arguments)}function tb(){var t=Rg(Kv()).domain([1,10]);return t.copy=function(){return Qv(t,tb()).base(t.base())},sg.apply(t,arguments)}function eb(){var t=Yg(Kv());return t.copy=function(){return Qv(t,eb()).constant(t.constant())},sg.apply(t,arguments)}function nb(){var t=Hg(Kv());return t.copy=function(){return Qv(t,nb()).exponent(t.exponent())},sg.apply(t,arguments)}function rb(){return nb.apply(null,arguments).exponent(.5)}function ib(){var t=[],e=vg;function n(n){if(!isNaN(n=+n))return e((u(t,n)-1)/(t.length-1))}return n.domain=function(e){if(!arguments.length)return t.slice();t=[];for(var r,a=0,o=e.length;a<o;++a)null==(r=e[a])||isNaN(r=+r)||t.push(r);return t.sort(i),n},n.interpolator=function(t){return arguments.length?(e=t,n):e},n.copy=function(){return ib(e).domain(t)},sg.apply(n,arguments)}function ab(){var t,e,n,r,i,a,o,s=0,c=.5,u=1,l=vg,f=!1;function h(t){return isNaN(t=+t)?o:(t=.5+((t=+a(t))-e)*(t<e?r:i),l(f?Math.max(0,Math.min(1,t)):t))}return h.domain=function(o){return arguments.length?(t=a(s=+o[0]),e=a(c=+o[1]),n=a(u=+o[2]),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),h):[s,c,u]},h.clamp=function(t){return arguments.length?(f=!!t,h):f},h.interpolator=function(t){return arguments.length?(l=t,h):l},h.unknown=function(t){return arguments.length?(o=t,h):o},function(o){return a=o,t=o(s),e=o(c),n=o(u),r=t===e?0:.5/(e-t),i=e===n?0:.5/(n-e),h}}function ob(){var t=Sg(ab()(vg));return t.copy=function(){return Qv(t,ob())},sg.apply(t,arguments)}function sb(){var t=Rg(ab()).domain([.1,1,10]);return t.copy=function(){return Qv(t,sb()).base(t.base())},sg.apply(t,arguments)}function cb(){var t=Yg(ab());return t.copy=function(){return Qv(t,cb()).constant(t.constant())},sg.apply(t,arguments)}function ub(){var t=Hg(ab());return t.copy=function(){return Qv(t,ub()).exponent(t.exponent())},sg.apply(t,arguments)}function lb(){return ub.apply(null,arguments).exponent(.5)}function fb(t){for(var e=t.length/6|0,n=new Array(e),r=0;r<e;)n[r]="#"+t.slice(6*r,6*++r);return n}const hb=fb("1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf"),db=fb("7fc97fbeaed4fdc086ffff99386cb0f0027fbf5b17666666"),pb=fb("1b9e77d95f027570b3e7298a66a61ee6ab02a6761d666666"),gb=fb("a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928"),yb=fb("fbb4aeb3cde3ccebc5decbe4fed9a6ffffcce5d8bdfddaecf2f2f2"),mb=fb("b3e2cdfdcdaccbd5e8f4cae4e6f5c9fff2aef1e2cccccccc"),vb=fb("e41a1c377eb84daf4a984ea3ff7f00ffff33a65628f781bf999999"),bb=fb("66c2a5fc8d628da0cbe78ac3a6d854ffd92fe5c494b3b3b3"),_b=fb("8dd3c7ffffb3bebadafb807280b1d3fdb462b3de69fccde5d9d9d9bc80bdccebc5ffed6f"),xb=fb("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab");function wb(t){return mn(t[t.length-1])}var kb=new Array(3).concat("d8b365f5f5f55ab4ac","a6611adfc27d80cdc1018571","a6611adfc27df5f5f580cdc1018571","8c510ad8b365f6e8c3c7eae55ab4ac01665e","8c510ad8b365f6e8c3f5f5f5c7eae55ab4ac01665e","8c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e","8c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e","5430058c510abf812ddfc27df6e8c3c7eae580cdc135978f01665e003c30","5430058c510abf812ddfc27df6e8c3f5f5f5c7eae580cdc135978f01665e003c30").map(fb);const Tb=wb(kb);var Eb=new Array(3).concat("af8dc3f7f7f77fbf7b","7b3294c2a5cfa6dba0008837","7b3294c2a5cff7f7f7a6dba0008837","762a83af8dc3e7d4e8d9f0d37fbf7b1b7837","762a83af8dc3e7d4e8f7f7f7d9f0d37fbf7b1b7837","762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b7837","762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b7837","40004b762a839970abc2a5cfe7d4e8d9f0d3a6dba05aae611b783700441b","40004b762a839970abc2a5cfe7d4e8f7f7f7d9f0d3a6dba05aae611b783700441b").map(fb);const Cb=wb(Eb);var Sb=new Array(3).concat("e9a3c9f7f7f7a1d76a","d01c8bf1b6dab8e1864dac26","d01c8bf1b6daf7f7f7b8e1864dac26","c51b7de9a3c9fde0efe6f5d0a1d76a4d9221","c51b7de9a3c9fde0eff7f7f7e6f5d0a1d76a4d9221","c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221","c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221","8e0152c51b7dde77aef1b6dafde0efe6f5d0b8e1867fbc414d9221276419","8e0152c51b7dde77aef1b6dafde0eff7f7f7e6f5d0b8e1867fbc414d9221276419").map(fb);const Mb=wb(Sb);var Ab=new Array(3).concat("998ec3f7f7f7f1a340","5e3c99b2abd2fdb863e66101","5e3c99b2abd2f7f7f7fdb863e66101","542788998ec3d8daebfee0b6f1a340b35806","542788998ec3d8daebf7f7f7fee0b6f1a340b35806","5427888073acb2abd2d8daebfee0b6fdb863e08214b35806","5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b35806","2d004b5427888073acb2abd2d8daebfee0b6fdb863e08214b358067f3b08","2d004b5427888073acb2abd2d8daebf7f7f7fee0b6fdb863e08214b358067f3b08").map(fb);const Ob=wb(Ab);var Nb=new Array(3).concat("ef8a62f7f7f767a9cf","ca0020f4a58292c5de0571b0","ca0020f4a582f7f7f792c5de0571b0","b2182bef8a62fddbc7d1e5f067a9cf2166ac","b2182bef8a62fddbc7f7f7f7d1e5f067a9cf2166ac","b2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac","b2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac","67001fb2182bd6604df4a582fddbc7d1e5f092c5de4393c32166ac053061","67001fb2182bd6604df4a582fddbc7f7f7f7d1e5f092c5de4393c32166ac053061").map(fb);const jb=wb(Nb);var Db=new Array(3).concat("ef8a62ffffff999999","ca0020f4a582bababa404040","ca0020f4a582ffffffbababa404040","b2182bef8a62fddbc7e0e0e09999994d4d4d","b2182bef8a62fddbc7ffffffe0e0e09999994d4d4d","b2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d","b2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d","67001fb2182bd6604df4a582fddbc7e0e0e0bababa8787874d4d4d1a1a1a","67001fb2182bd6604df4a582fddbc7ffffffe0e0e0bababa8787874d4d4d1a1a1a").map(fb);const Bb=wb(Db);var Lb=new Array(3).concat("fc8d59ffffbf91bfdb","d7191cfdae61abd9e92c7bb6","d7191cfdae61ffffbfabd9e92c7bb6","d73027fc8d59fee090e0f3f891bfdb4575b4","d73027fc8d59fee090ffffbfe0f3f891bfdb4575b4","d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4","d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4","a50026d73027f46d43fdae61fee090e0f3f8abd9e974add14575b4313695","a50026d73027f46d43fdae61fee090ffffbfe0f3f8abd9e974add14575b4313695").map(fb);const Ib=wb(Lb);var Rb=new Array(3).concat("fc8d59ffffbf91cf60","d7191cfdae61a6d96a1a9641","d7191cfdae61ffffbfa6d96a1a9641","d73027fc8d59fee08bd9ef8b91cf601a9850","d73027fc8d59fee08bffffbfd9ef8b91cf601a9850","d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850","d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850","a50026d73027f46d43fdae61fee08bd9ef8ba6d96a66bd631a9850006837","a50026d73027f46d43fdae61fee08bffffbfd9ef8ba6d96a66bd631a9850006837").map(fb);const Pb=wb(Rb);var Fb=new Array(3).concat("fc8d59ffffbf99d594","d7191cfdae61abdda42b83ba","d7191cfdae61ffffbfabdda42b83ba","d53e4ffc8d59fee08be6f59899d5943288bd","d53e4ffc8d59fee08bffffbfe6f59899d5943288bd","d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd","d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd","9e0142d53e4ff46d43fdae61fee08be6f598abdda466c2a53288bd5e4fa2","9e0142d53e4ff46d43fdae61fee08bffffbfe6f598abdda466c2a53288bd5e4fa2").map(fb);const zb=wb(Fb);var Yb=new Array(3).concat("e5f5f999d8c92ca25f","edf8fbb2e2e266c2a4238b45","edf8fbb2e2e266c2a42ca25f006d2c","edf8fbccece699d8c966c2a42ca25f006d2c","edf8fbccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45005824","f7fcfde5f5f9ccece699d8c966c2a441ae76238b45006d2c00441b").map(fb);const qb=wb(Yb);var Ub=new Array(3).concat("e0ecf49ebcda8856a7","edf8fbb3cde38c96c688419d","edf8fbb3cde38c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68856a7810f7c","edf8fbbfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d6e016b","f7fcfde0ecf4bfd3e69ebcda8c96c68c6bb188419d810f7c4d004b").map(fb);const Vb=wb(Ub);var Wb=new Array(3).concat("e0f3dba8ddb543a2ca","f0f9e8bae4bc7bccc42b8cbe","f0f9e8bae4bc7bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc443a2ca0868ac","f0f9e8ccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe08589e","f7fcf0e0f3dbccebc5a8ddb57bccc44eb3d32b8cbe0868ac084081").map(fb);const Hb=wb(Wb);var $b=new Array(3).concat("fee8c8fdbb84e34a33","fef0d9fdcc8afc8d59d7301f","fef0d9fdcc8afc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59e34a33b30000","fef0d9fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301f990000","fff7ecfee8c8fdd49efdbb84fc8d59ef6548d7301fb300007f0000").map(fb);const Gb=wb($b);var Xb=new Array(3).concat("ece2f0a6bddb1c9099","f6eff7bdc9e167a9cf02818a","f6eff7bdc9e167a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf1c9099016c59","f6eff7d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016450","fff7fbece2f0d0d1e6a6bddb67a9cf3690c002818a016c59014636").map(fb);const Zb=wb(Xb);var Kb=new Array(3).concat("ece7f2a6bddb2b8cbe","f1eef6bdc9e174a9cf0570b0","f1eef6bdc9e174a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf2b8cbe045a8d","f1eef6d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0034e7b","fff7fbece7f2d0d1e6a6bddb74a9cf3690c00570b0045a8d023858").map(fb);const Qb=wb(Kb);var Jb=new Array(3).concat("e7e1efc994c7dd1c77","f1eef6d7b5d8df65b0ce1256","f1eef6d7b5d8df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0dd1c77980043","f1eef6d4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125691003f","f7f4f9e7e1efd4b9dac994c7df65b0e7298ace125698004367001f").map(fb);const t_=wb(Jb);var e_=new Array(3).concat("fde0ddfa9fb5c51b8a","feebe2fbb4b9f768a1ae017e","feebe2fbb4b9f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1c51b8a7a0177","feebe2fcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a0177","fff7f3fde0ddfcc5c0fa9fb5f768a1dd3497ae017e7a017749006a").map(fb);const n_=wb(e_);var r_=new Array(3).concat("edf8b17fcdbb2c7fb8","ffffcca1dab441b6c4225ea8","ffffcca1dab441b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c42c7fb8253494","ffffccc7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea80c2c84","ffffd9edf8b1c7e9b47fcdbb41b6c41d91c0225ea8253494081d58").map(fb);const i_=wb(r_);var a_=new Array(3).concat("f7fcb9addd8e31a354","ffffccc2e69978c679238443","ffffccc2e69978c67931a354006837","ffffccd9f0a3addd8e78c67931a354006837","ffffccd9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443005a32","ffffe5f7fcb9d9f0a3addd8e78c67941ab5d238443006837004529").map(fb);const o_=wb(a_);var s_=new Array(3).concat("fff7bcfec44fd95f0e","ffffd4fed98efe9929cc4c02","ffffd4fed98efe9929d95f0e993404","ffffd4fee391fec44ffe9929d95f0e993404","ffffd4fee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c028c2d04","ffffe5fff7bcfee391fec44ffe9929ec7014cc4c02993404662506").map(fb);const c_=wb(s_);var u_=new Array(3).concat("ffeda0feb24cf03b20","ffffb2fecc5cfd8d3ce31a1c","ffffb2fecc5cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cf03b20bd0026","ffffb2fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cb10026","ffffccffeda0fed976feb24cfd8d3cfc4e2ae31a1cbd0026800026").map(fb);const l_=wb(u_);var f_=new Array(3).concat("deebf79ecae13182bd","eff3ffbdd7e76baed62171b5","eff3ffbdd7e76baed63182bd08519c","eff3ffc6dbef9ecae16baed63182bd08519c","eff3ffc6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b5084594","f7fbffdeebf7c6dbef9ecae16baed64292c62171b508519c08306b").map(fb);const h_=wb(f_);var d_=new Array(3).concat("e5f5e0a1d99b31a354","edf8e9bae4b374c476238b45","edf8e9bae4b374c47631a354006d2c","edf8e9c7e9c0a1d99b74c47631a354006d2c","edf8e9c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45005a32","f7fcf5e5f5e0c7e9c0a1d99b74c47641ab5d238b45006d2c00441b").map(fb);const p_=wb(d_);var g_=new Array(3).concat("f0f0f0bdbdbd636363","f7f7f7cccccc969696525252","f7f7f7cccccc969696636363252525","f7f7f7d9d9d9bdbdbd969696636363252525","f7f7f7d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525","fffffff0f0f0d9d9d9bdbdbd969696737373525252252525000000").map(fb);const y_=wb(g_);var m_=new Array(3).concat("efedf5bcbddc756bb1","f2f0f7cbc9e29e9ac86a51a3","f2f0f7cbc9e29e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8756bb154278f","f2f0f7dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a34a1486","fcfbfdefedf5dadaebbcbddc9e9ac8807dba6a51a354278f3f007d").map(fb);const v_=wb(m_);var b_=new Array(3).concat("fee0d2fc9272de2d26","fee5d9fcae91fb6a4acb181d","fee5d9fcae91fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4ade2d26a50f15","fee5d9fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181d99000d","fff5f0fee0d2fcbba1fc9272fb6a4aef3b2ccb181da50f1567000d").map(fb);const __=wb(b_);var x_=new Array(3).concat("fee6cefdae6be6550d","feeddefdbe85fd8d3cd94701","feeddefdbe85fd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3ce6550da63603","feeddefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d948018c2d04","fff5ebfee6cefdd0a2fdae6bfd8d3cf16913d94801a636037f2704").map(fb);const w_=wb(x_);function k_(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(-4.54-t*(35.34-t*(2381.73-t*(6402.7-t*(7024.72-2710.57*t)))))))+", "+Math.max(0,Math.min(255,Math.round(32.49+t*(170.73+t*(52.82-t*(131.46-t*(176.58-67.37*t)))))))+", "+Math.max(0,Math.min(255,Math.round(81.24+t*(442.36-t*(2482.43-t*(6167.24-t*(6614.94-2475.67*t)))))))+")"}const T_=qp(Va(300,.5,0),Va(-240,.5,1));var E_=qp(Va(-100,.75,.35),Va(80,1.5,.8)),C_=qp(Va(260,.75,.35),Va(80,1.5,.8)),S_=Va();function M_(t){(t<0||t>1)&&(t-=Math.floor(t));var e=Math.abs(t-.5);return S_.h=360*t-100,S_.s=1.5-1.5*e,S_.l=.8-.9*e,S_+""}var A_=Ke(),O_=Math.PI/3,N_=2*Math.PI/3;function j_(t){var e;return t=(.5-t)*Math.PI,A_.r=255*(e=Math.sin(t))*e,A_.g=255*(e=Math.sin(t+O_))*e,A_.b=255*(e=Math.sin(t+N_))*e,A_+""}function D_(t){return t=Math.max(0,Math.min(1,t)),"rgb("+Math.max(0,Math.min(255,Math.round(34.61+t*(1172.33-t*(10793.56-t*(33300.12-t*(38394.49-14825.05*t)))))))+", "+Math.max(0,Math.min(255,Math.round(23.31+t*(557.33+t*(1225.33-t*(3574.96-t*(1073.77+707.56*t)))))))+", "+Math.max(0,Math.min(255,Math.round(27.2+t*(3211.1-t*(15327.97-t*(27814-t*(22569.18-6838.66*t)))))))+")"}function B_(t){var e=t.length;return function(n){return t[Math.max(0,Math.min(e-1,Math.floor(n*e)))]}}const L_=B_(fb("44015444025645045745055946075a46085c460a5d460b5e470d60470e6147106347116447136548146748166848176948186a481a6c481b6d481c6e481d6f481f70482071482173482374482475482576482677482878482979472a7a472c7a472d7b472e7c472f7d46307e46327e46337f463480453581453781453882443983443a83443b84433d84433e85423f854240864241864142874144874045884046883f47883f48893e49893e4a893e4c8a3d4d8a3d4e8a3c4f8a3c508b3b518b3b528b3a538b3a548c39558c39568c38588c38598c375a8c375b8d365c8d365d8d355e8d355f8d34608d34618d33628d33638d32648e32658e31668e31678e31688e30698e306a8e2f6b8e2f6c8e2e6d8e2e6e8e2e6f8e2d708e2d718e2c718e2c728e2c738e2b748e2b758e2a768e2a778e2a788e29798e297a8e297b8e287c8e287d8e277e8e277f8e27808e26818e26828e26828e25838e25848e25858e24868e24878e23888e23898e238a8d228b8d228c8d228d8d218e8d218f8d21908d21918c20928c20928c20938c1f948c1f958b1f968b1f978b1f988b1f998a1f9a8a1e9b8a1e9c891e9d891f9e891f9f881fa0881fa1881fa1871fa28720a38620a48621a58521a68522a78522a88423a98324aa8325ab8225ac8226ad8127ad8128ae8029af7f2ab07f2cb17e2db27d2eb37c2fb47c31b57b32b67a34b67935b77937b87838b9773aba763bbb753dbc743fbc7340bd7242be7144bf7046c06f48c16e4ac16d4cc26c4ec36b50c46a52c56954c56856c66758c7655ac8645cc8635ec96260ca6063cb5f65cb5e67cc5c69cd5b6ccd5a6ece5870cf5773d05675d05477d1537ad1517cd2507fd34e81d34d84d44b86d54989d5488bd6468ed64590d74393d74195d84098d83e9bd93c9dd93ba0da39a2da37a5db36a8db34aadc32addc30b0dd2fb2dd2db5de2bb8de29bade28bddf26c0df25c2df23c5e021c8e020cae11fcde11dd0e11cd2e21bd5e21ad8e219dae319dde318dfe318e2e418e5e419e7e419eae51aece51befe51cf1e51df4e61ef6e620f8e621fbe723fde725"));var I_=B_(fb("00000401000501010601010802010902020b02020d03030f03031204041405041606051806051a07061c08071e0907200a08220b09240c09260d0a290e0b2b100b2d110c2f120d31130d34140e36150e38160f3b180f3d19103f1a10421c10441d11471e114920114b21114e22115024125325125527125829115a2a115c2c115f2d11612f116331116533106734106936106b38106c390f6e3b0f703d0f713f0f72400f74420f75440f764510774710784910784a10794c117a4e117b4f127b51127c52137c54137d56147d57157e59157e5a167e5c167f5d177f5f187f601880621980641a80651a80671b80681c816a1c816b1d816d1d816e1e81701f81721f817320817521817621817822817922827b23827c23827e24828025828125818326818426818627818827818928818b29818c29818e2a81902a81912b81932b80942c80962c80982d80992d809b2e7f9c2e7f9e2f7fa02f7fa1307ea3307ea5317ea6317da8327daa337dab337cad347cae347bb0357bb2357bb3367ab5367ab73779b83779ba3878bc3978bd3977bf3a77c03a76c23b75c43c75c53c74c73d73c83e73ca3e72cc3f71cd4071cf4070d0416fd2426fd3436ed5446dd6456cd8456cd9466bdb476adc4869de4968df4a68e04c67e24d66e34e65e44f64e55064e75263e85362e95462ea5661eb5760ec5860ed5a5fee5b5eef5d5ef05f5ef1605df2625df2645cf3655cf4675cf4695cf56b5cf66c5cf66e5cf7705cf7725cf8745cf8765cf9785df9795df97b5dfa7d5efa7f5efa815ffb835ffb8560fb8761fc8961fc8a62fc8c63fc8e64fc9065fd9266fd9467fd9668fd9869fd9a6afd9b6bfe9d6cfe9f6dfea16efea36ffea571fea772fea973feaa74feac76feae77feb078feb27afeb47bfeb67cfeb77efeb97ffebb81febd82febf84fec185fec287fec488fec68afec88cfeca8dfecc8ffecd90fecf92fed194fed395fed597fed799fed89afdda9cfddc9efddea0fde0a1fde2a3fde3a5fde5a7fde7a9fde9aafdebacfcecaefceeb0fcf0b2fcf2b4fcf4b6fcf6b8fcf7b9fcf9bbfcfbbdfcfdbf")),R_=B_(fb("00000401000501010601010802010a02020c02020e03021004031204031405041706041907051b08051d09061f0a07220b07240c08260d08290e092b10092d110a30120a32140b34150b37160b39180c3c190c3e1b0c411c0c431e0c451f0c48210c4a230c4c240c4f260c51280b53290b552b0b572d0b592f0a5b310a5c320a5e340a5f3609613809623909633b09643d09653e0966400a67420a68440a68450a69470b6a490b6a4a0c6b4c0c6b4d0d6c4f0d6c510e6c520e6d540f6d550f6d57106e59106e5a116e5c126e5d126e5f136e61136e62146e64156e65156e67166e69166e6a176e6c186e6d186e6f196e71196e721a6e741a6e751b6e771c6d781c6d7a1d6d7c1d6d7d1e6d7f1e6c801f6c82206c84206b85216b87216b88226a8a226a8c23698d23698f24699025689225689326679526679727669827669a28659b29649d29649f2a63a02a63a22b62a32c61a52c60a62d60a82e5fa92e5eab2f5ead305dae305cb0315bb1325ab3325ab43359b63458b73557b93556ba3655bc3754bd3853bf3952c03a51c13a50c33b4fc43c4ec63d4dc73e4cc83f4bca404acb4149cc4248ce4347cf4446d04545d24644d34743d44842d54a41d74b3fd84c3ed94d3dda4e3cdb503bdd513ade5238df5337e05536e15635e25734e35933e45a31e55c30e65d2fe75e2ee8602de9612bea632aeb6429eb6628ec6726ed6925ee6a24ef6c23ef6e21f06f20f1711ff1731df2741cf3761bf37819f47918f57b17f57d15f67e14f68013f78212f78410f8850ff8870ef8890cf98b0bf98c0af98e09fa9008fa9207fa9407fb9606fb9706fb9906fb9b06fb9d07fc9f07fca108fca309fca50afca60cfca80dfcaa0ffcac11fcae12fcb014fcb216fcb418fbb61afbb81dfbba1ffbbc21fbbe23fac026fac228fac42afac62df9c72ff9c932f9cb35f8cd37f8cf3af7d13df7d340f6d543f6d746f5d949f5db4cf4dd4ff4df53f4e156f3e35af3e55df2e661f2e865f2ea69f1ec6df1ed71f1ef75f1f179f2f27df2f482f3f586f3f68af4f88ef5f992f6fa96f8fb9af9fc9dfafda1fcffa4")),P_=B_(fb("0d088710078813078916078a19068c1b068d1d068e20068f2206902406912605912805922a05932c05942e05952f059631059733059735049837049938049a3a049a3c049b3e049c3f049c41049d43039e44039e46039f48039f4903a04b03a14c02a14e02a25002a25102a35302a35502a45601a45801a45901a55b01a55c01a65e01a66001a66100a76300a76400a76600a76700a86900a86a00a86c00a86e00a86f00a87100a87201a87401a87501a87701a87801a87a02a87b02a87d03a87e03a88004a88104a78305a78405a78606a68707a68808a68a09a58b0aa58d0ba58e0ca48f0da4910ea3920fa39410a29511a19613a19814a099159f9a169f9c179e9d189d9e199da01a9ca11b9ba21d9aa31e9aa51f99a62098a72197a82296aa2395ab2494ac2694ad2793ae2892b02991b12a90b22b8fb32c8eb42e8db52f8cb6308bb7318ab83289ba3388bb3488bc3587bd3786be3885bf3984c03a83c13b82c23c81c33d80c43e7fc5407ec6417dc7427cc8437bc9447aca457acb4679cc4778cc4977cd4a76ce4b75cf4c74d04d73d14e72d24f71d35171d45270d5536fd5546ed6556dd7566cd8576bd9586ada5a6ada5b69db5c68dc5d67dd5e66de5f65de6164df6263e06363e16462e26561e26660e3685fe4695ee56a5de56b5de66c5ce76e5be76f5ae87059e97158e97257ea7457eb7556eb7655ec7754ed7953ed7a52ee7b51ef7c51ef7e50f07f4ff0804ef1814df1834cf2844bf3854bf3874af48849f48948f58b47f58c46f68d45f68f44f79044f79143f79342f89441f89540f9973ff9983ef99a3efa9b3dfa9c3cfa9e3bfb9f3afba139fba238fca338fca537fca636fca835fca934fdab33fdac33fdae32fdaf31fdb130fdb22ffdb42ffdb52efeb72dfeb82cfeba2cfebb2bfebd2afebe2afec029fdc229fdc328fdc527fdc627fdc827fdca26fdcb26fccd25fcce25fcd025fcd225fbd324fbd524fbd724fad824fada24f9dc24f9dd25f8df25f8e125f7e225f7e425f6e626f6e826f5e926f5eb27f4ed27f3ee27f3f027f2f227f1f426f1f525f0f724f0f921"));function F_(t){return Te(ie(t).call(document.documentElement))}var z_=0;function Y_(){return new q_}function q_(){this._="@"+(++z_).toString(36)}function U_(t){return"string"==typeof t?new xe([document.querySelectorAll(t)],[document.documentElement]):new xe([null==t?[]:t],_e)}function V_(t,e){null==e&&(e=On().touches);for(var n=0,r=e?e.length:0,i=new Array(r);n<r;++n)i[n]=Nn(t,e[n]);return i}function W_(t){return function(){return t}}q_.prototype=Y_.prototype={constructor:q_,get:function(t){for(var e=this._;!(e in t);)if(!(t=t.parentNode))return;return t[e]},set:function(t,e){return t[this._]=e},remove:function(t){return this._ in t&&delete t[this._]},toString:function(){return this._}};var H_=Math.abs,$_=Math.atan2,G_=Math.cos,X_=Math.max,Z_=Math.min,K_=Math.sin,Q_=Math.sqrt,J_=1e-12,tx=Math.PI,ex=tx/2,nx=2*tx;function rx(t){return t>1?0:t<-1?tx:Math.acos(t)}function ix(t){return t>=1?ex:t<=-1?-ex:Math.asin(t)}function ax(t){return t.innerRadius}function ox(t){return t.outerRadius}function sx(t){return t.startAngle}function cx(t){return t.endAngle}function ux(t){return t&&t.padAngle}function lx(t,e,n,r,i,a,o,s){var c=n-t,u=r-e,l=o-i,f=s-a,h=f*c-l*u;if(!(h*h<J_))return[t+(h=(l*(e-a)-f*(t-i))/h)*c,e+h*u]}function fx(t,e,n,r,i,a,o){var s=t-n,c=e-r,u=(o?a:-a)/Q_(s*s+c*c),l=u*c,f=-u*s,h=t+l,d=e+f,p=n+l,g=r+f,y=(h+p)/2,m=(d+g)/2,v=p-h,b=g-d,_=v*v+b*b,x=i-a,w=h*g-p*d,k=(b<0?-1:1)*Q_(X_(0,x*x*_-w*w)),T=(w*b-v*k)/_,E=(-w*v-b*k)/_,C=(w*b+v*k)/_,S=(-w*v+b*k)/_,M=T-y,A=E-m,O=C-y,N=S-m;return M*M+A*A>O*O+N*N&&(T=C,E=S),{cx:T,cy:E,x01:-l,y01:-f,x11:T*(i/x-1),y11:E*(i/x-1)}}function hx(){var t=ax,e=ox,n=W_(0),r=null,i=sx,a=cx,o=ux,s=null;function c(){var c,u,l=+t.apply(this,arguments),f=+e.apply(this,arguments),h=i.apply(this,arguments)-ex,d=a.apply(this,arguments)-ex,p=H_(d-h),g=d>h;if(s||(s=c=Hi()),f<l&&(u=f,f=l,l=u),f>J_)if(p>nx-J_)s.moveTo(f*G_(h),f*K_(h)),s.arc(0,0,f,h,d,!g),l>J_&&(s.moveTo(l*G_(d),l*K_(d)),s.arc(0,0,l,d,h,g));else{var y,m,v=h,b=d,_=h,x=d,w=p,k=p,T=o.apply(this,arguments)/2,E=T>J_&&(r?+r.apply(this,arguments):Q_(l*l+f*f)),C=Z_(H_(f-l)/2,+n.apply(this,arguments)),S=C,M=C;if(E>J_){var A=ix(E/l*K_(T)),O=ix(E/f*K_(T));(w-=2*A)>J_?(_+=A*=g?1:-1,x-=A):(w=0,_=x=(h+d)/2),(k-=2*O)>J_?(v+=O*=g?1:-1,b-=O):(k=0,v=b=(h+d)/2)}var N=f*G_(v),j=f*K_(v),D=l*G_(x),B=l*K_(x);if(C>J_){var L,I=f*G_(b),R=f*K_(b),P=l*G_(_),F=l*K_(_);if(p<tx&&(L=lx(N,j,P,F,I,R,D,B))){var z=N-L[0],Y=j-L[1],q=I-L[0],U=R-L[1],V=1/K_(rx((z*q+Y*U)/(Q_(z*z+Y*Y)*Q_(q*q+U*U)))/2),W=Q_(L[0]*L[0]+L[1]*L[1]);S=Z_(C,(l-W)/(V-1)),M=Z_(C,(f-W)/(V+1))}}k>J_?M>J_?(y=fx(P,F,N,j,f,M,g),m=fx(I,R,D,B,f,M,g),s.moveTo(y.cx+y.x01,y.cy+y.y01),M<C?s.arc(y.cx,y.cy,M,$_(y.y01,y.x01),$_(m.y01,m.x01),!g):(s.arc(y.cx,y.cy,M,$_(y.y01,y.x01),$_(y.y11,y.x11),!g),s.arc(0,0,f,$_(y.cy+y.y11,y.cx+y.x11),$_(m.cy+m.y11,m.cx+m.x11),!g),s.arc(m.cx,m.cy,M,$_(m.y11,m.x11),$_(m.y01,m.x01),!g))):(s.moveTo(N,j),s.arc(0,0,f,v,b,!g)):s.moveTo(N,j),l>J_&&w>J_?S>J_?(y=fx(D,B,I,R,l,-S,g),m=fx(N,j,P,F,l,-S,g),s.lineTo(y.cx+y.x01,y.cy+y.y01),S<C?s.arc(y.cx,y.cy,S,$_(y.y01,y.x01),$_(m.y01,m.x01),!g):(s.arc(y.cx,y.cy,S,$_(y.y01,y.x01),$_(y.y11,y.x11),!g),s.arc(0,0,l,$_(y.cy+y.y11,y.cx+y.x11),$_(m.cy+m.y11,m.cx+m.x11),g),s.arc(m.cx,m.cy,S,$_(m.y11,m.x11),$_(m.y01,m.x01),!g))):s.arc(0,0,l,x,_,g):s.lineTo(D,B)}else s.moveTo(0,0);if(s.closePath(),c)return s=null,c+""||null}return c.centroid=function(){var n=(+t.apply(this,arguments)+ +e.apply(this,arguments))/2,r=(+i.apply(this,arguments)+ +a.apply(this,arguments))/2-tx/2;return[G_(r)*n,K_(r)*n]},c.innerRadius=function(e){return arguments.length?(t="function"==typeof e?e:W_(+e),c):t},c.outerRadius=function(t){return arguments.length?(e="function"==typeof t?t:W_(+t),c):e},c.cornerRadius=function(t){return arguments.length?(n="function"==typeof t?t:W_(+t),c):n},c.padRadius=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:W_(+t),c):r},c.startAngle=function(t){return arguments.length?(i="function"==typeof t?t:W_(+t),c):i},c.endAngle=function(t){return arguments.length?(a="function"==typeof t?t:W_(+t),c):a},c.padAngle=function(t){return arguments.length?(o="function"==typeof t?t:W_(+t),c):o},c.context=function(t){return arguments.length?(s=null==t?null:t,c):s},c}function dx(t){this._context=t}function px(t){return new dx(t)}function gx(t){return t[0]}function yx(t){return t[1]}function mx(){var t=gx,e=yx,n=W_(!0),r=null,i=px,a=null;function o(o){var s,c,u,l=o.length,f=!1;for(null==r&&(a=i(u=Hi())),s=0;s<=l;++s)!(s<l&&n(c=o[s],s,o))===f&&((f=!f)?a.lineStart():a.lineEnd()),f&&a.point(+t(c,s,o),+e(c,s,o));if(u)return a=null,u+""||null}return o.x=function(e){return arguments.length?(t="function"==typeof e?e:W_(+e),o):t},o.y=function(t){return arguments.length?(e="function"==typeof t?t:W_(+t),o):e},o.defined=function(t){return arguments.length?(n="function"==typeof t?t:W_(!!t),o):n},o.curve=function(t){return arguments.length?(i=t,null!=r&&(a=i(r)),o):i},o.context=function(t){return arguments.length?(null==t?r=a=null:a=i(r=t),o):r},o}function vx(){var t=gx,e=null,n=W_(0),r=yx,i=W_(!0),a=null,o=px,s=null;function c(c){var u,l,f,h,d,p=c.length,g=!1,y=new Array(p),m=new Array(p);for(null==a&&(s=o(d=Hi())),u=0;u<=p;++u){if(!(u<p&&i(h=c[u],u,c))===g)if(g=!g)l=u,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),f=u-1;f>=l;--f)s.point(y[f],m[f]);s.lineEnd(),s.areaEnd()}g&&(y[u]=+t(h,u,c),m[u]=+n(h,u,c),s.point(e?+e(h,u,c):y[u],r?+r(h,u,c):m[u]))}if(d)return s=null,d+""||null}function u(){return mx().defined(i).curve(o).context(a)}return c.x=function(n){return arguments.length?(t="function"==typeof n?n:W_(+n),e=null,c):t},c.x0=function(e){return arguments.length?(t="function"==typeof e?e:W_(+e),c):t},c.x1=function(t){return arguments.length?(e=null==t?null:"function"==typeof t?t:W_(+t),c):e},c.y=function(t){return arguments.length?(n="function"==typeof t?t:W_(+t),r=null,c):n},c.y0=function(t){return arguments.length?(n="function"==typeof t?t:W_(+t),c):n},c.y1=function(t){return arguments.length?(r=null==t?null:"function"==typeof t?t:W_(+t),c):r},c.lineX0=c.lineY0=function(){return u().x(t).y(n)},c.lineY1=function(){return u().x(t).y(r)},c.lineX1=function(){return u().x(e).y(n)},c.defined=function(t){return arguments.length?(i="function"==typeof t?t:W_(!!t),c):i},c.curve=function(t){return arguments.length?(o=t,null!=a&&(s=o(a)),c):o},c.context=function(t){return arguments.length?(null==t?a=s=null:s=o(a=t),c):a},c}function bx(t,e){return e<t?-1:e>t?1:e>=t?0:NaN}function _x(t){return t}function xx(){var t=_x,e=bx,n=null,r=W_(0),i=W_(nx),a=W_(0);function o(o){var s,c,u,l,f,h=o.length,d=0,p=new Array(h),g=new Array(h),y=+r.apply(this,arguments),m=Math.min(nx,Math.max(-nx,i.apply(this,arguments)-y)),v=Math.min(Math.abs(m)/h,a.apply(this,arguments)),b=v*(m<0?-1:1);for(s=0;s<h;++s)(f=g[p[s]=s]=+t(o[s],s,o))>0&&(d+=f);for(null!=e?p.sort((function(t,n){return e(g[t],g[n])})):null!=n&&p.sort((function(t,e){return n(o[t],o[e])})),s=0,u=d?(m-h*b)/d:0;s<h;++s,y=l)c=p[s],l=y+((f=g[c])>0?f*u:0)+b,g[c]={data:o[c],index:s,value:f,startAngle:y,endAngle:l,padAngle:v};return g}return o.value=function(e){return arguments.length?(t="function"==typeof e?e:W_(+e),o):t},o.sortValues=function(t){return arguments.length?(e=t,n=null,o):e},o.sort=function(t){return arguments.length?(n=t,e=null,o):n},o.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:W_(+t),o):r},o.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:W_(+t),o):i},o.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:W_(+t),o):a},o}dx.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}};var wx=Tx(px);function kx(t){this._curve=t}function Tx(t){function e(e){return new kx(t(e))}return e._curve=t,e}function Ex(t){var e=t.curve;return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t.curve=function(t){return arguments.length?e(Tx(t)):e()._curve},t}function Cx(){return Ex(mx().curve(wx))}function Sx(){var t=vx().curve(wx),e=t.curve,n=t.lineX0,r=t.lineX1,i=t.lineY0,a=t.lineY1;return t.angle=t.x,delete t.x,t.startAngle=t.x0,delete t.x0,t.endAngle=t.x1,delete t.x1,t.radius=t.y,delete t.y,t.innerRadius=t.y0,delete t.y0,t.outerRadius=t.y1,delete t.y1,t.lineStartAngle=function(){return Ex(n())},delete t.lineX0,t.lineEndAngle=function(){return Ex(r())},delete t.lineX1,t.lineInnerRadius=function(){return Ex(i())},delete t.lineY0,t.lineOuterRadius=function(){return Ex(a())},delete t.lineY1,t.curve=function(t){return arguments.length?e(Tx(t)):e()._curve},t}function Mx(t,e){return[(e=+e)*Math.cos(t-=Math.PI/2),e*Math.sin(t)]}kx.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(t,e){this._curve.point(e*Math.sin(t),e*-Math.cos(t))}};var Ax=Array.prototype.slice;function Ox(t){return t.source}function Nx(t){return t.target}function jx(t){var e=Ox,n=Nx,r=gx,i=yx,a=null;function o(){var o,s=Ax.call(arguments),c=e.apply(this,s),u=n.apply(this,s);if(a||(a=o=Hi()),t(a,+r.apply(this,(s[0]=c,s)),+i.apply(this,s),+r.apply(this,(s[0]=u,s)),+i.apply(this,s)),o)return a=null,o+""||null}return o.source=function(t){return arguments.length?(e=t,o):e},o.target=function(t){return arguments.length?(n=t,o):n},o.x=function(t){return arguments.length?(r="function"==typeof t?t:W_(+t),o):r},o.y=function(t){return arguments.length?(i="function"==typeof t?t:W_(+t),o):i},o.context=function(t){return arguments.length?(a=null==t?null:t,o):a},o}function Dx(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e=(e+r)/2,n,e,i,r,i)}function Bx(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e,n=(n+i)/2,r,n,r,i)}function Lx(t,e,n,r,i){var a=Mx(e,n),o=Mx(e,n=(n+i)/2),s=Mx(r,n),c=Mx(r,i);t.moveTo(a[0],a[1]),t.bezierCurveTo(o[0],o[1],s[0],s[1],c[0],c[1])}function Ix(){return jx(Dx)}function Rx(){return jx(Bx)}function Px(){var t=jx(Lx);return t.angle=t.x,delete t.x,t.radius=t.y,delete t.y,t}const Fx={draw:function(t,e){var n=Math.sqrt(e/tx);t.moveTo(n,0),t.arc(0,0,n,0,nx)}},zx={draw:function(t,e){var n=Math.sqrt(e/5)/2;t.moveTo(-3*n,-n),t.lineTo(-n,-n),t.lineTo(-n,-3*n),t.lineTo(n,-3*n),t.lineTo(n,-n),t.lineTo(3*n,-n),t.lineTo(3*n,n),t.lineTo(n,n),t.lineTo(n,3*n),t.lineTo(-n,3*n),t.lineTo(-n,n),t.lineTo(-3*n,n),t.closePath()}};var Yx=Math.sqrt(1/3),qx=2*Yx;const Ux={draw:function(t,e){var n=Math.sqrt(e/qx),r=n*Yx;t.moveTo(0,-n),t.lineTo(r,0),t.lineTo(0,n),t.lineTo(-r,0),t.closePath()}};var Vx=Math.sin(tx/10)/Math.sin(7*tx/10),Wx=Math.sin(nx/10)*Vx,Hx=-Math.cos(nx/10)*Vx;const $x={draw:function(t,e){var n=Math.sqrt(.8908130915292852*e),r=Wx*n,i=Hx*n;t.moveTo(0,-n),t.lineTo(r,i);for(var a=1;a<5;++a){var o=nx*a/5,s=Math.cos(o),c=Math.sin(o);t.lineTo(c*n,-s*n),t.lineTo(s*r-c*i,c*r+s*i)}t.closePath()}},Gx={draw:function(t,e){var n=Math.sqrt(e),r=-n/2;t.rect(r,r,n,n)}};var Xx=Math.sqrt(3);const Zx={draw:function(t,e){var n=-Math.sqrt(e/(3*Xx));t.moveTo(0,2*n),t.lineTo(-Xx*n,-n),t.lineTo(Xx*n,-n),t.closePath()}};var Kx=-.5,Qx=Math.sqrt(3)/2,Jx=1/Math.sqrt(12),tw=3*(Jx/2+1);const ew={draw:function(t,e){var n=Math.sqrt(e/tw),r=n/2,i=n*Jx,a=r,o=n*Jx+n,s=-a,c=o;t.moveTo(r,i),t.lineTo(a,o),t.lineTo(s,c),t.lineTo(Kx*r-Qx*i,Qx*r+Kx*i),t.lineTo(Kx*a-Qx*o,Qx*a+Kx*o),t.lineTo(Kx*s-Qx*c,Qx*s+Kx*c),t.lineTo(Kx*r+Qx*i,Kx*i-Qx*r),t.lineTo(Kx*a+Qx*o,Kx*o-Qx*a),t.lineTo(Kx*s+Qx*c,Kx*c-Qx*s),t.closePath()}};var nw=[Fx,zx,Ux,Gx,$x,Zx,ew];function rw(){var t=W_(Fx),e=W_(64),n=null;function r(){var r;if(n||(n=r=Hi()),t.apply(this,arguments).draw(n,+e.apply(this,arguments)),r)return n=null,r+""||null}return r.type=function(e){return arguments.length?(t="function"==typeof e?e:W_(e),r):t},r.size=function(t){return arguments.length?(e="function"==typeof t?t:W_(+t),r):e},r.context=function(t){return arguments.length?(n=null==t?null:t,r):n},r}function iw(){}function aw(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function ow(t){this._context=t}function sw(t){return new ow(t)}function cw(t){this._context=t}function uw(t){return new cw(t)}function lw(t){this._context=t}function fw(t){return new lw(t)}function hw(t,e){this._basis=new ow(t),this._beta=e}ow.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:aw(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:aw(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},cw.prototype={areaStart:iw,areaEnd:iw,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:aw(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},lw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:aw(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},hw.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],a=e[0],o=t[n]-i,s=e[n]-a,c=-1;++c<=n;)r=c/n,this._basis.point(this._beta*t[c]+(1-this._beta)*(i+r*o),this._beta*e[c]+(1-this._beta)*(a+r*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};const dw=function t(e){function n(t){return 1===e?new ow(t):new hw(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function pw(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function gw(t,e){this._context=t,this._k=(1-e)/6}gw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:pw(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:pw(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const yw=function t(e){function n(t){return new gw(t,e)}return n.tension=function(e){return t(+e)},n}(0);function mw(t,e){this._context=t,this._k=(1-e)/6}mw.prototype={areaStart:iw,areaEnd:iw,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:pw(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const vw=function t(e){function n(t){return new mw(t,e)}return n.tension=function(e){return t(+e)},n}(0);function bw(t,e){this._context=t,this._k=(1-e)/6}bw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:pw(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const _w=function t(e){function n(t){return new bw(t,e)}return n.tension=function(e){return t(+e)},n}(0);function xw(t,e,n){var r=t._x1,i=t._y1,a=t._x2,o=t._y2;if(t._l01_a>J_){var s=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*s-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,i=(i*s-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>J_){var u=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,l=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*u+t._x1*t._l23_2a-e*t._l12_2a)/l,o=(o*u+t._y1*t._l23_2a-n*t._l12_2a)/l}t._context.bezierCurveTo(r,i,a,o,t._x2,t._y2)}function ww(t,e){this._context=t,this._alpha=e}ww.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:xw(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const kw=function t(e){function n(t){return e?new ww(t,e):new gw(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Tw(t,e){this._context=t,this._alpha=e}Tw.prototype={areaStart:iw,areaEnd:iw,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:xw(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Ew=function t(e){function n(t){return e?new Tw(t,e):new mw(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Cw(t,e){this._context=t,this._alpha=e}Cw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:xw(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Sw=function t(e){function n(t){return e?new Cw(t,e):new bw(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function Mw(t){this._context=t}function Aw(t){return new Mw(t)}function Ow(t){return t<0?-1:1}function Nw(t,e,n){var r=t._x1-t._x0,i=e-t._x1,a=(t._y1-t._y0)/(r||i<0&&-0),o=(n-t._y1)/(i||r<0&&-0),s=(a*i+o*r)/(r+i);return(Ow(a)+Ow(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function jw(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function Dw(t,e,n){var r=t._x0,i=t._y0,a=t._x1,o=t._y1,s=(a-r)/3;t._context.bezierCurveTo(r+s,i+s*e,a-s,o-s*n,a,o)}function Bw(t){this._context=t}function Lw(t){this._context=new Iw(t)}function Iw(t){this._context=t}function Rw(t){return new Bw(t)}function Pw(t){return new Lw(t)}function Fw(t){this._context=t}function zw(t){var e,n,r=t.length-1,i=new Array(r),a=new Array(r),o=new Array(r);for(i[0]=0,a[0]=2,o[0]=t[0]+2*t[1],e=1;e<r-1;++e)i[e]=1,a[e]=4,o[e]=4*t[e]+2*t[e+1];for(i[r-1]=2,a[r-1]=7,o[r-1]=8*t[r-1]+t[r],e=1;e<r;++e)n=i[e]/a[e-1],a[e]-=n,o[e]-=n*o[e-1];for(i[r-1]=o[r-1]/a[r-1],e=r-2;e>=0;--e)i[e]=(o[e]-i[e+1])/a[e];for(a[r-1]=(t[r]+i[r-1])/2,e=0;e<r-1;++e)a[e]=2*t[e+1]-i[e+1];return[i,a]}function Yw(t){return new Fw(t)}function qw(t,e){this._context=t,this._t=e}function Uw(t){return new qw(t,.5)}function Vw(t){return new qw(t,0)}function Ww(t){return new qw(t,1)}function Hw(t,e){if((i=t.length)>1)for(var n,r,i,a=1,o=t[e[0]],s=o.length;a<i;++a)for(r=o,o=t[e[a]],n=0;n<s;++n)o[n][1]+=o[n][0]=isNaN(r[n][1])?r[n][0]:r[n][1]}function $w(t){for(var e=t.length,n=new Array(e);--e>=0;)n[e]=e;return n}function Gw(t,e){return t[e]}function Xw(){var t=W_([]),e=$w,n=Hw,r=Gw;function i(i){var a,o,s=t.apply(this,arguments),c=i.length,u=s.length,l=new Array(u);for(a=0;a<u;++a){for(var f,h=s[a],d=l[a]=new Array(c),p=0;p<c;++p)d[p]=f=[0,+r(i[p],h,p,i)],f.data=i[p];d.key=h}for(a=0,o=e(l);a<u;++a)l[o[a]].index=a;return n(l,o),l}return i.keys=function(e){return arguments.length?(t="function"==typeof e?e:W_(Ax.call(e)),i):t},i.value=function(t){return arguments.length?(r="function"==typeof t?t:W_(+t),i):r},i.order=function(t){return arguments.length?(e=null==t?$w:"function"==typeof t?t:W_(Ax.call(t)),i):e},i.offset=function(t){return arguments.length?(n=null==t?Hw:t,i):n},i}function Zw(t,e){if((r=t.length)>0){for(var n,r,i,a=0,o=t[0].length;a<o;++a){for(i=n=0;n<r;++n)i+=t[n][a][1]||0;if(i)for(n=0;n<r;++n)t[n][a][1]/=i}Hw(t,e)}}function Kw(t,e){if((s=t.length)>0)for(var n,r,i,a,o,s,c=0,u=t[e[0]].length;c<u;++c)for(a=o=0,n=0;n<s;++n)(i=(r=t[e[n]][c])[1]-r[0])>0?(r[0]=a,r[1]=a+=i):i<0?(r[1]=o,r[0]=o+=i):(r[0]=0,r[1]=i)}function Qw(t,e){if((n=t.length)>0){for(var n,r=0,i=t[e[0]],a=i.length;r<a;++r){for(var o=0,s=0;o<n;++o)s+=t[o][r][1]||0;i[r][1]+=i[r][0]=-s/2}Hw(t,e)}}function Jw(t,e){if((i=t.length)>0&&(r=(n=t[e[0]]).length)>0){for(var n,r,i,a=0,o=1;o<r;++o){for(var s=0,c=0,u=0;s<i;++s){for(var l=t[e[s]],f=l[o][1]||0,h=(f-(l[o-1][1]||0))/2,d=0;d<s;++d){var p=t[e[d]];h+=(p[o][1]||0)-(p[o-1][1]||0)}c+=f,u+=h*f}n[o-1][1]+=n[o-1][0]=a,c&&(a-=u/c)}n[o-1][1]+=n[o-1][0]=a,Hw(t,e)}}function tk(t){var e=t.map(ek);return $w(t).sort((function(t,n){return e[t]-e[n]}))}function ek(t){for(var e,n=-1,r=0,i=t.length,a=-1/0;++n<i;)(e=+t[n][1])>a&&(a=e,r=n);return r}function nk(t){var e=t.map(rk);return $w(t).sort((function(t,n){return e[t]-e[n]}))}function rk(t){for(var e,n=0,r=-1,i=t.length;++r<i;)(e=+t[r][1])&&(n+=e);return n}function ik(t){return nk(t).reverse()}function ak(t){var e,n,r=t.length,i=t.map(rk),a=tk(t),o=0,s=0,c=[],u=[];for(e=0;e<r;++e)n=a[e],o<s?(o+=i[n],c.push(n)):(s+=i[n],u.push(n));return u.reverse().concat(c)}function ok(t){return $w(t).reverse()}Mw.prototype={areaStart:iw,areaEnd:iw,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}},Bw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Dw(this,this._t0,jw(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var n=NaN;if(e=+e,(t=+t)!==this._x1||e!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,Dw(this,jw(this,n=Nw(this,t,e)),n);break;default:Dw(this,this._t0,n=Nw(this,t,e))}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=n}}},(Lw.prototype=Object.create(Bw.prototype)).point=function(t,e){Bw.prototype.point.call(this,e,t)},Iw.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,n,r,i,a){this._context.bezierCurveTo(e,t,r,n,a,i)}},Fw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,n=t.length;if(n)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),2===n)this._context.lineTo(t[1],e[1]);else for(var r=zw(t),i=zw(e),a=0,o=1;o<n;++a,++o)this._context.bezierCurveTo(r[0][a],i[0][a],r[1][a],i[1][a],t[o],e[o]);(this._line||0!==this._line&&1===n)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(t,e){this._x.push(+t),this._y.push(+e)}},qw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}};var sk="%Y-%m-%dT%H:%M:%S.%LZ",ck=Date.prototype.toISOString?function(t){return t.toISOString()}:ym(sk);const uk=ck;var lk=+new Date("2000-01-01T00:00:00.000Z")?function(t){var e=new Date(t);return isNaN(e)?null:e}:mm(sk);const fk=lk;function hk(t,e,n){var r=new Hn,i=e;return null==e?(r.restart(t,e,n),r):(e=+e,n=null==n?Vn():+n,r.restart((function a(o){o+=i,r.restart(a,i+=e,n),t(o)}),e,n),r)}function dk(t){return function(){return t}}function pk(t){return t[0]}function gk(t){return t[1]}function yk(){this._=null}function mk(t){t.U=t.C=t.L=t.R=t.P=t.N=null}function vk(t,e){var n=e,r=e.R,i=n.U;i?i.L===n?i.L=r:i.R=r:t._=r,r.U=i,n.U=r,n.R=r.L,n.R&&(n.R.U=n),r.L=n}function bk(t,e){var n=e,r=e.L,i=n.U;i?i.L===n?i.L=r:i.R=r:t._=r,r.U=i,n.U=r,n.L=r.R,n.L&&(n.L.U=n),r.R=n}function _k(t){for(;t.L;)t=t.L;return t}yk.prototype={constructor:yk,insert:function(t,e){var n,r,i;if(t){if(e.P=t,e.N=t.N,t.N&&(t.N.P=e),t.N=e,t.R){for(t=t.R;t.L;)t=t.L;t.L=e}else t.R=e;n=t}else this._?(t=_k(this._),e.P=null,e.N=t,t.P=t.L=e,n=t):(e.P=e.N=null,this._=e,n=null);for(e.L=e.R=null,e.U=n,e.C=!0,t=e;n&&n.C;)n===(r=n.U).L?(i=r.R)&&i.C?(n.C=i.C=!1,r.C=!0,t=r):(t===n.R&&(vk(this,n),n=(t=n).U),n.C=!1,r.C=!0,bk(this,r)):(i=r.L)&&i.C?(n.C=i.C=!1,r.C=!0,t=r):(t===n.L&&(bk(this,n),n=(t=n).U),n.C=!1,r.C=!0,vk(this,r)),n=t.U;this._.C=!1},remove:function(t){t.N&&(t.N.P=t.P),t.P&&(t.P.N=t.N),t.N=t.P=null;var e,n,r,i=t.U,a=t.L,o=t.R;if(n=a?o?_k(o):a:o,i?i.L===t?i.L=n:i.R=n:this._=n,a&&o?(r=n.C,n.C=t.C,n.L=a,a.U=n,n!==o?(i=n.U,n.U=t.U,t=n.R,i.L=t,n.R=o,o.U=n):(n.U=i,i=n,t=n.R)):(r=t.C,t=n),t&&(t.U=i),!r)if(t&&t.C)t.C=!1;else{do{if(t===this._)break;if(t===i.L){if((e=i.R).C&&(e.C=!1,i.C=!0,vk(this,i),e=i.R),e.L&&e.L.C||e.R&&e.R.C){e.R&&e.R.C||(e.L.C=!1,e.C=!0,bk(this,e),e=i.R),e.C=i.C,i.C=e.R.C=!1,vk(this,i),t=this._;break}}else if((e=i.L).C&&(e.C=!1,i.C=!0,bk(this,i),e=i.L),e.L&&e.L.C||e.R&&e.R.C){e.L&&e.L.C||(e.R.C=!1,e.C=!0,vk(this,e),e=i.L),e.C=i.C,i.C=e.L.C=!1,bk(this,i),t=this._;break}e.C=!0,t=i,i=i.U}while(!t.C);t&&(t.C=!1)}}};const xk=yk;function wk(t,e,n,r){var i=[null,null],a=Hk.push(i)-1;return i.left=t,i.right=e,n&&Tk(i,t,e,n),r&&Tk(i,e,t,r),Vk[t.index].halfedges.push(a),Vk[e.index].halfedges.push(a),i}function kk(t,e,n){var r=[e,n];return r.left=t,r}function Tk(t,e,n,r){t[0]||t[1]?t.left===n?t[1]=r:t[0]=r:(t[0]=r,t.left=e,t.right=n)}function Ek(t,e,n,r,i){var a,o=t[0],s=t[1],c=o[0],u=o[1],l=0,f=1,h=s[0]-c,d=s[1]-u;if(a=e-c,h||!(a>0)){if(a/=h,h<0){if(a<l)return;a<f&&(f=a)}else if(h>0){if(a>f)return;a>l&&(l=a)}if(a=r-c,h||!(a<0)){if(a/=h,h<0){if(a>f)return;a>l&&(l=a)}else if(h>0){if(a<l)return;a<f&&(f=a)}if(a=n-u,d||!(a>0)){if(a/=d,d<0){if(a<l)return;a<f&&(f=a)}else if(d>0){if(a>f)return;a>l&&(l=a)}if(a=i-u,d||!(a<0)){if(a/=d,d<0){if(a>f)return;a>l&&(l=a)}else if(d>0){if(a<l)return;a<f&&(f=a)}return!(l>0||f<1)||(l>0&&(t[0]=[c+l*h,u+l*d]),f<1&&(t[1]=[c+f*h,u+f*d]),!0)}}}}}function Ck(t,e,n,r,i){var a=t[1];if(a)return!0;var o,s,c=t[0],u=t.left,l=t.right,f=u[0],h=u[1],d=l[0],p=l[1],g=(f+d)/2,y=(h+p)/2;if(p===h){if(g<e||g>=r)return;if(f>d){if(c){if(c[1]>=i)return}else c=[g,n];a=[g,i]}else{if(c){if(c[1]<n)return}else c=[g,i];a=[g,n]}}else if(s=y-(o=(f-d)/(p-h))*g,o<-1||o>1)if(f>d){if(c){if(c[1]>=i)return}else c=[(n-s)/o,n];a=[(i-s)/o,i]}else{if(c){if(c[1]<n)return}else c=[(i-s)/o,i];a=[(n-s)/o,n]}else if(h<p){if(c){if(c[0]>=r)return}else c=[e,o*e+s];a=[r,o*r+s]}else{if(c){if(c[0]<e)return}else c=[r,o*r+s];a=[e,o*e+s]}return t[0]=c,t[1]=a,!0}function Sk(t,e){var n=t.site,r=e.left,i=e.right;return n===i&&(i=r,r=n),i?Math.atan2(i[1]-r[1],i[0]-r[0]):(n===r?(r=e[1],i=e[0]):(r=e[0],i=e[1]),Math.atan2(r[0]-i[0],i[1]-r[1]))}function Mk(t,e){return e[+(e.left!==t.site)]}function Ak(t,e){return e[+(e.left===t.site)]}var Ok,Nk=[];function jk(){mk(this),this.x=this.y=this.arc=this.site=this.cy=null}function Dk(t){var e=t.P,n=t.N;if(e&&n){var r=e.site,i=t.site,a=n.site;if(r!==a){var o=i[0],s=i[1],c=r[0]-o,u=r[1]-s,l=a[0]-o,f=a[1]-s,h=2*(c*f-u*l);if(!(h>=-Gk)){var d=c*c+u*u,p=l*l+f*f,g=(f*d-u*p)/h,y=(c*p-l*d)/h,m=Nk.pop()||new jk;m.arc=t,m.site=i,m.x=g+o,m.y=(m.cy=y+s)+Math.sqrt(g*g+y*y),t.circle=m;for(var v=null,b=Wk._;b;)if(m.y<b.y||m.y===b.y&&m.x<=b.x){if(!b.L){v=b.P;break}b=b.L}else{if(!b.R){v=b;break}b=b.R}Wk.insert(v,m),v||(Ok=m)}}}}function Bk(t){var e=t.circle;e&&(e.P||(Ok=e.N),Wk.remove(e),Nk.push(e),mk(e),t.circle=null)}var Lk=[];function Ik(){mk(this),this.edge=this.site=this.circle=null}function Rk(t){var e=Lk.pop()||new Ik;return e.site=t,e}function Pk(t){Bk(t),Uk.remove(t),Lk.push(t),mk(t)}function Fk(t){var e=t.circle,n=e.x,r=e.cy,i=[n,r],a=t.P,o=t.N,s=[t];Pk(t);for(var c=a;c.circle&&Math.abs(n-c.circle.x)<$k&&Math.abs(r-c.circle.cy)<$k;)a=c.P,s.unshift(c),Pk(c),c=a;s.unshift(c),Bk(c);for(var u=o;u.circle&&Math.abs(n-u.circle.x)<$k&&Math.abs(r-u.circle.cy)<$k;)o=u.N,s.push(u),Pk(u),u=o;s.push(u),Bk(u);var l,f=s.length;for(l=1;l<f;++l)u=s[l],c=s[l-1],Tk(u.edge,c.site,u.site,i);c=s[0],(u=s[f-1]).edge=wk(c.site,u.site,null,i),Dk(c),Dk(u)}function zk(t){for(var e,n,r,i,a=t[0],o=t[1],s=Uk._;s;)if((r=Yk(s,o)-a)>$k)s=s.L;else{if(!((i=a-qk(s,o))>$k)){r>-$k?(e=s.P,n=s):i>-$k?(e=s,n=s.N):e=n=s;break}if(!s.R){e=s;break}s=s.R}!function(t){Vk[t.index]={site:t,halfedges:[]}}(t);var c=Rk(t);if(Uk.insert(e,c),e||n){if(e===n)return Bk(e),n=Rk(e.site),Uk.insert(c,n),c.edge=n.edge=wk(e.site,c.site),Dk(e),void Dk(n);if(n){Bk(e),Bk(n);var u=e.site,l=u[0],f=u[1],h=t[0]-l,d=t[1]-f,p=n.site,g=p[0]-l,y=p[1]-f,m=2*(h*y-d*g),v=h*h+d*d,b=g*g+y*y,_=[(y*v-d*b)/m+l,(h*b-g*v)/m+f];Tk(n.edge,u,p,_),c.edge=wk(u,t,null,_),n.edge=wk(t,p,null,_),Dk(e),Dk(n)}else c.edge=wk(e.site,c.site)}}function Yk(t,e){var n=t.site,r=n[0],i=n[1],a=i-e;if(!a)return r;var o=t.P;if(!o)return-1/0;var s=(n=o.site)[0],c=n[1],u=c-e;if(!u)return s;var l=s-r,f=1/a-1/u,h=l/u;return f?(-h+Math.sqrt(h*h-2*f*(l*l/(-2*u)-c+u/2+i-a/2)))/f+r:(r+s)/2}function qk(t,e){var n=t.N;if(n)return Yk(n,e);var r=t.site;return r[1]===e?r[0]:1/0}var Uk,Vk,Wk,Hk,$k=1e-6,Gk=1e-12;function Xk(t,e,n){return(t[0]-n[0])*(e[1]-t[1])-(t[0]-e[0])*(n[1]-t[1])}function Zk(t,e){return e[1]-t[1]||e[0]-t[0]}function Kk(t,e){var n,r,i,a=t.sort(Zk).pop();for(Hk=[],Vk=new Array(t.length),Uk=new xk,Wk=new xk;;)if(i=Ok,a&&(!i||a[1]<i.y||a[1]===i.y&&a[0]<i.x))a[0]===n&&a[1]===r||(zk(a),n=a[0],r=a[1]),a=t.pop();else{if(!i)break;Fk(i.arc)}if(function(){for(var t,e,n,r,i=0,a=Vk.length;i<a;++i)if((t=Vk[i])&&(r=(e=t.halfedges).length)){var o=new Array(r),s=new Array(r);for(n=0;n<r;++n)o[n]=n,s[n]=Sk(t,Hk[e[n]]);for(o.sort((function(t,e){return s[e]-s[t]})),n=0;n<r;++n)s[n]=e[o[n]];for(n=0;n<r;++n)e[n]=s[n]}}(),e){var o=+e[0][0],s=+e[0][1],c=+e[1][0],u=+e[1][1];!function(t,e,n,r){for(var i,a=Hk.length;a--;)Ck(i=Hk[a],t,e,n,r)&&Ek(i,t,e,n,r)&&(Math.abs(i[0][0]-i[1][0])>$k||Math.abs(i[0][1]-i[1][1])>$k)||delete Hk[a]}(o,s,c,u),function(t,e,n,r){var i,a,o,s,c,u,l,f,h,d,p,g,y=Vk.length,m=!0;for(i=0;i<y;++i)if(a=Vk[i]){for(o=a.site,s=(c=a.halfedges).length;s--;)Hk[c[s]]||c.splice(s,1);for(s=0,u=c.length;s<u;)p=(d=Ak(a,Hk[c[s]]))[0],g=d[1],f=(l=Mk(a,Hk[c[++s%u]]))[0],h=l[1],(Math.abs(p-f)>$k||Math.abs(g-h)>$k)&&(c.splice(s,0,Hk.push(kk(o,d,Math.abs(p-t)<$k&&r-g>$k?[t,Math.abs(f-t)<$k?h:r]:Math.abs(g-r)<$k&&n-p>$k?[Math.abs(h-r)<$k?f:n,r]:Math.abs(p-n)<$k&&g-e>$k?[n,Math.abs(f-n)<$k?h:e]:Math.abs(g-e)<$k&&p-t>$k?[Math.abs(h-e)<$k?f:t,e]:null))-1),++u);u&&(m=!1)}if(m){var v,b,_,x=1/0;for(i=0,m=null;i<y;++i)(a=Vk[i])&&(_=(v=(o=a.site)[0]-t)*v+(b=o[1]-e)*b)<x&&(x=_,m=a);if(m){var w=[t,e],k=[t,r],T=[n,r],E=[n,e];m.halfedges.push(Hk.push(kk(o=m.site,w,k))-1,Hk.push(kk(o,k,T))-1,Hk.push(kk(o,T,E))-1,Hk.push(kk(o,E,w))-1)}}for(i=0;i<y;++i)(a=Vk[i])&&(a.halfedges.length||delete Vk[i])}(o,s,c,u)}this.edges=Hk,this.cells=Vk,Uk=Wk=Hk=Vk=null}function Qk(){var t=pk,e=gk,n=null;function r(r){return new Kk(r.map((function(n,i){var a=[Math.round(t(n,i,r)/$k)*$k,Math.round(e(n,i,r)/$k)*$k];return a.index=i,a.data=n,a})),n)}return r.polygons=function(t){return r(t).polygons()},r.links=function(t){return r(t).links()},r.triangles=function(t){return r(t).triangles()},r.x=function(e){return arguments.length?(t="function"==typeof e?e:dk(+e),r):t},r.y=function(t){return arguments.length?(e="function"==typeof t?t:dk(+t),r):e},r.extent=function(t){return arguments.length?(n=null==t?null:[[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]],r):n&&[[n[0][0],n[0][1]],[n[1][0],n[1][1]]]},r.size=function(t){return arguments.length?(n=null==t?null:[[0,0],[+t[0],+t[1]]],r):n&&[n[1][0]-n[0][0],n[1][1]-n[0][1]]},r}function Jk(t){return function(){return t}}function tT(t,e,n){this.target=t,this.type=e,this.transform=n}function eT(t,e,n){this.k=t,this.x=e,this.y=n}Kk.prototype={constructor:Kk,polygons:function(){var t=this.edges;return this.cells.map((function(e){var n=e.halfedges.map((function(n){return Mk(e,t[n])}));return n.data=e.site.data,n}))},triangles:function(){var t=[],e=this.edges;return this.cells.forEach((function(n,r){if(a=(i=n.halfedges).length)for(var i,a,o,s=n.site,c=-1,u=e[i[a-1]],l=u.left===s?u.right:u.left;++c<a;)o=l,l=(u=e[i[c]]).left===s?u.right:u.left,o&&l&&r<o.index&&r<l.index&&Xk(s,o,l)<0&&t.push([s.data,o.data,l.data])})),t},links:function(){return this.edges.filter((function(t){return t.right})).map((function(t){return{source:t.left.data,target:t.right.data}}))},find:function(t,e,n){for(var r,i,a=this,o=a._found||0,s=a.cells.length;!(i=a.cells[o]);)if(++o>=s)return null;var c=t-i.site[0],u=e-i.site[1],l=c*c+u*u;do{i=a.cells[r=o],o=null,i.halfedges.forEach((function(n){var r=a.edges[n],s=r.left;if(s!==i.site&&s||(s=r.right)){var c=t-s[0],u=e-s[1],f=c*c+u*u;f<l&&(l=f,o=s.index)}}))}while(null!==o);return a._found=r,null==n||l<=n*n?i.site:null}},eT.prototype={constructor:eT,scale:function(t){return 1===t?this:new eT(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new eT(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var nT=new eT(1,0,0);function rT(t){for(;!t.__zoom;)if(!(t=t.parentNode))return nT;return t.__zoom}function iT(){le.stopImmediatePropagation()}function aT(){le.preventDefault(),le.stopImmediatePropagation()}function oT(){return!le.ctrlKey&&!le.button}function sT(){var t=this;return t instanceof SVGElement?(t=t.ownerSVGElement||t).hasAttribute("viewBox")?[[(t=t.viewBox.baseVal).x,t.y],[t.x+t.width,t.y+t.height]]:[[0,0],[t.width.baseVal.value,t.height.baseVal.value]]:[[0,0],[t.clientWidth,t.clientHeight]]}function cT(){return this.__zoom||nT}function uT(){return-le.deltaY*(1===le.deltaMode?.05:le.deltaMode?1:.002)}function lT(){return navigator.maxTouchPoints||"ontouchstart"in this}function fT(t,e,n){var r=t.invertX(e[0][0])-n[0][0],i=t.invertX(e[1][0])-n[1][0],a=t.invertY(e[0][1])-n[0][1],o=t.invertY(e[1][1])-n[1][1];return t.translate(i>r?(r+i)/2:Math.min(0,r)||Math.max(0,i),o>a?(a+o)/2:Math.min(0,a)||Math.max(0,o))}function hT(){var t,e,n=oT,r=sT,i=fT,a=uT,o=lT,s=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],u=250,l=jp,f=ht("start","zoom","end"),h=500,d=0;function p(t){t.property("__zoom",cT).on("wheel.zoom",x).on("mousedown.zoom",w).on("dblclick.zoom",k).filter(o).on("touchstart.zoom",T).on("touchmove.zoom",E).on("touchend.zoom touchcancel.zoom",C).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function g(t,e){return(e=Math.max(s[0],Math.min(s[1],e)))===t.k?t:new eT(e,t.x,t.y)}function y(t,e,n){var r=e[0]-n[0]*t.k,i=e[1]-n[1]*t.k;return r===t.x&&i===t.y?t:new eT(t.k,r,i)}function m(t){return[(+t[0][0]+ +t[1][0])/2,(+t[0][1]+ +t[1][1])/2]}function v(t,e,n){t.on("start.zoom",(function(){b(this,arguments).start()})).on("interrupt.zoom end.zoom",(function(){b(this,arguments).end()})).tween("zoom",(function(){var t=this,i=arguments,a=b(t,i),o=r.apply(t,i),s=null==n?m(o):"function"==typeof n?n.apply(t,i):n,c=Math.max(o[1][0]-o[0][0],o[1][1]-o[0][1]),u=t.__zoom,f="function"==typeof e?e.apply(t,i):e,h=l(u.invert(s).concat(c/u.k),f.invert(s).concat(c/f.k));return function(t){if(1===t)t=f;else{var e=h(t),n=c/e[2];t=new eT(n,s[0]-e[0]*n,s[1]-e[1]*n)}a.zoom(null,t)}}))}function b(t,e,n){return!n&&t.__zooming||new _(t,e)}function _(t,e){this.that=t,this.args=e,this.active=0,this.extent=r.apply(t,e),this.taps=0}function x(){if(n.apply(this,arguments)){var t=b(this,arguments),e=this.__zoom,r=Math.max(s[0],Math.min(s[1],e.k*Math.pow(2,a.apply(this,arguments)))),o=Dn(this);if(t.wheel)t.mouse[0][0]===o[0]&&t.mouse[0][1]===o[1]||(t.mouse[1]=e.invert(t.mouse[0]=o)),clearTimeout(t.wheel);else{if(e.k===r)return;t.mouse=[o,e.invert(o)],ar(this),t.start()}aT(),t.wheel=setTimeout(u,150),t.zoom("mouse",i(y(g(e,r),t.mouse[0],t.mouse[1]),t.extent,c))}function u(){t.wheel=null,t.end()}}function w(){if(!e&&n.apply(this,arguments)){var t=b(this,arguments,!0),r=Te(le.view).on("mousemove.zoom",u,!0).on("mouseup.zoom",l,!0),a=Dn(this),o=le.clientX,s=le.clientY;Se(le.view),iT(),t.mouse=[a,this.__zoom.invert(a)],ar(this),t.start()}function u(){if(aT(),!t.moved){var e=le.clientX-o,n=le.clientY-s;t.moved=e*e+n*n>d}t.zoom("mouse",i(y(t.that.__zoom,t.mouse[0]=Dn(t.that),t.mouse[1]),t.extent,c))}function l(){r.on("mousemove.zoom mouseup.zoom",null),Me(le.view,t.moved),aT(),t.end()}}function k(){if(n.apply(this,arguments)){var t=this.__zoom,e=Dn(this),a=t.invert(e),o=t.k*(le.shiftKey?.5:2),s=i(y(g(t,o),e,a),r.apply(this,arguments),c);aT(),u>0?Te(this).transition().duration(u).call(v,s,e):Te(this).call(p.transform,s)}}function T(){if(n.apply(this,arguments)){var e,r,i,a,o=le.touches,s=o.length,c=b(this,arguments,le.changedTouches.length===s);for(iT(),r=0;r<s;++r)a=[a=jn(this,o,(i=o[r]).identifier),this.__zoom.invert(a),i.identifier],c.touch0?c.touch1||c.touch0[2]===a[2]||(c.touch1=a,c.taps=0):(c.touch0=a,e=!0,c.taps=1+!!t);t&&(t=clearTimeout(t)),e&&(c.taps<2&&(t=setTimeout((function(){t=null}),h)),ar(this),c.start())}}function E(){if(this.__zooming){var e,n,r,a,o=b(this,arguments),s=le.changedTouches,u=s.length;for(aT(),t&&(t=clearTimeout(t)),o.taps=0,e=0;e<u;++e)r=jn(this,s,(n=s[e]).identifier),o.touch0&&o.touch0[2]===n.identifier?o.touch0[0]=r:o.touch1&&o.touch1[2]===n.identifier&&(o.touch1[0]=r);if(n=o.that.__zoom,o.touch1){var l=o.touch0[0],f=o.touch0[1],h=o.touch1[0],d=o.touch1[1],p=(p=h[0]-l[0])*p+(p=h[1]-l[1])*p,m=(m=d[0]-f[0])*m+(m=d[1]-f[1])*m;n=g(n,Math.sqrt(p/m)),r=[(l[0]+h[0])/2,(l[1]+h[1])/2],a=[(f[0]+d[0])/2,(f[1]+d[1])/2]}else{if(!o.touch0)return;r=o.touch0[0],a=o.touch0[1]}o.zoom("touch",i(y(n,r,a),o.extent,c))}}function C(){if(this.__zooming){var t,n,r=b(this,arguments),i=le.changedTouches,a=i.length;for(iT(),e&&clearTimeout(e),e=setTimeout((function(){e=null}),h),t=0;t<a;++t)n=i[t],r.touch0&&r.touch0[2]===n.identifier?delete r.touch0:r.touch1&&r.touch1[2]===n.identifier&&delete r.touch1;if(r.touch1&&!r.touch0&&(r.touch0=r.touch1,delete r.touch1),r.touch0)r.touch0[1]=this.__zoom.invert(r.touch0[0]);else if(r.end(),2===r.taps){var o=Te(this).on("dblclick.zoom");o&&o.apply(this,arguments)}}}return p.transform=function(t,e,n){var r=t.selection?t.selection():t;r.property("__zoom",cT),t!==r?v(t,e,n):r.interrupt().each((function(){b(this,arguments).start().zoom(null,"function"==typeof e?e.apply(this,arguments):e).end()}))},p.scaleBy=function(t,e,n){p.scaleTo(t,(function(){var t=this.__zoom.k,n="function"==typeof e?e.apply(this,arguments):e;return t*n}),n)},p.scaleTo=function(t,e,n){p.transform(t,(function(){var t=r.apply(this,arguments),a=this.__zoom,o=null==n?m(t):"function"==typeof n?n.apply(this,arguments):n,s=a.invert(o),u="function"==typeof e?e.apply(this,arguments):e;return i(y(g(a,u),o,s),t,c)}),n)},p.translateBy=function(t,e,n){p.transform(t,(function(){return i(this.__zoom.translate("function"==typeof e?e.apply(this,arguments):e,"function"==typeof n?n.apply(this,arguments):n),r.apply(this,arguments),c)}))},p.translateTo=function(t,e,n,a){p.transform(t,(function(){var t=r.apply(this,arguments),o=this.__zoom,s=null==a?m(t):"function"==typeof a?a.apply(this,arguments):a;return i(nT.translate(s[0],s[1]).scale(o.k).translate("function"==typeof e?-e.apply(this,arguments):-e,"function"==typeof n?-n.apply(this,arguments):-n),t,c)}),a)},_.prototype={start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(t,e){return this.mouse&&"mouse"!==t&&(this.mouse[1]=e.invert(this.mouse[0])),this.touch0&&"touch"!==t&&(this.touch0[1]=e.invert(this.touch0[0])),this.touch1&&"touch"!==t&&(this.touch1[1]=e.invert(this.touch1[0])),this.that.__zoom=e,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(t){ye(new tT(p,t,this.that.__zoom),f.apply,f,[t,this.that,this.args])}},p.wheelDelta=function(t){return arguments.length?(a="function"==typeof t?t:Jk(+t),p):a},p.filter=function(t){return arguments.length?(n="function"==typeof t?t:Jk(!!t),p):n},p.touchable=function(t){return arguments.length?(o="function"==typeof t?t:Jk(!!t),p):o},p.extent=function(t){return arguments.length?(r="function"==typeof t?t:Jk([[+t[0][0],+t[0][1]],[+t[1][0],+t[1][1]]]),p):r},p.scaleExtent=function(t){return arguments.length?(s[0]=+t[0],s[1]=+t[1],p):[s[0],s[1]]},p.translateExtent=function(t){return arguments.length?(c[0][0]=+t[0][0],c[1][0]=+t[1][0],c[0][1]=+t[0][1],c[1][1]=+t[1][1],p):[[c[0][0],c[0][1]],[c[1][0],c[1][1]]]},p.constrain=function(t){return arguments.length?(i=t,p):i},p.duration=function(t){return arguments.length?(u=+t,p):u},p.interpolate=function(t){return arguments.length?(l=t,p):l},p.on=function(){var t=f.on.apply(f,arguments);return t===f?p:t},p.clickDistance=function(t){return arguments.length?(d=(t=+t)*t,p):Math.sqrt(d)},p}rT.prototype=eT.prototype},681:(t,e,n)=>{t.exports={graphlib:n(574),layout:n(8123),debug:n(7570),util:{time:n(1138).time,notime:n(1138).notime},version:n(8177)}},2188:(t,e,n)=>{"use strict";var r=n(8436),i=n(4079);t.exports={run:function(t){var e="greedy"===t.graph().acyclicer?i(t,function(t){return function(e){return t.edge(e).weight}}(t)):function(t){var e=[],n={},i={};return r.forEach(t.nodes(),(function a(o){r.has(i,o)||(i[o]=!0,n[o]=!0,r.forEach(t.outEdges(o),(function(t){r.has(n,t.w)?e.push(t):a(t.w)})),delete n[o])})),e}(t);r.forEach(e,(function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,r.uniqueId("rev"))}))},undo:function(t){r.forEach(t.edges(),(function(e){var n=t.edge(e);if(n.reversed){t.removeEdge(e);var r=n.forwardName;delete n.reversed,delete n.forwardName,t.setEdge(e.w,e.v,n,r)}}))}}},1133:(t,e,n)=>{var r=n(8436),i=n(1138);function a(t,e,n,r,a,o){var s={width:0,height:0,rank:o,borderType:e},c=a[e][o-1],u=i.addDummyNode(t,"border",s,n);a[e][o]=u,t.setParent(u,r),c&&t.setEdge(c,u,{weight:1})}t.exports=function(t){r.forEach(t.children(),(function e(n){var i=t.children(n),o=t.node(n);if(i.length&&r.forEach(i,e),r.has(o,"minRank")){o.borderLeft=[],o.borderRight=[];for(var s=o.minRank,c=o.maxRank+1;s<c;++s)a(t,"borderLeft","_bl",n,o,s),a(t,"borderRight","_br",n,o,s)}}))}},3258:(t,e,n)=>{"use strict";var r=n(8436);function i(t){r.forEach(t.nodes(),(function(e){a(t.node(e))})),r.forEach(t.edges(),(function(e){a(t.edge(e))}))}function a(t){var e=t.width;t.width=t.height,t.height=e}function o(t){t.y=-t.y}function s(t){var e=t.x;t.x=t.y,t.y=e}t.exports={adjust:function(t){var e=t.graph().rankdir.toLowerCase();"lr"!==e&&"rl"!==e||i(t)},undo:function(t){var e=t.graph().rankdir.toLowerCase();"bt"!==e&&"rl"!==e||function(t){r.forEach(t.nodes(),(function(e){o(t.node(e))})),r.forEach(t.edges(),(function(e){var n=t.edge(e);r.forEach(n.points,o),r.has(n,"y")&&o(n)}))}(t),"lr"!==e&&"rl"!==e||(function(t){r.forEach(t.nodes(),(function(e){s(t.node(e))})),r.forEach(t.edges(),(function(e){var n=t.edge(e);r.forEach(n.points,s),r.has(n,"x")&&s(n)}))}(t),i(t))}}},7822:t=>{function e(){var t={};t._next=t._prev=t,this._sentinel=t}function n(t){t._prev._next=t._next,t._next._prev=t._prev,delete t._next,delete t._prev}function r(t,e){if("_next"!==t&&"_prev"!==t)return e}t.exports=e,e.prototype.dequeue=function(){var t=this._sentinel,e=t._prev;if(e!==t)return n(e),e},e.prototype.enqueue=function(t){var e=this._sentinel;t._prev&&t._next&&n(t),t._next=e._next,e._next._prev=t,e._next=t,t._prev=e},e.prototype.toString=function(){for(var t=[],e=this._sentinel,n=e._prev;n!==e;)t.push(JSON.stringify(n,r)),n=n._prev;return"["+t.join(", ")+"]"}},7570:(t,e,n)=>{var r=n(8436),i=n(1138),a=n(574).Graph;t.exports={debugOrdering:function(t){var e=i.buildLayerMatrix(t),n=new a({compound:!0,multigraph:!0}).setGraph({});return r.forEach(t.nodes(),(function(e){n.setNode(e,{label:e}),n.setParent(e,"layer"+t.node(e).rank)})),r.forEach(t.edges(),(function(t){n.setEdge(t.v,t.w,{},t.name)})),r.forEach(e,(function(t,e){var i="layer"+e;n.setNode(i,{rank:"same"}),r.reduce(t,(function(t,e){return n.setEdge(t,e,{style:"invis"}),e}))})),n}}},574:(t,e,n)=>{var r;try{r=n(8282)}catch(t){}r||(r=window.graphlib),t.exports=r},4079:(t,e,n)=>{var r=n(8436),i=n(574).Graph,a=n(7822);t.exports=function(t,e){if(t.nodeCount()<=1)return[];var n=function(t,e){var n=new i,o=0,s=0;r.forEach(t.nodes(),(function(t){n.setNode(t,{v:t,in:0,out:0})})),r.forEach(t.edges(),(function(t){var r=n.edge(t.v,t.w)||0,i=e(t),a=r+i;n.setEdge(t.v,t.w,a),s=Math.max(s,n.node(t.v).out+=i),o=Math.max(o,n.node(t.w).in+=i)}));var u=r.range(s+o+3).map((function(){return new a})),l=o+1;return r.forEach(n.nodes(),(function(t){c(u,l,n.node(t))})),{graph:n,buckets:u,zeroIdx:l}}(t,e||o),u=function(t,e,n){for(var r,i=[],a=e[e.length-1],o=e[0];t.nodeCount();){for(;r=o.dequeue();)s(t,e,n,r);for(;r=a.dequeue();)s(t,e,n,r);if(t.nodeCount())for(var c=e.length-2;c>0;--c)if(r=e[c].dequeue()){i=i.concat(s(t,e,n,r,!0));break}}return i}(n.graph,n.buckets,n.zeroIdx);return r.flatten(r.map(u,(function(e){return t.outEdges(e.v,e.w)})),!0)};var o=r.constant(1);function s(t,e,n,i,a){var o=a?[]:void 0;return r.forEach(t.inEdges(i.v),(function(r){var i=t.edge(r),s=t.node(r.v);a&&o.push({v:r.v,w:r.w}),s.out-=i,c(e,n,s)})),r.forEach(t.outEdges(i.v),(function(r){var i=t.edge(r),a=r.w,o=t.node(a);o.in-=i,c(e,n,o)})),t.removeNode(i.v),o}function c(t,e,n){n.out?n.in?t[n.out-n.in+e].enqueue(n):t[t.length-1].enqueue(n):t[0].enqueue(n)}},8123:(t,e,n)=>{"use strict";var r=n(8436),i=n(2188),a=n(5995),o=n(8093),s=n(1138).normalizeRanks,c=n(4219),u=n(1138).removeEmptyRanks,l=n(2981),f=n(1133),h=n(3258),d=n(3408),p=n(7873),g=n(1138),y=n(574).Graph;t.exports=function(t,e){var n=e&&e.debugTiming?g.time:g.notime;n("layout",(function(){var e=n(" buildLayoutGraph",(function(){return function(t){var e=new y({multigraph:!0,compound:!0}),n=C(t.graph());return e.setGraph(r.merge({},v,E(n,m),r.pick(n,b))),r.forEach(t.nodes(),(function(n){var i=C(t.node(n));e.setNode(n,r.defaults(E(i,_),x)),e.setParent(n,t.parent(n))})),r.forEach(t.edges(),(function(n){var i=C(t.edge(n));e.setEdge(n,r.merge({},k,E(i,w),r.pick(i,T)))})),e}(t)}));n(" runLayout",(function(){!function(t,e){e(" makeSpaceForEdgeLabels",(function(){!function(t){var e=t.graph();e.ranksep/=2,r.forEach(t.edges(),(function(n){var r=t.edge(n);r.minlen*=2,"c"!==r.labelpos.toLowerCase()&&("TB"===e.rankdir||"BT"===e.rankdir?r.width+=r.labeloffset:r.height+=r.labeloffset)}))}(t)})),e(" removeSelfEdges",(function(){!function(t){r.forEach(t.edges(),(function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e,label:t.edge(e)}),t.removeEdge(e)}}))}(t)})),e(" acyclic",(function(){i.run(t)})),e(" nestingGraph.run",(function(){l.run(t)})),e(" rank",(function(){o(g.asNonCompoundGraph(t))})),e(" injectEdgeLabelProxies",(function(){!function(t){r.forEach(t.edges(),(function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i={rank:(t.node(e.w).rank-r.rank)/2+r.rank,e};g.addDummyNode(t,"edge-proxy",i,"_ep")}}))}(t)})),e(" removeEmptyRanks",(function(){u(t)})),e(" nestingGraph.cleanup",(function(){l.cleanup(t)})),e(" normalizeRanks",(function(){s(t)})),e(" assignRankMinMax",(function(){!function(t){var e=0;r.forEach(t.nodes(),(function(n){var i=t.node(n);i.borderTop&&(i.minRank=t.node(i.borderTop).rank,i.maxRank=t.node(i.borderBottom).rank,e=r.max(e,i.maxRank))})),t.graph().maxRank=e}(t)})),e(" removeEdgeLabelProxies",(function(){!function(t){r.forEach(t.nodes(),(function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))}))}(t)})),e(" normalize.run",(function(){a.run(t)})),e(" parentDummyChains",(function(){c(t)})),e(" addBorderSegments",(function(){f(t)})),e(" order",(function(){d(t)})),e(" insertSelfEdges",(function(){!function(t){var e=g.buildLayerMatrix(t);r.forEach(e,(function(e){var n=0;r.forEach(e,(function(e,i){var a=t.node(e);a.order=i+n,r.forEach(a.selfEdges,(function(e){g.addDummyNode(t,"selfedge",{width:e.label.width,height:e.label.height,rank:a.rank,order:i+ ++n,e:e.e,label:e.label},"_se")})),delete a.selfEdges}))}))}(t)})),e(" adjustCoordinateSystem",(function(){h.adjust(t)})),e(" position",(function(){p(t)})),e(" positionSelfEdges",(function(){!function(t){r.forEach(t.nodes(),(function(e){var n=t.node(e);if("selfedge"===n.dummy){var r=t.node(n.e.v),i=r.x+r.width/2,a=r.y,o=n.x-i,s=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*o/3,y:a-s},{x:i+5*o/6,y:a-s},{x:i+o,y:a},{x:i+5*o/6,y:a+s},{x:i+2*o/3,y:a+s}],n.label.x=n.x,n.label.y=n.y}}))}(t)})),e(" removeBorderNodes",(function(){!function(t){r.forEach(t.nodes(),(function(e){if(t.children(e).length){var n=t.node(e),i=t.node(n.borderTop),a=t.node(n.borderBottom),o=t.node(r.last(n.borderLeft)),s=t.node(r.last(n.borderRight));n.width=Math.abs(s.x-o.x),n.height=Math.abs(a.y-i.y),n.x=o.x+n.width/2,n.y=i.y+n.height/2}})),r.forEach(t.nodes(),(function(e){"border"===t.node(e).dummy&&t.removeNode(e)}))}(t)})),e(" normalize.undo",(function(){a.undo(t)})),e(" fixupEdgeLabelCoords",(function(){!function(t){r.forEach(t.edges(),(function(e){var n=t.edge(e);if(r.has(n,"x"))switch("l"!==n.labelpos&&"r"!==n.labelpos||(n.width-=n.labeloffset),n.labelpos){case"l":n.x-=n.width/2+n.labeloffset;break;case"r":n.x+=n.width/2+n.labeloffset}}))}(t)})),e(" undoCoordinateSystem",(function(){h.undo(t)})),e(" translateGraph",(function(){!function(t){var e=Number.POSITIVE_INFINITY,n=0,i=Number.POSITIVE_INFINITY,a=0,o=t.graph(),s=o.marginx||0,c=o.marginy||0;function u(t){var r=t.x,o=t.y,s=t.width,c=t.height;e=Math.min(e,r-s/2),n=Math.max(n,r+s/2),i=Math.min(i,o-c/2),a=Math.max(a,o+c/2)}r.forEach(t.nodes(),(function(e){u(t.node(e))})),r.forEach(t.edges(),(function(e){var n=t.edge(e);r.has(n,"x")&&u(n)})),e-=s,i-=c,r.forEach(t.nodes(),(function(n){var r=t.node(n);r.x-=e,r.y-=i})),r.forEach(t.edges(),(function(n){var a=t.edge(n);r.forEach(a.points,(function(t){t.x-=e,t.y-=i})),r.has(a,"x")&&(a.x-=e),r.has(a,"y")&&(a.y-=i)})),o.width=n-e+s,o.height=a-i+c}(t)})),e(" assignNodeIntersects",(function(){!function(t){r.forEach(t.edges(),(function(e){var n,r,i=t.edge(e),a=t.node(e.v),o=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=o,r=a),i.points.unshift(g.intersectRect(a,n)),i.points.push(g.intersectRect(o,r))}))}(t)})),e(" reversePoints",(function(){!function(t){r.forEach(t.edges(),(function(e){var n=t.edge(e);n.reversed&&n.points.reverse()}))}(t)})),e(" acyclic.undo",(function(){i.undo(t)}))}(e,n)})),n(" updateInputGraph",(function(){!function(t,e){r.forEach(t.nodes(),(function(n){var r=t.node(n),i=e.node(n);r&&(r.x=i.x,r.y=i.y,e.children(n).length&&(r.width=i.width,r.height=i.height))})),r.forEach(t.edges(),(function(n){var i=t.edge(n),a=e.edge(n);i.points=a.points,r.has(a,"x")&&(i.x=a.x,i.y=a.y)})),t.graph().width=e.graph().width,t.graph().height=e.graph().height}(t,e)}))}))};var m=["nodesep","edgesep","ranksep","marginx","marginy"],v={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},b=["acyclicer","ranker","rankdir","align"],_=["width","height"],x={width:0,height:0},w=["minlen","weight","width","height","labeloffset"],k={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},T=["labelpos"];function E(t,e){return r.mapValues(r.pick(t,e),Number)}function C(t){var e={};return r.forEach(t,(function(t,n){e[n.toLowerCase()]=t})),e}},8436:(t,e,n)=>{var r;try{r={cloneDeep:n(361),constant:n(5703),defaults:n(1747),each:n(6073),filter:n(3105),find:n(3311),flatten:n(5564),forEach:n(4486),forIn:n(2620),has:n(8721),isUndefined:n(2353),last:n(928),map:n(5161),mapValues:n(6604),max:n(6162),merge:n(3857),min:n(3632),minBy:n(2762),now:n(7771),pick:n(9722),range:n(6026),reduce:n(4061),sortBy:n(9734),uniqueId:n(3955),values:n(2628),zipObject:n(7287)}}catch(t){}r||(r=window._),t.exports=r},2981:(t,e,n)=>{var r=n(8436),i=n(1138);function a(t,e,n,o,s,c,u){var l=t.children(u);if(l.length){var f=i.addBorderNode(t,"_bt"),h=i.addBorderNode(t,"_bb"),d=t.node(u);t.setParent(f,u),d.borderTop=f,t.setParent(h,u),d.borderBottom=h,r.forEach(l,(function(r){a(t,e,n,o,s,c,r);var i=t.node(r),l=i.borderTop?i.borderTop:r,d=i.borderBottom?i.borderBottom:r,p=i.borderTop?o:2*o,g=l!==d?1:s-c[u]+1;t.setEdge(f,l,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,h,{weight:p,minlen:g,nestingEdge:!0})})),t.parent(u)||t.setEdge(e,f,{weight:0,minlen:s+c[u]})}else u!==e&&t.setEdge(e,u,{weight:0,minlen:n})}t.exports={run:function(t){var e=i.addDummyNode(t,"root",{},"_root"),n=function(t){var e={};function n(i,a){var o=t.children(i);o&&o.length&&r.forEach(o,(function(t){n(t,a+1)})),e[i]=a}return r.forEach(t.children(),(function(t){n(t,1)})),e}(t),o=r.max(r.values(n))-1,s=2*o+1;t.graph().nestingRoot=e,r.forEach(t.edges(),(function(e){t.edge(e).minlen*=s}));var c=function(t){return r.reduce(t.edges(),(function(e,n){return e+t.edge(n).weight}),0)}(t)+1;r.forEach(t.children(),(function(r){a(t,e,s,c,o,n,r)})),t.graph().nodeRankFactor=s},cleanup:function(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,r.forEach(t.edges(),(function(e){t.edge(e).nestingEdge&&t.removeEdge(e)}))}}},5995:(t,e,n)=>{"use strict";var r=n(8436),i=n(1138);t.exports={run:function(t){t.graph().dummyChains=[],r.forEach(t.edges(),(function(e){!function(t,e){var n,r,a,o=e.v,s=t.node(o).rank,c=e.w,u=t.node(c).rank,l=e.name,f=t.edge(e),h=f.labelRank;if(u!==s+1){for(t.removeEdge(e),a=0,++s;s<u;++a,++s)f.points=[],r={width:0,height:0,edgeLabel:f,edgeObj:e,rank:s},n=i.addDummyNode(t,"edge",r,"_d"),s===h&&(r.width=f.width,r.height=f.height,r.dummy="edge-label",r.labelpos=f.labelpos),t.setEdge(o,n,{weight:f.weight},l),0===a&&t.graph().dummyChains.push(n),o=n;t.setEdge(o,c,{weight:f.weight},l)}}(t,e)}))},undo:function(t){r.forEach(t.graph().dummyChains,(function(e){var n,r=t.node(e),i=r.edgeLabel;for(t.setEdge(r.edgeObj,i);r.dummy;)n=t.successors(e)[0],t.removeNode(e),i.points.push({x:r.x,y:r.y}),"edge-label"===r.dummy&&(i.x=r.x,i.y=r.y,i.width=r.width,i.height=r.height),e=n,r=t.node(e)}))}}},5093:(t,e,n)=>{var r=n(8436);t.exports=function(t,e,n){var i,a={};r.forEach(n,(function(n){for(var r,o,s=t.parent(n);s;){if((r=t.parent(s))?(o=a[r],a[r]=s):(o=i,i=s),o&&o!==s)return void e.setEdge(o,s);s=r}}))}},5439:(t,e,n)=>{var r=n(8436);t.exports=function(t,e){return r.map(e,(function(e){var n=t.inEdges(e);if(n.length){var i=r.reduce(n,(function(e,n){var r=t.edge(n),i=t.node(n.v);return{sum:e.sum+r.weight*i.order,weight:e.weight+r.weight}}),{sum:0,weight:0});return{v:e,barycenter:i.sum/i.weight,weight:i.weight}}return{v:e}}))}},3128:(t,e,n)=>{var r=n(8436),i=n(574).Graph;t.exports=function(t,e,n){var a=function(t){for(var e;t.hasNode(e=r.uniqueId("_root")););return e}(t),o=new i({compound:!0}).setGraph({root:a}).setDefaultNodeLabel((function(e){return t.node(e)}));return r.forEach(t.nodes(),(function(i){var s=t.node(i),c=t.parent(i);(s.rank===e||s.minRank<=e&&e<=s.maxRank)&&(o.setNode(i),o.setParent(i,c||a),r.forEach(t[n](i),(function(e){var n=e.v===i?e.w:e.v,a=o.edge(n,i),s=r.isUndefined(a)?0:a.weight;o.setEdge(n,i,{weight:t.edge(e).weight+s})})),r.has(s,"minRank")&&o.setNode(i,{borderLeft:s.borderLeft[e],borderRight:s.borderRight[e]}))})),o}},6630:(t,e,n)=>{"use strict";var r=n(8436);function i(t,e,n){for(var i=r.zipObject(n,r.map(n,(function(t,e){return e}))),a=r.flatten(r.map(e,(function(e){return r.sortBy(r.map(t.outEdges(e),(function(e){return{pos:i[e.w],weight:t.edge(e).weight}})),"pos")})),!0),o=1;o<n.length;)o<<=1;var s=2*o-1;o-=1;var c=r.map(new Array(s),(function(){return 0})),u=0;return r.forEach(a.forEach((function(t){var e=t.pos+o;c[e]+=t.weight;for(var n=0;e>0;)e%2&&(n+=c[e+1]),c[e=e-1>>1]+=t.weight;u+=t.weight*n}))),u}t.exports=function(t,e){for(var n=0,r=1;r<e.length;++r)n+=i(t,e[r-1],e[r]);return n}},3408:(t,e,n)=>{"use strict";var r=n(8436),i=n(2588),a=n(6630),o=n(1026),s=n(3128),c=n(5093),u=n(574).Graph,l=n(1138);function f(t,e,n){return r.map(e,(function(e){return s(t,e,n)}))}function h(t,e){var n=new u;r.forEach(t,(function(t){var i=t.graph().root,a=o(t,i,n,e);r.forEach(a.vs,(function(e,n){t.node(e).order=n})),c(t,n,a.vs)}))}function d(t,e){r.forEach(e,(function(e){r.forEach(e,(function(e,n){t.node(e).order=n}))}))}t.exports=function(t){var e=l.maxRank(t),n=f(t,r.range(1,e+1),"inEdges"),o=f(t,r.range(e-1,-1,-1),"outEdges"),s=i(t);d(t,s);for(var c,u=Number.POSITIVE_INFINITY,p=0,g=0;g<4;++p,++g){h(p%2?n:o,p%4>=2),s=l.buildLayerMatrix(t);var y=a(t,s);y<u&&(g=0,c=r.cloneDeep(s),u=y)}d(t,c)}},2588:(t,e,n)=>{"use strict";var r=n(8436);t.exports=function(t){var e={},n=r.filter(t.nodes(),(function(e){return!t.children(e).length})),i=r.max(r.map(n,(function(e){return t.node(e).rank}))),a=r.map(r.range(i+1),(function(){return[]})),o=r.sortBy(n,(function(e){return t.node(e).rank}));return r.forEach(o,(function n(i){if(!r.has(e,i)){e[i]=!0;var o=t.node(i);a[o.rank].push(i),r.forEach(t.successors(i),n)}})),a}},9567:(t,e,n)=>{"use strict";var r=n(8436);t.exports=function(t,e){var n={};return r.forEach(t,(function(t,e){var i=n[t.v]={indegree:0,in:[],out:[],vs:[t.v],i:e};r.isUndefined(t.barycenter)||(i.barycenter=t.barycenter,i.weight=t.weight)})),r.forEach(e.edges(),(function(t){var e=n[t.v],i=n[t.w];r.isUndefined(e)||r.isUndefined(i)||(i.indegree++,e.out.push(n[t.w]))})),function(t){var e=[];function n(t){return function(e){var n,i,a,o;e.merged||(r.isUndefined(e.barycenter)||r.isUndefined(t.barycenter)||e.barycenter>=t.barycenter)&&(i=e,a=0,o=0,(n=t).weight&&(a+=n.barycenter*n.weight,o+=n.weight),i.weight&&(a+=i.barycenter*i.weight,o+=i.weight),n.vs=i.vs.concat(n.vs),n.barycenter=a/o,n.weight=o,n.i=Math.min(i.i,n.i),i.merged=!0)}}function i(e){return function(n){n.in.push(e),0==--n.indegree&&t.push(n)}}for(;t.length;){var a=t.pop();e.push(a),r.forEach(a.in.reverse(),n(a)),r.forEach(a.out,i(a))}return r.map(r.filter(e,(function(t){return!t.merged})),(function(t){return r.pick(t,["vs","i","barycenter","weight"])}))}(r.filter(n,(function(t){return!t.indegree})))}},1026:(t,e,n)=>{var r=n(8436),i=n(5439),a=n(9567),o=n(7304);t.exports=function t(e,n,s,c){var u=e.children(n),l=e.node(n),f=l?l.borderLeft:void 0,h=l?l.borderRight:void 0,d={};f&&(u=r.filter(u,(function(t){return t!==f&&t!==h})));var p=i(e,u);r.forEach(p,(function(n){if(e.children(n.v).length){var i=t(e,n.v,s,c);d[n.v]=i,r.has(i,"barycenter")&&(a=n,o=i,r.isUndefined(a.barycenter)?(a.barycenter=o.barycenter,a.weight=o.weight):(a.barycenter=(a.barycenter*a.weight+o.barycenter*o.weight)/(a.weight+o.weight),a.weight+=o.weight))}var a,o}));var g=a(p,s);!function(t,e){r.forEach(t,(function(t){t.vs=r.flatten(t.vs.map((function(t){return e[t]?e[t].vs:t})),!0)}))}(g,d);var y=o(g,c);if(f&&(y.vs=r.flatten([f,y.vs,h],!0),e.predecessors(f).length)){var m=e.node(e.predecessors(f)[0]),v=e.node(e.predecessors(h)[0]);r.has(y,"barycenter")||(y.barycenter=0,y.weight=0),y.barycenter=(y.barycenter*y.weight+m.order+v.order)/(y.weight+2),y.weight+=2}return y}},7304:(t,e,n)=>{var r=n(8436),i=n(1138);function a(t,e,n){for(var i;e.length&&(i=r.last(e)).i<=n;)e.pop(),t.push(i.vs),n++;return n}t.exports=function(t,e){var n,o=i.partition(t,(function(t){return r.has(t,"barycenter")})),s=o.lhs,c=r.sortBy(o.rhs,(function(t){return-t.i})),u=[],l=0,f=0,h=0;s.sort((n=!!e,function(t,e){return t.barycenter<e.barycenter?-1:t.barycenter>e.barycenter?1:n?e.i-t.i:t.i-e.i})),h=a(u,c,h),r.forEach(s,(function(t){h+=t.vs.length,u.push(t.vs),l+=t.barycenter*t.weight,f+=t.weight,h=a(u,c,h)}));var d={vs:r.flatten(u,!0)};return f&&(d.barycenter=l/f,d.weight=f),d}},4219:(t,e,n)=>{var r=n(8436);t.exports=function(t){var e=function(t){var e={},n=0;return r.forEach(t.children(),(function i(a){var o=n;r.forEach(t.children(a),i),e[a]={low:o,lim:n++}})),e}(t);r.forEach(t.graph().dummyChains,(function(n){for(var r=t.node(n),i=r.edgeObj,a=function(t,e,n,r){var i,a,o=[],s=[],c=Math.min(e[n].low,e[r].low),u=Math.max(e[n].lim,e[r].lim);i=n;do{i=t.parent(i),o.push(i)}while(i&&(e[i].low>c||u>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)s.push(i);return{path:o.concat(s.reverse()),lca:a}}(t,e,i.v,i.w),o=a.path,s=a.lca,c=0,u=o[c],l=!0;n!==i.w;){if(r=t.node(n),l){for(;(u=o[c])!==s&&t.node(u).maxRank<r.rank;)c++;u===s&&(l=!1)}if(!l){for(;c<o.length-1&&t.node(u=o[c+1]).minRank<=r.rank;)c++;u=o[c]}t.setParent(n,u),n=t.successors(n)[0]}}))}},3573:(t,e,n)=>{"use strict";var r=n(8436),i=n(574).Graph,a=n(1138);function o(t,e){var n={};return r.reduce(e,(function(e,i){var a=0,o=0,s=e.length,u=r.last(i);return r.forEach(i,(function(e,l){var f=function(t,e){if(t.node(e).dummy)return r.find(t.predecessors(e),(function(e){return t.node(e).dummy}))}(t,e),h=f?t.node(f).order:s;(f||e===u)&&(r.forEach(i.slice(o,l+1),(function(e){r.forEach(t.predecessors(e),(function(r){var i=t.node(r),o=i.order;!(o<a||h<o)||i.dummy&&t.node(e).dummy||c(n,r,e)}))})),o=l+1,a=h)})),i})),n}function s(t,e){var n={};function i(e,i,a,o,s){var u;r.forEach(r.range(i,a),(function(i){u=e[i],t.node(u).dummy&&r.forEach(t.predecessors(u),(function(e){var r=t.node(e);r.dummy&&(r.order<o||r.order>s)&&c(n,e,u)}))}))}return r.reduce(e,(function(e,n){var a,o=-1,s=0;return r.forEach(n,(function(r,c){if("border"===t.node(r).dummy){var u=t.predecessors(r);u.length&&(a=t.node(u[0]).order,i(n,s,c,o,a),s=c,o=a)}i(n,s,n.length,a,e.length)})),n})),n}function c(t,e,n){if(e>n){var r=e;e=n,n=r}var i=t[e];i||(t[e]=i={}),i[n]=!0}function u(t,e,n){if(e>n){var i=e;e=n,n=i}return r.has(t[e],n)}function l(t,e,n,i){var a={},o={},s={};return r.forEach(e,(function(t){r.forEach(t,(function(t,e){a[t]=t,o[t]=t,s[t]=e}))})),r.forEach(e,(function(t){var e=-1;r.forEach(t,(function(t){var c=i(t);if(c.length){c=r.sortBy(c,(function(t){return s[t]}));for(var l=(c.length-1)/2,f=Math.floor(l),h=Math.ceil(l);f<=h;++f){var d=c[f];o[t]===t&&e<s[d]&&!u(n,t,d)&&(o[d]=t,o[t]=a[t]=a[d],e=s[d])}}}))})),{root:a,align:o}}function f(t,e,n,a,o){var s={},c=function(t,e,n,a){var o=new i,s=t.graph(),c=function(t,e,n){return function(i,a,o){var s,c=i.node(a),u=i.node(o),l=0;if(l+=c.width/2,r.has(c,"labelpos"))switch(c.labelpos.toLowerCase()){case"l":s=-c.width/2;break;case"r":s=c.width/2}if(s&&(l+=n?s:-s),s=0,l+=(c.dummy?e:t)/2,l+=(u.dummy?e:t)/2,l+=u.width/2,r.has(u,"labelpos"))switch(u.labelpos.toLowerCase()){case"l":s=u.width/2;break;case"r":s=-u.width/2}return s&&(l+=n?s:-s),s=0,l}}(s.nodesep,s.edgesep,a);return r.forEach(e,(function(e){var i;r.forEach(e,(function(e){var r=n[e];if(o.setNode(r),i){var a=n[i],s=o.edge(a,r);o.setEdge(a,r,Math.max(c(t,e,i),s||0))}i=e}))})),o}(t,e,n,o),u=o?"borderLeft":"borderRight";function l(t,e){for(var n=c.nodes(),r=n.pop(),i={};r;)i[r]?t(r):(i[r]=!0,n.push(r),n=n.concat(e(r))),r=n.pop()}return l((function(t){s[t]=c.inEdges(t).reduce((function(t,e){return Math.max(t,s[e.v]+c.edge(e))}),0)}),c.predecessors.bind(c)),l((function(e){var n=c.outEdges(e).reduce((function(t,e){return Math.min(t,s[e.w]-c.edge(e))}),Number.POSITIVE_INFINITY),r=t.node(e);n!==Number.POSITIVE_INFINITY&&r.borderType!==u&&(s[e]=Math.max(s[e],n))}),c.successors.bind(c)),r.forEach(a,(function(t){s[t]=s[n[t]]})),s}function h(t,e){return r.minBy(r.values(e),(function(e){var n=Number.NEGATIVE_INFINITY,i=Number.POSITIVE_INFINITY;return r.forIn(e,(function(e,r){var a=function(t,e){return t.node(e).width}(t,r)/2;n=Math.max(e+a,n),i=Math.min(e-a,i)})),n-i}))}function d(t,e){var n=r.values(e),i=r.min(n),a=r.max(n);r.forEach(["u","d"],(function(n){r.forEach(["l","r"],(function(o){var s,c=n+o,u=t[c];if(u!==e){var l=r.values(u);(s="l"===o?i-r.min(l):a-r.max(l))&&(t[c]=r.mapValues(u,(function(t){return t+s})))}}))}))}function p(t,e){return r.mapValues(t.ul,(function(n,i){if(e)return t[e.toLowerCase()][i];var a=r.sortBy(r.map(t,i));return(a[1]+a[2])/2}))}t.exports={positionX:function(t){var e,n=a.buildLayerMatrix(t),i=r.merge(o(t,n),s(t,n)),c={};r.forEach(["u","d"],(function(a){e="u"===a?n:r.values(n).reverse(),r.forEach(["l","r"],(function(n){"r"===n&&(e=r.map(e,(function(t){return r.values(t).reverse()})));var o=("u"===a?t.predecessors:t.successors).bind(t),s=l(0,e,i,o),u=f(t,e,s.root,s.align,"r"===n);"r"===n&&(u=r.mapValues(u,(function(t){return-t}))),c[a+n]=u}))}));var u=h(t,c);return d(c,u),p(c,t.graph().align)},findType1Conflicts:o,findType2Conflicts:s,addConflict:c,hasConflict:u,verticalAlignment:l,horizontalCompaction:f,alignCoordinates:d,findSmallestWidthAlignment:h,balance:p}},7873:(t,e,n)=>{"use strict";var r=n(8436),i=n(1138),a=n(3573).positionX;t.exports=function(t){(function(t){var e=i.buildLayerMatrix(t),n=t.graph().ranksep,a=0;r.forEach(e,(function(e){var i=r.max(r.map(e,(function(e){return t.node(e).height})));r.forEach(e,(function(e){t.node(e).y=a+i/2})),a+=i+n}))})(t=i.asNonCompoundGraph(t)),r.forEach(a(t),(function(e,n){t.node(n).x=e}))}},300:(t,e,n)=>{"use strict";var r=n(8436),i=n(574).Graph,a=n(6681).slack;function o(t,e){return r.forEach(t.nodes(),(function n(i){r.forEach(e.nodeEdges(i),(function(r){var o=r.v,s=i===o?r.w:o;t.hasNode(s)||a(e,r)||(t.setNode(s,{}),t.setEdge(i,s,{}),n(s))}))})),t.nodeCount()}function s(t,e){return r.minBy(e.edges(),(function(n){if(t.hasNode(n.v)!==t.hasNode(n.w))return a(e,n)}))}function c(t,e,n){r.forEach(t.nodes(),(function(t){e.node(t).rank+=n}))}t.exports=function(t){var e,n,r=new i({directed:!1}),u=t.nodes()[0],l=t.nodeCount();for(r.setNode(u,{});o(r,t)<l;)e=s(r,t),n=r.hasNode(e.v)?a(t,e):-a(t,e),c(r,t,n);return r}},8093:(t,e,n)=>{"use strict";var r=n(6681).longestPath,i=n(300),a=n(2472);t.exports=function(t){switch(t.graph().ranker){default:!function(t){a(t)}(t);break;case"tight-tree":!function(t){r(t),i(t)}(t);break;case"longest-path":o(t)}};var o=r},2472:(t,e,n)=>{"use strict";var r=n(8436),i=n(300),a=n(6681).slack,o=n(6681).longestPath,s=n(574).alg.preorder,c=n(574).alg.postorder,u=n(1138).simplify;function l(t){t=u(t),o(t);var e,n=i(t);for(d(n),f(n,t);e=g(n);)m(n,t,e,y(n,t,e))}function f(t,e){var n=c(t,t.nodes());n=n.slice(0,n.length-1),r.forEach(n,(function(n){!function(t,e,n){var r=t.node(n).parent;t.edge(n,r).cutvalue=h(t,e,n)}(t,e,n)}))}function h(t,e,n){var i=t.node(n).parent,a=!0,o=e.edge(n,i),s=0;return o||(a=!1,o=e.edge(i,n)),s=o.weight,r.forEach(e.nodeEdges(n),(function(r){var o,c,u=r.v===n,l=u?r.w:r.v;if(l!==i){var f=u===a,h=e.edge(r).weight;if(s+=f?h:-h,o=n,c=l,t.hasEdge(o,c)){var d=t.edge(n,l).cutvalue;s+=f?-d:d}}})),s}function d(t,e){arguments.length<2&&(e=t.nodes()[0]),p(t,{},1,e)}function p(t,e,n,i,a){var o=n,s=t.node(i);return e[i]=!0,r.forEach(t.neighbors(i),(function(a){r.has(e,a)||(n=p(t,e,n,a,i))})),s.low=o,s.lim=n++,a?s.parent=a:delete s.parent,n}function g(t){return r.find(t.edges(),(function(e){return t.edge(e).cutvalue<0}))}function y(t,e,n){var i=n.v,o=n.w;e.hasEdge(i,o)||(i=n.w,o=n.v);var s=t.node(i),c=t.node(o),u=s,l=!1;s.lim>c.lim&&(u=c,l=!0);var f=r.filter(e.edges(),(function(e){return l===v(0,t.node(e.v),u)&&l!==v(0,t.node(e.w),u)}));return r.minBy(f,(function(t){return a(e,t)}))}function m(t,e,n,i){var a=n.v,o=n.w;t.removeEdge(a,o),t.setEdge(i.v,i.w,{}),d(t),f(t,e),function(t,e){var n=r.find(t.nodes(),(function(t){return!e.node(t).parent})),i=s(t,n);i=i.slice(1),r.forEach(i,(function(n){var r=t.node(n).parent,i=e.edge(n,r),a=!1;i||(i=e.edge(r,n),a=!0),e.node(n).rank=e.node(r).rank+(a?i.minlen:-i.minlen)}))}(t,e)}function v(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}t.exports=l,l.initLowLimValues=d,l.initCutValues=f,l.calcCutValue=h,l.leaveEdge=g,l.enterEdge=y,l.exchangeEdges=m},6681:(t,e,n)=>{"use strict";var r=n(8436);t.exports={longestPath:function(t){var e={};r.forEach(t.sources(),(function n(i){var a=t.node(i);if(r.has(e,i))return a.rank;e[i]=!0;var o=r.min(r.map(t.outEdges(i),(function(e){return n(e.w)-t.edge(e).minlen})));return o!==Number.POSITIVE_INFINITY&&null!=o||(o=0),a.rank=o}))},slack:function(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}}},1138:(t,e,n)=>{"use strict";var r=n(8436),i=n(574).Graph;function a(t,e,n,i){var a;do{a=r.uniqueId(i)}while(t.hasNode(a));return n.dummy=e,t.setNode(a,n),a}function o(t){return r.max(r.map(t.nodes(),(function(e){var n=t.node(e).rank;if(!r.isUndefined(n))return n})))}t.exports={addDummyNode:a,simplify:function(t){var e=(new i).setGraph(t.graph());return r.forEach(t.nodes(),(function(n){e.setNode(n,t.node(n))})),r.forEach(t.edges(),(function(n){var r=e.edge(n.v,n.w)||{weight:0,minlen:1},i=t.edge(n);e.setEdge(n.v,n.w,{weight:r.weight+i.weight,minlen:Math.max(r.minlen,i.minlen)})})),e},asNonCompoundGraph:function(t){var e=new i({multigraph:t.isMultigraph()}).setGraph(t.graph());return r.forEach(t.nodes(),(function(n){t.children(n).length||e.setNode(n,t.node(n))})),r.forEach(t.edges(),(function(n){e.setEdge(n,t.edge(n))})),e},successorWeights:function(t){var e=r.map(t.nodes(),(function(e){var n={};return r.forEach(t.outEdges(e),(function(e){n[e.w]=(n[e.w]||0)+t.edge(e).weight})),n}));return r.zipObject(t.nodes(),e)},predecessorWeights:function(t){var e=r.map(t.nodes(),(function(e){var n={};return r.forEach(t.inEdges(e),(function(e){n[e.v]=(n[e.v]||0)+t.edge(e).weight})),n}));return r.zipObject(t.nodes(),e)},intersectRect:function(t,e){var n,r,i=t.x,a=t.y,o=e.x-i,s=e.y-a,c=t.width/2,u=t.height/2;if(!o&&!s)throw new Error("Not possible to find intersection inside of the rectangle");return Math.abs(s)*c>Math.abs(o)*u?(s<0&&(u=-u),n=u*o/s,r=u):(o<0&&(c=-c),n=c,r=c*s/o),{x:i+n,y:a+r}},buildLayerMatrix:function(t){var e=r.map(r.range(o(t)+1),(function(){return[]}));return r.forEach(t.nodes(),(function(n){var i=t.node(n),a=i.rank;r.isUndefined(a)||(e[a][i.order]=n)})),e},normalizeRanks:function(t){var e=r.min(r.map(t.nodes(),(function(e){return t.node(e).rank})));r.forEach(t.nodes(),(function(n){var i=t.node(n);r.has(i,"rank")&&(i.rank-=e)}))},removeEmptyRanks:function(t){var e=r.min(r.map(t.nodes(),(function(e){return t.node(e).rank}))),n=[];r.forEach(t.nodes(),(function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)}));var i=0,a=t.graph().nodeRankFactor;r.forEach(n,(function(e,n){r.isUndefined(e)&&n%a!=0?--i:i&&r.forEach(e,(function(e){t.node(e).rank+=i}))}))},addBorderNode:function(t,e,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),a(t,"border",i,e)},maxRank:o,partition:function(t,e){var n={lhs:[],rhs:[]};return r.forEach(t,(function(t){e(t)?n.lhs.push(t):n.rhs.push(t)})),n},time:function(t,e){var n=r.now();try{return e()}finally{console.log(t+" time: "+(r.now()-n)+"ms")}},notime:function(t,e){return e()}}},8177:t=>{t.exports="0.8.5"},1646:function(t,e,n){var r,i,a;i=[t,e,n(3921)],r=function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(e,"__esModule",{value:!0});var i=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=function t(e,a){if(e===a||!(0,n.isObject)(e)||!(0,n.isObject)(a))return{};var o=(0,n.properObject)(e),s=(0,n.properObject)(a);return Object.keys(s).reduce((function(e,a){if(o.hasOwnProperty(a)){var c=t(o[a],s[a]);return(0,n.isObject)(c)&&(0,n.isEmpty)(c)?e:i({},e,r({},a,c))}return i({},e,r({},a,s[a]))}),{})},t.exports=e.default},void 0===(a=r.apply(e,i))||(t.exports=a)},1511:function(t,e,n){var r,i,a;i=[t,e,n(3921)],r=function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(e,"__esModule",{value:!0});var i=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=function t(e,a){if(e===a||!(0,n.isObject)(e)||!(0,n.isObject)(a))return{};var o=(0,n.properObject)(e),s=(0,n.properObject)(a);return Object.keys(o).reduce((function(e,a){if(s.hasOwnProperty(a)){var c=t(o[a],s[a]);return(0,n.isObject)(c)&&(0,n.isEmpty)(c)?e:i({},e,r({},a,c))}return i({},e,r({},a,void 0))}),{})},t.exports=e.default},void 0===(a=r.apply(e,i))||(t.exports=a)},397:function(t,e,n){var r,i,a;i=[t,e,n(1646),n(1511),n(858)],r=function(t,e,n,r,i){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var a=c(n),o=c(r),s=c(i);function c(t){return t&&t.__esModule?t:{default:t}}e.default=function(t,e){return{added:(0,a.default)(t,e),deleted:(0,o.default)(t,e),updated:(0,s.default)(t,e)}},t.exports=e.default},void 0===(a=r.apply(e,i))||(t.exports=a)},7839:function(t,e,n){var r,i,a;i=[t,e,n(3921)],r=function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}Object.defineProperty(e,"__esModule",{value:!0});var i=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=function t(e,a){if(e===a)return{};if(!(0,n.isObject)(e)||!(0,n.isObject)(a))return a;var o=(0,n.properObject)(e),s=(0,n.properObject)(a),c=Object.keys(o).reduce((function(t,e){return s.hasOwnProperty(e)?t:i({},t,r({},e,void 0))}),{});return(0,n.isDate)(o)||(0,n.isDate)(s)?o.valueOf()==s.valueOf()?{}:s:Object.keys(s).reduce((function(e,a){if(!o.hasOwnProperty(a))return i({},e,r({},a,s[a]));var c=t(o[a],s[a]);return(0,n.isObject)(c)&&(0,n.isEmpty)(c)&&!(0,n.isDate)(c)?e:i({},e,r({},a,c))}),c)},t.exports=e.default},void 0===(a=r.apply(e,i))||(t.exports=a)},190:function(t,e,n){var r,i,a;i=[e,n(7839),n(1646),n(1511),n(858),n(397)],r=function(t,e,n,r,i,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.detailedDiff=t.updatedDiff=t.deletedDiff=t.diff=t.addedDiff=void 0;var o=f(e),s=f(n),c=f(r),u=f(i),l=f(a);function f(t){return t&&t.__esModule?t:{default:t}}t.addedDiff=s.default,t.diff=o.default,t.deletedDiff=c.default,t.updatedDiff=u.default,t.detailedDiff=l.default},void 0===(a=r.apply(e,i))||(t.exports=a)},858:function(t,e,n){var r,i,a;i=[t,e,n(3921)],r=function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t};e.default=function t(e,i){if(e===i)return{};if(!(0,n.isObject)(e)||!(0,n.isObject)(i))return i;var a=(0,n.properObject)(e),o=(0,n.properObject)(i);return(0,n.isDate)(a)||(0,n.isDate)(o)?a.valueOf()==o.valueOf()?{}:o:Object.keys(o).reduce((function(e,i){if(a.hasOwnProperty(i)){var s=t(a[i],o[i]);return(0,n.isObject)(s)&&(0,n.isEmpty)(s)&&!(0,n.isDate)(s)?e:r({},e,function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}({},i,s))}return e}),{})},t.exports=e.default},void 0===(a=r.apply(e,i))||(t.exports=a)},3921:function(t,e){var n,r;n=function(t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var e=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r=(t.isDate=function(t){return t instanceof Date},t.isEmpty=function(t){return 0===Object.keys(t).length},t.isObject=function(t){return null!=t&&"object"===(void 0===t?"undefined":n(t))});t.properObject=function(t){return r(t)&&!t.hasOwnProperty?e({},t):t}},void 0===(r=n.apply(e,[e]))||(t.exports=r)},9996:t=>{"use strict";var e=function(t){return function(t){return!!t&&"object"==typeof t}(t)&&!function(t){var e=Object.prototype.toString.call(t);return"[object RegExp]"===e||"[object Date]"===e||function(t){return t.$$typeof===n}(t)}(t)},n="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(t,e){return!1!==e.clone&&e.isMergeableObject(t)?s((n=t,Array.isArray(n)?[]:{}),t,e):t;var n}function i(t,e,n){return t.concat(e).map((function(t){return r(t,n)}))}function a(t){return Object.keys(t).concat(function(t){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(t).filter((function(e){return t.propertyIsEnumerable(e)})):[]}(t))}function o(t,e){try{return e in t}catch(t){return!1}}function s(t,n,c){(c=c||{}).arrayMerge=c.arrayMerge||i,c.isMergeableObject=c.isMergeableObject||e,c.cloneUnlessOtherwiseSpecified=r;var u=Array.isArray(n);return u===Array.isArray(t)?u?c.arrayMerge(t,n,c):function(t,e,n){var i={};return n.isMergeableObject(t)&&a(t).forEach((function(e){i[e]=r(t[e],n)})),a(e).forEach((function(a){(function(t,e){return o(t,e)&&!(Object.hasOwnProperty.call(t,e)&&Object.propertyIsEnumerable.call(t,e))})(t,a)||(o(t,a)&&n.isMergeableObject(e[a])?i[a]=function(t,e){if(!e.customMerge)return s;var n=e.customMerge(t);return"function"==typeof n?n:s}(a,n)(t[a],e[a],n):i[a]=r(e[a],n))})),i}(t,n,c):r(n,c)}s.all=function(t,e){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce((function(t,n){return s(t,n,e)}),{})};var c=s;t.exports=c},7856:function(t){t.exports=function(){"use strict";var t=Object.hasOwnProperty,e=Object.setPrototypeOf,n=Object.isFrozen,r=Object.getPrototypeOf,i=Object.getOwnPropertyDescriptor,a=Object.freeze,o=Object.seal,s=Object.create,c="undefined"!=typeof Reflect&&Reflect,u=c.apply,l=c.construct;u||(u=function(t,e,n){return t.apply(e,n)}),a||(a=function(t){return t}),o||(o=function(t){return t}),l||(l=function(t,e){return new(Function.prototype.bind.apply(t,[null].concat(function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}(e))))});var f,h=w(Array.prototype.forEach),d=w(Array.prototype.pop),p=w(Array.prototype.push),g=w(String.prototype.toLowerCase),y=w(String.prototype.match),m=w(String.prototype.replace),v=w(String.prototype.indexOf),b=w(String.prototype.trim),_=w(RegExp.prototype.test),x=(f=TypeError,function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return l(f,e)});function w(t){return function(e){for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];return u(t,e,r)}}function k(t,r){e&&e(t,null);for(var i=r.length;i--;){var a=r[i];if("string"==typeof a){var o=g(a);o!==a&&(n(r)||(r[i]=o),a=o)}t[a]=!0}return t}function T(e){var n=s(null),r=void 0;for(r in e)u(t,e,[r])&&(n[r]=e[r]);return n}function E(t,e){for(;null!==t;){var n=i(t,e);if(n){if(n.get)return w(n.get);if("function"==typeof n.value)return w(n.value)}t=r(t)}return function(t){return console.warn("fallback value for",t),null}}var C=a(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),S=a(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),M=a(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),A=a(["animate","color-profile","cursor","discard","fedropshadow","feimage","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),O=a(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover"]),N=a(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),j=a(["#text"]),D=a(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),B=a(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),L=a(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),I=a(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),R=o(/\{\{[\s\S]*|[\s\S]*\}\}/gm),P=o(/<%[\s\S]*|[\s\S]*%>/gm),F=o(/^data-[\-\w.\u00B7-\uFFFF]/),z=o(/^aria-[\-\w]+$/),Y=o(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),q=o(/^(?:\w+script|data):/i),U=o(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),V="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function W(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}var H=function(){return"undefined"==typeof window?null:window},$=function(t,e){if("object"!==(void 0===t?"undefined":V(t))||"function"!=typeof t.createPolicy)return null;var n=null,r="data-tt-policy-suffix";e.currentScript&&e.currentScript.hasAttribute(r)&&(n=e.currentScript.getAttribute(r));var i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML:function(t){return t}})}catch(t){return console.warn("TrustedTypes policy "+i+" could not be created."),null}};return function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:H(),n=function(e){return t(e)};if(n.version="2.3.1",n.removed=[],!e||!e.document||9!==e.document.nodeType)return n.isSupported=!1,n;var r=e.document,i=e.document,o=e.DocumentFragment,s=e.HTMLTemplateElement,c=e.Node,u=e.Element,l=e.NodeFilter,f=e.NamedNodeMap,w=void 0===f?e.NamedNodeMap||e.MozNamedAttrMap:f,G=e.Text,X=e.Comment,Z=e.DOMParser,K=e.trustedTypes,Q=u.prototype,J=E(Q,"cloneNode"),tt=E(Q,"nextSibling"),et=E(Q,"childNodes"),nt=E(Q,"parentNode");if("function"==typeof s){var rt=i.createElement("template");rt.content&&rt.content.ownerDocument&&(i=rt.content.ownerDocument)}var it=$(K,r),at=it&&Rt?it.createHTML(""):"",ot=i,st=ot.implementation,ct=ot.createNodeIterator,ut=ot.createDocumentFragment,lt=ot.getElementsByTagName,ft=r.importNode,ht={};try{ht=T(i).documentMode?i.documentMode:{}}catch(t){}var dt={};n.isSupported="function"==typeof nt&&st&&void 0!==st.createHTMLDocument&&9!==ht;var pt=R,gt=P,yt=F,mt=z,vt=q,bt=U,_t=Y,xt=null,wt=k({},[].concat(W(C),W(S),W(M),W(O),W(j))),kt=null,Tt=k({},[].concat(W(D),W(B),W(L),W(I))),Et=null,Ct=null,St=!0,Mt=!0,At=!1,Ot=!1,Nt=!1,jt=!1,Dt=!1,Bt=!1,Lt=!1,It=!0,Rt=!1,Pt=!0,Ft=!0,zt=!1,Yt={},qt=null,Ut=k({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),Vt=null,Wt=k({},["audio","video","img","source","image","track"]),Ht=null,$t=k({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Gt="http://www.w3.org/1998/Math/MathML",Xt="http://www.w3.org/2000/svg",Zt="http://www.w3.org/1999/xhtml",Kt=Zt,Qt=!1,Jt=null,te=i.createElement("form"),ee=function(t){Jt&&Jt===t||(t&&"object"===(void 0===t?"undefined":V(t))||(t={}),t=T(t),xt="ALLOWED_TAGS"in t?k({},t.ALLOWED_TAGS):wt,kt="ALLOWED_ATTR"in t?k({},t.ALLOWED_ATTR):Tt,Ht="ADD_URI_SAFE_ATTR"in t?k(T($t),t.ADD_URI_SAFE_ATTR):$t,Vt="ADD_DATA_URI_TAGS"in t?k(T(Wt),t.ADD_DATA_URI_TAGS):Wt,qt="FORBID_CONTENTS"in t?k({},t.FORBID_CONTENTS):Ut,Et="FORBID_TAGS"in t?k({},t.FORBID_TAGS):{},Ct="FORBID_ATTR"in t?k({},t.FORBID_ATTR):{},Yt="USE_PROFILES"in t&&t.USE_PROFILES,St=!1!==t.ALLOW_ARIA_ATTR,Mt=!1!==t.ALLOW_DATA_ATTR,At=t.ALLOW_UNKNOWN_PROTOCOLS||!1,Ot=t.SAFE_FOR_TEMPLATES||!1,Nt=t.WHOLE_DOCUMENT||!1,Bt=t.RETURN_DOM||!1,Lt=t.RETURN_DOM_FRAGMENT||!1,It=!1!==t.RETURN_DOM_IMPORT,Rt=t.RETURN_TRUSTED_TYPE||!1,Dt=t.FORCE_BODY||!1,Pt=!1!==t.SANITIZE_DOM,Ft=!1!==t.KEEP_CONTENT,zt=t.IN_PLACE||!1,_t=t.ALLOWED_URI_REGEXP||_t,Kt=t.NAMESPACE||Zt,Ot&&(Mt=!1),Lt&&(Bt=!0),Yt&&(xt=k({},[].concat(W(j))),kt=[],!0===Yt.html&&(k(xt,C),k(kt,D)),!0===Yt.svg&&(k(xt,S),k(kt,B),k(kt,I)),!0===Yt.svgFilters&&(k(xt,M),k(kt,B),k(kt,I)),!0===Yt.mathMl&&(k(xt,O),k(kt,L),k(kt,I))),t.ADD_TAGS&&(xt===wt&&(xt=T(xt)),k(xt,t.ADD_TAGS)),t.ADD_ATTR&&(kt===Tt&&(kt=T(kt)),k(kt,t.ADD_ATTR)),t.ADD_URI_SAFE_ATTR&&k(Ht,t.ADD_URI_SAFE_ATTR),t.FORBID_CONTENTS&&(qt===Ut&&(qt=T(qt)),k(qt,t.FORBID_CONTENTS)),Ft&&(xt["#text"]=!0),Nt&&k(xt,["html","head","body"]),xt.table&&(k(xt,["tbody"]),delete Et.tbody),a&&a(t),Jt=t)},ne=k({},["mi","mo","mn","ms","mtext"]),re=k({},["foreignobject","desc","title","annotation-xml"]),ie=k({},S);k(ie,M),k(ie,A);var ae=k({},O);k(ae,N);var oe=function(t){var e=nt(t);e&&e.tagName||(e={namespaceURI:Zt,tagName:"template"});var n=g(t.tagName),r=g(e.tagName);if(t.namespaceURI===Xt)return e.namespaceURI===Zt?"svg"===n:e.namespaceURI===Gt?"svg"===n&&("annotation-xml"===r||ne[r]):Boolean(ie[n]);if(t.namespaceURI===Gt)return e.namespaceURI===Zt?"math"===n:e.namespaceURI===Xt?"math"===n&&re[r]:Boolean(ae[n]);if(t.namespaceURI===Zt){if(e.namespaceURI===Xt&&!re[r])return!1;if(e.namespaceURI===Gt&&!ne[r])return!1;var i=k({},["title","style","font","a","script"]);return!ae[n]&&(i[n]||!ie[n])}return!1},se=function(t){p(n.removed,{element:t});try{t.parentNode.removeChild(t)}catch(e){try{t.outerHTML=at}catch(e){t.remove()}}},ce=function(t,e){try{p(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(t){p(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t&&!kt[t])if(Bt||Lt)try{se(e)}catch(t){}else try{e.setAttribute(t,"")}catch(t){}},ue=function(t){var e=void 0,n=void 0;if(Dt)t="<remove></remove>"+t;else{var r=y(t,/^[\r\n\t ]+/);n=r&&r[0]}var a=it?it.createHTML(t):t;if(Kt===Zt)try{e=(new Z).parseFromString(a,"text/html")}catch(t){}if(!e||!e.documentElement){e=st.createDocument(Kt,"template",null);try{e.documentElement.innerHTML=Qt?"":a}catch(t){}}var o=e.body||e.documentElement;return t&&n&&o.insertBefore(i.createTextNode(n),o.childNodes[0]||null),Kt===Zt?lt.call(e,Nt?"html":"body")[0]:Nt?e.documentElement:o},le=function(t){return ct.call(t.ownerDocument||t,t,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT,null,!1)},fe=function(t){return!(t instanceof G||t instanceof X||"string"==typeof t.nodeName&&"string"==typeof t.textContent&&"function"==typeof t.removeChild&&t.attributes instanceof w&&"function"==typeof t.removeAttribute&&"function"==typeof t.setAttribute&&"string"==typeof t.namespaceURI&&"function"==typeof t.insertBefore)},he=function(t){return"object"===(void 0===c?"undefined":V(c))?t instanceof c:t&&"object"===(void 0===t?"undefined":V(t))&&"number"==typeof t.nodeType&&"string"==typeof t.nodeName},de=function(t,e,r){dt[t]&&h(dt[t],(function(t){t.call(n,e,r,Jt)}))},pe=function(t){var e=void 0;if(de("beforeSanitizeElements",t,null),fe(t))return se(t),!0;if(y(t.nodeName,/[\u0080-\uFFFF]/))return se(t),!0;var r=g(t.nodeName);if(de("uponSanitizeElement",t,{tagName:r,allowedTags:xt}),!he(t.firstElementChild)&&(!he(t.content)||!he(t.content.firstElementChild))&&_(/<[/\w]/g,t.innerHTML)&&_(/<[/\w]/g,t.textContent))return se(t),!0;if("select"===r&&_(/<template/i,t.innerHTML))return se(t),!0;if(!xt[r]||Et[r]){if(Ft&&!qt[r]){var i=nt(t)||t.parentNode,a=et(t)||t.childNodes;if(a&&i)for(var o=a.length-1;o>=0;--o)i.insertBefore(J(a[o],!0),tt(t))}return se(t),!0}return t instanceof u&&!oe(t)?(se(t),!0):"noscript"!==r&&"noembed"!==r||!_(/<\/no(script|embed)/i,t.innerHTML)?(Ot&&3===t.nodeType&&(e=t.textContent,e=m(e,pt," "),e=m(e,gt," "),t.textContent!==e&&(p(n.removed,{element:t.cloneNode()}),t.textContent=e)),de("afterSanitizeElements",t,null),!1):(se(t),!0)},ge=function(t,e,n){if(Pt&&("id"===e||"name"===e)&&(n in i||n in te))return!1;if(Mt&&!Ct[e]&&_(yt,e));else if(St&&_(mt,e));else{if(!kt[e]||Ct[e])return!1;if(Ht[e]);else if(_(_t,m(n,bt,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==v(n,"data:")||!Vt[t])if(At&&!_(vt,m(n,bt,"")));else if(n)return!1}return!0},ye=function(t){var e=void 0,r=void 0,i=void 0,a=void 0;de("beforeSanitizeAttributes",t,null);var o=t.attributes;if(o){var s={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:kt};for(a=o.length;a--;){var c=e=o[a],u=c.name,l=c.namespaceURI;if(r=b(e.value),i=g(u),s.attrName=i,s.attrValue=r,s.keepAttr=!0,s.forceKeepAttr=void 0,de("uponSanitizeAttribute",t,s),r=s.attrValue,!s.forceKeepAttr&&(ce(u,t),s.keepAttr))if(_(/\/>/i,r))ce(u,t);else{Ot&&(r=m(r,pt," "),r=m(r,gt," "));var f=t.nodeName.toLowerCase();if(ge(f,i,r))try{l?t.setAttributeNS(l,u,r):t.setAttribute(u,r),d(n.removed)}catch(t){}}}de("afterSanitizeAttributes",t,null)}},me=function t(e){var n=void 0,r=le(e);for(de("beforeSanitizeShadowDOM",e,null);n=r.nextNode();)de("uponSanitizeShadowNode",n,null),pe(n)||(n.content instanceof o&&t(n.content),ye(n));de("afterSanitizeShadowDOM",e,null)};return n.sanitize=function(t,i){var a=void 0,s=void 0,u=void 0,l=void 0,f=void 0;if((Qt=!t)&&(t="\x3c!--\x3e"),"string"!=typeof t&&!he(t)){if("function"!=typeof t.toString)throw x("toString is not a function");if("string"!=typeof(t=t.toString()))throw x("dirty is not a string, aborting")}if(!n.isSupported){if("object"===V(e.toStaticHTML)||"function"==typeof e.toStaticHTML){if("string"==typeof t)return e.toStaticHTML(t);if(he(t))return e.toStaticHTML(t.outerHTML)}return t}if(jt||ee(i),n.removed=[],"string"==typeof t&&(zt=!1),zt);else if(t instanceof c)1===(s=(a=ue("\x3c!----\x3e")).ownerDocument.importNode(t,!0)).nodeType&&"BODY"===s.nodeName||"HTML"===s.nodeName?a=s:a.appendChild(s);else{if(!Bt&&!Ot&&!Nt&&-1===t.indexOf("<"))return it&&Rt?it.createHTML(t):t;if(!(a=ue(t)))return Bt?null:at}a&&Dt&&se(a.firstChild);for(var h=le(zt?t:a);u=h.nextNode();)3===u.nodeType&&u===l||pe(u)||(u.content instanceof o&&me(u.content),ye(u),l=u);if(l=null,zt)return t;if(Bt){if(Lt)for(f=ut.call(a.ownerDocument);a.firstChild;)f.appendChild(a.firstChild);else f=a;return It&&(f=ft.call(r,f,!0)),f}var d=Nt?a.outerHTML:a.innerHTML;return Ot&&(d=m(d,pt," "),d=m(d,gt," ")),it&&Rt?it.createHTML(d):d},n.setConfig=function(t){ee(t),jt=!0},n.clearConfig=function(){Jt=null,jt=!1},n.isValidAttribute=function(t,e,n){Jt||ee({});var r=g(t),i=g(e);return ge(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&(dt[t]=dt[t]||[],p(dt[t],e))},n.removeHook=function(t){dt[t]&&d(dt[t])},n.removeHooks=function(t){dt[t]&&(dt[t]=[])},n.removeAllHooks=function(){dt={}},n}()}()},8282:(t,e,n)=>{var r=n(2354);t.exports={Graph:r.Graph,json:n(8974),alg:n(2440),version:r.version}},2842:(t,e,n)=>{var r=n(9126);t.exports=function(t){var e,n={},i=[];function a(i){r.has(n,i)||(n[i]=!0,e.push(i),r.each(t.successors(i),a),r.each(t.predecessors(i),a))}return r.each(t.nodes(),(function(t){e=[],a(t),e.length&&i.push(e)})),i}},3984:(t,e,n)=>{var r=n(9126);function i(t,e,n,a,o,s){r.has(a,e)||(a[e]=!0,n||s.push(e),r.each(o(e),(function(e){i(t,e,n,a,o,s)})),n&&s.push(e))}t.exports=function(t,e,n){r.isArray(e)||(e=[e]);var a=(t.isDirected()?t.successors:t.neighbors).bind(t),o=[],s={};return r.each(e,(function(e){if(!t.hasNode(e))throw new Error("Graph does not have node: "+e);i(t,e,"post"===n,s,a,o)})),o}},4847:(t,e,n)=>{var r=n(3763),i=n(9126);t.exports=function(t,e,n){return i.transform(t.nodes(),(function(i,a){i[a]=r(t,a,e,n)}),{})}},3763:(t,e,n)=>{var r=n(9126),i=n(9675);t.exports=function(t,e,n,r){return function(t,e,n,r){var a,o,s={},c=new i,u=function(t){var e=t.v!==a?t.v:t.w,r=s[e],i=n(t),u=o.distance+i;if(i<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+t+" Weight: "+i);u<r.distance&&(r.distance=u,r.predecessor=a,c.decrease(e,u))};for(t.nodes().forEach((function(t){var n=t===e?0:Number.POSITIVE_INFINITY;s[t]={distance:n},c.add(t,n)}));c.size()>0&&(a=c.removeMin(),(o=s[a]).distance!==Number.POSITIVE_INFINITY);)r(a).forEach(u);return s}(t,String(e),n||a,r||function(e){return t.outEdges(e)})};var a=r.constant(1)},9096:(t,e,n)=>{var r=n(9126),i=n(5023);t.exports=function(t){return r.filter(i(t),(function(e){return e.length>1||1===e.length&&t.hasEdge(e[0],e[0])}))}},8924:(t,e,n)=>{var r=n(9126);t.exports=function(t,e,n){return function(t,e,n){var r={},i=t.nodes();return i.forEach((function(t){r[t]={},r[t][t]={distance:0},i.forEach((function(e){t!==e&&(r[t][e]={distance:Number.POSITIVE_INFINITY})})),n(t).forEach((function(n){var i=n.v===t?n.w:n.v,a=e(n);r[t][i]={distance:a,predecessor:t}}))})),i.forEach((function(t){var e=r[t];i.forEach((function(n){var a=r[n];i.forEach((function(n){var r=a[t],i=e[n],o=a[n],s=r.distance+i.distance;s<o.distance&&(o.distance=s,o.predecessor=i.predecessor)}))}))})),r}(t,e||i,n||function(e){return t.outEdges(e)})};var i=r.constant(1)},2440:(t,e,n)=>{t.exports={components:n(2842),dijkstra:n(3763),dijkstraAll:n(4847),findCycles:n(9096),floydWarshall:n(8924),isAcyclic:n(2707),postorder:n(8828),preorder:n(2648),prim:n(514),tarjan:n(5023),topsort:n(2166)}},2707:(t,e,n)=>{var r=n(2166);t.exports=function(t){try{r(t)}catch(t){if(t instanceof r.CycleException)return!1;throw t}return!0}},8828:(t,e,n)=>{var r=n(3984);t.exports=function(t,e){return r(t,e,"post")}},2648:(t,e,n)=>{var r=n(3984);t.exports=function(t,e){return r(t,e,"pre")}},514:(t,e,n)=>{var r=n(9126),i=n(771),a=n(9675);t.exports=function(t,e){var n,o=new i,s={},c=new a;function u(t){var r=t.v===n?t.w:t.v,i=c.priority(r);if(void 0!==i){var a=e(t);a<i&&(s[r]=n,c.decrease(r,a))}}if(0===t.nodeCount())return o;r.each(t.nodes(),(function(t){c.add(t,Number.POSITIVE_INFINITY),o.setNode(t)})),c.decrease(t.nodes()[0],0);for(var l=!1;c.size()>0;){if(n=c.removeMin(),r.has(s,n))o.setEdge(n,s[n]);else{if(l)throw new Error("Input graph is not connected: "+t);l=!0}t.nodeEdges(n).forEach(u)}return o}},5023:(t,e,n)=>{var r=n(9126);t.exports=function(t){var e=0,n=[],i={},a=[];function o(s){var c=i[s]={onStack:!0,lowlink:e,index:e++};if(n.push(s),t.successors(s).forEach((function(t){r.has(i,t)?i[t].onStack&&(c.lowlink=Math.min(c.lowlink,i[t].index)):(o(t),c.lowlink=Math.min(c.lowlink,i[t].lowlink))})),c.lowlink===c.index){var u,l=[];do{u=n.pop(),i[u].onStack=!1,l.push(u)}while(s!==u);a.push(l)}}return t.nodes().forEach((function(t){r.has(i,t)||o(t)})),a}},2166:(t,e,n)=>{var r=n(9126);function i(t){var e={},n={},i=[];if(r.each(t.sinks(),(function o(s){if(r.has(n,s))throw new a;r.has(e,s)||(n[s]=!0,e[s]=!0,r.each(t.predecessors(s),o),delete n[s],i.push(s))})),r.size(e)!==t.nodeCount())throw new a;return i}function a(){}t.exports=i,i.CycleException=a,a.prototype=new Error},9675:(t,e,n)=>{var r=n(9126);function i(){this._arr=[],this._keyIndices={}}t.exports=i,i.prototype.size=function(){return this._arr.length},i.prototype.keys=function(){return this._arr.map((function(t){return t.key}))},i.prototype.has=function(t){return r.has(this._keyIndices,t)},i.prototype.priority=function(t){var e=this._keyIndices[t];if(void 0!==e)return this._arr[e].priority},i.prototype.min=function(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key},i.prototype.add=function(t,e){var n=this._keyIndices;if(t=String(t),!r.has(n,t)){var i=this._arr,a=i.length;return n[t]=a,i.push({key:t,priority:e}),this._decrease(a),!0}return!1},i.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var t=this._arr.pop();return delete this._keyIndices[t.key],this._heapify(0),t.key},i.prototype.decrease=function(t,e){var n=this._keyIndices[t];if(e>this._arr[n].priority)throw new Error("New priority is greater than current priority. Key: "+t+" Old: "+this._arr[n].priority+" New: "+e);this._arr[n].priority=e,this._decrease(n)},i.prototype._heapify=function(t){var e=this._arr,n=2*t,r=n+1,i=t;n<e.length&&(i=e[n].priority<e[i].priority?n:i,r<e.length&&(i=e[r].priority<e[i].priority?r:i),i!==t&&(this._swap(t,i),this._heapify(i)))},i.prototype._decrease=function(t){for(var e,n=this._arr,r=n[t].priority;0!==t&&!(n[e=t>>1].priority<r);)this._swap(t,e),t=e},i.prototype._swap=function(t,e){var n=this._arr,r=this._keyIndices,i=n[t],a=n[e];n[t]=a,n[e]=i,r[a.key]=t,r[i.key]=e}},771:(t,e,n)=>{"use strict";var r=n(9126);t.exports=a;var i="\0";function a(t){this._isDirected=!r.has(t,"directed")||t.directed,this._isMultigraph=!!r.has(t,"multigraph")&&t.multigraph,this._isCompound=!!r.has(t,"compound")&&t.compound,this._label=void 0,this._defaultNodeLabelFn=r.constant(void 0),this._defaultEdgeLabelFn=r.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children["\0"]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}function o(t,e){t[e]?t[e]++:t[e]=1}function s(t,e){--t[e]||delete t[e]}function c(t,e,n,i){var a=""+e,o=""+n;if(!t&&a>o){var s=a;a=o,o=s}return a+""+o+""+(r.isUndefined(i)?"\0":i)}function u(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var o=i;i=a,a=o}var s={v:i,w:a};return r&&(s.name=r),s}function l(t,e){return c(t,e.v,e.w,e.name)}a.prototype._nodeCount=0,a.prototype._edgeCount=0,a.prototype.isDirected=function(){return this._isDirected},a.prototype.isMultigraph=function(){return this._isMultigraph},a.prototype.isCompound=function(){return this._isCompound},a.prototype.setGraph=function(t){return this._label=t,this},a.prototype.graph=function(){return this._label},a.prototype.setDefaultNodeLabel=function(t){return r.isFunction(t)||(t=r.constant(t)),this._defaultNodeLabelFn=t,this},a.prototype.nodeCount=function(){return this._nodeCount},a.prototype.nodes=function(){return r.keys(this._nodes)},a.prototype.sources=function(){var t=this;return r.filter(this.nodes(),(function(e){return r.isEmpty(t._in[e])}))},a.prototype.sinks=function(){var t=this;return r.filter(this.nodes(),(function(e){return r.isEmpty(t._out[e])}))},a.prototype.setNodes=function(t,e){var n=arguments,i=this;return r.each(t,(function(t){n.length>1?i.setNode(t,e):i.setNode(t)})),this},a.prototype.setNode=function(t,e){return r.has(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=e),this):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]=i,this._children[t]={},this._children["\0"][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)},a.prototype.node=function(t){return this._nodes[t]},a.prototype.hasNode=function(t){return r.has(this._nodes,t)},a.prototype.removeNode=function(t){var e=this;if(r.has(this._nodes,t)){var n=function(t){e.removeEdge(e._edgeObjs[t])};delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],r.each(this.children(t),(function(t){e.setParent(t)})),delete this._children[t]),r.each(r.keys(this._in[t]),n),delete this._in[t],delete this._preds[t],r.each(r.keys(this._out[t]),n),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this},a.prototype.setParent=function(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(r.isUndefined(e))e=i;else{for(var n=e+="";!r.isUndefined(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this},a.prototype._removeFromParentsChildList=function(t){delete this._children[this._parent[t]][t]},a.prototype.parent=function(t){if(this._isCompound){var e=this._parent[t];if(e!==i)return e}},a.prototype.children=function(t){if(r.isUndefined(t)&&(t=i),this._isCompound){var e=this._children[t];if(e)return r.keys(e)}else{if(t===i)return this.nodes();if(this.hasNode(t))return[]}},a.prototype.predecessors=function(t){var e=this._preds[t];if(e)return r.keys(e)},a.prototype.successors=function(t){var e=this._sucs[t];if(e)return r.keys(e)},a.prototype.neighbors=function(t){var e=this.predecessors(t);if(e)return r.union(e,this.successors(t))},a.prototype.isLeaf=function(t){return 0===(this.isDirected()?this.successors(t):this.neighbors(t)).length},a.prototype.filterNodes=function(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var n=this;r.each(this._nodes,(function(n,r){t(r)&&e.setNode(r,n)})),r.each(this._edgeObjs,(function(t){e.hasNode(t.v)&&e.hasNode(t.w)&&e.setEdge(t,n.edge(t))}));var i={};function a(t){var r=n.parent(t);return void 0===r||e.hasNode(r)?(i[t]=r,r):r in i?i[r]:a(r)}return this._isCompound&&r.each(e.nodes(),(function(t){e.setParent(t,a(t))})),e},a.prototype.setDefaultEdgeLabel=function(t){return r.isFunction(t)||(t=r.constant(t)),this._defaultEdgeLabelFn=t,this},a.prototype.edgeCount=function(){return this._edgeCount},a.prototype.edges=function(){return r.values(this._edgeObjs)},a.prototype.setPath=function(t,e){var n=this,i=arguments;return r.reduce(t,(function(t,r){return i.length>1?n.setEdge(t,r,e):n.setEdge(t,r),r})),this},a.prototype.setEdge=function(){var t,e,n,i,a=!1,s=arguments[0];"object"==typeof s&&null!==s&&"v"in s?(t=s.v,e=s.w,n=s.name,2===arguments.length&&(i=arguments[1],a=!0)):(t=s,e=arguments[1],n=arguments[3],arguments.length>2&&(i=arguments[2],a=!0)),t=""+t,e=""+e,r.isUndefined(n)||(n=""+n);var l=c(this._isDirected,t,e,n);if(r.has(this._edgeLabels,l))return a&&(this._edgeLabels[l]=i),this;if(!r.isUndefined(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[l]=a?i:this._defaultEdgeLabelFn(t,e,n);var f=u(this._isDirected,t,e,n);return t=f.v,e=f.w,Object.freeze(f),this._edgeObjs[l]=f,o(this._preds[e],t),o(this._sucs[t],e),this._in[e][l]=f,this._out[t][l]=f,this._edgeCount++,this},a.prototype.edge=function(t,e,n){var r=1===arguments.length?l(this._isDirected,arguments[0]):c(this._isDirected,t,e,n);return this._edgeLabels[r]},a.prototype.hasEdge=function(t,e,n){var i=1===arguments.length?l(this._isDirected,arguments[0]):c(this._isDirected,t,e,n);return r.has(this._edgeLabels,i)},a.prototype.removeEdge=function(t,e,n){var r=1===arguments.length?l(this._isDirected,arguments[0]):c(this._isDirected,t,e,n),i=this._edgeObjs[r];return i&&(t=i.v,e=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],s(this._preds[e],t),s(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this},a.prototype.inEdges=function(t,e){var n=this._in[t];if(n){var i=r.values(n);return e?r.filter(i,(function(t){return t.v===e})):i}},a.prototype.outEdges=function(t,e){var n=this._out[t];if(n){var i=r.values(n);return e?r.filter(i,(function(t){return t.w===e})):i}},a.prototype.nodeEdges=function(t,e){var n=this.inEdges(t,e);if(n)return n.concat(this.outEdges(t,e))}},2354:(t,e,n)=>{t.exports={Graph:n(771),version:n(9631)}},8974:(t,e,n)=>{var r=n(9126),i=n(771);function a(t){return r.map(t.nodes(),(function(e){var n=t.node(e),i=t.parent(e),a={v:e};return r.isUndefined(n)||(a.value=n),r.isUndefined(i)||(a.parent=i),a}))}function o(t){return r.map(t.edges(),(function(e){var n=t.edge(e),i={v:e.v,w:e.w};return r.isUndefined(e.name)||(i.name=e.name),r.isUndefined(n)||(i.value=n),i}))}t.exports={write:function(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:a(t),edges:o(t)};return r.isUndefined(t.graph())||(e.value=r.clone(t.graph())),e},read:function(t){var e=new i(t.options).setGraph(t.value);return r.each(t.nodes,(function(t){e.setNode(t.v,t.value),t.parent&&e.setParent(t.v,t.parent)})),r.each(t.edges,(function(t){e.setEdge({v:t.v,w:t.w,name:t.name},t.value)})),e}}},9126:(t,e,n)=>{var r;try{r={clone:n(6678),constant:n(5703),each:n(6073),filter:n(3105),has:n(8721),isArray:n(1469),isEmpty:n(1609),isFunction:n(3560),isUndefined:n(2353),keys:n(3674),map:n(5161),reduce:n(4061),size:n(4238),transform:n(8718),union:n(3386),values:n(2628)}}catch(t){}r||(r=window._),t.exports=r},9631:t=>{t.exports="2.1.8"},6240:t=>{"use strict";t.exports=function(t){return"object"==typeof t&&null!==t}},1773:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(7628),a=function(){function t(t,e){this.color=e,this.changed=!1,this.data=t,this.type=new i.default}return t.prototype.set=function(t,e){return this.color=e,this.changed=!1,this.data=t,this.type.type=0,this},t.prototype._ensureHSL=function(){var t=this.data,e=t.h,n=t.s,i=t.l;void 0===e&&(t.h=r.default.channel.rgb2hsl(t,"h")),void 0===n&&(t.s=r.default.channel.rgb2hsl(t,"s")),void 0===i&&(t.l=r.default.channel.rgb2hsl(t,"l"))},t.prototype._ensureRGB=function(){var t=this.data,e=t.r,n=t.g,i=t.b;void 0===e&&(t.r=r.default.channel.hsl2rgb(t,"r")),void 0===n&&(t.g=r.default.channel.hsl2rgb(t,"g")),void 0===i&&(t.b=r.default.channel.hsl2rgb(t,"b"))},Object.defineProperty(t.prototype,"r",{get:function(){var t=this.data,e=t.r;return this.type.is(2)||void 0===e?(this._ensureHSL(),r.default.channel.hsl2rgb(t,"r")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.r=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"g",{get:function(){var t=this.data,e=t.g;return this.type.is(2)||void 0===e?(this._ensureHSL(),r.default.channel.hsl2rgb(t,"g")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.g=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"b",{get:function(){var t=this.data,e=t.b;return this.type.is(2)||void 0===e?(this._ensureHSL(),r.default.channel.hsl2rgb(t,"b")):e},set:function(t){this.type.set(1),this.changed=!0,this.data.b=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"h",{get:function(){var t=this.data,e=t.h;return this.type.is(1)||void 0===e?(this._ensureRGB(),r.default.channel.rgb2hsl(t,"h")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.h=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"s",{get:function(){var t=this.data,e=t.s;return this.type.is(1)||void 0===e?(this._ensureRGB(),r.default.channel.rgb2hsl(t,"s")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.s=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"l",{get:function(){var t=this.data,e=t.l;return this.type.is(1)||void 0===e?(this._ensureRGB(),r.default.channel.rgb2hsl(t,"l")):e},set:function(t){this.type.set(2),this.changed=!0,this.data.l=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"a",{get:function(){return this.data.a},set:function(t){this.changed=!0,this.data.a=t},enumerable:!0,configurable:!0}),t}();e.default=a},8167:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=new(n(1773).default)({r:0,g:0,b:0,a:0},"transparent");e.default=r},7628:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function t(){this.type=0}return t.prototype.get=function(){return this.type},t.prototype.set=function(t){if(this.type&&this.type!==t)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=t},t.prototype.reset=function(){this.type=0},t.prototype.is=function(t){return this.type===t},t}();e.default=n},1655:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8167),i=n(6061),a={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:function(t){if(35===t.charCodeAt(0)){var e=t.match(a.re);if(e){var n=e[1],i=parseInt(n,16),o=n.length,s=o%4==0,c=o>4,u=c?1:17,l=c?8:4,f=s?0:-1,h=c?255:15;return r.default.set({r:(i>>l*(f+3)&h)*u,g:(i>>l*(f+2)&h)*u,b:(i>>l*(f+1)&h)*u,a:s?(i&h)*u/255:1},t)}}},stringify:function(t){var e=t.r,n=t.g,r=t.b,a=t.a;return a<1?"#"+i.DEC2HEX[Math.round(e)]+i.DEC2HEX[Math.round(n)]+i.DEC2HEX[Math.round(r)]+i.DEC2HEX[Math.round(255*a)]:"#"+i.DEC2HEX[Math.round(e)]+i.DEC2HEX[Math.round(n)]+i.DEC2HEX[Math.round(r)]}};e.default=a},8589:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(8167),a={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:function(t){var e=t.match(a.hueRe);if(e){var n=e[1];switch(e[2]){case"grad":return r.default.channel.clamp.h(.9*parseFloat(n));case"rad":return r.default.channel.clamp.h(180*parseFloat(n)/Math.PI);case"turn":return r.default.channel.clamp.h(360*parseFloat(n))}}return r.default.channel.clamp.h(parseFloat(t))},parse:function(t){var e=t.charCodeAt(0);if(104===e||72===e){var n=t.match(a.re);if(n){var o=n[1],s=n[2],c=n[3],u=n[4],l=n[5];return i.default.set({h:a._hue2deg(o),s:r.default.channel.clamp.s(parseFloat(s)),l:r.default.channel.clamp.l(parseFloat(c)),a:u?r.default.channel.clamp.a(l?parseFloat(u)/100:parseFloat(u)):1},t)}}},stringify:function(t){var e=t.h,n=t.s,i=t.l,a=t.a;return a<1?"hsla("+r.default.lang.round(e)+", "+r.default.lang.round(n)+"%, "+r.default.lang.round(i)+"%, "+a+")":"hsl("+r.default.lang.round(e)+", "+r.default.lang.round(n)+"%, "+r.default.lang.round(i)+"%)"}};e.default=a},2191:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1655),i=n(7538),a=n(6762),o=n(8589),s={format:{keyword:i.default,hex:r.default,rgb:a.default,rgba:a.default,hsl:o.default,hsla:o.default},parse:function(t){if("string"!=typeof t)return t;var e=r.default.parse(t)||a.default.parse(t)||o.default.parse(t)||i.default.parse(t);if(e)return e;throw new Error('Unsupported color format: "'+t+'"')},stringify:function(t){return!t.changed&&t.color?t.color:t.type.is(2)||void 0===t.data.r?o.default.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?a.default.stringify(t):r.default.stringify(t)}};e.default=s},7538:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1655),i={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:function(t){t=t.toLowerCase();var e=i.colors[t];if(e)return r.default.parse(e)},stringify:function(t){var e=r.default.stringify(t);for(var n in i.colors)if(i.colors[n]===e)return n}};e.default=i},6762:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(8167),a={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:function(t){var e=t.charCodeAt(0);if(114===e||82===e){var n=t.match(a.re);if(n){var o=n[1],s=n[2],c=n[3],u=n[4],l=n[5],f=n[6],h=n[7],d=n[8];return i.default.set({r:r.default.channel.clamp.r(s?2.55*parseFloat(o):parseFloat(o)),g:r.default.channel.clamp.g(u?2.55*parseFloat(c):parseFloat(c)),b:r.default.channel.clamp.b(f?2.55*parseFloat(l):parseFloat(l)),a:h?r.default.channel.clamp.a(d?parseFloat(h)/100:parseFloat(h)):1},t)}}},stringify:function(t){var e=t.r,n=t.g,i=t.b,a=t.a;return a<1?"rgba("+r.default.lang.round(e)+", "+r.default.lang.round(n)+", "+r.default.lang.round(i)+", "+r.default.lang.round(a)+")":"rgb("+r.default.lang.round(e)+", "+r.default.lang.round(n)+", "+r.default.lang.round(i)+")"}};e.default=a},6061:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i={};e.DEC2HEX=i;for(var a=0;a<=255;a++)i[a]=r.default.unit.dec2hex(a)},8613:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t){for(var n in t)e.hasOwnProperty(n)||(e[n]=t[n])}(n(1203))},5371:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191),i=n(418);e.default=function(t,e){var n=r.default.parse(t),a={};for(var o in e)e[o]&&(a[o]=n[o]+e[o]);return i.default(t,a)}},1416:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(2191);e.default=function(t,e,n){var a=i.default.parse(t),o=a[e],s=r.default.channel.clamp[e](o+n);return o!==s&&(a[e]=s),i.default.stringify(a)}},9353:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"a")}},3394:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"b")}},418:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(2191);e.default=function(t,e){var n=i.default.parse(t);for(var a in e)n[a]=r.default.channel.clamp[a](e[a]);return i.default.stringify(n)}},6197:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(2191);e.default=function(t,e){return r.default.lang.round(i.default.parse(t)[e])}},7647:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t){return r.default(t,"h",180)}},6881:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(8346);e.default=function(t,e){var n=i.default(t),a=i.default(e),o=Math.max(n,a),s=Math.min(n,a),c=(o+Number.EPSILON)/(s+Number.EPSILON);return r.default.lang.round(r.default.lang.clamp(c,1,10))}},1364:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"l",-e)}},9610:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"s",-e)}},572:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(418);e.default=function(t){return r.default(t,{s:0})}},2299:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"g")}},3116:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(8167),a=n(2191);e.default=function(t,e,n,o){void 0===o&&(o=1);var s=i.default.set({h:r.default.channel.clamp.h(t),s:r.default.channel.clamp.s(e),l:r.default.channel.clamp.l(n),a:r.default.channel.clamp.a(o)});return a.default.stringify(s)}},3008:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"h")}},1203:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6538);e.hex=r.default;var i=n(6538);e.rgb=i.default;var a=n(6538);e.rgba=a.default;var o=n(3116);e.hsl=o.default;var s=n(3116);e.hsla=s.default;var c=n(2619);e.toKeyword=c.default;var u=n(4307);e.toHex=u.default;var l=n(7713);e.toRgba=l.default;var f=n(7329);e.toHsla=f.default;var h=n(6197);e.channel=h.default;var d=n(9640);e.red=d.default;var p=n(2299);e.green=p.default;var g=n(3394);e.blue=g.default;var y=n(3008);e.hue=y.default;var m=n(6451);e.saturation=m.default;var v=n(9235);e.lightness=v.default;var b=n(9353);e.alpha=b.default;var _=n(9353);e.opacity=_.default;var x=n(6881);e.contrast=x.default;var w=n(8346);e.luminance=w.default;var k=n(4117);e.isDark=k.default;var T=n(2224);e.isLight=T.default;var E=n(585);e.isValid=E.default;var C=n(1080);e.saturate=C.default;var S=n(9610);e.desaturate=S.default;var M=n(3235);e.lighten=M.default;var A=n(1364);e.darken=A.default;var O=n(7189);e.opacify=O.default;var N=n(7189);e.fadeIn=N.default;var j=n(4989);e.transparentize=j.default;var D=n(4989);e.fadeOut=D.default;var B=n(7647);e.complement=B.default;var L=n(572);e.grayscale=L.default;var I=n(5371);e.adjust=I.default;var R=n(418);e.change=R.default;var P=n(566);e.invert=P.default;var F=n(1861);e.mix=F.default;var z=n(7081);e.scale=z.default},566:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191),i=n(1861);e.default=function(t,e){void 0===e&&(e=100);var n=r.default.parse(t);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,i.default(n,t,e)}},4117:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2224);e.default=function(t){return!r.default(t)}},2224:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(8346);e.default=function(t){return r.default(t)>=.5}},585:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191);e.default=function(t){try{return r.default.parse(t),!0}catch(t){return!1}}},3235:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"l",e)}},9235:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"l")}},8346:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(2191);e.default=function(t){var e=i.default.parse(t),n=e.r,a=e.g,o=e.b,s=.2126*r.default.channel.toLinear(n)+.7152*r.default.channel.toLinear(a)+.0722*r.default.channel.toLinear(o);return r.default.lang.round(s)}},1861:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191),i=n(6538);e.default=function(t,e,n){void 0===n&&(n=50);var a=r.default.parse(t),o=a.r,s=a.g,c=a.b,u=a.a,l=r.default.parse(e),f=l.r,h=l.g,d=l.b,p=l.a,g=n/100,y=2*g-1,m=u-p,v=((y*m==-1?y:(y+m)/(1+y*m))+1)/2,b=1-v,_=o*v+f*b,x=s*v+h*b,w=c*v+d*b,k=u*g+p*(1-g);return i.default(_,x,w,k)}},7189:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"a",e)}},9640:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"r")}},6538:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(8167),a=n(2191),o=n(418);e.default=function(t,e,n,s){if(void 0===n&&(n=0),void 0===s&&(s=1),"number"!=typeof t)return o.default(t,{a:e});var c=i.default.set({r:r.default.channel.clamp.r(t),g:r.default.channel.clamp.g(e),b:r.default.channel.clamp.b(n),a:r.default.channel.clamp.a(s)});return a.default.stringify(c)}},1080:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"s",e)}},6451:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(6197);e.default=function(t){return r.default(t,"s")}},7081:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1083),i=n(2191),a=n(5371);e.default=function(t,e){var n,o,s,c=i.default.parse(t),u={};for(var l in e)u[l]=(n=c[l],o=e[l],s=r.default.channel.max[l],o>0?(s-n)*o/100:n*o/100);return a.default(t,u)}},4307:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191);e.default=function(t){return r.default.format.hex.stringify(r.default.parse(t))}},7329:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191);e.default=function(t){return r.default.format.hsla.stringify(r.default.parse(t))}},2619:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191);e.default=function(t){return r.default.format.keyword.stringify(r.default.parse(t))}},7713:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(2191);e.default=function(t){return r.default.format.rgba.stringify(r.default.parse(t))}},4989:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(1416);e.default=function(t,e){return r.default(t,"a",-e)}},7994:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:function(t){return t>=255?255:t<0?0:t},g:function(t){return t>=255?255:t<0?0:t},b:function(t){return t>=255?255:t<0?0:t},h:function(t){return t%360},s:function(t){return t>=100?100:t<0?0:t},l:function(t){return t>=100?100:t<0?0:t},a:function(t){return t>=1?1:t<0?0:t}},toLinear:function(t){var e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},hue2rgb:function(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t},hsl2rgb:function(t,e){var r=t.h,i=t.s,a=t.l;if(!i)return 2.55*a;r/=360,i/=100;var o=(a/=100)<.5?a*(1+i):a+i-a*i,s=2*a-o;switch(e){case"r":return 255*n.hue2rgb(s,o,r+1/3);case"g":return 255*n.hue2rgb(s,o,r);case"b":return 255*n.hue2rgb(s,o,r-1/3)}},rgb2hsl:function(t,e){var n=t.r,r=t.g,i=t.b;n/=255,r/=255,i/=255;var a=Math.max(n,r,i),o=Math.min(n,r,i),s=(a+o)/2;if("l"===e)return 100*s;if(a===o)return 0;var c=a-o;if("s"===e)return 100*(s>.5?c/(2-a-o):c/(a+o));switch(a){case n:return 60*((r-i)/c+(r<i?6:0));case r:return 60*((i-n)/c+2);case i:return 60*((n-r)/c+4);default:return-1}}};e.default=n},1083:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(7994),i=n(4027),a=n(318),o={channel:r.default,lang:i.default,unit:a.default};e.default=o},4027:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n={clamp:function(t,e,n){return e>n?Math.min(e,Math.max(n,t)):Math.min(n,Math.max(e,t))},round:function(t){return Math.round(1e10*t)/1e10}};e.default=n},318:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n={dec2hex:function(t){var e=Math.round(t).toString(16);return e.length>1?e:"0"+e}};e.default=n},8552:(t,e,n)=>{var r=n(852)(n(5639),"DataView");t.exports=r},1989:(t,e,n)=>{var r=n(1789),i=n(401),a=n(7667),o=n(1327),s=n(1866);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c},8407:(t,e,n)=>{var r=n(7040),i=n(4125),a=n(2117),o=n(7518),s=n(4705);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c},7071:(t,e,n)=>{var r=n(852)(n(5639),"Map");t.exports=r},3369:(t,e,n)=>{var r=n(4785),i=n(1285),a=n(6e3),o=n(9916),s=n(5265);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}c.prototype.clear=r,c.prototype.delete=i,c.prototype.get=a,c.prototype.has=o,c.prototype.set=s,t.exports=c},3818:(t,e,n)=>{var r=n(852)(n(5639),"Promise");t.exports=r},8525:(t,e,n)=>{var r=n(852)(n(5639),"Set");t.exports=r},8668:(t,e,n)=>{var r=n(3369),i=n(619),a=n(2385);function o(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new r;++e<n;)this.add(t[e])}o.prototype.add=o.prototype.push=i,o.prototype.has=a,t.exports=o},6384:(t,e,n)=>{var r=n(8407),i=n(7465),a=n(3779),o=n(7599),s=n(4758),c=n(4309);function u(t){var e=this.__data__=new r(t);this.size=e.size}u.prototype.clear=i,u.prototype.delete=a,u.prototype.get=o,u.prototype.has=s,u.prototype.set=c,t.exports=u},2705:(t,e,n)=>{var r=n(5639).Symbol;t.exports=r},1149:(t,e,n)=>{var r=n(5639).Uint8Array;t.exports=r},577:(t,e,n)=>{var r=n(852)(n(5639),"WeakMap");t.exports=r},6874:t=>{t.exports=function(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}},7412:t=>{t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r&&!1!==e(t[n],n,t););return t}},4963:t=>{t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,a=[];++n<r;){var o=t[n];e(o,n,t)&&(a[i++]=o)}return a}},7443:(t,e,n)=>{var r=n(2118);t.exports=function(t,e){return!(null==t||!t.length)&&r(t,e,0)>-1}},1196:t=>{t.exports=function(t,e,n){for(var r=-1,i=null==t?0:t.length;++r<i;)if(n(e,t[r]))return!0;return!1}},4636:(t,e,n)=>{var r=n(2545),i=n(5694),a=n(1469),o=n(4144),s=n(5776),c=n(6719),u=Object.prototype.hasOwnProperty;t.exports=function(t,e){var n=a(t),l=!n&&i(t),f=!n&&!l&&o(t),h=!n&&!l&&!f&&c(t),d=n||l||f||h,p=d?r(t.length,String):[],g=p.length;for(var y in t)!e&&!u.call(t,y)||d&&("length"==y||f&&("offset"==y||"parent"==y)||h&&("buffer"==y||"byteLength"==y||"byteOffset"==y)||s(y,g))||p.push(y);return p}},9932:t=>{t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}},2488:t=>{t.exports=function(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}},2663:t=>{t.exports=function(t,e,n,r){var i=-1,a=null==t?0:t.length;for(r&&a&&(n=t[++i]);++i<a;)n=e(n,t[i],i,t);return n}},2908:t=>{t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}},8983:(t,e,n)=>{var r=n(371)("length");t.exports=r},6556:(t,e,n)=>{var r=n(9465),i=n(7813);t.exports=function(t,e,n){(void 0!==n&&!i(t[e],n)||void 0===n&&!(e in t))&&r(t,e,n)}},4865:(t,e,n)=>{var r=n(9465),i=n(7813),a=Object.prototype.hasOwnProperty;t.exports=function(t,e,n){var o=t[e];a.call(t,e)&&i(o,n)&&(void 0!==n||e in t)||r(t,e,n)}},8470:(t,e,n)=>{var r=n(7813);t.exports=function(t,e){for(var n=t.length;n--;)if(r(t[n][0],e))return n;return-1}},4037:(t,e,n)=>{var r=n(8363),i=n(3674);t.exports=function(t,e){return t&&r(e,i(e),t)}},3886:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(t,e){return t&&r(e,i(e),t)}},9465:(t,e,n)=>{var r=n(8777);t.exports=function(t,e,n){"__proto__"==e&&r?r(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},5990:(t,e,n)=>{var r=n(6384),i=n(7412),a=n(4865),o=n(4037),s=n(3886),c=n(4626),u=n(278),l=n(8805),f=n(1911),h=n(8234),d=n(6904),p=n(4160),g=n(3824),y=n(9148),m=n(8517),v=n(1469),b=n(4144),_=n(6688),x=n(3218),w=n(2928),k=n(3674),T=n(1704),E="[object Arguments]",C="[object Function]",S="[object Object]",M={};M[E]=M["[object Array]"]=M["[object ArrayBuffer]"]=M["[object DataView]"]=M["[object Boolean]"]=M["[object Date]"]=M["[object Float32Array]"]=M["[object Float64Array]"]=M["[object Int8Array]"]=M["[object Int16Array]"]=M["[object Int32Array]"]=M["[object Map]"]=M["[object Number]"]=M[S]=M["[object RegExp]"]=M["[object Set]"]=M["[object String]"]=M["[object Symbol]"]=M["[object Uint8Array]"]=M["[object Uint8ClampedArray]"]=M["[object Uint16Array]"]=M["[object Uint32Array]"]=!0,M["[object Error]"]=M[C]=M["[object WeakMap]"]=!1,t.exports=function t(e,n,A,O,N,j){var D,B=1&n,L=2&n,I=4&n;if(A&&(D=N?A(e,O,N,j):A(e)),void 0!==D)return D;if(!x(e))return e;var R=v(e);if(R){if(D=g(e),!B)return u(e,D)}else{var P=p(e),F=P==C||"[object GeneratorFunction]"==P;if(b(e))return c(e,B);if(P==S||P==E||F&&!N){if(D=L||F?{}:m(e),!B)return L?f(e,s(D,e)):l(e,o(D,e))}else{if(!M[P])return N?e:{};D=y(e,P,B)}}j||(j=new r);var z=j.get(e);if(z)return z;j.set(e,D),w(e)?e.forEach((function(r){D.add(t(r,n,A,r,e,j))})):_(e)&&e.forEach((function(r,i){D.set(i,t(r,n,A,i,e,j))}));var Y=R?void 0:(I?L?d:h:L?T:k)(e);return i(Y||e,(function(r,i){Y&&(r=e[i=r]),a(D,i,t(r,n,A,i,e,j))})),D}},3118:(t,e,n)=>{var r=n(3218),i=Object.create,a=function(){function t(){}return function(e){if(!r(e))return{};if(i)return i(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();t.exports=a},9881:(t,e,n)=>{var r=n(7816),i=n(9291)(r);t.exports=i},6029:(t,e,n)=>{var r=n(3448);t.exports=function(t,e,n){for(var i=-1,a=t.length;++i<a;){var o=t[i],s=e(o);if(null!=s&&(void 0===c?s==s&&!r(s):n(s,c)))var c=s,u=o}return u}},760:(t,e,n)=>{var r=n(9881);t.exports=function(t,e){var n=[];return r(t,(function(t,r,i){e(t,r,i)&&n.push(t)})),n}},1848:t=>{t.exports=function(t,e,n,r){for(var i=t.length,a=n+(r?1:-1);r?a--:++a<i;)if(e(t[a],a,t))return a;return-1}},1078:(t,e,n)=>{var r=n(2488),i=n(7285);t.exports=function t(e,n,a,o,s){var c=-1,u=e.length;for(a||(a=i),s||(s=[]);++c<u;){var l=e[c];n>0&&a(l)?n>1?t(l,n-1,a,o,s):r(s,l):o||(s[s.length]=l)}return s}},8483:(t,e,n)=>{var r=n(5063)();t.exports=r},7816:(t,e,n)=>{var r=n(8483),i=n(3674);t.exports=function(t,e){return t&&r(t,e,i)}},7786:(t,e,n)=>{var r=n(1811),i=n(327);t.exports=function(t,e){for(var n=0,a=(e=r(e,t)).length;null!=t&&n<a;)t=t[i(e[n++])];return n&&n==a?t:void 0}},8866:(t,e,n)=>{var r=n(2488),i=n(1469);t.exports=function(t,e,n){var a=e(t);return i(t)?a:r(a,n(t))}},4239:(t,e,n)=>{var r=n(2705),i=n(9607),a=n(2333),o=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":o&&o in Object(t)?i(t):a(t)}},3325:t=>{t.exports=function(t,e){return t>e}},8565:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(t,n){return null!=t&&e.call(t,n)}},13:t=>{t.exports=function(t,e){return null!=t&&e in Object(t)}},2118:(t,e,n)=>{var r=n(1848),i=n(2722),a=n(2351);t.exports=function(t,e,n){return e==e?a(t,e,n):r(t,i,n)}},9454:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(t){return i(t)&&"[object Arguments]"==r(t)}},939:(t,e,n)=>{var r=n(2492),i=n(7005);t.exports=function t(e,n,a,o,s){return e===n||(null==e||null==n||!i(e)&&!i(n)?e!=e&&n!=n:r(e,n,a,o,t,s))}},2492:(t,e,n)=>{var r=n(6384),i=n(7114),a=n(8351),o=n(6096),s=n(4160),c=n(1469),u=n(4144),l=n(6719),f="[object Arguments]",h="[object Array]",d="[object Object]",p=Object.prototype.hasOwnProperty;t.exports=function(t,e,n,g,y,m){var v=c(t),b=c(e),_=v?h:s(t),x=b?h:s(e),w=(_=_==f?d:_)==d,k=(x=x==f?d:x)==d,T=_==x;if(T&&u(t)){if(!u(e))return!1;v=!0,w=!1}if(T&&!w)return m||(m=new r),v||l(t)?i(t,e,n,g,y,m):a(t,e,_,n,g,y,m);if(!(1&n)){var E=w&&p.call(t,"__wrapped__"),C=k&&p.call(e,"__wrapped__");if(E||C){var S=E?t.value():t,M=C?e.value():e;return m||(m=new r),y(S,M,n,g,m)}}return!!T&&(m||(m=new r),o(t,e,n,g,y,m))}},5588:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(t){return i(t)&&"[object Map]"==r(t)}},2958:(t,e,n)=>{var r=n(6384),i=n(939);t.exports=function(t,e,n,a){var o=n.length,s=o,c=!a;if(null==t)return!s;for(t=Object(t);o--;){var u=n[o];if(c&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++o<s;){var l=(u=n[o])[0],f=t[l],h=u[1];if(c&&u[2]){if(void 0===f&&!(l in t))return!1}else{var d=new r;if(a)var p=a(f,h,l,t,e,d);if(!(void 0===p?i(h,f,3,a,d):p))return!1}}return!0}},2722:t=>{t.exports=function(t){return t!=t}},8458:(t,e,n)=>{var r=n(3560),i=n(5346),a=n(3218),o=n(346),s=/^\[object .+?Constructor\]$/,c=Function.prototype,u=Object.prototype,l=c.toString,f=u.hasOwnProperty,h=RegExp("^"+l.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");t.exports=function(t){return!(!a(t)||i(t))&&(r(t)?h:s).test(o(t))}},9221:(t,e,n)=>{var r=n(4160),i=n(7005);t.exports=function(t){return i(t)&&"[object Set]"==r(t)}},8749:(t,e,n)=>{var r=n(4239),i=n(1780),a=n(7005),o={};o["[object Float32Array]"]=o["[object Float64Array]"]=o["[object Int8Array]"]=o["[object Int16Array]"]=o["[object Int32Array]"]=o["[object Uint8Array]"]=o["[object Uint8ClampedArray]"]=o["[object Uint16Array]"]=o["[object Uint32Array]"]=!0,o["[object Arguments]"]=o["[object Array]"]=o["[object ArrayBuffer]"]=o["[object Boolean]"]=o["[object DataView]"]=o["[object Date]"]=o["[object Error]"]=o["[object Function]"]=o["[object Map]"]=o["[object Number]"]=o["[object Object]"]=o["[object RegExp]"]=o["[object Set]"]=o["[object String]"]=o["[object WeakMap]"]=!1,t.exports=function(t){return a(t)&&i(t.length)&&!!o[r(t)]}},7206:(t,e,n)=>{var r=n(1573),i=n(6432),a=n(6557),o=n(1469),s=n(9601);t.exports=function(t){return"function"==typeof t?t:null==t?a:"object"==typeof t?o(t)?i(t[0],t[1]):r(t):s(t)}},280:(t,e,n)=>{var r=n(5726),i=n(6916),a=Object.prototype.hasOwnProperty;t.exports=function(t){if(!r(t))return i(t);var e=[];for(var n in Object(t))a.call(t,n)&&"constructor"!=n&&e.push(n);return e}},313:(t,e,n)=>{var r=n(3218),i=n(5726),a=n(3498),o=Object.prototype.hasOwnProperty;t.exports=function(t){if(!r(t))return a(t);var e=i(t),n=[];for(var s in t)("constructor"!=s||!e&&o.call(t,s))&&n.push(s);return n}},433:t=>{t.exports=function(t,e){return t<e}},9199:(t,e,n)=>{var r=n(9881),i=n(8612);t.exports=function(t,e){var n=-1,a=i(t)?Array(t.length):[];return r(t,(function(t,r,i){a[++n]=e(t,r,i)})),a}},1573:(t,e,n)=>{var r=n(2958),i=n(1499),a=n(2634);t.exports=function(t){var e=i(t);return 1==e.length&&e[0][2]?a(e[0][0],e[0][1]):function(n){return n===t||r(n,t,e)}}},6432:(t,e,n)=>{var r=n(939),i=n(7361),a=n(9095),o=n(5403),s=n(9162),c=n(2634),u=n(327);t.exports=function(t,e){return o(t)&&s(e)?c(u(t),e):function(n){var o=i(n,t);return void 0===o&&o===e?a(n,t):r(e,o,3)}}},2980:(t,e,n)=>{var r=n(6384),i=n(6556),a=n(8483),o=n(9783),s=n(3218),c=n(1704),u=n(6390);t.exports=function t(e,n,l,f,h){e!==n&&a(n,(function(a,c){if(h||(h=new r),s(a))o(e,n,c,l,t,f,h);else{var d=f?f(u(e,c),a,c+"",e,n,h):void 0;void 0===d&&(d=a),i(e,c,d)}}),c)}},9783:(t,e,n)=>{var r=n(6556),i=n(4626),a=n(7133),o=n(278),s=n(8517),c=n(5694),u=n(1469),l=n(9246),f=n(4144),h=n(3560),d=n(3218),p=n(8630),g=n(6719),y=n(6390),m=n(3678);t.exports=function(t,e,n,v,b,_,x){var w=y(t,n),k=y(e,n),T=x.get(k);if(T)r(t,n,T);else{var E=_?_(w,k,n+"",t,e,x):void 0,C=void 0===E;if(C){var S=u(k),M=!S&&f(k),A=!S&&!M&&g(k);E=k,S||M||A?u(w)?E=w:l(w)?E=o(w):M?(C=!1,E=i(k,!0)):A?(C=!1,E=a(k,!0)):E=[]:p(k)||c(k)?(E=w,c(w)?E=m(w):d(w)&&!h(w)||(E=s(k))):C=!1}C&&(x.set(k,E),b(E,k,v,_,x),x.delete(k)),r(t,n,E)}}},9556:(t,e,n)=>{var r=n(9932),i=n(7786),a=n(7206),o=n(9199),s=n(1131),c=n(1717),u=n(5022),l=n(6557),f=n(1469);t.exports=function(t,e,n){e=e.length?r(e,(function(t){return f(t)?function(e){return i(e,1===t.length?t[0]:t)}:t})):[l];var h=-1;e=r(e,c(a));var d=o(t,(function(t,n,i){return{criteria:r(e,(function(e){return e(t)})),index:++h,value:t}}));return s(d,(function(t,e){return u(t,e,n)}))}},5970:(t,e,n)=>{var r=n(3012),i=n(9095);t.exports=function(t,e){return r(t,e,(function(e,n){return i(t,n)}))}},3012:(t,e,n)=>{var r=n(7786),i=n(611),a=n(1811);t.exports=function(t,e,n){for(var o=-1,s=e.length,c={};++o<s;){var u=e[o],l=r(t,u);n(l,u)&&i(c,a(u,t),l)}return c}},371:t=>{t.exports=function(t){return function(e){return null==e?void 0:e[t]}}},9152:(t,e,n)=>{var r=n(7786);t.exports=function(t){return function(e){return r(e,t)}}},98:t=>{var e=Math.ceil,n=Math.max;t.exports=function(t,r,i,a){for(var o=-1,s=n(e((r-t)/(i||1)),0),c=Array(s);s--;)c[a?s:++o]=t,t+=i;return c}},107:t=>{t.exports=function(t,e,n,r,i){return i(t,(function(t,i,a){n=r?(r=!1,t):e(n,t,i,a)})),n}},5976:(t,e,n)=>{var r=n(6557),i=n(5357),a=n(61);t.exports=function(t,e){return a(i(t,e,r),t+"")}},611:(t,e,n)=>{var r=n(4865),i=n(1811),a=n(5776),o=n(3218),s=n(327);t.exports=function(t,e,n,c){if(!o(t))return t;for(var u=-1,l=(e=i(e,t)).length,f=l-1,h=t;null!=h&&++u<l;){var d=s(e[u]),p=n;if("__proto__"===d||"constructor"===d||"prototype"===d)return t;if(u!=f){var g=h[d];void 0===(p=c?c(g,d,h):void 0)&&(p=o(g)?g:a(e[u+1])?[]:{})}r(h,d,p),h=h[d]}return t}},6560:(t,e,n)=>{var r=n(5703),i=n(8777),a=n(6557),o=i?function(t,e){return i(t,"toString",{configurable:!0,enumerable:!1,value:r(e),writable:!0})}:a;t.exports=o},1131:t=>{t.exports=function(t,e){var n=t.length;for(t.sort(e);n--;)t[n]=t[n].value;return t}},2545:t=>{t.exports=function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}},531:(t,e,n)=>{var r=n(2705),i=n(9932),a=n(1469),o=n(3448),s=r?r.prototype:void 0,c=s?s.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(a(e))return i(e,t)+"";if(o(e))return c?c.call(e):"";var n=e+"";return"0"==n&&1/e==-1/0?"-0":n}},7561:(t,e,n)=>{var r=n(7990),i=/^\s+/;t.exports=function(t){return t?t.slice(0,r(t)+1).replace(i,""):t}},1717:t=>{t.exports=function(t){return function(e){return t(e)}}},5652:(t,e,n)=>{var r=n(8668),i=n(7443),a=n(1196),o=n(4757),s=n(3593),c=n(1814);t.exports=function(t,e,n){var u=-1,l=i,f=t.length,h=!0,d=[],p=d;if(n)h=!1,l=a;else if(f>=200){var g=e?null:s(t);if(g)return c(g);h=!1,l=o,p=new r}else p=e?[]:d;t:for(;++u<f;){var y=t[u],m=e?e(y):y;if(y=n||0!==y?y:0,h&&m==m){for(var v=p.length;v--;)if(p[v]===m)continue t;e&&p.push(m),d.push(y)}else l(p,m,n)||(p!==d&&p.push(m),d.push(y))}return d}},7415:(t,e,n)=>{var r=n(9932);t.exports=function(t,e){return r(e,(function(e){return t[e]}))}},1757:t=>{t.exports=function(t,e,n){for(var r=-1,i=t.length,a=e.length,o={};++r<i;){var s=r<a?e[r]:void 0;n(o,t[r],s)}return o}},4757:t=>{t.exports=function(t,e){return t.has(e)}},4290:(t,e,n)=>{var r=n(6557);t.exports=function(t){return"function"==typeof t?t:r}},1811:(t,e,n)=>{var r=n(1469),i=n(5403),a=n(5514),o=n(9833);t.exports=function(t,e){return r(t)?t:i(t,e)?[t]:a(o(t))}},4318:(t,e,n)=>{var r=n(1149);t.exports=function(t){var e=new t.constructor(t.byteLength);return new r(e).set(new r(t)),e}},4626:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=e&&!e.nodeType&&e,a=i&&t&&!t.nodeType&&t,o=a&&a.exports===i?r.Buffer:void 0,s=o?o.allocUnsafe:void 0;t.exports=function(t,e){if(e)return t.slice();var n=t.length,r=s?s(n):new t.constructor(n);return t.copy(r),r}},7157:(t,e,n)=>{var r=n(4318);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}},3147:t=>{var e=/\w*$/;t.exports=function(t){var n=new t.constructor(t.source,e.exec(t));return n.lastIndex=t.lastIndex,n}},419:(t,e,n)=>{var r=n(2705),i=r?r.prototype:void 0,a=i?i.valueOf:void 0;t.exports=function(t){return a?Object(a.call(t)):{}}},7133:(t,e,n)=>{var r=n(4318);t.exports=function(t,e){var n=e?r(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},6393:(t,e,n)=>{var r=n(3448);t.exports=function(t,e){if(t!==e){var n=void 0!==t,i=null===t,a=t==t,o=r(t),s=void 0!==e,c=null===e,u=e==e,l=r(e);if(!c&&!l&&!o&&t>e||o&&s&&u&&!c&&!l||i&&s&&u||!n&&u||!a)return 1;if(!i&&!o&&!l&&t<e||l&&n&&a&&!i&&!o||c&&n&&a||!s&&a||!u)return-1}return 0}},5022:(t,e,n)=>{var r=n(6393);t.exports=function(t,e,n){for(var i=-1,a=t.criteria,o=e.criteria,s=a.length,c=n.length;++i<s;){var u=r(a[i],o[i]);if(u)return i>=c?u:u*("desc"==n[i]?-1:1)}return t.index-e.index}},278:t=>{t.exports=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}},8363:(t,e,n)=>{var r=n(4865),i=n(9465);t.exports=function(t,e,n,a){var o=!n;n||(n={});for(var s=-1,c=e.length;++s<c;){var u=e[s],l=a?a(n[u],t[u],u,n,t):void 0;void 0===l&&(l=t[u]),o?i(n,u,l):r(n,u,l)}return n}},8805:(t,e,n)=>{var r=n(8363),i=n(9551);t.exports=function(t,e){return r(t,i(t),e)}},1911:(t,e,n)=>{var r=n(8363),i=n(1442);t.exports=function(t,e){return r(t,i(t),e)}},4429:(t,e,n)=>{var r=n(5639)["__core-js_shared__"];t.exports=r},1463:(t,e,n)=>{var r=n(5976),i=n(6612);t.exports=function(t){return r((function(e,n){var r=-1,a=n.length,o=a>1?n[a-1]:void 0,s=a>2?n[2]:void 0;for(o=t.length>3&&"function"==typeof o?(a--,o):void 0,s&&i(n[0],n[1],s)&&(o=a<3?void 0:o,a=1),e=Object(e);++r<a;){var c=n[r];c&&t(e,c,r,o)}return e}))}},9291:(t,e,n)=>{var r=n(8612);t.exports=function(t,e){return function(n,i){if(null==n)return n;if(!r(n))return t(n,i);for(var a=n.length,o=e?a:-1,s=Object(n);(e?o--:++o<a)&&!1!==i(s[o],o,s););return n}}},5063:t=>{t.exports=function(t){return function(e,n,r){for(var i=-1,a=Object(e),o=r(e),s=o.length;s--;){var c=o[t?s:++i];if(!1===n(a[c],c,a))break}return e}}},7740:(t,e,n)=>{var r=n(7206),i=n(8612),a=n(3674);t.exports=function(t){return function(e,n,o){var s=Object(e);if(!i(e)){var c=r(n,3);e=a(e),n=function(t){return c(s[t],t,s)}}var u=t(e,n,o);return u>-1?s[c?e[u]:u]:void 0}}},7445:(t,e,n)=>{var r=n(98),i=n(6612),a=n(8601);t.exports=function(t){return function(e,n,o){return o&&"number"!=typeof o&&i(e,n,o)&&(n=o=void 0),e=a(e),void 0===n?(n=e,e=0):n=a(n),o=void 0===o?e<n?1:-1:a(o),r(e,n,o,t)}}},3593:(t,e,n)=>{var r=n(8525),i=n(308),a=n(1814),o=r&&1/a(new r([,-0]))[1]==1/0?function(t){return new r(t)}:i;t.exports=o},8777:(t,e,n)=>{var r=n(852),i=function(){try{var t=r(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();t.exports=i},7114:(t,e,n)=>{var r=n(8668),i=n(2908),a=n(4757);t.exports=function(t,e,n,o,s,c){var u=1&n,l=t.length,f=e.length;if(l!=f&&!(u&&f>l))return!1;var h=c.get(t),d=c.get(e);if(h&&d)return h==e&&d==t;var p=-1,g=!0,y=2&n?new r:void 0;for(c.set(t,e),c.set(e,t);++p<l;){var m=t[p],v=e[p];if(o)var b=u?o(v,m,p,e,t,c):o(m,v,p,t,e,c);if(void 0!==b){if(b)continue;g=!1;break}if(y){if(!i(e,(function(t,e){if(!a(y,e)&&(m===t||s(m,t,n,o,c)))return y.push(e)}))){g=!1;break}}else if(m!==v&&!s(m,v,n,o,c)){g=!1;break}}return c.delete(t),c.delete(e),g}},8351:(t,e,n)=>{var r=n(2705),i=n(1149),a=n(7813),o=n(7114),s=n(8776),c=n(1814),u=r?r.prototype:void 0,l=u?u.valueOf:void 0;t.exports=function(t,e,n,r,u,f,h){switch(n){case"[object DataView]":if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case"[object ArrayBuffer]":return!(t.byteLength!=e.byteLength||!f(new i(t),new i(e)));case"[object Boolean]":case"[object Date]":case"[object Number]":return a(+t,+e);case"[object Error]":return t.name==e.name&&t.message==e.message;case"[object RegExp]":case"[object String]":return t==e+"";case"[object Map]":var d=s;case"[object Set]":var p=1&r;if(d||(d=c),t.size!=e.size&&!p)return!1;var g=h.get(t);if(g)return g==e;r|=2,h.set(t,e);var y=o(d(t),d(e),r,u,f,h);return h.delete(t),y;case"[object Symbol]":if(l)return l.call(t)==l.call(e)}return!1}},6096:(t,e,n)=>{var r=n(8234),i=Object.prototype.hasOwnProperty;t.exports=function(t,e,n,a,o,s){var c=1&n,u=r(t),l=u.length;if(l!=r(e).length&&!c)return!1;for(var f=l;f--;){var h=u[f];if(!(c?h in e:i.call(e,h)))return!1}var d=s.get(t),p=s.get(e);if(d&&p)return d==e&&p==t;var g=!0;s.set(t,e),s.set(e,t);for(var y=c;++f<l;){var m=t[h=u[f]],v=e[h];if(a)var b=c?a(v,m,h,e,t,s):a(m,v,h,t,e,s);if(!(void 0===b?m===v||o(m,v,n,a,s):b)){g=!1;break}y||(y="constructor"==h)}if(g&&!y){var _=t.constructor,x=e.constructor;_==x||!("constructor"in t)||!("constructor"in e)||"function"==typeof _&&_ instanceof _&&"function"==typeof x&&x instanceof x||(g=!1)}return s.delete(t),s.delete(e),g}},9021:(t,e,n)=>{var r=n(5564),i=n(5357),a=n(61);t.exports=function(t){return a(i(t,void 0,r),t+"")}},1957:(t,e,n)=>{var r="object"==typeof n.g&&n.g&&n.g.Object===Object&&n.g;t.exports=r},8234:(t,e,n)=>{var r=n(8866),i=n(9551),a=n(3674);t.exports=function(t){return r(t,a,i)}},6904:(t,e,n)=>{var r=n(8866),i=n(1442),a=n(1704);t.exports=function(t){return r(t,a,i)}},5050:(t,e,n)=>{var r=n(7019);t.exports=function(t,e){var n=t.__data__;return r(e)?n["string"==typeof e?"string":"hash"]:n.map}},1499:(t,e,n)=>{var r=n(9162),i=n(3674);t.exports=function(t){for(var e=i(t),n=e.length;n--;){var a=e[n],o=t[a];e[n]=[a,o,r(o)]}return e}},852:(t,e,n)=>{var r=n(8458),i=n(7801);t.exports=function(t,e){var n=i(t,e);return r(n)?n:void 0}},5924:(t,e,n)=>{var r=n(5569)(Object.getPrototypeOf,Object);t.exports=r},9607:(t,e,n)=>{var r=n(2705),i=Object.prototype,a=i.hasOwnProperty,o=i.toString,s=r?r.toStringTag:void 0;t.exports=function(t){var e=a.call(t,s),n=t[s];try{t[s]=void 0;var r=!0}catch(t){}var i=o.call(t);return r&&(e?t[s]=n:delete t[s]),i}},9551:(t,e,n)=>{var r=n(4963),i=n(479),a=Object.prototype.propertyIsEnumerable,o=Object.getOwnPropertySymbols,s=o?function(t){return null==t?[]:(t=Object(t),r(o(t),(function(e){return a.call(t,e)})))}:i;t.exports=s},1442:(t,e,n)=>{var r=n(2488),i=n(5924),a=n(9551),o=n(479),s=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)r(e,a(t)),t=i(t);return e}:o;t.exports=s},4160:(t,e,n)=>{var r=n(8552),i=n(7071),a=n(3818),o=n(8525),s=n(577),c=n(4239),u=n(346),l="[object Map]",f="[object Promise]",h="[object Set]",d="[object WeakMap]",p="[object DataView]",g=u(r),y=u(i),m=u(a),v=u(o),b=u(s),_=c;(r&&_(new r(new ArrayBuffer(1)))!=p||i&&_(new i)!=l||a&&_(a.resolve())!=f||o&&_(new o)!=h||s&&_(new s)!=d)&&(_=function(t){var e=c(t),n="[object Object]"==e?t.constructor:void 0,r=n?u(n):"";if(r)switch(r){case g:return p;case y:return l;case m:return f;case v:return h;case b:return d}return e}),t.exports=_},7801:t=>{t.exports=function(t,e){return null==t?void 0:t[e]}},222:(t,e,n)=>{var r=n(1811),i=n(5694),a=n(1469),o=n(5776),s=n(1780),c=n(327);t.exports=function(t,e,n){for(var u=-1,l=(e=r(e,t)).length,f=!1;++u<l;){var h=c(e[u]);if(!(f=null!=t&&n(t,h)))break;t=t[h]}return f||++u!=l?f:!!(l=null==t?0:t.length)&&s(l)&&o(h,l)&&(a(t)||i(t))}},2689:t=>{var e=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");t.exports=function(t){return e.test(t)}},1789:(t,e,n)=>{var r=n(4536);t.exports=function(){this.__data__=r?r(null):{},this.size=0}},401:t=>{t.exports=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}},7667:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;if(r){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return i.call(e,t)?e[t]:void 0}},1327:(t,e,n)=>{var r=n(4536),i=Object.prototype.hasOwnProperty;t.exports=function(t){var e=this.__data__;return r?void 0!==e[t]:i.call(e,t)}},1866:(t,e,n)=>{var r=n(4536);t.exports=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=r&&void 0===e?"__lodash_hash_undefined__":e,this}},3824:t=>{var e=Object.prototype.hasOwnProperty;t.exports=function(t){var n=t.length,r=new t.constructor(n);return n&&"string"==typeof t[0]&&e.call(t,"index")&&(r.index=t.index,r.input=t.input),r}},9148:(t,e,n)=>{var r=n(4318),i=n(7157),a=n(3147),o=n(419),s=n(7133);t.exports=function(t,e,n){var c=t.constructor;switch(e){case"[object ArrayBuffer]":return r(t);case"[object Boolean]":case"[object Date]":return new c(+t);case"[object DataView]":return i(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return s(t,n);case"[object Map]":case"[object Set]":return new c;case"[object Number]":case"[object String]":return new c(t);case"[object RegExp]":return a(t);case"[object Symbol]":return o(t)}}},8517:(t,e,n)=>{var r=n(3118),i=n(5924),a=n(5726);t.exports=function(t){return"function"!=typeof t.constructor||a(t)?{}:r(i(t))}},7285:(t,e,n)=>{var r=n(2705),i=n(5694),a=n(1469),o=r?r.isConcatSpreadable:void 0;t.exports=function(t){return a(t)||i(t)||!!(o&&t&&t[o])}},5776:t=>{var e=/^(?:0|[1-9]\d*)$/;t.exports=function(t,n){var r=typeof t;return!!(n=null==n?9007199254740991:n)&&("number"==r||"symbol"!=r&&e.test(t))&&t>-1&&t%1==0&&t<n}},6612:(t,e,n)=>{var r=n(7813),i=n(8612),a=n(5776),o=n(3218);t.exports=function(t,e,n){if(!o(n))return!1;var s=typeof e;return!!("number"==s?i(n)&&a(e,n.length):"string"==s&&e in n)&&r(n[e],t)}},5403:(t,e,n)=>{var r=n(1469),i=n(3448),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,o=/^\w*$/;t.exports=function(t,e){if(r(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!i(t))||o.test(t)||!a.test(t)||null!=e&&t in Object(e)}},7019:t=>{t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},5346:(t,e,n)=>{var r,i=n(4429),a=(r=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";t.exports=function(t){return!!a&&a in t}},5726:t=>{var e=Object.prototype;t.exports=function(t){var n=t&&t.constructor;return t===("function"==typeof n&&n.prototype||e)}},9162:(t,e,n)=>{var r=n(3218);t.exports=function(t){return t==t&&!r(t)}},7040:t=>{t.exports=function(){this.__data__=[],this.size=0}},4125:(t,e,n)=>{var r=n(8470),i=Array.prototype.splice;t.exports=function(t){var e=this.__data__,n=r(e,t);return!(n<0||(n==e.length-1?e.pop():i.call(e,n,1),--this.size,0))}},2117:(t,e,n)=>{var r=n(8470);t.exports=function(t){var e=this.__data__,n=r(e,t);return n<0?void 0:e[n][1]}},7518:(t,e,n)=>{var r=n(8470);t.exports=function(t){return r(this.__data__,t)>-1}},4705:(t,e,n)=>{var r=n(8470);t.exports=function(t,e){var n=this.__data__,i=r(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this}},4785:(t,e,n)=>{var r=n(1989),i=n(8407),a=n(7071);t.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||i),string:new r}}},1285:(t,e,n)=>{var r=n(5050);t.exports=function(t){var e=r(this,t).delete(t);return this.size-=e?1:0,e}},6e3:(t,e,n)=>{var r=n(5050);t.exports=function(t){return r(this,t).get(t)}},9916:(t,e,n)=>{var r=n(5050);t.exports=function(t){return r(this,t).has(t)}},5265:(t,e,n)=>{var r=n(5050);t.exports=function(t,e){var n=r(this,t),i=n.size;return n.set(t,e),this.size+=n.size==i?0:1,this}},8776:t=>{t.exports=function(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}},2634:t=>{t.exports=function(t,e){return function(n){return null!=n&&n[t]===e&&(void 0!==e||t in Object(n))}}},4523:(t,e,n)=>{var r=n(8306);t.exports=function(t){var e=r(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}},4536:(t,e,n)=>{var r=n(852)(Object,"create");t.exports=r},6916:(t,e,n)=>{var r=n(5569)(Object.keys,Object);t.exports=r},3498:t=>{t.exports=function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}},1167:(t,e,n)=>{t=n.nmd(t);var r=n(1957),i=e&&!e.nodeType&&e,a=i&&t&&!t.nodeType&&t,o=a&&a.exports===i&&r.process,s=function(){try{return a&&a.require&&a.require("util").types||o&&o.binding&&o.binding("util")}catch(t){}}();t.exports=s},2333:t=>{var e=Object.prototype.toString;t.exports=function(t){return e.call(t)}},5569:t=>{t.exports=function(t,e){return function(n){return t(e(n))}}},5357:(t,e,n)=>{var r=n(6874),i=Math.max;t.exports=function(t,e,n){return e=i(void 0===e?t.length-1:e,0),function(){for(var a=arguments,o=-1,s=i(a.length-e,0),c=Array(s);++o<s;)c[o]=a[e+o];o=-1;for(var u=Array(e+1);++o<e;)u[o]=a[o];return u[e]=n(c),r(t,this,u)}}},5639:(t,e,n)=>{var r=n(1957),i="object"==typeof self&&self&&self.Object===Object&&self,a=r||i||Function("return this")();t.exports=a},6390:t=>{t.exports=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}},619:t=>{t.exports=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this}},2385:t=>{t.exports=function(t){return this.__data__.has(t)}},1814:t=>{t.exports=function(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}},61:(t,e,n)=>{var r=n(6560),i=n(1275)(r);t.exports=i},1275:t=>{var e=Date.now;t.exports=function(t){var n=0,r=0;return function(){var i=e(),a=16-(i-r);if(r=i,a>0){if(++n>=800)return arguments[0]}else n=0;return t.apply(void 0,arguments)}}},7465:(t,e,n)=>{var r=n(8407);t.exports=function(){this.__data__=new r,this.size=0}},3779:t=>{t.exports=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}},7599:t=>{t.exports=function(t){return this.__data__.get(t)}},4758:t=>{t.exports=function(t){return this.__data__.has(t)}},4309:(t,e,n)=>{var r=n(8407),i=n(7071),a=n(3369);t.exports=function(t,e){var n=this.__data__;if(n instanceof r){var o=n.__data__;if(!i||o.length<199)return o.push([t,e]),this.size=++n.size,this;n=this.__data__=new a(o)}return n.set(t,e),this.size=n.size,this}},2351:t=>{t.exports=function(t,e,n){for(var r=n-1,i=t.length;++r<i;)if(t[r]===e)return r;return-1}},8016:(t,e,n)=>{var r=n(8983),i=n(2689),a=n(1903);t.exports=function(t){return i(t)?a(t):r(t)}},5514:(t,e,n)=>{var r=n(4523),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,o=r((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(i,(function(t,n,r,i){e.push(r?i.replace(a,"$1"):n||t)})),e}));t.exports=o},327:(t,e,n)=>{var r=n(3448);t.exports=function(t){if("string"==typeof t||r(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},346:t=>{var e=Function.prototype.toString;t.exports=function(t){if(null!=t){try{return e.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},7990:t=>{var e=/\s/;t.exports=function(t){for(var n=t.length;n--&&e.test(t.charAt(n)););return n}},1903:t=>{var e="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",n="\\ud83c[\\udffb-\\udfff]",r="[^\\ud800-\\udfff]",i="(?:\\ud83c[\\udde6-\\uddff]){2}",a="[\\ud800-\\udbff][\\udc00-\\udfff]",o="(?:"+e+"|"+n+")?",s="[\\ufe0e\\ufe0f]?",c=s+o+"(?:\\u200d(?:"+[r,i,a].join("|")+")"+s+o+")*",u="(?:"+[r+e+"?",e,i,a,"[\\ud800-\\udfff]"].join("|")+")",l=RegExp(n+"(?="+n+")|"+u+c,"g");t.exports=function(t){for(var e=l.lastIndex=0;l.test(t);)++e;return e}},6678:(t,e,n)=>{var r=n(5990);t.exports=function(t){return r(t,4)}},361:(t,e,n)=>{var r=n(5990);t.exports=function(t){return r(t,5)}},5703:t=>{t.exports=function(t){return function(){return t}}},1747:(t,e,n)=>{var r=n(5976),i=n(7813),a=n(6612),o=n(1704),s=Object.prototype,c=s.hasOwnProperty,u=r((function(t,e){t=Object(t);var n=-1,r=e.length,u=r>2?e[2]:void 0;for(u&&a(e[0],e[1],u)&&(r=1);++n<r;)for(var l=e[n],f=o(l),h=-1,d=f.length;++h<d;){var p=f[h],g=t[p];(void 0===g||i(g,s[p])&&!c.call(t,p))&&(t[p]=l[p])}return t}));t.exports=u},6073:(t,e,n)=>{t.exports=n(4486)},7813:t=>{t.exports=function(t,e){return t===e||t!=t&&e!=e}},3105:(t,e,n)=>{var r=n(4963),i=n(760),a=n(7206),o=n(1469);t.exports=function(t,e){return(o(t)?r:i)(t,a(e,3))}},3311:(t,e,n)=>{var r=n(7740)(n(998));t.exports=r},998:(t,e,n)=>{var r=n(1848),i=n(7206),a=n(554),o=Math.max;t.exports=function(t,e,n){var s=null==t?0:t.length;if(!s)return-1;var c=null==n?0:a(n);return c<0&&(c=o(s+c,0)),r(t,i(e,3),c)}},5564:(t,e,n)=>{var r=n(1078);t.exports=function(t){return null!=t&&t.length?r(t,1):[]}},4486:(t,e,n)=>{var r=n(7412),i=n(9881),a=n(4290),o=n(1469);t.exports=function(t,e){return(o(t)?r:i)(t,a(e))}},2620:(t,e,n)=>{var r=n(8483),i=n(4290),a=n(1704);t.exports=function(t,e){return null==t?t:r(t,i(e),a)}},7361:(t,e,n)=>{var r=n(7786);t.exports=function(t,e,n){var i=null==t?void 0:r(t,e);return void 0===i?n:i}},8721:(t,e,n)=>{var r=n(8565),i=n(222);t.exports=function(t,e){return null!=t&&i(t,e,r)}},9095:(t,e,n)=>{var r=n(13),i=n(222);t.exports=function(t,e){return null!=t&&i(t,e,r)}},6557:t=>{t.exports=function(t){return t}},5694:(t,e,n)=>{var r=n(9454),i=n(7005),a=Object.prototype,o=a.hasOwnProperty,s=a.propertyIsEnumerable,c=r(function(){return arguments}())?r:function(t){return i(t)&&o.call(t,"callee")&&!s.call(t,"callee")};t.exports=c},1469:t=>{var e=Array.isArray;t.exports=e},8612:(t,e,n)=>{var r=n(3560),i=n(1780);t.exports=function(t){return null!=t&&i(t.length)&&!r(t)}},9246:(t,e,n)=>{var r=n(8612),i=n(7005);t.exports=function(t){return i(t)&&r(t)}},4144:(t,e,n)=>{t=n.nmd(t);var r=n(5639),i=n(5062),a=e&&!e.nodeType&&e,o=a&&t&&!t.nodeType&&t,s=o&&o.exports===a?r.Buffer:void 0,c=(s?s.isBuffer:void 0)||i;t.exports=c},1609:(t,e,n)=>{var r=n(280),i=n(4160),a=n(5694),o=n(1469),s=n(8612),c=n(4144),u=n(5726),l=n(6719),f=Object.prototype.hasOwnProperty;t.exports=function(t){if(null==t)return!0;if(s(t)&&(o(t)||"string"==typeof t||"function"==typeof t.splice||c(t)||l(t)||a(t)))return!t.length;var e=i(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if(u(t))return!r(t).length;for(var n in t)if(f.call(t,n))return!1;return!0}},3560:(t,e,n)=>{var r=n(4239),i=n(3218);t.exports=function(t){if(!i(t))return!1;var e=r(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},1780:t=>{t.exports=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},6688:(t,e,n)=>{var r=n(5588),i=n(1717),a=n(1167),o=a&&a.isMap,s=o?i(o):r;t.exports=s},3218:t=>{t.exports=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},7005:t=>{t.exports=function(t){return null!=t&&"object"==typeof t}},8630:(t,e,n)=>{var r=n(4239),i=n(5924),a=n(7005),o=Function.prototype,s=Object.prototype,c=o.toString,u=s.hasOwnProperty,l=c.call(Object);t.exports=function(t){if(!a(t)||"[object Object]"!=r(t))return!1;var e=i(t);if(null===e)return!0;var n=u.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&c.call(n)==l}},2928:(t,e,n)=>{var r=n(9221),i=n(1717),a=n(1167),o=a&&a.isSet,s=o?i(o):r;t.exports=s},7037:(t,e,n)=>{var r=n(4239),i=n(1469),a=n(7005);t.exports=function(t){return"string"==typeof t||!i(t)&&a(t)&&"[object String]"==r(t)}},3448:(t,e,n)=>{var r=n(4239),i=n(7005);t.exports=function(t){return"symbol"==typeof t||i(t)&&"[object Symbol]"==r(t)}},6719:(t,e,n)=>{var r=n(8749),i=n(1717),a=n(1167),o=a&&a.isTypedArray,s=o?i(o):r;t.exports=s},2353:t=>{t.exports=function(t){return void 0===t}},3674:(t,e,n)=>{var r=n(4636),i=n(280),a=n(8612);t.exports=function(t){return a(t)?r(t):i(t)}},1704:(t,e,n)=>{var r=n(4636),i=n(313),a=n(8612);t.exports=function(t){return a(t)?r(t,!0):i(t)}},928:t=>{t.exports=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}},5161:(t,e,n)=>{var r=n(9932),i=n(7206),a=n(9199),o=n(1469);t.exports=function(t,e){return(o(t)?r:a)(t,i(e,3))}},6604:(t,e,n)=>{var r=n(9465),i=n(7816),a=n(7206);t.exports=function(t,e){var n={};return e=a(e,3),i(t,(function(t,i,a){r(n,i,e(t,i,a))})),n}},6162:(t,e,n)=>{var r=n(6029),i=n(3325),a=n(6557);t.exports=function(t){return t&&t.length?r(t,a,i):void 0}},8306:(t,e,n)=>{var r=n(3369);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var o=t.apply(this,r);return n.cache=a.set(i,o)||a,o};return n.cache=new(i.Cache||r),n}i.Cache=r,t.exports=i},3857:(t,e,n)=>{var r=n(2980),i=n(1463)((function(t,e,n){r(t,e,n)}));t.exports=i},3632:(t,e,n)=>{var r=n(6029),i=n(433),a=n(6557);t.exports=function(t){return t&&t.length?r(t,a,i):void 0}},2762:(t,e,n)=>{var r=n(6029),i=n(7206),a=n(433);t.exports=function(t,e){return t&&t.length?r(t,i(e,2),a):void 0}},308:t=>{t.exports=function(){}},7771:(t,e,n)=>{var r=n(5639);t.exports=function(){return r.Date.now()}},9722:(t,e,n)=>{var r=n(5970),i=n(9021)((function(t,e){return null==t?{}:r(t,e)}));t.exports=i},9601:(t,e,n)=>{var r=n(371),i=n(9152),a=n(5403),o=n(327);t.exports=function(t){return a(t)?r(o(t)):i(t)}},6026:(t,e,n)=>{var r=n(7445)();t.exports=r},4061:(t,e,n)=>{var r=n(2663),i=n(9881),a=n(7206),o=n(107),s=n(1469);t.exports=function(t,e,n){var c=s(t)?r:o,u=arguments.length<3;return c(t,a(e,4),n,u,i)}},4238:(t,e,n)=>{var r=n(280),i=n(4160),a=n(8612),o=n(7037),s=n(8016);t.exports=function(t){if(null==t)return 0;if(a(t))return o(t)?s(t):t.length;var e=i(t);return"[object Map]"==e||"[object Set]"==e?t.size:r(t).length}},9734:(t,e,n)=>{var r=n(1078),i=n(9556),a=n(5976),o=n(6612),s=a((function(t,e){if(null==t)return[];var n=e.length;return n>1&&o(t,e[0],e[1])?e=[]:n>2&&o(e[0],e[1],e[2])&&(e=[e[0]]),i(t,r(e,1),[])}));t.exports=s},479:t=>{t.exports=function(){return[]}},5062:t=>{t.exports=function(){return!1}},8601:(t,e,n)=>{var r=n(4841);t.exports=function(t){return t?Infinity===(t=r(t))||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},554:(t,e,n)=>{var r=n(8601);t.exports=function(t){var e=r(t),n=e%1;return e==e?n?e-n:e:0}},4841:(t,e,n)=>{var r=n(7561),i=n(3218),a=n(3448),o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,c=/^0o[0-7]+$/i,u=parseInt;t.exports=function(t){if("number"==typeof t)return t;if(a(t))return NaN;if(i(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=i(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=r(t);var n=s.test(t);return n||c.test(t)?u(t.slice(2),n?2:8):o.test(t)?NaN:+t}},3678:(t,e,n)=>{var r=n(8363),i=n(1704);t.exports=function(t){return r(t,i(t))}},9833:(t,e,n)=>{var r=n(531);t.exports=function(t){return null==t?"":r(t)}},8718:(t,e,n)=>{var r=n(7412),i=n(3118),a=n(7816),o=n(7206),s=n(5924),c=n(1469),u=n(4144),l=n(3560),f=n(3218),h=n(6719);t.exports=function(t,e,n){var d=c(t),p=d||u(t)||h(t);if(e=o(e,4),null==n){var g=t&&t.constructor;n=p?d?new g:[]:f(t)&&l(g)?i(s(t)):{}}return(p?r:a)(t,(function(t,r,i){return e(n,t,r,i)})),n}},3386:(t,e,n)=>{var r=n(1078),i=n(5976),a=n(5652),o=n(9246),s=i((function(t){return a(r(t,1,o,!0))}));t.exports=s},3955:(t,e,n)=>{var r=n(9833),i=0;t.exports=function(t){var e=++i;return r(t)+e}},2628:(t,e,n)=>{var r=n(7415),i=n(3674);t.exports=function(t){return null==t?[]:r(t,i(t))}},7287:(t,e,n)=>{var r=n(4865),i=n(1757);t.exports=function(t,e){return i(t||[],e||[],r)}},1140:function(t,e,n){var r;"undefined"!=typeof self&&self,r=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="./src/mermaid.js")}({"./node_modules/node-libs-browser/mock/empty.js":function(t,e){},"./node_modules/path-browserify/index.js":function(t,e,n){(function(t){function n(t,e){for(var n=0,r=t.length-1;r>=0;r--){var i=t[r];"."===i?t.splice(r,1):".."===i?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r<t.length;r++)e(t[r],r,t)&&n.push(t[r]);return n}e.resolve=function(){for(var e="",i=!1,a=arguments.length-1;a>=-1&&!i;a--){var o=a>=0?arguments[a]:t.cwd();if("string"!=typeof o)throw new TypeError("Arguments to path.resolve must be strings");o&&(e=o+"/"+e,i="/"===o.charAt(0))}return(i?"/":"")+(e=n(r(e.split("/"),(function(t){return!!t})),!i).join("/"))||"."},e.normalize=function(t){var a=e.isAbsolute(t),o="/"===i(t,-1);return(t=n(r(t.split("/"),(function(t){return!!t})),!a).join("/"))||a||(t="."),t&&o&&(t+="/"),(a?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,(function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t})).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e<t.length&&""===t[e];e++);for(var n=t.length-1;n>=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var i=r(t.split("/")),a=r(n.split("/")),o=Math.min(i.length,a.length),s=o,c=0;c<o;c++)if(i[c]!==a[c]){s=c;break}var u=[];for(c=s;c<i.length;c++)u.push("..");return(u=u.concat(a.slice(s))).join("/")},e.sep="/",e.delimiter=":",e.dirname=function(t){if("string"!=typeof t&&(t+=""),0===t.length)return".";for(var e=t.charCodeAt(0),n=47===e,r=-1,i=!0,a=t.length-1;a>=1;--a)if(47===(e=t.charCodeAt(a))){if(!i){r=a;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":t.slice(0,r)},e.basename=function(t,e){var n=function(t){"string"!=typeof t&&(t+="");var e,n=0,r=-1,i=!0;for(e=t.length-1;e>=0;--e)if(47===t.charCodeAt(e)){if(!i){n=e+1;break}}else-1===r&&(i=!1,r=e+1);return-1===r?"":t.slice(n,r)}(t);return e&&n.substr(-1*e.length)===e&&(n=n.substr(0,n.length-e.length)),n},e.extname=function(t){"string"!=typeof t&&(t+="");for(var e=-1,n=0,r=-1,i=!0,a=0,o=t.length-1;o>=0;--o){var s=t.charCodeAt(o);if(47!==s)-1===r&&(i=!1,r=o+1),46===s?-1===e?e=o:1!==a&&(a=1):-1!==e&&(a=-1);else if(!i){n=o+1;break}}return-1===e||-1===r||0===a||1===a&&e===r-1&&e===n+1?"":t.slice(e,r)};var i=function(t,e,n){return t.substr(e,n)}}).call(this,n("./node_modules/process/browser.js"))},"./node_modules/process/browser.js":function(t,e){var n,r,i=t.exports={};function a(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(t){if(n===setTimeout)return setTimeout(t,0);if((n===a||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:a}catch(t){n=a}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(t){r=o}}();var c,u=[],l=!1,f=-1;function h(){l&&c&&(l=!1,c.length?u=c.concat(u):f=-1,u.length&&d())}function d(){if(!l){var t=s(h);l=!0;for(var e=u.length;e;){for(c=u,u=[];++f<e;)c&&c[f].run();f=-1,e=u.length}c=null,l=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===o||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function p(t,e){this.fun=t,this.array=e}function g(){}i.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];u.push(new p(t,e)),1!==u.length||l||s(d)},p.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=g,i.addListener=g,i.once=g,i.off=g,i.removeListener=g,i.removeAllListeners=g,i.emit=g,i.prependListener=g,i.prependOnceListener=g,i.listeners=function(t){return[]},i.binding=function(t){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(t){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},"./node_modules/webpack/buildin/module.js":function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},"./package.json":function(t){t.exports=JSON.parse('{"name":"mermaid","version":"8.13.2","description":"Markdownish syntax for generating flowcharts, sequence diagrams, class diagrams, gantt charts and git graphs.","main":"dist/mermaid.core.js","keywords":["diagram","markdown","flowchart","sequence diagram","gantt","class diagram","git graph"],"scripts":{"build:development":"webpack --progress --color","build:production":"yarn build:development --mode production --config webpack.config.prod.babel.js","build":"yarn build:development && yarn build:production","postbuild":"documentation build src/mermaidAPI.js src/config.js src/defaultConfig.js --shallow -f md --markdown-toc false > docs/Setup.md","build:watch":"yarn build --watch","release":"yarn build","lint":"eslint src","e2e:depr":"yarn lint && jest e2e --config e2e/jest.config.js","cypress":"percy exec -- cypress run","e2e":"start-server-and-test dev http://localhost:9000/ cypress","e2e-upd":"yarn lint && jest e2e -u --config e2e/jest.config.js","dev":"webpack serve --config webpack.config.e2e.js","test":"yarn lint && jest src/.*","test:watch":"jest --watch src","prepublishOnly":"yarn build && yarn test","prepare":"yarn build"},"repository":{"type":"git","url":"https://github.com/knsv/mermaid"},"author":"Knut Sveidqvist","license":"MIT","standard":{"ignore":["**/parser/*.js","dist/**/*.js","cypress/**/*.js"],"globals":["page"]},"dependencies":{"@braintree/sanitize-url":"^3.1.0","d3":"^7.0.0","dagre":"^0.8.5","dagre-d3":"^0.6.4","dompurify":"2.3.1","graphlib":"^2.1.8","khroma":"^1.4.1","moment-mini":"^2.24.0","stylis":"^4.0.10"},"devDependencies":{"@babel/core":"^7.14.6","@babel/eslint-parser":"^7.14.7","@babel/preset-env":"^7.14.7","@babel/register":"^7.14.5","@percy/cli":"^1.0.0-beta.58","@percy/cypress":"^3.1.0","@percy/migrate":"^0.11.0","babel-jest":"^27.0.6","babel-loader":"^8.2.2","coveralls":"^3.0.2","css-to-string-loader":"^0.1.3","cypress":"8.1.0","documentation":"13.2.0","eslint":"^7.30.0","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.4.0","husky":"^7.0.1","identity-obj-proxy":"^3.0.0","jest":"^27.0.6","jison":"^0.4.18","js-base64":"3.6.1","moment":"^2.23.0","prettier":"^2.3.2","start-server-and-test":"^1.12.6","terser-webpack-plugin":"^4.2.3","webpack":"^4.41.2","webpack-cli":"^4.7.2","webpack-dev-server":"^3.4.1","webpack-node-externals":"^3.0.0"},"files":["dist"],"sideEffects":["**/*.css","**/*.scss"],"husky":{"hooks":{"pre-push":"yarn test"}}}')},"./src/config.js":function(t,e,n){"use strict";n.r(e),n.d(e,"defaultConfig",(function(){return u})),n.d(e,"updateCurrentConfig",(function(){return d})),n.d(e,"setSiteConfig",(function(){return p})),n.d(e,"saveConfigFromInitilize",(function(){return g})),n.d(e,"updateSiteConfig",(function(){return y})),n.d(e,"getSiteConfig",(function(){return m})),n.d(e,"setConfig",(function(){return v})),n.d(e,"getConfig",(function(){return b})),n.d(e,"sanitize",(function(){return _})),n.d(e,"addDirective",(function(){return x})),n.d(e,"reset",(function(){return w}));var r=n("./src/utils.js"),i=n("./src/logger.js"),a=n("./src/themes/index.js"),o=n("./src/defaultConfig.js");function s(t){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s(t)}var c,u=Object.freeze(o.default),l=Object(r.assignWithDepth)({},u),f=[],h=Object(r.assignWithDepth)({},u),d=function(t,e){for(var n=Object(r.assignWithDepth)({},t),i={},o=0;o<e.length;o++){var s=e[o];_(s),i=Object(r.assignWithDepth)(i,s)}if(n=Object(r.assignWithDepth)(n,i),i.theme){var u=Object(r.assignWithDepth)({},c),l=Object(r.assignWithDepth)(u.themeVariables||{},i.themeVariables);n.themeVariables=a.default[n.theme].getThemeVariables(l)}return h=n,n},p=function(t){return l=Object(r.assignWithDepth)({},u),l=Object(r.assignWithDepth)(l,t),t.theme&&(l.themeVariables=a.default[t.theme].getThemeVariables(t.themeVariables)),h=d(l,f),l},g=function(t){c=Object(r.assignWithDepth)({},t)},y=function(t){return l=Object(r.assignWithDepth)(l,t),d(l,f),l},m=function(){return Object(r.assignWithDepth)({},l)},v=function(t){return Object(r.assignWithDepth)(h,t),b()},b=function(){return Object(r.assignWithDepth)({},h)},_=function t(e){Object.keys(l.secure).forEach((function(t){void 0!==e[l.secure[t]]&&(i.log.debug("Denied attempt to modify a secure key ".concat(l.secure[t]),e[l.secure[t]]),delete e[l.secure[t]])})),Object.keys(e).forEach((function(t){0===t.indexOf("__")&&delete e[t]})),Object.keys(e).forEach((function(n){"string"==typeof e[n]&&(e[n].indexOf("<")>-1||e[n].indexOf(">")>-1||e[n].indexOf("url(data:")>-1)&&delete e[n],"object"===s(e[n])&&t(e[n])}))},x=function(t){t.fontFamily&&(t.themeVariables&&t.themeVariables.fontFamily||(t.themeVariables={fontFamily:t.fontFamily})),f.push(t),d(l,f)},w=function(){d(l,f=[])}},"./src/dagre-wrapper/clusters.js":function(t,e,n){"use strict";n.r(e),n.d(e,"insertCluster",(function(){return f})),n.d(e,"getClusterTitleWidth",(function(){return h})),n.d(e,"clear",(function(){return d})),n.d(e,"positionCluster",(function(){return p}));var r=n("./src/dagre-wrapper/intersect/intersect-rect.js"),i=n("./src/logger.js"),a=n("./src/dagre-wrapper/createLabel.js"),o=n("d3"),s=n("./src/config.js"),c=n("./src/diagrams/common/common.js"),u={rect:function(t,e){i.log.trace("Creating subgraph rect for ",e.id,e);var n=t.insert("g").attr("class","cluster"+(e.class?" "+e.class:"")).attr("id",e.id),u=n.insert("rect",":first-child"),l=n.insert("g").attr("class","cluster-label"),f=l.node().appendChild(Object(a.default)(e.labelText,e.labelStyle,void 0,!0)),h=f.getBBox();if(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)){var d=f.children[0],p=Object(o.select)(f);h=d.getBoundingClientRect(),p.attr("width",h.width),p.attr("height",h.height)}var g=0*e.padding,y=g/2,m=e.width<=h.width+g?h.width+g:e.width;e.width<=h.width+g?e.diff=(h.width-e.width)/2:e.diff=-e.padding/2,i.log.trace("Data ",e,JSON.stringify(e)),u.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-m/2).attr("y",e.y-e.height/2-y).attr("width",m).attr("height",e.height+g),l.attr("transform","translate("+(e.x-h.width/2)+", "+(e.y-e.height/2+e.padding/3)+")");var v=u.node().getBBox();return e.width=v.width,e.height=v.height,e.intersect=function(t){return Object(r.default)(e,t)},n},roundedWithTitle:function(t,e){var n=t.insert("g").attr("class",e.classes).attr("id",e.id),i=n.insert("rect",":first-child"),u=n.insert("g").attr("class","cluster-label"),l=n.append("rect"),f=u.node().appendChild(Object(a.default)(e.labelText,e.labelStyle,void 0,!0)),h=f.getBBox();if(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)){var d=f.children[0],p=Object(o.select)(f);h=d.getBoundingClientRect(),p.attr("width",h.width),p.attr("height",h.height)}h=f.getBBox();var g=0*e.padding,y=g/2,m=e.width<=h.width+e.padding?h.width+e.padding:e.width;e.width<=h.width+e.padding?e.diff=(h.width+0*e.padding-e.width)/2:e.diff=-e.padding/2,i.attr("class","outer").attr("x",e.x-m/2-y).attr("y",e.y-e.height/2-y).attr("width",m+g).attr("height",e.height+g),l.attr("class","inner").attr("x",e.x-m/2-y).attr("y",e.y-e.height/2-y+h.height-1).attr("width",m+g).attr("height",e.height+g-h.height-3),u.attr("transform","translate("+(e.x-h.width/2)+", "+(e.y-e.height/2-e.padding/3+(Object(c.evaluate)(Object(s.getConfig)().flowchart.htmlLabels)?5:3))+")");var v=i.node().getBBox();return e.height=v.height,e.intersect=function(t){return Object(r.default)(e,t)},n},noteGroup:function(t,e){var n=t.insert("g").attr("class","note-cluster").attr("id",e.id),i=n.insert("rect",":first-child"),a=0*e.padding,o=a/2;i.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2-o).attr("width",e.width+a).attr("height",e.height+a).attr("fill","none");var s=i.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(t){return Object(r.default)(e,t)},n},divider:function(t,e){var n=t.insert("g").attr("class",e.classes).attr("id",e.id),i=n.insert("rect",":first-child"),a=0*e.padding,o=a/2;i.attr("class","divider").attr("x",e.x-e.width/2-o).attr("y",e.y-e.height/2).attr("width",e.width+a).attr("height",e.height+a);var s=i.node().getBBox();return e.width=s.width,e.height=s.height,e.diff=-e.padding/2,e.intersect=function(t){return Object(r.default)(e,t)},n}},l={},f=function(t,e){i.log.trace("Inserting cluster");var n=e.shape||"rect";l[e.id]=u[n](t,e)},h=function(t,e){var n=Object(a.default)(e.labelText,e.labelStyle,void 0,!0);t.node().appendChild(n);var r=n.getBBox().width;return t.node().removeChild(n),r},d=function(){l={}},p=function(t){i.log.info("Position cluster ("+t.id+", "+t.x+", "+t.y+")"),l[t.id].attr("transform","translate("+t.x+", "+t.y+")")}},"./src/dagre-wrapper/createLabel.js":function(t,e,n){"use strict";n.r(e);var r=n("d3"),i=n("./src/logger.js"),a=n("./src/diagrams/common/common.js"),o=n("./src/config.js");function s(t){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},s(t)}e.default=function(t,e,n,c){var u,l,f,h,d,p,g=t||"";if("object"===s(g)&&(g=g[0]),Object(a.evaluate)(Object(o.getConfig)().flowchart.htmlLabels))return g=g.replace(/\\n|\n/g,"<br />"),i.log.info("vertexText"+g),u={isNode:c,label:g.replace(/fa[lrsb]?:fa-[\w-]+/g,(function(t){return"<i class='".concat(t.replace(":"," "),"'></i>")})),labelStyle:e.replace("fill:","color:")},f=Object(r.select)(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),h=f.append("xhtml:div"),d=u.label,p=u.isNode?"nodeLabel":"edgeLabel",h.html('<span class="'+p+'" '+(u.labelStyle?'style="'+u.labelStyle+'"':"")+">"+d+"</span>"),(l=u.labelStyle)&&h.attr("style",l),h.style("display","inline-block"),h.style("white-space","nowrap"),h.attr("xmlns","http://www.w3.org/1999/xhtml"),f.node();var y=document.createElementNS("http://www.w3.org/2000/svg","text");y.setAttribute("style",e.replace("color:","fill:"));var m=[];m="string"==typeof g?g.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(g)?g:[];for(var v=0;v<m.length;v++){var b=document.createElementNS("http://www.w3.org/2000/svg","tspan");b.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),b.setAttribute("dy","1em"),b.setAttribute("x","0"),n?b.setAttribute("class","title-row"):b.setAttribute("class","row"),b.textContent=m[v].trim(),y.appendChild(b)}return y}},"./src/dagre-wrapper/edges.js":function(t,e,n){"use strict";n.r(e),n.d(e,"clear",(function(){return f})),n.d(e,"insertEdgeLabel",(function(){return h})),n.d(e,"positionEdgeLabel",(function(){return p})),n.d(e,"intersection",(function(){return g})),n.d(e,"insertEdge",(function(){return m}));var r=n("./src/logger.js"),i=n("./src/dagre-wrapper/createLabel.js"),a=n("d3"),o=n("./src/config.js"),s=n("./src/utils.js"),c=n("./src/diagrams/common/common.js"),u={},l={},f=function(){u={},l={}},h=function(t,e){var n=Object(i.default)(e.label,e.labelStyle),r=t.insert("g").attr("class","edgeLabel"),s=r.insert("g").attr("class","label");s.node().appendChild(n);var f,h=n.getBBox();if(Object(c.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var p=n.children[0],g=Object(a.select)(n);h=p.getBoundingClientRect(),g.attr("width",h.width),g.attr("height",h.height)}if(s.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"),u[e.id]=r,e.width=h.width,e.height=h.height,e.startLabelLeft){var y=Object(i.default)(e.startLabelLeft,e.labelStyle),m=t.insert("g").attr("class","edgeTerminals"),v=m.insert("g").attr("class","inner");f=v.node().appendChild(y);var b=y.getBBox();v.attr("transform","translate("+-b.width/2+", "+-b.height/2+")"),l[e.id]||(l[e.id]={}),l[e.id].startLeft=m,d(f,e.startLabelLeft)}if(e.startLabelRight){var _=Object(i.default)(e.startLabelRight,e.labelStyle),x=t.insert("g").attr("class","edgeTerminals"),w=x.insert("g").attr("class","inner");f=x.node().appendChild(_),w.node().appendChild(_);var k=_.getBBox();w.attr("transform","translate("+-k.width/2+", "+-k.height/2+")"),l[e.id]||(l[e.id]={}),l[e.id].startRight=x,d(f,e.startLabelRight)}if(e.endLabelLeft){var T=Object(i.default)(e.endLabelLeft,e.labelStyle),E=t.insert("g").attr("class","edgeTerminals"),C=E.insert("g").attr("class","inner");f=C.node().appendChild(T);var S=T.getBBox();C.attr("transform","translate("+-S.width/2+", "+-S.height/2+")"),E.node().appendChild(T),l[e.id]||(l[e.id]={}),l[e.id].endLeft=E,d(f,e.endLabelLeft)}if(e.endLabelRight){var M=Object(i.default)(e.endLabelRight,e.labelStyle),A=t.insert("g").attr("class","edgeTerminals"),O=A.insert("g").attr("class","inner");f=O.node().appendChild(M);var N=M.getBBox();O.attr("transform","translate("+-N.width/2+", "+-N.height/2+")"),A.node().appendChild(M),l[e.id]||(l[e.id]={}),l[e.id].endRight=A,d(f,e.endLabelRight)}};function d(t,e){Object(o.getConfig)().flowchart.htmlLabels&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}var p=function(t,e){r.log.info("Moving label abc78 ",t.id,t.label,u[t.id]);var n=e.updatedPath?e.updatedPath:e.originalPath;if(t.label){var i=u[t.id],a=t.x,o=t.y;if(n){var c=s.default.calcLabelPosition(n);r.log.info("Moving label from (",a,",",o,") to (",c.x,",",c.y,") abc78")}i.attr("transform","translate("+a+", "+o+")")}if(t.startLabelLeft){var f=l[t.id].startLeft,h=t.x,d=t.y;if(n){var p=s.default.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",n);h=p.x,d=p.y}f.attr("transform","translate("+h+", "+d+")")}if(t.startLabelRight){var g=l[t.id].startRight,y=t.x,m=t.y;if(n){var v=s.default.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",n);y=v.x,m=v.y}g.attr("transform","translate("+y+", "+m+")")}if(t.endLabelLeft){var b=l[t.id].endLeft,_=t.x,x=t.y;if(n){var w=s.default.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",n);_=w.x,x=w.y}b.attr("transform","translate("+_+", "+x+")")}if(t.endLabelRight){var k=l[t.id].endRight,T=t.x,E=t.y;if(n){var C=s.default.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",n);T=C.x,E=C.y}k.attr("transform","translate("+T+", "+E+")")}},g=function(t,e,n){r.log.warn("intersection calc abc89:\n outsidePoint: ".concat(JSON.stringify(e),"\n insidePoint : ").concat(JSON.stringify(n),"\n node : x:").concat(t.x," y:").concat(t.y," w:").concat(t.width," h:").concat(t.height));var i=t.x,a=t.y,o=Math.abs(i-n.x),s=t.width/2,c=n.x<e.x?s-o:s+o,u=t.height/2,l=Math.abs(e.y-n.y),f=Math.abs(e.x-n.x);if(Math.abs(a-e.y)*s>Math.abs(i-e.x)*u){var h=n.y<e.y?e.y-u-a:a-u-e.y;c=f*h/l;var d={x:n.x<e.x?n.x+c:n.x-f+c,y:n.y<e.y?n.y+l-h:n.y-l+h};return 0===c&&(d.x=e.x,d.y=e.y),0===f&&(d.x=e.x),0===l&&(d.y=e.y),r.log.warn("abc89 topp/bott calc, Q ".concat(l,", q ").concat(h,", R ").concat(f,", r ").concat(c),d),d}var p=l*(c=n.x<e.x?e.x-s-i:i-s-e.x)/f,g=n.x<e.x?n.x+f-c:n.x-f+c,y=n.y<e.y?n.y+p:n.y-p;return r.log.warn("sides calc abc89, Q ".concat(l,", q ").concat(p,", R ").concat(f,", r ").concat(c),{_x:g,_y:y}),0===c&&(g=e.x,y=e.y),0===f&&(g=e.x),0===l&&(y=e.y),{x:g,y}},y=function(t,e){r.log.warn("abc88 cutPathAtIntersect",t,e);var n=[],i=t[0],a=!1;return t.forEach((function(t){if(r.log.info("abc88 checking point",t,e),function(t,e){var n=t.x,r=t.y,i=Math.abs(e.x-n),a=Math.abs(e.y-r),o=t.width/2,s=t.height/2;return i>=o||a>=s}(e,t)||a)r.log.warn("abc88 outside",t,i),i=t,a||n.push(t);else{var o=g(e,i,t);r.log.warn("abc88 inside",t,i,o),r.log.warn("abc88 intersection",o);var s=!1;n.forEach((function(t){s=s||t.x===o.x&&t.y===o.y})),n.find((function(t){return t.x===o.x&&t.y===o.y}))?r.log.warn("abc88 no intersect",o,n):n.push(o),a=!0}})),r.log.warn("abc88 returning points",n),n},m=function(t,e,n,i,s,c){var u=n.points,l=!1,f=c.node(e.v),h=c.node(e.w);r.log.info("abc88 InsertEdge: ",n),h.intersect&&f.intersect&&((u=u.slice(1,n.points.length-1)).unshift(f.intersect(u[0])),r.log.info("Last point",u[u.length-1],h,h.intersect(u[u.length-1])),u.push(h.intersect(u[u.length-1]))),n.toCluster&&(r.log.info("to cluster abc88",i[n.toCluster]),u=y(n.points,i[n.toCluster].node),l=!0),n.fromCluster&&(r.log.info("from cluster abc88",i[n.fromCluster]),u=y(u.reverse(),i[n.fromCluster].node).reverse(),l=!0);var d,p=u.filter((function(t){return!Number.isNaN(t.y)}));d=("graph"===s||"flowchart"===s)&&n.curve||a.curveBasis;var g,m=Object(a.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(d);switch(n.thickness){case"normal":g="edge-thickness-normal";break;case"thick":g="edge-thickness-thick";break;default:g=""}switch(n.pattern){case"solid":g+=" edge-pattern-solid";break;case"dotted":g+=" edge-pattern-dotted";break;case"dashed":g+=" edge-pattern-dashed"}var v=t.append("path").attr("d",m(p)).attr("id",n.id).attr("class"," "+g+(n.classes?" "+n.classes:"")).attr("style",n.style),b="";switch(Object(o.getConfig)().state.arrowMarkerAbsolute&&(b=(b=(b=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),r.log.info("arrowTypeStart",n.arrowTypeStart),r.log.info("arrowTypeEnd",n.arrowTypeEnd),n.arrowTypeStart){case"arrow_cross":v.attr("marker-start","url("+b+"#"+s+"-crossStart)");break;case"arrow_point":v.attr("marker-start","url("+b+"#"+s+"-pointStart)");break;case"arrow_barb":v.attr("marker-start","url("+b+"#"+s+"-barbStart)");break;case"arrow_circle":v.attr("marker-start","url("+b+"#"+s+"-circleStart)");break;case"aggregation":v.attr("marker-start","url("+b+"#"+s+"-aggregationStart)");break;case"extension":v.attr("marker-start","url("+b+"#"+s+"-extensionStart)");break;case"composition":v.attr("marker-start","url("+b+"#"+s+"-compositionStart)");break;case"dependency":v.attr("marker-start","url("+b+"#"+s+"-dependencyStart)")}switch(n.arrowTypeEnd){case"arrow_cross":v.attr("marker-end","url("+b+"#"+s+"-crossEnd)");break;case"arrow_point":v.attr("marker-end","url("+b+"#"+s+"-pointEnd)");break;case"arrow_barb":v.attr("marker-end","url("+b+"#"+s+"-barbEnd)");break;case"arrow_circle":v.attr("marker-end","url("+b+"#"+s+"-circleEnd)");break;case"aggregation":v.attr("marker-end","url("+b+"#"+s+"-aggregationEnd)");break;case"extension":v.attr("marker-end","url("+b+"#"+s+"-extensionEnd)");break;case"composition":v.attr("marker-end","url("+b+"#"+s+"-compositionEnd)");break;case"dependency":v.attr("marker-end","url("+b+"#"+s+"-dependencyEnd)")}var _={};return l&&(_.updatedPath=u),_.originalPath=n.points,_}},"./src/dagre-wrapper/index.js":function(t,e,n){"use strict";n.r(e),n.d(e,"render",(function(){return g}));var r=n("dagre"),i=n.n(r),a=n("graphlib"),o=n.n(a),s=n("./src/dagre-wrapper/markers.js"),c=n("./src/dagre-wrapper/shapes/util.js"),u=n("./src/dagre-wrapper/mermaid-graphlib.js"),l=n("./src/dagre-wrapper/nodes.js"),f=n("./src/dagre-wrapper/clusters.js"),h=n("./src/dagre-wrapper/edges.js"),d=n("./src/logger.js"),p=function t(e,n,r,a){d.log.info("Graph in recursive render: XXX",o.a.json.write(n),a);var s=n.graph().rankdir;d.log.trace("Dir in recursive render - dir:",s);var p=e.insert("g").attr("class","root");n.nodes()?d.log.info("Recursive render XXX",n.nodes()):d.log.info("No nodes found for",n),n.edges().length>0&&d.log.trace("Recursive edges",n.edge(n.edges()[0]));var g=p.insert("g").attr("class","clusters"),y=p.insert("g").attr("class","edgePaths"),m=p.insert("g").attr("class","edgeLabels"),v=p.insert("g").attr("class","nodes");n.nodes().forEach((function(e){var i=n.node(e);if(void 0!==a){var o=JSON.parse(JSON.stringify(a.clusterData));d.log.info("Setting data for cluster XXX (",e,") ",o,a),n.setNode(a.id,o),n.parent(e)||(d.log.trace("Setting parent",e,a.id),n.setParent(e,a.id,o))}if(d.log.info("(Insert) Node XXX"+e+": "+JSON.stringify(n.node(e))),i&&i.clusterNode){d.log.info("Cluster identified",e,i.width,n.node(e));var f=t(v,i.graph,r,n.node(e)),h=f.elem;Object(c.updateNodeBounds)(i,h),i.diff=f.diff||0,d.log.info("Node bounds (abc123)",e,i,i.width,i.x,i.y),Object(l.setNodeElem)(h,i),d.log.warn("Recursive render complete ",h,i)}else n.children(e).length>0?(d.log.info("Cluster - the non recursive path XXX",e,i.id,i,n),d.log.info(Object(u.findNonClusterChild)(i.id,n)),u.clusterDb[i.id]={id:Object(u.findNonClusterChild)(i.id,n),node:i}):(d.log.info("Node - the non recursive path",e,i.id,i),Object(l.insertNode)(v,n.node(e),s))})),n.edges().forEach((function(t){var e=n.edge(t.v,t.w,t.name);d.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t)),d.log.info("Edge "+t.v+" -> "+t.w+": ",t," ",JSON.stringify(n.edge(t))),d.log.info("Fix",u.clusterDb,"ids:",t.v,t.w,"Translateing: ",u.clusterDb[t.v],u.clusterDb[t.w]),Object(h.insertEdgeLabel)(m,e)})),n.edges().forEach((function(t){d.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t))})),d.log.info("#############################################"),d.log.info("### Layout ###"),d.log.info("#############################################"),d.log.info(n),i.a.layout(n),d.log.info("Graph after layout:",o.a.json.write(n));var b=0;return Object(u.sortNodesByHierarchy)(n).forEach((function(t){var e=n.node(t);d.log.info("Position "+t+": "+JSON.stringify(n.node(t))),d.log.info("Position "+t+": ("+e.x,","+e.y,") width: ",e.width," height: ",e.height),e&&e.clusterNode?Object(l.positionNode)(e):n.children(t).length>0?(Object(f.insertCluster)(g,e),u.clusterDb[e.id].node=e):Object(l.positionNode)(e)})),n.edges().forEach((function(t){var e=n.edge(t);d.log.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(e),e);var i=Object(h.insertEdge)(y,t,e,u.clusterDb,r,n);Object(h.positionEdgeLabel)(e,i)})),n.nodes().forEach((function(t){var e=n.node(t);d.log.info(t,e.type,e.diff),"group"===e.type&&(b=e.diff)})),{elem:p,diff:b}},g=function(t,e,n,r,i){Object(s.default)(t,n,r,i),Object(l.clear)(),Object(h.clear)(),Object(f.clear)(),Object(u.clear)(),d.log.warn("Graph at first:",o.a.json.write(e)),Object(u.adjustClustersAndEdges)(e),d.log.warn("Graph after:",o.a.json.write(e)),p(t,e,r)}},"./src/dagre-wrapper/intersect/index.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-node.js"),i=n.n(r),a=n("./src/dagre-wrapper/intersect/intersect-circle.js"),o=n("./src/dagre-wrapper/intersect/intersect-ellipse.js"),s=n("./src/dagre-wrapper/intersect/intersect-polygon.js"),c=n("./src/dagre-wrapper/intersect/intersect-rect.js");e.default={node:i.a,circle:a.default,ellipse:o.default,polygon:s.default,rect:c.default}},"./src/dagre-wrapper/intersect/intersect-circle.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-ellipse.js");e.default=function(t,e,n){return Object(r.default)(t,e,e,n)}},"./src/dagre-wrapper/intersect/intersect-ellipse.js":function(t,e,n){"use strict";n.r(e),e.default=function(t,e,n,r){var i=t.x,a=t.y,o=i-r.x,s=a-r.y,c=Math.sqrt(e*e*s*s+n*n*o*o),u=Math.abs(e*n*o/c);r.x<i&&(u=-u);var l=Math.abs(e*n*s/c);return r.y<a&&(l=-l),{x:i+u,y:a+l}}},"./src/dagre-wrapper/intersect/intersect-line.js":function(t,e,n){"use strict";function r(t,e){return t*e>0}n.r(e),e.default=function(t,e,n,i){var a,o,s,c,u,l,f,h,d,p,g,y,m;if(a=e.y-t.y,s=t.x-e.x,u=e.x*t.y-t.x*e.y,d=a*n.x+s*n.y+u,p=a*i.x+s*i.y+u,!(0!==d&&0!==p&&r(d,p)||(o=i.y-n.y,c=n.x-i.x,l=i.x*n.y-n.x*i.y,f=o*t.x+c*t.y+l,h=o*e.x+c*e.y+l,0!==f&&0!==h&&r(f,h)||0==(g=a*c-o*s))))return y=Math.abs(g/2),{x:(m=s*l-c*u)<0?(m-y)/g:(m+y)/g,y:(m=o*u-a*l)<0?(m-y)/g:(m+y)/g}}},"./src/dagre-wrapper/intersect/intersect-node.js":function(t,e){t.exports=function(t,e){return t.intersect(e)}},"./src/dagre-wrapper/intersect/intersect-polygon.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/dagre-wrapper/intersect/intersect-line.js");e.default=function(t,e,n){var i=t.x,a=t.y,o=[],s=Number.POSITIVE_INFINITY,c=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach((function(t){s=Math.min(s,t.x),c=Math.min(c,t.y)})):(s=Math.min(s,e.x),c=Math.min(c,e.y));for(var u=i-t.width/2-s,l=a-t.height/2-c,f=0;f<e.length;f++){var h=e[f],d=e[f<e.length-1?f+1:0],p=Object(r.default)(t,n,{x:u+h.x,y:l+h.y},{x:u+d.x,y:l+d.y});p&&o.push(p)}return o.length?(o.length>1&&o.sort((function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),o=e.x-n.x,s=e.y-n.y,c=Math.sqrt(o*o+s*s);return a<c?-1:a===c?0:1})),o[0]):t}},"./src/dagre-wrapper/intersect/intersect-rect.js":function(t,e,n){"use strict";n.r(e),e.default=function(t,e){var n,r,i=t.x,a=t.y,o=e.x-i,s=e.y-a,c=t.width/2,u=t.height/2;return Math.abs(s)*c>Math.abs(o)*u?(s<0&&(u=-u),n=0===s?0:u*o/s,r=u):(o<0&&(c=-c),n=c,r=0===o?0:c*s/o),{x:i+n,y:a+r}}},"./src/dagre-wrapper/markers.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/logger.js"),i={extension:function(t,e,n){r.log.trace("Making markers for ",n),t.append("defs").append("marker").attr("id",e+"-extensionStart").attr("class","marker extension "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},composition:function(t,e){t.append("defs").append("marker").attr("id",e+"-compositionStart").attr("class","marker composition "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},aggregation:function(t,e){t.append("defs").append("marker").attr("id",e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},dependency:function(t,e){t.append("defs").append("marker").attr("id",e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},point:function(t,e){t.append("marker").attr("id",e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",0).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},circle:function(t,e){t.append("marker").attr("id",e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},cross:function(t,e){t.append("marker").attr("id",e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),t.append("marker").attr("id",e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},barb:function(t,e){t.append("defs").append("marker").attr("id",e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")}};e.default=function(t,e,n,r){e.forEach((function(e){i[e](t,n,r)}))}},"./src/dagre-wrapper/mermaid-graphlib.js":function(t,e,n){"use strict";n.r(e),n.d(e,"clusterDb",(function(){return o})),n.d(e,"clear",(function(){return u})),n.d(e,"extractDecendants",(function(){return h})),n.d(e,"validate",(function(){return d})),n.d(e,"findNonClusterChild",(function(){return p})),n.d(e,"adjustClustersAndEdges",(function(){return y})),n.d(e,"extractor",(function(){return m})),n.d(e,"sortNodesByHierarchy",(function(){return b}));var r=n("./src/logger.js"),i=n("graphlib"),a=n.n(i),o={},s={},c={},u=function(){s={},c={},o={}},l=function(t,e){return r.log.trace("In isDecendant",e," ",t," = ",s[e].indexOf(t)>=0),s[e].indexOf(t)>=0},f=function t(e,n,i,a){r.log.warn("Copying children of ",e,"root",a,"data",n.node(e),a);var o=n.children(e)||[];e!==a&&o.push(e),r.log.warn("Copying (nodes) clusterId",e,"nodes",o),o.forEach((function(o){if(n.children(o).length>0)t(o,n,i,a);else{var c=n.node(o);r.log.info("cp ",o," to ",a," with parent ",e),i.setNode(o,c),a!==n.parent(o)&&(r.log.warn("Setting parent",o,n.parent(o)),i.setParent(o,n.parent(o))),e!==a&&o!==e?(r.log.debug("Setting parent",o,e),i.setParent(o,e)):(r.log.info("In copy ",e,"root",a,"data",n.node(e),a),r.log.debug("Not Setting parent for node=",o,"cluster!==rootId",e!==a,"node!==clusterId",o!==e));var u=n.edges(o);r.log.debug("Copying Edges",u),u.forEach((function(t){r.log.info("Edge",t);var o=n.edge(t.v,t.w,t.name);r.log.info("Edge data",o,a);try{!function(t,e){return r.log.info("Decendants of ",e," is ",s[e]),r.log.info("Edge is ",t),t.v!==e&&t.w!==e&&(s[e]?(r.log.info("Here "),s[e].indexOf(t.v)>=0||!!l(t.v,e)||!!l(t.w,e)||s[e].indexOf(t.w)>=0):(r.log.debug("Tilt, ",e,",not in decendants"),!1))}(t,a)?r.log.info("Skipping copy of edge ",t.v,"--\x3e",t.w," rootId: ",a," clusterId:",e):(r.log.info("Copying as ",t.v,t.w,o,t.name),i.setEdge(t.v,t.w,o,t.name),r.log.info("newGraph edges ",i.edges(),i.edge(i.edges()[0])))}catch(t){r.log.error(t)}}))}r.log.debug("Removing node",o),n.removeNode(o)}))},h=function t(e,n){for(var r=n.children(e),i=[].concat(r),a=0;a<r.length;a++)c[r[a]]=e,i=i.concat(t(r[a],n));return i},d=function(t){var e=t.edges();r.log.trace("Edges: ",e);for(var n=0;n<e.length;n++){if(t.children(e[n].v).length>0)return r.log.trace("The node ",e[n].v," is part of and edge even though it has children"),!1;if(t.children(e[n].w).length>0)return r.log.trace("The node ",e[n].w," is part of and edge even though it has children"),!1}return!0},p=function t(e,n){r.log.trace("Searching",e);var i=n.children(e);if(r.log.trace("Searching children of id ",e,i),i.length<1)return r.log.trace("This is a valid node",e),e;for(var a=0;a<i.length;a++){var o=t(i[a],n);if(o)return r.log.trace("Found replacement for",e," => ",o),o}},g=function(t){return o[t]&&o[t].externalConnections&&o[t]?o[t].id:t},y=function(t,e){!t||e>10?r.log.debug("Opting out, no graph "):(r.log.debug("Opting in, graph "),t.nodes().forEach((function(e){t.children(e).length>0&&(r.log.warn("Cluster identified",e," Replacement id in edges: ",p(e,t)),s[e]=h(e,t),o[e]={id:p(e,t),clusterData:t.node(e)})})),t.nodes().forEach((function(e){var n=t.children(e),i=t.edges();n.length>0?(r.log.debug("Cluster identified",e,s),i.forEach((function(t){t.v!==e&&t.w!==e&&l(t.v,e)^l(t.w,e)&&(r.log.warn("Edge: ",t," leaves cluster ",e),r.log.warn("Decendants of XXX ",e,": ",s[e]),o[e].externalConnections=!0)}))):r.log.debug("Not a cluster ",e,s)})),t.edges().forEach((function(e){var n=t.edge(e);r.log.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(e)),r.log.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(t.edge(e)));var i=e.v,a=e.w;r.log.warn("Fix XXX",o,"ids:",e.v,e.w,"Translateing: ",o[e.v]," --- ",o[e.w]),(o[e.v]||o[e.w])&&(r.log.warn("Fixing and trixing - removing XXX",e.v,e.w,e.name),i=g(e.v),a=g(e.w),t.removeEdge(e.v,e.w,e.name),i!==e.v&&(n.fromCluster=e.v),a!==e.w&&(n.toCluster=e.w),r.log.warn("Fix Replacing with XXX",i,a,e.name),t.setEdge(i,a,n,e.name))})),r.log.warn("Adjusted Graph",a.a.json.write(t)),m(t,0),r.log.trace(o))},m=function t(e,n){if(r.log.warn("extractor - ",n,a.a.json.write(e),e.children("D")),n>10)r.log.error("Bailing out");else{for(var i=e.nodes(),s=!1,c=0;c<i.length;c++){var u=i[c],l=e.children(u);s=s||l.length>0}if(s){r.log.debug("Nodes = ",i,n);for(var h=0;h<i.length;h++){var d=i[h];if(r.log.debug("Extracting node",d,o,o[d]&&!o[d].externalConnections,!e.parent(d),e.node(d),e.children("D")," Depth ",n),o[d])if(!o[d].externalConnections&&e.children(d)&&e.children(d).length>0){r.log.warn("Cluster without external connections, without a parent and with children",d,n);var p="TB"===e.graph().rankdir?"LR":"TB";o[d]&&o[d].clusterData&&o[d].clusterData.dir&&(p=o[d].clusterData.dir,r.log.warn("Fixing dir",o[d].clusterData.dir,p));var g=new a.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:p,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}}));r.log.warn("Old graph before copy",a.a.json.write(e)),f(d,e,g,d),e.setNode(d,{clusterNode:!0,id:d,clusterData:o[d].clusterData,labelText:o[d].labelText,graph:g}),r.log.warn("New graph after copy node: (",d,")",a.a.json.write(g)),r.log.debug("Old graph after copy",a.a.json.write(e))}else r.log.warn("Cluster ** ",d," **not meeting the criteria !externalConnections:",!o[d].externalConnections," no parent: ",!e.parent(d)," children ",e.children(d)&&e.children(d).length>0,e.children("D"),n),r.log.debug(o);else r.log.debug("Not a cluster",d,n)}i=e.nodes(),r.log.warn("New list of nodes",i);for(var y=0;y<i.length;y++){var m=i[y],v=e.node(m);r.log.warn(" Now next level",m,v),v.clusterNode&&t(v.graph,n+1)}}else r.log.debug("Done, no node has children",e.nodes())}},v=function t(e,n){if(0===n.length)return[];var r=Object.assign(n);return n.forEach((function(n){var i=e.children(n),a=t(e,i);r=r.concat(a)})),r},b=function(t){return v(t,t.children())}},"./src/dagre-wrapper/nodes.js":function(t,e,n){"use strict";n.r(e),n.d(e,"insertNode",(function(){return y})),n.d(e,"setNodeElem",(function(){return m})),n.d(e,"clear",(function(){return v})),n.d(e,"positionNode",(function(){return b}));var r=n("d3"),i=n("./src/logger.js"),a=n("./src/dagre-wrapper/shapes/util.js"),o=n("./src/config.js"),s=n("./src/dagre-wrapper/intersect/index.js"),c=n("./src/dagre-wrapper/createLabel.js"),u=n("./src/dagre-wrapper/shapes/note.js"),l=n("./src/diagrams/class/svgDraw.js"),f=n("./src/diagrams/common/common.js");function h(t){return h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},h(t)}var d=function(t,e,n){var r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),i=70,o=10;"LR"===n&&(i=10,o=70);var c=r.append("rect").attr("x",-1*i/2).attr("y",-1*o/2).attr("width",i).attr("height",o).attr("class","fork-join");return Object(a.updateNodeBounds)(e,c),e.height=e.height+e.padding/2,e.width=e.width+e.padding/2,e.intersect=function(t){return s.default.rect(e,t)},r},p={question:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,o=n.bbox,c=o.width+e.padding+(o.height+e.padding),u=[{x:c/2,y:0},{x:c,y:-c/2},{x:c/2,y:-c},{x:0,y:-c/2}];i.log.info("Question main (Circle)");var l=Object(a.insertPolygonShape)(r,c,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return i.log.warn("Intersect called"),s.default.polygon(e,u,t)},r},rect:function(t,e){var n=Object(a.labelHelper)(t,e,"node "+e.classes,!0),r=n.shapeSvg,o=n.bbox,c=n.halfPadding;i.log.trace("Classes = ",e.classes);var u=r.insert("rect",":first-child");return u.attr("class","basic label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",-o.width/2-c).attr("y",-o.height/2-c).attr("width",o.width+e.padding).attr("height",o.height+e.padding),Object(a.updateNodeBounds)(e,u),e.intersect=function(t){return s.default.rect(e,t)},r},rectWithTitle:function(t,e){var n;n=e.classes?"node "+e.classes:"node default";var u,l=t.insert("g").attr("class",n).attr("id",e.domId||e.id),d=l.insert("rect",":first-child"),p=l.insert("line"),g=l.insert("g").attr("class","label"),y=e.labelText.flat?e.labelText.flat():e.labelText;u="object"===h(y)?y[0]:y,i.log.info("Label text abc79",u,y,"object"===h(y));var m=g.node().appendChild(Object(c.default)(u,e.labelStyle,!0,!0)),v={width:0,height:0};if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var b=m.children[0],_=Object(r.select)(m);v=b.getBoundingClientRect(),_.attr("width",v.width),_.attr("height",v.height)}i.log.info("Text 2",y);var x=y.slice(1,y.length),w=m.getBBox(),k=g.node().appendChild(Object(c.default)(x.join?x.join("<br/>"):x,e.labelStyle,!0,!0));if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var T=k.children[0],E=Object(r.select)(k);v=T.getBoundingClientRect(),E.attr("width",v.width),E.attr("height",v.height)}var C=e.padding/2;return Object(r.select)(k).attr("transform","translate( "+(v.width>w.width?0:(w.width-v.width)/2)+", "+(w.height+C+5)+")"),Object(r.select)(m).attr("transform","translate( "+(v.width<w.width?0:-(w.width-v.width)/2)+", 0)"),v=g.node().getBBox(),g.attr("transform","translate("+-v.width/2+", "+(-v.height/2-C+3)+")"),d.attr("class","outer title-state").attr("x",-v.width/2-C).attr("y",-v.height/2-C).attr("width",v.width+e.padding).attr("height",v.height+e.padding),p.attr("class","divider").attr("x1",-v.width/2-C).attr("x2",v.width/2+C).attr("y1",-v.height/2-C+w.height+C).attr("y2",-v.height/2-C+w.height+C),Object(a.updateNodeBounds)(e,d),e.intersect=function(t){return s.default.rect(e,t)},l},choice:function(t,e){var n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);return n.insert("polygon",":first-child").attr("points",[{x:0,y:14},{x:14,y:0},{x:0,y:-14},{x:-14,y:0}].map((function(t){return t.x+","+t.y})).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),e.width=28,e.height=28,e.intersect=function(t){return s.default.circle(e,14,t)},n},circle:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,o=n.bbox,c=n.halfPadding,u=r.insert("circle",":first-child");return u.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",o.width/2+c).attr("width",o.width+e.padding).attr("height",o.height+e.padding),i.log.info("Circle main"),Object(a.updateNodeBounds)(e,u),e.intersect=function(t){return i.log.info("Circle intersect",e,o.width/2+c,t),s.default.circle(e,o.width/2+c,t)},r},stadium:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.height+e.padding,c=i.width+o/4+e.padding,u=r.insert("rect",":first-child").attr("style",e.style).attr("rx",o/2).attr("ry",o/2).attr("x",-c/2).attr("y",-o/2).attr("width",c).attr("height",o);return Object(a.updateNodeBounds)(e,u),e.intersect=function(t){return s.default.rect(e,t)},r},hexagon:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.height+e.padding,c=o/4,u=i.width+2*c+e.padding,l=[{x:c,y:0},{x:u-c,y:0},{x:u,y:-o/2},{x:u-c,y:-o},{x:c,y:-o},{x:0,y:-o/2}],f=Object(a.insertPolygonShape)(r,u,o,l);return f.attr("style",e.style),Object(a.updateNodeBounds)(e,f),e.intersect=function(t){return s.default.polygon(e,l,t)},r},rect_left_inv_arrow:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:-c/2,y:0},{x:o,y:0},{x:o,y:-c},{x:-c/2,y:-c},{x:0,y:-c/2}];return Object(a.insertPolygonShape)(r,o,c,u).attr("style",e.style),e.width=o+c,e.height=c,e.intersect=function(t){return s.default.polygon(e,u,t)},r},lean_right:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:-2*c/6,y:0},{x:o-c/6,y:0},{x:o+2*c/6,y:-c},{x:c/6,y:-c}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},lean_left:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:2*c/6,y:0},{x:o+c/6,y:0},{x:o-2*c/6,y:-c},{x:-c/6,y:-c}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},trapezoid:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:-2*c/6,y:0},{x:o+2*c/6,y:0},{x:o-c/6,y:-c},{x:c/6,y:-c}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},inv_trapezoid:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:c/6,y:0},{x:o-c/6,y:0},{x:o+2*c/6,y:-c},{x:-2*c/6,y:-c}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},rect_right_inv_arrow:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:0,y:0},{x:o+c/2,y:0},{x:o,y:-c/2},{x:o+c/2,y:-c},{x:0,y:-c}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},cylinder:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=o/2,u=c/(2.5+o/50),l=i.height+u+e.padding,f="M 0,"+u+" a "+c+","+u+" 0,0,0 "+o+" 0 a "+c+","+u+" 0,0,0 "+-o+" 0 l 0,"+l+" a "+c+","+u+" 0,0,0 "+o+" 0 l 0,"+-l,h=r.attr("label-offset-y",u).insert("path",":first-child").attr("style",e.style).attr("d",f).attr("transform","translate("+-o/2+","+-(l/2+u)+")");return Object(a.updateNodeBounds)(e,h),e.intersect=function(t){var n=s.default.rect(e,t),r=n.x-e.x;if(0!=c&&(Math.abs(r)<e.width/2||Math.abs(r)==e.width/2&&Math.abs(n.y-e.y)>e.height/2-u)){var i=u*u*(1-r*r/(c*c));0!=i&&(i=Math.sqrt(i)),i=u-i,t.y-e.y>0&&(i=-i),n.y+=i}return n},r},start:function(t,e){var n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child");return r.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),Object(a.updateNodeBounds)(e,r),e.intersect=function(t){return s.default.circle(e,7,t)},n},end:function(t,e){var n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child"),i=n.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),r.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),Object(a.updateNodeBounds)(e,i),e.intersect=function(t){return s.default.circle(e,7,t)},n},note:u.default,subroutine:function(t,e){var n=Object(a.labelHelper)(t,e,void 0,!0),r=n.shapeSvg,i=n.bbox,o=i.width+e.padding,c=i.height+e.padding,u=[{x:0,y:0},{x:o,y:0},{x:o,y:-c},{x:0,y:-c},{x:0,y:0},{x:-8,y:0},{x:o+8,y:0},{x:o+8,y:-c},{x:-8,y:-c},{x:-8,y:0}],l=Object(a.insertPolygonShape)(r,o,c,u);return l.attr("style",e.style),Object(a.updateNodeBounds)(e,l),e.intersect=function(t){return s.default.polygon(e,u,t)},r},fork:d,join:d,class_box:function(t,e){var n,i=e.padding/2;n=e.classes?"node "+e.classes:"node default";var u=t.insert("g").attr("class",n).attr("id",e.domId||e.id),h=u.insert("rect",":first-child"),d=u.insert("line"),p=u.insert("line"),g=0,y=4,m=u.insert("g").attr("class","label"),v=0,b=e.classData.annotations&&e.classData.annotations[0],_=e.classData.annotations[0]?"«"+e.classData.annotations[0]+"»":"",x=m.node().appendChild(Object(c.default)(_,e.labelStyle,!0,!0)),w=x.getBBox();if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var k=x.children[0],T=Object(r.select)(x);w=k.getBoundingClientRect(),T.attr("width",w.width),T.attr("height",w.height)}e.classData.annotations[0]&&(y+=w.height+4,g+=w.width);var E=e.classData.id;void 0!==e.classData.type&&""!==e.classData.type&&(Object(o.getConfig)().flowchart.htmlLabels?E+="&lt;"+e.classData.type+"&gt;":E+="<"+e.classData.type+">");var C=m.node().appendChild(Object(c.default)(E,e.labelStyle,!0,!0));Object(r.select)(C).attr("class","classTitle");var S=C.getBBox();if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var M=C.children[0],A=Object(r.select)(C);S=M.getBoundingClientRect(),A.attr("width",S.width),A.attr("height",S.height)}y+=S.height+4,S.width>g&&(g=S.width);var O=[];e.classData.members.forEach((function(t){var n=Object(l.parseMember)(t),i=n.displayText;Object(o.getConfig)().flowchart.htmlLabels&&(i=i.replace(/</g,"&lt;").replace(/>/g,"&gt;"));var a=m.node().appendChild(Object(c.default)(i,n.cssStyle?n.cssStyle:e.labelStyle,!0,!0)),s=a.getBBox();if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var u=a.children[0],h=Object(r.select)(a);s=u.getBoundingClientRect(),h.attr("width",s.width),h.attr("height",s.height)}s.width>g&&(g=s.width),y+=s.height+4,O.push(a)})),y+=8;var N=[];if(e.classData.methods.forEach((function(t){var n=Object(l.parseMember)(t),i=n.displayText;Object(o.getConfig)().flowchart.htmlLabels&&(i=i.replace(/</g,"&lt;").replace(/>/g,"&gt;"));var a=m.node().appendChild(Object(c.default)(i,n.cssStyle?n.cssStyle:e.labelStyle,!0,!0)),s=a.getBBox();if(Object(f.evaluate)(Object(o.getConfig)().flowchart.htmlLabels)){var u=a.children[0],h=Object(r.select)(a);s=u.getBoundingClientRect(),h.attr("width",s.width),h.attr("height",s.height)}s.width>g&&(g=s.width),y+=s.height+4,N.push(a)})),y+=8,b){var j=(g-w.width)/2;Object(r.select)(x).attr("transform","translate( "+(-1*g/2+j)+", "+-1*y/2+")"),v=w.height+4}var D=(g-S.width)/2;return Object(r.select)(C).attr("transform","translate( "+(-1*g/2+D)+", "+(-1*y/2+v)+")"),v+=S.height+4,d.attr("class","divider").attr("x1",-g/2-i).attr("x2",g/2+i).attr("y1",-y/2-i+8+v).attr("y2",-y/2-i+8+v),v+=8,O.forEach((function(t){Object(r.select)(t).attr("transform","translate( "+-g/2+", "+(-1*y/2+v+4)+")"),v+=S.height+4})),v+=8,p.attr("class","divider").attr("x1",-g/2-i).attr("x2",g/2+i).attr("y1",-y/2-i+8+v).attr("y2",-y/2-i+8+v),v+=8,N.forEach((function(t){Object(r.select)(t).attr("transform","translate( "+-g/2+", "+(-1*y/2+v)+")"),v+=S.height+4})),h.attr("class","outer title-state").attr("x",-g/2-i).attr("y",-y/2-i).attr("width",g+e.padding).attr("height",y+e.padding),Object(a.updateNodeBounds)(e,h),e.intersect=function(t){return s.default.rect(e,t)},u}},g={},y=function(t,e,n){var r,i;e.link?(r=t.insert("svg:a").attr("xlink:href",e.link).attr("target",e.linkTarget||"_blank"),i=p[e.shape](r,e,n)):r=i=p[e.shape](t,e,n),e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),g[e.id]=r,e.haveCallback&&g[e.id].attr("class",g[e.id].attr("class")+" clickable")},m=function(t,e){g[e.id]=t},v=function(){g={}},b=function(t){var e=g[t.id];i.log.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");var n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n}},"./src/dagre-wrapper/shapes/note.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/dagre-wrapper/shapes/util.js"),i=n("./src/logger.js"),a=n("./src/dagre-wrapper/intersect/index.js");e.default=function(t,e){var n=Object(r.labelHelper)(t,e,"node "+e.classes,!0),o=n.shapeSvg,s=n.bbox,c=n.halfPadding;i.log.info("Classes = ",e.classes);var u=o.insert("rect",":first-child");return u.attr("rx",e.rx).attr("ry",e.ry).attr("x",-s.width/2-c).attr("y",-s.height/2-c).attr("width",s.width+e.padding).attr("height",s.height+e.padding),Object(r.updateNodeBounds)(e,u),e.intersect=function(t){return a.default.rect(e,t)},o}},"./src/dagre-wrapper/shapes/util.js":function(t,e,n){"use strict";n.r(e),n.d(e,"labelHelper",(function(){return s})),n.d(e,"updateNodeBounds",(function(){return c})),n.d(e,"insertPolygonShape",(function(){return u}));var r=n("./src/dagre-wrapper/createLabel.js"),i=n("./src/config.js"),a=n("d3"),o=n("./src/diagrams/common/common.js"),s=function(t,e,n,s){var c;c=n||"node default";var u=t.insert("g").attr("class",c).attr("id",e.domId||e.id),l=u.insert("g").attr("class","label").attr("style",e.labelStyle),f=l.node().appendChild(Object(r.default)(e.labelText,e.labelStyle,!1,s)),h=f.getBBox();if(Object(o.evaluate)(Object(i.getConfig)().flowchart.htmlLabels)){var d=f.children[0],p=Object(a.select)(f);h=d.getBoundingClientRect(),p.attr("width",h.width),p.attr("height",h.height)}var g=e.padding/2;return l.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"),{shapeSvg:u,bbox:h,halfPadding:g,label:l}},c=function(t,e){var n=e.node().getBBox();t.width=n.width,t.height=n.height};function u(t,e,n,r){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+n/2+")")}},"./src/defaultConfig.js":function(t,e,n){"use strict";function r(t){return function(t){if(Array.isArray(t))return i(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return i(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?i(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}n.r(e),n.d(e,"configKeys",(function(){return s}));var o={theme:"default",themeVariables:n("./src/themes/index.js").default.default.getThemeVariables(),themeCSS:void 0,maxTextSize:5e4,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize"],deterministicIds:!1,deterministicIDSeed:void 0,flowchart:{diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,useMaxWidth:!0,defaultRenderer:"dagre-d3"},sequence:{activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open-Sans", "sans-serif"',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20,messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},noteFont:function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},actorFont:function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}}},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",useMaxWidth:!0,topAxis:!1,useWidth:void 0},journey:{diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open-Sans", "sans-serif"',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"]},class:{arrowMarkerAbsolute:!1,useMaxWidth:!0,defaultRenderer:"dagre-wrapper"},git:{arrowMarkerAbsolute:!1,useWidth:void 0,useMaxWidth:!0},state:{dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,useMaxWidth:!0,defaultRenderer:"dagre-wrapper"},er:{diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,stroke:"gray",fill:"honeydew",fontSize:12,useMaxWidth:!0},pie:{useWidth:void 0,useMaxWidth:!0},requirement:{useWidth:void 0,useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20}};o.class.arrowMarkerAbsolute=o.arrowMarkerAbsolute,o.git.arrowMarkerAbsolute=o.arrowMarkerAbsolute;var s=function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object.keys(e).reduce((function(i,o){return Array.isArray(e[o])?i:"object"===a(e[o])&&null!==e[o]?[].concat(r(i),[n+o],r(t(e[o],""))):[].concat(r(i),[n+o])}),[])}(o,"");e.default=o},"./src/diagrams/class/classDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return g})),n.d(e,"addClass",(function(){return m})),n.d(e,"lookUpDomId",(function(){return v})),n.d(e,"clear",(function(){return b})),n.d(e,"getClass",(function(){return _})),n.d(e,"getClasses",(function(){return x})),n.d(e,"getRelations",(function(){return w})),n.d(e,"addRelation",(function(){return k})),n.d(e,"addAnnotation",(function(){return T})),n.d(e,"addMember",(function(){return E})),n.d(e,"addMembers",(function(){return C})),n.d(e,"cleanupLabel",(function(){return S})),n.d(e,"setCssClass",(function(){return M})),n.d(e,"setLink",(function(){return A})),n.d(e,"setClickEvent",(function(){return O})),n.d(e,"bindFunctions",(function(){return j})),n.d(e,"lineType",(function(){return D})),n.d(e,"relationType",(function(){return B}));var r=n("d3"),i=n("./src/logger.js"),a=n("./src/config.js"),o=n("./src/diagrams/common/common.js"),s=n("./src/utils.js"),c=n("./src/mermaidAPI.js");function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var l="classid-",f=[],h={},d=0,p=[],g=function(t,e,n){c.default.parseDirective(this,t,e,n)},y=function(t){var e="",n=t;if(t.indexOf("~")>0){var r=t.split("~");n=r[0],e=r[1]}return{className:n,type:e}},m=function(t){var e=y(t);void 0===h[e.className]&&(h[e.className]={id:e.className,type:e.type,cssClasses:[],methods:[],members:[],annotations:[],domId:l+e.className+"-"+d},d++)},v=function(t){for(var e=Object.keys(h),n=0;n<e.length;n++)if(h[e[n]].id===t)return h[e[n]].domId},b=function(){f=[],h={},(p=[]).push(L)},_=function(t){return h[t]},x=function(){return h},w=function(){return f},k=function(t){i.log.debug("Adding relation: "+JSON.stringify(t)),m(t.id1),m(t.id2),t.id1=y(t.id1).className,t.id2=y(t.id2).className,f.push(t)},T=function(t,e){var n=y(t).className;h[n].annotations.push(e)},E=function(t,e){var n=y(t).className,r=h[n];if("string"==typeof e){var i=e.trim();i.startsWith("<<")&&i.endsWith(">>")?r.annotations.push(i.substring(2,i.length-2)):i.indexOf(")")>0?r.methods.push(i):i&&r.members.push(i)}},C=function(t,e){Array.isArray(e)&&(e.reverse(),e.forEach((function(e){return E(t,e)})))},S=function(t){return":"===t.substring(0,1)?t.substr(1).trim():t.trim()},M=function(t,e){t.split(",").forEach((function(t){var n=t;t[0].match(/\d/)&&(n=l+n),void 0!==h[n]&&h[n].cssClasses.push(e)}))},A=function(t,e,n){var r=a.getConfig();t.split(",").forEach((function(t){var i=t;t[0].match(/\d/)&&(i=l+i),void 0!==h[i]&&(h[i].link=s.default.formatUrl(e,r),h[i].linkTarget="string"==typeof n?n:"_blank")})),M(t,"clickable")},O=function(t,e,n){t.split(",").forEach((function(t){N(t,e,n),h[t].haveCallback=!0})),M(t,"clickable")},N=function(t,e,n){var r=a.getConfig(),i=t,o=v(i);if("loose"===r.securityLevel&&void 0!==e&&void 0!==h[i]){var c=[];if("string"==typeof n){c=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(var l=0;l<c.length;l++){var f=c[l].trim();'"'===f.charAt(0)&&'"'===f.charAt(f.length-1)&&(f=f.substr(1,f.length-2)),c[l]=f}}0===c.length&&c.push(o),p.push((function(){var t=document.querySelector('[id="'.concat(o,'"]'));null!==t&&t.addEventListener("click",(function(){var t;s.default.runFunc.apply(s.default,[e].concat(function(t){if(Array.isArray(t))return u(t)}(t=c)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return u(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}),!1)}))}},j=function(t){p.forEach((function(e){e(t)}))},D={LINE:0,DOTTED_LINE:1},B={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3},L=function(t){var e=Object(r.select)(".mermaidTooltip");null===(e._groups||e)[0][0]&&(e=Object(r.select)("body").append("div").attr("class","mermaidTooltip").style("opacity",0)),Object(r.select)(t).select("svg").selectAll("g.node").on("mouseover",(function(){var t=Object(r.select)(this);if(null!==t.attr("title")){var n=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",window.scrollX+n.left+(n.right-n.left)/2+"px").style("top",window.scrollY+n.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}})).on("mouseout",(function(){e.transition().duration(500).style("opacity",0),Object(r.select)(this).classed("hover",!1)}))};p.push(L);var I="TB";e.default={parseDirective:g,getConfig:function(){return a.getConfig().class},addClass:m,bindFunctions:j,clear:b,getClass:_,getClasses:x,addAnnotation:T,getRelations:w,addRelation:k,getDirection:function(){return I},setDirection:function(t){I=t},addMember:E,addMembers:C,cleanupLabel:S,lineType:D,relationType:B,setClickEvent:O,setCssClass:M,setLink:A,setTooltip:function(t,e){var n=a.getConfig();t.split(",").forEach((function(t){void 0!==e&&(h[t].tooltip=o.default.sanitizeText(e,n))}))},lookUpDomId:v}},"./src/diagrams/class/classRenderer-v2.js":function(t,e,n){"use strict";n.r(e),n.d(e,"addClasses",(function(){return v})),n.d(e,"addRelations",(function(){return b})),n.d(e,"setConf",(function(){return x})),n.d(e,"drawOld",(function(){return w})),n.d(e,"draw",(function(){return k}));var r=n("d3"),i=n("dagre"),a=n.n(i),o=n("graphlib"),s=n.n(o),c=n("./src/logger.js"),u=n("./src/diagrams/class/classDb.js"),l=n("./src/diagrams/class/parser/classDiagram.jison"),f=n("./src/diagrams/class/svgDraw.js"),h=n("./src/config.js"),d=n("./src/dagre-wrapper/index.js"),p=n("./src/utils.js"),g=n("./src/diagrams/common/common.js");l.parser.yy=u.default;var y={},m={dividerMargin:10,padding:5,textHeight:10},v=function(t,e){var n=Object.keys(t);c.log.info("keys:",n),c.log.info(t),n.forEach((function(n){var r=t[n],i="";r.cssClasses.length>0&&(i=i+" "+r.cssClasses.join(" "));var a,o={labelStyle:""},s=void 0!==r.text?r.text:r.id;r.type,a="class_box",e.setNode(r.id,{labelStyle:o.labelStyle,shape:a,labelText:s,classData:r,rx:0,ry:0,class:i,style:o.style,id:r.id,domId:r.domId,haveCallback:r.haveCallback,link:r.link,width:"group"===r.type?500:void 0,type:r.type,padding:Object(h.getConfig)().flowchart.padding}),c.log.info("setNode",{labelStyle:o.labelStyle,shape:a,labelText:s,rx:0,ry:0,class:i,style:o.style,id:r.id,width:"group"===r.type?500:void 0,type:r.type,padding:Object(h.getConfig)().flowchart.padding})}))},b=function(t,e){var n=0;t.forEach((function(i){n++;var a={classes:"relation"};a.pattern=1==i.relation.lineType?"dashed":"solid",a.id="id"+n,"arrow_open"===i.type?a.arrowhead="none":a.arrowhead="normal",c.log.info(a,i),a.startLabelRight="none"===i.relationTitle1?"":i.relationTitle1,a.endLabelLeft="none"===i.relationTitle2?"":i.relationTitle2,a.arrowTypeStart=T(i.relation.type1),a.arrowTypeEnd=T(i.relation.type2);var o="",s="";if(void 0!==i.style){var u=Object(p.getStylesFromArray)(i.style);o=u.style,s=u.labelStyle}else o="fill:none";a.style=o,a.labelStyle=s,void 0!==i.interpolate?a.curve=Object(p.interpolateToCurve)(i.interpolate,r.curveLinear):void 0!==t.defaultInterpolate?a.curve=Object(p.interpolateToCurve)(t.defaultInterpolate,r.curveLinear):a.curve=Object(p.interpolateToCurve)(m.curve,r.curveLinear),i.text=i.title,void 0===i.text?void 0!==i.style&&(a.arrowheadStyle="fill: #333"):(a.arrowheadStyle="fill: #333",a.labelpos="c",Object(h.getConfig)().flowchart.htmlLabels?(a.labelType="html",a.label='<span class="edgeLabel">'+i.text+"</span>"):(a.labelType="text",a.label=i.text.replace(g.default.lineBreakRegex,"\n"),void 0===i.style&&(a.style=a.style||"stroke: #333; stroke-width: 1.5px;fill:none"),a.labelStyle=a.labelStyle.replace("color:","fill:"))),e.setEdge(i.id1,i.id2,a,n)}))},_=function(t){for(var e=Object.keys(y),n=0;n<e.length;n++)if(y[e[n]].label===t)return e[n]},x=function(t){Object.keys(t).forEach((function(e){m[e]=t[e]}))},w=function(t,e){y={},l.parser.yy.clear(),l.parser.parse(t),c.log.info("Rendering diagram "+t);var n=Object(r.select)("[id='".concat(e,"']")),i=new s.a.Graph({multigraph:!0});i.setGraph({isMultiGraph:!0}),i.setDefaultEdgeLabel((function(){return{}}));var o=u.default.getClasses();c.log.info("classes:"),c.log.info(o);for(var h=Object.keys(o),d=0;d<h.length;d++){var g=o[h[d]],v=f.default.drawClass(n,g,m);y[v.id]=v,i.setNode(v.id,v),c.log.info("Org height: "+v.height)}var b=u.default.getRelations();c.log.info("relations:",b),b.forEach((function(t){c.log.info("tjoho"+_(t.id1)+_(t.id2)+JSON.stringify(t)),i.setEdge(_(t.id1),_(t.id2),{relation:t},t.title||"DEFAULT")})),a.a.layout(i),i.nodes().forEach((function(t){void 0!==t&&void 0!==i.node(t)&&(c.log.debug("Node "+t+": "+JSON.stringify(i.node(t))),Object(r.select)("#"+Object(u.lookUpDomId)(t)).attr("transform","translate("+(i.node(t).x-i.node(t).width/2)+","+(i.node(t).y-i.node(t).height/2)+" )"))})),i.edges().forEach((function(t){void 0!==t&&void 0!==i.edge(t)&&(c.log.debug("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(i.edge(t))),f.default.drawEdge(n,i.edge(t),i.edge(t).relation,m))}));var x=n.node().getBBox(),w=x.width+40,k=x.height+40;Object(p.configureSvgSize)(n,k,w,m.useMaxWidth);var T="".concat(x.x-20," ").concat(x.y-20," ").concat(w," ").concat(k);c.log.debug("viewBox ".concat(T)),n.attr("viewBox",T)},k=function(t,e){c.log.info("Drawing class"),u.default.clear(),l.parser.parse(t);var n=Object(h.getConfig)().flowchart;c.log.info("config:",n);var i=n.nodeSpacing||50,a=n.rankSpacing||50,o=new s.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:u.default.getDirection(),nodesep:i,ranksep:a,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}})),f=u.default.getClasses(),g=u.default.getRelations();c.log.info(g),v(f,o,e),b(g,o);var y=Object(r.select)('[id="'.concat(e,'"]'));y.attr("xmlns:xlink","http://www.w3.org/1999/xlink");var m=Object(r.select)("#"+e+" g");Object(d.render)(m,o,["aggregation","extension","composition","dependency"],"classDiagram",e);var _=y.node().getBBox(),x=_.width+16,w=_.height+16;if(c.log.debug("new ViewBox 0 0 ".concat(x," ").concat(w),"translate(".concat(8-o._label.marginx,", ").concat(8-o._label.marginy,")")),Object(p.configureSvgSize)(y,w,x,n.useMaxWidth),y.attr("viewBox","0 0 ".concat(x," ").concat(w)),y.select("g").attr("transform","translate(".concat(8-o._label.marginx,", ").concat(8-_.y,")")),!n.htmlLabels)for(var k=document.querySelectorAll('[id="'+e+'"] .edgeLabel .label'),T=0;T<k.length;T++){var E=k[T],C=E.getBBox(),S=document.createElementNS("http://www.w3.org/2000/svg","rect");S.setAttribute("rx",0),S.setAttribute("ry",0),S.setAttribute("width",C.width),S.setAttribute("height",C.height),E.insertBefore(S,E.firstChild)}};function T(t){var e;switch(t){case 0:e="aggregation";break;case 1:e="extension";break;case 2:e="composition";break;case 3:e="dependency";break;default:e="none"}return e}e.default={setConf:x,draw:k}},"./src/diagrams/class/classRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return y})),n.d(e,"draw",(function(){return m}));var r=n("d3"),i=n("dagre"),a=n.n(i),o=n("graphlib"),s=n.n(o),c=n("./src/logger.js"),u=n("./src/diagrams/class/classDb.js"),l=n("./src/diagrams/class/parser/classDiagram.jison"),f=n("./src/diagrams/class/svgDraw.js"),h=n("./src/utils.js");l.parser.yy=u.default;var d={},p={dividerMargin:10,padding:5,textHeight:10},g=function(t){for(var e=Object.keys(d),n=0;n<e.length;n++)if(d[e[n]].label===t)return e[n]},y=function(t){Object.keys(t).forEach((function(e){p[e]=t[e]}))},m=function(t,e){d={},l.parser.yy.clear(),l.parser.parse(t),c.log.info("Rendering diagram "+t);var n,i=Object(r.select)("[id='".concat(e,"']"));i.attr("xmlns:xlink","http://www.w3.org/1999/xlink"),(n=i).append("defs").append("marker").attr("id","extensionStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),n.append("defs").append("marker").attr("id","extensionEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z"),n.append("defs").append("marker").attr("id","compositionStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),n.append("defs").append("marker").attr("id","compositionEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),n.append("defs").append("marker").attr("id","aggregationStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),n.append("defs").append("marker").attr("id","aggregationEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),n.append("defs").append("marker").attr("id","dependencyStart").attr("class","extension").attr("refX",0).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),n.append("defs").append("marker").attr("id","dependencyEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z");var o=new s.a.Graph({multigraph:!0});o.setGraph({isMultiGraph:!0}),o.setDefaultEdgeLabel((function(){return{}}));for(var y=u.default.getClasses(),m=Object.keys(y),v=0;v<m.length;v++){var b=y[m[v]],_=f.default.drawClass(i,b,p);d[_.id]=_,o.setNode(_.id,_),c.log.info("Org height: "+_.height)}u.default.getRelations().forEach((function(t){c.log.info("tjoho"+g(t.id1)+g(t.id2)+JSON.stringify(t)),o.setEdge(g(t.id1),g(t.id2),{relation:t},t.title||"DEFAULT")})),a.a.layout(o),o.nodes().forEach((function(t){void 0!==t&&void 0!==o.node(t)&&(c.log.debug("Node "+t+": "+JSON.stringify(o.node(t))),Object(r.select)("#"+Object(u.lookUpDomId)(t)).attr("transform","translate("+(o.node(t).x-o.node(t).width/2)+","+(o.node(t).y-o.node(t).height/2)+" )"))})),o.edges().forEach((function(t){void 0!==t&&void 0!==o.edge(t)&&(c.log.debug("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(o.edge(t))),f.default.drawEdge(i,o.edge(t),o.edge(t).relation,p))}));var x=i.node().getBBox(),w=x.width+40,k=x.height+40;Object(h.configureSvgSize)(i,k,w,p.useMaxWidth);var T="".concat(x.x-20," ").concat(x.y-20," ").concat(w," ").concat(k);c.log.debug("viewBox ".concat(T)),i.attr("viewBox",T)};e.default={setConf:y,draw:m}},"./src/diagrams/class/parser/classDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,6],n=[1,7],r=[1,8],i=[1,9],a=[1,12],o=[1,11],s=[1,15,24],c=[1,19],u=[1,31],l=[1,34],f=[1,32],h=[1,33],d=[1,35],p=[1,36],g=[1,37],y=[1,38],m=[1,41],v=[1,42],b=[1,43],_=[1,44],x=[15,24],w=[1,56],k=[1,57],T=[1,58],E=[1,59],C=[1,60],S=[1,61],M=[15,24,31,38,39,47,50,51,52,53,54,55,60,62],A=[15,24,29,31,38,39,43,47,50,51,52,53,54,55,60,62,77,78,79,80],O=[7,8,9,10,15,18,22,24],N=[47,77,78,79,80],j=[47,54,55,77,78,79,80],D=[47,50,51,52,53,77,78,79,80],B=[15,24,31],L=[1,93],I={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,directive:6,direction_tb:7,direction_bt:8,direction_rl:9,direction_lr:10,graphConfig:11,openDirective:12,typeDirective:13,closeDirective:14,NEWLINE:15,":":16,argDirective:17,open_directive:18,type_directive:19,arg_directive:20,close_directive:21,CLASS_DIAGRAM:22,statements:23,EOF:24,statement:25,className:26,alphaNumToken:27,classLiteralName:28,GENERICTYPE:29,relationStatement:30,LABEL:31,classStatement:32,methodStatement:33,annotationStatement:34,clickStatement:35,cssClassStatement:36,CLASS:37,STYLE_SEPARATOR:38,STRUCT_START:39,members:40,STRUCT_STOP:41,ANNOTATION_START:42,ANNOTATION_END:43,MEMBER:44,SEPARATOR:45,relation:46,STR:47,relationType:48,lineType:49,AGGREGATION:50,EXTENSION:51,COMPOSITION:52,DEPENDENCY:53,LINE:54,DOTTED_LINE:55,CALLBACK:56,LINK:57,LINK_TARGET:58,CLICK:59,CALLBACK_NAME:60,CALLBACK_ARGS:61,HREF:62,CSSCLASS:63,commentToken:64,textToken:65,graphCodeTokens:66,textNoTagsToken:67,TAGSTART:68,TAGEND:69,"==":70,"--":71,PCT:72,DEFAULT:73,SPACE:74,MINUS:75,keywords:76,UNICODE_TEXT:77,NUM:78,ALPHA:79,BQUOTE_STR:80,$accept:0,$end:1},terminals_:{2:"error",7:"direction_tb",8:"direction_bt",9:"direction_rl",10:"direction_lr",15:"NEWLINE",16:":",18:"open_directive",19:"type_directive",20:"arg_directive",21:"close_directive",22:"CLASS_DIAGRAM",24:"EOF",29:"GENERICTYPE",31:"LABEL",37:"CLASS",38:"STYLE_SEPARATOR",39:"STRUCT_START",41:"STRUCT_STOP",42:"ANNOTATION_START",43:"ANNOTATION_END",44:"MEMBER",45:"SEPARATOR",47:"STR",50:"AGGREGATION",51:"EXTENSION",52:"COMPOSITION",53:"DEPENDENCY",54:"LINE",55:"DOTTED_LINE",56:"CALLBACK",57:"LINK",58:"LINK_TARGET",59:"CLICK",60:"CALLBACK_NAME",61:"CALLBACK_ARGS",62:"HREF",63:"CSSCLASS",66:"graphCodeTokens",68:"TAGSTART",69:"TAGEND",70:"==",71:"--",72:"PCT",73:"DEFAULT",74:"SPACE",75:"MINUS",76:"keywords",77:"UNICODE_TEXT",78:"NUM",79:"ALPHA",80:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[3,2],[5,1],[5,1],[5,1],[5,1],[4,1],[6,4],[6,6],[12,1],[13,1],[17,1],[14,1],[11,4],[23,1],[23,2],[23,3],[26,1],[26,1],[26,2],[26,2],[26,2],[25,1],[25,2],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[32,2],[32,4],[32,5],[32,7],[34,4],[40,1],[40,2],[33,1],[33,2],[33,1],[33,1],[30,3],[30,4],[30,4],[30,5],[46,3],[46,2],[46,2],[46,1],[48,1],[48,1],[48,1],[48,1],[49,1],[49,1],[35,3],[35,4],[35,3],[35,4],[35,4],[35,5],[35,3],[35,4],[35,4],[35,5],[35,3],[35,4],[35,4],[35,5],[36,3],[64,1],[64,1],[65,1],[65,1],[65,1],[65,1],[65,1],[65,1],[65,1],[67,1],[67,1],[67,1],[67,1],[27,1],[27,1],[27,1],[28,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 4:r.setDirection("TB");break;case 5:r.setDirection("BT");break;case 6:r.setDirection("RL");break;case 7:r.setDirection("LR");break;case 11:r.parseDirective("%%{","open_directive");break;case 12:r.parseDirective(a[s],"type_directive");break;case 13:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 14:r.parseDirective("}%%","close_directive","class");break;case 19:case 20:this.$=a[s];break;case 21:this.$=a[s-1]+a[s];break;case 22:case 23:this.$=a[s-1]+"~"+a[s];break;case 24:r.addRelation(a[s]);break;case 25:a[s-1].title=r.cleanupLabel(a[s]),r.addRelation(a[s-1]);break;case 33:r.addClass(a[s]);break;case 34:r.addClass(a[s-2]),r.setCssClass(a[s-2],a[s]);break;case 35:r.addClass(a[s-3]),r.addMembers(a[s-3],a[s-1]);break;case 36:r.addClass(a[s-5]),r.setCssClass(a[s-5],a[s-3]),r.addMembers(a[s-5],a[s-1]);break;case 37:r.addAnnotation(a[s],a[s-2]);break;case 38:this.$=[a[s]];break;case 39:a[s].push(a[s-1]),this.$=a[s];break;case 40:case 42:case 43:break;case 41:r.addMember(a[s-1],r.cleanupLabel(a[s]));break;case 44:this.$={id1:a[s-2],id2:a[s],relation:a[s-1],relationTitle1:"none",relationTitle2:"none"};break;case 45:this.$={id1:a[s-3],id2:a[s],relation:a[s-1],relationTitle1:a[s-2],relationTitle2:"none"};break;case 46:this.$={id1:a[s-3],id2:a[s],relation:a[s-2],relationTitle1:"none",relationTitle2:a[s-1]};break;case 47:this.$={id1:a[s-4],id2:a[s],relation:a[s-2],relationTitle1:a[s-3],relationTitle2:a[s-1]};break;case 48:this.$={type1:a[s-2],type2:a[s],lineType:a[s-1]};break;case 49:this.$={type1:"none",type2:a[s],lineType:a[s-1]};break;case 50:this.$={type1:a[s-1],type2:"none",lineType:a[s]};break;case 51:this.$={type1:"none",type2:"none",lineType:a[s]};break;case 52:this.$=r.relationType.AGGREGATION;break;case 53:this.$=r.relationType.EXTENSION;break;case 54:this.$=r.relationType.COMPOSITION;break;case 55:this.$=r.relationType.DEPENDENCY;break;case 56:this.$=r.lineType.LINE;break;case 57:this.$=r.lineType.DOTTED_LINE;break;case 58:case 64:this.$=a[s-2],r.setClickEvent(a[s-1],a[s]);break;case 59:case 65:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 60:case 68:this.$=a[s-2],r.setLink(a[s-1],a[s]);break;case 61:case 69:this.$=a[s-3],r.setLink(a[s-2],a[s-1],a[s]);break;case 62:case 70:this.$=a[s-3],r.setLink(a[s-2],a[s-1]),r.setTooltip(a[s-2],a[s]);break;case 63:case 71:this.$=a[s-4],r.setLink(a[s-3],a[s-2],a[s]),r.setTooltip(a[s-3],a[s-1]);break;case 66:this.$=a[s-3],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 67:this.$=a[s-4],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setTooltip(a[s-3],a[s]);break;case 72:r.setCssClass(a[s-1],a[s])}},table:[{3:1,4:2,5:3,6:4,7:e,8:n,9:r,10:i,11:5,12:10,18:a,22:o},{1:[3]},{1:[2,1]},{1:[2,2]},{3:13,4:2,5:3,6:4,7:e,8:n,9:r,10:i,11:5,12:10,18:a,22:o},{1:[2,8]},t(s,[2,4]),t(s,[2,5]),t(s,[2,6]),t(s,[2,7]),{13:14,19:[1,15]},{15:[1,16]},{19:[2,11]},{1:[2,3]},{14:17,16:[1,18],21:c},t([16,21],[2,12]),{5:29,6:28,7:e,8:n,9:r,10:i,12:10,18:a,23:20,25:21,26:30,27:39,28:40,30:22,32:23,33:24,34:25,35:26,36:27,37:u,42:l,44:f,45:h,56:d,57:p,59:g,63:y,77:m,78:v,79:b,80:_},{15:[1,45]},{17:46,20:[1,47]},{15:[2,14]},{24:[1,48]},{15:[1,49],24:[2,16]},t(x,[2,24],{31:[1,50]}),t(x,[2,26]),t(x,[2,27]),t(x,[2,28]),t(x,[2,29]),t(x,[2,30]),t(x,[2,31]),t(x,[2,32]),t(x,[2,40],{46:51,48:54,49:55,31:[1,53],47:[1,52],50:w,51:k,52:T,53:E,54:C,55:S}),{26:62,27:39,28:40,77:m,78:v,79:b,80:_},t(x,[2,42]),t(x,[2,43]),{27:63,77:m,78:v,79:b},{26:64,27:39,28:40,77:m,78:v,79:b,80:_},{26:65,27:39,28:40,77:m,78:v,79:b,80:_},{26:66,27:39,28:40,77:m,78:v,79:b,80:_},{47:[1,67]},t(M,[2,19],{27:39,28:40,26:68,29:[1,69],77:m,78:v,79:b,80:_}),t(M,[2,20],{29:[1,70]}),t(A,[2,86]),t(A,[2,87]),t(A,[2,88]),t([15,24,29,31,38,39,47,50,51,52,53,54,55,60,62],[2,89]),t(O,[2,9]),{14:71,21:c},{21:[2,13]},{1:[2,15]},{5:29,6:28,7:e,8:n,9:r,10:i,12:10,18:a,23:72,24:[2,17],25:21,26:30,27:39,28:40,30:22,32:23,33:24,34:25,35:26,36:27,37:u,42:l,44:f,45:h,56:d,57:p,59:g,63:y,77:m,78:v,79:b,80:_},t(x,[2,25]),{26:73,27:39,28:40,47:[1,74],77:m,78:v,79:b,80:_},{46:75,48:54,49:55,50:w,51:k,52:T,53:E,54:C,55:S},t(x,[2,41]),{49:76,54:C,55:S},t(N,[2,51],{48:77,50:w,51:k,52:T,53:E}),t(j,[2,52]),t(j,[2,53]),t(j,[2,54]),t(j,[2,55]),t(D,[2,56]),t(D,[2,57]),t(x,[2,33],{38:[1,78],39:[1,79]}),{43:[1,80]},{47:[1,81]},{47:[1,82]},{60:[1,83],62:[1,84]},{27:85,77:m,78:v,79:b},t(M,[2,21]),t(M,[2,22]),t(M,[2,23]),{15:[1,86]},{24:[2,18]},t(B,[2,44]),{26:87,27:39,28:40,77:m,78:v,79:b,80:_},{26:88,27:39,28:40,47:[1,89],77:m,78:v,79:b,80:_},t(N,[2,50],{48:90,50:w,51:k,52:T,53:E}),t(N,[2,49]),{27:91,77:m,78:v,79:b},{40:92,44:L},{26:94,27:39,28:40,77:m,78:v,79:b,80:_},t(x,[2,58],{47:[1,95]}),t(x,[2,60],{47:[1,97],58:[1,96]}),t(x,[2,64],{47:[1,98],61:[1,99]}),t(x,[2,68],{47:[1,101],58:[1,100]}),t(x,[2,72]),t(O,[2,10]),t(B,[2,46]),t(B,[2,45]),{26:102,27:39,28:40,77:m,78:v,79:b,80:_},t(N,[2,48]),t(x,[2,34],{39:[1,103]}),{41:[1,104]},{40:105,41:[2,38],44:L},t(x,[2,37]),t(x,[2,59]),t(x,[2,61]),t(x,[2,62],{58:[1,106]}),t(x,[2,65]),t(x,[2,66],{47:[1,107]}),t(x,[2,69]),t(x,[2,70],{58:[1,108]}),t(B,[2,47]),{40:109,44:L},t(x,[2,35]),{41:[2,39]},t(x,[2,63]),t(x,[2,67]),t(x,[2,71]),{41:[1,110]},t(x,[2,36])],defaultActions:{2:[2,1],3:[2,2],5:[2,8],12:[2,11],13:[2,3],19:[2,14],47:[2,13],48:[2,15],72:[2,18],105:[2,39]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},R={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),18;case 1:return 7;case 2:return 8;case 3:return 9;case 4:return 10;case 5:return this.begin("type_directive"),19;case 6:return this.popState(),this.begin("arg_directive"),16;case 7:return this.popState(),this.popState(),21;case 8:return 20;case 9:case 10:case 12:case 19:break;case 11:return 15;case 13:case 14:return 22;case 15:return this.begin("struct"),39;case 16:return"EOF_IN_STRUCT";case 17:return"OPEN_IN_STRUCT";case 18:return this.popState(),41;case 20:return"MEMBER";case 21:return 37;case 22:return 63;case 23:return 56;case 24:return 57;case 25:return 59;case 26:return 42;case 27:return 43;case 28:this.begin("generic");break;case 29:case 32:case 35:case 38:case 41:case 44:this.popState();break;case 30:return"GENERICTYPE";case 31:this.begin("string");break;case 33:return"STR";case 34:this.begin("bqstring");break;case 36:return"BQUOTE_STR";case 37:this.begin("href");break;case 39:return 62;case 40:this.begin("callback_name");break;case 42:this.popState(),this.begin("callback_args");break;case 43:return 60;case 45:return 61;case 46:case 47:case 48:case 49:return 58;case 50:case 51:return 51;case 52:case 53:return 53;case 54:return 52;case 55:return 50;case 56:return 54;case 57:return 55;case 58:return 31;case 59:return 38;case 60:return 75;case 61:return"DOT";case 62:return"PLUS";case 63:return 72;case 64:case 65:return"EQUALS";case 66:return 79;case 67:return"PUNCTUATION";case 68:return 78;case 69:return 77;case 70:return 74;case 71:return 24}},rules:[/^(?:%%\{)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:((?:(?!\}%%)[^:.])*))/,/^(?::)/,/^(?:\}%%)/,/^(?:((?:(?!\}%%).|\n)*))/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:[{])/,/^(?:$)/,/^(?:[{])/,/^(?:[}])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:class\b)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:[~])/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[`])/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:href[\s]+["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:$)/],conditions:{arg_directive:{rules:[7,8],inclusive:!1},type_directive:{rules:[6,7],inclusive:!1},open_directive:{rules:[5],inclusive:!1},callback_args:{rules:[44,45],inclusive:!1},callback_name:{rules:[41,42,43],inclusive:!1},href:{rules:[38,39],inclusive:!1},struct:{rules:[16,17,18,19,20],inclusive:!1},generic:{rules:[29,30],inclusive:!1},bqstring:{rules:[35,36],inclusive:!1},string:{rules:[32,33],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,9,10,11,12,13,14,15,21,22,23,24,25,26,27,28,31,34,37,40,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71],inclusive:!0}}};function P(){this.yy={}}return I.lexer=R,P.prototype=I,I.Parser=P,new P}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/class/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return"g.classGroup text {\n fill: ".concat(t.nodeBorder,";\n fill: ").concat(t.classText,";\n stroke: none;\n font-family: ").concat(t.fontFamily,";\n font-size: 10px;\n\n .title {\n font-weight: bolder;\n }\n\n}\n\n.nodeLabel, .edgeLabel {\n color: ").concat(t.classText,";\n}\n.edgeLabel .label rect {\n fill: ").concat(t.mainBkg,";\n}\n.label text {\n fill: ").concat(t.classText,";\n}\n.edgeLabel .label span {\n background: ").concat(t.mainBkg,";\n}\n\n.classTitle {\n font-weight: bolder;\n}\n.node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1px;\n }\n\n\n.divider {\n stroke: ").concat(t.nodeBorder,";\n stroke: 1;\n}\n\ng.clickable {\n cursor: pointer;\n}\n\ng.classGroup rect {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n}\n\ng.classGroup line {\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1;\n}\n\n.classLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ").concat(t.mainBkg,";\n opacity: 0.5;\n}\n\n.classLabel .label {\n fill: ").concat(t.nodeBorder,";\n font-size: 10px;\n}\n\n.relation {\n stroke: ").concat(t.lineColor,";\n stroke-width: 1;\n fill: none;\n}\n\n.dashed-line{\n stroke-dasharray: 3;\n}\n\n#compositionStart, .composition {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#compositionEnd, .composition {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#extensionStart, .extension {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#extensionEnd, .extension {\n fill: ").concat(t.lineColor," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#aggregationStart, .aggregation {\n fill: ").concat(t.mainBkg," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n#aggregationEnd, .aggregation {\n fill: ").concat(t.mainBkg," !important;\n stroke: ").concat(t.lineColor," !important;\n stroke-width: 1;\n}\n\n.edgeTerminals {\n font-size: 11px;\n}\n\n")}},"./src/diagrams/class/svgDraw.js":function(t,e,n){"use strict";n.r(e),n.d(e,"drawEdge",(function(){return c})),n.d(e,"drawClass",(function(){return u})),n.d(e,"parseMember",(function(){return l}));var r=n("d3"),i=n("./src/diagrams/class/classDb.js"),a=n("./src/utils.js"),o=n("./src/logger.js"),s=0,c=function(t,e,n,c){var u=function(t){switch(t){case i.relationType.AGGREGATION:return"aggregation";case i.relationType.EXTENSION:return"extension";case i.relationType.COMPOSITION:return"composition";case i.relationType.DEPENDENCY:return"dependency"}};e.points=e.points.filter((function(t){return!Number.isNaN(t.y)}));var l,f,h=e.points,d=Object(r.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(r.curveBasis),p=t.append("path").attr("d",d(h)).attr("id","edge"+s).attr("class","relation"),g="";c.arrowMarkerAbsolute&&(g=(g=(g=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),1==n.relation.lineType&&p.attr("class","relation dashed-line"),"none"!==n.relation.type1&&p.attr("marker-start","url("+g+"#"+u(n.relation.type1)+"Start)"),"none"!==n.relation.type2&&p.attr("marker-end","url("+g+"#"+u(n.relation.type2)+"End)");var y,m,v,b,_=e.points.length,x=a.default.calcLabelPosition(e.points);if(l=x.x,f=x.y,_%2!=0&&_>1){var w=a.default.calcCardinalityPosition("none"!==n.relation.type1,e.points,e.points[0]),k=a.default.calcCardinalityPosition("none"!==n.relation.type2,e.points,e.points[_-1]);o.log.debug("cardinality_1_point "+JSON.stringify(w)),o.log.debug("cardinality_2_point "+JSON.stringify(k)),y=w.x,m=w.y,v=k.x,b=k.y}if(void 0!==n.title){var T=t.append("g").attr("class","classLabel"),E=T.append("text").attr("class","label").attr("x",l).attr("y",f).attr("fill","red").attr("text-anchor","middle").text(n.title);window.label=E;var C=E.node().getBBox();T.insert("rect",":first-child").attr("class","box").attr("x",C.x-c.padding/2).attr("y",C.y-c.padding/2).attr("width",C.width+c.padding).attr("height",C.height+c.padding)}o.log.info("Rendering relation "+JSON.stringify(n)),void 0!==n.relationTitle1&&"none"!==n.relationTitle1&&t.append("g").attr("class","cardinality").append("text").attr("class","type1").attr("x",y).attr("y",m).attr("fill","black").attr("font-size","6").text(n.relationTitle1),void 0!==n.relationTitle2&&"none"!==n.relationTitle2&&t.append("g").attr("class","cardinality").append("text").attr("class","type2").attr("x",v).attr("y",b).attr("fill","black").attr("font-size","6").text(n.relationTitle2),s++},u=function(t,e,n){o.log.info("Rendering class "+e);var r,a=e.id,s={id:a,label:e.id,width:0,height:0},c=t.append("g").attr("id",Object(i.lookUpDomId)(a)).attr("class","classGroup");r=e.link?c.append("svg:a").attr("xlink:href",e.link).attr("target",e.linkTarget).append("text").attr("y",n.textHeight+n.padding).attr("x",0):c.append("text").attr("y",n.textHeight+n.padding).attr("x",0);var u=!0;e.annotations.forEach((function(t){var e=r.append("tspan").text("«"+t+"»");u||e.attr("dy",n.textHeight),u=!1}));var l=e.id;void 0!==e.type&&""!==e.type&&(l+="<"+e.type+">");var f=r.append("tspan").text(l).attr("class","title");u||f.attr("dy",n.textHeight);var h=r.node().getBBox().height,d=c.append("line").attr("x1",0).attr("y1",n.padding+h+n.dividerMargin/2).attr("y2",n.padding+h+n.dividerMargin/2),g=c.append("text").attr("x",n.padding).attr("y",h+n.dividerMargin+n.textHeight).attr("fill","white").attr("class","classText");u=!0,e.members.forEach((function(t){p(g,t,u,n),u=!1}));var y=g.node().getBBox(),m=c.append("line").attr("x1",0).attr("y1",n.padding+h+n.dividerMargin+y.height).attr("y2",n.padding+h+n.dividerMargin+y.height),v=c.append("text").attr("x",n.padding).attr("y",h+2*n.dividerMargin+y.height+n.textHeight).attr("fill","white").attr("class","classText");u=!0,e.methods.forEach((function(t){p(v,t,u,n),u=!1}));var b=c.node().getBBox(),_=" ";e.cssClasses.length>0&&(_+=e.cssClasses.join(" "));var x=c.insert("rect",":first-child").attr("x",0).attr("y",0).attr("width",b.width+2*n.padding).attr("height",b.height+n.padding+.5*n.dividerMargin).attr("class",_).node().getBBox().width;return r.node().childNodes.forEach((function(t){t.setAttribute("x",(x-t.getBBox().width)/2)})),e.tooltip&&r.insert("title").text(e.tooltip),d.attr("x2",x),m.attr("x2",x),s.width=x,s.height=b.height+n.padding+.5*n.dividerMargin,s},l=function(t){var e=t.match(/^(\+|-|~|#)?(\w+)(~\w+~|\[\])?\s+(\w+) *(\*|\$)?$/),n=t.match(/^([+|\-|~|#])?(\w+) *\( *(.*)\) *(\*|\$)? *(\w*[~|[\]]*\s*\w*~?)$/);return e&&!n?f(e):n?h(n):d(t)},f=function(t){var e="",n="";try{var r=t[1]?t[1].trim():"",i=t[2]?t[2].trim():"",a=t[3]?g(t[3].trim()):"",o=t[4]?t[4].trim():"",s=t[5]?t[5].trim():"";n=r+i+a+" "+o,e=y(s)}catch(e){n=t}return{displayText:n,cssStyle:e}},h=function(t){var e="",n="";try{var r=t[1]?t[1].trim():"",i=t[2]?t[2].trim():"",a=t[3]?g(t[3].trim()):"",o=t[4]?t[4].trim():"";n=r+i+"("+a+")"+(t[5]?" : "+g(t[5]).trim():""),e=y(o)}catch(e){n=t}return{displayText:n,cssStyle:e}},d=function(t){var e="",n="",r="",i=t.indexOf("("),a=t.indexOf(")");if(i>1&&a>i&&a<=t.length){var o="",s="",c=t.substring(0,1);c.match(/\w/)?s=t.substring(0,i).trim():(c.match(/\+|-|~|#/)&&(o=c),s=t.substring(1,i).trim());var u=t.substring(i+1,a),l=t.substring(a+1,1);n=y(l),e=o+s+"("+g(u.trim())+")",a<"".length&&""!==(r=t.substring(a+2).trim())&&(r=" : "+g(r))}else e=g(t);return{displayText:e,cssStyle:n}},p=function(t,e,n,r){var i=l(e),a=t.append("tspan").attr("x",r.padding).text(i.displayText);""!==i.cssStyle&&a.attr("style",i.cssStyle),n||a.attr("dy",r.textHeight)},g=function t(e){var n=e;return-1!=e.indexOf("~")?t(n=(n=n.replace("~","<")).replace("~",">")):n},y=function(t){switch(t){case"*":return"font-style:italic;";case"$":return"text-decoration:underline;";default:return""}};e.default={drawClass:u,drawEdge:c,parseMember:l}},"./src/diagrams/common/common.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getRows",(function(){return a})),n.d(e,"removeScript",(function(){return o})),n.d(e,"sanitizeText",(function(){return s})),n.d(e,"lineBreakRegex",(function(){return c})),n.d(e,"hasBreaks",(function(){return u})),n.d(e,"splitBreaks",(function(){return l})),n.d(e,"evaluate",(function(){return d}));var r=n("dompurify"),i=n.n(r),a=function(t){if(!t)return 1;var e=h(t);return(e=e.replace(/\\n/g,"#br#")).split("#br#")},o=function(t){for(var e="",n=0;n>=0;){if(!((n=t.indexOf("<script"))>=0)){e+=t,n=-1;break}e+=t.substr(0,n),(n=(t=t.substr(n+1)).indexOf("<\/script>"))>=0&&(n+=9,t=t.substr(n))}return(e=(e=(e=(e=e.replace(/script>/gi,"#")).replace(/script>/gi,"#")).replace(/javascript:/gi,"#")).replace(/onerror=/gi,"onerror:")).replace(/<iframe/gi,"")},s=function(t,e){var n=e.securityLevel;if(console.log("security level",n),!t)return t;var r=i.a.sanitize(function(t,e){var n=t,r=!0;if(!e.flowchart||!1!==e.flowchart.htmlLabels&&"false"!==e.flowchart.htmlLabels||(r=!1),r){var i=e.securityLevel;"antiscript"===i?n=o(n):"loose"!==i&&(n=(n=(n=h(n)).replace(/</g,"&lt;").replace(/>/g,"&gt;")).replace(/=/g,"&equals;"),n=f(n))}return n}(t,e));return r},c=/<br\s*\/?>/gi,u=function(t){return/<br\s*[/]?>/gi.test(t)},l=function(t){return t.split(/<br\s*[/]?>/gi)},f=function(t){return t.replace(/#br#/g,"<br/>")},h=function(t){return t.replace(c,"#br#")},d=function(t){return"false"!==t&&!1!==t};e.default={getRows:a,sanitizeText:s,hasBreaks:u,splitBreaks:l,lineBreakRegex:c,removeScript:o,getUrl:function(t){var e="";return t&&(e=(e=(e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),e},evaluate:d}},"./src/diagrams/er/erDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return u}));var r=n("./src/logger.js"),i=n("./src/mermaidAPI.js"),a=n("./src/config.js"),o={},s=[],c="",u=function(t,e,n){i.default.parseDirective(this,t,e,n)},l=function(t){return void 0===o[t]&&(o[t]={attributes:[]},r.log.info("Added new entity :",t)),o[t]};e.default={Cardinality:{ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE"},Identification:{NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},parseDirective:u,getConfig:function(){return a.getConfig().er},addEntity:l,addAttributes:function(t,e){var n,i=l(t);for(n=e.length-1;n>=0;n--)i.attributes.push(e[n]),r.log.debug("Added attribute ",e[n].attributeName)},getEntities:function(){return o},addRelationship:function(t,e,n,i){var a={entityA:t,roleA:e,entityB:n,relSpec:i};s.push(a),r.log.debug("Added new relationship :",a)},getRelationships:function(){return s},clear:function(){o={},s=[],c=""},setTitle:function(t){c=t},getTitle:function(){return c}}},"./src/diagrams/er/erMarkers.js":function(t,e,n){"use strict";n.r(e);var r={ONLY_ONE_START:"ONLY_ONE_START",ONLY_ONE_END:"ONLY_ONE_END",ZERO_OR_ONE_START:"ZERO_OR_ONE_START",ZERO_OR_ONE_END:"ZERO_OR_ONE_END",ONE_OR_MORE_START:"ONE_OR_MORE_START",ONE_OR_MORE_END:"ONE_OR_MORE_END",ZERO_OR_MORE_START:"ZERO_OR_MORE_START",ZERO_OR_MORE_END:"ZERO_OR_MORE_END"};e.default={ERMarkers:r,insertMarkers:function(t,e){var n;t.append("defs").append("marker").attr("id",r.ONLY_ONE_START).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M9,0 L9,18 M15,0 L15,18"),t.append("defs").append("marker").attr("id",r.ONLY_ONE_END).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M3,0 L3,18 M9,0 L9,18"),(n=t.append("defs").append("marker").attr("id",r.ZERO_OR_ONE_START).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto")).append("circle").attr("stroke",e.stroke).attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),n.append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M9,0 L9,18"),(n=t.append("defs").append("marker").attr("id",r.ZERO_OR_ONE_END).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto")).append("circle").attr("stroke",e.stroke).attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),n.append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M21,0 L21,18"),t.append("defs").append("marker").attr("id",r.ONE_OR_MORE_START).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),t.append("defs").append("marker").attr("id",r.ONE_OR_MORE_END).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18"),(n=t.append("defs").append("marker").attr("id",r.ZERO_OR_MORE_START).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto")).append("circle").attr("stroke",e.stroke).attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),n.append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18"),(n=t.append("defs").append("marker").attr("id",r.ZERO_OR_MORE_END).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto")).append("circle").attr("stroke",e.stroke).attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),n.append("path").attr("stroke",e.stroke).attr("fill","none").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")}}},"./src/diagrams/er/erRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return y})),n.d(e,"draw",(function(){return b}));var r=n("graphlib"),i=n.n(r),a=n("d3"),o=n("./src/diagrams/er/erDb.js"),s=n("./src/diagrams/er/parser/erDiagram.jison"),c=n.n(s),u=n("dagre"),l=n.n(u),f=n("./src/config.js"),h=n("./src/logger.js"),d=n("./src/diagrams/er/erMarkers.js"),p=n("./src/utils.js"),g={},y=function(t){for(var e=Object.keys(t),n=0;n<e.length;n++)g[e[n]]=t[e[n]]},m=function(t){return(t.entityA+t.roleA+t.entityB).replace(/\s/g,"")},v=0,b=function(t,e){h.log.info("Drawing ER diagram"),o.default.clear();var n=c.a.parser;n.yy=o.default;try{n.parse(t)}catch(t){h.log.debug("Parsing failed")}var r,s=Object(a.select)("[id='".concat(e,"']"));d.default.insertMarkers(s,g),r=new i.a.Graph({multigraph:!0,directed:!0,compound:!1}).setGraph({rankdir:g.layoutDirection,marginx:20,marginy:20,nodesep:100,edgesep:100,ranksep:100}).setDefaultEdgeLabel((function(){return{}}));var u,y,b=function(t,e,n){var r;return Object.keys(e).forEach((function(i){var a=t.append("g").attr("id",i);r=void 0===r?i:r;var o="entity-"+i,s=a.append("text").attr("class","er entityLabel").attr("id",o).attr("x",0).attr("y",0).attr("dominant-baseline","middle").attr("text-anchor","middle").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+g.fontSize+"px").text(i),c=function(t,e,n){var r=g.entityPadding/3,i=g.entityPadding/3,a=.85*g.fontSize,o=e.node().getBBox(),s=[],c=!1,u=!1,l=0,h=0,d=0,p=0,y=0,m=o.height+2*r,v=1;n.forEach((function(n){var i="".concat(e.node().id,"-attr-").concat(v),o=0,g=0,b=t.append("text").attr("class","er entityLabel").attr("id","".concat(i,"-type")).attr("x",0).attr("y",0).attr("dominant-baseline","middle").attr("text-anchor","left").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+a+"px").text(n.attributeType),_=t.append("text").attr("class","er entityLabel").attr("id","".concat(i,"-name")).attr("x",0).attr("y",0).attr("dominant-baseline","middle").attr("text-anchor","left").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+a+"px").text(n.attributeName),x={};x.tn=b,x.nn=_;var w=b.node().getBBox(),k=_.node().getBBox();if(h=Math.max(h,w.width),d=Math.max(d,k.width),o+=w.width,o+=k.width,g=Math.max(w.height,k.height),c||void 0!==n.attributeKeyType){var T=t.append("text").attr("class","er entityLabel").attr("id","".concat(i,"-name")).attr("x",0).attr("y",0).attr("dominant-baseline","middle").attr("text-anchor","left").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+a+"px").text(n.attributeKeyType||"");x.kn=T;var E=T.node().getBBox();o+=E.width,p=Math.max(p,o),g=Math.max(g,E.height),c=!0}if(u||void 0!==n.attributeComment){var C=t.append("text").attr("class","er entityLabel").attr("id","".concat(i,"-name")).attr("x",0).attr("y",0).attr("dominant-baseline","middle").attr("text-anchor","left").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+a+"px").text(n.attributeComment||"");x.cn=C;var S=C.node().getBBox();o+=S.width,y=Math.max(o,k.width),g=Math.max(g,S.height),u=!0}x.height=g,s.push(x),l=Math.max(l,o),m+=g+2*r,v+=1}));var b={width:Math.max(g.minEntityWidth,Math.max(o.width+2*g.entityPadding,l+4*i)),height:n.length>0?m:Math.max(g.minEntityHeight,o.height+2*g.entityPadding)},_=Math.max(0,b.width-l-4*i);if(n.length>0){e.attr("transform","translate("+b.width/2+","+(r+o.height/2)+")");var x=o.height+2*r,w="attributeBoxOdd";s.forEach((function(e){var n=x+r+e.height/2;e.tn.attr("transform","translate("+i+","+n+")");var a=t.insert("rect","#"+e.tn.node().id).attr("class","er ".concat(w)).attr("fill",g.fill).attr("fill-opacity","100%").attr("stroke",g.stroke).attr("x",0).attr("y",x).attr("width",2*h+_/2).attr("height",e.tn.node().getBBox().height+2*r);e.nn.attr("transform","translate("+(parseFloat(a.attr("width"))+i)+","+n+")"),t.insert("rect","#"+e.nn.node().id).attr("class","er ".concat(w)).attr("fill",g.fill).attr("fill-opacity","100%").attr("stroke",g.stroke).attr("x","".concat(a.attr("x")+a.attr("width"))).attr("y",x).attr("width",d+2*i+_/2).attr("height",e.nn.node().getBBox().height+2*r),c&&(e.kn.attr("transform","translate("+(parseFloat(a.attr("width"))+i)+","+n+")"),t.insert("rect","#"+e.kn.node().id).attr("class","er ".concat(w)).attr("fill",g.fill).attr("fill-opacity","100%").attr("stroke",g.stroke).attr("x","".concat(a.attr("x")+a.attr("width"))).attr("y",x).attr("width",p+2*i+_/2).attr("height",e.kn.node().getBBox().height+2*r)),u&&(e.cn.attr("transform","translate("+(parseFloat(a.attr("width"))+i)+","+n+")"),t.insert("rect","#"+e.cn.node().id).attr("class","er ".concat(w)).attr("fill",g.fill).attr("fill-opacity","100%").attr("stroke",g.stroke).attr("x","".concat(a.attr("x")+a.attr("width"))).attr("y",x).attr("width",y+2*i+_/2).attr("height",e.cn.node().getBBox().height+2*r)),x+=e.height+2*r,w="attributeBoxOdd"==w?"attributeBoxEven":"attributeBoxOdd"}))}else b.height=Math.max(g.minEntityHeight,m),e.attr("transform","translate("+b.width/2+","+b.height/2+")");return b}(a,s,e[i].attributes),u=c.width,l=c.height,h=a.insert("rect","#"+o).attr("class","er entityBox").attr("fill",g.fill).attr("fill-opacity","100%").attr("stroke",g.stroke).attr("x",0).attr("y",0).attr("width",u).attr("height",l).node().getBBox();n.setNode(i,{width:h.width,height:h.height,shape:"rect",id:i})})),r}(s,o.default.getEntities(),r),_=function(t,e){return t.forEach((function(t){e.setEdge(t.entityA,t.entityB,{relationship:t},m(t))})),t}(o.default.getRelationships(),r);l.a.layout(r),u=s,(y=r).nodes().forEach((function(t){void 0!==t&&void 0!==y.node(t)&&u.select("#"+t).attr("transform","translate("+(y.node(t).x-y.node(t).width/2)+","+(y.node(t).y-y.node(t).height/2)+" )")})),_.forEach((function(t){!function(t,e,n,r){v++;var i=n.edge(e.entityA,e.entityB,m(e)),s=Object(a.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(a.curveBasis),c=t.insert("path","#"+r).attr("class","er relationshipLine").attr("d",s(i.points)).attr("stroke",g.stroke).attr("fill","none");e.relSpec.relType===o.default.Identification.NON_IDENTIFYING&&c.attr("stroke-dasharray","8,8");var u="";switch(g.arrowMarkerAbsolute&&(u=(u=(u=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),e.relSpec.cardA){case o.default.Cardinality.ZERO_OR_ONE:c.attr("marker-end","url("+u+"#"+d.default.ERMarkers.ZERO_OR_ONE_END+")");break;case o.default.Cardinality.ZERO_OR_MORE:c.attr("marker-end","url("+u+"#"+d.default.ERMarkers.ZERO_OR_MORE_END+")");break;case o.default.Cardinality.ONE_OR_MORE:c.attr("marker-end","url("+u+"#"+d.default.ERMarkers.ONE_OR_MORE_END+")");break;case o.default.Cardinality.ONLY_ONE:c.attr("marker-end","url("+u+"#"+d.default.ERMarkers.ONLY_ONE_END+")")}switch(e.relSpec.cardB){case o.default.Cardinality.ZERO_OR_ONE:c.attr("marker-start","url("+u+"#"+d.default.ERMarkers.ZERO_OR_ONE_START+")");break;case o.default.Cardinality.ZERO_OR_MORE:c.attr("marker-start","url("+u+"#"+d.default.ERMarkers.ZERO_OR_MORE_START+")");break;case o.default.Cardinality.ONE_OR_MORE:c.attr("marker-start","url("+u+"#"+d.default.ERMarkers.ONE_OR_MORE_START+")");break;case o.default.Cardinality.ONLY_ONE:c.attr("marker-start","url("+u+"#"+d.default.ERMarkers.ONLY_ONE_START+")")}var l=c.node().getTotalLength(),h=c.node().getPointAtLength(.5*l),p="rel"+v,y=t.append("text").attr("class","er relationshipLabel").attr("id",p).attr("x",h.x).attr("y",h.y).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("style","font-family: "+Object(f.getConfig)().fontFamily+"; font-size: "+g.fontSize+"px").text(e.roleA).node().getBBox();t.insert("rect","#"+p).attr("class","er relationshipLabelBox").attr("x",h.x-y.width/2).attr("y",h.y-y.height/2).attr("width",y.width).attr("height",y.height).attr("fill","white").attr("fill-opacity","85%")}(s,t,r,b)}));var x=g.diagramPadding,w=s.node().getBBox(),k=w.width+2*x,T=w.height+2*x;Object(p.configureSvgSize)(s,T,k,g.useMaxWidth),s.attr("viewBox","".concat(w.x-x," ").concat(w.y-x," ").concat(k," ").concat(T))};e.default={setConf:y,draw:b}},"./src/diagrams/er/parser/erDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,2],n=[1,5],r=[6,9,11,23,40],i=[1,17],a=[1,20],o=[1,25],s=[1,26],c=[1,27],u=[1,28],l=[1,37],f=[23,37,38],h=[4,6,9,11,23,40],d=[33,34,35,36],p=[22,29],g={trace:function(){},yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,directive:7,line:8,SPACE:9,statement:10,NEWLINE:11,openDirective:12,typeDirective:13,closeDirective:14,":":15,argDirective:16,entityName:17,relSpec:18,role:19,BLOCK_START:20,attributes:21,BLOCK_STOP:22,ALPHANUM:23,attribute:24,attributeType:25,attributeName:26,attributeKeyType:27,COMMENT:28,ATTRIBUTE_WORD:29,ATTRIBUTE_KEY:30,cardinality:31,relType:32,ZERO_OR_ONE:33,ZERO_OR_MORE:34,ONE_OR_MORE:35,ONLY_ONE:36,NON_IDENTIFYING:37,IDENTIFYING:38,WORD:39,open_directive:40,type_directive:41,arg_directive:42,close_directive:43,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",9:"SPACE",11:"NEWLINE",15:":",20:"BLOCK_START",22:"BLOCK_STOP",23:"ALPHANUM",28:"COMMENT",29:"ATTRIBUTE_WORD",30:"ATTRIBUTE_KEY",33:"ZERO_OR_ONE",34:"ZERO_OR_MORE",35:"ONE_OR_MORE",36:"ONLY_ONE",37:"NON_IDENTIFYING",38:"IDENTIFYING",39:"WORD",40:"open_directive",41:"type_directive",42:"arg_directive",43:"close_directive"},productions_:[0,[3,3],[3,2],[5,0],[5,2],[8,2],[8,1],[8,1],[8,1],[7,4],[7,6],[10,1],[10,5],[10,4],[10,3],[10,1],[17,1],[21,1],[21,2],[24,2],[24,3],[24,3],[24,4],[25,1],[26,1],[27,1],[18,3],[31,1],[31,1],[31,1],[31,1],[32,1],[32,1],[19,1],[19,1],[12,1],[13,1],[16,1],[14,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 1:break;case 3:case 7:case 8:this.$=[];break;case 4:a[s-1].push(a[s]),this.$=a[s-1];break;case 5:case 6:case 16:case 23:case 24:case 25:case 34:this.$=a[s];break;case 12:r.addEntity(a[s-4]),r.addEntity(a[s-2]),r.addRelationship(a[s-4],a[s],a[s-2],a[s-3]);break;case 13:r.addEntity(a[s-3]),r.addAttributes(a[s-3],a[s-1]);break;case 14:r.addEntity(a[s-2]);break;case 15:r.addEntity(a[s]);break;case 17:this.$=[a[s]];break;case 18:a[s].push(a[s-1]),this.$=a[s];break;case 19:this.$={attributeType:a[s-1],attributeName:a[s]};break;case 20:this.$={attributeType:a[s-2],attributeName:a[s-1],attributeKeyType:a[s]};break;case 21:this.$={attributeType:a[s-2],attributeName:a[s-1],attributeComment:a[s]};break;case 22:this.$={attributeType:a[s-3],attributeName:a[s-2],attributeKeyType:a[s-1],attributeComment:a[s]};break;case 26:this.$={cardA:a[s],relType:a[s-1],cardB:a[s-2]};break;case 27:this.$=r.Cardinality.ZERO_OR_ONE;break;case 28:this.$=r.Cardinality.ZERO_OR_MORE;break;case 29:this.$=r.Cardinality.ONE_OR_MORE;break;case 30:this.$=r.Cardinality.ONLY_ONE;break;case 31:this.$=r.Identification.NON_IDENTIFYING;break;case 32:this.$=r.Identification.IDENTIFYING;break;case 33:this.$=a[s].replace(/"/g,"");break;case 35:r.parseDirective("%%{","open_directive");break;case 36:r.parseDirective(a[s],"type_directive");break;case 37:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 38:r.parseDirective("}%%","close_directive","er")}},table:[{3:1,4:e,7:3,12:4,40:n},{1:[3]},t(r,[2,3],{5:6}),{3:7,4:e,7:3,12:4,40:n},{13:8,41:[1,9]},{41:[2,35]},{6:[1,10],7:15,8:11,9:[1,12],10:13,11:[1,14],12:4,17:16,23:i,40:n},{1:[2,2]},{14:18,15:[1,19],43:a},t([15,43],[2,36]),t(r,[2,8],{1:[2,1]}),t(r,[2,4]),{7:15,10:21,12:4,17:16,23:i,40:n},t(r,[2,6]),t(r,[2,7]),t(r,[2,11]),t(r,[2,15],{18:22,31:24,20:[1,23],33:o,34:s,35:c,36:u}),t([6,9,11,15,20,23,33,34,35,36,40],[2,16]),{11:[1,29]},{16:30,42:[1,31]},{11:[2,38]},t(r,[2,5]),{17:32,23:i},{21:33,22:[1,34],24:35,25:36,29:l},{32:38,37:[1,39],38:[1,40]},t(f,[2,27]),t(f,[2,28]),t(f,[2,29]),t(f,[2,30]),t(h,[2,9]),{14:41,43:a},{43:[2,37]},{15:[1,42]},{22:[1,43]},t(r,[2,14]),{21:44,22:[2,17],24:35,25:36,29:l},{26:45,29:[1,46]},{29:[2,23]},{31:47,33:o,34:s,35:c,36:u},t(d,[2,31]),t(d,[2,32]),{11:[1,48]},{19:49,23:[1,51],39:[1,50]},t(r,[2,13]),{22:[2,18]},t(p,[2,19],{27:52,28:[1,53],30:[1,54]}),t([22,28,29,30],[2,24]),{23:[2,26]},t(h,[2,10]),t(r,[2,12]),t(r,[2,33]),t(r,[2,34]),t(p,[2,20],{28:[1,55]}),t(p,[2,21]),t([22,28,29],[2,25]),t(p,[2,22])],defaultActions:{5:[2,35],7:[2,2],20:[2,38],31:[2,37],37:[2,23],44:[2,18],47:[2,26]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},y={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),40;case 1:return this.begin("type_directive"),41;case 2:return this.popState(),this.begin("arg_directive"),15;case 3:return this.popState(),this.popState(),43;case 4:return 42;case 5:case 6:case 8:case 13:case 17:break;case 7:return 11;case 9:return 9;case 10:return 39;case 11:return 4;case 12:return this.begin("block"),20;case 14:return 30;case 15:return 29;case 16:return 28;case 18:return this.popState(),22;case 19:case 32:return e.yytext[0];case 20:case 24:return 33;case 21:case 25:return 34;case 22:case 26:return 35;case 23:return 36;case 27:case 29:case 30:return 37;case 28:return 38;case 31:return 23;case 33:return 6}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:[\s]+)/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:\s+)/i,/^(?:(?:PK)|(?:FK))/i,/^(?:[A-Za-z][A-Za-z0-9\-_]*)/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\|o\b)/i,/^(?:\}o\b)/i,/^(?:\}\|)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:[A-Za-z][A-Za-z0-9\-_]*)/i,/^(?:.)/i,/^(?:$)/i],conditions:{open_directive:{rules:[1],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},block:{rules:[13,14,15,16,17,18,19],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,11,12,20,21,22,23,24,25,26,27,28,29,30,31,32,33],inclusive:!0}}};function m(){this.yy={}}return g.lexer=y,m.prototype=g,g.Parser=m,new m}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/er/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return"\n .entityBox {\n fill: ".concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n }\n\n .attributeBoxOdd {\n fill: #ffffff;\n stroke: ").concat(t.nodeBorder,";\n }\n\n .attributeBoxEven {\n fill: #f2f2f2;\n stroke: ").concat(t.nodeBorder,";\n }\n\n .relationshipLabelBox {\n fill: ").concat(t.tertiaryColor,";\n opacity: 0.7;\n background-color: ").concat(t.tertiaryColor,";\n rect {\n opacity: 0.5;\n }\n }\n\n .relationshipLine {\n stroke: ").concat(t.lineColor,";\n }\n")}},"./src/diagrams/flowchart/flowChartShapes.js":function(t,e,n){"use strict";n.r(e),n.d(e,"addToRender",(function(){return y})),n.d(e,"addToRenderV2",(function(){return m}));var r=n("dagre-d3"),i=n.n(r);function a(t,e,n){var r=.9*(e.width+e.height),a=[{x:r/2,y:0},{x:r,y:-r/2},{x:r/2,y:-r},{x:0,y:-r/2}],o=v(t,r,r,a);return n.intersect=function(t){return i.a.intersect.polygon(n,a,t)},o}function o(t,e,n){var r=e.height,a=r/4,o=e.width+2*a,s=[{x:a,y:0},{x:o-a,y:0},{x:o,y:-r/2},{x:o-a,y:-r},{x:a,y:-r},{x:0,y:-r/2}],c=v(t,o,r,s);return n.intersect=function(t){return i.a.intersect.polygon(n,s,t)},c}function s(t,e,n){var r=e.width,a=e.height,o=[{x:-a/2,y:0},{x:r,y:0},{x:r,y:-a},{x:-a/2,y:-a},{x:0,y:-a/2}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function c(t,e,n){var r=e.width,a=e.height,o=[{x:-2*a/6,y:0},{x:r-a/6,y:0},{x:r+2*a/6,y:-a},{x:a/6,y:-a}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function u(t,e,n){var r=e.width,a=e.height,o=[{x:2*a/6,y:0},{x:r+a/6,y:0},{x:r-2*a/6,y:-a},{x:-a/6,y:-a}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function l(t,e,n){var r=e.width,a=e.height,o=[{x:-2*a/6,y:0},{x:r+2*a/6,y:0},{x:r-a/6,y:-a},{x:a/6,y:-a}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function f(t,e,n){var r=e.width,a=e.height,o=[{x:a/6,y:0},{x:r-a/6,y:0},{x:r+2*a/6,y:-a},{x:-2*a/6,y:-a}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function h(t,e,n){var r=e.width,a=e.height,o=[{x:0,y:0},{x:r+a/2,y:0},{x:r,y:-a/2},{x:r+a/2,y:-a},{x:0,y:-a}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function d(t,e,n){var r=e.height,a=e.width+r/4,o=t.insert("rect",":first-child").attr("rx",r/2).attr("ry",r/2).attr("x",-a/2).attr("y",-r/2).attr("width",a).attr("height",r);return n.intersect=function(t){return i.a.intersect.rect(n,t)},o}function p(t,e,n){var r=e.width,a=e.height,o=[{x:0,y:0},{x:r,y:0},{x:r,y:-a},{x:0,y:-a},{x:0,y:0},{x:-8,y:0},{x:r+8,y:0},{x:r+8,y:-a},{x:-8,y:-a},{x:-8,y:0}],s=v(t,r,a,o);return n.intersect=function(t){return i.a.intersect.polygon(n,o,t)},s}function g(t,e,n){var r=e.width,a=r/2,o=a/(2.5+r/50),s=e.height+o,c="M 0,"+o+" a "+a+","+o+" 0,0,0 "+r+" 0 a "+a+","+o+" 0,0,0 "+-r+" 0 l 0,"+s+" a "+a+","+o+" 0,0,0 "+r+" 0 l 0,"+-s,u=t.attr("label-offset-y",o).insert("path",":first-child").attr("d",c).attr("transform","translate("+-r/2+","+-(s/2+o)+")");return n.intersect=function(t){var e=i.a.intersect.rect(n,t),r=e.x-n.x;if(0!=a&&(Math.abs(r)<n.width/2||Math.abs(r)==n.width/2&&Math.abs(e.y-n.y)>n.height/2-o)){var s=o*o*(1-r*r/(a*a));0!=s&&(s=Math.sqrt(s)),s=o-s,t.y-n.y>0&&(s=-s),e.y+=s}return e},u}function y(t){t.shapes().question=a,t.shapes().hexagon=o,t.shapes().stadium=d,t.shapes().subroutine=p,t.shapes().cylinder=g,t.shapes().rect_left_inv_arrow=s,t.shapes().lean_right=c,t.shapes().lean_left=u,t.shapes().trapezoid=l,t.shapes().inv_trapezoid=f,t.shapes().rect_right_inv_arrow=h}function m(t){t({question:a}),t({hexagon:o}),t({stadium:d}),t({subroutine:p}),t({cylinder:g}),t({rect_left_inv_arrow:s}),t({lean_right:c}),t({lean_left:u}),t({trapezoid:l}),t({inv_trapezoid:f}),t({rect_right_inv_arrow:h})}function v(t,e,n,r){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("transform","translate("+-e/2+","+n/2+")")}e.default={addToRender:y,addToRenderV2:m}},"./src/diagrams/flowchart/flowDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return T})),n.d(e,"lookUpDomId",(function(){return E})),n.d(e,"addVertex",(function(){return C})),n.d(e,"addSingleLink",(function(){return S})),n.d(e,"addLink",(function(){return M})),n.d(e,"updateLinkInterpolate",(function(){return A})),n.d(e,"updateLink",(function(){return O})),n.d(e,"addClass",(function(){return N})),n.d(e,"setDirection",(function(){return j})),n.d(e,"setClass",(function(){return D})),n.d(e,"setLink",(function(){return B})),n.d(e,"getTooltip",(function(){return L})),n.d(e,"setClickEvent",(function(){return I})),n.d(e,"bindFunctions",(function(){return R})),n.d(e,"getDirection",(function(){return P})),n.d(e,"getVertices",(function(){return F})),n.d(e,"getEdges",(function(){return z})),n.d(e,"getClasses",(function(){return Y})),n.d(e,"clear",(function(){return U})),n.d(e,"setGen",(function(){return V})),n.d(e,"defaultStyle",(function(){return W})),n.d(e,"addSubGraph",(function(){return H})),n.d(e,"getDepthFirstPos",(function(){return K})),n.d(e,"indexNodes",(function(){return Q})),n.d(e,"getSubGraphs",(function(){return J})),n.d(e,"firstGraph",(function(){return tt}));var r=n("d3"),i=n("./src/utils.js"),a=n("./src/config.js"),o=n("./src/diagrams/common/common.js"),s=n("./src/mermaidAPI.js"),c=n("./src/logger.js");function u(t){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},u(t)}function l(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var f,h,d=0,p=a.getConfig(),g={},y=[],m=[],v=[],b={},_={},x=0,w=!0,k=[],T=function(t,e,n){s.default.parseDirective(this,t,e,n)},E=function(t){for(var e=Object.keys(g),n=0;n<e.length;n++)if(g[e[n]].id===t)return g[e[n]].domId;return t},C=function(t,e,n,r,i,s){var c,u=t;void 0!==u&&0!==u.trim().length&&(void 0===g[u]&&(g[u]={id:u,domId:"flowchart-"+u+"-"+d,styles:[],classes:[]}),d++,void 0!==e?(p=a.getConfig(),'"'===(c=o.default.sanitizeText(e.trim(),p))[0]&&'"'===c[c.length-1]&&(c=c.substring(1,c.length-1)),g[u].text=c):void 0===g[u].text&&(g[u].text=t),void 0!==n&&(g[u].type=n),null!=r&&r.forEach((function(t){g[u].styles.push(t)})),null!=i&&i.forEach((function(t){g[u].classes.push(t)})),void 0!==s&&(g[u].dir=s))},S=function(t,e,n,r){var i={start:t,end:e,type:void 0,text:""};void 0!==(r=n.text)&&(i.text=o.default.sanitizeText(r.trim(),p),'"'===i.text[0]&&'"'===i.text[i.text.length-1]&&(i.text=i.text.substring(1,i.text.length-1))),void 0!==n&&(i.type=n.type,i.stroke=n.stroke,i.length=n.length),y.push(i)},M=function(t,e,n,r){var i,a;for(i=0;i<t.length;i++)for(a=0;a<e.length;a++)S(t[i],e[a],n,r)},A=function(t,e){t.forEach((function(t){"default"===t?y.defaultInterpolate=e:y[t].interpolate=e}))},O=function(t,e){t.forEach((function(t){"default"===t?y.defaultStyle=e:(-1===i.default.isSubstringInArray("fill",e)&&e.push("fill:none"),y[t].style=e)}))},N=function(t,e){void 0===m[t]&&(m[t]={id:t,styles:[],textStyles:[]}),null!=e&&e.forEach((function(e){if(e.match("color")){var n=e.replace("fill","bgFill").replace("color","fill");m[t].textStyles.push(n)}m[t].styles.push(e)}))},j=function(t){(f=t).match(/.*</)&&(f="RL"),f.match(/.*\^/)&&(f="BT"),f.match(/.*>/)&&(f="LR"),f.match(/.*v/)&&(f="TB")},D=function(t,e){t.split(",").forEach((function(t){var n=t;void 0!==g[n]&&g[n].classes.push(e),void 0!==b[n]&&b[n].classes.push(e)}))},B=function(t,e,n){t.split(",").forEach((function(t){void 0!==g[t]&&(g[t].link=i.default.formatUrl(e,p),g[t].linkTarget=n)})),D(t,"clickable")},L=function(t){return _[t]},I=function(t,e,n){t.split(",").forEach((function(t){!function(t,e,n){var r=E(t);if("loose"===a.getConfig().securityLevel&&void 0!==e){var o=[];if("string"==typeof n){o=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(var s=0;s<o.length;s++){var c=o[s].trim();'"'===c.charAt(0)&&'"'===c.charAt(c.length-1)&&(c=c.substr(1,c.length-2)),o[s]=c}}0===o.length&&o.push(t),void 0!==g[t]&&(g[t].haveCallback=!0,k.push((function(){var t=document.querySelector('[id="'.concat(r,'"]'));null!==t&&t.addEventListener("click",(function(){var t;i.default.runFunc.apply(i.default,[e].concat(function(t){if(Array.isArray(t))return l(t)}(t=o)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return l(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}),!1)})))}}(t,e,n)})),D(t,"clickable")},R=function(t){k.forEach((function(e){e(t)}))},P=function(){return f.trim()},F=function(){return g},z=function(){return y},Y=function(){return m},q=function(t){var e=Object(r.select)(".mermaidTooltip");null===(e._groups||e)[0][0]&&(e=Object(r.select)("body").append("div").attr("class","mermaidTooltip").style("opacity",0)),Object(r.select)(t).select("svg").selectAll("g.node").on("mouseover",(function(){var t=Object(r.select)(this);if(null!==t.attr("title")){var n=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(t.attr("title")).style("left",window.scrollX+n.left+(n.right-n.left)/2+"px").style("top",window.scrollY+n.top-14+document.body.scrollTop+"px"),t.classed("hover",!0)}})).on("mouseout",(function(){e.transition().duration(500).style("opacity",0),Object(r.select)(this).classed("hover",!1)}))};k.push(q);var U=function(t){g={},m={},y=[],(k=[]).push(q),v=[],b={},x=0,_=[],w=!0,h=t||"gen-1"},V=function(t){h=t||"gen-1"},W=function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},H=function(t,e,n){var r=t.trim(),i=n;t===n&&n.match(/\s/)&&(r=void 0);var a=[],s=function(t){var e,n={boolean:{},number:{},string:{}},r=[];return{nodeList:t.filter((function(t){var i=u(t);return t.stmt&&"dir"===t.stmt?(e=t.value,!1):""!==t.trim()&&(i in n?!n[i].hasOwnProperty(t)&&(n[i][t]=!0):!(r.indexOf(t)>=0)&&r.push(t))})),dir:e}}(a.concat.apply(a,e)),l=s.nodeList,f=s.dir;if(a=l,"gen-1"===h){c.log.warn("LOOKING UP");for(var d=0;d<a.length;d++)a[d]=E(a[d])}r=r||"subGraph"+x,i=i||"",i=o.default.sanitizeText(i,p),x+=1;var g={id:r,nodes:a,title:i.trim(),classes:[],dir:f};return c.log.info("Adding",g.id,g.nodes,g.dir),g.nodes=nt(g,v).nodes,v.push(g),b[r]=g,r},$=function(t){for(var e=0;e<v.length;e++)if(v[e].id===t)return e;return-1},G=-1,X=[],Z=function t(e,n){var r=v[n].nodes;if(!((G+=1)>2e3)){if(X[G]=n,v[n].id===e)return{result:!0,count:0};for(var i=0,a=1;i<r.length;){var o=$(r[i]);if(o>=0){var s=t(e,o);if(s.result)return{result:!0,count:a+s.count};a+=s.count}i+=1}return{result:!1,count:a}}},K=function(t){return X[t]},Q=function(){G=-1,v.length>0&&Z("none",v.length-1)},J=function(){return v},tt=function(){return!!w&&(w=!1,!0)},et=function(t,e){var n=!1;return t.forEach((function(t){t.nodes.indexOf(e)>=0&&(n=!0)})),n},nt=function(t,e){var n=[];return t.nodes.forEach((function(r,i){et(e,r)||n.push(t.nodes[i])})),{nodes:n}};e.default={parseDirective:T,defaultConfig:function(){return a.defaultConfig.flowchart},addVertex:C,lookUpDomId:E,addLink:M,updateLinkInterpolate:A,updateLink:O,addClass:N,setDirection:j,setClass:D,setTooltip:function(t,e){t.split(",").forEach((function(t){void 0!==e&&(_["gen-1"===h?E(t):t]=o.default.sanitizeText(e,p))}))},getTooltip:L,setClickEvent:I,setLink:B,bindFunctions:R,getDirection:P,getVertices:F,getEdges:z,getClasses:Y,clear:U,setGen:V,defaultStyle:W,addSubGraph:H,getDepthFirstPos:K,indexNodes:Q,getSubGraphs:J,destructLink:function(t,e){var n,r=function(t){var e=t.trim(),n=e.slice(0,-1),r="arrow_open";switch(e.slice(-1)){case"x":r="arrow_cross","x"===e[0]&&(r="double_"+r,n=n.slice(1));break;case">":r="arrow_point","<"===e[0]&&(r="double_"+r,n=n.slice(1));break;case"o":r="arrow_circle","o"===e[0]&&(r="double_"+r,n=n.slice(1))}var i="normal",a=n.length-1;"="===n[0]&&(i="thick");var o=function(t,e){for(var n=e.length,r=0,i=0;i<n;++i)"."===e[i]&&++r;return r}(0,n);return o&&(i="dotted",a=o),{type:r,stroke:i,length:a}}(t);if(e){if(n=function(t){var e=t.trim(),n="arrow_open";switch(e[0]){case"<":n="arrow_point",e=e.slice(1);break;case"x":n="arrow_cross",e=e.slice(1);break;case"o":n="arrow_circle",e=e.slice(1)}var r="normal";return-1!==e.indexOf("=")&&(r="thick"),-1!==e.indexOf(".")&&(r="dotted"),{type:n,stroke:r}}(e),n.stroke!==r.stroke)return{type:"INVALID",stroke:"INVALID"};if("arrow_open"===n.type)n.type=r.type;else{if(n.type!==r.type)return{type:"INVALID",stroke:"INVALID"};n.type="double_"+n.type}return"double_arrow"===n.type&&(n.type="double_arrow_point"),n.length=r.length,n}return r},lex:{firstGraph:tt},exists:et,makeUniq:nt}},"./src/diagrams/flowchart/flowRenderer-v2.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return m})),n.d(e,"addVertices",(function(){return v})),n.d(e,"addEdges",(function(){return b})),n.d(e,"getClasses",(function(){return _})),n.d(e,"draw",(function(){return x}));var r=n("graphlib"),i=n.n(r),a=n("d3"),o=n("./src/diagrams/flowchart/flowDb.js"),s=n("./src/diagrams/flowchart/parser/flow.jison"),c=n.n(s),u=n("./src/config.js"),l=n("./src/dagre-wrapper/index.js"),f=n("dagre-d3/lib/label/add-html-label.js"),h=n.n(f),d=n("./src/logger.js"),p=n("./src/diagrams/common/common.js"),g=n("./src/utils.js"),y={},m=function(t){for(var e=Object.keys(t),n=0;n<e.length;n++)y[e[n]]=t[e[n]]},v=function(t,e,n){var r=Object(a.select)('[id="'.concat(n,'"]'));Object.keys(t).forEach((function(n){var i=t[n],a="default";i.classes.length>0&&(a=i.classes.join(" "));var s,c=Object(g.getStylesFromArray)(i.styles),l=void 0!==i.text?i.text:i.id;if(Object(p.evaluate)(Object(u.getConfig)().flowchart.htmlLabels)){var f={label:l.replace(/fa[lrsb]?:fa-[\w-]+/g,(function(t){return"<i class='".concat(t.replace(":"," "),"'></i>")}))};(s=h()(r,f).node()).parentNode.removeChild(s)}else{var y=document.createElementNS("http://www.w3.org/2000/svg","text");y.setAttribute("style",c.labelStyle.replace("color:","fill:"));for(var m=l.split(p.default.lineBreakRegex),v=0;v<m.length;v++){var b=document.createElementNS("http://www.w3.org/2000/svg","tspan");b.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),b.setAttribute("dy","1em"),b.setAttribute("x","1"),b.textContent=m[v],y.appendChild(b)}s=y}var _=0,x="";switch(i.type){case"round":_=5,x="rect";break;default:x="rect";break;case"diamond":x="question";break;case"hexagon":x="hexagon";break;case"odd":case"odd_right":x="rect_left_inv_arrow";break;case"lean_right":x="lean_right";break;case"lean_left":x="lean_left";break;case"trapezoid":x="trapezoid";break;case"inv_trapezoid":x="inv_trapezoid";break;case"circle":x="circle";break;case"ellipse":x="ellipse";break;case"stadium":x="stadium";break;case"subroutine":x="subroutine";break;case"cylinder":x="cylinder"}e.setNode(i.id,{labelStyle:c.labelStyle,shape:x,labelText:l,rx:_,ry:_,class:a,style:c.style,id:i.id,link:i.link,linkTarget:i.linkTarget,tooltip:o.default.getTooltip(i.id)||"",domId:o.default.lookUpDomId(i.id),haveCallback:i.haveCallback,width:"group"===i.type?500:void 0,dir:i.dir,type:i.type,padding:Object(u.getConfig)().flowchart.padding}),d.log.info("setNode",{labelStyle:c.labelStyle,shape:x,labelText:l,rx:_,ry:_,class:a,style:c.style,id:i.id,domId:o.default.lookUpDomId(i.id),width:"group"===i.type?500:void 0,type:i.type,dir:i.dir,padding:Object(u.getConfig)().flowchart.padding})}))},b=function(t,e){d.log.info("abc78 edges = ",t);var n,r,i=0,o={};if(void 0!==t.defaultStyle){var s=Object(g.getStylesFromArray)(t.defaultStyle);n=s.style,r=s.labelStyle}t.forEach((function(s){i++;var c="L-"+s.start+"-"+s.end;void 0===o[c]?(o[c]=0,d.log.info("abc78 new entry",c,o[c])):(o[c]++,d.log.info("abc78 new entry",c,o[c]));var u=c+"-"+o[c];d.log.info("abc78 new link id to be used is",c,u,o[c]);var l="LS-"+s.start,f="LE-"+s.end,h={style:"",labelStyle:""};switch(h.minlen=s.length||1,"arrow_open"===s.type?h.arrowhead="none":h.arrowhead="normal",h.arrowTypeStart="arrow_open",h.arrowTypeEnd="arrow_open",s.type){case"double_arrow_cross":h.arrowTypeStart="arrow_cross";case"arrow_cross":h.arrowTypeEnd="arrow_cross";break;case"double_arrow_point":h.arrowTypeStart="arrow_point";case"arrow_point":h.arrowTypeEnd="arrow_point";break;case"double_arrow_circle":h.arrowTypeStart="arrow_circle";case"arrow_circle":h.arrowTypeEnd="arrow_circle"}var m="",v="";switch(s.stroke){case"normal":m="fill:none;",void 0!==n&&(m=n),void 0!==r&&(v=r),h.thickness="normal",h.pattern="solid";break;case"dotted":h.thickness="normal",h.pattern="dotted",h.style="fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":h.thickness="thick",h.pattern="solid",h.style="stroke-width: 3.5px;fill:none;"}if(void 0!==s.style){var b=Object(g.getStylesFromArray)(s.style);m=b.style,v=b.labelStyle}h.style=h.style+=m,h.labelStyle=h.labelStyle+=v,void 0!==s.interpolate?h.curve=Object(g.interpolateToCurve)(s.interpolate,a.curveLinear):void 0!==t.defaultInterpolate?h.curve=Object(g.interpolateToCurve)(t.defaultInterpolate,a.curveLinear):h.curve=Object(g.interpolateToCurve)(y.curve,a.curveLinear),void 0===s.text?void 0!==s.style&&(h.arrowheadStyle="fill: #333"):(h.arrowheadStyle="fill: #333",h.labelpos="c"),h.labelType="text",h.label=s.text.replace(p.default.lineBreakRegex,"\n"),void 0===s.style&&(h.style=h.style||"stroke: #333; stroke-width: 1.5px;fill:none;"),h.labelStyle=h.labelStyle.replace("color:","fill:"),h.id=u,h.classes="flowchart-link "+l+" "+f,e.setEdge(s.start,s.end,h,i)}))},_=function(t){d.log.info("Extracting classes"),o.default.clear();var e=c.a.parser;e.yy=o.default;try{e.parse(t)}catch(t){return}return o.default.getClasses()},x=function(t,e){d.log.info("Drawing flowchart"),o.default.clear(),o.default.setGen("gen-2");var n=c.a.parser;n.yy=o.default,n.parse(t);var r=o.default.getDirection();void 0===r&&(r="TD");var s,f=Object(u.getConfig)().flowchart,h=f.nodeSpacing||50,p=f.rankSpacing||50,y=new i.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:r,nodesep:h,ranksep:p,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}})),m=o.default.getSubGraphs();d.log.info("Subgraphs - ",m);for(var _=m.length-1;_>=0;_--)s=m[_],d.log.info("Subgraph - ",s),o.default.addVertex(s.id,s.title,"group",void 0,s.classes,s.dir);var x=o.default.getVertices(),w=o.default.getEdges();d.log.info(w);var k=0;for(k=m.length-1;k>=0;k--){s=m[k],Object(a.selectAll)("cluster").append("text");for(var T=0;T<s.nodes.length;T++)d.log.info("Setting up subgraphs",s.nodes[T],s.id),y.setParent(s.nodes[T],s.id)}v(x,y,e),b(w,y);var E=Object(a.select)('[id="'.concat(e,'"]'));E.attr("xmlns:xlink","http://www.w3.org/1999/xlink");var C=Object(a.select)("#"+e+" g");Object(l.render)(C,y,["point","circle","cross"],"flowchart",e);var S=f.diagramPadding,M=E.node().getBBox(),A=M.width+2*S,O=M.height+2*S;if(d.log.debug("new ViewBox 0 0 ".concat(A," ").concat(O),"translate(".concat(S-y._label.marginx,", ").concat(S-y._label.marginy,")")),Object(g.configureSvgSize)(E,O,A,f.useMaxWidth),E.attr("viewBox","0 0 ".concat(A," ").concat(O)),E.select("g").attr("transform","translate(".concat(S-y._label.marginx,", ").concat(S-M.y,")")),o.default.indexNodes("subGraph"+k),!f.htmlLabels)for(var N=document.querySelectorAll('[id="'+e+'"] .edgeLabel .label'),j=0;j<N.length;j++){var D=N[j],B=D.getBBox(),L=document.createElementNS("http://www.w3.org/2000/svg","rect");L.setAttribute("rx",0),L.setAttribute("ry",0),L.setAttribute("width",B.width),L.setAttribute("height",B.height),D.insertBefore(L,D.firstChild)}Object.keys(x).forEach((function(t){var n=x[t];if(n.link){var r=Object(a.select)("#"+e+' [id="'+t+'"]');if(r){var i=document.createElementNS("http://www.w3.org/2000/svg","a");i.setAttributeNS("http://www.w3.org/2000/svg","class",n.classes.join(" ")),i.setAttributeNS("http://www.w3.org/2000/svg","href",n.link),i.setAttributeNS("http://www.w3.org/2000/svg","rel","noopener"),n.linkTarget&&i.setAttributeNS("http://www.w3.org/2000/svg","target",n.linkTarget);var o=r.insert((function(){return i}),":first-child"),s=r.select(".label-container");s&&o.append((function(){return s.node()}));var c=r.select(".label");c&&o.append((function(){return c.node()}))}}}))};e.default={setConf:m,addVertices:v,addEdges:b,getClasses:_,draw:x}},"./src/diagrams/flowchart/flowRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return b})),n.d(e,"addVertices",(function(){return _})),n.d(e,"addEdges",(function(){return x})),n.d(e,"getClasses",(function(){return w})),n.d(e,"draw",(function(){return k}));var r=n("graphlib"),i=n.n(r),a=n("d3"),o=n("./src/diagrams/flowchart/flowDb.js"),s=n("./src/diagrams/flowchart/parser/flow.jison"),c=n.n(s),u=n("./src/config.js"),l=n("dagre-d3"),f=n.n(l),h=n("dagre-d3/lib/label/add-html-label.js"),d=n.n(h),p=n("./src/logger.js"),g=n("./src/diagrams/common/common.js"),y=n("./src/utils.js"),m=n("./src/diagrams/flowchart/flowChartShapes.js"),v={},b=function(t){for(var e=Object.keys(t),n=0;n<e.length;n++)v[e[n]]=t[e[n]]},_=function(t,e,n){var r=Object(a.select)('[id="'.concat(n,'"]'));Object.keys(t).forEach((function(n){var i=t[n],a="default";i.classes.length>0&&(a=i.classes.join(" "));var s,c=Object(y.getStylesFromArray)(i.styles),l=void 0!==i.text?i.text:i.id;if(Object(g.evaluate)(Object(u.getConfig)().flowchart.htmlLabels)){var f={label:l.replace(/fa[lrsb]?:fa-[\w-]+/g,(function(t){return"<i class='".concat(t.replace(":"," "),"'></i>")}))};(s=d()(r,f).node()).parentNode.removeChild(s)}else{var h=document.createElementNS("http://www.w3.org/2000/svg","text");h.setAttribute("style",c.labelStyle.replace("color:","fill:"));for(var m=l.split(g.default.lineBreakRegex),v=0;v<m.length;v++){var b=document.createElementNS("http://www.w3.org/2000/svg","tspan");b.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),b.setAttribute("dy","1em"),b.setAttribute("x","1"),b.textContent=m[v],h.appendChild(b)}s=h}var _=0,x="";switch(i.type){case"round":_=5,x="rect";break;default:x="rect";break;case"diamond":x="question";break;case"hexagon":x="hexagon";break;case"odd":case"odd_right":x="rect_left_inv_arrow";break;case"lean_right":x="lean_right";break;case"lean_left":x="lean_left";break;case"trapezoid":x="trapezoid";break;case"inv_trapezoid":x="inv_trapezoid";break;case"circle":x="circle";break;case"ellipse":x="ellipse";break;case"stadium":x="stadium";break;case"subroutine":x="subroutine";break;case"cylinder":x="cylinder"}p.log.warn("Adding node",i.id,i.domId),e.setNode(o.default.lookUpDomId(i.id),{labelType:"svg",labelStyle:c.labelStyle,shape:x,label:s,rx:_,ry:_,class:a,style:c.style,id:o.default.lookUpDomId(i.id)})}))},x=function(t,e){var n,r,i=0;if(void 0!==t.defaultStyle){var s=Object(y.getStylesFromArray)(t.defaultStyle);n=s.style,r=s.labelStyle}t.forEach((function(s){i++;var c="L-"+s.start+"-"+s.end,l="LS-"+s.start,f="LE-"+s.end,h={};"arrow_open"===s.type?h.arrowhead="none":h.arrowhead="normal";var d="",p="";if(void 0!==s.style){var m=Object(y.getStylesFromArray)(s.style);d=m.style,p=m.labelStyle}else switch(s.stroke){case"normal":d="fill:none",void 0!==n&&(d=n),void 0!==r&&(p=r);break;case"dotted":d="fill:none;stroke-width:2px;stroke-dasharray:3;";break;case"thick":d=" stroke-width: 3.5px;fill:none"}h.style=d,h.labelStyle=p,void 0!==s.interpolate?h.curve=Object(y.interpolateToCurve)(s.interpolate,a.curveLinear):void 0!==t.defaultInterpolate?h.curve=Object(y.interpolateToCurve)(t.defaultInterpolate,a.curveLinear):h.curve=Object(y.interpolateToCurve)(v.curve,a.curveLinear),void 0===s.text?void 0!==s.style&&(h.arrowheadStyle="fill: #333"):(h.arrowheadStyle="fill: #333",h.labelpos="c",Object(g.evaluate)(Object(u.getConfig)().flowchart.htmlLabels)?(h.labelType="html",h.label='<span id="L-'.concat(c,'" class="edgeLabel L-').concat(l,"' L-").concat(f,'">').concat(s.text.replace(/fa[lrsb]?:fa-[\w-]+/g,(function(t){return"<i class='".concat(t.replace(":"," "),"'></i>")})),"</span>")):(h.labelType="text",h.label=s.text.replace(g.default.lineBreakRegex,"\n"),void 0===s.style&&(h.style=h.style||"stroke: #333; stroke-width: 1.5px;fill:none"),h.labelStyle=h.labelStyle.replace("color:","fill:"))),h.id=c,h.class=l+" "+f,h.minlen=s.length||1,e.setEdge(o.default.lookUpDomId(s.start),o.default.lookUpDomId(s.end),h,i)}))},w=function(t){p.log.info("Extracting classes"),o.default.clear();try{var e=c.a.parser;return e.yy=o.default,e.parse(t),o.default.getClasses()}catch(t){return}},k=function(t,e){p.log.info("Drawing flowchart"),o.default.clear(),o.default.setGen("gen-1");var n=c.a.parser;n.yy=o.default,n.parse(t);var r=o.default.getDirection();void 0===r&&(r="TD");for(var s,l=Object(u.getConfig)().flowchart,h=l.nodeSpacing||50,d=l.rankSpacing||50,v=new i.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:r,nodesep:h,ranksep:d,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}})),b=o.default.getSubGraphs(),w=b.length-1;w>=0;w--)s=b[w],o.default.addVertex(s.id,s.title,"group",void 0,s.classes);var k=o.default.getVertices();p.log.warn("Get vertices",k);var T=o.default.getEdges(),E=0;for(E=b.length-1;E>=0;E--){s=b[E],Object(a.selectAll)("cluster").append("text");for(var C=0;C<s.nodes.length;C++)p.log.warn("Setting subgraph",s.nodes[C],o.default.lookUpDomId(s.nodes[C]),o.default.lookUpDomId(s.id)),v.setParent(o.default.lookUpDomId(s.nodes[C]),o.default.lookUpDomId(s.id))}_(k,v,e),x(T,v);var S=new(0,f.a.render);m.default.addToRender(S),S.arrows().none=function(t,e,n,r){var i=t.append("marker").attr("id",e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","strokeWidth").attr("markerWidth",8).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 0 0 L 0 0 L 0 0 z");f.a.util.applyStyle(i,n[r+"Style"])},S.arrows().normal=function(t,e){t.append("marker").attr("id",e).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerUnits","strokeWidth").attr("markerWidth",8).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowheadPath").style("stroke-width",1).style("stroke-dasharray","1,0")};var M=Object(a.select)('[id="'.concat(e,'"]'));M.attr("xmlns:xlink","http://www.w3.org/1999/xlink"),p.log.warn(v);var A=Object(a.select)("#"+e+" g");S(A,v),A.selectAll("g.node").attr("title",(function(){return o.default.getTooltip(this.id)}));var O=l.diagramPadding,N=M.node().getBBox(),j=N.width+2*O,D=N.height+2*O;Object(y.configureSvgSize)(M,D,j,l.useMaxWidth);var B="".concat(N.x-O," ").concat(N.y-O," ").concat(j," ").concat(D);for(p.log.debug("viewBox ".concat(B)),M.attr("viewBox",B),o.default.indexNodes("subGraph"+E),E=0;E<b.length;E++)if("undefined"!==(s=b[E]).title){var L=document.querySelectorAll("#"+e+' [id="'+o.default.lookUpDomId(s.id)+'"] rect'),I=document.querySelectorAll("#"+e+' [id="'+o.default.lookUpDomId(s.id)+'"]'),R=L[0].x.baseVal.value,P=L[0].y.baseVal.value,F=L[0].width.baseVal.value,z=Object(a.select)(I[0]).select(".label");z.attr("transform","translate(".concat(R+F/2,", ").concat(P+14,")")),z.attr("id",e+"Text");for(var Y=0;Y<s.classes.length;Y++)I[0].classList.add(s.classes[Y])}Object(g.evaluate)(l.htmlLabels);for(var q=document.querySelectorAll('[id="'+e+'"] .edgeLabel .label'),U=0;U<q.length;U++){var V=q[U],W=V.getBBox(),H=document.createElementNS("http://www.w3.org/2000/svg","rect");H.setAttribute("rx",0),H.setAttribute("ry",0),H.setAttribute("width",W.width),H.setAttribute("height",W.height),V.insertBefore(H,V.firstChild)}Object.keys(k).forEach((function(t){var n=k[t];if(n.link){var r=Object(a.select)("#"+e+' [id="'+o.default.lookUpDomId(t)+'"]');if(r){var i=document.createElementNS("http://www.w3.org/2000/svg","a");i.setAttributeNS("http://www.w3.org/2000/svg","class",n.classes.join(" ")),i.setAttributeNS("http://www.w3.org/2000/svg","href",n.link),i.setAttributeNS("http://www.w3.org/2000/svg","rel","noopener"),n.linkTarget&&i.setAttributeNS("http://www.w3.org/2000/svg","target",n.linkTarget);var s=r.insert((function(){return i}),":first-child"),c=r.select(".label-container");c&&s.append((function(){return c.node()}));var u=r.select(".label");u&&s.append((function(){return u.node()}))}}}))};e.default={setConf:b,addVertices:_,addEdges:x,getClasses:w,draw:k}},"./src/diagrams/flowchart/parser/flow.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,9],n=[1,7],r=[1,6],i=[1,8],a=[1,20,21,22,23,38,47,76,77,78,79,80,81,95,96,99,100,101,103,104,110,111,112,113,114,115,116,117,118,119],o=[2,10],s=[1,20],c=[1,21],u=[1,22],l=[1,23],f=[1,30],h=[1,59],d=[1,33],p=[1,34],g=[1,35],y=[1,36],m=[1,37],v=[1,53],b=[1,48],_=[1,50],x=[1,45],w=[1,49],k=[1,52],T=[1,56],E=[1,57],C=[1,38],S=[1,39],M=[1,40],A=[1,41],O=[1,58],N=[1,47],j=[1,51],D=[1,54],B=[1,55],L=[1,46],I=[1,62],R=[1,67],P=[1,20,21,22,23,38,42,47,76,77,78,79,80,81,95,96,99,100,101,103,104,110,111,112,113,114,115,116,117,118,119],F=[1,71],z=[1,70],Y=[1,72],q=[20,21,23,70,71],U=[1,93],V=[1,98],W=[1,95],H=[1,100],$=[1,103],G=[1,101],X=[1,102],Z=[1,96],K=[1,108],Q=[1,107],J=[1,97],tt=[1,99],et=[1,104],nt=[1,105],rt=[1,106],it=[1,109],at=[20,21,22,23,70,71],ot=[20,21,22,23,48,70,71],st=[20,21,22,23,40,47,48,50,52,54,56,58,60,62,63,65,70,71,81,95,96,99,100,101,103,104,114,115,116,117,118,119],ct=[20,21,23],ut=[20,21,23,47,70,71,81,95,96,99,100,101,103,104,114,115,116,117,118,119],lt=[1,12,20,21,22,23,24,38,42,47,76,77,78,79,80,81,95,96,99,100,101,103,104,110,111,112,113,114,115,116,117,118,119],ft=[47,81,95,96,99,100,101,103,104,114,115,116,117,118,119],ht=[1,141],dt=[1,149],pt=[1,150],gt=[1,151],yt=[1,152],mt=[1,136],vt=[1,137],bt=[1,133],_t=[1,144],xt=[1,145],wt=[1,146],kt=[1,147],Tt=[1,148],Et=[1,153],Ct=[1,154],St=[1,139],Mt=[1,142],At=[1,138],Ot=[1,135],Nt=[20,21,22,23,38,42,47,76,77,78,79,80,81,95,96,99,100,101,103,104,110,111,112,113,114,115,116,117,118,119],jt=[1,157],Dt=[20,21,22,23,26,47,81,95,96,99,100,101,103,104,114,115,116,117,118,119],Bt=[20,21,22,23,24,26,38,40,41,42,47,51,53,55,57,59,61,62,64,66,70,71,72,76,77,78,79,80,81,82,85,95,96,99,100,101,103,104,105,106,114,115,116,117,118,119],Lt=[12,21,22,24],It=[22,96],Rt=[1,238],Pt=[1,242],Ft=[1,239],zt=[1,236],Yt=[1,233],qt=[1,234],Ut=[1,235],Vt=[1,237],Wt=[1,240],Ht=[1,241],$t=[1,243],Gt=[1,260],Xt=[20,21,23,96],Zt=[20,21,22,23,76,92,95,96,99,100,101,102,103,104,105],Kt={trace:function(){},yy:{},symbols_:{error:2,start:3,mermaidDoc:4,directive:5,openDirective:6,typeDirective:7,closeDirective:8,separator:9,":":10,argDirective:11,open_directive:12,type_directive:13,arg_directive:14,close_directive:15,graphConfig:16,document:17,line:18,statement:19,SEMI:20,NEWLINE:21,SPACE:22,EOF:23,GRAPH:24,NODIR:25,DIR:26,FirstStmtSeperator:27,ending:28,endToken:29,spaceList:30,spaceListNewline:31,verticeStatement:32,styleStatement:33,linkStyleStatement:34,classDefStatement:35,classStatement:36,clickStatement:37,subgraph:38,text:39,SQS:40,SQE:41,end:42,direction:43,link:44,node:45,vertex:46,AMP:47,STYLE_SEPARATOR:48,idString:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,CYLINDERSTART:58,CYLINDEREND:59,DIAMOND_START:60,DIAMOND_STOP:61,TAGEND:62,TRAPSTART:63,TRAPEND:64,INVTRAPSTART:65,INVTRAPEND:66,linkStatement:67,arrowText:68,TESTSTR:69,START_LINK:70,LINK:71,PIPE:72,textToken:73,STR:74,keywords:75,STYLE:76,LINKSTYLE:77,CLASSDEF:78,CLASS:79,CLICK:80,DOWN:81,UP:82,textNoTags:83,textNoTagsToken:84,DEFAULT:85,stylesOpt:86,alphaNum:87,CALLBACKNAME:88,CALLBACKARGS:89,HREF:90,LINK_TARGET:91,HEX:92,numList:93,INTERPOLATE:94,NUM:95,COMMA:96,style:97,styleComponent:98,ALPHA:99,COLON:100,MINUS:101,UNIT:102,BRKT:103,DOT:104,PCT:105,TAGSTART:106,alphaNumToken:107,idStringToken:108,alphaNumStatement:109,direction_tb:110,direction_bt:111,direction_rl:112,direction_lr:113,PUNCTUATION:114,UNICODE_TEXT:115,PLUS:116,EQUALS:117,MULT:118,UNDERSCORE:119,graphCodeTokens:120,ARROW_CROSS:121,ARROW_POINT:122,ARROW_CIRCLE:123,ARROW_OPEN:124,QUOTE:125,$accept:0,$end:1},terminals_:{2:"error",10:":",12:"open_directive",13:"type_directive",14:"arg_directive",15:"close_directive",20:"SEMI",21:"NEWLINE",22:"SPACE",23:"EOF",24:"GRAPH",25:"NODIR",26:"DIR",38:"subgraph",40:"SQS",41:"SQE",42:"end",47:"AMP",48:"STYLE_SEPARATOR",50:"PS",51:"PE",52:"(-",53:"-)",54:"STADIUMSTART",55:"STADIUMEND",56:"SUBROUTINESTART",57:"SUBROUTINEEND",58:"CYLINDERSTART",59:"CYLINDEREND",60:"DIAMOND_START",61:"DIAMOND_STOP",62:"TAGEND",63:"TRAPSTART",64:"TRAPEND",65:"INVTRAPSTART",66:"INVTRAPEND",69:"TESTSTR",70:"START_LINK",71:"LINK",72:"PIPE",74:"STR",76:"STYLE",77:"LINKSTYLE",78:"CLASSDEF",79:"CLASS",80:"CLICK",81:"DOWN",82:"UP",85:"DEFAULT",88:"CALLBACKNAME",89:"CALLBACKARGS",90:"HREF",91:"LINK_TARGET",92:"HEX",94:"INTERPOLATE",95:"NUM",96:"COMMA",99:"ALPHA",100:"COLON",101:"MINUS",102:"UNIT",103:"BRKT",104:"DOT",105:"PCT",106:"TAGSTART",110:"direction_tb",111:"direction_bt",112:"direction_rl",113:"direction_lr",114:"PUNCTUATION",115:"UNICODE_TEXT",116:"PLUS",117:"EQUALS",118:"MULT",119:"UNDERSCORE",121:"ARROW_CROSS",122:"ARROW_POINT",123:"ARROW_CIRCLE",124:"ARROW_OPEN",125:"QUOTE"},productions_:[0,[3,1],[3,2],[5,4],[5,6],[6,1],[7,1],[11,1],[8,1],[4,2],[17,0],[17,2],[18,1],[18,1],[18,1],[18,1],[18,1],[16,2],[16,2],[16,2],[16,3],[28,2],[28,1],[29,1],[29,1],[29,1],[27,1],[27,1],[27,2],[31,2],[31,2],[31,1],[31,1],[30,2],[30,1],[19,2],[19,2],[19,2],[19,2],[19,2],[19,2],[19,9],[19,6],[19,4],[19,1],[9,1],[9,1],[9,1],[32,3],[32,4],[32,2],[32,1],[45,1],[45,5],[45,3],[46,4],[46,6],[46,4],[46,4],[46,4],[46,4],[46,4],[46,4],[46,6],[46,4],[46,4],[46,4],[46,4],[46,4],[46,1],[44,2],[44,3],[44,3],[44,1],[44,3],[67,1],[68,3],[39,1],[39,2],[39,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[75,1],[83,1],[83,2],[35,5],[35,5],[36,5],[37,2],[37,4],[37,3],[37,5],[37,2],[37,4],[37,4],[37,6],[37,2],[37,4],[37,2],[37,4],[37,4],[37,6],[33,5],[33,5],[34,5],[34,5],[34,9],[34,9],[34,7],[34,7],[93,1],[93,3],[86,1],[86,3],[97,1],[97,2],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[98,1],[73,1],[73,1],[73,1],[73,1],[73,1],[73,1],[84,1],[84,1],[84,1],[84,1],[49,1],[49,2],[87,1],[87,2],[109,1],[109,1],[109,1],[109,1],[43,1],[43,1],[43,1],[43,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 5:r.parseDirective("%%{","open_directive");break;case 6:r.parseDirective(a[s],"type_directive");break;case 7:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 8:r.parseDirective("}%%","close_directive","flowchart");break;case 10:case 36:case 37:case 38:case 39:case 40:this.$=[];break;case 11:a[s]!==[]&&a[s-1].push(a[s]),this.$=a[s-1];break;case 12:case 77:case 79:case 91:case 147:case 149:case 150:case 73:case 145:this.$=a[s];break;case 19:r.setDirection("TB"),this.$="TB";break;case 20:r.setDirection(a[s-1]),this.$=a[s-1];break;case 35:this.$=a[s-1].nodes;break;case 41:this.$=r.addSubGraph(a[s-6],a[s-1],a[s-4]);break;case 42:this.$=r.addSubGraph(a[s-3],a[s-1],a[s-3]);break;case 43:this.$=r.addSubGraph(void 0,a[s-1],void 0);break;case 48:r.addLink(a[s-2].stmt,a[s],a[s-1]),this.$={stmt:a[s],nodes:a[s].concat(a[s-2].nodes)};break;case 49:r.addLink(a[s-3].stmt,a[s-1],a[s-2]),this.$={stmt:a[s-1],nodes:a[s-1].concat(a[s-3].nodes)};break;case 50:this.$={stmt:a[s-1],nodes:a[s-1]};break;case 51:this.$={stmt:a[s],nodes:a[s]};break;case 52:case 118:case 120:this.$=[a[s]];break;case 53:this.$=a[s-4].concat(a[s]);break;case 54:this.$=[a[s-2]],r.setClass(a[s-2],a[s]);break;case 55:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"square");break;case 56:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],"circle");break;case 57:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"ellipse");break;case 58:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"stadium");break;case 59:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"subroutine");break;case 60:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"cylinder");break;case 61:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"round");break;case 62:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"diamond");break;case 63:this.$=a[s-5],r.addVertex(a[s-5],a[s-2],"hexagon");break;case 64:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"odd");break;case 65:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"trapezoid");break;case 66:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"inv_trapezoid");break;case 67:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"lean_right");break;case 68:this.$=a[s-3],r.addVertex(a[s-3],a[s-1],"lean_left");break;case 69:this.$=a[s],r.addVertex(a[s]);break;case 70:a[s-1].text=a[s],this.$=a[s-1];break;case 71:case 72:a[s-2].text=a[s-1],this.$=a[s-2];break;case 74:var c=r.destructLink(a[s],a[s-2]);this.$={type:c.type,stroke:c.stroke,length:c.length,text:a[s-1]};break;case 75:c=r.destructLink(a[s]),this.$={type:c.type,stroke:c.stroke,length:c.length};break;case 76:this.$=a[s-1];break;case 78:case 92:case 148:case 146:this.$=a[s-1]+""+a[s];break;case 93:case 94:this.$=a[s-4],r.addClass(a[s-2],a[s]);break;case 95:this.$=a[s-4],r.setClass(a[s-2],a[s]);break;case 96:case 104:this.$=a[s-1],r.setClickEvent(a[s-1],a[s]);break;case 97:case 105:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 98:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 99:this.$=a[s-4],r.setClickEvent(a[s-4],a[s-3],a[s-2]),r.setTooltip(a[s-4],a[s]);break;case 100:case 106:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 101:case 107:this.$=a[s-3],r.setLink(a[s-3],a[s-2]),r.setTooltip(a[s-3],a[s]);break;case 102:case 108:this.$=a[s-3],r.setLink(a[s-3],a[s-2],a[s]);break;case 103:case 109:this.$=a[s-5],r.setLink(a[s-5],a[s-4],a[s]),r.setTooltip(a[s-5],a[s-2]);break;case 110:this.$=a[s-4],r.addVertex(a[s-2],void 0,void 0,a[s]);break;case 111:case 113:this.$=a[s-4],r.updateLink(a[s-2],a[s]);break;case 112:this.$=a[s-4],r.updateLink([a[s-2]],a[s]);break;case 114:this.$=a[s-8],r.updateLinkInterpolate([a[s-6]],a[s-2]),r.updateLink([a[s-6]],a[s]);break;case 115:this.$=a[s-8],r.updateLinkInterpolate(a[s-6],a[s-2]),r.updateLink(a[s-6],a[s]);break;case 116:this.$=a[s-6],r.updateLinkInterpolate([a[s-4]],a[s]);break;case 117:this.$=a[s-6],r.updateLinkInterpolate(a[s-4],a[s]);break;case 119:case 121:a[s-2].push(a[s]),this.$=a[s-2];break;case 123:this.$=a[s-1]+a[s];break;case 151:this.$="v";break;case 152:this.$="-";break;case 153:this.$={stmt:"dir",value:"TB"};break;case 154:this.$={stmt:"dir",value:"BT"};break;case 155:this.$={stmt:"dir",value:"RL"};break;case 156:this.$={stmt:"dir",value:"LR"}}},table:[{3:1,4:2,5:3,6:5,12:e,16:4,21:n,22:r,24:i},{1:[3]},{1:[2,1]},{3:10,4:2,5:3,6:5,12:e,16:4,21:n,22:r,24:i},t(a,o,{17:11}),{7:12,13:[1,13]},{16:14,21:n,22:r,24:i},{16:15,21:n,22:r,24:i},{25:[1,16],26:[1,17]},{13:[2,5]},{1:[2,2]},{1:[2,9],18:18,19:19,20:s,21:c,22:u,23:l,32:24,33:25,34:26,35:27,36:28,37:29,38:f,43:31,45:32,46:42,47:h,49:43,76:d,77:p,78:g,79:y,80:m,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,110:C,111:S,112:M,113:A,114:O,115:N,116:j,117:D,118:B,119:L},{8:60,10:[1,61],15:I},t([10,15],[2,6]),t(a,[2,17]),t(a,[2,18]),t(a,[2,19]),{20:[1,64],21:[1,65],22:R,27:63,30:66},t(P,[2,11]),t(P,[2,12]),t(P,[2,13]),t(P,[2,14]),t(P,[2,15]),t(P,[2,16]),{9:68,20:F,21:z,23:Y,44:69,67:73,70:[1,74],71:[1,75]},{9:76,20:F,21:z,23:Y},{9:77,20:F,21:z,23:Y},{9:78,20:F,21:z,23:Y},{9:79,20:F,21:z,23:Y},{9:80,20:F,21:z,23:Y},{9:82,20:F,21:z,22:[1,81],23:Y},t(P,[2,44]),t(q,[2,51],{30:83,22:R}),{22:[1,84]},{22:[1,85]},{22:[1,86]},{22:[1,87]},{26:U,47:V,74:[1,91],81:W,87:90,88:[1,88],90:[1,89],95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(P,[2,153]),t(P,[2,154]),t(P,[2,155]),t(P,[2,156]),t(at,[2,52],{48:[1,110]}),t(ot,[2,69],{108:121,40:[1,111],47:h,50:[1,112],52:[1,113],54:[1,114],56:[1,115],58:[1,116],60:[1,117],62:[1,118],63:[1,119],65:[1,120],81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,114:O,115:N,116:j,117:D,118:B,119:L}),t(st,[2,145]),t(st,[2,170]),t(st,[2,171]),t(st,[2,172]),t(st,[2,173]),t(st,[2,174]),t(st,[2,175]),t(st,[2,176]),t(st,[2,177]),t(st,[2,178]),t(st,[2,179]),t(st,[2,180]),t(st,[2,181]),t(st,[2,182]),t(st,[2,183]),t(st,[2,184]),{9:122,20:F,21:z,23:Y},{11:123,14:[1,124]},t(ct,[2,8]),t(a,[2,20]),t(a,[2,26]),t(a,[2,27]),{21:[1,125]},t(ut,[2,34],{30:126,22:R}),t(P,[2,35]),{45:127,46:42,47:h,49:43,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,114:O,115:N,116:j,117:D,118:B,119:L},t(lt,[2,45]),t(lt,[2,46]),t(lt,[2,47]),t(ft,[2,73],{68:128,69:[1,129],72:[1,130]}),{22:ht,24:dt,26:pt,38:gt,39:131,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t([47,69,72,81,95,96,99,100,101,103,104,114,115,116,117,118,119],[2,75]),t(P,[2,36]),t(P,[2,37]),t(P,[2,38]),t(P,[2,39]),t(P,[2,40]),{22:ht,24:dt,26:pt,38:gt,39:155,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(Nt,o,{17:156}),t(q,[2,50],{47:jt}),{26:U,47:V,81:W,87:158,92:[1,159],95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},{85:[1,160],93:161,95:[1,162]},{26:U,47:V,81:W,85:[1,163],87:164,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},{26:U,47:V,81:W,87:165,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ct,[2,96],{22:[1,166],89:[1,167]}),t(ct,[2,100],{22:[1,168]}),t(ct,[2,104],{107:94,109:170,22:[1,169],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,114:J,115:tt,116:et,117:nt,118:rt,119:it}),t(ct,[2,106],{22:[1,171]}),t(Dt,[2,147]),t(Dt,[2,149]),t(Dt,[2,150]),t(Dt,[2,151]),t(Dt,[2,152]),t(Bt,[2,157]),t(Bt,[2,158]),t(Bt,[2,159]),t(Bt,[2,160]),t(Bt,[2,161]),t(Bt,[2,162]),t(Bt,[2,163]),t(Bt,[2,164]),t(Bt,[2,165]),t(Bt,[2,166]),t(Bt,[2,167]),t(Bt,[2,168]),t(Bt,[2,169]),{47:h,49:172,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,114:O,115:N,116:j,117:D,118:B,119:L},{22:ht,24:dt,26:pt,38:gt,39:173,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:175,42:yt,47:V,50:[1,174],62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:176,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:177,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:178,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:179,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:180,42:yt,47:V,60:[1,181],62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:182,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:183,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:184,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(st,[2,146]),t(Lt,[2,3]),{8:185,15:I},{15:[2,7]},t(a,[2,28]),t(ut,[2,33]),t(q,[2,48],{30:186,22:R}),t(ft,[2,70],{22:[1,187]}),{22:[1,188]},{22:ht,24:dt,26:pt,38:gt,39:189,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,62:mt,70:vt,71:[1,190],73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(Bt,[2,77]),t(Bt,[2,79]),t(Bt,[2,135]),t(Bt,[2,136]),t(Bt,[2,137]),t(Bt,[2,138]),t(Bt,[2,139]),t(Bt,[2,140]),t(Bt,[2,141]),t(Bt,[2,142]),t(Bt,[2,143]),t(Bt,[2,144]),t(Bt,[2,80]),t(Bt,[2,81]),t(Bt,[2,82]),t(Bt,[2,83]),t(Bt,[2,84]),t(Bt,[2,85]),t(Bt,[2,86]),t(Bt,[2,87]),t(Bt,[2,88]),t(Bt,[2,89]),t(Bt,[2,90]),{9:193,20:F,21:z,22:ht,23:Y,24:dt,26:pt,38:gt,40:[1,192],42:yt,47:V,62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{18:18,19:19,20:s,21:c,22:u,23:l,32:24,33:25,34:26,35:27,36:28,37:29,38:f,42:[1,194],43:31,45:32,46:42,47:h,49:43,76:d,77:p,78:g,79:y,80:m,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,110:C,111:S,112:M,113:A,114:O,115:N,116:j,117:D,118:B,119:L},{22:R,30:195},{22:[1,196],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:170,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:[1,197]},{22:[1,198]},{22:[1,199],96:[1,200]},t(It,[2,118]),{22:[1,201]},{22:[1,202],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:170,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:[1,203],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:170,114:J,115:tt,116:et,117:nt,118:rt,119:it},{74:[1,204]},t(ct,[2,98],{22:[1,205]}),{74:[1,206],91:[1,207]},{74:[1,208]},t(Dt,[2,148]),{74:[1,209],91:[1,210]},t(at,[2,54],{108:121,47:h,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,114:O,115:N,116:j,117:D,118:B,119:L}),{22:ht,24:dt,26:pt,38:gt,41:[1,211],42:yt,47:V,62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:212,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,51:[1,213],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,53:[1,214],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,55:[1,215],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,57:[1,216],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,59:[1,217],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,61:[1,218],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,39:219,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,41:[1,220],42:yt,47:V,62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,62:mt,64:[1,221],66:[1,222],70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,62:mt,64:[1,224],66:[1,223],70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{9:225,20:F,21:z,23:Y},t(q,[2,49],{47:jt}),t(ft,[2,72]),t(ft,[2,71]),{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,62:mt,70:vt,72:[1,226],73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ft,[2,74]),t(Bt,[2,78]),{22:ht,24:dt,26:pt,38:gt,39:227,42:yt,47:V,62:mt,70:vt,73:132,74:bt,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(Nt,o,{17:228}),t(P,[2,43]),{46:229,47:h,49:43,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,114:O,115:N,116:j,117:D,118:B,119:L},{22:Rt,76:Pt,86:230,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{22:Rt,76:Pt,86:244,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{22:Rt,76:Pt,86:245,92:Ft,94:[1,246],95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{22:Rt,76:Pt,86:247,92:Ft,94:[1,248],95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{95:[1,249]},{22:Rt,76:Pt,86:250,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{22:Rt,76:Pt,86:251,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{26:U,47:V,81:W,87:252,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ct,[2,97]),{74:[1,253]},t(ct,[2,101],{22:[1,254]}),t(ct,[2,102]),t(ct,[2,105]),t(ct,[2,107],{22:[1,255]}),t(ct,[2,108]),t(ot,[2,55]),{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,51:[1,256],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ot,[2,61]),t(ot,[2,57]),t(ot,[2,58]),t(ot,[2,59]),t(ot,[2,60]),t(ot,[2,62]),{22:ht,24:dt,26:pt,38:gt,42:yt,47:V,61:[1,257],62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ot,[2,64]),t(ot,[2,65]),t(ot,[2,67]),t(ot,[2,66]),t(ot,[2,68]),t(Lt,[2,4]),t([22,47,81,95,96,99,100,101,103,104,114,115,116,117,118,119],[2,76]),{22:ht,24:dt,26:pt,38:gt,41:[1,258],42:yt,47:V,62:mt,70:vt,73:191,75:143,76:_t,77:xt,78:wt,79:kt,80:Tt,81:Et,82:Ct,84:134,85:St,95:H,96:$,99:G,100:X,101:Mt,103:K,104:Q,105:At,106:Ot,107:140,114:J,115:tt,116:et,117:nt,118:rt,119:it},{18:18,19:19,20:s,21:c,22:u,23:l,32:24,33:25,34:26,35:27,36:28,37:29,38:f,42:[1,259],43:31,45:32,46:42,47:h,49:43,76:d,77:p,78:g,79:y,80:m,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,110:C,111:S,112:M,113:A,114:O,115:N,116:j,117:D,118:B,119:L},t(at,[2,53]),t(ct,[2,110],{96:Gt}),t(Xt,[2,120],{98:261,22:Rt,76:Pt,92:Ft,95:zt,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t}),t(Zt,[2,122]),t(Zt,[2,124]),t(Zt,[2,125]),t(Zt,[2,126]),t(Zt,[2,127]),t(Zt,[2,128]),t(Zt,[2,129]),t(Zt,[2,130]),t(Zt,[2,131]),t(Zt,[2,132]),t(Zt,[2,133]),t(Zt,[2,134]),t(ct,[2,111],{96:Gt}),t(ct,[2,112],{96:Gt}),{22:[1,262]},t(ct,[2,113],{96:Gt}),{22:[1,263]},t(It,[2,119]),t(ct,[2,93],{96:Gt}),t(ct,[2,94],{96:Gt}),t(ct,[2,95],{107:94,109:170,26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,114:J,115:tt,116:et,117:nt,118:rt,119:it}),t(ct,[2,99]),{91:[1,264]},{91:[1,265]},{51:[1,266]},{61:[1,267]},{9:268,20:F,21:z,23:Y},t(P,[2,42]),{22:Rt,76:Pt,92:Ft,95:zt,97:269,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},t(Zt,[2,123]),{26:U,47:V,81:W,87:270,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},{26:U,47:V,81:W,87:271,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,107:94,109:92,114:J,115:tt,116:et,117:nt,118:rt,119:it},t(ct,[2,103]),t(ct,[2,109]),t(ot,[2,56]),t(ot,[2,63]),t(Nt,o,{17:272}),t(Xt,[2,121],{98:261,22:Rt,76:Pt,92:Ft,95:zt,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t}),t(ct,[2,116],{107:94,109:170,22:[1,273],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,114:J,115:tt,116:et,117:nt,118:rt,119:it}),t(ct,[2,117],{107:94,109:170,22:[1,274],26:U,47:V,81:W,95:H,96:$,99:G,100:X,101:Z,103:K,104:Q,114:J,115:tt,116:et,117:nt,118:rt,119:it}),{18:18,19:19,20:s,21:c,22:u,23:l,32:24,33:25,34:26,35:27,36:28,37:29,38:f,42:[1,275],43:31,45:32,46:42,47:h,49:43,76:d,77:p,78:g,79:y,80:m,81:v,95:b,96:_,99:x,100:w,101:k,103:T,104:E,108:44,110:C,111:S,112:M,113:A,114:O,115:N,116:j,117:D,118:B,119:L},{22:Rt,76:Pt,86:276,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},{22:Rt,76:Pt,86:277,92:Ft,95:zt,97:231,98:232,99:Yt,100:qt,101:Ut,102:Vt,103:Wt,104:Ht,105:$t},t(P,[2,41]),t(ct,[2,114],{96:Gt}),t(ct,[2,115],{96:Gt})],defaultActions:{2:[2,1],9:[2,5],10:[2,2],124:[2,7]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},Qt={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),12;case 1:return this.begin("type_directive"),13;case 2:return this.popState(),this.begin("arg_directive"),10;case 3:return this.popState(),this.popState(),15;case 4:return 14;case 5:case 6:break;case 7:this.begin("string");break;case 8:case 17:case 20:case 23:case 26:this.popState();break;case 9:return"STR";case 10:return 76;case 11:return 85;case 12:return 77;case 13:return 94;case 14:return 78;case 15:return 79;case 16:this.begin("href");break;case 18:return 90;case 19:this.begin("callbackname");break;case 21:this.popState(),this.begin("callbackargs");break;case 22:return 88;case 24:return 89;case 25:this.begin("click");break;case 27:return 80;case 28:case 29:return t.lex.firstGraph()&&this.begin("dir"),24;case 30:return 38;case 31:return 42;case 32:case 33:case 34:case 35:return 91;case 36:return this.popState(),25;case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:return this.popState(),26;case 47:return 110;case 48:return 111;case 49:return 112;case 50:return 113;case 51:return 95;case 52:return 103;case 53:return 48;case 54:return 100;case 55:return 47;case 56:return 20;case 57:return 96;case 58:return 118;case 59:case 60:case 61:return 71;case 62:case 63:case 64:return 70;case 65:return 52;case 66:return 53;case 67:return 54;case 68:return 55;case 69:return 56;case 70:return 57;case 71:return 58;case 72:return 59;case 73:return 101;case 74:return 104;case 75:return 119;case 76:return 116;case 77:return 105;case 78:case 79:return 117;case 80:return 106;case 81:return 62;case 82:return 82;case 83:return"SEP";case 84:return 81;case 85:return 99;case 86:return 64;case 87:return 63;case 88:return 66;case 89:return 65;case 90:return 114;case 91:return 115;case 92:return 72;case 93:return 50;case 94:return 51;case 95:return 40;case 96:return 41;case 97:return 60;case 98:return 61;case 99:return 125;case 100:return 21;case 101:return 22;case 102:return 23}},rules:[/^(?:%%\{)/,/^(?:((?:(?!\}%%)[^:.])*))/,/^(?::)/,/^(?:\}%%)/,/^(?:((?:(?!\}%%).|\n)*))/,/^(?:%%(?!\{)[^\n]*)/,/^(?:[^\}]%%[^\n]*)/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s]+["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\[)/,/^(?:\]\))/,/^(?:\[\[)/,/^(?:\]\])/,/^(?:\[\()/,/^(?:\)\])/,/^(?:-)/,/^(?:\.)/,/^(?:[\_])/,/^(?:\+)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:[A-Za-z]+)/,/^(?:\\\])/,/^(?:\[\/)/,/^(?:\/\])/,/^(?:\[\\)/,/^(?:[!"#$%&'*+,-.`?\\_/])/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\()/,/^(?:\))/,/^(?:\[)/,/^(?:\])/,/^(?:\{)/,/^(?:\})/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{close_directive:{rules:[],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},open_directive:{rules:[1],inclusive:!1},callbackargs:{rules:[23,24],inclusive:!1},callbackname:{rules:[20,21,22],inclusive:!1},href:{rules:[17,18],inclusive:!1},click:{rules:[26,27],inclusive:!1},vertex:{rules:[],inclusive:!1},dir:{rules:[36,37,38,39,40,41,42,43,44,45,46],inclusive:!1},string:{rules:[8,9],inclusive:!1},INITIAL:{rules:[0,5,6,7,10,11,12,13,14,15,16,19,25,28,29,30,31,32,33,34,35,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98,99,100,101,102],inclusive:!0}}};function Jt(){this.yy={}}return Kt.lexer=Qt,Jt.prototype=Kt,Kt.Parser=Jt,new Jt}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/flowchart/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return".label {\n font-family: ".concat(t.fontFamily,";\n color: ").concat(t.nodeTextColor||t.textColor,";\n }\n .cluster-label text {\n fill: ").concat(t.titleColor,";\n }\n .cluster-label span {\n color: ").concat(t.titleColor,";\n }\n\n .label text,span {\n fill: ").concat(t.nodeTextColor||t.textColor,";\n color: ").concat(t.nodeTextColor||t.textColor,";\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1px;\n }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ").concat(t.arrowheadColor,";\n }\n\n .edgePath .path {\n stroke: ").concat(t.lineColor,";\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ").concat(t.lineColor,";\n fill: none;\n }\n\n .edgeLabel {\n background-color: ").concat(t.edgeLabelBackground,";\n rect {\n opacity: 0.5;\n background-color: ").concat(t.edgeLabelBackground,";\n fill: ").concat(t.edgeLabelBackground,";\n }\n text-align: center;\n }\n\n .cluster rect {\n fill: ").concat(t.clusterBkg,";\n stroke: ").concat(t.clusterBorder,";\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ").concat(t.titleColor,";\n }\n\n .cluster span {\n color: ").concat(t.titleColor,";\n }\n // .cluster div {\n // color: ").concat(t.titleColor,";\n // }\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ").concat(t.fontFamily,";\n font-size: 12px;\n background: ").concat(t.tertiaryColor,";\n border: 1px solid ").concat(t.border2,";\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n")}},"./src/diagrams/gantt/ganttDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return C})),n.d(e,"clear",(function(){return S})),n.d(e,"setAxisFormat",(function(){return M})),n.d(e,"getAxisFormat",(function(){return A})),n.d(e,"setTodayMarker",(function(){return O})),n.d(e,"getTodayMarker",(function(){return N})),n.d(e,"setDateFormat",(function(){return j})),n.d(e,"enableInclusiveEndDates",(function(){return D})),n.d(e,"endDatesAreInclusive",(function(){return B})),n.d(e,"enableTopAxis",(function(){return L})),n.d(e,"topAxisEnabled",(function(){return I})),n.d(e,"getDateFormat",(function(){return R})),n.d(e,"setExcludes",(function(){return P})),n.d(e,"getExcludes",(function(){return F})),n.d(e,"setTitle",(function(){return z})),n.d(e,"getTitle",(function(){return Y})),n.d(e,"addSection",(function(){return q})),n.d(e,"getSections",(function(){return U})),n.d(e,"getTasks",(function(){return V})),n.d(e,"addTask",(function(){return et})),n.d(e,"findTaskById",(function(){return nt})),n.d(e,"addTaskOrg",(function(){return rt})),n.d(e,"setLink",(function(){return at})),n.d(e,"setClass",(function(){return ot})),n.d(e,"setClickEvent",(function(){return ct})),n.d(e,"bindFunctions",(function(){return ut}));var r=n("moment-mini"),i=n.n(r),a=n("@braintree/sanitize-url"),o=n("./src/logger.js"),s=n("./src/config.js"),c=n("./src/utils.js"),u=n("./src/mermaidAPI.js");function l(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var f,h,d="",p="",g="",y=[],m="",v=[],b=[],_="",x=["active","done","crit","milestone"],w=[],k=!1,T=!1,E=0,C=function(t,e,n){u.default.parseDirective(this,t,e,n)},S=function(){v=[],b=[],_="",w=[],m="",K=0,f=void 0,h=void 0,J=[],d="",p="",g="",y=[],k=!1,T=!1,E=0},M=function(t){p=t},A=function(){return p},O=function(t){g=t},N=function(){return g},j=function(t){d=t},D=function(){k=!0},B=function(){return k},L=function(){T=!0},I=function(){return T},R=function(){return d},P=function(t){y=t.toLowerCase().split(/[\s,]+/)},F=function(){return y},z=function(t){m=t},Y=function(){return m},q=function(t){_=t,v.push(t)},U=function(){return v},V=function(){for(var t=it(),e=0;!t&&e<10;)t=it(),e++;return b=J},W=function(t,e,n){return t.isoWeekday()>=6&&n.indexOf("weekends")>=0||n.indexOf(t.format("dddd").toLowerCase())>=0||n.indexOf(t.format(e.trim()))>=0},H=function(t,e,n){if(n.length&&!t.manualEndTime){var r=i()(t.startTime,e,!0);r.add(1,"d");var a=i()(t.endTime,e,!0),o=$(r,a,e,n);t.endTime=a.toDate(),t.renderEndTime=o}},$=function(t,e,n,r){for(var i=!1,a=null;t<=e;)i||(a=e.toDate()),(i=W(t,n,r))&&e.add(1,"d"),t.add(1,"d");return a},G=function(t,e,n){n=n.trim();var r=/^after\s+([\d\w- ]+)/.exec(n.trim());if(null!==r){var a=null;if(r[1].split(" ").forEach((function(t){var e=nt(t);void 0!==e&&(a?e.endTime>a.endTime&&(a=e):a=e)})),a)return a.endTime;var s=new Date;return s.setHours(0,0,0,0),s}var c=i()(n,e.trim(),!0);return c.isValid()?c.toDate():(o.log.debug("Invalid date:"+n),o.log.debug("With date format:"+e.trim()),new Date)},X=function(t,e){if(null!==t)switch(t[2]){case"s":e.add(t[1],"seconds");break;case"m":e.add(t[1],"minutes");break;case"h":e.add(t[1],"hours");break;case"d":e.add(t[1],"days");break;case"w":e.add(t[1],"weeks")}return e.toDate()},Z=function(t,e,n,r){r=r||!1,n=n.trim();var a=i()(n,e.trim(),!0);return a.isValid()?(r&&a.add(1,"d"),a.toDate()):X(/^([\d]+)([wdhms])/.exec(n.trim()),i()(t))},K=0,Q=function(t){return void 0===t?"task"+(K+=1):t},J=[],tt={},et=function(t,e){var n={section:_,type:_,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:e},task:t,classes:[]},r=function(t,e){var n=(":"===e.substr(0,1)?e.substr(1,e.length):e).split(","),r={};lt(n,r,x);for(var i=0;i<n.length;i++)n[i]=n[i].trim();switch(n.length){case 1:r.id=Q(),r.startTime={type:"prevTaskEnd",id:t},r.endTime={data:n[0]};break;case 2:r.id=Q(),r.startTime={type:"getStartDate",startData:n[0]},r.endTime={data:n[1]};break;case 3:r.id=Q(n[0]),r.startTime={type:"getStartDate",startData:n[1]},r.endTime={data:n[2]}}return r}(h,e);n.raw.startTime=r.startTime,n.raw.endTime=r.endTime,n.id=r.id,n.prevTaskId=h,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,n.order=E,E++;var i=J.push(n);h=n.id,tt[n.id]=i-1},nt=function(t){var e=tt[t];return J[e]},rt=function(t,e){var n={section:_,type:_,description:t,task:t,classes:[]},r=function(t,e){var n=(":"===e.substr(0,1)?e.substr(1,e.length):e).split(","),r={};lt(n,r,x);for(var a=0;a<n.length;a++)n[a]=n[a].trim();var o="";switch(n.length){case 1:r.id=Q(),r.startTime=t.endTime,o=n[0];break;case 2:r.id=Q(),r.startTime=G(0,d,n[0]),o=n[1];break;case 3:r.id=Q(n[0]),r.startTime=G(0,d,n[1]),o=n[2]}return o&&(r.endTime=Z(r.startTime,d,o,k),r.manualEndTime=i()(o,"YYYY-MM-DD",!0).isValid(),H(r,d,y)),r}(f,e);n.startTime=r.startTime,n.endTime=r.endTime,n.id=r.id,n.active=r.active,n.done=r.done,n.crit=r.crit,n.milestone=r.milestone,f=n,b.push(n)},it=function(){for(var t=function(t){var e=J[t],n="";switch(J[t].raw.startTime.type){case"prevTaskEnd":var r=nt(e.prevTaskId);e.startTime=r.endTime;break;case"getStartDate":(n=G(0,d,J[t].raw.startTime.startData))&&(J[t].startTime=n)}return J[t].startTime&&(J[t].endTime=Z(J[t].startTime,d,J[t].raw.endTime.data,k),J[t].endTime&&(J[t].processed=!0,J[t].manualEndTime=i()(J[t].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),H(J[t],d,y))),J[t].processed},e=!0,n=0;n<J.length;n++)t(n),e=e&&J[n].processed;return e},at=function(t,e){var n=e;"loose"!==s.getConfig().securityLevel&&(n=Object(a.sanitizeUrl)(e)),t.split(",").forEach((function(t){void 0!==nt(t)&&st(t,(function(){window.open(n,"_self")}))})),ot(t,"clickable")},ot=function(t,e){t.split(",").forEach((function(t){var n=nt(t);void 0!==n&&n.classes.push(e)}))},st=function(t,e){w.push((function(){var n=document.querySelector('[id="'.concat(t,'"]'));null!==n&&n.addEventListener("click",(function(){e()}))})),w.push((function(){var n=document.querySelector('[id="'.concat(t,'-text"]'));null!==n&&n.addEventListener("click",(function(){e()}))}))},ct=function(t,e,n){t.split(",").forEach((function(t){!function(t,e,n){if("loose"===s.getConfig().securityLevel&&void 0!==e){var r=[];if("string"==typeof n){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(var i=0;i<r.length;i++){var a=r[i].trim();'"'===a.charAt(0)&&'"'===a.charAt(a.length-1)&&(a=a.substr(1,a.length-2)),r[i]=a}}0===r.length&&r.push(t),void 0!==nt(t)&&st(t,(function(){var t;c.default.runFunc.apply(c.default,[e].concat(function(t){if(Array.isArray(t))return l(t)}(t=r)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return l(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()))}))}}(t,e,n)})),ot(t,"clickable")},ut=function(t){w.forEach((function(e){e(t)}))};function lt(t,e,n){for(var r=!0;r;)r=!1,n.forEach((function(n){var i=new RegExp("^\\s*"+n+"\\s*$");t[0].match(i)&&(e[n]=!0,t.shift(1),r=!0)}))}e.default={parseDirective:C,getConfig:function(){return s.getConfig().gantt},clear:S,setDateFormat:j,getDateFormat:R,enableInclusiveEndDates:D,endDatesAreInclusive:B,enableTopAxis:L,topAxisEnabled:I,setAxisFormat:M,getAxisFormat:A,setTodayMarker:O,getTodayMarker:N,setTitle:z,getTitle:Y,addSection:q,getSections:U,getTasks:V,addTask:et,findTaskById:nt,addTaskOrg:rt,setExcludes:P,getExcludes:F,setClickEvent:ct,setLink:at,bindFunctions:ut,durationToDate:X}},"./src/diagrams/gantt/ganttRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return l})),n.d(e,"draw",(function(){return f}));var r=n("d3"),i=n("./src/diagrams/gantt/parser/gantt.jison"),a=n("./src/diagrams/common/common.js"),o=n("./src/diagrams/gantt/ganttDb.js"),s=n("./src/config.js"),c=n("./src/utils.js");i.parser.yy=o.default;var u,l=function(){},f=function(t,e){var n=Object(s.getConfig)().gantt;i.parser.yy.clear(),i.parser.parse(t);var l=document.getElementById(e);void 0===(u=l.parentElement.offsetWidth)&&(u=1200),void 0!==n.useWidth&&(u=n.useWidth);var f=i.parser.yy.getTasks(),h=f.length*(n.barHeight+n.barGap)+2*n.topPadding;l.setAttribute("viewBox","0 0 "+u+" "+h);for(var d=Object(r.select)('[id="'.concat(e,'"]')),p=Object(r.scaleTime)().domain([Object(r.min)(f,(function(t){return t.startTime})),Object(r.max)(f,(function(t){return t.endTime}))]).rangeRound([0,u-n.leftPadding-n.rightPadding]),g=[],y=0;y<f.length;y++)g.push(f[y].type);var m,v,b,_,x,w,k,T=g;g=function(t){for(var e={},n=[],r=0,i=t.length;r<i;++r)e.hasOwnProperty(t[r])||(e[t[r]]=!0,n.push(t[r]));return n}(g),f.sort((function(t,e){var n=t.startTime,r=e.startTime,i=0;return n>r?i=1:n<r&&(i=-1),i})),m=f,v=u,b=h,x=(_=n.barHeight)+n.barGap,w=n.topPadding,k=n.leftPadding,Object(r.scaleLinear)().domain([0,g.length]).range(["#00B9FA","#F95002"]).interpolate(r.interpolateHcl),function(t,e,a,s){var c=Object(r.axisBottom)(p).tickSize(-s+e+n.gridLineStartPadding).tickFormat(Object(r.timeFormat)(i.parser.yy.getAxisFormat()||n.axisFormat||"%Y-%m-%d"));if(d.append("g").attr("class","grid").attr("transform","translate("+t+", "+(s-50)+")").call(c).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),o.default.topAxisEnabled()||n.topAxis){var u=Object(r.axisTop)(p).tickSize(-s+e+n.gridLineStartPadding).tickFormat(Object(r.timeFormat)(i.parser.yy.getAxisFormat()||n.axisFormat||"%Y-%m-%d"));d.append("g").attr("class","grid").attr("transform","translate("+t+", "+e+")").call(u).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}(k,w,0,b),function(t,e,r,i,a,o,s){d.append("g").selectAll("rect").data(t).enter().append("rect").attr("x",0).attr("y",(function(t,n){return t.order*e+r-2})).attr("width",(function(){return s-n.rightPadding/2})).attr("height",e).attr("class",(function(t){for(var e=0;e<g.length;e++)if(t.type===g[e])return"section section"+e%n.numberSectionStyles;return"section section0"}));var c=d.append("g").selectAll("rect").data(t).enter();c.append("rect").attr("id",(function(t){return t.id})).attr("rx",3).attr("ry",3).attr("x",(function(t){return t.milestone?p(t.startTime)+i+.5*(p(t.endTime)-p(t.startTime))-.5*a:p(t.startTime)+i})).attr("y",(function(t,n){return t.order*e+r})).attr("width",(function(t){return t.milestone?a:p(t.renderEndTime||t.endTime)-p(t.startTime)})).attr("height",a).attr("transform-origin",(function(t,n){return n=t.order,(p(t.startTime)+i+.5*(p(t.endTime)-p(t.startTime))).toString()+"px "+(n*e+r+.5*a).toString()+"px"})).attr("class",(function(t){var e="";t.classes.length>0&&(e=t.classes.join(" "));for(var r=0,i=0;i<g.length;i++)t.type===g[i]&&(r=i%n.numberSectionStyles);var a="";return t.active?t.crit?a+=" activeCrit":a=" active":t.done?a=t.crit?" doneCrit":" done":t.crit&&(a+=" crit"),0===a.length&&(a=" task"),t.milestone&&(a=" milestone "+a),"task"+(a+=r)+" "+e})),c.append("text").attr("id",(function(t){return t.id+"-text"})).text((function(t){return t.task})).attr("font-size",n.fontSize).attr("x",(function(t){var e=p(t.startTime),r=p(t.renderEndTime||t.endTime);t.milestone&&(e+=.5*(p(t.endTime)-p(t.startTime))-.5*a),t.milestone&&(r=e+a);var o=this.getBBox().width;return o>r-e?r+o+1.5*n.leftPadding>s?e+i-5:r+i+5:(r-e)/2+e+i})).attr("y",(function(t,i){return t.order*e+n.barHeight/2+(n.fontSize/2-2)+r})).attr("text-height",a).attr("class",(function(t){var e=p(t.startTime),r=p(t.endTime);t.milestone&&(r=e+a);var i=this.getBBox().width,o="";t.classes.length>0&&(o=t.classes.join(" "));for(var c=0,u=0;u<g.length;u++)t.type===g[u]&&(c=u%n.numberSectionStyles);var l="";return t.active&&(l=t.crit?"activeCritText"+c:"activeText"+c),t.done?l=t.crit?l+" doneCritText"+c:l+" doneText"+c:t.crit&&(l=l+" critText"+c),t.milestone&&(l+=" milestoneText"),i>r-e?r+i+1.5*n.leftPadding>s?o+" taskTextOutsideLeft taskTextOutside"+c+" "+l:o+" taskTextOutsideRight taskTextOutside"+c+" "+l+" width-"+i:o+" taskText taskText"+c+" "+l+" width-"+i}))}(m,x,w,k,_,0,v),function(t,e){for(var r=[],i=0,o=0;o<g.length;o++)r[o]=[g[o],(s=g[o],c=T,function(t){for(var e=t.length,n={};e;)n[t[--e]]=(n[t[e]]||0)+1;return n}(c)[s]||0)];var s,c;d.append("g").selectAll("text").data(r).enter().append((function(t){var e=t[0].split(a.default.lineBreakRegex),n=-(e.length-1)/2,r=document.createElementNS("http://www.w3.org/2000/svg","text");r.setAttribute("dy",n+"em");for(var i=0;i<e.length;i++){var o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttribute("alignment-baseline","central"),o.setAttribute("x","10"),i>0&&o.setAttribute("dy","1em"),o.textContent=e[i],r.appendChild(o)}return r})).attr("x",10).attr("y",(function(n,a){if(!(a>0))return n[1]*t/2+e;for(var o=0;o<a;o++)return i+=r[a-1][1],n[1]*t/2+i*t+e})).attr("font-size",n.sectionFontSize).attr("font-size",n.sectionFontSize).attr("class",(function(t){for(var e=0;e<g.length;e++)if(t[0]===g[e])return"sectionTitle sectionTitle"+e%n.numberSectionStyles;return"sectionTitle"}))}(x,w),function(t,e,r,i){var a=o.default.getTodayMarker();if("off"!==a){var s=d.append("g").attr("class","today"),c=new Date,u=s.append("line");u.attr("x1",p(c)+t).attr("x2",p(c)+t).attr("y1",n.titleTopMargin).attr("y2",i-n.titleTopMargin).attr("class","today"),""!==a&&u.attr("style",a.replace(/,/g,";"))}}(k,0,0,b),Object(c.configureSvgSize)(d,h,u,n.useMaxWidth),d.append("text").text(i.parser.yy.getTitle()).attr("x",u/2).attr("y",n.titleTopMargin).attr("class","titleText")};e.default={setConf:l,draw:f}},"./src/diagrams/gantt/parser/gantt.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,3],n=[1,5],r=[7,9,11,12,13,14,15,16,17,18,19,21,28,33],i=[1,15],a=[1,16],o=[1,17],s=[1,18],c=[1,19],u=[1,20],l=[1,21],f=[1,22],h=[1,24],d=[1,26],p=[1,29],g=[5,7,9,11,12,13,14,15,16,17,18,19,21,28,33],y={trace:function(){},yy:{},symbols_:{error:2,start:3,directive:4,gantt:5,document:6,EOF:7,line:8,SPACE:9,statement:10,NL:11,dateFormat:12,inclusiveEndDates:13,topAxis:14,axisFormat:15,excludes:16,todayMarker:17,title:18,section:19,clickStatement:20,taskTxt:21,taskData:22,openDirective:23,typeDirective:24,closeDirective:25,":":26,argDirective:27,click:28,callbackname:29,callbackargs:30,href:31,clickStatementDebug:32,open_directive:33,type_directive:34,arg_directive:35,close_directive:36,$accept:0,$end:1},terminals_:{2:"error",5:"gantt",7:"EOF",9:"SPACE",11:"NL",12:"dateFormat",13:"inclusiveEndDates",14:"topAxis",15:"axisFormat",16:"excludes",17:"todayMarker",18:"title",19:"section",21:"taskTxt",22:"taskData",26:":",28:"click",29:"callbackname",30:"callbackargs",31:"href",33:"open_directive",34:"type_directive",35:"arg_directive",36:"close_directive"},productions_:[0,[3,2],[3,3],[6,0],[6,2],[8,2],[8,1],[8,1],[8,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,1],[4,4],[4,6],[20,2],[20,3],[20,3],[20,4],[20,3],[20,4],[20,2],[32,2],[32,3],[32,3],[32,4],[32,3],[32,4],[32,2],[23,1],[24,1],[27,1],[25,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 2:return a[s-1];case 3:case 7:case 8:this.$=[];break;case 4:a[s-1].push(a[s]),this.$=a[s-1];break;case 5:case 6:this.$=a[s];break;case 9:r.setDateFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 10:r.enableInclusiveEndDates(),this.$=a[s].substr(18);break;case 11:r.TopAxis(),this.$=a[s].substr(8);break;case 12:r.setAxisFormat(a[s].substr(11)),this.$=a[s].substr(11);break;case 13:r.setExcludes(a[s].substr(9)),this.$=a[s].substr(9);break;case 14:r.setTodayMarker(a[s].substr(12)),this.$=a[s].substr(12);break;case 15:r.setTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 16:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 18:r.addTask(a[s-1],a[s]),this.$="task";break;case 22:this.$=a[s-1],r.setClickEvent(a[s-1],a[s],null);break;case 23:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],a[s]);break;case 24:this.$=a[s-2],r.setClickEvent(a[s-2],a[s-1],null),r.setLink(a[s-2],a[s]);break;case 25:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-2],a[s-1]),r.setLink(a[s-3],a[s]);break;case 26:this.$=a[s-2],r.setClickEvent(a[s-2],a[s],null),r.setLink(a[s-2],a[s-1]);break;case 27:this.$=a[s-3],r.setClickEvent(a[s-3],a[s-1],a[s]),r.setLink(a[s-3],a[s-2]);break;case 28:this.$=a[s-1],r.setLink(a[s-1],a[s]);break;case 29:case 35:this.$=a[s-1]+" "+a[s];break;case 30:case 31:case 33:this.$=a[s-2]+" "+a[s-1]+" "+a[s];break;case 32:case 34:this.$=a[s-3]+" "+a[s-2]+" "+a[s-1]+" "+a[s];break;case 36:r.parseDirective("%%{","open_directive");break;case 37:r.parseDirective(a[s],"type_directive");break;case 38:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 39:r.parseDirective("}%%","close_directive","gantt")}},table:[{3:1,4:2,5:e,23:4,33:n},{1:[3]},{3:6,4:2,5:e,23:4,33:n},t(r,[2,3],{6:7}),{24:8,34:[1,9]},{34:[2,36]},{1:[2,1]},{4:25,7:[1,10],8:11,9:[1,12],10:13,11:[1,14],12:i,13:a,14:o,15:s,16:c,17:u,18:l,19:f,20:23,21:h,23:4,28:d,33:n},{25:27,26:[1,28],36:p},t([26,36],[2,37]),t(r,[2,8],{1:[2,2]}),t(r,[2,4]),{4:25,10:30,12:i,13:a,14:o,15:s,16:c,17:u,18:l,19:f,20:23,21:h,23:4,28:d,33:n},t(r,[2,6]),t(r,[2,7]),t(r,[2,9]),t(r,[2,10]),t(r,[2,11]),t(r,[2,12]),t(r,[2,13]),t(r,[2,14]),t(r,[2,15]),t(r,[2,16]),t(r,[2,17]),{22:[1,31]},t(r,[2,19]),{29:[1,32],31:[1,33]},{11:[1,34]},{27:35,35:[1,36]},{11:[2,39]},t(r,[2,5]),t(r,[2,18]),t(r,[2,22],{30:[1,37],31:[1,38]}),t(r,[2,28],{29:[1,39]}),t(g,[2,20]),{25:40,36:p},{36:[2,38]},t(r,[2,23],{31:[1,41]}),t(r,[2,24]),t(r,[2,26],{30:[1,42]}),{11:[1,43]},t(r,[2,25]),t(r,[2,27]),t(g,[2,21])],defaultActions:{5:[2,36],6:[2,1],29:[2,39],36:[2,38]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},m={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),33;case 1:return this.begin("type_directive"),34;case 2:return this.popState(),this.begin("arg_directive"),26;case 3:return this.popState(),this.popState(),36;case 4:return 35;case 5:case 6:case 7:case 9:case 10:case 11:break;case 8:return 11;case 12:this.begin("href");break;case 13:case 16:case 19:case 22:this.popState();break;case 14:return 31;case 15:this.begin("callbackname");break;case 17:this.popState(),this.begin("callbackargs");break;case 18:return 29;case 20:return 30;case 21:this.begin("click");break;case 23:return 28;case 24:return 5;case 25:return 12;case 26:return 13;case 27:return 14;case 28:return 15;case 29:return 16;case 30:return 17;case 31:return"date";case 32:return 18;case 33:return 19;case 34:return 21;case 35:return 22;case 36:return 26;case 37:return 7;case 38:return"INVALID"}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/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,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{close_directive:{rules:[],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},open_directive:{rules:[1],inclusive:!1},callbackargs:{rules:[19,20],inclusive:!1},callbackname:{rules:[16,17,18],inclusive:!1},href:{rules:[13,14],inclusive:!1},click:{rules:[22,23],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,11,12,15,21,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],inclusive:!0}}};function v(){this.yy={}}return y.lexer=m,v.prototype=y,y.Parser=v,new v}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/gantt/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return'\n .mermaid-main-font {\n font-family: "trebuchet ms", verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n }\n\n .section {\n stroke: none;\n opacity: 0.2;\n }\n\n .section0 {\n fill: '.concat(t.sectionBkgColor,";\n }\n\n .section2 {\n fill: ").concat(t.sectionBkgColor2,";\n }\n\n .section1,\n .section3 {\n fill: ").concat(t.altSectionBkgColor,";\n opacity: 0.2;\n }\n\n .sectionTitle0 {\n fill: ").concat(t.titleColor,";\n }\n\n .sectionTitle1 {\n fill: ").concat(t.titleColor,";\n }\n\n .sectionTitle2 {\n fill: ").concat(t.titleColor,";\n }\n\n .sectionTitle3 {\n fill: ").concat(t.titleColor,";\n }\n\n .sectionTitle {\n text-anchor: start;\n // font-size: ").concat(t.ganttFontSize,";\n // text-height: 14px;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n\n }\n\n\n /* Grid and axis */\n\n .grid .tick {\n stroke: ").concat(t.gridColor,";\n opacity: 0.8;\n shape-rendering: crispEdges;\n text {\n font-family: ").concat(t.fontFamily,";\n fill: ").concat(t.textColor,";\n }\n }\n\n .grid path {\n stroke-width: 0;\n }\n\n\n /* Today line */\n\n .today {\n fill: none;\n stroke: ").concat(t.todayLineColor,";\n stroke-width: 2px;\n }\n\n\n /* Task styling */\n\n /* Default task */\n\n .task {\n stroke-width: 2;\n }\n\n .taskText {\n text-anchor: middle;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n }\n\n // .taskText:not([font-size]) {\n // font-size: ").concat(t.ganttFontSize,";\n // }\n\n .taskTextOutsideRight {\n fill: ").concat(t.taskTextDarkColor,";\n text-anchor: start;\n // font-size: ").concat(t.ganttFontSize,";\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n\n }\n\n .taskTextOutsideLeft {\n fill: ").concat(t.taskTextDarkColor,";\n text-anchor: end;\n // font-size: ").concat(t.ganttFontSize,";\n }\n\n /* Special case clickable */\n .task.clickable {\n cursor: pointer;\n }\n .taskText.clickable {\n cursor: pointer;\n fill: ").concat(t.taskTextClickableColor," !important;\n font-weight: bold;\n }\n\n .taskTextOutsideLeft.clickable {\n cursor: pointer;\n fill: ").concat(t.taskTextClickableColor," !important;\n font-weight: bold;\n }\n\n .taskTextOutsideRight.clickable {\n cursor: pointer;\n fill: ").concat(t.taskTextClickableColor," !important;\n font-weight: bold;\n }\n\n /* Specific task settings for the sections*/\n\n .taskText0,\n .taskText1,\n .taskText2,\n .taskText3 {\n fill: ").concat(t.taskTextColor,";\n }\n\n .task0,\n .task1,\n .task2,\n .task3 {\n fill: ").concat(t.taskBkgColor,";\n stroke: ").concat(t.taskBorderColor,";\n }\n\n .taskTextOutside0,\n .taskTextOutside2\n {\n fill: ").concat(t.taskTextOutsideColor,";\n }\n\n .taskTextOutside1,\n .taskTextOutside3 {\n fill: ").concat(t.taskTextOutsideColor,";\n }\n\n\n /* Active task */\n\n .active0,\n .active1,\n .active2,\n .active3 {\n fill: ").concat(t.activeTaskBkgColor,";\n stroke: ").concat(t.activeTaskBorderColor,";\n }\n\n .activeText0,\n .activeText1,\n .activeText2,\n .activeText3 {\n fill: ").concat(t.taskTextDarkColor," !important;\n }\n\n\n /* Completed task */\n\n .done0,\n .done1,\n .done2,\n .done3 {\n stroke: ").concat(t.doneTaskBorderColor,";\n fill: ").concat(t.doneTaskBkgColor,";\n stroke-width: 2;\n }\n\n .doneText0,\n .doneText1,\n .doneText2,\n .doneText3 {\n fill: ").concat(t.taskTextDarkColor," !important;\n }\n\n\n /* Tasks on the critical line */\n\n .crit0,\n .crit1,\n .crit2,\n .crit3 {\n stroke: ").concat(t.critBorderColor,";\n fill: ").concat(t.critBkgColor,";\n stroke-width: 2;\n }\n\n .activeCrit0,\n .activeCrit1,\n .activeCrit2,\n .activeCrit3 {\n stroke: ").concat(t.critBorderColor,";\n fill: ").concat(t.activeTaskBkgColor,";\n stroke-width: 2;\n }\n\n .doneCrit0,\n .doneCrit1,\n .doneCrit2,\n .doneCrit3 {\n stroke: ").concat(t.critBorderColor,";\n fill: ").concat(t.doneTaskBkgColor,";\n stroke-width: 2;\n cursor: pointer;\n shape-rendering: crispEdges;\n }\n\n .milestone {\n transform: rotate(45deg) scale(0.8,0.8);\n }\n\n .milestoneText {\n font-style: italic;\n }\n .doneCritText0,\n .doneCritText1,\n .doneCritText2,\n .doneCritText3 {\n fill: ").concat(t.taskTextDarkColor," !important;\n }\n\n .activeCritText0,\n .activeCritText1,\n .activeCritText2,\n .activeCritText3 {\n fill: ").concat(t.taskTextDarkColor," !important;\n }\n\n .titleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ").concat(t.textColor," ;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n }\n")}},"./src/diagrams/git/gitGraphAst.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setDirection",(function(){return d})),n.d(e,"setOptions",(function(){return g})),n.d(e,"getOptions",(function(){return y})),n.d(e,"commit",(function(){return m})),n.d(e,"branch",(function(){return v})),n.d(e,"merge",(function(){return b})),n.d(e,"checkout",(function(){return _})),n.d(e,"reset",(function(){return x})),n.d(e,"prettyPrint",(function(){return T})),n.d(e,"clear",(function(){return E})),n.d(e,"getBranchesAsObjArray",(function(){return C})),n.d(e,"getBranches",(function(){return S})),n.d(e,"getCommits",(function(){return M})),n.d(e,"getCommitsArray",(function(){return A})),n.d(e,"getCurrentBranch",(function(){return O})),n.d(e,"getDirection",(function(){return N})),n.d(e,"getHead",(function(){return j}));var r=n("./src/logger.js"),i=n("./src/utils.js"),a={},o=null,s={master:o},c="master",u="LR",l=0;function f(){return Object(i.random)({length:7})}function h(t,e){for(r.log.debug("Entering isfastforwardable:",t.id,e.id);t.seq<=e.seq&&t!==e&&null!=e.parent;){if(Array.isArray(e.parent))return r.log.debug("In merge commit:",e.parent),h(t,a[e.parent[0]])||h(t,a[e.parent[1]]);e=a[e.parent]}return r.log.debug(t.id,e.id),t.id===e.id}var d=function(t){u=t},p={},g=function(t){r.log.debug("options str",t),t=(t=t&&t.trim())||"{}";try{p=JSON.parse(t)}catch(t){r.log.error("error while parsing gitGraph options",t.message)}},y=function(){return p},m=function(t){var e={id:f(),message:t,seq:l++,parent:null==o?null:o.id};o=e,a[e.id]=e,s[c]=e.id,r.log.debug("in pushCommit "+e.id)},v=function(t){s[t]=null!=o?o.id:null,r.log.debug("in createBranch")},b=function(t){var e=a[s[c]],n=a[s[t]];if(function(t,e){return t.seq>e.seq&&h(e,t)}(e,n))r.log.debug("Already merged");else{if(h(e,n))s[c]=s[t],o=a[s[c]];else{var i={id:f(),message:"merged branch "+t+" into "+c,seq:l++,parent:[null==o?null:o.id,s[t]]};o=i,a[i.id]=i,s[c]=i.id}r.log.debug(s),r.log.debug("in mergeBranch")}},_=function(t){r.log.debug("in checkout");var e=s[c=t];o=a[e]},x=function(t){r.log.debug("in reset",t);var e=t.split(":")[0],n=parseInt(t.split(":")[1]),i="HEAD"===e?o:a[s[e]];for(r.log.debug(i,n);n>0;)if(n--,!(i=a[i.parent])){var u="Critical error - unique parent commit not found during reset";throw r.log.error(u),u}o=i,s[c]=i.id};function w(t,e,n){var r=t.indexOf(e);-1===r?t.push(n):t.splice(r,1,n)}function k(t){var e=t.reduce((function(t,e){return t.seq>e.seq?t:e}),t[0]),n="";t.forEach((function(t){n+=t===e?"\t*":"\t|"}));var i,o,c,u=[n,e.id,e.seq];for(var l in s)s[l]===e.id&&u.push(l);if(r.log.debug(u.join(" ")),Array.isArray(e.parent)){var f=a[e.parent[0]];w(t,e,f),t.push(a[e.parent[1]])}else{if(null==e.parent)return;var h=a[e.parent];w(t,e,h)}i=t,o=function(t){return t.id},c=Object.create(null),k(t=i.reduce((function(t,e){var n=o(e);return c[n]||(c[n]=!0,t.push(e)),t}),[]))}var T=function(){r.log.debug(a),k([A()[0]])},E=function(){a={},s={master:o=null},c="master",l=0},C=function(){var t=[];for(var e in s)t.push({name:e,commit:a[s[e]]});return t},S=function(){return s},M=function(){return a},A=function(){var t=Object.keys(a).map((function(t){return a[t]}));return t.forEach((function(t){r.log.debug(t.id)})),t.sort((function(t,e){return e.seq-t.seq})),t},O=function(){return c},N=function(){return u},j=function(){return o};e.default={setDirection:d,setOptions:g,getOptions:y,commit:m,branch:v,merge:b,checkout:_,reset:x,prettyPrint:T,clear:E,getBranchesAsObjArray:C,getBranches:S,getCommits:M,getCommitsArray:A,getCurrentBranch:O,getDirection:N,getHead:j}},"./src/diagrams/git/gitGraphRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return d})),n.d(e,"draw",(function(){return _}));var r,i=n("d3"),a=n("./src/diagrams/git/gitGraphAst.js"),o=n("./src/diagrams/git/parser/gitGraph.jison"),s=n.n(o),c=n("./src/logger.js"),u=n("./src/utils.js"),l={},f={nodeSpacing:150,nodeFillColor:"yellow",nodeStrokeWidth:2,nodeStrokeColor:"grey",lineStrokeWidth:4,branchOffset:50,lineColor:"grey",leftMargin:50,branchColors:["#442f74","#983351","#609732","#AA9A39"],nodeRadius:10,nodeLabel:{width:75,height:100,x:-25,y:0}},h={},d=function(t){h=t};function p(t,e,n,r){var a=Object(u.interpolateToCurve)(r,i.curveBasis),o=f.branchColors[n%f.branchColors.length],s=Object(i.line)().x((function(t){return Math.round(t.x)})).y((function(t){return Math.round(t.y)})).curve(a);t.append("svg:path").attr("d",s(e)).style("stroke",o).style("stroke-width",f.lineStrokeWidth).style("fill","none")}function g(t,e){e=e||t.node().getBBox();var n=t.node().getCTM();return{left:n.e+e.x*n.a,top:n.f+e.y*n.d,width:e.width,height:e.height}}function y(t,e,n,r,i){c.log.debug("svgDrawLineForCommits: ",e,n);var a=g(t.select("#node-"+e+" circle")),o=g(t.select("#node-"+n+" circle"));switch(r){case"LR":if(a.left-o.left>f.nodeSpacing){var s={x:a.left-f.nodeSpacing,y:o.top+o.height/2};p(t,[s,{x:o.left+o.width,y:o.top+o.height/2}],i,"linear"),p(t,[{x:a.left,y:a.top+a.height/2},{x:a.left-f.nodeSpacing/2,y:a.top+a.height/2},{x:a.left-f.nodeSpacing/2,y:s.y},s],i)}else p(t,[{x:a.left,y:a.top+a.height/2},{x:a.left-f.nodeSpacing/2,y:a.top+a.height/2},{x:a.left-f.nodeSpacing/2,y:o.top+o.height/2},{x:o.left+o.width,y:o.top+o.height/2}],i);break;case"BT":if(o.top-a.top>f.nodeSpacing){var u={x:o.left+o.width/2,y:a.top+a.height+f.nodeSpacing};p(t,[u,{x:o.left+o.width/2,y:o.top}],i,"linear"),p(t,[{x:a.left+a.width/2,y:a.top+a.height},{x:a.left+a.width/2,y:a.top+a.height+f.nodeSpacing/2},{x:o.left+o.width/2,y:u.y-f.nodeSpacing/2},u],i)}else p(t,[{x:a.left+a.width/2,y:a.top+a.height},{x:a.left+a.width/2,y:a.top+f.nodeSpacing/2},{x:o.left+o.width/2,y:o.top-f.nodeSpacing/2},{x:o.left+o.width/2,y:o.top}],i)}}function m(t,e){return t.select(e).node().cloneNode(!0)}function v(t,e,n,i){var a,o=Object.keys(l).length;if("string"==typeof e)do{if(a=l[e],c.log.debug("in renderCommitHistory",a.id,a.seq),t.select("#node-"+e).size()>0)return;t.append((function(){return m(t,"#def-commit")})).attr("class","commit").attr("id",(function(){return"node-"+a.id})).attr("transform",(function(){switch(i){case"LR":return"translate("+(a.seq*f.nodeSpacing+f.leftMargin)+", "+r*f.branchOffset+")";case"BT":return"translate("+(r*f.branchOffset+f.leftMargin)+", "+(o-a.seq)*f.nodeSpacing+")"}})).attr("fill",f.nodeFillColor).attr("stroke",f.nodeStrokeColor).attr("stroke-width",f.nodeStrokeWidth);var s=void 0;for(var u in n)if(n[u].commit===a){s=n[u];break}s&&(c.log.debug("found branch ",s.name),t.select("#node-"+a.id+" p").append("xhtml:span").attr("class","branch-label").text(s.name+", ")),t.select("#node-"+a.id+" p").append("xhtml:span").attr("class","commit-id").text(a.id),""!==a.message&&"BT"===i&&t.select("#node-"+a.id+" p").append("xhtml:span").attr("class","commit-msg").text(", "+a.message),e=a.parent}while(e&&l[e]);Array.isArray(e)&&(c.log.debug("found merge commmit",e),v(t,e[0],n,i),r++,v(t,e[1],n,i),r--)}function b(t,e,n,r){for(r=r||0;e.seq>0&&!e.lineDrawn;)"string"==typeof e.parent?(y(t,e.id,e.parent,n,r),e.lineDrawn=!0,e=l[e.parent]):Array.isArray(e.parent)&&(y(t,e.id,e.parent[0],n,r),y(t,e.id,e.parent[1],n,r+1),b(t,l[e.parent[1]],n,r+1),e.lineDrawn=!0,e=l[e.parent[0]])}var _=function(t,e,n){try{var o=s.a.parser;o.yy=a.default,o.yy.clear(),c.log.debug("in gitgraph renderer",t+"\n","id:",e,n),o.parse(t+"\n"),f=Object.assign(f,h,a.default.getOptions()),c.log.debug("effective options",f);var u=a.default.getDirection();l=a.default.getCommits();var d=a.default.getBranchesAsObjArray();"BT"===u&&(f.nodeLabel.x=d.length*f.branchOffset,f.nodeLabel.width="100%",f.nodeLabel.y=-2*f.nodeRadius);var p=Object(i.select)('[id="'.concat(e,'"]'));for(var g in function(t){t.append("defs").append("g").attr("id","def-commit").append("circle").attr("r",f.nodeRadius).attr("cx",0).attr("cy",0),t.select("#def-commit").append("foreignObject").attr("width",f.nodeLabel.width).attr("height",f.nodeLabel.height).attr("x",f.nodeLabel.x).attr("y",f.nodeLabel.y).attr("class","node-label").attr("requiredFeatures","http://www.w3.org/TR/SVG11/feature#Extensibility").append("p").html("")}(p),r=1,d){var y=d[g];v(p,y.commit.id,d,u),b(p,y.commit,u),r++}p.attr("height",(function(){return"BT"===u?Object.keys(l).length*f.nodeSpacing:(d.length+1)*f.branchOffset}))}catch(t){c.log.error("Error while rendering gitgraph"),c.log.error(t.message)}};e.default={setConf:d,draw:_}},"./src/diagrams/git/parser/gitGraph.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[2,3],n=[1,7],r=[7,12,15,17,19,20,21],i=[7,11,12,15,17,19,20,21],a=[2,20],o=[1,32],s={trace:function(){},yy:{},symbols_:{error:2,start:3,GG:4,":":5,document:6,EOF:7,DIR:8,options:9,body:10,OPT:11,NL:12,line:13,statement:14,COMMIT:15,commit_arg:16,BRANCH:17,ID:18,CHECKOUT:19,MERGE:20,RESET:21,reset_arg:22,STR:23,HEAD:24,reset_parents:25,CARET:26,$accept:0,$end:1},terminals_:{2:"error",4:"GG",5:":",7:"EOF",8:"DIR",11:"OPT",12:"NL",15:"COMMIT",17:"BRANCH",18:"ID",19:"CHECKOUT",20:"MERGE",21:"RESET",23:"STR",24:"HEAD",26:"CARET"},productions_:[0,[3,4],[3,5],[6,0],[6,2],[9,2],[9,1],[10,0],[10,2],[13,2],[13,1],[14,2],[14,2],[14,2],[14,2],[14,2],[16,0],[16,1],[22,2],[22,2],[25,0],[25,2]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 2:return r.setDirection(a[s-3]),a[s-1];case 4:r.setOptions(a[s-1]),this.$=a[s];break;case 5:a[s-1]+=a[s],this.$=a[s-1];break;case 7:this.$=[];break;case 8:a[s-1].push(a[s]),this.$=a[s-1];break;case 9:this.$=a[s-1];break;case 11:r.commit(a[s]);break;case 12:r.branch(a[s]);break;case 13:r.checkout(a[s]);break;case 14:r.merge(a[s]);break;case 15:r.reset(a[s]);break;case 16:this.$="";break;case 17:this.$=a[s];break;case 18:this.$=a[s-1]+":"+a[s];break;case 19:this.$=a[s-1]+":"+r.count,r.count=0;break;case 20:r.count=0;break;case 21:r.count+=1}},table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3],8:[1,4]},{6:5,7:e,9:6,12:n},{5:[1,8]},{7:[1,9]},t(r,[2,7],{10:10,11:[1,11]}),t(i,[2,6]),{6:12,7:e,9:6,12:n},{1:[2,1]},{7:[2,4],12:[1,15],13:13,14:14,15:[1,16],17:[1,17],19:[1,18],20:[1,19],21:[1,20]},t(i,[2,5]),{7:[1,21]},t(r,[2,8]),{12:[1,22]},t(r,[2,10]),{12:[2,16],16:23,23:[1,24]},{18:[1,25]},{18:[1,26]},{18:[1,27]},{18:[1,30],22:28,24:[1,29]},{1:[2,2]},t(r,[2,9]),{12:[2,11]},{12:[2,17]},{12:[2,12]},{12:[2,13]},{12:[2,14]},{12:[2,15]},{12:a,25:31,26:o},{12:a,25:33,26:o},{12:[2,18]},{12:a,25:34,26:o},{12:[2,19]},{12:[2,21]}],defaultActions:{9:[2,1],21:[2,2],23:[2,11],24:[2,17],25:[2,12],26:[2,13],27:[2,14],28:[2,15],31:[2,18],33:[2,19],34:[2,21]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},c={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return 12;case 1:case 2:case 3:break;case 4:return 4;case 5:return 15;case 6:return 17;case 7:return 20;case 8:return 21;case 9:return 19;case 10:case 11:return 8;case 12:return 5;case 13:return 26;case 14:this.begin("options");break;case 15:case 18:this.popState();break;case 16:return 11;case 17:this.begin("string");break;case 19:return 23;case 20:return 18;case 21:return 7}},rules:[/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:gitGraph\b)/i,/^(?:commit\b)/i,/^(?:branch\b)/i,/^(?:merge\b)/i,/^(?:reset\b)/i,/^(?:checkout\b)/i,/^(?:LR\b)/i,/^(?:BT\b)/i,/^(?::)/i,/^(?:\^)/i,/^(?:options\r?\n)/i,/^(?:end\r?\n)/i,/^(?:[^\n]+\r?\n)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[a-zA-Z][-_\.a-zA-Z0-9]*[-_a-zA-Z0-9])/i,/^(?:$)/i],conditions:{options:{rules:[15,16],inclusive:!1},string:{rules:[18,19],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,17,20,21],inclusive:!0}}};function u(){this.yy={}}return s.lexer=c,u.prototype=s,s.Parser=u,new u}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/git/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(){return"\n .commit-id,\n .commit-msg,\n .branch-label {\n fill: lightgrey;\n color: lightgrey;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n }\n"}},"./src/diagrams/info/infoDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setMessage",(function(){return o})),n.d(e,"getMessage",(function(){return s})),n.d(e,"setInfo",(function(){return c})),n.d(e,"getInfo",(function(){return u}));var r=n("./src/logger.js"),i="",a=!1,o=function(t){r.log.debug("Setting message to: "+t),i=t},s=function(){return i},c=function(t){a=t},u=function(){return a};e.default={setMessage:o,getMessage:s,setInfo:c,getInfo:u}},"./src/diagrams/info/infoRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return u})),n.d(e,"draw",(function(){return l}));var r=n("d3"),i=n("./src/diagrams/info/infoDb.js"),a=n("./src/diagrams/info/parser/info.jison"),o=n.n(a),s=n("./src/logger.js"),c={},u=function(t){Object.keys(t).forEach((function(e){c[e]=t[e]}))},l=function(t,e,n){try{var a=o.a.parser;a.yy=i.default,s.log.debug("Renering info diagram\n"+t),a.parse(t),s.log.debug("Parsed info diagram");var c=Object(r.select)("#"+e);c.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size","32px").style("text-anchor","middle").text("v "+n),c.attr("height",100),c.attr("width",400)}catch(t){s.log.error("Error while rendering info diagram"),s.log.error(t.message)}};e.default={setConf:u,draw:l}},"./src/diagrams/info/parser/info.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[6,9,10],n={trace:function(){},yy:{},symbols_:{error:2,start:3,info:4,document:5,EOF:6,line:7,statement:8,NL:9,showInfo:10,$accept:0,$end:1},terminals_:{2:"error",4:"info",6:"EOF",9:"NL",10:"showInfo"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[8,1]],performAction:function(t,e,n,r,i,a,o){switch(a.length,i){case 1:return r;case 4:break;case 6:r.setInfo(!0)}},table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:6,9:[1,7],10:[1,8]},{1:[2,1]},t(e,[2,3]),t(e,[2,4]),t(e,[2,5]),t(e,[2,6])],defaultActions:{4:[2,1]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},r={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return 4;case 1:return 9;case 2:return"space";case 3:return 10;case 4:return 6;case 5:return"TXT"}},rules:[/^(?:info\b)/i,/^(?:[\s\n\r]+)/i,/^(?:[\s]+)/i,/^(?:showInfo\b)/i,/^(?:$)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5],inclusive:!0}}};function i(){this.yy={}}return n.lexer=r,i.prototype=n,n.Parser=i,new i}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/info/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(){return""}},"./src/diagrams/pie/parser/pie.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,4],n=[1,5],r=[1,6],i=[1,7],a=[1,9],o=[1,11,13,20,21,22,23],s=[2,5],c=[1,6,11,13,20,21,22,23],u=[20,21,22],l=[2,8],f=[1,18],h=[1,19],d=[1,24],p=[6,20,21,22,23],g={trace:function(){},yy:{},symbols_:{error:2,start:3,eol:4,directive:5,PIE:6,document:7,showData:8,line:9,statement:10,txt:11,value:12,title:13,title_value:14,openDirective:15,typeDirective:16,closeDirective:17,":":18,argDirective:19,NEWLINE:20,";":21,EOF:22,open_directive:23,type_directive:24,arg_directive:25,close_directive:26,$accept:0,$end:1},terminals_:{2:"error",6:"PIE",8:"showData",11:"txt",12:"value",13:"title",14:"title_value",18:":",20:"NEWLINE",21:";",22:"EOF",23:"open_directive",24:"type_directive",25:"arg_directive",26:"close_directive"},productions_:[0,[3,2],[3,2],[3,2],[3,3],[7,0],[7,2],[9,2],[10,0],[10,2],[10,2],[10,1],[5,3],[5,5],[4,1],[4,1],[4,1],[15,1],[16,1],[19,1],[17,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 4:r.setShowData(!0);break;case 7:this.$=a[s-1];break;case 9:r.addSection(a[s-1],r.cleanupValue(a[s]));break;case 10:this.$=a[s].trim(),r.setTitle(this.$);break;case 17:r.parseDirective("%%{","open_directive");break;case 18:r.parseDirective(a[s],"type_directive");break;case 19:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 20:r.parseDirective("}%%","close_directive","pie")}},table:[{3:1,4:2,5:3,6:e,15:8,20:n,21:r,22:i,23:a},{1:[3]},{3:10,4:2,5:3,6:e,15:8,20:n,21:r,22:i,23:a},{3:11,4:2,5:3,6:e,15:8,20:n,21:r,22:i,23:a},t(o,s,{7:12,8:[1,13]}),t(c,[2,14]),t(c,[2,15]),t(c,[2,16]),{16:14,24:[1,15]},{24:[2,17]},{1:[2,1]},{1:[2,2]},t(u,l,{15:8,9:16,10:17,5:20,1:[2,3],11:f,13:h,23:a}),t(o,s,{7:21}),{17:22,18:[1,23],26:d},t([18,26],[2,18]),t(o,[2,6]),{4:25,20:n,21:r,22:i},{12:[1,26]},{14:[1,27]},t(u,[2,11]),t(u,l,{15:8,9:16,10:17,5:20,1:[2,4],11:f,13:h,23:a}),t(p,[2,12]),{19:28,25:[1,29]},t(p,[2,20]),t(o,[2,7]),t(u,[2,9]),t(u,[2,10]),{17:30,26:d},{26:[2,19]},t(p,[2,13])],defaultActions:{9:[2,17],10:[2,1],11:[2,2],29:[2,19]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},y={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),23;case 1:return this.begin("type_directive"),24;case 2:return this.popState(),this.begin("arg_directive"),18;case 3:return this.popState(),this.popState(),26;case 4:return 25;case 5:case 6:case 8:case 9:break;case 7:return 20;case 10:return this.begin("title"),13;case 11:return this.popState(),"title_value";case 12:this.begin("string");break;case 13:this.popState();break;case 14:return"txt";case 15:return 6;case 16:return 8;case 17:return"value";case 18:return 22}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:[\s]+)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:pie\b)/i,/^(?:showData\b)/i,/^(?::[\s]*[\d]+(?:\.[\d]+)?)/i,/^(?:$)/i],conditions:{close_directive:{rules:[],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},open_directive:{rules:[1],inclusive:!1},title:{rules:[11],inclusive:!1},string:{rules:[13,14],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,12,15,16,17,18],inclusive:!0}}};function m(){this.yy={}}return g.lexer=y,m.prototype=g,g.Parser=m,new m}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/pie/pieDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return u}));var r=n("./src/logger.js"),i=n("./src/mermaidAPI.js"),a=n("./src/config.js"),o={},s="",c=!1,u=function(t,e,n){i.default.parseDirective(this,t,e,n)};e.default={parseDirective:u,getConfig:function(){return a.getConfig().pie},addSection:function(t,e){void 0===o[t]&&(o[t]=e,r.log.debug("Added new section :",t))},getSections:function(){return o},cleanupValue:function(t){return":"===t.substring(0,1)?(t=t.substring(1).trim(),Number(t.trim())):Number(t.trim())},clear:function(){o={},s="",c=!1},setTitle:function(t){s=t},getTitle:function(){return s},setShowData:function(t){c=t},getShowData:function(){return c}}},"./src/diagrams/pie/pieRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"draw",(function(){return h}));var r,i=n("d3"),a=n("./src/diagrams/pie/pieDb.js"),o=n("./src/diagrams/pie/parser/pie.jison"),s=n.n(o),c=n("./src/logger.js"),u=n("./src/utils.js"),l=n("./src/config.js"),f=l.getConfig(),h=function(t,e){try{f=l.getConfig();var n=s.a.parser;n.yy=a.default,c.log.debug("Rendering info diagram\n"+t),n.yy.clear(),n.parse(t),c.log.debug("Parsed info diagram");var o=document.getElementById(e);void 0===(r=o.parentElement.offsetWidth)&&(r=1200),void 0!==f.useWidth&&(r=f.useWidth),void 0!==f.pie.useWidth&&(r=f.pie.useWidth);var h=Object(i.select)("#"+e);Object(u.configureSvgSize)(h,450,r,f.pie.useMaxWidth),o.setAttribute("viewBox","0 0 "+r+" 450");var d=Math.min(r,450)/2-40,p=h.append("g").attr("transform","translate("+r/2+",225)"),g=a.default.getSections(),y=0;Object.keys(g).forEach((function(t){y+=g[t]}));var m=f.themeVariables,v=[m.pie1,m.pie2,m.pie3,m.pie4,m.pie5,m.pie6,m.pie7,m.pie8,m.pie9,m.pie10,m.pie11,m.pie12],b=Object(i.scaleOrdinal)().range(v),_=Object(i.pie)().value((function(t){return t[1]}))(Object.entries(g)),x=Object(i.arc)().innerRadius(0).outerRadius(d);p.selectAll("mySlices").data(_).enter().append("path").attr("d",x).attr("fill",(function(t){return b(t.data[0])})).attr("class","pieCircle"),p.selectAll("mySlices").data(_).enter().append("text").text((function(t){return(t.data[1]/y*100).toFixed(0)+"%"})).attr("transform",(function(t){return"translate("+x.centroid(t)+")"})).style("text-anchor","middle").attr("class","slice"),p.append("text").text(n.yy.getTitle()).attr("x",0).attr("y",-200).attr("class","pieTitleText");var w=p.selectAll(".legend").data(b.domain()).enter().append("g").attr("class","legend").attr("transform",(function(t,e){return"translate(216,"+(22*e-22*b.domain().length/2)+")"}));w.append("rect").attr("width",18).attr("height",18).style("fill",b).style("stroke",b),w.data(_).append("text").attr("x",22).attr("y",14).text((function(t){return n.yy.getShowData()||f.showData||f.pie.showData?t.data[0]+" ["+t.data[1]+"]":t.data[0]}))}catch(t){c.log.error("Error while rendering info diagram"),c.log.error(t)}};e.default={draw:h}},"./src/diagrams/pie/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return"\n .pieCircle{\n stroke: ".concat(t.pieStrokeColor,";\n stroke-width : ").concat(t.pieStrokeWidth,";\n opacity : ").concat(t.pieOpacity,";\n }\n .pieTitleText {\n text-anchor: middle;\n font-size: ").concat(t.pieTitleTextSize,";\n fill: ").concat(t.pieTitleTextColor,";\n font-family: ").concat(t.fontFamily,";\n }\n .slice {\n font-family: ").concat(t.fontFamily,";\n fill: ").concat(t.pieSectionTextColor,";\n font-size:").concat(t.pieSectionTextSize,";\n // fill: white;\n }\n .legend text {\n fill: ").concat(t.pieLegendTextColor,";\n font-family: ").concat(t.fontFamily,";\n font-size: ").concat(t.pieLegendTextSize,";\n }\n")}},"./src/diagrams/requirement/parser/requirementDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,3],n=[1,5],r=[1,17],i=[2,10],a=[1,21],o=[1,22],s=[1,23],c=[1,24],u=[1,25],l=[1,26],f=[1,19],h=[1,27],d=[1,28],p=[1,31],g=[66,67],y=[5,8,14,35,36,37,38,39,40,48,55,57,66,67],m=[5,6,8,14,35,36,37,38,39,40,48,66,67],v=[1,51],b=[1,52],_=[1,53],x=[1,54],w=[1,55],k=[1,56],T=[1,57],E=[57,58],C=[1,69],S=[1,65],M=[1,66],A=[1,67],O=[1,68],N=[1,70],j=[1,74],D=[1,75],B=[1,72],L=[1,73],I=[5,8,14,35,36,37,38,39,40,48,66,67],R={trace:function(){},yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,openDirective:9,typeDirective:10,closeDirective:11,":":12,argDirective:13,open_directive:14,type_directive:15,arg_directive:16,close_directive:17,requirementDef:18,elementDef:19,relationshipDef:20,requirementType:21,requirementName:22,STRUCT_START:23,requirementBody:24,ID:25,COLONSEP:26,id:27,TEXT:28,text:29,RISK:30,riskLevel:31,VERIFYMTHD:32,verifyType:33,STRUCT_STOP:34,REQUIREMENT:35,FUNCTIONAL_REQUIREMENT:36,INTERFACE_REQUIREMENT:37,PERFORMANCE_REQUIREMENT:38,PHYSICAL_REQUIREMENT:39,DESIGN_CONSTRAINT:40,LOW_RISK:41,MED_RISK:42,HIGH_RISK:43,VERIFY_ANALYSIS:44,VERIFY_DEMONSTRATION:45,VERIFY_INSPECTION:46,VERIFY_TEST:47,ELEMENT:48,elementName:49,elementBody:50,TYPE:51,type:52,DOCREF:53,ref:54,END_ARROW_L:55,relationship:56,LINE:57,END_ARROW_R:58,CONTAINS:59,COPIES:60,DERIVES:61,SATISFIES:62,VERIFIES:63,REFINES:64,TRACES:65,unqString:66,qString:67,$accept:0,$end:1},terminals_:{2:"error",5:"NEWLINE",6:"RD",8:"EOF",12:":",14:"open_directive",15:"type_directive",16:"arg_directive",17:"close_directive",23:"STRUCT_START",25:"ID",26:"COLONSEP",28:"TEXT",30:"RISK",32:"VERIFYMTHD",34:"STRUCT_STOP",35:"REQUIREMENT",36:"FUNCTIONAL_REQUIREMENT",37:"INTERFACE_REQUIREMENT",38:"PERFORMANCE_REQUIREMENT",39:"PHYSICAL_REQUIREMENT",40:"DESIGN_CONSTRAINT",41:"LOW_RISK",42:"MED_RISK",43:"HIGH_RISK",44:"VERIFY_ANALYSIS",45:"VERIFY_DEMONSTRATION",46:"VERIFY_INSPECTION",47:"VERIFY_TEST",48:"ELEMENT",51:"TYPE",53:"DOCREF",55:"END_ARROW_L",57:"LINE",58:"END_ARROW_R",59:"CONTAINS",60:"COPIES",61:"DERIVES",62:"SATISFIES",63:"VERIFIES",64:"REFINES",65:"TRACES",66:"unqString",67:"qString"},productions_:[0,[3,3],[3,2],[3,4],[4,3],[4,5],[9,1],[10,1],[13,1],[11,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[18,5],[24,5],[24,5],[24,5],[24,5],[24,2],[24,1],[21,1],[21,1],[21,1],[21,1],[21,1],[21,1],[31,1],[31,1],[31,1],[33,1],[33,1],[33,1],[33,1],[19,5],[50,5],[50,5],[50,2],[50,1],[20,5],[20,5],[56,1],[56,1],[56,1],[56,1],[56,1],[56,1],[56,1],[22,1],[22,1],[27,1],[27,1],[29,1],[29,1],[49,1],[49,1],[52,1],[52,1],[54,1],[54,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 6:r.parseDirective("%%{","open_directive");break;case 7:r.parseDirective(a[s],"type_directive");break;case 8:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 9:r.parseDirective("}%%","close_directive","pie");break;case 10:this.$=[];break;case 16:r.addRequirement(a[s-3],a[s-4]);break;case 17:r.setNewReqId(a[s-2]);break;case 18:r.setNewReqText(a[s-2]);break;case 19:r.setNewReqRisk(a[s-2]);break;case 20:r.setNewReqVerifyMethod(a[s-2]);break;case 23:this.$=r.RequirementType.REQUIREMENT;break;case 24:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 25:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 26:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 27:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 28:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 29:this.$=r.RiskLevel.LOW_RISK;break;case 30:this.$=r.RiskLevel.MED_RISK;break;case 31:this.$=r.RiskLevel.HIGH_RISK;break;case 32:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 33:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 34:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 35:this.$=r.VerifyType.VERIFY_TEST;break;case 36:r.addElement(a[s-3]);break;case 37:r.setNewElementType(a[s-2]);break;case 38:r.setNewElementDocRef(a[s-2]);break;case 41:r.addRelationship(a[s-2],a[s],a[s-4]);break;case 42:r.addRelationship(a[s-2],a[s-4],a[s]);break;case 43:this.$=r.Relationships.CONTAINS;break;case 44:this.$=r.Relationships.COPIES;break;case 45:this.$=r.Relationships.DERIVES;break;case 46:this.$=r.Relationships.SATISFIES;break;case 47:this.$=r.Relationships.VERIFIES;break;case 48:this.$=r.Relationships.REFINES;break;case 49:this.$=r.Relationships.TRACES}},table:[{3:1,4:2,6:e,9:4,14:n},{1:[3]},{3:7,4:2,5:[1,6],6:e,9:4,14:n},{5:[1,8]},{10:9,15:[1,10]},{15:[2,6]},{3:11,4:2,6:e,9:4,14:n},{1:[2,2]},{4:16,5:r,7:12,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{11:29,12:[1,30],17:p},t([12,17],[2,7]),{1:[2,1]},{8:[1,32]},{4:16,5:r,7:33,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{4:16,5:r,7:34,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{4:16,5:r,7:35,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{4:16,5:r,7:36,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{4:16,5:r,7:37,8:i,9:4,14:n,18:13,19:14,20:15,21:18,27:20,35:a,36:o,37:s,38:c,39:u,40:l,48:f,66:h,67:d},{22:38,66:[1,39],67:[1,40]},{49:41,66:[1,42],67:[1,43]},{55:[1,44],57:[1,45]},t(g,[2,23]),t(g,[2,24]),t(g,[2,25]),t(g,[2,26]),t(g,[2,27]),t(g,[2,28]),t(y,[2,52]),t(y,[2,53]),t(m,[2,4]),{13:46,16:[1,47]},t(m,[2,9]),{1:[2,3]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{23:[1,48]},{23:[2,50]},{23:[2,51]},{23:[1,49]},{23:[2,56]},{23:[2,57]},{56:50,59:v,60:b,61:_,62:x,63:w,64:k,65:T},{56:58,59:v,60:b,61:_,62:x,63:w,64:k,65:T},{11:59,17:p},{17:[2,8]},{5:[1,60]},{5:[1,61]},{57:[1,62]},t(E,[2,43]),t(E,[2,44]),t(E,[2,45]),t(E,[2,46]),t(E,[2,47]),t(E,[2,48]),t(E,[2,49]),{58:[1,63]},t(m,[2,5]),{5:C,24:64,25:S,28:M,30:A,32:O,34:N},{5:j,34:D,50:71,51:B,53:L},{27:76,66:h,67:d},{27:77,66:h,67:d},t(I,[2,16]),{26:[1,78]},{26:[1,79]},{26:[1,80]},{26:[1,81]},{5:C,24:82,25:S,28:M,30:A,32:O,34:N},t(I,[2,22]),t(I,[2,36]),{26:[1,83]},{26:[1,84]},{5:j,34:D,50:85,51:B,53:L},t(I,[2,40]),t(I,[2,41]),t(I,[2,42]),{27:86,66:h,67:d},{29:87,66:[1,88],67:[1,89]},{31:90,41:[1,91],42:[1,92],43:[1,93]},{33:94,44:[1,95],45:[1,96],46:[1,97],47:[1,98]},t(I,[2,21]),{52:99,66:[1,100],67:[1,101]},{54:102,66:[1,103],67:[1,104]},t(I,[2,39]),{5:[1,105]},{5:[1,106]},{5:[2,54]},{5:[2,55]},{5:[1,107]},{5:[2,29]},{5:[2,30]},{5:[2,31]},{5:[1,108]},{5:[2,32]},{5:[2,33]},{5:[2,34]},{5:[2,35]},{5:[1,109]},{5:[2,58]},{5:[2,59]},{5:[1,110]},{5:[2,60]},{5:[2,61]},{5:C,24:111,25:S,28:M,30:A,32:O,34:N},{5:C,24:112,25:S,28:M,30:A,32:O,34:N},{5:C,24:113,25:S,28:M,30:A,32:O,34:N},{5:C,24:114,25:S,28:M,30:A,32:O,34:N},{5:j,34:D,50:115,51:B,53:L},{5:j,34:D,50:116,51:B,53:L},t(I,[2,17]),t(I,[2,18]),t(I,[2,19]),t(I,[2,20]),t(I,[2,37]),t(I,[2,38])],defaultActions:{5:[2,6],7:[2,2],11:[2,1],32:[2,3],33:[2,11],34:[2,12],35:[2,13],36:[2,14],37:[2,15],39:[2,50],40:[2,51],42:[2,56],43:[2,57],47:[2,8],88:[2,54],89:[2,55],91:[2,29],92:[2,30],93:[2,31],95:[2,32],96:[2,33],97:[2,34],98:[2,35],100:[2,58],101:[2,59],103:[2,60],104:[2,61]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},P={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),14;case 1:return this.begin("type_directive"),15;case 2:return this.popState(),this.begin("arg_directive"),12;case 3:return this.popState(),this.popState(),17;case 4:return 16;case 5:return 5;case 6:case 7:case 8:break;case 9:return 8;case 10:return 6;case 11:return 23;case 12:return 34;case 13:return 26;case 14:return 25;case 15:return 28;case 16:return 30;case 17:return 32;case 18:return 35;case 19:return 36;case 20:return 37;case 21:return 38;case 22:return 39;case 23:return 40;case 24:return 41;case 25:return 42;case 26:return 43;case 27:return 44;case 28:return 45;case 29:return 46;case 30:return 47;case 31:return 48;case 32:return 59;case 33:return 60;case 34:return 61;case 35:return 62;case 36:return 63;case 37:return 64;case 38:return 65;case 39:return 51;case 40:return 53;case 41:return 55;case 42:return 58;case 43:return 57;case 44:this.begin("string");break;case 45:this.popState();break;case 46:return"qString";case 47:return e.yytext=e.yytext.trim(),66}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^\r\n\{\<\>\-\=]*)/i],conditions:{close_directive:{rules:[],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},open_directive:{rules:[1],inclusive:!1},unqString:{rules:[],inclusive:!1},token:{rules:[],inclusive:!1},string:{rules:[45,46],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,47],inclusive:!0}}};function F(){this.yy={}}return R.lexer=P,F.prototype=R,R.Parser=F,new F}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/requirement/requirementDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return f}));var r=n("./src/config.js"),i=n("./src/logger.js"),a=n("./src/mermaidAPI.js"),o=[],s={},c={},u={},l={},f=function(t,e,n){a.default.parseDirective(this,t,e,n)};e.default={RequirementType:{REQUIREMENT:"Requirement",FUNCTIONAL_REQUIREMENT:"Functional Requirement",INTERFACE_REQUIREMENT:"Interface Requirement",PERFORMANCE_REQUIREMENT:"Performance Requirement",PHYSICAL_REQUIREMENT:"Physical Requirement",DESIGN_CONSTRAINT:"Design Constraint"},RiskLevel:{LOW_RISK:"Low",MED_RISK:"Medium",HIGH_RISK:"High"},VerifyType:{VERIFY_ANALYSIS:"Analysis",VERIFY_DEMONSTRATION:"Demonstration",VERIFY_INSPECTION:"Inspection",VERIFY_TEST:"Test"},Relationships:{CONTAINS:"contains",COPIES:"copies",DERIVES:"derives",SATISFIES:"satisfies",VERIFIES:"verifies",REFINES:"refines",TRACES:"traces"},parseDirective:f,getConfig:function(){return r.getConfig().req},addRequirement:function(t,e){return void 0===c[t]&&(c[t]={name:t,type:e,id:s.id,text:s.text,risk:s.risk,verifyMethod:s.verifyMethod}),s={},c[t]},getRequirements:function(){return c},setNewReqId:function(t){void 0!==s&&(s.id=t)},setNewReqText:function(t){void 0!==s&&(s.text=t)},setNewReqRisk:function(t){void 0!==s&&(s.risk=t)},setNewReqVerifyMethod:function(t){void 0!==s&&(s.verifyMethod=t)},addElement:function(t){return void 0===l[t]&&(l[t]={name:t,type:u.type,docRef:u.docRef},i.log.info("Added new requirement: ",t)),u={},l[t]},getElements:function(){return l},setNewElementType:function(t){void 0!==u&&(u.type=t)},setNewElementDocRef:function(t){void 0!==u&&(u.docRef=t)},addRelationship:function(t,e,n){o.push({type:t,src:e,dst:n})},getRelationships:function(){return o},clear:function(){o=[],s={},c={},u={},l={}}}},"./src/diagrams/requirement/requirementMarkers.js":function(t,e,n){"use strict";n.r(e);var r={CONTAINS:"contains",ARROW:"arrow"};e.default={ReqMarkers:r,insertLineEndings:function(t,e){var n=t.append("defs").append("marker").attr("id",r.CONTAINS+"_line_ending").attr("refX",0).attr("refY",e.line_height/2).attr("markerWidth",e.line_height).attr("markerHeight",e.line_height).attr("orient","auto").append("g");n.append("circle").attr("cx",e.line_height/2).attr("cy",e.line_height/2).attr("r",e.line_height/2).attr("fill","none"),n.append("line").attr("x1",0).attr("x2",e.line_height).attr("y1",e.line_height/2).attr("y2",e.line_height/2).attr("stroke-width",1),n.append("line").attr("y1",0).attr("y2",e.line_height).attr("x1",e.line_height/2).attr("x2",e.line_height/2).attr("stroke-width",1),t.append("defs").append("marker").attr("id",r.ARROW+"_line_ending").attr("refX",e.line_height).attr("refY",.5*e.line_height).attr("markerWidth",e.line_height).attr("markerHeight",e.line_height).attr("orient","auto").append("path").attr("d","M0,0\n L".concat(e.line_height,",").concat(e.line_height/2,"\n M").concat(e.line_height,",").concat(e.line_height/2,"\n L0,").concat(e.line_height)).attr("stroke-width",1)}}},"./src/diagrams/requirement/requirementRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return y})),n.d(e,"drawReqs",(function(){return _})),n.d(e,"drawElements",(function(){return x})),n.d(e,"draw",(function(){return k}));var r=n("d3"),i=n("dagre"),a=n.n(i),o=n("graphlib"),s=n.n(o),c=n("./src/logger.js"),u=n("./src/utils.js"),l=n("./src/diagrams/common/common.js"),f=n("./src/diagrams/requirement/parser/requirementDiagram.jison"),h=n("./src/diagrams/requirement/requirementDb.js"),d=n("./src/diagrams/requirement/requirementMarkers.js"),p={},g=0,y=function(t){if(void 0!==t)for(var e=Object.keys(t),n=0;n<e.length;n++)p[e[n]]=t[e[n]]},m=function(t,e){return t.insert("rect","#"+e).attr("class","req reqBox").attr("x",0).attr("y",0).attr("width",p.rect_min_width+"px").attr("height",p.rect_min_height+"px")},v=function(t,e,n){var r=p.rect_min_width/2,i=t.append("text").attr("class","req reqLabel reqTitle").attr("id",e).attr("x",r).attr("y",p.rect_padding).attr("dominant-baseline","hanging"),a=0;n.forEach((function(t){0==a?i.append("tspan").attr("text-anchor","middle").attr("x",p.rect_min_width/2).attr("dy",0).text(t):i.append("tspan").attr("text-anchor","middle").attr("x",p.rect_min_width/2).attr("dy",.75*p.line_height).text(t),a++}));var o=1.5*p.rect_padding+a*p.line_height*.75;return t.append("line").attr("class","req-title-line").attr("x1","0").attr("x2",p.rect_min_width).attr("y1",o).attr("y2",o),{titleNode:i,y:o}},b=function(t,e,n,r){var i=t.append("text").attr("class","req reqLabel").attr("id",e).attr("x",p.rect_padding).attr("y",r).attr("dominant-baseline","hanging"),a=0,o=[];return n.forEach((function(t){for(var e=t.length;e>30&&a<3;){var n=t.substring(0,30);e=(t=t.substring(30,t.length)).length,o[o.length]=n,a++}if(3==a){var r=o[o.length-1];o[o.length-1]=r.substring(0,r.length-4)+"..."}else o[o.length]=t;a=0})),o.forEach((function(t){i.append("tspan").attr("x",p.rect_padding).attr("dy",p.line_height).text(t)})),i},_=function(t,e,n){Object.keys(t).forEach((function(r){var i=t[r];r=w(r),c.log.info("Added new requirement: ",r);var a=n.append("g").attr("id",r),o=m(a,"req-"+r),s=[],u=v(a,r+"_title",["<<".concat(i.type,">>"),"".concat(i.name)]);s.push(u.titleNode);var l=b(a,r+"_body",["Id: ".concat(i.id),"Text: ".concat(i.text),"Risk: ".concat(i.risk),"Verification: ".concat(i.verifyMethod)],u.y);s.push(l);var f=o.node().getBBox();e.setNode(r,{width:f.width,height:f.height,shape:"rect",id:r})}))},x=function(t,e,n){Object.keys(t).forEach((function(r){var i=t[r],a=w(r),o=n.append("g").attr("id",a),s="element-"+a,c=m(o,s),u=[],l=v(o,s+"_title",["<<Element>>","".concat(r)]);u.push(l.titleNode);var f=b(o,s+"_body",["Type: ".concat(i.type||"Not Specified"),"Doc Ref: ".concat(i.docRef||"None")],l.y);u.push(f);var h=c.node().getBBox();e.setNode(a,{width:h.width,height:h.height,shape:"rect",id:a})}))},w=function(t){return t.replace(/\s/g,"").replace(/\./g,"_")},k=function(t,e){f.parser.yy=h.default,f.parser.yy.clear(),f.parser.parse(t);var n=Object(r.select)("[id='".concat(e,"']"));d.default.insertLineEndings(n,p);var i,o,c=new s.a.Graph({multigraph:!1,compound:!1,directed:!0}).setGraph({rankdir:p.layoutDirection,marginx:20,marginy:20,nodesep:100,edgesep:100,ranksep:100}).setDefaultEdgeLabel((function(){return{}})),y=h.default.getRequirements(),m=h.default.getElements(),v=h.default.getRelationships();_(y,c,n),x(m,c,n),function(t,e){t.forEach((function(t){var n=w(t.src),r=w(t.dst);e.setEdge(n,r,{relationship:t})}))}(v,c),a.a.layout(c),i=n,(o=c).nodes().forEach((function(t){void 0!==t&&void 0!==o.node(t)&&(i.select("#"+t),i.select("#"+t).attr("transform","translate("+(o.node(t).x-o.node(t).width/2)+","+(o.node(t).y-o.node(t).height/2)+" )"))})),v.forEach((function(t){!function(t,e,n,i){var a=n.edge(w(e.src),w(e.dst)),o=Object(r.line)().x((function(t){return t.x})).y((function(t){return t.y})),s=t.insert("path","#"+i).attr("class","er relationshipLine").attr("d",o(a.points)).attr("fill","none");e.type==h.default.Relationships.CONTAINS?s.attr("marker-start","url("+l.default.getUrl(p.arrowMarkerAbsolute)+"#"+e.type+"_line_ending)"):(s.attr("stroke-dasharray","10,7"),s.attr("marker-end","url("+l.default.getUrl(p.arrowMarkerAbsolute)+"#"+d.default.ReqMarkers.ARROW+"_line_ending)")),function(t,e,n,r){var i=e.node().getTotalLength(),a=e.node().getPointAtLength(.5*i),o="rel"+g;g++;var s=t.append("text").attr("class","req relationshipLabel").attr("id",o).attr("x",a.x).attr("y",a.y).attr("text-anchor","middle").attr("dominant-baseline","middle").text(r).node().getBBox();t.insert("rect","#"+o).attr("class","req reqLabelBox").attr("x",a.x-s.width/2).attr("y",a.y-s.height/2).attr("width",s.width).attr("height",s.height).attr("fill","white").attr("fill-opacity","85%")}(t,s,0,"<<".concat(e.type,">>"))}(n,t,c,e)}));var b=p.rect_padding,k=n.node().getBBox(),T=k.width+2*b,E=k.height+2*b;Object(u.configureSvgSize)(n,E,T,p.useMaxWidth),n.attr("viewBox","".concat(k.x-b," ").concat(k.y-b," ").concat(T," ").concat(E))};e.default={setConf:y,draw:k}},"./src/diagrams/requirement/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return"\n\n marker {\n fill: ".concat(t.relationColor,";\n stroke: ").concat(t.relationColor,";\n }\n\n marker.cross {\n stroke: ").concat(t.lineColor,";\n }\n\n svg {\n font-family: ").concat(t.fontFamily,";\n font-size: ").concat(t.fontSize,";\n }\n\n .reqBox {\n fill: ").concat(t.requirementBackground,";\n fill-opacity: 100%;\n stroke: ").concat(t.requirementBorderColor,";\n stroke-width: ").concat(t.requirementBorderSize,";\n }\n \n .reqTitle, .reqLabel{\n fill: ").concat(t.requirementTextColor,";\n }\n .reqLabelBox {\n fill: ").concat(t.relationLabelBackground,";\n fill-opacity: 100%;\n }\n\n .req-title-line {\n stroke: ").concat(t.requirementBorderColor,";\n stroke-width: ").concat(t.requirementBorderSize,";\n }\n .relationshipLine {\n stroke: ").concat(t.relationColor,";\n stroke-width: 1;\n }\n .relationshipLabel {\n fill: ").concat(t.relationLabelColor,";\n }\n\n")}},"./src/diagrams/sequence/parser/sequenceDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,2],n=[1,3],r=[1,5],i=[1,7],a=[2,5],o=[1,15],s=[1,17],c=[1,18],u=[1,19],l=[1,21],f=[1,22],h=[1,23],d=[1,25],p=[1,26],g=[1,27],y=[1,28],m=[1,29],v=[1,30],b=[1,33],_=[1,34],x=[1,37],w=[1,4,5,16,20,22,23,24,26,28,29,30,31,32,34,36,37,38,49,59],k=[1,46],T=[4,5,16,20,22,23,24,26,28,29,30,31,32,34,38,49,59],E=[4,5,16,20,22,23,24,26,28,29,30,31,32,34,37,38,49,59],C=[4,5,16,20,22,23,24,26,28,29,30,31,32,34,36,38,49,59],S=[47,48,49],M=[1,4,5,7,16,20,22,23,24,26,28,29,30,31,32,34,36,37,38,49,59],A={trace:function(){},yy:{},symbols_:{error:2,start:3,SPACE:4,NEWLINE:5,directive:6,SD:7,document:8,line:9,statement:10,openDirective:11,typeDirective:12,closeDirective:13,":":14,argDirective:15,participant:16,actor:17,AS:18,restOfLine:19,participant_actor:20,signal:21,autonumber:22,activate:23,deactivate:24,note_statement:25,title:26,text2:27,loop:28,end:29,rect:30,opt:31,alt:32,else_sections:33,par:34,par_sections:35,and:36,else:37,note:38,placement:39,over:40,actor_pair:41,spaceList:42,",":43,left_of:44,right_of:45,signaltype:46,"+":47,"-":48,ACTOR:49,SOLID_OPEN_ARROW:50,DOTTED_OPEN_ARROW:51,SOLID_ARROW:52,DOTTED_ARROW:53,SOLID_CROSS:54,DOTTED_CROSS:55,SOLID_POINT:56,DOTTED_POINT:57,TXT:58,open_directive:59,type_directive:60,arg_directive:61,close_directive:62,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NEWLINE",7:"SD",14:":",16:"participant",18:"AS",19:"restOfLine",20:"participant_actor",22:"autonumber",23:"activate",24:"deactivate",26:"title",28:"loop",29:"end",30:"rect",31:"opt",32:"alt",34:"par",36:"and",37:"else",38:"note",40:"over",43:",",44:"left_of",45:"right_of",47:"+",48:"-",49:"ACTOR",50:"SOLID_OPEN_ARROW",51:"DOTTED_OPEN_ARROW",52:"SOLID_ARROW",53:"DOTTED_ARROW",54:"SOLID_CROSS",55:"DOTTED_CROSS",56:"SOLID_POINT",57:"DOTTED_POINT",58:"TXT",59:"open_directive",60:"type_directive",61:"arg_directive",62:"close_directive"},productions_:[0,[3,2],[3,2],[3,2],[3,2],[8,0],[8,2],[9,2],[9,1],[9,1],[6,4],[6,6],[10,5],[10,3],[10,5],[10,3],[10,2],[10,1],[10,3],[10,3],[10,2],[10,3],[10,4],[10,4],[10,4],[10,4],[10,4],[10,1],[35,1],[35,4],[33,1],[33,4],[25,4],[25,4],[42,2],[42,1],[41,3],[41,1],[39,1],[39,1],[21,5],[21,5],[21,4],[17,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[46,1],[27,1],[11,1],[12,1],[15,1],[13,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 4:return r.apply(a[s]),a[s];case 5:case 9:this.$=[];break;case 6:a[s-1].push(a[s]),this.$=a[s-1];break;case 7:case 8:case 37:this.$=a[s];break;case 12:a[s-3].type="addParticipant",a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 13:a[s-1].type="addParticipant",this.$=a[s-1];break;case 14:a[s-3].type="addActor",a[s-3].description=r.parseMessage(a[s-1]),this.$=a[s-3];break;case 15:a[s-1].type="addActor",this.$=a[s-1];break;case 17:r.enableSequenceNumbers();break;case 18:this.$={type:"activeStart",signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1]};break;case 19:this.$={type:"activeEnd",signalType:r.LINETYPE.ACTIVE_END,actor:a[s-1]};break;case 21:this.$=[{type:"setTitle",text:a[s-1]}];break;case 22:a[s-1].unshift({type:"loopStart",loopText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.LOOP_START}),a[s-1].push({type:"loopEnd",loopText:a[s-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[s-1];break;case 23:a[s-1].unshift({type:"rectStart",color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_START}),a[s-1].push({type:"rectEnd",color:r.parseMessage(a[s-2]),signalType:r.LINETYPE.RECT_END}),this.$=a[s-1];break;case 24:a[s-1].unshift({type:"optStart",optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_START}),a[s-1].push({type:"optEnd",optText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.OPT_END}),this.$=a[s-1];break;case 25:a[s-1].unshift({type:"altStart",altText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.ALT_START}),a[s-1].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[s-1];break;case 26:a[s-1].unshift({type:"parStart",parText:r.parseMessage(a[s-2]),signalType:r.LINETYPE.PAR_START}),a[s-1].push({type:"parEnd",signalType:r.LINETYPE.PAR_END}),this.$=a[s-1];break;case 29:this.$=a[s-3].concat([{type:"and",parText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.PAR_AND},a[s]]);break;case 31:this.$=a[s-3].concat([{type:"else",altText:r.parseMessage(a[s-1]),signalType:r.LINETYPE.ALT_ELSE},a[s]]);break;case 32:this.$=[a[s-1],{type:"addNote",placement:a[s-2],actor:a[s-1].actor,text:a[s]}];break;case 33:a[s-2]=[].concat(a[s-1],a[s-1]).slice(0,2),a[s-2][0]=a[s-2][0].actor,a[s-2][1]=a[s-2][1].actor,this.$=[a[s-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[s-2].slice(0,2),text:a[s]}];break;case 36:this.$=[a[s-2],a[s]];break;case 38:this.$=r.PLACEMENT.LEFTOF;break;case 39:this.$=r.PLACEMENT.RIGHTOF;break;case 40:this.$=[a[s-4],a[s-1],{type:"addMessage",from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s]},{type:"activeStart",signalType:r.LINETYPE.ACTIVE_START,actor:a[s-1]}];break;case 41:this.$=[a[s-4],a[s-1],{type:"addMessage",from:a[s-4].actor,to:a[s-1].actor,signalType:a[s-3],msg:a[s]},{type:"activeEnd",signalType:r.LINETYPE.ACTIVE_END,actor:a[s-4]}];break;case 42:this.$=[a[s-3],a[s-1],{type:"addMessage",from:a[s-3].actor,to:a[s-1].actor,signalType:a[s-2],msg:a[s]}];break;case 43:this.$={type:"addParticipant",actor:a[s]};break;case 44:this.$=r.LINETYPE.SOLID_OPEN;break;case 45:this.$=r.LINETYPE.DOTTED_OPEN;break;case 46:this.$=r.LINETYPE.SOLID;break;case 47:this.$=r.LINETYPE.DOTTED;break;case 48:this.$=r.LINETYPE.SOLID_CROSS;break;case 49:this.$=r.LINETYPE.DOTTED_CROSS;break;case 50:this.$=r.LINETYPE.SOLID_POINT;break;case 51:this.$=r.LINETYPE.DOTTED_POINT;break;case 52:this.$=r.parseMessage(a[s].trim().substring(1));break;case 53:r.parseDirective("%%{","open_directive");break;case 54:r.parseDirective(a[s],"type_directive");break;case 55:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 56:r.parseDirective("}%%","close_directive","sequence")}},table:[{3:1,4:e,5:n,6:4,7:r,11:6,59:i},{1:[3]},{3:8,4:e,5:n,6:4,7:r,11:6,59:i},{3:9,4:e,5:n,6:4,7:r,11:6,59:i},{3:10,4:e,5:n,6:4,7:r,11:6,59:i},t([1,4,5,16,20,22,23,24,26,28,30,31,32,34,38,49,59],a,{8:11}),{12:12,60:[1,13]},{60:[2,53]},{1:[2,1]},{1:[2,2]},{1:[2,3]},{1:[2,4],4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,30:g,31:y,32:m,34:v,38:b,49:_,59:i},{13:35,14:[1,36],62:x},t([14,62],[2,54]),t(w,[2,6]),{6:31,10:38,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,30:g,31:y,32:m,34:v,38:b,49:_,59:i},t(w,[2,8]),t(w,[2,9]),{17:39,49:_},{17:40,49:_},{5:[1,41]},t(w,[2,17]),{17:42,49:_},{17:43,49:_},{5:[1,44]},{27:45,58:k},{19:[1,47]},{19:[1,48]},{19:[1,49]},{19:[1,50]},{19:[1,51]},t(w,[2,27]),{46:52,50:[1,53],51:[1,54],52:[1,55],53:[1,56],54:[1,57],55:[1,58],56:[1,59],57:[1,60]},{39:61,40:[1,62],44:[1,63],45:[1,64]},t([5,18,43,50,51,52,53,54,55,56,57,58],[2,43]),{5:[1,65]},{15:66,61:[1,67]},{5:[2,56]},t(w,[2,7]),{5:[1,69],18:[1,68]},{5:[1,71],18:[1,70]},t(w,[2,16]),{5:[1,72]},{5:[1,73]},t(w,[2,20]),{5:[1,74]},{5:[2,52]},t(T,a,{8:75}),t(T,a,{8:76}),t(T,a,{8:77}),t(E,a,{33:78,8:79}),t(C,a,{35:80,8:81}),{17:84,47:[1,82],48:[1,83],49:_},t(S,[2,44]),t(S,[2,45]),t(S,[2,46]),t(S,[2,47]),t(S,[2,48]),t(S,[2,49]),t(S,[2,50]),t(S,[2,51]),{17:85,49:_},{17:87,41:86,49:_},{49:[2,38]},{49:[2,39]},t(M,[2,10]),{13:88,62:x},{62:[2,55]},{19:[1,89]},t(w,[2,13]),{19:[1,90]},t(w,[2,15]),t(w,[2,18]),t(w,[2,19]),t(w,[2,21]),{4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,29:[1,91],30:g,31:y,32:m,34:v,38:b,49:_,59:i},{4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,29:[1,92],30:g,31:y,32:m,34:v,38:b,49:_,59:i},{4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,29:[1,93],30:g,31:y,32:m,34:v,38:b,49:_,59:i},{29:[1,94]},{4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,29:[2,30],30:g,31:y,32:m,34:v,37:[1,95],38:b,49:_,59:i},{29:[1,96]},{4:o,5:s,6:31,9:14,10:16,11:6,16:c,17:32,20:u,21:20,22:l,23:f,24:h,25:24,26:d,28:p,29:[2,28],30:g,31:y,32:m,34:v,36:[1,97],38:b,49:_,59:i},{17:98,49:_},{17:99,49:_},{27:100,58:k},{27:101,58:k},{27:102,58:k},{43:[1,103],58:[2,37]},{5:[1,104]},{5:[1,105]},{5:[1,106]},t(w,[2,22]),t(w,[2,23]),t(w,[2,24]),t(w,[2,25]),{19:[1,107]},t(w,[2,26]),{19:[1,108]},{27:109,58:k},{27:110,58:k},{5:[2,42]},{5:[2,32]},{5:[2,33]},{17:111,49:_},t(M,[2,11]),t(w,[2,12]),t(w,[2,14]),t(E,a,{8:79,33:112}),t(C,a,{8:81,35:113}),{5:[2,40]},{5:[2,41]},{58:[2,36]},{29:[2,31]},{29:[2,29]}],defaultActions:{7:[2,53],8:[2,1],9:[2,2],10:[2,3],37:[2,56],46:[2,52],63:[2,38],64:[2,39],67:[2,55],100:[2,42],101:[2,32],102:[2,33],109:[2,40],110:[2,41],111:[2,36],112:[2,31],113:[2,29]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},O={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),59;case 1:return this.begin("type_directive"),60;case 2:return this.popState(),this.begin("arg_directive"),14;case 3:return this.popState(),this.popState(),62;case 4:return 61;case 5:case 35:case 48:return 5;case 6:case 7:case 8:case 9:case 10:break;case 11:return this.begin("ID"),16;case 12:return this.begin("ID"),20;case 13:return e.yytext=e.yytext.trim(),this.begin("ALIAS"),49;case 14:return this.popState(),this.popState(),this.begin("LINE"),18;case 15:return this.popState(),this.popState(),5;case 16:return this.begin("LINE"),28;case 17:return this.begin("LINE"),30;case 18:return this.begin("LINE"),31;case 19:return this.begin("LINE"),32;case 20:return this.begin("LINE"),37;case 21:return this.begin("LINE"),34;case 22:return this.begin("LINE"),36;case 23:return this.popState(),19;case 24:return 29;case 25:return 44;case 26:return 45;case 27:return 40;case 28:return 38;case 29:return this.begin("ID"),23;case 30:return this.begin("ID"),24;case 31:return 26;case 32:return 7;case 33:return 22;case 34:return 43;case 36:return e.yytext=e.yytext.trim(),49;case 37:return 52;case 38:return 53;case 39:return 50;case 40:return 51;case 41:return 54;case 42:return 55;case 43:return 56;case 44:return 57;case 45:return 58;case 46:return 47;case 47:return 48;case 49:return"INVALID"}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:participant\b)/i,/^(?:actor\b)/i,/^(?:[^\->:\n,;]+?(?=((?!\n)\s)+as(?!\n)\s|[#\n;]|$))/i,/^(?:as\b)/i,/^(?:(?:))/i,/^(?:loop\b)/i,/^(?:rect\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:par\b)/i,/^(?:and\b)/i,/^(?:(?:[:]?(?:no)?wrap)?[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:activate\b)/i,/^(?:deactivate\b)/i,/^(?:title\b)/i,/^(?:sequenceDiagram\b)/i,/^(?:autonumber\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\+\->:\n,;]+((?!(-x|--x|-\)|--\)))[\-]*[^\+\->:\n,;]+)*)/i,/^(?:->>)/i,/^(?:-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?:-[\)])/i,/^(?:--[\)])/i,/^(?::(?:(?:no)?wrap)?[^#\n;]+)/i,/^(?:\+)/i,/^(?:-)/i,/^(?:$)/i,/^(?:.)/i],conditions:{open_directive:{rules:[1,8],inclusive:!1},type_directive:{rules:[2,3,8],inclusive:!1},arg_directive:{rules:[3,4,8],inclusive:!1},ID:{rules:[7,8,13],inclusive:!1},ALIAS:{rules:[7,8,14,15],inclusive:!1},LINE:{rules:[7,8,23],inclusive:!1},INITIAL:{rules:[0,5,6,8,9,10,11,12,16,17,18,19,20,21,22,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49],inclusive:!0}}};function N(){this.yy={}}return A.lexer=O,N.prototype=A,A.Parser=N,new N}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/sequence/sequenceDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return p})),n.d(e,"addActor",(function(){return g})),n.d(e,"addMessage",(function(){return m})),n.d(e,"addSignal",(function(){return v})),n.d(e,"getMessages",(function(){return b})),n.d(e,"getActors",(function(){return _})),n.d(e,"getActor",(function(){return x})),n.d(e,"getActorKeys",(function(){return w})),n.d(e,"getTitle",(function(){return k})),n.d(e,"getTitleWrapped",(function(){return T})),n.d(e,"enableSequenceNumbers",(function(){return E})),n.d(e,"showSequenceNumbers",(function(){return C})),n.d(e,"setWrap",(function(){return S})),n.d(e,"autoWrap",(function(){return M})),n.d(e,"clear",(function(){return A})),n.d(e,"parseMessage",(function(){return O})),n.d(e,"LINETYPE",(function(){return N})),n.d(e,"ARROWTYPE",(function(){return j})),n.d(e,"PLACEMENT",(function(){return D})),n.d(e,"addNote",(function(){return B})),n.d(e,"setTitle",(function(){return L})),n.d(e,"apply",(function(){return I}));var r=n("./src/mermaidAPI.js"),i=n("./src/config.js"),a=n("./src/logger.js"),o=void 0,s={},c=[],u=[],l="",f=!1,h=!1,d=!1,p=function(t,e,n){r.default.parseDirective(this,t,e,n)},g=function(t,e,n,r){var i=s[t];i&&e===i.name&&null==n||(null!=n&&null!=n.text||(n={text:e,wrap:null,type:r}),null!=r&&null!=n.text||(n={text:e,wrap:null,type:r}),s[t]={name:e,description:n.text,wrap:void 0===n.wrap&&M()||!!n.wrap,prevActor:o,type:r||"participant"},o&&s[o]&&(s[o].nextActor=t),o=t)},y=function(t){var e,n=0;for(e=0;e<c.length;e++)c[e].type===N.ACTIVE_START&&c[e].from.actor===t&&n++,c[e].type===N.ACTIVE_END&&c[e].from.actor===t&&n--;return n},m=function(t,e,n,r){c.push({from:t,to:e,message:n.text,wrap:void 0===n.wrap&&M()||!!n.wrap,answer:r})},v=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{text:void 0,wrap:void 0},r=arguments.length>3?arguments[3]:void 0;if(r===N.ACTIVE_END){var i=y(t.actor);if(i<1){var a=new Error("Trying to inactivate an inactive participant ("+t.actor+")");throw a.hash={text:"->>-",token:"->>-",line:"1",loc:{first_line:1,last_line:1,first_column:1,last_column:1},expected:["'ACTIVE_PARTICIPANT'"]},a}}return c.push({from:t,to:e,message:n.text,wrap:void 0===n.wrap&&M()||!!n.wrap,type:r}),!0},b=function(){return c},_=function(){return s},x=function(t){return s[t]},w=function(){return Object.keys(s)},k=function(){return l},T=function(){return f},E=function(){h=!0},C=function(){return h},S=function(t){d=t},M=function(){return d},A=function(){s={},c=[]},O=function(t){var e=t.trim(),n={text:e.replace(/^[:]?(?:no)?wrap:/,"").trim(),wrap:null!==e.match(/^[:]?wrap:/)||null===e.match(/^[:]?nowrap:/)&&void 0};return a.log.debug("parseMessage:",n),n},N={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},j={FILLED:0,OPEN:1},D={LEFTOF:0,RIGHTOF:1,OVER:2},B=function(t,e,n){var r={actor:t,placement:e,message:n.text,wrap:void 0===n.wrap&&M()||!!n.wrap},i=[].concat(t,t);u.push(r),c.push({from:i[0],to:i[1],message:n.text,wrap:void 0===n.wrap&&M()||!!n.wrap,type:N.NOTE,placement:e})},L=function(t){l=t.text,f=void 0===t.wrap&&M()||!!t.wrap},I=function t(e){if(e instanceof Array)e.forEach((function(e){t(e)}));else switch(e.type){case"addParticipant":g(e.actor,e.actor,e.description,"participant");break;case"addActor":g(e.actor,e.actor,e.description,"actor");break;case"activeStart":case"activeEnd":v(e.actor,void 0,void 0,e.signalType);break;case"addNote":B(e.actor,e.placement,e.text);break;case"addMessage":v(e.from,e.to,e.msg,e.signalType);break;case"loopStart":v(void 0,void 0,e.loopText,e.signalType);break;case"loopEnd":case"rectEnd":case"optEnd":case"altEnd":case"parEnd":v(void 0,void 0,void 0,e.signalType);break;case"rectStart":v(void 0,void 0,e.color,e.signalType);break;case"optStart":v(void 0,void 0,e.optText,e.signalType);break;case"altStart":case"else":v(void 0,void 0,e.altText,e.signalType);break;case"setTitle":L(e.text);break;case"parStart":case"and":v(void 0,void 0,e.parText,e.signalType)}};e.default={addActor:g,addMessage:m,addSignal:v,autoWrap:M,setWrap:S,enableSequenceNumbers:E,showSequenceNumbers:C,getMessages:b,getActors:_,getActor:x,getActorKeys:w,getTitle:k,parseDirective:p,getConfig:function(){return i.getConfig().sequence},getTitleWrapped:T,clear:A,parseMessage:O,LINETYPE:N,ARROWTYPE:j,PLACEMENT:D,addNote:B,setTitle:L,apply:I}},"./src/diagrams/sequence/sequenceRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"bounds",(function(){return h})),n.d(e,"drawActors",(function(){return y})),n.d(e,"setConf",(function(){return m})),n.d(e,"draw",(function(){return x}));var r=n("d3"),i=n("./src/diagrams/sequence/svgDraw.js"),a=n("./src/logger.js"),o=n("./src/diagrams/sequence/parser/sequenceDiagram.jison"),s=n("./src/diagrams/common/common.js"),c=n("./src/diagrams/sequence/sequenceDb.js"),u=n("./src/config.js"),l=n("./src/utils.js");o.parser.yy=c.default;var f={},h={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],activations:[],models:{getHeight:function(){return Math.max.apply(null,0===this.actors.length?[0]:this.actors.map((function(t){return t.height||0})))+(0===this.loops.length?0:this.loops.map((function(t){return t.height||0})).reduce((function(t,e){return t+e})))+(0===this.messages.length?0:this.messages.map((function(t){return t.height||0})).reduce((function(t,e){return t+e})))+(0===this.notes.length?0:this.notes.map((function(t){return t.height||0})).reduce((function(t,e){return t+e})))},clear:function(){this.actors=[],this.loops=[],this.messages=[],this.notes=[]},addActor:function(t){this.actors.push(t)},addLoop:function(t){this.loops.push(t)},addMessage:function(t){this.messages.push(t)},addNote:function(t){this.notes.push(t)},lastActor:function(){return this.actors[this.actors.length-1]},lastLoop:function(){return this.loops[this.loops.length-1]},lastMessage:function(){return this.messages[this.messages.length-1]},lastNote:function(){return this.notes[this.notes.length-1]},actors:[],loops:[],messages:[],notes:[]},init:function(){this.sequenceItems=[],this.activations=[],this.models.clear(),this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0,m(o.parser.yy.getConfig())},updateVal:function(t,e,n,r){void 0===t[e]?t[e]=n:t[e]=r(n,t[e])},updateBounds:function(t,e,n,r){var i=this,a=0;function o(o){return function(s){a++;var c=i.sequenceItems.length-a+1;i.updateVal(s,"starty",e-c*f.boxMargin,Math.min),i.updateVal(s,"stopy",r+c*f.boxMargin,Math.max),i.updateVal(h.data,"startx",t-c*f.boxMargin,Math.min),i.updateVal(h.data,"stopx",n+c*f.boxMargin,Math.max),"activation"!==o&&(i.updateVal(s,"startx",t-c*f.boxMargin,Math.min),i.updateVal(s,"stopx",n+c*f.boxMargin,Math.max),i.updateVal(h.data,"starty",e-c*f.boxMargin,Math.min),i.updateVal(h.data,"stopy",r+c*f.boxMargin,Math.max))}}this.sequenceItems.forEach(o()),this.activations.forEach(o("activation"))},insert:function(t,e,n,r){var i=Math.min(t,n),a=Math.max(t,n),o=Math.min(e,r),s=Math.max(e,r);this.updateVal(h.data,"startx",i,Math.min),this.updateVal(h.data,"starty",o,Math.min),this.updateVal(h.data,"stopx",a,Math.max),this.updateVal(h.data,"stopy",s,Math.max),this.updateBounds(i,o,a,s)},newActivation:function(t,e,n){var r=n[t.from.actor],a=v(t.from.actor).length||0,o=r.x+r.width/2+(a-1)*f.activationWidth/2;this.activations.push({startx:o,starty:this.verticalPos+2,stopx:o+f.activationWidth,stopy:void 0,actor:t.from.actor,anchored:i.default.anchorElement(e)})},endActivation:function(t){var e=this.activations.map((function(t){return t.actor})).lastIndexOf(t.from.actor);return this.activations.splice(e,1)[0]},createLoop:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{message:void 0,wrap:!1,width:void 0},e=arguments.length>1?arguments[1]:void 0;return{startx:void 0,starty:this.verticalPos,stopx:void 0,stopy:void 0,title:t.message,wrap:t.wrap,width:t.width,height:0,fill:e}},newLoop:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{message:void 0,wrap:!1,width:void 0},e=arguments.length>1?arguments[1]:void 0;this.sequenceItems.push(this.createLoop(t,e))},endLoop:function(){return this.sequenceItems.pop()},addSectionToLoop:function(t){var e=this.sequenceItems.pop();e.sections=e.sections||[],e.sectionTitles=e.sectionTitles||[],e.sections.push({y:h.getVerticalPos(),height:0}),e.sectionTitles.push(t),this.sequenceItems.push(e)},bumpVerticalPos:function(t){this.verticalPos=this.verticalPos+t,this.data.stopy=this.verticalPos},getVerticalPos:function(){return this.verticalPos},getBounds:function(){return{bounds:this.data,models:this.models}}},d=function(t){return{fontFamily:t.messageFontFamily,fontSize:t.messageFontSize,fontWeight:t.messageFontWeight}},p=function(t){return{fontFamily:t.noteFontFamily,fontSize:t.noteFontSize,fontWeight:t.noteFontWeight}},g=function(t){return{fontFamily:t.actorFontFamily,fontSize:t.actorFontSize,fontWeight:t.actorFontWeight}},y=function(t,e,n,r){for(var a=0,o=0,s=0,c=0;c<n.length;c++){var u=e[n[c]];u.width=u.width||f.width,u.height=Math.max(u.height||f.height,f.height),u.margin=u.margin||f.actorMargin,u.x=a+o,u.y=r;var l=i.default.drawActor(t,u,f);s=Math.max(s,l),h.insert(u.x,r,u.x+u.width,u.height),a+=u.width,o+=u.margin,h.models.addActor(u)}h.bumpVerticalPos(s)},m=function(t){Object(l.assignWithDepth)(f,t),t.fontFamily&&(f.actorFontFamily=f.noteFontFamily=f.messageFontFamily=t.fontFamily),t.fontSize&&(f.actorFontSize=f.noteFontSize=f.messageFontSize=t.fontSize),t.fontWeight&&(f.actorFontWeight=f.noteFontWeight=f.messageFontWeight=t.fontWeight)},v=function(t){return h.activations.filter((function(e){return e.actor===t}))},b=function(t,e){var n=e[t],r=v(t);return[r.reduce((function(t,e){return Math.min(t,e.startx)}),n.x+n.width/2),r.reduce((function(t,e){return Math.max(t,e.stopx)}),n.x+n.width/2)]};function _(t,e,n,r,i){h.bumpVerticalPos(n);var o=r;if(e.id&&e.message&&t[e.id]){var s=t[e.id].width,c=d(f);e.message=l.default.wrapLabel("[".concat(e.message,"]"),s-2*f.wrapPadding,c),e.width=s,e.wrap=!0;var u=l.default.calculateTextDimensions(e.message,c),p=Math.max(u.height,f.labelBoxHeight);o=r+p,a.log.debug("".concat(p," - ").concat(e.message))}i(e),h.bumpVerticalPos(o)}var x=function(t,e){f=u.getConfig().sequence,o.parser.yy.clear(),o.parser.yy.setWrap(f.wrap),o.parser.parse(t+"\n"),h.init(),a.log.debug("C:".concat(JSON.stringify(f,null,2)));var n=Object(r.select)('[id="'.concat(e,'"]')),p=o.parser.yy.getActors(),g=o.parser.yy.getActorKeys(),m=o.parser.yy.getMessages(),b=o.parser.yy.getTitle(),x=w(p,m);f.height=k(p,x),y(n,p,g,0);var E=T(m,p,x);i.default.insertArrowHead(n),i.default.insertArrowCrossHead(n),i.default.insertArrowFilledHead(n),i.default.insertSequenceNumber(n);var C=1;m.forEach((function(t){var e,r,u;switch(t.type){case o.parser.yy.LINETYPE.NOTE:r=t.noteModel,function(t,e){h.bumpVerticalPos(f.boxMargin),e.height=f.boxMargin,e.starty=h.getVerticalPos();var n=i.default.getNoteRect();n.x=e.startx,n.y=e.starty,n.width=e.width||f.width,n.class="note";var r=t.append("g"),a=i.default.drawRect(r,n),o=i.default.getTextObj();o.x=e.startx,o.y=e.starty,o.width=n.width,o.dy="1em",o.text=e.message,o.class="noteText",o.fontFamily=f.noteFontFamily,o.fontSize=f.noteFontSize,o.fontWeight=f.noteFontWeight,o.anchor=f.noteAlign,o.textMargin=f.noteMargin,o.valign=f.noteAlign;var s=Object(i.drawText)(r,o),c=Math.round(s.map((function(t){return(t._groups||t)[0][0].getBBox().height})).reduce((function(t,e){return t+e})));a.attr("height",c+2*f.noteMargin),e.height+=c+2*f.noteMargin,h.bumpVerticalPos(c+2*f.noteMargin),e.stopy=e.starty+c+2*f.noteMargin,e.stopx=e.startx+n.width,h.insert(e.startx,e.starty,e.stopx,e.stopy),h.models.addNote(e)}(n,r);break;case o.parser.yy.LINETYPE.ACTIVE_START:h.newActivation(t,n,p);break;case o.parser.yy.LINETYPE.ACTIVE_END:!function(t,e){var r=h.endActivation(t);r.starty+18>e&&(r.starty=e-6,e+=12),i.default.drawActivation(n,r,e,f,v(t.from.actor).length),h.insert(r.startx,e-10,r.stopx,e)}(t,h.getVerticalPos());break;case o.parser.yy.LINETYPE.LOOP_START:_(E,t,f.boxMargin,f.boxMargin+f.boxTextMargin,(function(t){return h.newLoop(t)}));break;case o.parser.yy.LINETYPE.LOOP_END:e=h.endLoop(),i.default.drawLoop(n,e,"loop",f),h.bumpVerticalPos(e.stopy-h.getVerticalPos()),h.models.addLoop(e);break;case o.parser.yy.LINETYPE.RECT_START:_(E,t,f.boxMargin,f.boxMargin,(function(t){return h.newLoop(void 0,t.message)}));break;case o.parser.yy.LINETYPE.RECT_END:e=h.endLoop(),i.default.drawBackgroundRect(n,e),h.models.addLoop(e),h.bumpVerticalPos(e.stopy-h.getVerticalPos());break;case o.parser.yy.LINETYPE.OPT_START:_(E,t,f.boxMargin,f.boxMargin+f.boxTextMargin,(function(t){return h.newLoop(t)}));break;case o.parser.yy.LINETYPE.OPT_END:e=h.endLoop(),i.default.drawLoop(n,e,"opt",f),h.bumpVerticalPos(e.stopy-h.getVerticalPos()),h.models.addLoop(e);break;case o.parser.yy.LINETYPE.ALT_START:_(E,t,f.boxMargin,f.boxMargin+f.boxTextMargin,(function(t){return h.newLoop(t)}));break;case o.parser.yy.LINETYPE.ALT_ELSE:_(E,t,f.boxMargin+f.boxTextMargin,f.boxMargin,(function(t){return h.addSectionToLoop(t)}));break;case o.parser.yy.LINETYPE.ALT_END:e=h.endLoop(),i.default.drawLoop(n,e,"alt",f),h.bumpVerticalPos(e.stopy-h.getVerticalPos()),h.models.addLoop(e);break;case o.parser.yy.LINETYPE.PAR_START:_(E,t,f.boxMargin,f.boxMargin+f.boxTextMargin,(function(t){return h.newLoop(t)}));break;case o.parser.yy.LINETYPE.PAR_AND:_(E,t,f.boxMargin+f.boxTextMargin,f.boxMargin,(function(t){return h.addSectionToLoop(t)}));break;case o.parser.yy.LINETYPE.PAR_END:e=h.endLoop(),i.default.drawLoop(n,e,"par",f),h.bumpVerticalPos(e.stopy-h.getVerticalPos()),h.models.addLoop(e);break;default:try{(u=t.msgModel).starty=h.getVerticalPos(),u.sequenceIndex=C,function(t,e){h.bumpVerticalPos(10);var n=e.startx,r=e.stopx,a=e.starty,u=e.message,p=e.type,g=e.sequenceIndex,y=s.default.splitBreaks(u).length,m=l.default.calculateTextDimensions(u,d(f)),v=m.height/y;e.height+=v,h.bumpVerticalPos(v);var b=i.default.getTextObj();b.x=n,b.y=a+10,b.width=r-n,b.class="messageText",b.dy="1em",b.text=u,b.fontFamily=f.messageFontFamily,b.fontSize=f.messageFontSize,b.fontWeight=f.messageFontWeight,b.anchor=f.messageAlign,b.valign=f.messageAlign,b.textMargin=f.wrapPadding,b.tspan=!1,Object(i.drawText)(t,b);var _,x,w=m.height-10,k=m.width;if(n===r){x=h.getVerticalPos()+w,f.rightAngles?_=t.append("path").attr("d","M ".concat(n,",").concat(x," H ").concat(n+Math.max(f.width/2,k/2)," V ").concat(x+25," H ").concat(n)):(w+=f.boxMargin,x=h.getVerticalPos()+w,_=t.append("path").attr("d","M "+n+","+x+" C "+(n+60)+","+(x-10)+" "+(n+60)+","+(x+30)+" "+n+","+(x+20))),w+=30;var T=Math.max(k/2,f.width/2);h.insert(n-T,h.getVerticalPos()-10+w,r+T,h.getVerticalPos()+30+w)}else w+=f.boxMargin,x=h.getVerticalPos()+w,(_=t.append("line")).attr("x1",n),_.attr("y1",x),_.attr("x2",r),_.attr("y2",x),h.insert(n,x-10,r,x);p===o.parser.yy.LINETYPE.DOTTED||p===o.parser.yy.LINETYPE.DOTTED_CROSS||p===o.parser.yy.LINETYPE.DOTTED_POINT||p===o.parser.yy.LINETYPE.DOTTED_OPEN?(_.style("stroke-dasharray","3, 3"),_.attr("class","messageLine1")):_.attr("class","messageLine0");var E="";f.arrowMarkerAbsolute&&(E=(E=(E=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),_.attr("stroke-width",2),_.attr("stroke","none"),_.style("fill","none"),p!==o.parser.yy.LINETYPE.SOLID&&p!==o.parser.yy.LINETYPE.DOTTED||_.attr("marker-end","url("+E+"#arrowhead)"),p!==o.parser.yy.LINETYPE.SOLID_POINT&&p!==o.parser.yy.LINETYPE.DOTTED_POINT||_.attr("marker-end","url("+E+"#filled-head)"),p!==o.parser.yy.LINETYPE.SOLID_CROSS&&p!==o.parser.yy.LINETYPE.DOTTED_CROSS||_.attr("marker-end","url("+E+"#crosshead)"),(c.default.showSequenceNumbers()||f.showSequenceNumbers)&&(_.attr("marker-start","url("+E+"#sequencenumber)"),t.append("text").attr("x",n).attr("y",x+4).attr("font-family","sans-serif").attr("font-size","12px").attr("text-anchor","middle").attr("textLength","16px").attr("class","sequenceNumber").text(g)),h.bumpVerticalPos(w),e.height+=w,e.stopy=e.starty+e.height,h.insert(e.fromBounds,e.starty,e.toBounds,e.stopy)}(n,u),h.models.addMessage(u)}catch(t){a.log.error("error while drawing message",t)}}[o.parser.yy.LINETYPE.SOLID_OPEN,o.parser.yy.LINETYPE.DOTTED_OPEN,o.parser.yy.LINETYPE.SOLID,o.parser.yy.LINETYPE.DOTTED,o.parser.yy.LINETYPE.SOLID_CROSS,o.parser.yy.LINETYPE.DOTTED_CROSS,o.parser.yy.LINETYPE.SOLID_POINT,o.parser.yy.LINETYPE.DOTTED_POINT].includes(t.type)&&C++})),f.mirrorActors&&(h.bumpVerticalPos(2*f.boxMargin),y(n,p,g,h.getVerticalPos()),h.bumpVerticalPos(f.boxMargin),Object(i.fixLifeLineHeights)(n,h.getVerticalPos()));var S=h.getBounds().bounds;a.log.debug("For line height fix Querying: #"+e+" .actor-line"),Object(r.selectAll)("#"+e+" .actor-line").attr("y2",S.stopy);var M=S.stopy-S.starty+2*f.diagramMarginY;f.mirrorActors&&(M=M-f.boxMargin+f.bottomMarginAdj);var A=S.stopx-S.startx+2*f.diagramMarginX;b&&n.append("text").text(b).attr("x",(S.stopx-S.startx)/2-2*f.diagramMarginX).attr("y",-25),Object(l.configureSvgSize)(n,M,A,f.useMaxWidth);var O=b?40:0;n.attr("viewBox",S.startx-f.diagramMarginX+" -"+(f.diagramMarginY+O)+" "+A+" "+(M+O)),a.log.debug("models:",h.models)},w=function(t,e){var n={};return e.forEach((function(e){if(t[e.to]&&t[e.from]){var r=t[e.to];if(e.placement===o.parser.yy.PLACEMENT.LEFTOF&&!r.prevActor)return;if(e.placement===o.parser.yy.PLACEMENT.RIGHTOF&&!r.nextActor)return;var i=void 0!==e.placement,a=!i,s=i?p(f):d(f),c=e.wrap?l.default.wrapLabel(e.message,f.width-2*f.wrapPadding,s):e.message,u=l.default.calculateTextDimensions(c,s).width+2*f.wrapPadding;a&&e.from===r.nextActor?n[e.to]=Math.max(n[e.to]||0,u):a&&e.from===r.prevActor?n[e.from]=Math.max(n[e.from]||0,u):a&&e.from===e.to?(n[e.from]=Math.max(n[e.from]||0,u/2),n[e.to]=Math.max(n[e.to]||0,u/2)):e.placement===o.parser.yy.PLACEMENT.RIGHTOF?n[e.from]=Math.max(n[e.from]||0,u):e.placement===o.parser.yy.PLACEMENT.LEFTOF?n[r.prevActor]=Math.max(n[r.prevActor]||0,u):e.placement===o.parser.yy.PLACEMENT.OVER&&(r.prevActor&&(n[r.prevActor]=Math.max(n[r.prevActor]||0,u/2)),r.nextActor&&(n[e.from]=Math.max(n[e.from]||0,u/2)))}})),a.log.debug("maxMessageWidthPerActor:",n),n},k=function(t,e){var n=0;for(var r in Object.keys(t).forEach((function(e){var r=t[e];r.wrap&&(r.description=l.default.wrapLabel(r.description,f.width-2*f.wrapPadding,g(f)));var i=l.default.calculateTextDimensions(r.description,g(f));r.width=r.wrap?f.width:Math.max(f.width,i.width+2*f.wrapPadding),r.height=r.wrap?Math.max(i.height,f.height):f.height,n=Math.max(n,r.height)})),e){var i=t[r];if(i){var a=t[i.nextActor];if(a){var o=e[r]+f.actorMargin-i.width/2-a.width/2;i.margin=Math.max(o,f.actorMargin)}}}return Math.max(n,f.height)},T=function(t,e){var n,r,i,s={},c=[];return t.forEach((function(t){switch(t.id=l.default.random({length:10}),t.type){case o.parser.yy.LINETYPE.LOOP_START:case o.parser.yy.LINETYPE.ALT_START:case o.parser.yy.LINETYPE.OPT_START:case o.parser.yy.LINETYPE.PAR_START:c.push({id:t.id,msg:t.message,from:Number.MAX_SAFE_INTEGER,to:Number.MIN_SAFE_INTEGER,width:0});break;case o.parser.yy.LINETYPE.ALT_ELSE:case o.parser.yy.LINETYPE.PAR_AND:t.message&&(n=c.pop(),s[n.id]=n,s[t.id]=n,c.push(n));break;case o.parser.yy.LINETYPE.LOOP_END:case o.parser.yy.LINETYPE.ALT_END:case o.parser.yy.LINETYPE.OPT_END:case o.parser.yy.LINETYPE.PAR_END:n=c.pop(),s[n.id]=n;break;case o.parser.yy.LINETYPE.ACTIVE_START:var u=e[t.from?t.from.actor:t.to.actor],g=v(t.from?t.from.actor:t.to.actor).length,y=u.x+u.width/2+(g-1)*f.activationWidth/2,m={startx:y,stopx:y+f.activationWidth,actor:t.from.actor,enabled:!0};h.activations.push(m);break;case o.parser.yy.LINETYPE.ACTIVE_END:var _=h.activations.map((function(t){return t.actor})).lastIndexOf(t.from.actor);delete h.activations.splice(_,1)[0]}void 0!==t.placement?(r=function(t,e){var n=e[t.from].x,r=e[t.to].x,i=t.wrap&&t.message,s=l.default.calculateTextDimensions(i?l.default.wrapLabel(t.message,f.width,p(f)):t.message,p(f)),c={width:i?f.width:Math.max(f.width,s.width+2*f.noteMargin),height:0,startx:e[t.from].x,stopx:0,starty:0,stopy:0,message:t.message};return t.placement===o.parser.yy.PLACEMENT.RIGHTOF?(c.width=i?Math.max(f.width,s.width):Math.max(e[t.from].width/2+e[t.to].width/2,s.width+2*f.noteMargin),c.startx=n+(e[t.from].width+f.actorMargin)/2):t.placement===o.parser.yy.PLACEMENT.LEFTOF?(c.width=i?Math.max(f.width,s.width+2*f.noteMargin):Math.max(e[t.from].width/2+e[t.to].width/2,s.width+2*f.noteMargin),c.startx=n-c.width+(e[t.from].width-f.actorMargin)/2):t.to===t.from?(s=l.default.calculateTextDimensions(i?l.default.wrapLabel(t.message,Math.max(f.width,e[t.from].width),p(f)):t.message,p(f)),c.width=i?Math.max(f.width,e[t.from].width):Math.max(e[t.from].width,f.width,s.width+2*f.noteMargin),c.startx=n+(e[t.from].width-c.width)/2):(c.width=Math.abs(n+e[t.from].width/2-(r+e[t.to].width/2))+f.actorMargin,c.startx=n<r?n+e[t.from].width/2-f.actorMargin/2:r+e[t.to].width/2-f.actorMargin/2),i&&(c.message=l.default.wrapLabel(t.message,c.width-2*f.wrapPadding,p(f))),a.log.debug("NM:[".concat(c.startx,",").concat(c.stopx,",").concat(c.starty,",").concat(c.stopy,":").concat(c.width,",").concat(c.height,"=").concat(t.message,"]")),c}(t,e),t.noteModel=r,c.forEach((function(t){(n=t).from=Math.min(n.from,r.startx),n.to=Math.max(n.to,r.startx+r.width),n.width=Math.max(n.width,Math.abs(n.from-n.to))-f.labelBoxWidth}))):(i=function(t,e){var n=!1;if([o.parser.yy.LINETYPE.SOLID_OPEN,o.parser.yy.LINETYPE.DOTTED_OPEN,o.parser.yy.LINETYPE.SOLID,o.parser.yy.LINETYPE.DOTTED,o.parser.yy.LINETYPE.SOLID_CROSS,o.parser.yy.LINETYPE.DOTTED_CROSS,o.parser.yy.LINETYPE.SOLID_POINT,o.parser.yy.LINETYPE.DOTTED_POINT].includes(t.type)&&(n=!0),!n)return{};var r=b(t.from,e),i=b(t.to,e),a=r[0]<=i[0]?1:0,s=r[0]<i[0]?0:1,c=r.concat(i),u=Math.abs(i[s]-r[a]);t.wrap&&t.message&&(t.message=l.default.wrapLabel(t.message,Math.max(u+2*f.wrapPadding,f.width),d(f)));var h=l.default.calculateTextDimensions(t.message,d(f));return{width:Math.max(t.wrap?0:h.width+2*f.wrapPadding,u+2*f.wrapPadding,f.width),height:0,startx:r[a],stopx:i[s],starty:0,stopy:0,message:t.message,type:t.type,wrap:t.wrap,fromBounds:Math.min.apply(null,c),toBounds:Math.max.apply(null,c)}}(t,e),t.msgModel=i,i.startx&&i.stopx&&c.length>0&&c.forEach((function(r){if(n=r,i.startx===i.stopx){var a=e[t.from],o=e[t.to];n.from=Math.min(a.x-i.width/2,a.x-a.width/2,n.from),n.to=Math.max(o.x+i.width/2,o.x+a.width/2,n.to),n.width=Math.max(n.width,Math.abs(n.to-n.from))-f.labelBoxWidth}else n.from=Math.min(i.startx,n.from),n.to=Math.max(i.stopx,n.to),n.width=Math.max(n.width,i.width)-f.labelBoxWidth})))})),h.activations=[],a.log.debug("Loop type widths:",s),s};e.default={bounds:h,drawActors:y,setConf:m,draw:x}},"./src/diagrams/sequence/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return".actor {\n stroke: ".concat(t.actorBorder,";\n fill: ").concat(t.actorBkg,";\n }\n\n text.actor > tspan {\n fill: ").concat(t.actorTextColor,";\n stroke: none;\n }\n\n .actor-line {\n stroke: ").concat(t.actorLineColor,";\n }\n\n .messageLine0 {\n stroke-width: 1.5;\n stroke-dasharray: none;\n stroke: ").concat(t.signalColor,";\n }\n\n .messageLine1 {\n stroke-width: 1.5;\n stroke-dasharray: 2, 2;\n stroke: ").concat(t.signalColor,";\n }\n\n #arrowhead path {\n fill: ").concat(t.signalColor,";\n stroke: ").concat(t.signalColor,";\n }\n\n .sequenceNumber {\n fill: ").concat(t.sequenceNumberColor,";\n }\n\n #sequencenumber {\n fill: ").concat(t.signalColor,";\n }\n\n #crosshead path {\n fill: ").concat(t.signalColor,";\n stroke: ").concat(t.signalColor,";\n }\n\n .messageText {\n fill: ").concat(t.signalTextColor,";\n stroke: ").concat(t.signalTextColor,";\n }\n\n .labelBox {\n stroke: ").concat(t.labelBoxBorderColor,";\n fill: ").concat(t.labelBoxBkgColor,";\n }\n\n .labelText, .labelText > tspan {\n fill: ").concat(t.labelTextColor,";\n stroke: none;\n }\n\n .loopText, .loopText > tspan {\n fill: ").concat(t.loopTextColor,";\n stroke: none;\n }\n\n .loopLine {\n stroke-width: 2px;\n stroke-dasharray: 2, 2;\n stroke: ").concat(t.labelBoxBorderColor,";\n fill: ").concat(t.labelBoxBorderColor,";\n }\n\n .note {\n //stroke: #decc93;\n stroke: ").concat(t.noteBorderColor,";\n fill: ").concat(t.noteBkgColor,";\n }\n\n .noteText, .noteText > tspan {\n fill: ").concat(t.noteTextColor,";\n stroke: none;\n }\n\n .activation0 {\n fill: ").concat(t.activationBkgColor,";\n stroke: ").concat(t.activationBorderColor,";\n }\n\n .activation1 {\n fill: ").concat(t.activationBkgColor,";\n stroke: ").concat(t.activationBorderColor,";\n }\n\n .activation2 {\n fill: ").concat(t.activationBkgColor,";\n stroke: ").concat(t.activationBorderColor,";\n }\n .actor-man line {\n stroke: ").concat(t.actorBorder,";\n fill: ").concat(t.actorBkg,";\n }\n .actor-man circle, line {\n stroke: ").concat(t.actorBorder,";\n fill: ").concat(t.actorBkg,";\n stroke-width: 2px;\n }\n")}},"./src/diagrams/sequence/svgDraw.js":function(t,e,n){"use strict";n.r(e),n.d(e,"drawRect",(function(){return i})),n.d(e,"drawText",(function(){return a})),n.d(e,"drawLabel",(function(){return o})),n.d(e,"fixLifeLineHeights",(function(){return c})),n.d(e,"drawActor",(function(){return u})),n.d(e,"anchorElement",(function(){return l})),n.d(e,"drawActivation",(function(){return f})),n.d(e,"drawLoop",(function(){return h})),n.d(e,"drawBackgroundRect",(function(){return d})),n.d(e,"insertArrowHead",(function(){return p})),n.d(e,"insertArrowFilledHead",(function(){return g})),n.d(e,"insertSequenceNumber",(function(){return y})),n.d(e,"insertArrowCrossHead",(function(){return m})),n.d(e,"getTextObj",(function(){return v})),n.d(e,"getNoteRect",(function(){return b}));var r=n("./src/diagrams/common/common.js"),i=function(t,e){var n=t.append("rect");return n.attr("x",e.x),n.attr("y",e.y),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("width",e.width),n.attr("height",e.height),n.attr("rx",e.rx),n.attr("ry",e.ry),void 0!==e.class&&n.attr("class",e.class),n},a=function(t,e){var n=0,i=0,a=e.text.split(r.default.lineBreakRegex),o=[],s=0,c=function(){return e.y};if(void 0!==e.valign&&void 0!==e.textMargin&&e.textMargin>0)switch(e.valign){case"top":case"start":c=function(){return Math.round(e.y+e.textMargin)};break;case"middle":case"center":c=function(){return Math.round(e.y+(n+i+e.textMargin)/2)};break;case"bottom":case"end":c=function(){return Math.round(e.y+(n+i+2*e.textMargin)-e.textMargin)}}if(void 0!==e.anchor&&void 0!==e.textMargin&&void 0!==e.width)switch(e.anchor){case"left":case"start":e.x=Math.round(e.x+e.textMargin),e.anchor="start",e.dominantBaseline="text-after-edge",e.alignmentBaseline="middle";break;case"middle":case"center":e.x=Math.round(e.x+e.width/2),e.anchor="middle",e.dominantBaseline="middle",e.alignmentBaseline="middle";break;case"right":case"end":e.x=Math.round(e.x+e.width-e.textMargin),e.anchor="end",e.dominantBaseline="text-before-edge",e.alignmentBaseline="middle"}for(var u=0;u<a.length;u++){var l=a[u];void 0!==e.textMargin&&0===e.textMargin&&void 0!==e.fontSize&&(s=u*e.fontSize);var f=t.append("text");if(f.attr("x",e.x),f.attr("y",c()),void 0!==e.anchor&&f.attr("text-anchor",e.anchor).attr("dominant-baseline",e.dominantBaseline).attr("alignment-baseline",e.alignmentBaseline),void 0!==e.fontFamily&&f.style("font-family",e.fontFamily),void 0!==e.fontSize&&f.style("font-size",e.fontSize),void 0!==e.fontWeight&&f.style("font-weight",e.fontWeight),void 0!==e.fill&&f.attr("fill",e.fill),void 0!==e.class&&f.attr("class",e.class),void 0!==e.dy?f.attr("dy",e.dy):0!==s&&f.attr("dy",s),e.tspan){var h=f.append("tspan");h.attr("x",e.x),void 0!==e.fill&&h.attr("fill",e.fill),h.text(l)}else f.text(l);void 0!==e.valign&&void 0!==e.textMargin&&e.textMargin>0&&(i+=(f._groups||f)[0][0].getBBox().height,n=i),o.push(f)}return o},o=function(t,e){var n,r,i,o,s=t.append("polygon");return s.attr("points",(n=e.x)+","+(r=e.y)+" "+(n+(i=e.width))+","+r+" "+(n+i)+","+(r+(o=e.height)-7)+" "+(n+i-8.4)+","+(r+o)+" "+n+","+(r+o)),s.attr("class","labelBox"),e.y=e.y+e.height/2,a(t,e),s},s=-1,c=function(t,e){t.selectAll&&t.selectAll(".actor-line").attr("class","200").attr("y2",e-55)},u=function(t,e,n){switch(e.type){case"actor":return function(t,e,n){var r=e.x+e.width/2;0===e.y&&(s++,t.append("line").attr("id","actor"+s).attr("x1",r).attr("y1",80).attr("x2",r).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var i=t.append("g");i.attr("class","actor-man");var a=b();a.x=e.x,a.y=e.y,a.fill="#eaeaea",a.width=e.width,a.height=e.height,a.class="actor",a.rx=3,a.ry=3,i.append("line").attr("id","actor-man-torso"+s).attr("x1",r).attr("y1",e.y+25).attr("x2",r).attr("y2",e.y+45),i.append("line").attr("id","actor-man-arms"+s).attr("x1",r-18).attr("y1",e.y+33).attr("x2",r+18).attr("y2",e.y+33),i.append("line").attr("x1",r-18).attr("y1",e.y+60).attr("x2",r).attr("y2",e.y+45),i.append("line").attr("x1",r).attr("y1",e.y+45).attr("x2",r+16).attr("y2",e.y+60);var o=i.append("circle");o.attr("cx",e.x+e.width/2),o.attr("cy",e.y+10),o.attr("r",15),o.attr("width",e.width),o.attr("height",e.height);var c=i.node().getBBox();return e.height=c.height,_(n)(e.description,i,a.x,a.y+35,a.width,a.height,{class:"actor"},n),e.height}(t,e,n);case"participant":return function(t,e,n){var r=e.x+e.width/2,a=t.append("g");0===e.y&&(s++,a.append("line").attr("id","actor"+s).attr("x1",r).attr("y1",5).attr("x2",r).attr("y2",2e3).attr("class","actor-line").attr("stroke-width","0.5px").attr("stroke","#999"));var o=b();o.x=e.x,o.y=e.y,o.fill="#eaeaea",o.width=e.width,o.height=e.height,o.class="actor",o.rx=3,o.ry=3;var c=i(a,o);_(n)(e.description,a,o.x,o.y,o.width,o.height,{class:"actor"},n);var u=e.height;if(c.node){var l=c.node().getBBox();e.height=l.height,u=l.height}return u}(t,e,n)}},l=function(t){return t.append("g")},f=function(t,e,n,r,a){var o=b(),s=e.anchored;o.x=e.startx,o.y=e.starty,o.class="activation"+a%3,o.width=e.stopx-e.startx,o.height=n-e.starty,i(s,o)},h=function(t,e,n,r){var i=r.boxMargin,s=r.boxTextMargin,c=r.labelBoxHeight,u=r.labelBoxWidth,l=r.messageFontFamily,f=r.messageFontSize,h=r.messageFontWeight,d=t.append("g"),p=function(t,e,n,r){return d.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("class","loopLine")};p(e.startx,e.starty,e.stopx,e.starty),p(e.stopx,e.starty,e.stopx,e.stopy),p(e.startx,e.stopy,e.stopx,e.stopy),p(e.startx,e.starty,e.startx,e.stopy),void 0!==e.sections&&e.sections.forEach((function(t){p(e.startx,t.y,e.stopx,t.y).style("stroke-dasharray","3, 3")}));var g=v();g.text=n,g.x=e.startx,g.y=e.starty,g.fontFamily=l,g.fontSize=f,g.fontWeight=h,g.anchor="middle",g.valign="middle",g.tspan=!1,g.width=u||50,g.height=c||20,g.textMargin=s,g.class="labelText",o(d,g),(g=v()).text=e.title,g.x=e.startx+u/2+(e.stopx-e.startx)/2,g.y=e.starty+i+s,g.anchor="middle",g.valign="middle",g.textMargin=s,g.class="loopText",g.fontFamily=l,g.fontSize=f,g.fontWeight=h,g.wrap=!0;var y=a(d,g);return void 0!==e.sectionTitles&&e.sectionTitles.forEach((function(t,n){if(t.message){g.text=t.message,g.x=e.startx+(e.stopx-e.startx)/2,g.y=e.sections[n].y+i+s,g.class="loopText",g.anchor="middle",g.valign="middle",g.tspan=!1,g.fontFamily=l,g.fontSize=f,g.fontWeight=h,g.wrap=e.wrap,y=a(d,g);var r=Math.round(y.map((function(t){return(t._groups||t)[0][0].getBBox().height})).reduce((function(t,e){return t+e})));e.sections[n].height+=r-(i+s)}})),e.height=Math.round(e.stopy-e.starty),d},d=function(t,e){i(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,class:"rect"}).lower()},p=function(t){t.append("defs").append("marker").attr("id","arrowhead").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z")},g=function(t){t.append("defs").append("marker").attr("id","filled-head").attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},y=function(t){t.append("defs").append("marker").attr("id","sequencenumber").attr("refX",15).attr("refY",15).attr("markerWidth",60).attr("markerHeight",40).attr("orient","auto").append("circle").attr("cx",15).attr("cy",15).attr("r",6)},m=function(t){var e=t.append("defs").append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);e.append("path").attr("fill","black").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 9,2 V 6 L16,4 Z"),e.append("path").attr("fill","none").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 0,1 L 6,7 M 6,1 L 0,7")},v=function(){return{x:0,y:0,fill:void 0,anchor:void 0,style:"#666",width:void 0,height:void 0,textMargin:0,rx:0,ry:0,tspan:!0,valign:void 0}},b=function(){return{x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0}},_=function(){function t(t,e,n,r,a,o,s){i(e.append("text").attr("x",n+a/2).attr("y",r+o/2+5).style("text-anchor","middle").text(t),s)}function e(t,e,n,a,o,s,c,u){for(var l=u.actorFontSize,f=u.actorFontFamily,h=u.actorFontWeight,d=t.split(r.default.lineBreakRegex),p=0;p<d.length;p++){var g=p*l-l*(d.length-1)/2,y=e.append("text").attr("x",n+o/2).attr("y",a).style("text-anchor","middle").style("font-size",l).style("font-weight",h).style("font-family",f);y.append("tspan").attr("x",n+o/2).attr("dy",g).text(d[p]),y.attr("y",a+s/2).attr("dominant-baseline","central").attr("alignment-baseline","central"),i(y,c)}}function n(t,n,r,a,o,s,c,u){var l=n.append("switch"),f=l.append("foreignObject").attr("x",r).attr("y",a).attr("width",o).attr("height",s).append("xhtml:div").style("display","table").style("height","100%").style("width","100%");f.append("div").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(t),e(t,l,r,a,o,s,c,u),i(f,c)}function i(t,e){for(var n in e)e.hasOwnProperty(n)&&t.attr(n,e[n])}return function(r){return"fo"===r.textPlacement?n:"old"===r.textPlacement?t:e}}();e.default={drawRect:i,drawText:a,drawLabel:o,drawActor:u,anchorElement:l,drawActivation:f,drawLoop:h,drawBackgroundRect:d,insertArrowHead:p,insertArrowFilledHead:g,insertSequenceNumber:y,insertArrowCrossHead:m,getTextObj:v,getNoteRect:b,fixLifeLineHeights:c}},"./src/diagrams/state/id-cache.js":function(t,e,n){"use strict";n.r(e),n.d(e,"set",(function(){return i})),n.d(e,"get",(function(){return a})),n.d(e,"keys",(function(){return o})),n.d(e,"size",(function(){return s}));var r={},i=function(t,e){r[t]=e},a=function(t){return r[t]},o=function(){return Object.keys(r)},s=function(){return o().length};e.default={get:a,set:i,keys:o,size:s}},"./src/diagrams/state/parser/stateDiagram.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,2],n=[1,3],r=[1,5],i=[1,7],a=[2,5],o=[1,15],s=[1,17],c=[1,19],u=[1,20],l=[1,21],f=[1,22],h=[1,30],d=[1,23],p=[1,24],g=[1,25],y=[1,26],m=[1,27],v=[1,32],b=[1,33],_=[1,34],x=[1,35],w=[1,31],k=[1,38],T=[1,4,5,14,15,17,19,20,22,23,24,25,26,27,36,37,38,39,42,45],E=[1,4,5,12,13,14,15,17,19,20,22,23,24,25,26,27,36,37,38,39,42,45],C=[1,4,5,7,14,15,17,19,20,22,23,24,25,26,27,36,37,38,39,42,45],S=[4,5,14,15,17,19,20,22,23,24,25,26,27,36,37,38,39,42,45],M={trace:function(){},yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,directive:6,SD:7,document:8,line:9,statement:10,idStatement:11,DESCR:12,"--\x3e":13,HIDE_EMPTY:14,scale:15,WIDTH:16,COMPOSIT_STATE:17,STRUCT_START:18,STRUCT_STOP:19,STATE_DESCR:20,AS:21,ID:22,FORK:23,JOIN:24,CHOICE:25,CONCURRENT:26,note:27,notePosition:28,NOTE_TEXT:29,direction:30,openDirective:31,typeDirective:32,closeDirective:33,":":34,argDirective:35,direction_tb:36,direction_bt:37,direction_rl:38,direction_lr:39,eol:40,";":41,EDGE_STATE:42,left_of:43,right_of:44,open_directive:45,type_directive:46,arg_directive:47,close_directive:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",7:"SD",12:"DESCR",13:"--\x3e",14:"HIDE_EMPTY",15:"scale",16:"WIDTH",17:"COMPOSIT_STATE",18:"STRUCT_START",19:"STRUCT_STOP",20:"STATE_DESCR",21:"AS",22:"ID",23:"FORK",24:"JOIN",25:"CHOICE",26:"CONCURRENT",27:"note",29:"NOTE_TEXT",34:":",36:"direction_tb",37:"direction_bt",38:"direction_rl",39:"direction_lr",41:";",42:"EDGE_STATE",43:"left_of",44:"right_of",45:"open_directive",46:"type_directive",47:"arg_directive",48:"close_directive"},productions_:[0,[3,2],[3,2],[3,2],[3,2],[8,0],[8,2],[9,2],[9,1],[9,1],[10,1],[10,2],[10,3],[10,4],[10,1],[10,2],[10,1],[10,4],[10,3],[10,6],[10,1],[10,1],[10,1],[10,1],[10,4],[10,4],[10,1],[10,1],[6,3],[6,5],[30,1],[30,1],[30,1],[30,1],[40,1],[40,1],[11,1],[11,1],[28,1],[28,1],[31,1],[32,1],[35,1],[33,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 4:return r.setRootDoc(a[s]),a[s];case 5:this.$=[];break;case 6:"nl"!=a[s]&&(a[s-1].push(a[s]),this.$=a[s-1]);break;case 7:case 8:case 36:case 37:this.$=a[s];break;case 9:this.$="nl";break;case 10:this.$={stmt:"state",id:a[s],type:"default",description:""};break;case 11:this.$={stmt:"state",id:a[s-1],type:"default",description:r.trimColon(a[s])};break;case 12:this.$={stmt:"relation",state1:{stmt:"state",id:a[s-2],type:"default",description:""},state2:{stmt:"state",id:a[s],type:"default",description:""}};break;case 13:this.$={stmt:"relation",state1:{stmt:"state",id:a[s-3],type:"default",description:""},state2:{stmt:"state",id:a[s-1],type:"default",description:""},description:a[s].substr(1).trim()};break;case 17:this.$={stmt:"state",id:a[s-3],type:"default",description:"",doc:a[s-1]};break;case 18:var c=a[s],u=a[s-2].trim();if(a[s].match(":")){var l=a[s].split(":");c=l[0],u=[u,l[1]]}this.$={stmt:"state",id:c,type:"default",description:u};break;case 19:this.$={stmt:"state",id:a[s-3],type:"default",description:a[s-5],doc:a[s-1]};break;case 20:this.$={stmt:"state",id:a[s],type:"fork"};break;case 21:this.$={stmt:"state",id:a[s],type:"join"};break;case 22:this.$={stmt:"state",id:a[s],type:"choice"};break;case 23:this.$={stmt:"state",id:r.getDividerId(),type:"divider"};break;case 24:this.$={stmt:"state",id:a[s-1].trim(),note:{position:a[s-2].trim(),text:a[s].trim()}};break;case 30:r.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 31:r.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 32:r.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 33:r.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 40:r.parseDirective("%%{","open_directive");break;case 41:r.parseDirective(a[s],"type_directive");break;case 42:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 43:r.parseDirective("}%%","close_directive","state")}},table:[{3:1,4:e,5:n,6:4,7:r,31:6,45:i},{1:[3]},{3:8,4:e,5:n,6:4,7:r,31:6,45:i},{3:9,4:e,5:n,6:4,7:r,31:6,45:i},{3:10,4:e,5:n,6:4,7:r,31:6,45:i},t([1,4,5,14,15,17,20,22,23,24,25,26,27,36,37,38,39,42,45],a,{8:11}),{32:12,46:[1,13]},{46:[2,40]},{1:[2,1]},{1:[2,2]},{1:[2,3]},{1:[2,4],4:o,5:s,6:28,9:14,10:16,11:18,14:c,15:u,17:l,20:f,22:h,23:d,24:p,25:g,26:y,27:m,30:29,31:6,36:v,37:b,38:_,39:x,42:w,45:i},{33:36,34:[1,37],48:k},t([34,48],[2,41]),t(T,[2,6]),{6:28,10:39,11:18,14:c,15:u,17:l,20:f,22:h,23:d,24:p,25:g,26:y,27:m,30:29,31:6,36:v,37:b,38:_,39:x,42:w,45:i},t(T,[2,8]),t(T,[2,9]),t(T,[2,10],{12:[1,40],13:[1,41]}),t(T,[2,14]),{16:[1,42]},t(T,[2,16],{18:[1,43]}),{21:[1,44]},t(T,[2,20]),t(T,[2,21]),t(T,[2,22]),t(T,[2,23]),{28:45,29:[1,46],43:[1,47],44:[1,48]},t(T,[2,26]),t(T,[2,27]),t(E,[2,36]),t(E,[2,37]),t(T,[2,30]),t(T,[2,31]),t(T,[2,32]),t(T,[2,33]),t(C,[2,28]),{35:49,47:[1,50]},t(C,[2,43]),t(T,[2,7]),t(T,[2,11]),{11:51,22:h,42:w},t(T,[2,15]),t(S,a,{8:52}),{22:[1,53]},{22:[1,54]},{21:[1,55]},{22:[2,38]},{22:[2,39]},{33:56,48:k},{48:[2,42]},t(T,[2,12],{12:[1,57]}),{4:o,5:s,6:28,9:14,10:16,11:18,14:c,15:u,17:l,19:[1,58],20:f,22:h,23:d,24:p,25:g,26:y,27:m,30:29,31:6,36:v,37:b,38:_,39:x,42:w,45:i},t(T,[2,18],{18:[1,59]}),{29:[1,60]},{22:[1,61]},t(C,[2,29]),t(T,[2,13]),t(T,[2,17]),t(S,a,{8:62}),t(T,[2,24]),t(T,[2,25]),{4:o,5:s,6:28,9:14,10:16,11:18,14:c,15:u,17:l,19:[1,63],20:f,22:h,23:d,24:p,25:g,26:y,27:m,30:29,31:6,36:v,37:b,38:_,39:x,42:w,45:i},t(T,[2,19])],defaultActions:{7:[2,40],8:[2,1],9:[2,2],10:[2,3],47:[2,38],48:[2,39],50:[2,42]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},A={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:case 26:return 36;case 1:case 27:return 37;case 2:case 28:return 38;case 3:case 29:return 39;case 4:return this.begin("open_directive"),45;case 5:return this.begin("type_directive"),46;case 6:return this.popState(),this.begin("arg_directive"),34;case 7:return this.popState(),this.popState(),48;case 8:return 47;case 9:case 10:case 12:case 13:case 14:case 15:case 39:case 45:break;case 11:case 59:return 5;case 16:return this.pushState("SCALE"),15;case 17:return 16;case 18:case 33:case 36:this.popState();break;case 19:this.pushState("STATE");break;case 20:case 23:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),23;case 21:case 24:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),24;case 22:case 25:return this.popState(),e.yytext=e.yytext.slice(0,-10).trim(),25;case 30:this.begin("STATE_STRING");break;case 31:return this.popState(),this.pushState("STATE_ID"),"AS";case 32:case 47:return this.popState(),"ID";case 34:return"STATE_DESCR";case 35:return 17;case 37:return this.popState(),this.pushState("struct"),18;case 38:return this.popState(),19;case 40:return this.begin("NOTE"),27;case 41:return this.popState(),this.pushState("NOTE_ID"),43;case 42:return this.popState(),this.pushState("NOTE_ID"),44;case 43:this.popState(),this.pushState("FLOATING_NOTE");break;case 44:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";case 46:return"NOTE_TEXT";case 48:return this.popState(),this.pushState("NOTE_TEXT"),22;case 49:return this.popState(),e.yytext=e.yytext.substr(2).trim(),29;case 50:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),29;case 51:case 52:return 7;case 53:return 14;case 54:return 42;case 55:return 22;case 56:return e.yytext=e.yytext.trim(),12;case 57:return 13;case 58:return 26;case 60:return"INVALID"}},rules:[/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[13,14],inclusive:!1},close_directive:{rules:[13,14],inclusive:!1},arg_directive:{rules:[7,8,13,14],inclusive:!1},type_directive:{rules:[6,7,13,14],inclusive:!1},open_directive:{rules:[5,13,14],inclusive:!1},struct:{rules:[13,14,19,26,27,28,29,38,39,40,54,55,56,57,58],inclusive:!1},FLOATING_NOTE_ID:{rules:[47],inclusive:!1},FLOATING_NOTE:{rules:[44,45,46],inclusive:!1},NOTE_TEXT:{rules:[49,50],inclusive:!1},NOTE_ID:{rules:[48],inclusive:!1},NOTE:{rules:[41,42,43],inclusive:!1},SCALE:{rules:[17,18],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[32],inclusive:!1},STATE_STRING:{rules:[33,34],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[13,14,20,21,22,23,24,25,30,31,35,36,37],inclusive:!1},ID:{rules:[13,14],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,9,10,11,12,14,15,16,19,37,40,51,52,53,54,55,56,57,59,60],inclusive:!0}}};function O(){this.yy={}}return M.lexer=A,O.prototype=M,M.Parser=O,new O}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/state/shapes.js":function(t,e,n){"use strict";n.r(e),n.d(e,"drawStartState",(function(){return f})),n.d(e,"drawDivider",(function(){return h})),n.d(e,"drawSimpleState",(function(){return d})),n.d(e,"drawDescrState",(function(){return p})),n.d(e,"addTitleAndBox",(function(){return g})),n.d(e,"drawText",(function(){return y})),n.d(e,"drawNote",(function(){return m})),n.d(e,"drawState",(function(){return v})),n.d(e,"drawEdge",(function(){return _}));var r=n("d3"),i=n("./src/diagrams/state/id-cache.js"),a=n("./src/diagrams/state/stateDb.js"),o=n("./src/utils.js"),s=n("./src/diagrams/common/common.js"),c=n("./src/config.js"),u=n("./src/logger.js");function l(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var f=function(t){return t.append("circle").attr("class","start-state").attr("r",Object(c.getConfig)().state.sizeUnit).attr("cx",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit).attr("cy",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit)},h=function(t){return t.append("line").style("stroke","grey").style("stroke-dasharray","3").attr("x1",Object(c.getConfig)().state.textHeight).attr("class","divider").attr("x2",2*Object(c.getConfig)().state.textHeight).attr("y1",0).attr("y2",0)},d=function(t,e){var n=t.append("text").attr("x",2*Object(c.getConfig)().state.padding).attr("y",Object(c.getConfig)().state.textHeight+2*Object(c.getConfig)().state.padding).attr("font-size",Object(c.getConfig)().state.fontSize).attr("class","state-title").text(e.id),r=n.node().getBBox();return t.insert("rect",":first-child").attr("x",Object(c.getConfig)().state.padding).attr("y",Object(c.getConfig)().state.padding).attr("width",r.width+2*Object(c.getConfig)().state.padding).attr("height",r.height+2*Object(c.getConfig)().state.padding).attr("rx",Object(c.getConfig)().state.radius),n},p=function(t,e){var n=t.append("text").attr("x",2*Object(c.getConfig)().state.padding).attr("y",Object(c.getConfig)().state.textHeight+1.3*Object(c.getConfig)().state.padding).attr("font-size",Object(c.getConfig)().state.fontSize).attr("class","state-title").text(e.descriptions[0]).node().getBBox(),r=n.height,i=t.append("text").attr("x",Object(c.getConfig)().state.padding).attr("y",r+.4*Object(c.getConfig)().state.padding+Object(c.getConfig)().state.dividerMargin+Object(c.getConfig)().state.textHeight).attr("class","state-description"),a=!0,o=!0;e.descriptions.forEach((function(t){a||(function(t,e,n){var r=t.append("tspan").attr("x",2*Object(c.getConfig)().state.padding).text(e);n||r.attr("dy",Object(c.getConfig)().state.textHeight)}(i,t,o),o=!1),a=!1}));var s=t.append("line").attr("x1",Object(c.getConfig)().state.padding).attr("y1",Object(c.getConfig)().state.padding+r+Object(c.getConfig)().state.dividerMargin/2).attr("y2",Object(c.getConfig)().state.padding+r+Object(c.getConfig)().state.dividerMargin/2).attr("class","descr-divider"),u=i.node().getBBox(),l=Math.max(u.width,n.width);return s.attr("x2",l+3*Object(c.getConfig)().state.padding),t.insert("rect",":first-child").attr("x",Object(c.getConfig)().state.padding).attr("y",Object(c.getConfig)().state.padding).attr("width",l+2*Object(c.getConfig)().state.padding).attr("height",u.height+r+2*Object(c.getConfig)().state.padding).attr("rx",Object(c.getConfig)().state.radius),t},g=function(t,e,n){var r,i=Object(c.getConfig)().state.padding,a=2*Object(c.getConfig)().state.padding,o=t.node().getBBox(),s=o.width,u=o.x,l=t.append("text").attr("x",0).attr("y",Object(c.getConfig)().state.titleShift).attr("font-size",Object(c.getConfig)().state.fontSize).attr("class","state-title").text(e.id),f=l.node().getBBox().width+a,h=Math.max(f,s);h===s&&(h+=a);var d=t.node().getBBox();e.doc,r=u-i,f>s&&(r=(s-h)/2+i),Math.abs(u-d.x)<i&&f>s&&(r=u-(f-s)/2);var p=1-Object(c.getConfig)().state.textHeight;return t.insert("rect",":first-child").attr("x",r).attr("y",p).attr("class",n?"alt-composit":"composit").attr("width",h).attr("height",d.height+Object(c.getConfig)().state.textHeight+Object(c.getConfig)().state.titleShift+1).attr("rx","0"),l.attr("x",r+i),f<=s&&l.attr("x",u+(h-a)/2-f/2+i),t.insert("rect",":first-child").attr("x",r).attr("y",Object(c.getConfig)().state.titleShift-Object(c.getConfig)().state.textHeight-Object(c.getConfig)().state.padding).attr("width",h).attr("height",3*Object(c.getConfig)().state.textHeight).attr("rx",Object(c.getConfig)().state.radius),t.insert("rect",":first-child").attr("x",r).attr("y",Object(c.getConfig)().state.titleShift-Object(c.getConfig)().state.textHeight-Object(c.getConfig)().state.padding).attr("width",h).attr("height",d.height+3+2*Object(c.getConfig)().state.textHeight).attr("rx",Object(c.getConfig)().state.radius),t},y=function(t,e){var n=e.text.replace(s.default.lineBreakRegex," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.style("text-anchor",e.anchor),r.attr("fill",e.fill),void 0!==e.class&&r.attr("class",e.class);var i=r.append("tspan");return i.attr("x",e.x+2*e.textMargin),i.attr("fill",e.fill),i.text(n),r},m=function(t,e){e.attr("class","state-note");var n=e.append("rect").attr("x",0).attr("y",Object(c.getConfig)().state.padding),r=function(t,e,n,r){var i=0,a=r.append("text");a.style("text-anchor","start"),a.attr("class","noteText");var o,u=t.replace(/\r\n/g,"<br/>"),f=(u=u.replace(/\n/g,"<br/>")).split(s.default.lineBreakRegex),h=1.25*Object(c.getConfig)().state.noteMargin,d=function(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return l(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?l(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}(f);try{for(d.s();!(o=d.n()).done;){var p=o.value.trim();if(p.length>0){var g=a.append("tspan");g.text(p),0===h&&(h+=g.node().getBBox().height),i+=h,g.attr("x",0+Object(c.getConfig)().state.noteMargin),g.attr("y",0+i+1.25*Object(c.getConfig)().state.noteMargin)}}}catch(t){d.e(t)}finally{d.f()}return{textWidth:a.node().getBBox().width,textHeight:i}}(t,0,0,e.append("g")),i=r.textWidth,a=r.textHeight;return n.attr("height",a+2*Object(c.getConfig)().state.noteMargin),n.attr("width",i+2*Object(c.getConfig)().state.noteMargin),n},v=function(t,e){var n=e.id,r={id:n,label:e.id,width:0,height:0},a=t.append("g").attr("id",n).attr("class","stateGroup");"start"===e.type&&f(a),"end"===e.type&&function(t){t.append("circle").attr("class","end-state-outer").attr("r",Object(c.getConfig)().state.sizeUnit+Object(c.getConfig)().state.miniPadding).attr("cx",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit+Object(c.getConfig)().state.miniPadding).attr("cy",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit+Object(c.getConfig)().state.miniPadding),t.append("circle").attr("class","end-state-inner").attr("r",Object(c.getConfig)().state.sizeUnit).attr("cx",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit+2).attr("cy",Object(c.getConfig)().state.padding+Object(c.getConfig)().state.sizeUnit+2)}(a),"fork"!==e.type&&"join"!==e.type||function(t,e){var n=Object(c.getConfig)().state.forkWidth,r=Object(c.getConfig)().state.forkHeight;if(e.parentId){var i=n;n=r,r=i}t.append("rect").style("stroke","black").style("fill","black").attr("width",n).attr("height",r).attr("x",Object(c.getConfig)().state.padding).attr("y",Object(c.getConfig)().state.padding)}(a,e),"note"===e.type&&m(e.note.text,a),"divider"===e.type&&h(a),"default"===e.type&&0===e.descriptions.length&&d(a,e),"default"===e.type&&e.descriptions.length>0&&p(a,e);var o=a.node().getBBox();return r.width=o.width+2*Object(c.getConfig)().state.padding,r.height=o.height+2*Object(c.getConfig)().state.padding,i.default.set(n,r),r},b=0,_=function(t,e,n){e.points=e.points.filter((function(t){return!Number.isNaN(t.y)}));var i=e.points,l=Object(r.line)().x((function(t){return t.x})).y((function(t){return t.y})).curve(r.curveBasis),f=t.append("path").attr("d",l(i)).attr("id","edge"+b).attr("class","transition"),h="";if(Object(c.getConfig)().state.arrowMarkerAbsolute&&(h=(h=(h=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search).replace(/\(/g,"\\(")).replace(/\)/g,"\\)")),f.attr("marker-end","url("+h+"#"+function(t){switch(t){case a.default.relationType.AGGREGATION:return"aggregation";case a.default.relationType.EXTENSION:return"extension";case a.default.relationType.COMPOSITION:return"composition";case a.default.relationType.DEPENDENCY:return"dependency"}}(a.default.relationType.DEPENDENCY)+"End)"),void 0!==n.title){for(var d=t.append("g").attr("class","stateLabel"),p=o.default.calcLabelPosition(e.points),g=p.x,y=p.y,m=s.default.getRows(n.title),v=0,_=[],x=0,w=0,k=0;k<=m.length;k++){var T=d.append("text").attr("text-anchor","middle").text(m[k]).attr("x",g).attr("y",y+v),E=T.node().getBBox();if(x=Math.max(x,E.width),w=Math.min(w,E.x),u.log.info(E.x,g,y+v),0===v){var C=T.node().getBBox();v=C.height,u.log.info("Title height",v,y)}_.push(T)}var S=v*m.length;if(m.length>1){var M=(m.length-1)*v*.5;_.forEach((function(t,e){return t.attr("y",y+e*v-M)})),S=v*m.length}var A=d.node().getBBox();d.insert("rect",":first-child").attr("class","box").attr("x",g-x/2-Object(c.getConfig)().state.padding/2).attr("y",y-S/2-Object(c.getConfig)().state.padding/2-3.5).attr("width",x+Object(c.getConfig)().state.padding).attr("height",S+Object(c.getConfig)().state.padding),u.log.info(A)}b++}},"./src/diagrams/state/stateDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return f})),n.d(e,"addState",(function(){return y})),n.d(e,"clear",(function(){return m})),n.d(e,"getState",(function(){return v})),n.d(e,"getStates",(function(){return b})),n.d(e,"logDocuments",(function(){return _})),n.d(e,"getRelations",(function(){return x})),n.d(e,"addRelation",(function(){return w})),n.d(e,"cleanupLabel",(function(){return T})),n.d(e,"lineType",(function(){return E})),n.d(e,"relationType",(function(){return A}));var r=n("./src/logger.js"),i=n("./src/utils.js"),a=n("./src/mermaidAPI.js"),o=n("./src/diagrams/common/common.js"),s=n("./src/config.js");function c(t){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},c(t)}var u=function(t){return JSON.parse(JSON.stringify(t))},l=[],f=function(t,e,n){a.default.parseDirective(this,t,e,n)},h=function t(e,n,r){if("relation"===n.stmt)t(e,n.state1,!0),t(e,n.state2,!1);else if("state"===n.stmt&&"[*]"===n.id&&(n.id=r?e.id+"_start":e.id+"_end",n.start=r),n.doc){var a=[],o=0,s=[];for(o=0;o<n.doc.length;o++)if("divider"===n.doc[o].type){var c=u(n.doc[o]);c.doc=u(s),a.push(c),s=[]}else s.push(n.doc[o]);if(a.length>0&&s.length>0){var l={stmt:"state",id:Object(i.generateId)(),type:"divider",doc:u(s)};a.push(u(l)),n.doc=a}n.doc.forEach((function(e){return t(n,e,!0)}))}},d={root:{relations:[],states:{},documents:{}}},p=d.root,g=0,y=function(t,e,n,i,a){void 0===p.states[t]?p.states[t]={id:t,descriptions:[],type:e,doc:n,note:a}:(p.states[t].doc||(p.states[t].doc=n),p.states[t].type||(p.states[t].type=e)),i&&(r.log.info("Adding state ",t,i),"string"==typeof i&&k(t,i.trim()),"object"===c(i)&&i.forEach((function(e){return k(t,e.trim())}))),a&&(p.states[t].note=a,p.states[t].note.text=o.default.sanitizeText(p.states[t].note.text,s.getConfig()))},m=function(){p=(d={root:{relations:[],states:{},documents:{}}}).root,p=d.root,g=0,S=[]},v=function(t){return p.states[t]},b=function(){return p.states},_=function(){r.log.info("Documents = ",d)},x=function(){return p.relations},w=function(t,e,n){var r=t,i=e,a="default",c="default";"[*]"===t&&(r="start"+ ++g,a="start"),"[*]"===e&&(i="end"+g,c="end"),y(r,a),y(i,c),p.relations.push({id1:r,id2:i,title:o.default.sanitizeText(n,s.getConfig())})},k=function(t,e){var n=p.states[t],r=e;":"===r[0]&&(r=r.substr(1).trim()),n.descriptions.push(o.default.sanitizeText(r,s.getConfig()))},T=function(t){return":"===t.substring(0,1)?t.substr(2).trim():t.trim()},E={LINE:0,DOTTED_LINE:1},C=0,S=[],M="TB",A={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3};e.default={parseDirective:f,getConfig:function(){return s.getConfig().state},addState:y,clear:m,getState:v,getStates:b,getRelations:x,getClasses:function(){return S},getDirection:function(){return M},addRelation:w,getDividerId:function(){return"divider-id-"+ ++C},setDirection:function(t){M=t},cleanupLabel:T,lineType:E,relationType:A,logDocuments:_,getRootDoc:function(){return l},setRootDoc:function(t){r.log.info("Setting root doc",t),l=t},getRootDocV2:function(){return h({id:"root"},{id:"root",doc:l},!0),{id:"root",doc:l}},extract:function(t){var e;e=t.doc?t.doc:t,r.log.info(e),m(),r.log.info("Extract",e),e.forEach((function(t){"state"===t.stmt&&y(t.id,t.type,t.doc,t.description,t.note),"relation"===t.stmt&&w(t.state1.id,t.state2.id,t.description)}))},trimColon:function(t){return t&&":"===t[0]?t.substr(1).trim():t.trim()}}},"./src/diagrams/state/stateRenderer-v2.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return g})),n.d(e,"getClasses",(function(){return m})),n.d(e,"draw",(function(){return w}));var r=n("graphlib"),i=n.n(r),a=n("d3"),o=n("./src/diagrams/state/stateDb.js"),s=n("./src/diagrams/state/parser/stateDiagram.jison"),c=n.n(s),u=n("./src/config.js"),l=n("./src/dagre-wrapper/index.js"),f=n("./src/logger.js"),h=n("./src/utils.js"),d=n("./src/diagrams/common/common.js"),p={},g=function(t){for(var e=Object.keys(t),n=0;n<e.length;n++)p[e[n]]=t[e[n]]},y={},m=function(t){f.log.trace("Extracting classes"),o.default.clear();var e=c.a.parser;return e.yy=o.default,e.parse(t),o.default.getClasses()},v=function(t,e,n,r){if("root"!==n.id){var i="rect";!0===n.start&&(i="start"),!1===n.start&&(i="end"),"default"!==n.type&&(i=n.type),y[n.id]||(y[n.id]={id:n.id,shape:i,description:d.default.sanitizeText(n.id,Object(u.getConfig)()),classes:"statediagram-state"}),n.description&&(Array.isArray(y[n.id].description)?(y[n.id].shape="rectWithTitle",y[n.id].description.push(n.description)):y[n.id].description.length>0?(y[n.id].shape="rectWithTitle",y[n.id].description===n.id?y[n.id].description=[n.description]:y[n.id].description=[y[n.id].description,n.description]):(y[n.id].shape="rect",y[n.id].description=n.description)),!y[n.id].type&&n.doc&&(f.log.info("Setting cluster for ",n.id,x(n)),y[n.id].type="group",y[n.id].dir=x(n),y[n.id].shape="divider"===n.type?"divider":"roundedWithTitle",y[n.id].classes=y[n.id].classes+" "+(r?"statediagram-cluster statediagram-cluster-alt":"statediagram-cluster"));var a={labelStyle:"",shape:y[n.id].shape,labelText:y[n.id].description,classes:y[n.id].classes,style:"",id:n.id,dir:y[n.id].dir,domId:"state-"+n.id+"-"+b,type:y[n.id].type,padding:15};if(n.note){var o={labelStyle:"",shape:"note",labelText:n.note.text,classes:"statediagram-note",style:"",id:n.id+"----note-"+b,domId:"state-"+n.id+"----note-"+b,type:y[n.id].type,padding:15},s={labelStyle:"",shape:"noteGroup",labelText:n.note.text,classes:y[n.id].classes,style:"",id:n.id+"----parent",domId:"state-"+n.id+"----parent-"+b,type:"group",padding:0};b++,t.setNode(n.id+"----parent",s),t.setNode(o.id,o),t.setNode(n.id,a),t.setParent(n.id,n.id+"----parent"),t.setParent(o.id,n.id+"----parent");var c=n.id,l=o.id;"left of"===n.note.position&&(c=o.id,l=n.id),t.setEdge(c,l,{arrowhead:"none",arrowType:"",style:"fill:none",labelStyle:"",classes:"transition note-edge",arrowheadStyle:"fill: #333",labelpos:"c",labelType:"text",thickness:"normal"})}else t.setNode(n.id,a)}e&&"root"!==e.id&&(f.log.trace("Setting node ",n.id," to be child of its parent ",e.id),t.setParent(n.id,e.id)),n.doc&&(f.log.trace("Adding nodes children "),_(t,n,n.doc,!r))},b=0,_=function(t,e,n,r){f.log.trace("items",n),n.forEach((function(n){if("state"===n.stmt||"default"===n.stmt)v(t,e,n,r);else if("relation"===n.stmt){v(t,e,n.state1,r),v(t,e,n.state2,r);var i={id:"edge"+b,arrowhead:"normal",arrowTypeEnd:"arrow_barb",style:"fill:none",labelStyle:"",label:n.description,arrowheadStyle:"fill: #333",labelpos:"c",labelType:"text",thickness:"normal",classes:"transition"},a=n.state1.id,o=n.state2.id;t.setEdge(a,o,i,b),b++}}))},x=function(t,e){var n=e||"TB";if(t.doc)for(var r=0;r<t.doc.length;r++){var i=t.doc[r];"dir"===i.stmt&&(n=i.value)}return n},w=function(t,e){f.log.info("Drawing state diagram (v2)",e),o.default.clear(),y={};var n=c.a.parser;n.yy=o.default,n.parse(t);var r=o.default.getDirection();void 0===r&&(r="LR");var s=Object(u.getConfig)().state,d=s.nodeSpacing||50,p=s.rankSpacing||50;f.log.info(o.default.getRootDocV2()),o.default.extract(o.default.getRootDocV2()),f.log.info(o.default.getRootDocV2());var g=new i.a.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:x(o.default.getRootDocV2()),nodesep:d,ranksep:p,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}}));v(g,void 0,o.default.getRootDocV2(),!0);var m=Object(a.select)('[id="'.concat(e,'"]')),b=Object(a.select)("#"+e+" g");Object(l.render)(b,g,["barb"],"statediagram",e);var _=m.node().getBBox(),w=_.width+16,k=_.height+16;m.attr("class","statediagram");var T=m.node().getBBox();Object(h.configureSvgSize)(m,k,1.75*w,s.useMaxWidth);var E="".concat(T.x-8," ").concat(T.y-8," ").concat(w," ").concat(k);f.log.debug("viewBox ".concat(E)),m.attr("viewBox",E);for(var C=document.querySelectorAll('[id="'+e+'"] .edgeLabel .label'),S=0;S<C.length;S++){var M=C[S],A=M.getBBox(),O=document.createElementNS("http://www.w3.org/2000/svg","rect");O.setAttribute("rx",0),O.setAttribute("ry",0),O.setAttribute("width",A.width),O.setAttribute("height",A.height),M.insertBefore(O,M.firstChild)}};e.default={setConf:g,getClasses:m,draw:w}},"./src/diagrams/state/stateRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return m})),n.d(e,"draw",(function(){return v}));var r,i=n("d3"),a=n("dagre"),o=n.n(a),s=n("graphlib"),c=n.n(s),u=n("./src/logger.js"),l=n("./src/diagrams/state/stateDb.js"),f=n("./src/diagrams/common/common.js"),h=n("./src/diagrams/state/parser/stateDiagram.jison"),d=n("./src/diagrams/state/shapes.js"),p=n("./src/config.js"),g=n("./src/utils.js");h.parser.yy=l.default;var y={},m=function(){},v=function(t,e){r=Object(p.getConfig)().state,h.parser.yy.clear(),h.parser.parse(t),u.log.debug("Rendering diagram "+t);var n=Object(i.select)("[id='".concat(e,"']"));n.append("defs").append("marker").attr("id","dependencyEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z"),new c.a.Graph({multigraph:!0,compound:!0,rankdir:"RL"}).setDefaultEdgeLabel((function(){return{}}));var a=l.default.getRootDoc();b(a,n,void 0,!1);var o=r.padding,s=n.node().getBBox(),f=s.width+2*o,d=s.height+2*o,y=1.75*f;Object(g.configureSvgSize)(n,d,y,r.useMaxWidth),n.attr("viewBox","".concat(s.x-r.padding," ").concat(s.y-r.padding," ")+f+" "+d)},b=function t(e,n,a,s){var h,p=new c.a.Graph({compound:!0,multigraph:!0}),g=!0;for(h=0;h<e.length;h++)if("relation"===e[h].stmt){g=!1;break}a?p.setGraph({rankdir:"LR",multigraph:!0,compound:!0,ranker:"tight-tree",ranksep:g?1:r.edgeLengthFactor,nodeSep:g?1:50,isMultiGraph:!0}):p.setGraph({rankdir:"TB",multigraph:!0,compound:!0,ranksep:g?1:r.edgeLengthFactor,nodeSep:g?1:50,ranker:"tight-tree",isMultiGraph:!0}),p.setDefaultEdgeLabel((function(){return{}})),l.default.extract(e);for(var m=l.default.getStates(),v=l.default.getRelations(),b=Object.keys(m),_=0;_<b.length;_++){var x=m[b[_]];a&&(x.parentId=a);var w=void 0;if(x.doc){var k=n.append("g").attr("id",x.id).attr("class","stateGroup");w=t(x.doc,k,x.id,!s);var T=(k=Object(d.addTitleAndBox)(k,x,s)).node().getBBox();w.width=T.width,w.height=T.height+r.padding/2,y[x.id]={y:r.compositTitleSize}}else w=Object(d.drawState)(n,x,p);if(x.note){var E={descriptions:[],id:x.id+"-note",note:x.note,type:"note"},C=Object(d.drawState)(n,E,p);"left of"===x.note.position?(p.setNode(w.id+"-note",C),p.setNode(w.id,w)):(p.setNode(w.id,w),p.setNode(w.id+"-note",C)),p.setParent(w.id,w.id+"-group"),p.setParent(w.id+"-note",w.id+"-group")}else p.setNode(w.id,w)}u.log.debug("Count=",p.nodeCount(),p);var S=0;v.forEach((function(t){var e;S++,u.log.debug("Setting edge",t),p.setEdge(t.id1,t.id2,{relation:t,width:(e=t.title,e?e.length*r.fontSizeFactor:1),height:r.labelHeight*f.default.getRows(t.title).length,labelpos:"c"},"id"+S)})),o.a.layout(p),u.log.debug("Graph after layout",p.nodes());var M=n.node();p.nodes().forEach((function(t){void 0!==t&&void 0!==p.node(t)?(u.log.warn("Node "+t+": "+JSON.stringify(p.node(t))),Object(i.select)("#"+M.id+" #"+t).attr("transform","translate("+(p.node(t).x-p.node(t).width/2)+","+(p.node(t).y+(y[t]?y[t].y:0)-p.node(t).height/2)+" )"),Object(i.select)("#"+M.id+" #"+t).attr("data-x-shift",p.node(t).x-p.node(t).width/2),document.querySelectorAll("#"+M.id+" #"+t+" .divider").forEach((function(t){var e=t.parentElement,n=0,r=0;e&&(e.parentElement&&(n=e.parentElement.getBBox().width),r=parseInt(e.getAttribute("data-x-shift"),10),Number.isNaN(r)&&(r=0)),t.setAttribute("x1",0-r+8),t.setAttribute("x2",n-r-8)}))):u.log.debug("No Node "+t+": "+JSON.stringify(p.node(t)))}));var A=M.getBBox();p.edges().forEach((function(t){void 0!==t&&void 0!==p.edge(t)&&(u.log.debug("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(p.edge(t))),Object(d.drawEdge)(n,p.edge(t),p.edge(t).relation))})),A=M.getBBox();var O={id:a||"root",label:a||"root",width:0,height:0};return O.width=A.width+2*r.padding,O.height=A.height+2*r.padding,u.log.debug("Doc rendered",O,p),O};e.default={setConf:m,draw:v}},"./src/diagrams/state/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return"\ndefs #statediagram-barbEnd {\n fill: ".concat(t.transitionColor,";\n stroke: ").concat(t.transitionColor,";\n }\ng.stateGroup text {\n fill: ").concat(t.nodeBorder,";\n stroke: none;\n font-size: 10px;\n}\ng.stateGroup text {\n fill: ").concat(t.textColor,";\n stroke: none;\n font-size: 10px;\n\n}\ng.stateGroup .state-title {\n font-weight: bolder;\n fill: ").concat(t.stateLabelColor,";\n}\n\ng.stateGroup rect {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n}\n\ng.stateGroup line {\n stroke: ").concat(t.lineColor,";\n stroke-width: 1;\n}\n\n.transition {\n stroke: ").concat(t.transitionColor,";\n stroke-width: 1;\n fill: none;\n}\n\n.stateGroup .composit {\n fill: ").concat(t.background,";\n border-bottom: 1px\n}\n\n.stateGroup .alt-composit {\n fill: #e0e0e0;\n border-bottom: 1px\n}\n\n.state-note {\n stroke: ").concat(t.noteBorderColor,";\n fill: ").concat(t.noteBkgColor,";\n\n text {\n fill: ").concat(t.noteTextColor,";\n stroke: none;\n font-size: 10px;\n }\n}\n\n.stateLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ").concat(t.mainBkg,";\n opacity: 0.5;\n}\n\n.edgeLabel .label rect {\n fill: ").concat(t.labelBackgroundColor,";\n opacity: 0.5;\n}\n.edgeLabel .label text {\n fill: ").concat(t.transitionLabelColor||t.tertiaryTextColor,";\n}\n.label div .edgeLabel {\n color: ").concat(t.transitionLabelColor||t.tertiaryTextColor,";\n}\n\n.stateLabel text {\n fill: ").concat(t.stateLabelColor,";\n font-size: 10px;\n font-weight: bold;\n}\n\n.node circle.state-start {\n fill: ").concat(t.specialStateColor,";\n stroke: ").concat(t.specialStateColor,";\n}\n\n.node .fork-join {\n fill: ").concat(t.specialStateColor,";\n stroke: ").concat(t.specialStateColor,";\n}\n\n.node circle.state-end {\n fill: ").concat(t.innerEndBackground,";\n stroke: ").concat(t.background,";\n stroke-width: 1.5\n}\n.end-state-inner {\n fill: ").concat(t.compositeBackground||t.background,";\n // stroke: ").concat(t.background,";\n stroke-width: 1.5\n}\n\n.node rect {\n fill: ").concat(t.stateBkg||t.mainBkg,";\n stroke: ").concat(t.stateBorder||t.nodeBorder,";\n stroke-width: 1px;\n}\n.node polygon {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.stateBorder||t.nodeBorder,";;\n stroke-width: 1px;\n}\n#statediagram-barbEnd {\n fill: ").concat(t.lineColor,";\n}\n\n.statediagram-cluster rect {\n fill: ").concat(t.compositeTitleBackground,";\n stroke: ").concat(t.stateBorder||t.nodeBorder,";\n stroke-width: 1px;\n}\n\n.cluster-label, .nodeLabel {\n color: ").concat(t.stateLabelColor,";\n}\n\n.statediagram-cluster rect.outer {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state .divider {\n stroke: ").concat(t.stateBorder||t.nodeBorder,";\n}\n\n.statediagram-state .title-state {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-cluster.statediagram-cluster .inner {\n fill: ").concat(t.compositeBackground||t.background,";\n}\n.statediagram-cluster.statediagram-cluster-alt .inner {\n fill: ").concat(t.altBackground?t.altBackground:"#efefef",";\n}\n\n.statediagram-cluster .inner {\n rx:0;\n ry:0;\n}\n\n.statediagram-state rect.basic {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state rect.divider {\n stroke-dasharray: 10,10;\n fill: ").concat(t.altBackground?t.altBackground:"#efefef",";\n}\n\n.note-edge {\n stroke-dasharray: 5;\n}\n\n.statediagram-note rect {\n fill: ").concat(t.noteBkgColor,";\n stroke: ").concat(t.noteBorderColor,";\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n.statediagram-note rect {\n fill: ").concat(t.noteBkgColor,";\n stroke: ").concat(t.noteBorderColor,";\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n\n.statediagram-note text {\n fill: ").concat(t.noteTextColor,";\n}\n\n.statediagram-note .nodeLabel {\n color: ").concat(t.noteTextColor,";\n}\n.statediagram .edgeLabel {\n color: red; // ").concat(t.noteTextColor,";\n}\n\n#dependencyStart, #dependencyEnd {\n fill: ").concat(t.lineColor,";\n stroke: ").concat(t.lineColor,";\n stroke-width: 1;\n}\n")}},"./src/diagrams/user-journey/journeyDb.js":function(t,e,n){"use strict";n.r(e),n.d(e,"parseDirective",(function(){return h})),n.d(e,"clear",(function(){return d})),n.d(e,"setTitle",(function(){return p})),n.d(e,"getTitle",(function(){return g})),n.d(e,"addSection",(function(){return y})),n.d(e,"getSections",(function(){return m})),n.d(e,"getTasks",(function(){return v})),n.d(e,"addTask",(function(){return b})),n.d(e,"addTaskOrg",(function(){return _}));var r=n("./src/mermaidAPI.js"),i=n("./src/config.js");function a(t){return function(t){if(Array.isArray(t))return o(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||function(t,e){if(t){if("string"==typeof t)return o(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var s="",c="",u=[],l=[],f=[],h=function(t,e,n){r.default.parseDirective(this,t,e,n)},d=function(){u.length=0,l.length=0,c="",s="",f.length=0},p=function(t){s=t},g=function(){return s},y=function(t){c=t,u.push(t)},m=function(){return u},v=function(){for(var t=x(),e=0;!t&&e<100;)t=x(),e++;return l.push.apply(l,f),l},b=function(t,e){var n=e.substr(1).split(":"),r=0,i=[];1===n.length?(r=Number(n[0]),i=[]):(r=Number(n[0]),i=n[1].split(","));var a=i.map((function(t){return t.trim()})),o={section:c,type:c,people:a,task:t,score:r};f.push(o)},_=function(t){var e={section:c,type:c,description:t,task:t,classes:[]};l.push(e)},x=function(){for(var t=!0,e=0;e<f.length;e++)f[e].processed,t=t&&f[e].processed;return t};e.default={parseDirective:h,getConfig:function(){return i.getConfig().journey},clear:d,setTitle:p,getTitle:g,addSection:y,getSections:m,getTasks:v,addTask:b,addTaskOrg:_,getActors:function(){return t=[],l.forEach((function(e){e.people&&t.push.apply(t,a(e.people))})),a(new Set(t)).sort();var t}}},"./src/diagrams/user-journey/journeyRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return u})),n.d(e,"draw",(function(){return d})),n.d(e,"bounds",(function(){return p})),n.d(e,"drawTasks",(function(){return m}));var r=n("d3"),i=n("./src/diagrams/user-journey/parser/journey.jison"),a=n("./src/diagrams/user-journey/journeyDb.js"),o=n("./src/diagrams/user-journey/svgDraw.js"),s=n("./src/config.js"),c=n("./src/utils.js");i.parser.yy=a.default;var u=function(t){Object.keys(t).forEach((function(e){f[e]=t[e]}))},l={},f=Object(s.getConfig)().journey,h=Object(s.getConfig)().journey.leftMargin,d=function(t,e){var n=Object(s.getConfig)().journey;i.parser.yy.clear(),i.parser.parse(t+"\n"),p.init();var a=Object(r.select)("#"+e);a.attr("xmlns:xlink","http://www.w3.org/1999/xlink"),o.default.initGraphics(a);var u=i.parser.yy.getTasks(),f=i.parser.yy.getTitle(),d=i.parser.yy.getActors();for(var g in l)delete l[g];var y=0;d.forEach((function(t){l[t]={color:n.actorColours[y%n.actorColours.length],position:y},y++})),function(t){var e=Object(s.getConfig)().journey,n=60;Object.keys(l).forEach((function(r){var i=l[r].color,a={cx:20,cy:n,r:7,fill:i,stroke:"#000",pos:l[r].position};o.default.drawCircle(t,a);var s={x:40,y:n+7,fill:"#666",text:r,textMargin:5|e.boxTextMargin};o.default.drawText(t,s),n+=20}))}(a),p.insert(0,0,h,50*Object.keys(l).length),m(a,u,0);var v=p.getBounds();f&&a.append("text").text(f).attr("x",h).attr("font-size","4ex").attr("font-weight","bold").attr("y",25);var b=v.stopy-v.starty+2*n.diagramMarginY,_=h+v.stopx+2*n.diagramMarginX;Object(c.configureSvgSize)(a,b,_,n.useMaxWidth),a.append("line").attr("x1",h).attr("y1",4*n.height).attr("x2",_-h-4).attr("y2",4*n.height).attr("stroke-width",4).attr("stroke","black").attr("marker-end","url(#arrowhead)");var x=f?70:0;a.attr("viewBox","".concat(v.startx," -25 ").concat(_," ").concat(b+x)),a.attr("preserveAspectRatio","xMinYMin meet"),a.attr("height",b+x+25)},p={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],init:function(){this.sequenceItems=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0},updateVal:function(t,e,n,r){void 0===t[e]?t[e]=n:t[e]=r(n,t[e])},updateBounds:function(t,e,n,r){var i=Object(s.getConfig)().journey,a=this,o=0;this.sequenceItems.forEach((function(s){o++;var c=a.sequenceItems.length-o+1;a.updateVal(s,"starty",e-c*i.boxMargin,Math.min),a.updateVal(s,"stopy",r+c*i.boxMargin,Math.max),a.updateVal(p.data,"startx",t-c*i.boxMargin,Math.min),a.updateVal(p.data,"stopx",n+c*i.boxMargin,Math.max),a.updateVal(s,"startx",t-c*i.boxMargin,Math.min),a.updateVal(s,"stopx",n+c*i.boxMargin,Math.max),a.updateVal(p.data,"starty",e-c*i.boxMargin,Math.min),a.updateVal(p.data,"stopy",r+c*i.boxMargin,Math.max)}))},insert:function(t,e,n,r){var i=Math.min(t,n),a=Math.max(t,n),o=Math.min(e,r),s=Math.max(e,r);this.updateVal(p.data,"startx",i,Math.min),this.updateVal(p.data,"starty",o,Math.min),this.updateVal(p.data,"stopx",a,Math.max),this.updateVal(p.data,"stopy",s,Math.max),this.updateBounds(i,o,a,s)},bumpVerticalPos:function(t){this.verticalPos=this.verticalPos+t,this.data.stopy=this.verticalPos},getVerticalPos:function(){return this.verticalPos},getBounds:function(){return this.data}},g=f.sectionFills,y=f.sectionColours,m=function(t,e,n){for(var r=Object(s.getConfig)().journey,i="",a=n+(2*r.height+r.diagramMarginY),c=0,u="#CCC",f="black",d=0,m=0;m<e.length;m++){var v=e[m];if(i!==v.section){u=g[c%g.length],d=c%g.length,f=y[c%y.length];var b={x:m*r.taskMargin+m*r.width+h,y:50,text:v.section,fill:u,num:d,colour:f};o.default.drawSection(t,b,r),i=v.section,c++}var _=v.people.reduce((function(t,e){return l[e]&&(t[e]=l[e]),t}),{});v.x=m*r.taskMargin+m*r.width+h,v.y=a,v.width=r.diagramMarginX,v.height=r.diagramMarginY,v.colour=f,v.fill=u,v.num=d,v.actors=_,o.default.drawTask(t,v,r),p.insert(v.x,v.y,v.x+v.width+r.taskMargin,450)}};e.default={setConf:u,draw:d}},"./src/diagrams/user-journey/parser/journey.jison":function(t,e,n){(function(t,r){var i=function(){var t=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},e=[1,2],n=[1,5],r=[6,9,11,17,18,19,21],i=[1,15],a=[1,16],o=[1,17],s=[1,21],c=[4,6,9,11,17,18,19,21],u={trace:function(){},yy:{},symbols_:{error:2,start:3,journey:4,document:5,EOF:6,directive:7,line:8,SPACE:9,statement:10,NEWLINE:11,openDirective:12,typeDirective:13,closeDirective:14,":":15,argDirective:16,title:17,section:18,taskName:19,taskData:20,open_directive:21,type_directive:22,arg_directive:23,close_directive:24,$accept:0,$end:1},terminals_:{2:"error",4:"journey",6:"EOF",9:"SPACE",11:"NEWLINE",15:":",17:"title",18:"section",19:"taskName",20:"taskData",21:"open_directive",22:"type_directive",23:"arg_directive",24:"close_directive"},productions_:[0,[3,3],[3,2],[5,0],[5,2],[8,2],[8,1],[8,1],[8,1],[7,4],[7,6],[10,1],[10,1],[10,2],[10,1],[12,1],[13,1],[16,1],[14,1]],performAction:function(t,e,n,r,i,a,o){var s=a.length-1;switch(i){case 1:return a[s-1];case 3:case 7:case 8:this.$=[];break;case 4:a[s-1].push(a[s]),this.$=a[s-1];break;case 5:case 6:this.$=a[s];break;case 11:r.setTitle(a[s].substr(6)),this.$=a[s].substr(6);break;case 12:r.addSection(a[s].substr(8)),this.$=a[s].substr(8);break;case 13:r.addTask(a[s-1],a[s]),this.$="task";break;case 15:r.parseDirective("%%{","open_directive");break;case 16:r.parseDirective(a[s],"type_directive");break;case 17:a[s]=a[s].trim().replace(/'/g,'"'),r.parseDirective(a[s],"arg_directive");break;case 18:r.parseDirective("}%%","close_directive","journey")}},table:[{3:1,4:e,7:3,12:4,21:n},{1:[3]},t(r,[2,3],{5:6}),{3:7,4:e,7:3,12:4,21:n},{13:8,22:[1,9]},{22:[2,15]},{6:[1,10],7:18,8:11,9:[1,12],10:13,11:[1,14],12:4,17:i,18:a,19:o,21:n},{1:[2,2]},{14:19,15:[1,20],24:s},t([15,24],[2,16]),t(r,[2,8],{1:[2,1]}),t(r,[2,4]),{7:18,10:22,12:4,17:i,18:a,19:o,21:n},t(r,[2,6]),t(r,[2,7]),t(r,[2,11]),t(r,[2,12]),{20:[1,23]},t(r,[2,14]),{11:[1,24]},{16:25,23:[1,26]},{11:[2,18]},t(r,[2,5]),t(r,[2,13]),t(c,[2,9]),{14:27,24:s},{24:[2,17]},{11:[1,28]},t(c,[2,10])],defaultActions:{5:[2,15],7:[2,2],21:[2,18],26:[2,17]},parseError:function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},parse:function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,s="",c=0,u=0,l=0,f=2,h=1,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(g.yy[y]=this.yy[y]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=r.pop()||p.lex()||h)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;for(var _,x,w,k,T,E,C,S,M,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==_&&(_=b()),k=o[w]&&o[w][_]),void 0===k||!k.length||!k[0]){var O="";for(E in M=[],o[w])this.terminals_[E]&&E>f&&M.push("'"+this.terminals_[E]+"'");O=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+M.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(_==h?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(O,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:M})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+_);switch(k[0]){case 1:n.push(_),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),_=null,x?(_=x,x=null):(u=p.yyleng,s=p.yytext,c=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(C=this.productions_[k[1]][1],A.$=i[i.length-C],A._$={first_line:a[a.length-(C||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(C||1)].first_column,last_column:a[a.length-1].last_column},v&&(A._$.range=[a[a.length-(C||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[s,u,c,g.yy,k[1],i,a].concat(d))))return T;C&&(n=n.slice(0,-1*C*2),i=i.slice(0,-1*C),a=a.slice(0,-1*C)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}},l={EOF:1,parseError:function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},setInput:function(t,e){return this.yy=e||this.yy||{},this._input=t,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},input:function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},unput:function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},more:function(){return this._more=!0,this},reject:function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):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).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},less:function(t){this.unput(this.match.slice(t))},pastInput:function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},upcomingInput:function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},showPosition:function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},test_match:function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1},next:function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if((n=this._input.match(this.rules[i[a]]))&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},lex:function(){return this.next()||this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},_currentRules:function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},topState:function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},pushState:function(t){this.begin(t)},stateStackSize:function(){return this.conditionStack.length},options:{"case-insensitive":!0},performAction:function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),21;case 1:return this.begin("type_directive"),22;case 2:return this.popState(),this.begin("arg_directive"),15;case 3:return this.popState(),this.popState(),24;case 4:return 23;case 5:case 6:case 8:case 9:break;case 7:return 11;case 10:return 4;case 11:return 17;case 12:return 18;case 13:return 19;case 14:return 20;case 15:return 15;case 16:return 6;case 17:return"INVALID"}},rules:[/^(?:%%\{)/i,/^(?:((?:(?!\}%%)[^:.])*))/i,/^(?::)/i,/^(?:\}%%)/i,/^(?:((?:(?!\}%%).|\n)*))/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:journey\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{open_directive:{rules:[1],inclusive:!1},type_directive:{rules:[2,3],inclusive:!1},arg_directive:{rules:[3,4],inclusive:!1},INITIAL:{rules:[0,5,6,7,8,9,10,11,12,13,14,15,16,17],inclusive:!0}}};function f(){this.yy={}}return u.lexer=l,f.prototype=u,u.Parser=f,new f}();e.parser=i,e.Parser=i.Parser,e.parse=function(){return i.parse.apply(i,arguments)},e.main=function(r){r[1]||(console.log("Usage: "+r[0]+" FILE"),t.exit(1));var i=n("./node_modules/node-libs-browser/mock/empty.js").readFileSync(n("./node_modules/path-browserify/index.js").normalize(r[1]),"utf8");return e.parser.parse(i)},n.c[n.s]===r&&e.main(t.argv.slice(1))}).call(this,n("./node_modules/process/browser.js"),n("./node_modules/webpack/buildin/module.js")(t))},"./src/diagrams/user-journey/styles.js":function(t,e,n){"use strict";n.r(e),e.default=function(t){return".label {\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n color: ".concat(t.textColor,";\n }\n .mouth {\n stroke: #666;\n }\n\n line {\n stroke: ").concat(t.textColor,"\n }\n\n .legend {\n fill: ").concat(t.textColor,";\n }\n\n .label text {\n fill: #333;\n }\n .label {\n color: ").concat(t.textColor,"\n }\n\n .face {\n ").concat(t.faceColor?"fill: ".concat(t.faceColor):"fill: #FFF8DC",";\n stroke: #999;\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ").concat(t.mainBkg,";\n stroke: ").concat(t.nodeBorder,";\n stroke-width: 1px;\n }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ").concat(t.arrowheadColor,";\n }\n\n .edgePath .path {\n stroke: ").concat(t.lineColor,";\n stroke-width: 1.5px;\n }\n\n .flowchart-link {\n stroke: ").concat(t.lineColor,";\n fill: none;\n }\n\n .edgeLabel {\n background-color: ").concat(t.edgeLabelBackground,";\n rect {\n opacity: 0.5;\n }\n text-align: center;\n }\n\n .cluster rect {\n }\n\n .cluster text {\n fill: ").concat(t.titleColor,";\n }\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n font-size: 12px;\n background: ").concat(t.tertiaryColor,";\n border: 1px solid ").concat(t.border2,";\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .task-type-0, .section-type-0 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType0):"",";\n }\n .task-type-1, .section-type-1 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType1):"",";\n }\n .task-type-2, .section-type-2 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType2):"",";\n }\n .task-type-3, .section-type-3 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType3):"",";\n }\n .task-type-4, .section-type-4 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType4):"",";\n }\n .task-type-5, .section-type-5 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType5):"",";\n }\n .task-type-6, .section-type-6 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType6):"",";\n }\n .task-type-7, .section-type-7 {\n ").concat(t.fillType0?"fill: ".concat(t.fillType7):"",";\n }\n\n .actor-0 {\n ").concat(t.actor0?"fill: ".concat(t.actor0):"",";\n }\n .actor-1 {\n ").concat(t.actor1?"fill: ".concat(t.actor1):"",";\n }\n .actor-2 {\n ").concat(t.actor2?"fill: ".concat(t.actor2):"",";\n }\n .actor-3 {\n ").concat(t.actor3?"fill: ".concat(t.actor3):"",";\n }\n .actor-4 {\n ").concat(t.actor4?"fill: ".concat(t.actor4):"",";\n }\n .actor-5 {\n ").concat(t.actor5?"fill: ".concat(t.actor5):"",";\n }\n\n }\n")}},"./src/diagrams/user-journey/svgDraw.js":function(t,e,n){"use strict";n.r(e),n.d(e,"drawRect",(function(){return i})),n.d(e,"drawFace",(function(){return a})),n.d(e,"drawCircle",(function(){return o})),n.d(e,"drawText",(function(){return s})),n.d(e,"drawLabel",(function(){return c})),n.d(e,"drawSection",(function(){return u})),n.d(e,"drawTask",(function(){return f})),n.d(e,"drawBackgroundRect",(function(){return h})),n.d(e,"getTextObj",(function(){return d})),n.d(e,"getNoteRect",(function(){return p}));var r=n("d3"),i=function(t,e){var n=t.append("rect");return n.attr("x",e.x),n.attr("y",e.y),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("width",e.width),n.attr("height",e.height),n.attr("rx",e.rx),n.attr("ry",e.ry),void 0!==e.class&&n.attr("class",e.class),n},a=function(t,e){var n=t.append("circle").attr("cx",e.cx).attr("cy",e.cy).attr("class","face").attr("r",15).attr("stroke-width",2).attr("overflow","visible"),i=t.append("g");return i.append("circle").attr("cx",e.cx-5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),i.append("circle").attr("cx",e.cx+5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),e.score>3?function(t){var n=Object(r.arc)().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+2)+")")}(i):e.score<3?function(t){var n=Object(r.arc)().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+7)+")")}(i):function(t){t.append("line").attr("class","mouth").attr("stroke",2).attr("x1",e.cx-5).attr("y1",e.cy+7).attr("x2",e.cx+5).attr("y2",e.cy+7).attr("class","mouth").attr("stroke-width","1px").attr("stroke","#666")}(i),n},o=function(t,e){var n=t.append("circle");return n.attr("cx",e.cx),n.attr("cy",e.cy),n.attr("class","actor-"+e.pos),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("r",e.r),void 0!==n.class&&n.attr("class",n.class),void 0!==e.title&&n.append("title").text(e.title),n},s=function(t,e){var n=e.text.replace(/<br\s*\/?>/gi," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.attr("class","legend"),r.style("text-anchor",e.anchor),void 0!==e.class&&r.attr("class",e.class);var i=r.append("tspan");return i.attr("x",e.x+2*e.textMargin),i.text(n),r},c=function(t,e){var n,r,i=t.append("polygon");i.attr("points",(n=e.x)+","+(r=e.y)+" "+(n+50)+","+r+" "+(n+50)+","+(r+20-7)+" "+(n+50-8.4)+","+(r+20)+" "+n+","+(r+20)),i.attr("class","labelBox"),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,s(t,e)},u=function(t,e,n){var r=t.append("g"),a=p();a.x=e.x,a.y=e.y,a.fill=e.fill,a.width=n.width,a.height=n.height,a.class="journey-section section-type-"+e.num,a.rx=3,a.ry=3,i(r,a),g(n)(e.text,r,a.x,a.y,a.width,a.height,{class:"journey-section section-type-"+e.num},n,e.colour)},l=-1,f=function(t,e,n){var r=e.x+n.width/2,s=t.append("g");l++,s.append("line").attr("id","task"+l).attr("x1",r).attr("y1",e.y).attr("x2",r).attr("y2",450).attr("class","task-line").attr("stroke-width","1px").attr("stroke-dasharray","4 2").attr("stroke","#666"),a(s,{cx:r,cy:300+30*(5-e.score),score:e.score});var c=p();c.x=e.x,c.y=e.y,c.fill=e.fill,c.width=n.width,c.height=n.height,c.class="task task-type-"+e.num,c.rx=3,c.ry=3,i(s,c);var u=e.x+14;e.people.forEach((function(t){var n=e.actors[t].color,r={cx:u,cy:e.y,r:7,fill:n,stroke:"#000",title:t,pos:e.actors[t].position};o(s,r),u+=10})),g(n)(e.task,s,c.x,c.y,c.width,c.height,{class:"task"},n,e.colour)},h=function(t,e){i(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,class:"rect"}).lower()},d=function(){return{x:0,y:0,fill:void 0,"text-anchor":"start",width:100,height:100,textMargin:0,rx:0,ry:0}},p=function(){return{x:0,y:0,width:100,anchor:"start",height:100,rx:0,ry:0}},g=function(){function t(t,e,n,i,a,o,s,c){r(e.append("text").attr("x",n+a/2).attr("y",i+o/2+5).style("font-color",c).style("text-anchor","middle").text(t),s)}function e(t,e,n,i,a,o,s,c,u){for(var l=c.taskFontSize,f=c.taskFontFamily,h=t.split(/<br\s*\/?>/gi),d=0;d<h.length;d++){var p=d*l-l*(h.length-1)/2,g=e.append("text").attr("x",n+a/2).attr("y",i).attr("fill",u).style("text-anchor","middle").style("font-size",l).style("font-family",f);g.append("tspan").attr("x",n+a/2).attr("dy",p).text(h[d]),g.attr("y",i+o/2).attr("dominant-baseline","central").attr("alignment-baseline","central"),r(g,s)}}function n(t,n,i,a,o,s,c,u){var l=n.append("switch"),f=l.append("foreignObject").attr("x",i).attr("y",a).attr("width",o).attr("height",s).attr("position","fixed").append("xhtml:div").style("display","table").style("height","100%").style("width","100%");f.append("div").attr("class","label").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(t),e(t,l,i,a,o,s,c,u),r(f,c)}function r(t,e){for(var n in e)n in e&&t.attr(n,e[n])}return function(r){return"fo"===r.textPlacement?n:"old"===r.textPlacement?t:e}}();e.default={drawRect:i,drawCircle:o,drawSection:u,drawText:s,drawLabel:c,drawTask:f,drawBackgroundRect:h,getTextObj:d,getNoteRect:p,initGraphics:function(t){t.append("defs").append("marker").attr("id","arrowhead").attr("refX",5).attr("refY",2).attr("markerWidth",6).attr("markerHeight",4).attr("orient","auto").append("path").attr("d","M 0,0 V 4 L6,2 Z")}}},"./src/errorRenderer.js":function(t,e,n){"use strict";n.r(e),n.d(e,"setConf",(function(){return o})),n.d(e,"draw",(function(){return s}));var r=n("d3"),i=n("./src/logger.js"),a={},o=function(t){Object.keys(t).forEach((function(e){a[e]=t[e]}))},s=function(t,e){try{i.log.debug("Renering svg for syntax error\n");var n=Object(r.select)("#"+t),a=n.append("g");a.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),a.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),a.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),a.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),a.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),a.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),a.append("text").attr("class","error-text").attr("x",1240).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in graph"),a.append("text").attr("class","error-text").attr("x",1050).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text("mermaid version "+e),n.attr("height",100),n.attr("width",400),n.attr("viewBox","768 0 512 512")}catch(t){i.log.error("Error while rendering info diagram"),i.log.error(t.message)}};e.default={setConf:o,draw:s}},"./src/logger.js":function(t,e,n){"use strict";n.r(e),n.d(e,"LEVELS",(function(){return a})),n.d(e,"log",(function(){return o})),n.d(e,"setLogLevel",(function(){return s}));var r=n("moment-mini"),i=n.n(r),a={debug:1,info:2,warn:3,error:4,fatal:5},o={debug:function(){},info:function(){},warn:function(){},error:function(){},fatal:function(){}},s=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"fatal";isNaN(t)&&(t=t.toLowerCase(),void 0!==a[t]&&(t=a[t])),o.trace=function(){},o.debug=function(){},o.info=function(){},o.warn=function(){},o.error=function(){},o.fatal=function(){},t<=a.fatal&&(o.fatal=console.error?console.error.bind(console,c("FATAL"),"color: orange"):console.log.bind(console,"",c("FATAL"))),t<=a.error&&(o.error=console.error?console.error.bind(console,c("ERROR"),"color: orange"):console.log.bind(console,"",c("ERROR"))),t<=a.warn&&(o.warn=console.warn?console.warn.bind(console,c("WARN"),"color: orange"):console.log.bind(console,"",c("WARN"))),t<=a.info&&(o.info=console.info?console.info.bind(console,c("INFO"),"color: lightblue"):console.log.bind(console,"",c("INFO"))),t<=a.debug&&(o.debug=console.debug?console.debug.bind(console,c("DEBUG"),"color: lightgreen"):console.log.bind(console,"",c("DEBUG")))},c=function(t){var e=i()().format("ss.SSS");return"%c".concat(e," : ").concat(t," : ")}},"./src/mermaid.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/logger.js"),i=n("./src/mermaidAPI.js"),a=n("./src/utils.js"),o=function(){s.startOnLoad?i.default.getConfig().startOnLoad&&s.init():void 0===s.startOnLoad&&(r.log.debug("In start, no config"),i.default.getConfig().startOnLoad&&s.init())};"undefined"!=typeof document&&window.addEventListener("load",(function(){o()}),!1);var s={startOnLoad:!0,htmlLabels:!0,mermaidAPI:i.default,parse:i.default.parse,render:i.default.render,init:function(){var t,e,n=this,o=i.default.getConfig();arguments.length>=2?(void 0!==arguments[0]&&(s.sequenceConfig=arguments[0]),t=arguments[1]):t=arguments[0],"function"==typeof arguments[arguments.length-1]?(e=arguments[arguments.length-1],r.log.debug("Callback function found")):void 0!==o.mermaid&&("function"==typeof o.mermaid.callback?(e=o.mermaid.callback,r.log.debug("Callback function found")):r.log.debug("No Callback function found")),t=void 0===t?document.querySelectorAll(".mermaid"):"string"==typeof t?document.querySelectorAll(t):t instanceof window.Node?[t]:t,r.log.debug("Start On Load before: "+s.startOnLoad),void 0!==s.startOnLoad&&(r.log.debug("Start On Load inner: "+s.startOnLoad),i.default.updateSiteConfig({startOnLoad:s.startOnLoad})),void 0!==s.ganttConfig&&i.default.updateSiteConfig({gantt:s.ganttConfig});for(var c,u=new a.default.initIdGeneratior(o.deterministicIds,o.deterministicIDSeed),l=function(o){var s=t[o];if(s.getAttribute("data-processed"))return"continue";s.setAttribute("data-processed",!0);var l="mermaid-".concat(u.next());c=s.innerHTML,c=a.default.entityDecode(c).trim().replace(/<br\s*\/?>/gi,"<br/>");var f=a.default.detectInit(c);f&&r.log.debug("Detected early reinit: ",f);try{i.default.render(l,c,(function(t,n){s.innerHTML=t,void 0!==e&&e(l),n&&n(s)}),s)}catch(t){r.log.warn("Syntax Error rendering"),r.log.warn(t),n.parseError&&n.parseError(t)}},f=0;f<t.length;f++)l(f)},initialize:function(t){void 0!==t.mermaid&&(void 0!==t.mermaid.startOnLoad&&(s.startOnLoad=t.mermaid.startOnLoad),void 0!==t.mermaid.htmlLabels&&(s.htmlLabels="false"!==t.mermaid.htmlLabels&&!1!==t.mermaid.htmlLabels)),i.default.initialize(t)},contentLoaded:o};e.default=s},"./src/mermaidAPI.js":function(t,e,n){"use strict";n.r(e),n.d(e,"encodeEntities",(function(){return ot})),n.d(e,"decodeEntities",(function(){return st}));var r=n("d3"),i=n("stylis"),a=n("./package.json"),o=n("./src/config.js"),s=n("./src/diagrams/class/classDb.js"),c=n("./src/diagrams/class/classRenderer.js"),u=n("./src/diagrams/class/classRenderer-v2.js"),l=n("./src/diagrams/class/parser/classDiagram.jison"),f=n.n(l),h=n("./src/diagrams/er/erDb.js"),d=n("./src/diagrams/er/erRenderer.js"),p=n("./src/diagrams/er/parser/erDiagram.jison"),g=n.n(p),y=n("./src/diagrams/flowchart/flowDb.js"),m=n("./src/diagrams/flowchart/flowRenderer.js"),v=n("./src/diagrams/flowchart/flowRenderer-v2.js"),b=n("./src/diagrams/flowchart/parser/flow.jison"),_=n.n(b),x=n("./src/diagrams/gantt/ganttDb.js"),w=n("./src/diagrams/gantt/ganttRenderer.js"),k=n("./src/diagrams/gantt/parser/gantt.jison"),T=n.n(k),E=n("./src/diagrams/git/gitGraphAst.js"),C=n("./src/diagrams/git/gitGraphRenderer.js"),S=n("./src/diagrams/git/parser/gitGraph.jison"),M=n.n(S),A=n("./src/diagrams/info/infoDb.js"),O=n("./src/diagrams/info/infoRenderer.js"),N=n("./src/diagrams/info/parser/info.jison"),j=n.n(N),D=n("./src/diagrams/pie/parser/pie.jison"),B=n.n(D),L=n("./src/diagrams/pie/pieDb.js"),I=n("./src/diagrams/pie/pieRenderer.js"),R=n("./src/diagrams/requirement/parser/requirementDiagram.jison"),P=n.n(R),F=n("./src/diagrams/requirement/requirementDb.js"),z=n("./src/diagrams/requirement/requirementRenderer.js"),Y=n("./src/diagrams/sequence/parser/sequenceDiagram.jison"),q=n.n(Y),U=n("./src/diagrams/sequence/sequenceDb.js"),V=n("./src/diagrams/sequence/sequenceRenderer.js"),W=n("./src/diagrams/state/parser/stateDiagram.jison"),H=n.n(W),$=n("./src/diagrams/state/stateDb.js"),G=n("./src/diagrams/state/stateRenderer.js"),X=n("./src/diagrams/state/stateRenderer-v2.js"),Z=n("./src/diagrams/user-journey/journeyDb.js"),K=n("./src/diagrams/user-journey/journeyRenderer.js"),Q=n("./src/diagrams/user-journey/parser/journey.jison"),J=n.n(Q),tt=n("./src/errorRenderer.js"),et=n("./src/logger.js"),nt=n("./src/styles.js"),rt=n("./src/themes/index.js"),it=n("./src/utils.js");function at(t){return at="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},at(t)}var ot=function(t){var e=t;return(e=(e=e.replace(/style.*:\S*#.*;/g,(function(t){return t.substring(0,t.length-1)}))).replace(/classDef.*:\S*#.*;/g,(function(t){return t.substring(0,t.length-1)}))).replace(/#\w+;/g,(function(t){var e=t.substring(1,t.length-1);return/^\+?\d+$/.test(e)?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"}))},st=function(t){var e=t;return(e=(e=e.replace(/fl°°/g,(function(){return"&#"}))).replace(/fl°/g,(function(){return"&"}))).replace(/¶ß/g,(function(){return";"}))},ct={};function ut(t){C.default.setConf(t.git),m.default.setConf(t.flowchart),v.default.setConf(t.flowchart),void 0!==t.sequenceDiagram&&V.default.setConf(Object(it.assignWithDepth)(t.sequence,t.sequenceDiagram)),V.default.setConf(t.sequence),w.default.setConf(t.gantt),c.default.setConf(t.class),G.default.setConf(t.state),X.default.setConf(t.state),O.default.setConf(t.class),d.default.setConf(t.er),K.default.setConf(t.journey),z.default.setConf(t.requirement),tt.default.setConf(t.class)}var lt=Object.freeze({render:function(t,e,n,l){o.reset();var f=e,h=it.default.detectInit(f);h&&o.addDirective(h);var p=o.getConfig();if(e.length>p.maxTextSize&&(f="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa"),void 0!==l)l.innerHTML="",Object(r.select)(l).append("div").attr("id","d"+t).attr("style","font-family: "+p.fontFamily).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g");else{var g=document.getElementById(t);g&&g.remove();var b=document.querySelector("#d"+t);b&&b.remove(),Object(r.select)("body").append("div").attr("id","d"+t).append("svg").attr("id",t).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg").append("g")}window.txt=f,f=ot(f);var _=Object(r.select)("#d"+t).node(),k=it.default.detectType(f,p),T=_.firstChild,E=T.firstChild,S="";if(void 0!==p.themeCSS&&(S+="\n".concat(p.themeCSS)),void 0!==p.fontFamily&&(S+="\n:root { --mermaid-font-family: ".concat(p.fontFamily,"}")),void 0!==p.altFontFamily&&(S+="\n:root { --mermaid-alt-font-family: ".concat(p.altFontFamily,"}")),"flowchart"===k||"flowchart-v2"===k||"graph"===k){var M=m.default.getClasses(f),A=p.htmlLabels||p.flowchart.htmlLabels;for(var N in M)A?(S+="\n.".concat(N," > * { ").concat(M[N].styles.join(" !important; ")," !important; }"),S+="\n.".concat(N," span { ").concat(M[N].styles.join(" !important; ")," !important; }")):(S+="\n.".concat(N," path { ").concat(M[N].styles.join(" !important; ")," !important; }"),S+="\n.".concat(N," rect { ").concat(M[N].styles.join(" !important; ")," !important; }"),S+="\n.".concat(N," polygon { ").concat(M[N].styles.join(" !important; ")," !important; }"),S+="\n.".concat(N," ellipse { ").concat(M[N].styles.join(" !important; ")," !important; }"),S+="\n.".concat(N," circle { ").concat(M[N].styles.join(" !important; ")," !important; }"),M[N].textStyles&&(S+="\n.".concat(N," tspan { ").concat(M[N].textStyles.join(" !important; ")," !important; }")))}var j,D,B=(j="#".concat(t),D=Object(nt.default)(k,S,p.themeVariables),Object(i.serialize)(Object(i.compile)("".concat(j,"{").concat(D,"}")),i.stringify)),L=document.createElement("style");L.innerHTML="#".concat(t," ")+B,T.insertBefore(L,E);try{switch(k){case"git":p.flowchart.arrowMarkerAbsolute=p.arrowMarkerAbsolute,C.default.setConf(p.git),C.default.draw(f,t,!1);break;case"flowchart":p.flowchart.arrowMarkerAbsolute=p.arrowMarkerAbsolute,m.default.setConf(p.flowchart),m.default.draw(f,t,!1);break;case"flowchart-v2":p.flowchart.arrowMarkerAbsolute=p.arrowMarkerAbsolute,v.default.setConf(p.flowchart),v.default.draw(f,t,!1);break;case"sequence":p.sequence.arrowMarkerAbsolute=p.arrowMarkerAbsolute,p.sequenceDiagram?(V.default.setConf(Object.assign(p.sequence,p.sequenceDiagram)),console.error("`mermaid config.sequenceDiagram` has been renamed to `config.sequence`. Please update your mermaid config.")):V.default.setConf(p.sequence),V.default.draw(f,t);break;case"gantt":p.gantt.arrowMarkerAbsolute=p.arrowMarkerAbsolute,w.default.setConf(p.gantt),w.default.draw(f,t);break;case"class":p.class.arrowMarkerAbsolute=p.arrowMarkerAbsolute,c.default.setConf(p.class),c.default.draw(f,t);break;case"classDiagram":p.class.arrowMarkerAbsolute=p.arrowMarkerAbsolute,u.default.setConf(p.class),u.default.draw(f,t);break;case"state":p.class.arrowMarkerAbsolute=p.arrowMarkerAbsolute,G.default.setConf(p.state),G.default.draw(f,t);break;case"stateDiagram":p.class.arrowMarkerAbsolute=p.arrowMarkerAbsolute,X.default.setConf(p.state),X.default.draw(f,t);break;case"info":p.class.arrowMarkerAbsolute=p.arrowMarkerAbsolute,O.default.setConf(p.class),O.default.draw(f,t,a.version);break;case"pie":I.default.draw(f,t,a.version);break;case"er":d.default.setConf(p.er),d.default.draw(f,t,a.version);break;case"journey":K.default.setConf(p.journey),K.default.draw(f,t,a.version);break;case"requirement":z.default.setConf(p.requirement),z.default.draw(f,t,a.version)}}catch(e){throw tt.default.draw(t,a.version),e}Object(r.select)('[id="'.concat(t,'"]')).selectAll("foreignobject > *").attr("xmlns","http://www.w3.org/1999/xhtml");var R=Object(r.select)("#d"+t).node().innerHTML;if(et.log.debug("cnf.arrowMarkerAbsolute",p.arrowMarkerAbsolute),p.arrowMarkerAbsolute&&"false"!==p.arrowMarkerAbsolute||(R=R.replace(/marker-end="url\(.*?#/g,'marker-end="url(#',"g")),R=(R=st(R)).replace(/<br>/g,"<br/>"),void 0!==n)switch(k){case"flowchart":case"flowchart-v2":n(R,y.default.bindFunctions);break;case"gantt":n(R,x.default.bindFunctions);break;case"class":case"classDiagram":n(R,s.default.bindFunctions);break;default:n(R)}else et.log.debug("CB = undefined!");var P=Object(r.select)("#d"+t).node();return null!==P&&"function"==typeof P.remove&&Object(r.select)("#d"+t).node().remove(),R},parse:function(t){var e=o.getConfig(),n=it.default.detectInit(t,e);n&&et.log.debug("reinit ",n);var r,i=it.default.detectType(t,e);switch(et.log.debug("Type "+i),i){case"git":(r=M.a).parser.yy=E.default;break;case"flowchart":case"flowchart-v2":y.default.clear(),(r=_.a).parser.yy=y.default;break;case"sequence":(r=q.a).parser.yy=U.default;break;case"gantt":(r=T.a).parser.yy=x.default;break;case"class":case"classDiagram":(r=f.a).parser.yy=s.default;break;case"state":case"stateDiagram":(r=H.a).parser.yy=$.default;break;case"info":et.log.debug("info info info"),(r=j.a).parser.yy=A.default;break;case"pie":et.log.debug("pie"),(r=B.a).parser.yy=L.default;break;case"er":et.log.debug("er"),(r=g.a).parser.yy=h.default;break;case"journey":et.log.debug("Journey"),(r=J.a).parser.yy=Z.default;break;case"requirement":case"requirementDiagram":et.log.debug("RequirementDiagram"),(r=P.a).parser.yy=F.default}return r.parser.yy.graphType=i,r.parser.yy.parseError=function(t,e){throw{str:t,hash:e}},r.parse(t),r},parseDirective:function(t,e,n,r){try{if(void 0!==e)switch(e=e.trim(),n){case"open_directive":ct={};break;case"type_directive":ct.type=e.toLowerCase();break;case"arg_directive":ct.args=JSON.parse(e);break;case"close_directive":(function(t,e,n){switch(et.log.debug("Directive type=".concat(e.type," with args:"),e.args),e.type){case"init":case"initialize":["config"].forEach((function(t){void 0!==e.args[t]&&("flowchart-v2"===n&&(n="flowchart"),e.args[n]=e.args[t],delete e.args[t])})),et.log.debug("sanitize in handleDirective",e.args),Object(it.directiveSanitizer)(e.args),et.log.debug("sanitize in handleDirective (done)",e.args),e.args,o.addDirective(e.args);break;case"wrap":case"nowrap":t&&t.setWrap&&t.setWrap("wrap"===e.type);break;default:et.log.warn("Unhandled directive: source: '%%{".concat(e.type,": ").concat(JSON.stringify(e.args?e.args:{}),"}%%"),e)}})(t,ct,r),ct=null}}catch(t){et.log.error("Error while rendering sequenceDiagram directive: ".concat(e," jison context: ").concat(n)),et.log.error(t.message)}},initialize:function(t){t&&t.fontFamily&&(t.themeVariables&&t.themeVariables.fontFamily||(t.themeVariables={fontFamily:t.fontFamily})),o.saveConfigFromInitilize(t),t&&t.theme&&rt.default[t.theme]?t.themeVariables=rt.default[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=rt.default.default.getThemeVariables(t.themeVariables));var e="object"===at(t)?o.setSiteConfig(t):o.getSiteConfig();ut(e),Object(et.setLogLevel)(e.logLevel)},reinitialize:function(){},getConfig:o.getConfig,setConfig:o.setConfig,getSiteConfig:o.getSiteConfig,updateSiteConfig:o.updateSiteConfig,reset:function(){o.reset()},globalReset:function(){o.reset(o.defaultConfig),ut(o.getConfig())},defaultConfig:o.defaultConfig});Object(et.setLogLevel)(o.getConfig().logLevel),o.reset(o.getConfig()),e.default=lt},"./src/styles.js":function(t,e,n){"use strict";n.r(e),n.d(e,"calcThemeVariables",(function(){return g}));var r=n("./src/diagrams/class/styles.js"),i=n("./src/diagrams/er/styles.js"),a=n("./src/diagrams/flowchart/styles.js"),o=n("./src/diagrams/gantt/styles.js"),s=n("./src/diagrams/git/styles.js"),c=n("./src/diagrams/info/styles.js"),u=n("./src/diagrams/pie/styles.js"),l=n("./src/diagrams/requirement/styles.js"),f=n("./src/diagrams/sequence/styles.js"),h=n("./src/diagrams/state/styles.js"),d=n("./src/diagrams/user-journey/styles.js"),p={flowchart:a.default,"flowchart-v2":a.default,sequence:f.default,gantt:o.default,classDiagram:r.default,"classDiagram-v2":r.default,class:r.default,stateDiagram:h.default,state:h.default,git:s.default,info:c.default,pie:u.default,er:i.default,journey:d.default,requirement:l.default},g=function(t,e){return t.calcColors(e)};e.default=function(t,e,n){return" {\n font-family: ".concat(n.fontFamily,";\n font-size: ").concat(n.fontSize,";\n fill: ").concat(n.textColor,"\n }\n\n /* Classes common for multiple diagrams */\n\n .error-icon {\n fill: ").concat(n.errorBkgColor,";\n }\n .error-text {\n fill: ").concat(n.errorTextColor,";\n stroke: ").concat(n.errorTextColor,";\n }\n\n .edge-thickness-normal {\n stroke-width: 2px;\n }\n .edge-thickness-thick {\n stroke-width: 3.5px\n }\n .edge-pattern-solid {\n stroke-dasharray: 0;\n }\n\n .edge-pattern-dashed{\n stroke-dasharray: 3;\n }\n .edge-pattern-dotted {\n stroke-dasharray: 2;\n }\n\n .marker {\n fill: ").concat(n.lineColor,";\n stroke: ").concat(n.lineColor,";\n }\n .marker.cross {\n stroke: ").concat(n.lineColor,";\n }\n\n svg {\n font-family: ").concat(n.fontFamily,";\n font-size: ").concat(n.fontSize,";\n }\n\n ").concat(p[t](n),"\n\n ").concat(e,"\n")}},"./src/themes/index.js":function(t,e,n){"use strict";n.r(e);var r=n("./src/themes/theme-base.js"),i=n("./src/themes/theme-dark.js"),a=n("./src/themes/theme-default.js"),o=n("./src/themes/theme-forest.js"),s=n("./src/themes/theme-neutral.js");e.default={base:{getThemeVariables:r.getThemeVariables},dark:{getThemeVariables:i.getThemeVariables},default:{getThemeVariables:a.getThemeVariables},forest:{getThemeVariables:o.getThemeVariables},neutral:{getThemeVariables:s.getThemeVariables}}},"./src/themes/theme-base.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getThemeVariables",(function(){return c}));var r=n("khroma"),i=n("./src/themes/theme-helpers.js");function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function o(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var s=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.background="#f4f4f4",this.darkMode=!1,this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}var e,n;return e=t,(n=[{key:"updateColors",value:function(){this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#ddd":"#333"),this.secondaryColor=this.secondaryColor||Object(r.adjust)(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||Object(r.adjust)(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Object(i.mkBorder)(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Object(i.mkBorder)(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Object(i.mkBorder)(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Object(i.mkBorder)(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||Object(r.invert)(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||Object(r.invert)(this.tertiaryColor),this.lineColor=this.lineColor||Object(r.invert)(this.background),this.textColor=this.textColor||this.primaryTextColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?Object(r.darken)(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||"grey",this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||Object(r.darken)(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||Object(r.invert)(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||Object(r.lighten)(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||Object(r.adjust)(this.primaryColor,{h:64}),this.fillType3=this.fillType3||Object(r.adjust)(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||Object(r.adjust)(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||Object(r.adjust)(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||Object(r.adjust)(this.primaryColor,{h:128}),this.fillType7=this.fillType7||Object(r.adjust)(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||Object(r.adjust)(this.primaryColor,{l:-10}),this.pie5=this.pie5||Object(r.adjust)(this.secondaryColor,{l:-10}),this.pie6=this.pie6||Object(r.adjust)(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||Object(r.adjust)(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||Object(r.adjust)(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||Object(r.adjust)(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||Object(r.adjust)(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||Object(r.adjust)(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||Object(r.adjust)(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOpacity=this.pieOpacity||"0.7",this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||this.primaryBorderColor,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?Object(r.darken)(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor}},{key:"calculate",value:function(t){var e=this;if("object"===a(t)){var n=Object.keys(t);n.forEach((function(n){e[n]=t[n]})),this.updateColors(),n.forEach((function(n){e[n]=t[n]}))}else this.updateColors()}}])&&o(e.prototype,n),t}(),c=function(t){var e=new s;return e.calculate(t),e}},"./src/themes/theme-dark.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getThemeVariables",(function(){return c}));var r=n("khroma"),i=n("./src/themes/theme-helpers.js");function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function o(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var s=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=Object(r.lighten)(this.primaryColor,16),this.tertiaryColor=Object(r.adjust)(this.primaryColor,{h:-160}),this.primaryBorderColor=Object(i.mkBorder)(this.primaryColor,this.darkMode),this.secondaryBorderColor=Object(i.mkBorder)(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Object(i.mkBorder)(this.tertiaryColor,this.darkMode),this.primaryTextColor=Object(r.invert)(this.primaryColor),this.secondaryTextColor=Object(r.invert)(this.secondaryColor),this.tertiaryTextColor=Object(r.invert)(this.tertiaryColor),this.lineColor=Object(r.invert)(this.background),this.textColor=Object(r.invert)(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=Object(r.lighten)(Object(r.invert)("#323D47"),10),this.lineColor="calculated",this.border1="#81B1DB",this.border2=Object(r.rgba)(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=Object(r.darken)("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.taskBorderColor=Object(r.rgba)(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Object(r.rgba)(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}var e,n;return e=t,(n=[{key:"updateColors",value:function(){this.secondBkg=Object(r.lighten)(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=Object(r.lighten)(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.mainContrastColor,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=Object(r.lighten)(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Object(r.adjust)(this.primaryColor,{h:64}),this.fillType3=Object(r.adjust)(this.secondaryColor,{h:64}),this.fillType4=Object(r.adjust)(this.primaryColor,{h:-64}),this.fillType5=Object(r.adjust)(this.secondaryColor,{h:-64}),this.fillType6=Object(r.adjust)(this.primaryColor,{h:128}),this.fillType7=Object(r.adjust)(this.secondaryColor,{h:128}),this.pie1=this.pie1||"#0b0000",this.pie2=this.pie2||"#4d1037",this.pie3=this.pie3||"#3f5258",this.pie4=this.pie4||"#4f2f1b",this.pie5=this.pie5||"#6e0a0a",this.pie6=this.pie6||"#3b0048",this.pie7=this.pie7||"#995a01",this.pie8=this.pie8||"#154706",this.pie9=this.pie9||"#161722",this.pie10=this.pie10||"#00296f",this.pie11=this.pie11||"#01629c",this.pie12=this.pie12||"#010029",this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOpacity=this.pieOpacity||"0.7",this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||this.primaryBorderColor,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?Object(r.darken)(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor}},{key:"calculate",value:function(t){var e=this;if("object"===a(t)){var n=Object.keys(t);n.forEach((function(n){e[n]=t[n]})),this.updateColors(),n.forEach((function(n){e[n]=t[n]}))}else this.updateColors()}}])&&o(e.prototype,n),t}(),c=function(t){var e=new s;return e.calculate(t),e}},"./src/themes/theme-default.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getThemeVariables",(function(){return c}));var r=n("khroma"),i=n("./src/themes/theme-helpers.js");function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function o(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var s=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=Object(r.adjust)(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=Object(r.adjust)(this.primaryColor,{h:-160}),this.primaryBorderColor=Object(i.mkBorder)(this.primaryColor,this.darkMode),this.secondaryBorderColor=Object(i.mkBorder)(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Object(i.mkBorder)(this.tertiaryColor,this.darkMode),this.primaryTextColor=Object(r.invert)(this.primaryColor),this.secondaryTextColor=Object(r.invert)(this.secondaryColor),this.tertiaryTextColor=Object(r.invert)(this.tertiaryColor),this.lineColor=Object(r.invert)(this.background),this.textColor=Object(r.invert)(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#e8e8e8",this.textColor="#333",this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.sectionBkgColor=Object(r.rgba)(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}var e,n;return e=t,(n=[{key:"updateColors",value:function(){this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=Object(r.lighten)(this.border1,23),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Object(r.adjust)(this.primaryColor,{h:64}),this.fillType3=Object(r.adjust)(this.secondaryColor,{h:64}),this.fillType4=Object(r.adjust)(this.primaryColor,{h:-64}),this.fillType5=Object(r.adjust)(this.secondaryColor,{h:-64}),this.fillType6=Object(r.adjust)(this.primaryColor,{h:128}),this.fillType7=Object(r.adjust)(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||Object(r.adjust)(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||Object(r.adjust)(this.primaryColor,{l:-10}),this.pie5=this.pie5||Object(r.adjust)(this.secondaryColor,{l:-30}),this.pie6=this.pie6||Object(r.adjust)(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||Object(r.adjust)(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||Object(r.adjust)(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||Object(r.adjust)(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||Object(r.adjust)(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||Object(r.adjust)(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||Object(r.adjust)(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOpacity=this.pieOpacity||"0.7",this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||this.primaryBorderColor,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor}},{key:"calculate",value:function(t){var e=this;if("object"===a(t)){var n=Object.keys(t);n.forEach((function(n){e[n]=t[n]})),this.updateColors(),n.forEach((function(n){e[n]=t[n]}))}else this.updateColors()}}])&&o(e.prototype,n),t}(),c=function(t){var e=new s;return e.calculate(t),e}},"./src/themes/theme-forest.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getThemeVariables",(function(){return c}));var r=n("khroma"),i=n("./src/themes/theme-helpers.js");function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function o(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var s=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=Object(r.lighten)("#cde498",10),this.primaryBorderColor=Object(i.mkBorder)(this.primaryColor,this.darkMode),this.secondaryBorderColor=Object(i.mkBorder)(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Object(i.mkBorder)(this.tertiaryColor,this.darkMode),this.primaryTextColor=Object(r.invert)(this.primaryColor),this.secondaryTextColor=Object(r.invert)(this.secondaryColor),this.tertiaryTextColor=Object(r.invert)(this.primaryColor),this.lineColor=Object(r.invert)(this.background),this.textColor=Object(r.invert)(this.background),this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}var e,n;return e=t,(n=[{key:"updateColors",value:function(){this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.actorBorder=Object(r.darken)(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Object(r.adjust)(this.primaryColor,{h:64}),this.fillType3=Object(r.adjust)(this.secondaryColor,{h:64}),this.fillType4=Object(r.adjust)(this.primaryColor,{h:-64}),this.fillType5=Object(r.adjust)(this.secondaryColor,{h:-64}),this.fillType6=Object(r.adjust)(this.primaryColor,{h:128}),this.fillType7=Object(r.adjust)(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||Object(r.adjust)(this.primaryColor,{l:-30}),this.pie5=this.pie5||Object(r.adjust)(this.secondaryColor,{l:-30}),this.pie6=this.pie6||Object(r.adjust)(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||Object(r.adjust)(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||Object(r.adjust)(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||Object(r.adjust)(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||Object(r.adjust)(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||Object(r.adjust)(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||Object(r.adjust)(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOpacity=this.pieOpacity||"0.7",this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||this.primaryBorderColor,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor}},{key:"calculate",value:function(t){var e=this;if("object"===a(t)){var n=Object.keys(t);n.forEach((function(n){e[n]=t[n]})),this.updateColors(),n.forEach((function(n){e[n]=t[n]}))}else this.updateColors()}}])&&o(e.prototype,n),t}(),c=function(t){var e=new s;return e.calculate(t),e}},"./src/themes/theme-helpers.js":function(t,e,n){"use strict";n.r(e),n.d(e,"mkBorder",(function(){return i}));var r=n("khroma"),i=function(t,e){return e?Object(r.adjust)(t,{s:-40,l:10}):Object(r.adjust)(t,{s:-40,l:-10})}},"./src/themes/theme-neutral.js":function(t,e,n){"use strict";n.r(e),n.d(e,"getThemeVariables",(function(){return c}));var r=n("khroma"),i=n("./src/themes/theme-helpers.js");function a(t){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(t)}function o(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}var s=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=Object(r.lighten)(this.contrast,55),this.background="#ffffff",this.tertiaryColor=Object(r.adjust)(this.primaryColor,{h:-160}),this.primaryBorderColor=Object(i.mkBorder)(this.primaryColor,this.darkMode),this.secondaryBorderColor=Object(i.mkBorder)(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Object(i.mkBorder)(this.tertiaryColor,this.darkMode),this.primaryTextColor=Object(r.invert)(this.primaryColor),this.secondaryTextColor=Object(r.invert)(this.secondaryColor),this.tertiaryTextColor=Object(r.invert)(this.tertiaryColor),this.lineColor=Object(r.invert)(this.background),this.textColor=Object(r.invert)(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}var e,n;return e=t,(n=[{key:"updateColors",value:function(){this.secondBkg=Object(r.lighten)(this.contrast,55),this.border2=this.contrast,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.actorBorder=Object(r.lighten)(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.lineColor,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.sectionBkgColor=Object(r.lighten)(this.contrast,30),this.sectionBkgColor2=Object(r.lighten)(this.contrast,30),this.taskBorderColor=Object(r.darken)(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=Object(r.lighten)(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=Object(r.darken)(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.transitionColor=this.transitionColor||"#000",this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Object(r.adjust)(this.primaryColor,{h:64}),this.fillType3=Object(r.adjust)(this.secondaryColor,{h:64}),this.fillType4=Object(r.adjust)(this.primaryColor,{h:-64}),this.fillType5=Object(r.adjust)(this.secondaryColor,{h:-64}),this.fillType6=Object(r.adjust)(this.primaryColor,{h:128}),this.fillType7=Object(r.adjust)(this.secondaryColor,{h:128}),this.pie1=this.pie1||"#F4F4F4",this.pie2=this.pie2||"#555",this.pie3=this.pie3||"#BBB",this.pie4=this.pie4||"#777",this.pie5=this.pie5||"#999",this.pie6=this.pie6||"#DDD",this.pie7=this.pie7||"#FFF",this.pie8=this.pie8||"#DDD",this.pie9=this.pie9||"#BBB",this.pie10=this.pie10||"#999",this.pie11=this.pie11||"#777",this.pie12=this.pie12||"#555",this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOpacity=this.pieOpacity||"0.7",this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||this.primaryBorderColor,this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor}},{key:"calculate",value:function(t){var e=this;if("object"===a(t)){var n=Object.keys(t);n.forEach((function(n){e[n]=t[n]})),this.updateColors(),n.forEach((function(n){e[n]=t[n]}))}else this.updateColors()}}])&&o(e.prototype,n),t}(),c=function(t){var e=new s;return e.calculate(t),e}},"./src/utils.js":function(t,e,n){"use strict";n.r(e),n.d(e,"detectInit",(function(){return _})),n.d(e,"detectDirective",(function(){return x})),n.d(e,"detectType",(function(){return w})),n.d(e,"isSubstringInArray",(function(){return T})),n.d(e,"interpolateToCurve",(function(){return E})),n.d(e,"formatUrl",(function(){return C})),n.d(e,"runFunc",(function(){return S})),n.d(e,"getStylesFromArray",(function(){return A})),n.d(e,"generateId",(function(){return N})),n.d(e,"random",(function(){return j})),n.d(e,"assignWithDepth",(function(){return D})),n.d(e,"getTextObj",(function(){return B})),n.d(e,"drawSimpleText",(function(){return L})),n.d(e,"wrapLabel",(function(){return I})),n.d(e,"calculateTextHeight",(function(){return P})),n.d(e,"calculateTextWidth",(function(){return F})),n.d(e,"calculateTextDimensions",(function(){return z})),n.d(e,"calculateSvgSizeAttrs",(function(){return Y})),n.d(e,"configureSvgSize",(function(){return q})),n.d(e,"initIdGeneratior",(function(){return U})),n.d(e,"entityDecode",(function(){return V})),n.d(e,"directiveSanitizer",(function(){return W}));var r=n("@braintree/sanitize-url"),i=n("d3"),a=n("./src/diagrams/common/common.js"),o=n("./src/defaultConfig.js"),s=n("./src/logger.js"),c=void 0;function u(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function l(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=d(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function f(t){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},f(t)}function h(t){return function(t){if(Array.isArray(t))return p(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||d(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(t,e){if(t){if("string"==typeof t)return p(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(t,e):void 0}}function p(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var g,y={curveBasis:i.curveBasis,curveBasisClosed:i.curveBasisClosed,curveBasisOpen:i.curveBasisOpen,curveLinear:i.curveLinear,curveLinearClosed:i.curveLinearClosed,curveMonotoneX:i.curveMonotoneX,curveMonotoneY:i.curveMonotoneY,curveNatural:i.curveNatural,curveStep:i.curveStep,curveStepAfter:i.curveStepAfter,curveStepBefore:i.curveStepBefore},m=/[%]{2}[{]\s*(?:(?:(\w+)\s*:|(\w+))\s*(?:(?:(\w+))|((?:(?![}][%]{2}).|\r?\n)*))?\s*)(?:[}][%]{2})?/gi,v=/\s*(?:(?:(\w+)(?=:):|(\w+))\s*(?:(?:(\w+))|((?:(?![}][%]{2}).|\r?\n)*))?\s*)(?:[}][%]{2})?/gi,b=/\s*%%.*\n/gm,_=function(t,e){var n=x(t,/(?:init\b)|(?:initialize\b)/),r={};if(Array.isArray(n)){var i=n.map((function(t){return t.args}));W(i),r=D(r,h(i))}else r=n.args;if(r){var a=w(t,e);["config"].forEach((function(t){void 0!==r[t]&&("flowchart-v2"===a&&(a="flowchart"),r[a]=r[t],delete r[t])}))}return r},x=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;try{var n=new RegExp("[%]{2}(?![{]".concat(v.source,")(?=[}][%]{2}).*\n"),"ig");t=t.trim().replace(n,"").replace(/'/gm,'"'),s.log.debug("Detecting diagram directive".concat(null!==e?" type:"+e:""," based on the text:").concat(t));for(var r,i=[];null!==(r=m.exec(t));)if(r.index===m.lastIndex&&m.lastIndex++,r&&!e||e&&r[1]&&r[1].match(e)||e&&r[2]&&r[2].match(e)){var a=r[1]?r[1]:r[2],o=r[3]?r[3].trim():r[4]?JSON.parse(r[4].trim()):null;i.push({type:a,args:o})}return 0===i.length&&i.push({type:t,args:null}),1===i.length?i[0]:i}catch(n){return s.log.error("ERROR: ".concat(n.message," - Unable to parse directive\n ").concat(null!==e?" type:"+e:""," based on the text:").concat(t)),{type:null,args:null}}},w=function(t,e){return(t=t.replace(m,"").replace(b,"\n")).match(/^\s*sequenceDiagram/)?"sequence":t.match(/^\s*gantt/)?"gantt":t.match(/^\s*classDiagram-v2/)?"classDiagram":t.match(/^\s*classDiagram/)?e&&e.class&&"dagre-wrapper"===e.class.defaultRenderer?"classDiagram":"class":t.match(/^\s*stateDiagram-v2/)?"stateDiagram":t.match(/^\s*stateDiagram/)?e&&e.class&&"dagre-wrapper"===e.state.defaultRenderer?"stateDiagram":"state":t.match(/^\s*gitGraph/)?"git":t.match(/^\s*flowchart/)?"flowchart-v2":t.match(/^\s*info/)?"info":t.match(/^\s*pie/)?"pie":t.match(/^\s*erDiagram/)?"er":t.match(/^\s*journey/)?"journey":t.match(/^\s*requirement/)||t.match(/^\s*requirementDiagram/)?"requirement":e&&e.flowchart&&"dagre-wrapper"===e.flowchart.defaultRenderer?"flowchart-v2":"flowchart"},k=function(t,e){var n={};return function(){for(var r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];var o=e?e.apply(c,i):i[0];if(o in n)return n[o];var s=t.apply(void 0,i);return n[o]=s,s}},T=function(t,e){for(var n=0;n<e.length;n++)if(e[n].match(t))return n;return-1},E=function(t,e){if(!t)return e;var n="curve".concat(t.charAt(0).toUpperCase()+t.slice(1));return y[n]||e},C=function(t,e){var n=t.trim();if(n)return"loose"!==e.securityLevel?Object(r.sanitizeUrl)(n):n},S=function(t){for(var e,n=t.split("."),r=n.length-1,i=n[r],a=window,o=0;o<r;o++)if(!(a=a[n[o]]))return;for(var s=arguments.length,c=new Array(s>1?s-1:0),u=1;u<s;u++)c[u-1]=arguments[u];(e=a)[i].apply(e,c)},M=function(t,e){return t&&e?Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2)):0},A=function(t){for(var e="",n="",r=0;r<t.length;r++)void 0!==t[r]&&(t[r].startsWith("color:")||t[r].startsWith("text-align:")?n=n+t[r]+";":e=e+t[r]+";");return{style:e,labelStyle:n}},O=0,N=function(){return O++,"id-"+Math.random().toString(36).substr(2,12)+"-"+O},j=function(t){return function(t){for(var e="",n="0123456789abcdef",r=n.length,i=0;i<t;i++)e+=n.charAt(Math.floor(Math.random()*r));return e}(t.length)},D=function t(e,n,r){var i=Object.assign({depth:2,clobber:!1},r),a=i.depth,o=i.clobber;return Array.isArray(n)&&!Array.isArray(e)?(n.forEach((function(n){return t(e,n,r)})),e):Array.isArray(n)&&Array.isArray(e)?(n.forEach((function(t){-1===e.indexOf(t)&&e.push(t)})),e):void 0===e||a<=0?null!=e&&"object"===f(e)&&"object"===f(n)?Object.assign(e,n):n:(void 0!==n&&"object"===f(e)&&"object"===f(n)&&Object.keys(n).forEach((function(r){"object"!==f(n[r])||void 0!==e[r]&&"object"!==f(e[r])?(o||"object"!==f(e[r])&&"object"!==f(n[r]))&&(e[r]=n[r]):(void 0===e[r]&&(e[r]=Array.isArray(n[r])?[]:{}),e[r]=t(e[r],n[r],{depth:a-1,clobber:o}))})),e)},B=function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0}},L=function(t,e){var n=e.text.replace(a.default.lineBreakRegex," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.style("text-anchor",e.anchor),r.style("font-family",e.fontFamily),r.style("font-size",e.fontSize),r.style("font-weight",e.fontWeight),r.attr("fill",e.fill),void 0!==e.class&&r.attr("class",e.class);var i=r.append("tspan");return i.attr("x",e.x+2*e.textMargin),i.attr("fill",e.fill),i.text(n),r},I=k((function(t,e,n){if(!t)return t;if(n=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},n),a.default.lineBreakRegex.test(t))return t;var r=t.split(" "),i=[],o="";return r.forEach((function(t,a){var s=F("".concat(t," "),n),c=F(o,n);if(s>e){var u=R(t,e,"-",n),l=u.hyphenatedStrings,f=u.remainingWord;i.push.apply(i,[o].concat(h(l))),o=f}else c+s>=e?(i.push(o),o=t):o=[o,t].filter(Boolean).join(" ");a+1===r.length&&i.push(o)})),i.filter((function(t){return""!==t})).join(n.joinWith)}),(function(t,e,n){return"".concat(t,"-").concat(e,"-").concat(n.fontSize,"-").concat(n.fontWeight,"-").concat(n.fontFamily,"-").concat(n.joinWith)})),R=k((function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"-",r=arguments.length>3?arguments[3]:void 0;r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},r);var i=t.split(""),a=[],o="";return i.forEach((function(t,s){var c="".concat(o).concat(t);if(F(c,r)>=e){var u=s+1,l=i.length===u,f="".concat(c).concat(n);a.push(l?c:f),o=""}else o=c})),{hyphenatedStrings:a,remainingWord:o}}),(function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"-",r=arguments.length>3?arguments[3]:void 0;return"".concat(t,"-").concat(e,"-").concat(n,"-").concat(r.fontSize,"-").concat(r.fontWeight,"-").concat(r.fontFamily)})),P=function(t,e){return e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:15},e),z(t,e).height},F=function(t,e){return e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial"},e),z(t,e).width},z=k((function(t,e){var n=e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial"},e),r=n.fontSize,o=n.fontFamily,s=n.fontWeight;if(!t)return{width:0,height:0};var c=["sans-serif",o],u=t.split(a.default.lineBreakRegex),f=[],h=Object(i.select)("body");if(!h.remove)return{width:0,height:0,lineHeight:0};for(var d=h.append("svg"),p=0,g=c;p<g.length;p++){var y,m=g[p],v=0,b={width:0,height:0,lineHeight:0},_=l(u);try{for(_.s();!(y=_.n()).done;){var x=y.value,w=B();w.text=x;var k=L(d,w).style("font-size",r).style("font-weight",s).style("font-family",m),T=(k._groups||k)[0][0].getBBox();b.width=Math.round(Math.max(b.width,T.width)),v=Math.round(T.height),b.height+=v,b.lineHeight=Math.round(Math.max(b.lineHeight,v))}}catch(t){_.e(t)}finally{_.f()}f.push(b)}return d.remove(),f[isNaN(f[1].height)||isNaN(f[1].width)||isNaN(f[1].lineHeight)||f[0].height>f[1].height&&f[0].width>f[1].width&&f[0].lineHeight>f[1].lineHeight?0:1]}),(function(t,e){return"".concat(t,"-").concat(e.fontSize,"-").concat(e.fontWeight,"-").concat(e.fontFamily)})),Y=function(t,e,n){var r=new Map;return r.set("height",t),n?(r.set("width","100%"),r.set("style","max-width: ".concat(e,"px;"))):r.set("width",e),r},q=function(t,e,n,r){!function(t,e){var n,r=l(e);try{for(r.s();!(n=r.n()).done;){var i=n.value;t.attr(i[0],i[1])}}catch(t){r.e(t)}finally{r.f()}}(t,Y(e,n,r))},U=function(){function t(e,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.deterministic=e,this.seed=n,this.count=n?n.length:0}var e,n;return e=t,(n=[{key:"next",value:function(){return this.deterministic?this.count++:Date.now()}}])&&u(e.prototype,n),t}(),V=function(t){return g=g||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),g.innerHTML=t,unescape(g.textContent)},W=function t(e){s.log.debug("directiveSanitizer called with",e),"object"===f(e)&&(e.length?e.forEach((function(e){return t(e)})):Object.keys(e).forEach((function(n){s.log.debug("Checking key",n),0===n.indexOf("__")&&(s.log.debug("sanitize deleting __ option",n),delete e[n]),n.indexOf("proto")>=0&&(s.log.debug("sanitize deleting proto option",n),delete e[n]),n.indexOf("constr")>=0&&(s.log.debug("sanitize deleting constr option",n),delete e[n]),o.configKeys.indexOf(n)<0?(s.log.debug("sanitize deleting option",n),delete e[n]):"object"===f(e[n])&&(s.log.debug("sanitize deleting object",n),t(e[n]))})))};e.default={assignWithDepth:D,wrapLabel:I,calculateTextHeight:P,calculateTextWidth:F,calculateTextDimensions:z,calculateSvgSizeAttrs:Y,configureSvgSize:q,detectInit:_,detectDirective:x,detectType:w,isSubstringInArray:T,interpolateToCurve:E,calcLabelPosition:function(t){return function(t){var e,n=0;t.forEach((function(t){n+=M(t,e),e=t}));var r=n/2,i=void 0;return e=void 0,t.forEach((function(t){if(e&&!i){var n=M(t,e);if(n<r)r-=n;else{var a=r/n;a<=0&&(i=e),a>=1&&(i={x:t.x,y:t.y}),a>0&&a<1&&(i={x:(1-a)*e.x+a*t.x,y:(1-a)*e.y+a*t.y})}}e=t})),i}(t)},calcCardinalityPosition:function(t,e,n){var r;s.log.info("our points",e),e[0]!==n&&(e=e.reverse()),e.forEach((function(t){M(t,r),r=t}));var i,a=25;r=void 0,e.forEach((function(t){if(r&&!i){var e=M(t,r);if(e<a)a-=e;else{var n=a/e;n<=0&&(i=r),n>=1&&(i={x:t.x,y:t.y}),n>0&&n<1&&(i={x:(1-n)*r.x+n*t.x,y:(1-n)*r.y+n*t.y})}}r=t}));var o=t?10:5,c=Math.atan2(e[0].y-i.y,e[0].x-i.x),u={x:0,y:0};return u.x=Math.sin(c)*o+(e[0].x+i.x)/2,u.y=-Math.cos(c)*o+(e[0].y+i.y)/2,u},calcTerminalLabelPosition:function(t,e,n){var r,i=JSON.parse(JSON.stringify(n));s.log.info("our points",i),"start_left"!==e&&"start_right"!==e&&(i=i.reverse()),i.forEach((function(t){M(t,r),r=t}));var a,o=25+t;r=void 0,i.forEach((function(t){if(r&&!a){var e=M(t,r);if(e<o)o-=e;else{var n=o/e;n<=0&&(a=r),n>=1&&(a={x:t.x,y:t.y}),n>0&&n<1&&(a={x:(1-n)*r.x+n*t.x,y:(1-n)*r.y+n*t.y})}}r=t}));var c=10+.5*t,u=Math.atan2(i[0].y-a.y,i[0].x-a.x),l={x:0,y:0};return l.x=Math.sin(u)*c+(i[0].x+a.x)/2,l.y=-Math.cos(u)*c+(i[0].y+a.y)/2,"start_left"===e&&(l.x=Math.sin(u+Math.PI)*c+(i[0].x+a.x)/2,l.y=-Math.cos(u+Math.PI)*c+(i[0].y+a.y)/2),"end_right"===e&&(l.x=Math.sin(u-Math.PI)*c+(i[0].x+a.x)/2-5,l.y=-Math.cos(u-Math.PI)*c+(i[0].y+a.y)/2-5),"end_left"===e&&(l.x=Math.sin(u)*c+(i[0].x+a.x)/2-5,l.y=-Math.cos(u)*c+(i[0].y+a.y)/2-5),l},formatUrl:C,getStylesFromArray:A,generateId:N,random:j,memoize:k,runFunc:S,entityDecode:V,initIdGeneratior:U,directiveSanitizer:W}},"@braintree/sanitize-url":function(t,e){t.exports=n(9609)},d3:function(t,e){t.exports=n(7543)},dagre:function(t,e){t.exports=n(681)},"dagre-d3":function(t,e){t.exports=n(4949)},"dagre-d3/lib/label/add-html-label.js":function(t,e){t.exports=n(8284)},dompurify:function(t,e){t.exports=n(7856)},graphlib:function(t,e){t.exports=n(8282)},khroma:function(t,e){t.exports=n(8613)},"moment-mini":function(t,e){t.exports=n(1941)},stylis:function(t,e){t.exports=n(6783)}}).default},t.exports=r()},9234:()=>{},1748:(t,e,n)=>{var r={"./locale":9234,"./locale.js":9234};function i(t){var e=a(t);return n(e)}function a(t){if(!n.o(r,t)){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}return r[t]}i.keys=function(){return Object.keys(r)},i.resolve=a,t.exports=i,i.id=1748},1941:function(t,e,n){(t=n.nmd(t)).exports=function(){"use strict";var e,r;function i(){return e.apply(null,arguments)}function a(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function o(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function s(t){return void 0===t}function c(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function u(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function l(t,e){var n,r=[];for(n=0;n<t.length;++n)r.push(e(t[n],n));return r}function f(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function h(t,e){for(var n in e)f(e,n)&&(t[n]=e[n]);return f(e,"toString")&&(t.toString=e.toString),f(e,"valueOf")&&(t.valueOf=e.valueOf),t}function d(t,e,n,r){return be(t,e,n,r,!0).utc()}function p(t){return null==t._pf&&(t._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}),t._pf}function g(t){if(null==t._isValid){var e=p(t),n=r.call(e.parsedDateParts,(function(t){return null!=t})),i=!isNaN(t._d.getTime())&&e.overflow<0&&!e.empty&&!e.invalidMonth&&!e.invalidWeekday&&!e.weekdayMismatch&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated&&(!e.meridiem||e.meridiem&&n);if(t._strict&&(i=i&&0===e.charsLeftOver&&0===e.unusedTokens.length&&void 0===e.bigHour),null!=Object.isFrozen&&Object.isFrozen(t))return i;t._isValid=i}return t._isValid}function y(t){var e=d(NaN);return null!=t?h(p(e),t):p(e).userInvalidated=!0,e}r=Array.prototype.some?Array.prototype.some:function(t){for(var e=Object(this),n=e.length>>>0,r=0;r<n;r++)if(r in e&&t.call(this,e[r],r,e))return!0;return!1};var m=i.momentProperties=[];function v(t,e){var n,r,i;if(s(e._isAMomentObject)||(t._isAMomentObject=e._isAMomentObject),s(e._i)||(t._i=e._i),s(e._f)||(t._f=e._f),s(e._l)||(t._l=e._l),s(e._strict)||(t._strict=e._strict),s(e._tzm)||(t._tzm=e._tzm),s(e._isUTC)||(t._isUTC=e._isUTC),s(e._offset)||(t._offset=e._offset),s(e._pf)||(t._pf=p(e)),s(e._locale)||(t._locale=e._locale),0<m.length)for(n=0;n<m.length;n++)s(i=e[r=m[n]])||(t[r]=i);return t}var b=!1;function _(t){v(this,t),this._d=new Date(null!=t._d?t._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===b&&(b=!0,i.updateOffset(this),b=!1)}function x(t){return t instanceof _||null!=t&&null!=t._isAMomentObject}function w(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function k(t){var e=+t,n=0;return 0!==e&&isFinite(e)&&(n=w(e)),n}function T(t,e,n){var r,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),o=0;for(r=0;r<i;r++)(n&&t[r]!==e[r]||!n&&k(t[r])!==k(e[r]))&&o++;return o+a}function E(t){!1===i.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function C(t,e){var n=!0;return h((function(){if(null!=i.deprecationHandler&&i.deprecationHandler(null,t),n){for(var r,a=[],o=0;o<arguments.length;o++){if(r="","object"==typeof arguments[o]){for(var s in r+="\n["+o+"] ",arguments[0])r+=s+": "+arguments[0][s]+", ";r=r.slice(0,-2)}else r=arguments[o];a.push(r)}E(t+"\nArguments: "+Array.prototype.slice.call(a).join("")+"\n"+(new Error).stack),n=!1}return e.apply(this,arguments)}),e)}var S,M={};function A(t,e){null!=i.deprecationHandler&&i.deprecationHandler(t,e),M[t]||(E(e),M[t]=!0)}function O(t){return t instanceof Function||"[object Function]"===Object.prototype.toString.call(t)}function N(t,e){var n,r=h({},t);for(n in e)f(e,n)&&(o(t[n])&&o(e[n])?(r[n]={},h(r[n],t[n]),h(r[n],e[n])):null!=e[n]?r[n]=e[n]:delete r[n]);for(n in t)f(t,n)&&!f(e,n)&&o(t[n])&&(r[n]=h({},r[n]));return r}function j(t){null!=t&&this.set(t)}i.suppressDeprecationWarnings=!1,i.deprecationHandler=null,S=Object.keys?Object.keys:function(t){var e,n=[];for(e in t)f(t,e)&&n.push(e);return n};var D={};function B(t,e){var n=t.toLowerCase();D[n]=D[n+"s"]=D[e]=t}function L(t){return"string"==typeof t?D[t]||D[t.toLowerCase()]:void 0}function I(t){var e,n,r={};for(n in t)f(t,n)&&(e=L(n))&&(r[e]=t[n]);return r}var R={};function P(t,e){R[t]=e}function F(t,e,n){var r=""+Math.abs(t),i=e-r.length;return(0<=t?n?"+":"":"-")+Math.pow(10,Math.max(0,i)).toString().substr(1)+r}var z=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Y=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,q={},U={};function V(t,e,n,r){var i=r;"string"==typeof r&&(i=function(){return this[r]()}),t&&(U[t]=i),e&&(U[e[0]]=function(){return F(i.apply(this,arguments),e[1],e[2])}),n&&(U[n]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function W(t,e){return t.isValid()?(e=H(e,t.localeData()),q[e]=q[e]||function(t){var e,n,r,i=t.match(z);for(e=0,n=i.length;e<n;e++)U[i[e]]?i[e]=U[i[e]]:i[e]=(r=i[e]).match(/\[[\s\S]/)?r.replace(/^\[|\]$/g,""):r.replace(/\\/g,"");return function(e){var r,a="";for(r=0;r<n;r++)a+=O(i[r])?i[r].call(e,t):i[r];return a}}(e),q[e](t)):t.localeData().invalidDate()}function H(t,e){var n=5;function r(t){return e.longDateFormat(t)||t}for(Y.lastIndex=0;0<=n&&Y.test(t);)t=t.replace(Y,r),Y.lastIndex=0,n-=1;return t}var $=/\d/,G=/\d\d/,X=/\d{3}/,Z=/\d{4}/,K=/[+-]?\d{6}/,Q=/\d\d?/,J=/\d\d\d\d?/,tt=/\d\d\d\d\d\d?/,et=/\d{1,3}/,nt=/\d{1,4}/,rt=/[+-]?\d{1,6}/,it=/\d+/,at=/[+-]?\d+/,ot=/Z|[+-]\d\d:?\d\d/gi,st=/Z|[+-]\d\d(?::?\d\d)?/gi,ct=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,ut={};function lt(t,e,n){ut[t]=O(e)?e:function(t,r){return t&&n?n:e}}function ft(t,e){return f(ut,t)?ut[t](e._strict,e._locale):new RegExp(ht(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(t,e,n,r,i){return e||n||r||i}))))}function ht(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var dt={};function pt(t,e){var n,r=e;for("string"==typeof t&&(t=[t]),c(e)&&(r=function(t,n){n[e]=k(t)}),n=0;n<t.length;n++)dt[t[n]]=r}function gt(t,e){pt(t,(function(t,n,r,i){r._w=r._w||{},e(t,r._w,r,i)}))}function yt(t){return mt(t)?366:365}function mt(t){return t%4==0&&t%100!=0||t%400==0}V("Y",0,0,(function(){var t=this.year();return t<=9999?""+t:"+"+t})),V(0,["YY",2],0,(function(){return this.year()%100})),V(0,["YYYY",4],0,"year"),V(0,["YYYYY",5],0,"year"),V(0,["YYYYYY",6,!0],0,"year"),B("year","y"),P("year",1),lt("Y",at),lt("YY",Q,G),lt("YYYY",nt,Z),lt("YYYYY",rt,K),lt("YYYYYY",rt,K),pt(["YYYYY","YYYYYY"],0),pt("YYYY",(function(t,e){e[0]=2===t.length?i.parseTwoDigitYear(t):k(t)})),pt("YY",(function(t,e){e[0]=i.parseTwoDigitYear(t)})),pt("Y",(function(t,e){e[0]=parseInt(t,10)})),i.parseTwoDigitYear=function(t){return k(t)+(68<k(t)?1900:2e3)};var vt,bt=_t("FullYear",!0);function _t(t,e){return function(n){return null!=n?(wt(this,t,n),i.updateOffset(this,e),this):xt(this,t)}}function xt(t,e){return t.isValid()?t._d["get"+(t._isUTC?"UTC":"")+e]():NaN}function wt(t,e,n){t.isValid()&&!isNaN(n)&&("FullYear"===e&&mt(t.year())&&1===t.month()&&29===t.date()?t._d["set"+(t._isUTC?"UTC":"")+e](n,t.month(),kt(n,t.month())):t._d["set"+(t._isUTC?"UTC":"")+e](n))}function kt(t,e){if(isNaN(t)||isNaN(e))return NaN;var n=(e%12+12)%12;return t+=(e-n)/12,1===n?mt(t)?29:28:31-n%7%2}vt=Array.prototype.indexOf?Array.prototype.indexOf:function(t){var e;for(e=0;e<this.length;++e)if(this[e]===t)return e;return-1},V("M",["MM",2],"Mo",(function(){return this.month()+1})),V("MMM",0,0,(function(t){return this.localeData().monthsShort(this,t)})),V("MMMM",0,0,(function(t){return this.localeData().months(this,t)})),B("month","M"),P("month",8),lt("M",Q),lt("MM",Q,G),lt("MMM",(function(t,e){return e.monthsShortRegex(t)})),lt("MMMM",(function(t,e){return e.monthsRegex(t)})),pt(["M","MM"],(function(t,e){e[1]=k(t)-1})),pt(["MMM","MMMM"],(function(t,e,n,r){var i=n._locale.monthsParse(t,r,n._strict);null!=i?e[1]=i:p(n).invalidMonth=t}));var Tt=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Et="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ct="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function St(t,e){var n;if(!t.isValid())return t;if("string"==typeof e)if(/^\d+$/.test(e))e=k(e);else if(!c(e=t.localeData().monthsParse(e)))return t;return n=Math.min(t.date(),kt(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,n),t}function Mt(t){return null!=t?(St(this,t),i.updateOffset(this,!0),this):xt(this,"Month")}var At=ct,Ot=ct;function Nt(){function t(t,e){return e.length-t.length}var e,n,r=[],i=[],a=[];for(e=0;e<12;e++)n=d([2e3,e]),r.push(this.monthsShort(n,"")),i.push(this.months(n,"")),a.push(this.months(n,"")),a.push(this.monthsShort(n,""));for(r.sort(t),i.sort(t),a.sort(t),e=0;e<12;e++)r[e]=ht(r[e]),i[e]=ht(i[e]);for(e=0;e<24;e++)a[e]=ht(a[e]);this._monthsRegex=new RegExp("^("+a.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+i.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+r.join("|")+")","i")}function jt(t){var e;if(t<100&&0<=t){var n=Array.prototype.slice.call(arguments);n[0]=t+400,e=new Date(Date.UTC.apply(null,n)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)}else e=new Date(Date.UTC.apply(null,arguments));return e}function Dt(t,e,n){var r=7+e-n;return-(7+jt(t,0,r).getUTCDay()-e)%7+r-1}function Bt(t,e,n,r,i){var a,o,s=1+7*(e-1)+(7+n-r)%7+Dt(t,r,i);return o=s<=0?yt(a=t-1)+s:s>yt(t)?(a=t+1,s-yt(t)):(a=t,s),{year:a,dayOfYear:o}}function Lt(t,e,n){var r,i,a=Dt(t.year(),e,n),o=Math.floor((t.dayOfYear()-a-1)/7)+1;return o<1?r=o+It(i=t.year()-1,e,n):o>It(t.year(),e,n)?(r=o-It(t.year(),e,n),i=t.year()+1):(i=t.year(),r=o),{week:r,year:i}}function It(t,e,n){var r=Dt(t,e,n),i=Dt(t+1,e,n);return(yt(t)-r+i)/7}function Rt(t,e){return t.slice(e,7).concat(t.slice(0,e))}V("w",["ww",2],"wo","week"),V("W",["WW",2],"Wo","isoWeek"),B("week","w"),B("isoWeek","W"),P("week",5),P("isoWeek",5),lt("w",Q),lt("ww",Q,G),lt("W",Q),lt("WW",Q,G),gt(["w","ww","W","WW"],(function(t,e,n,r){e[r.substr(0,1)]=k(t)})),V("d",0,"do","day"),V("dd",0,0,(function(t){return this.localeData().weekdaysMin(this,t)})),V("ddd",0,0,(function(t){return this.localeData().weekdaysShort(this,t)})),V("dddd",0,0,(function(t){return this.localeData().weekdays(this,t)})),V("e",0,0,"weekday"),V("E",0,0,"isoWeekday"),B("day","d"),B("weekday","e"),B("isoWeekday","E"),P("day",11),P("weekday",11),P("isoWeekday",11),lt("d",Q),lt("e",Q),lt("E",Q),lt("dd",(function(t,e){return e.weekdaysMinRegex(t)})),lt("ddd",(function(t,e){return e.weekdaysShortRegex(t)})),lt("dddd",(function(t,e){return e.weekdaysRegex(t)})),gt(["dd","ddd","dddd"],(function(t,e,n,r){var i=n._locale.weekdaysParse(t,r,n._strict);null!=i?e.d=i:p(n).invalidWeekday=t})),gt(["d","e","E"],(function(t,e,n,r){e[r]=k(t)}));var Pt="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Ft="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),zt="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Yt=ct,qt=ct,Ut=ct;function Vt(){function t(t,e){return e.length-t.length}var e,n,r,i,a,o=[],s=[],c=[],u=[];for(e=0;e<7;e++)n=d([2e3,1]).day(e),r=this.weekdaysMin(n,""),i=this.weekdaysShort(n,""),a=this.weekdays(n,""),o.push(r),s.push(i),c.push(a),u.push(r),u.push(i),u.push(a);for(o.sort(t),s.sort(t),c.sort(t),u.sort(t),e=0;e<7;e++)s[e]=ht(s[e]),c[e]=ht(c[e]),u[e]=ht(u[e]);this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+c.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function Wt(){return this.hours()%12||12}function Ht(t,e){V(t,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)}))}function $t(t,e){return e._meridiemParse}V("H",["HH",2],0,"hour"),V("h",["hh",2],0,Wt),V("k",["kk",2],0,(function(){return this.hours()||24})),V("hmm",0,0,(function(){return""+Wt.apply(this)+F(this.minutes(),2)})),V("hmmss",0,0,(function(){return""+Wt.apply(this)+F(this.minutes(),2)+F(this.seconds(),2)})),V("Hmm",0,0,(function(){return""+this.hours()+F(this.minutes(),2)})),V("Hmmss",0,0,(function(){return""+this.hours()+F(this.minutes(),2)+F(this.seconds(),2)})),Ht("a",!0),Ht("A",!1),B("hour","h"),P("hour",13),lt("a",$t),lt("A",$t),lt("H",Q),lt("h",Q),lt("k",Q),lt("HH",Q,G),lt("hh",Q,G),lt("kk",Q,G),lt("hmm",J),lt("hmmss",tt),lt("Hmm",J),lt("Hmmss",tt),pt(["H","HH"],3),pt(["k","kk"],(function(t,e,n){var r=k(t);e[3]=24===r?0:r})),pt(["a","A"],(function(t,e,n){n._isPm=n._locale.isPM(t),n._meridiem=t})),pt(["h","hh"],(function(t,e,n){e[3]=k(t),p(n).bigHour=!0})),pt("hmm",(function(t,e,n){var r=t.length-2;e[3]=k(t.substr(0,r)),e[4]=k(t.substr(r)),p(n).bigHour=!0})),pt("hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[3]=k(t.substr(0,r)),e[4]=k(t.substr(r,2)),e[5]=k(t.substr(i)),p(n).bigHour=!0})),pt("Hmm",(function(t,e,n){var r=t.length-2;e[3]=k(t.substr(0,r)),e[4]=k(t.substr(r))})),pt("Hmmss",(function(t,e,n){var r=t.length-4,i=t.length-2;e[3]=k(t.substr(0,r)),e[4]=k(t.substr(r,2)),e[5]=k(t.substr(i))}));var Gt,Xt=_t("Hours",!0),Zt={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{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"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:Et,monthsShort:Ct,week:{dow:0,doy:6},weekdays:Pt,weekdaysMin:zt,weekdaysShort:Ft,meridiemParse:/[ap]\.?m?\.?/i},Kt={},Qt={};function Jt(t){return t?t.toLowerCase().replace("_","-"):t}function te(e){var r=null;if(!Kt[e]&&t&&t.exports)try{r=Gt._abbr,n(1748)("./"+e),ee(r)}catch(e){}return Kt[e]}function ee(t,e){var n;return t&&((n=s(e)?re(t):ne(t,e))?Gt=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),Gt._abbr}function ne(t,e){if(null===e)return delete Kt[t],null;var n,r=Zt;if(e.abbr=t,null!=Kt[t])A("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=Kt[t]._config;else if(null!=e.parentLocale)if(null!=Kt[e.parentLocale])r=Kt[e.parentLocale]._config;else{if(null==(n=te(e.parentLocale)))return Qt[e.parentLocale]||(Qt[e.parentLocale]=[]),Qt[e.parentLocale].push({name:t,config:e}),null;r=n._config}return Kt[t]=new j(N(r,e)),Qt[t]&&Qt[t].forEach((function(t){ne(t.name,t.config)})),ee(t),Kt[t]}function re(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return Gt;if(!a(t)){if(e=te(t))return e;t=[t]}return function(t){for(var e,n,r,i,a=0;a<t.length;){for(e=(i=Jt(t[a]).split("-")).length,n=(n=Jt(t[a+1]))?n.split("-"):null;0<e;){if(r=te(i.slice(0,e).join("-")))return r;if(n&&n.length>=e&&T(i,n,!0)>=e-1)break;e--}a++}return Gt}(t)}function ie(t){var e,n=t._a;return n&&-2===p(t).overflow&&(e=n[1]<0||11<n[1]?1:n[2]<1||n[2]>kt(n[0],n[1])?2:n[3]<0||24<n[3]||24===n[3]&&(0!==n[4]||0!==n[5]||0!==n[6])?3:n[4]<0||59<n[4]?4:n[5]<0||59<n[5]?5:n[6]<0||999<n[6]?6:-1,p(t)._overflowDayOfYear&&(e<0||2<e)&&(e=2),p(t)._overflowWeeks&&-1===e&&(e=7),p(t)._overflowWeekday&&-1===e&&(e=8),p(t).overflow=e),t}function ae(t,e,n){return null!=t?t:null!=e?e:n}function oe(t){var e,n,r,a,o,s=[];if(!t._d){var c,u;for(c=t,u=new Date(i.now()),r=c._useUTC?[u.getUTCFullYear(),u.getUTCMonth(),u.getUTCDate()]:[u.getFullYear(),u.getMonth(),u.getDate()],t._w&&null==t._a[2]&&null==t._a[1]&&function(t){var e,n,r,i,a,o,s,c;if(null!=(e=t._w).GG||null!=e.W||null!=e.E)a=1,o=4,n=ae(e.GG,t._a[0],Lt(_e(),1,4).year),r=ae(e.W,1),((i=ae(e.E,1))<1||7<i)&&(c=!0);else{a=t._locale._week.dow,o=t._locale._week.doy;var u=Lt(_e(),a,o);n=ae(e.gg,t._a[0],u.year),r=ae(e.w,u.week),null!=e.d?((i=e.d)<0||6<i)&&(c=!0):null!=e.e?(i=e.e+a,(e.e<0||6<e.e)&&(c=!0)):i=a}r<1||r>It(n,a,o)?p(t)._overflowWeeks=!0:null!=c?p(t)._overflowWeekday=!0:(s=Bt(n,r,i,a,o),t._a[0]=s.year,t._dayOfYear=s.dayOfYear)}(t),null!=t._dayOfYear&&(o=ae(t._a[0],r[0]),(t._dayOfYear>yt(o)||0===t._dayOfYear)&&(p(t)._overflowDayOfYear=!0),n=jt(o,0,t._dayOfYear),t._a[1]=n.getUTCMonth(),t._a[2]=n.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=s[e]=r[e];for(;e<7;e++)t._a[e]=s[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[3]&&0===t._a[4]&&0===t._a[5]&&0===t._a[6]&&(t._nextDay=!0,t._a[3]=0),t._d=(t._useUTC?jt:function(t,e,n,r,i,a,o){var s;return t<100&&0<=t?(s=new Date(t+400,e,n,r,i,a,o),isFinite(s.getFullYear())&&s.setFullYear(t)):s=new Date(t,e,n,r,i,a,o),s}).apply(null,s),a=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[3]=24),t._w&&void 0!==t._w.d&&t._w.d!==a&&(p(t).weekdayMismatch=!0)}}var se=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,ce=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,ue=/Z|[+-]\d\d(?::?\d\d)?/,le=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],fe=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],he=/^\/?Date\((\-?\d+)/i;function de(t){var e,n,r,i,a,o,s=t._i,c=se.exec(s)||ce.exec(s);if(c){for(p(t).iso=!0,e=0,n=le.length;e<n;e++)if(le[e][1].exec(c[1])){i=le[e][0],r=!1!==le[e][2];break}if(null==i)return void(t._isValid=!1);if(c[3]){for(e=0,n=fe.length;e<n;e++)if(fe[e][1].exec(c[3])){a=(c[2]||" ")+fe[e][0];break}if(null==a)return void(t._isValid=!1)}if(!r&&null!=a)return void(t._isValid=!1);if(c[4]){if(!ue.exec(c[4]))return void(t._isValid=!1);o="Z"}t._f=i+(a||"")+(o||""),me(t)}else t._isValid=!1}var pe=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/;var ge={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function ye(t){var e,n,r,i=pe.exec(t._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(i){var a=function(t,e,n,r,i,a){var o=[function(t){var e=parseInt(t,10);return e<=49?2e3+e:e<=999?1900+e:e}(t),Ct.indexOf(e),parseInt(n,10),parseInt(r,10),parseInt(i,10)];return a&&o.push(parseInt(a,10)),o}(i[4],i[3],i[2],i[5],i[6],i[7]);if(n=a,r=t,(e=i[1])&&Ft.indexOf(e)!==new Date(n[0],n[1],n[2]).getDay()&&(p(r).weekdayMismatch=!0,!(r._isValid=!1)))return;t._a=a,t._tzm=function(t,e,n){if(t)return ge[t];if(e)return 0;var r=parseInt(n,10),i=r%100;return(r-i)/100*60+i}(i[8],i[9],i[10]),t._d=jt.apply(null,t._a),t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),p(t).rfc2822=!0}else t._isValid=!1}function me(t){if(t._f!==i.ISO_8601)if(t._f!==i.RFC_2822){t._a=[],p(t).empty=!0;var e,n,r,a,o,s,c,u,l=""+t._i,h=l.length,d=0;for(r=H(t._f,t._locale).match(z)||[],e=0;e<r.length;e++)a=r[e],(n=(l.match(ft(a,t))||[])[0])&&(0<(o=l.substr(0,l.indexOf(n))).length&&p(t).unusedInput.push(o),l=l.slice(l.indexOf(n)+n.length),d+=n.length),U[a]?(n?p(t).empty=!1:p(t).unusedTokens.push(a),s=a,u=t,null!=(c=n)&&f(dt,s)&&dt[s](c,u._a,u,s)):t._strict&&!n&&p(t).unusedTokens.push(a);p(t).charsLeftOver=h-d,0<l.length&&p(t).unusedInput.push(l),t._a[3]<=12&&!0===p(t).bigHour&&0<t._a[3]&&(p(t).bigHour=void 0),p(t).parsedDateParts=t._a.slice(0),p(t).meridiem=t._meridiem,t._a[3]=function(t,e,n){var r;return null==n?e:null!=t.meridiemHour?t.meridiemHour(e,n):(null!=t.isPM&&((r=t.isPM(n))&&e<12&&(e+=12),r||12!==e||(e=0)),e)}(t._locale,t._a[3],t._meridiem),oe(t),ie(t)}else ye(t);else de(t)}function ve(t){var e,n,r,f,d=t._i,m=t._f;return t._locale=t._locale||re(t._l),null===d||void 0===m&&""===d?y({nullInput:!0}):("string"==typeof d&&(t._i=d=t._locale.preparse(d)),x(d)?new _(ie(d)):(u(d)?t._d=d:a(m)?function(t){var e,n,r,i,a;if(0===t._f.length)return p(t).invalidFormat=!0,t._d=new Date(NaN);for(i=0;i<t._f.length;i++)a=0,e=v({},t),null!=t._useUTC&&(e._useUTC=t._useUTC),e._f=t._f[i],me(e),g(e)&&(a+=p(e).charsLeftOver,a+=10*p(e).unusedTokens.length,p(e).score=a,(null==r||a<r)&&(r=a,n=e));h(t,n||e)}(t):m?me(t):s(n=(e=t)._i)?e._d=new Date(i.now()):u(n)?e._d=new Date(n.valueOf()):"string"==typeof n?(r=e,null===(f=he.exec(r._i))?(de(r),!1===r._isValid&&(delete r._isValid,ye(r),!1===r._isValid&&(delete r._isValid,i.createFromInputFallback(r)))):r._d=new Date(+f[1])):a(n)?(e._a=l(n.slice(0),(function(t){return parseInt(t,10)})),oe(e)):o(n)?function(t){if(!t._d){var e=I(t._i);t._a=l([e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],(function(t){return t&&parseInt(t,10)})),oe(t)}}(e):c(n)?e._d=new Date(n):i.createFromInputFallback(e),g(t)||(t._d=null),t))}function be(t,e,n,r,i){var s,c={};return!0!==n&&!1!==n||(r=n,n=void 0),(o(t)&&function(t){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(t).length;var e;for(e in t)if(t.hasOwnProperty(e))return!1;return!0}(t)||a(t)&&0===t.length)&&(t=void 0),c._isAMomentObject=!0,c._useUTC=c._isUTC=i,c._l=n,c._i=t,c._f=e,c._strict=r,(s=new _(ie(ve(c))))._nextDay&&(s.add(1,"d"),s._nextDay=void 0),s}function _e(t,e,n,r){return be(t,e,n,r,!1)}i.createFromInputFallback=C("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))})),i.ISO_8601=function(){},i.RFC_2822=function(){};var xe=C("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=_e.apply(null,arguments);return this.isValid()&&t.isValid()?t<this?this:t:y()})),we=C("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=_e.apply(null,arguments);return this.isValid()&&t.isValid()?this<t?this:t:y()}));function ke(t,e){var n,r;if(1===e.length&&a(e[0])&&(e=e[0]),!e.length)return _e();for(n=e[0],r=1;r<e.length;++r)e[r].isValid()&&!e[r][t](n)||(n=e[r]);return n}var Te=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Ee(t){var e=I(t),n=e.year||0,r=e.quarter||0,i=e.month||0,a=e.week||e.isoWeek||0,o=e.day||0,s=e.hour||0,c=e.minute||0,u=e.second||0,l=e.millisecond||0;this._isValid=function(t){for(var e in t)if(-1===vt.call(Te,e)||null!=t[e]&&isNaN(t[e]))return!1;for(var n=!1,r=0;r<Te.length;++r)if(t[Te[r]]){if(n)return!1;parseFloat(t[Te[r]])!==k(t[Te[r]])&&(n=!0)}return!0}(e),this._milliseconds=+l+1e3*u+6e4*c+1e3*s*60*60,this._days=+o+7*a,this._months=+i+3*r+12*n,this._data={},this._locale=re(),this._bubble()}function Ce(t){return t instanceof Ee}function Se(t){return t<0?-1*Math.round(-1*t):Math.round(t)}function Me(t,e){V(t,0,0,(function(){var t=this.utcOffset(),n="+";return t<0&&(t=-t,n="-"),n+F(~~(t/60),2)+e+F(~~t%60,2)}))}Me("Z",":"),Me("ZZ",""),lt("Z",st),lt("ZZ",st),pt(["Z","ZZ"],(function(t,e,n){n._useUTC=!0,n._tzm=Oe(st,t)}));var Ae=/([\+\-]|\d\d)/g
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment