mermaid/dist/mermaidAPI.slim.min.js

9 lines
270 KiB
JavaScript
Raw Normal View History

2015-09-26 13:00:30 +02:00
!function t(e,n,r){function i(s,o){if(!n[s]){if(!e[s]){var u="function"==typeof require&&require;if(!o&&u)return u(s,!0);if(a)return a(s,!0);throw new Error("Cannot find module '"+s+"'")}var c=n[s]={exports:{}};e[s][0].call(c.exports,function(t){var n=e[s][1][t];return i(n?n:t)},c,c.exports,t,e,n,r)}return n[s].exports}for(var a="function"==typeof require&&require,s=0;s<r.length;s++)i(r[s]);return i}({1:[function(t,e){e.exports={graphlib:t("./lib/graphlib"),dagre:t("./lib/dagre"),intersect:t("./lib/intersect"),render:t("./lib/render"),util:t("./lib/util"),version:t("./lib/version")}},{"./lib/dagre":8,"./lib/graphlib":9,"./lib/intersect":10,"./lib/render":25,"./lib/util":27,"./lib/version":28}],2:[function(t,e){function n(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"),s=i.append("path").attr("d","M 0 0 L 10 5 L 0 10 z").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(s,n[r+"Style"])}function r(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"),s=i.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");a.applyStyle(s,n[r+"Style"])}function i(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"),s=i.append("path").attr("d","M 0 5 L 10 5").style("stroke-width",1).style("stroke-dasharray","1,0");a.applyStyle(s,n[r+"Style"])}var a=t("./util");e.exports={"default":n,normal:n,vee:r,undirected:i}},{"./util":27}],3:[function(t,e){function n(t,e){var n=e.nodes().filter(function(t){return r.isSubgraph(e,t)}),a=t.selectAll("g.cluster").data(n,function(t){return t});return a.selectAll("*").remove(),a.enter().append("g").attr("class","cluster").attr("id",function(t){var n=e.node(t);return n.id}).style("opacity",0),r.applyTransition(a,e).style("opacity",1),a.each(function(t){var n=e.node(t),r=d3.select(this);d3.select(this).append("rect");var a=r.append("g").attr("class","label");i(a,n,n.clusterLabelPos)}),a.selectAll("rect").each(function(t){var n=e.node(t),i=d3.select(this);r.applyStyle(i,n.style)}),r.applyTransition(a.exit(),e).style("opacity",0).remove(),a}var r=t("./util"),i=t("./label/add-label");e.exports=n},{"./label/add-label":18,"./util":27}],4:[function(t,e){"use strict";function n(t,e){var n=t.selectAll("g.edgeLabel").data(e.edges(),function(t){return a.edgeToId(t)}).classed("update",!0);return n.selectAll("*").remove(),n.enter().append("g").classed("edgeLabel",!0).style("opacity",0),n.each(function(t){var n=e.edge(t),a=i(s.select(this),e.edge(t),0,0).classed("label",!0),o=a.node().getBBox();n.labelId&&a.attr("id",n.labelId),r.has(n,"width")||(n.width=o.width),r.has(n,"height")||(n.height=o.height)}),a.applyTransition(n.exit(),e).style("opacity",0).remove(),n}var r=t("./lodash"),i=t("./label/add-label"),a=t("./util"),s=t("./d3");e.exports=n},{"./d3":7,"./label/add-label":18,"./lodash":21,"./util":27}],5:[function(t,e){"use strict";function n(t,e,n){var i=t.selectAll("g.edgePath").data(e.edges(),function(t){return l.edgeToId(t)}).classed("update",!0);return s(i,e),o(i,e),l.applyTransition(i,e).style("opacity",1),i.each(function(t){var n=h.select(this),r=e.edge(t);r.elem=this,r.id&&n.attr("id",r.id),l.applyClass(n,r["class"],(n.classed("update")?"update ":"")+"edgePath")}),i.selectAll("path.path").each(function(t){var n=e.edge(t);n.arrowheadId=u.uniqueId("arrowhead");var i=h.select(this).attr("marker-end",function(){return"url(#"+n.arrowheadId+")"}).style("fill","none");l.applyTransition(i,e).attr("d",function(t){return r(e,t)}),l.applyStyle(i,n.style)}),i.selectAll("defs *").remove(),i.selectAll("defs").each(function(t){var r=e.edge(t),i=n[r.arrowhead];i(h.select(this),r.arrowheadId,r,"arrowh
function n(t){function e(i){if(!r.has(n,i)){n[i]=!0;var a=t.node(i);s[a.rank].push(i),r.each(t.successors(i),e)}}var n={},i=r.filter(t.nodes(),function(e){return!t.children(e).length}),a=r.max(r.map(i,function(e){return t.node(e).rank})),s=r.map(r.range(a+1),function(){return[]}),o=r.sortBy(i,function(e){return t.node(e).rank});return r.each(o,e),s}var r=t("../lodash");e.exports=n},{"../lodash":38}],47:[function(t,e){"use strict";function n(t,e){var n={};a.each(t,function(t,e){var r=n[t.v]={indegree:0,"in":[],out:[],vs:[t.v],i:e};a.isUndefined(t.barycenter)||(r.barycenter=t.barycenter,r.weight=t.weight)}),a.each(e.edges(),function(t){var e=n[t.v],r=n[t.w];a.isUndefined(e)||a.isUndefined(r)||(r.indegree++,e.out.push(n[t.w]))});var i=a.filter(n,function(t){return!t.indegree});return r(i)}function r(t){function e(t){return function(e){e.merged||(a.isUndefined(e.barycenter)||a.isUndefined(t.barycenter)||e.barycenter>=t.barycenter)&&i(t,e)}}function n(e){return function(n){n["in"].push(e),0===--n.indegree&&t.push(n)}}for(var r=[];t.length;){var s=t.pop();r.push(s),a.each(s["in"].reverse(),e(s)),a.each(s.out,n(s))}return a.chain(r).filter(function(t){return!t.merged}).map(function(t){return a.pick(t,["vs","i","barycenter","weight"])}).value()}function i(t,e){var n=0,r=0;t.weight&&(n+=t.barycenter*t.weight,r+=t.weight),e.weight&&(n+=e.barycenter*e.weight,r+=e.weight),t.vs=e.vs.concat(t.vs),t.barycenter=n/r,t.weight=r,t.i=Math.min(e.i,t.i),e.merged=!0}var a=t("../lodash");e.exports=n},{"../lodash":38}],48:[function(t,e){function n(t,e,c,l){var h=t.children(e),f=t.node(e),d=f?f.borderLeft:void 0,p=f?f.borderRight:void 0,g={};d&&(h=a.filter(h,function(t){return t!==d&&t!==p}));var y=s(t,h);a.each(y,function(e){if(t.children(e.v).length){var r=n(t,e.v,c,l);g[e.v]=r,a.has(r,"barycenter")&&i(e,r)}});var m=o(y,c);r(m,g);var v=u(m,l);if(d&&(v.vs=a.flatten([d,v.vs,p],!0),t.predecessors(d).length)){var _=t.node(t.predecessors(d)[0]),b=t.node(t.predecessors(p)[0]);a.has(v,"barycenter")||(v.barycenter=0,v.weight=0),v.barycenter=(v.barycenter*v.weight+_.order+b.order)/(v.weight+2),v.weight+=2}return v}function r(t,e){a.each(t,function(t){t.vs=a.flatten(t.vs.map(function(t){return e[t]?e[t].vs:t}),!0)})}function i(t,e){a.isUndefined(t.barycenter)?(t.barycenter=e.barycenter,t.weight=e.weight):(t.barycenter=(t.barycenter*t.weight+e.barycenter*e.weight)/(t.weight+e.weight),t.weight+=e.weight)}var a=t("../lodash"),s=t("./barycenter"),o=t("./resolve-conflicts"),u=t("./sort");e.exports=n},{"../lodash":38,"./barycenter":42,"./resolve-conflicts":47,"./sort":49}],49:[function(t,e){function n(t,e){var n=s.partition(t,function(t){return a.has(t,"barycenter")}),o=n.lhs,u=a.sortBy(n.rhs,function(t){return-t.i}),c=[],l=0,h=0,f=0;o.sort(i(!!e)),f=r(c,u,f),a.each(o,function(t){f+=t.vs.length,c.push(t.vs),l+=t.barycenter*t.weight,h+=t.weight,f=r(c,u,f)});var d={vs:a.flatten(c,!0)};return h&&(d.barycenter=l/h,d.weight=h),d}function r(t,e,n){for(var r;e.length&&(r=a.last(e)).i<=n;)e.pop(),t.push(r.vs),n++;return n}function i(t){return function(e,n){return e.barycenter<n.barycenter?-1:e.barycenter>n.barycenter?1:t?n.i-e.i:e.i-n.i}}var a=t("../lodash"),s=t("../util");e.exports=n},{"../lodash":38,"../util":57}],50:[function(t,e){function n(t){var e=i(t);a.each(t.graph().dummyChains,function(n){for(var i=t.node(n),a=i.edgeObj,s=r(t,e,a.v,a.w),o=s.path,u=s.lca,c=0,l=o[c],h=!0;n!==a.w;){if(i=t.node(n),h){for(;(l=o[c])!==u&&t.node(l).maxRank<i.rank;)c++;l===u&&(h=!1)}if(!h){for(;c<o.length-1&&t.node(l=o[c+1]).minRank<=i.rank;)c++;l=o[c]}t.setParent(n,l),n=t.successors(n)[0]}})}function r(t,e,n,r){var i,a,s=[],o=[],u=Math.min(e[n].low,e[r].low),c=Math.max(e[n].lim,e[r].lim);i=n;do i=t.parent(i),s.push(i);while(i&&(e[i].low>u||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:s.concat(o.reverse()),lca:a}}function i(t){function e(i){var s=r;a.each(t.children(i),e),n[i]={low:s,lim:r++}}var n={},r=0;return a.each(t.children(),e),n}var a=t("./lodash");e.exports=n},{"./lodash":38}],51:[function(t,e){"use strict";function n(t,e){function n(e,n){var s=0,o=0
for(e||(e=js(r));++n<r;)e[n]=t[n];return e}function en(t,e){for(var n=-1,r=t.length;++n<r&&e(t[n],n,t)!==!1;);return t}function an(t,e){for(var n=t.length;n--&&e(t[n],n,t)!==!1;);return t}function sn(t,e){for(var n=-1,r=t.length;++n<r;)if(!e(t[n],n,t))return!1;return!0}function on(t,e,n,r){for(var i=-1,a=t.length,s=r,o=s;++i<a;){var u=t[i],c=+e(u);n(c,s)&&(s=c,o=u)}return o}function un(t,e){for(var n=-1,r=t.length,i=-1,a=[];++n<r;){var s=t[n];e(s,n,t)&&(a[++i]=s)}return a}function cn(t,e){for(var n=-1,r=t.length,i=js(r);++n<r;)i[n]=e(t[n],n,t);return i}function ln(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}function hn(t,e,n,r){var i=-1,a=t.length;for(r&&a&&(n=t[++i]);++i<a;)n=e(n,t[i],i,t);return n}function fn(t,e,n,r){var i=t.length;for(r&&i&&(n=t[--i]);i--;)n=e(n,t[i],i,t);return n}function dn(t,e){for(var n=-1,r=t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}function pn(t,e){for(var n=t.length,r=0;n--;)r+=+e(t[n])||0;return r}function gn(t,e){return t===E?e:t}function yn(t,e,n,r){return t!==E&&to.call(r,n)?t:e}function mn(t,e,n){for(var r=-1,i=ju(e),a=i.length;++r<a;){var s=i[r],o=t[s],u=n(o,e[s],s,t,e);(u===u?u===o:o!==o)&&(o!==E||s in t)||(t[s]=u)}return t}function vn(t,e){return null==e?t:bn(e,ju(e),t)}function _n(t,e){for(var n=-1,r=null==t,i=!r&&Xr(t),a=i?t.length:0,s=e.length,o=js(s);++n<s;){var u=e[n];o[n]=i?Qr(u,a)?t[u]:E:r?E:t[u]}return o}function bn(t,e,n){n||(n={});for(var r=-1,i=e.length;++r<i;){var a=e[r];n[a]=t[a]}return n}function xn(t,e,n){var r=typeof t;return"function"==r?e===E?t:sr(t,e,n):null==t?Ts:"object"==r?jn(t):e===E?Is(t):$n(t,e)}function wn(t,e,n,r,i,a,s){var o;if(n&&(o=i?n(t,r,i):n(t)),o!==E)return o;if(!Ma(t))return t;var u=Cu(t);if(u){if(o=zr(t),!e)return tn(t,o)}else{var c=no.call(t),l=c==K;if(c!=J&&c!=V&&(!l||i))return We[c]?Zr(t,c,e):i?t:{};if(o=qr(l?{}:t),!e)return vn(o,t)}a||(a=[]),s||(s=[]);for(var h=a.length;h--;)if(a[h]==t)return s[h];return a.push(t),s.push(o),(u?en:Bn)(t,function(r,i){o[i]=wn(r,e,n,i,t,a,s)}),o}function kn(t,e,n){if("function"!=typeof t)throw new Zs(W);return ho(function(){t.apply(E,n)},e)}function An(t,e){var n=t?t.length:0,r=[];if(!n)return r;var i=-1,s=Wr(),o=s==a,u=o&&e.length>=j?gr(e):null,c=e.length;u&&(s=Xe,o=!1,e=u);t:for(;++i<n;){var l=t[i];if(o&&l===l){for(var h=c;h--;)if(e[h]===l)continue t;r.push(l)}else s(e,l,0)<0&&r.push(l)}return r}function En(t,e){var n=!0;return Po(t,function(t,r,i){return n=!!e(t,r,i)}),n}function Dn(t,e,n,r){var i=r,a=i;return Po(t,function(t,s,o){var u=+e(t,s,o);(n(u,i)||u===r&&u===a)&&(i=u,a=t)}),a}function Tn(t,e,n,r){var i=t.length;for(n=null==n?0:+n||0,0>n&&(n=-n>i?0:i+n),r=r===E||r>i?i:+r||0,0>r&&(r+=i),i=n>r?0:r>>>0,n>>>=0;i>n;)t[n++]=e;return t}function Sn(t,e){var n=[];return Po(t,function(t,r,i){e(t,r,i)&&n.push(t)}),n}function Cn(t,e,n,r){var i;return n(t,function(t,n,a){return e(t,n,a)?(i=r?n:t,!1):void 0}),i}function Fn(t,e,n,r){r||(r=[]);for(var i=-1,a=t.length;++i<a;){var s=t[i];m(s)&&Xr(s)&&(n||Cu(s)||Ea(s))?e?Fn(s,e,n,r):ln(r,s):n||(r[r.length]=s)}return r}function On(t,e){return Ro(t,e,ts)}function Bn(t,e){return Ro(t,e,ju)}function In(t,e){return Yo(t,e,ju)}function Mn(t,e){for(var n=-1,r=e.length,i=-1,a=[];++n<r;){var s=e[n];Ia(t[s])&&(a[++i]=s)}return a}function Ln(t,e,n){if(null!=t){n!==E&&n in hi(t)&&(e=[n]);for(var r=0,i=e.length;null!=t&&i>r;)t=t[e[r++]];return r&&r==i?t:E}}function Pn(t,e,n,r,i,a){return t===e?!0:null==t||null==e||!Ma(t)&&!m(e)?t!==t&&e!==e:Nn(t,e,Pn,n,r,i,a)}function Nn(t,e,n,r,i,a,s){var o=Cu(t),u=Cu(e),c=H,l=H;o||(c=no.call(t),c==V?c=J:c!=J&&(o=Wa(t))),u||(l=no.call(e),l==V?l=J:l!=J&&(u=Wa(e)));var h=c==J,f=l==J,d=c==l;if(d&&!o&&!h)return Yr(t,e,c);if(!i){var p=h&&to.call(t,"__wrapped__"),g=f&&to.call(e,"__wrapped__");if(p||g)return n(p?t.value():t,g?e.value():e,r,i,a,s)}if(!d)return!1;a||(a=[]),s||(s=[]);for(var y=a.length;y--;)if(a[y]==t)return s[y]==e;a.push(t),s.push(e);var m=(o?Rr:jr)(t,e,n,r,i,a,s);return a.pop(),s.pop(),m}function Rn(t,e,n){var r=e.length,i=r,a=!n;if(null==t)return!i;for(t=hi(t);r--;){var s=e[r];if(a&&s[2]?s[1]!==t[s[0]]:!(s[0]in
for(var r=-1,i=wo(yo((e-t)/(n||1)),0),a=js(i);++r<i;)a[r]=t,t+=n;return a}function Ps(t,e,n){if(t=vo(t),1>t||!bo(t))return[];var r=-1,i=js(ko(t,Co));for(e=sr(e,n,1);++r<t;)Co>r?i[r]=e(r):e(r);return i}function Ns(t){var e=++eo;return o(t)+e}function Rs(t,e){return(+t||0)+(+e||0)}function Ys(t,e,n){return n&&Jr(t,e,n)&&(e=E),e=$r(e,n,3),1==e.length?pn(Cu(t)?t:li(t),e):Jn(t,e)}t=t?rn.defaults(nn.Object(),t,rn.pick(nn,je)):nn;{var js=t.Array,$s=t.Date,Us=t.Error,Ws=t.Function,Gs=t.Math,Vs=t.Number,Hs=t.Object,zs=t.RegExp,qs=t.String,Zs=t.TypeError,Ks=js.prototype,Xs=Hs.prototype,Qs=qs.prototype,Js=Ws.prototype.toString,to=Xs.hasOwnProperty,eo=0,no=Xs.toString,ro=nn._,io=zs("^"+Js.call(to).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ao=t.ArrayBuffer,so=t.clearTimeout,oo=t.parseFloat,uo=Gs.pow,co=Xs.propertyIsEnumerable,lo=Vr(t,"Set"),ho=t.setTimeout,fo=Ks.splice,po=t.Uint8Array,go=Vr(t,"WeakMap"),yo=Gs.ceil,mo=Vr(Hs,"create"),vo=Gs.floor,_o=Vr(js,"isArray"),bo=t.isFinite,xo=Vr(Hs,"keys"),wo=Gs.max,ko=Gs.min,Ao=Vr($s,"now"),Eo=t.parseInt,Do=Gs.random,To=Vs.NEGATIVE_INFINITY,So=Vs.POSITIVE_INFINITY,Co=4294967295,Fo=Co-1,Oo=Co>>>1,Bo=9007199254740991,Io=go&&new go,Mo={};e.support={}}e.templateSettings={escape:xe,evaluate:we,interpolate:ke,variable:"",imports:{_:e}};var Lo=function(){function t(){}return function(e){if(Ma(e)){t.prototype=e;var n=new t;t.prototype=E}return n||{}}}(),Po=fr(Bn),No=fr(In,!0),Ro=dr(),Yo=dr(!0),jo=Io?function(t,e){return Io.set(t,e),t}:Ts,$o=Io?function(t){return Io.get(t)}:Bs,Uo=Gn("length"),Wo=function(){var t=0,e=0;return function(n,r){var i=gu(),a=Y-(i-e);if(e=i,a>0){if(++t>=R)return n}else t=0;return jo(n,r)}}(),Go=ma(function(t,e){return m(t)&&Xr(t)?An(t,Fn(e,!1,!0)):[]}),Vo=wr(),Ho=wr(!0),zo=ma(function(t){for(var e=t.length,n=e,r=js(h),i=Wr(),s=i==a,o=[];n--;){var u=t[n]=Xr(u=t[n])?u:[];r[n]=s&&u.length>=120?gr(n&&u):null}var c=t[0],l=-1,h=c?c.length:0,f=r[0];t:for(;++l<h;)if(u=c[l],(f?Xe(f,u):i(o,u,0))<0){for(var n=e;--n;){var d=r[n];if((d?Xe(d,u):i(t[n],u,0))<0)continue t}f&&f.push(u),o.push(u)}return o}),qo=ma(function(t,e){e=Fn(e);var n=_n(t,e);return Hn(t,e.sort(r)),n}),Zo=Pr(),Ko=Pr(!0),Xo=ma(function(t){return tr(Fn(t,!1,!0))}),Qo=ma(function(t,e){return Xr(t)?An(t,e):[]}),Jo=ma(Ni),tu=ma(function(t){var e=t.length,n=e>2?t[e-2]:E,r=e>1?t[e-1]:E;return e>2&&"function"==typeof n?e-=2:(n=e>1&&"function"==typeof r?(--e,r):E,r=E),t.length=e,Ri(t,n,r)}),eu=ma(function(t){return t=Fn(t),this.thru(function(e){return Je(Cu(e)?e:[hi(e)],t)})}),nu=ma(function(t,e){return _n(t,Fn(e))}),ru=lr(function(t,e,n){to.call(t,n)?++t[n]:t[n]=1}),iu=xr(Po),au=xr(No,!0),su=Er(en,Po),ou=Er(an,No),uu=lr(function(t,e,n){to.call(t,n)?t[n].push(e):t[n]=[e]}),cu=lr(function(t,e,n){t[n]=e}),lu=ma(function(t,e,n){var r=-1,i="function"==typeof e,a=ti(e),s=Xr(t)?js(t.length):[];return Po(t,function(t){var o=i?e:a&&null!=t?t[e]:E;s[++r]=o?o.apply(t,n):Kr(t,e,n)}),s}),hu=lr(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),fu=Or(hn,Po),du=Or(fn,No),pu=ma(function(t,e){if(null==t)return[];var n=e[2];return n&&Jr(e[0],e[1],n)&&(e.length=1),Qn(t,Fn(e),[])}),gu=Ao||function(){return(new $s).getTime()},yu=ma(function(t,e,n){var r=T;if(n.length){var i=_(n,yu.placeholder);r|=B}return Nr(t,r,e,n,i)}),mu=ma(function(t,e){e=e.length?Fn(e):Ka(t);for(var n=-1,r=e.length;++n<r;){var i=e[n];t[i]=Nr(t[i],T,t)}return t}),vu=ma(function(t,e,n){var r=T|S;if(n.length){var i=_(n,vu.placeholder);r|=B}return Nr(e,r,t,n,i)}),_u=vr(F),bu=vr(O),xu=ma(function(t,e){return kn(t,1,e)}),wu=ma(function(t,e,n){return kn(t,e,n)}),ku=Ar(),Au=Ar(!0),Eu=ma(function(t,e){if(e=Fn(e),"function"!=typeof t||!sn(e,s))throw new Zs(W);var n=e.length;return ma(function(r){for(var i=ko(r.length,n);i--;)r[i]=e[i](r[i]);return t.apply(this,r)})}),Du=Fr(B),Tu=Fr(I),Su=ma(function(t,e){return Nr(t,L,E,E,E,Fn(e))}),Cu=_o||function(t){return m(t)&&ni(t.length)&&no.call(t)==H},Fu=hr(Un),Ou=hr(function(t,e,n){return n?mn(t,e,n):vn(t,e)}),Bu=_r(Ou,gn),Iu=_r(Fu,ai),Mu=kr(Bn),Lu=kr(In),Pu=Dr(R
}else this._isDSTShifted=!1;return this._isDSTShifted}function Ze(){return!this._isUTC}function Ke(){return this._isUTC}function Xe(){return this._isUTC&&0===this._offset}function Qe(t,e){var n,r,i,a=t,s=null;return Pe(t)?a={ms:t._milliseconds,d:t._days,M:t._months}:"number"==typeof t?(a={},e?a[e]=t:a.milliseconds=t):(s=Ti.exec(t))?(n="-"===s[1]?-1:1,a={y:0,d:v(s[li])*n,h:v(s[hi])*n,m:v(s[fi])*n,s:v(s[di])*n,ms:v(s[pi])*n}):(s=Si.exec(t))?(n="-"===s[1]?-1:1,a={y:Je(s[2],n),M:Je(s[3],n),d:Je(s[4],n),h:Je(s[5],n),m:Je(s[6],n),s:Je(s[7],n),w:Je(s[8],n)}):null==a?a={}:"object"==typeof a&&("from"in a||"to"in a)&&(i=en(Oe(a.from),Oe(a.to)),a={},a.ms=i.milliseconds,a.M=i.months),r=new Le(a),Pe(t)&&o(t,"_locale")&&(r._locale=t._locale),r}function Je(t,e){var n=t&&parseFloat(t.replace(",","."));return(isNaN(n)?0:n)*e}function tn(t,e){var n={milliseconds:0,months:0};return n.months=e.month()-t.month()+12*(e.year()-t.year()),t.clone().add(n.months,"M").isAfter(e)&&--n.months,n.milliseconds=+e-+t.clone().add(n.months,"M"),n}function en(t,e){var n;return e=Ye(e,t),t.isBefore(e)?n=tn(t,e):(n=tn(e,t),n.milliseconds=-n.milliseconds,n.months=-n.months),n}function nn(t,e){return function(n,r){var i,a;return null===r||isNaN(+r)||(re(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period)."),a=n,n=r,r=a),n="string"==typeof n?+n:n,i=Qe(n,r),rn(this,i,t),this}}function rn(t,e,r,i){var a=e._milliseconds,s=e._days,o=e._months;i=null==i?!0:i,a&&t._d.setTime(+t._d+a*r),s&&B(t,"Date",O(t,"Date")+s*r),o&&X(t,O(t,"Month")+o*r),i&&n.updateOffset(t,s||o)}function an(t,e){var n=t||Oe(),r=Ye(n,this).startOf("day"),i=this.diff(r,"days",!0),a=-6>i?"sameElse":-1>i?"lastWeek":0>i?"lastDay":1>i?"sameDay":2>i?"nextDay":7>i?"nextWeek":"sameElse";return this.format(e&&e[a]||this.localeData().calendar(a,this,Oe(n)))}function sn(){return new g(this)}function on(t,e){var n;return e=S("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Oe(t),+this>+t):(n=y(t)?+t:+Oe(t),n<+this.clone().startOf(e))}function un(t,e){var n;return e=S("undefined"!=typeof e?e:"millisecond"),"millisecond"===e?(t=y(t)?t:Oe(t),+t>+this):(n=y(t)?+t:+Oe(t),+this.clone().endOf(e)<n)}function cn(t,e,n){return this.isAfter(t,n)&&this.isBefore(e,n)}function ln(t,e){var n;return e=S(e||"millisecond"),"millisecond"===e?(t=y(t)?t:Oe(t),+this===+t):(n=+Oe(t),+this.clone().startOf(e)<=n&&n<=+this.clone().endOf(e))}function hn(t,e,n){var r,i,a=Ye(t,this),s=6e4*(a.utcOffset()-this.utcOffset());return e=S(e),"year"===e||"month"===e||"quarter"===e?(i=fn(this,a),"quarter"===e?i/=3:"year"===e&&(i/=12)):(r=this-a,i="second"===e?r/1e3:"minute"===e?r/6e4:"hour"===e?r/36e5:"day"===e?(r-s)/864e5:"week"===e?(r-s)/6048e5:r),n?i:m(i)}function fn(t,e){var n,r,i=12*(e.year()-t.year())+(e.month()-t.month()),a=t.clone().add(i,"months");return 0>e-a?(n=t.clone().add(i-1,"months"),r=(e-a)/(a-n)):(n=t.clone().add(i+1,"months"),r=(e-a)/(n-a)),-(i+r)}function dn(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function pn(){var t=this.clone().utc();return 0<t.year()&&t.year()<=9999?"function"==typeof Date.prototype.toISOString?this.toDate().toISOString():R(t,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):R(t,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")}function gn(t){var e=R(this,t||n.defaultFormat);return this.localeData().postformat(e)}function yn(t,e){return this.isValid()?Qe({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function mn(t){return this.from(Oe(),t)}function vn(t,e){return this.isValid()?Qe({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()}function _n(t){return this.to(Oe(),t)}function bn(t){var e;return void 0===t?this._locale._abbr:(e=D(t),null!=e&&(this._locale=e),this)}function xn(){return this._locale}function wn(t){switch(t=S(t)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===t&&this.weekday(0),"isoWeek"===t&&t
},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),r&&(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;this._input||(this.done=!0);var t,e,n,r;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]]),n&&(!e||n[0].length>e[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(t=this.test_match(n,i[a]),t!==!1)return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?(t=this.test_match(e,i[r]),t!==!1?t:!1):""===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(){var t=this.next();return t?t:this.lex()},begin:function(t){this.conditionStack.push(t)},popState:function(){var t=this.conditionStack.length-1;return t>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),t>=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 9;case 1:return 10;case 2:return 4;case 3:return 12;case 4:return 13;case 5:return 6;case 6:return"INVALID"}},rules:[/^(?:[\n]+)/i,/^(?:showInfo\b)/i,/^(?:info\b)/i,/^(?:say\b)/i,/^(?::[^#\n;]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6],inclusive:!0}}};return t}();return r.lexer=i,t.prototype=r,r.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof n&&(n.parser=i,n.Parser=i.Parser,n.parse=function(){return i.parse.apply(i,arguments)},n.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),r.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]
return t}();return $.lexer=U,t.prototype=$,$.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof n&&(n.parser=i,n.Parser=i.Parser,n.parse=function(){return i.parse.apply(i,arguments)},n.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),r.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("1YiZ5S"))},{"1YiZ5S":82,fs:80,path:81}],93:[function(t,e,n){(function(r){var i=function(){function t(){this.yy={}}var e=function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n},n=[1,4],r=[1,3],i=[1,5],a=[1,8,9,10,11,13,18,30,44,69,70,71,72,73,79,83,85,86,88,89,91,92,93],s=[2,2],o=[1,12],u=[1,13],c=[1,14],l=[1,15],h=[1,31],f=[1,33],d=[1,22],p=[1,34],g=[1,24],y=[1,25],m=[1,26],v=[1,27],_=[1,28],b=[1,36],x=[1,38],w=[1,35],k=[1,37],A=[1,43],E=[1,42],D=[1,39],T=[1,40],S=[1,41],C=[1,8,9,10,11,13,18,30,32,44,69,70,71,72,73,79,83,85,86,88,89,91,92,93],F=[1,51],O=[1,50],B=[1,52],I=[1,70],M=[1,78],L=[1,79],P=[1,64],N=[1,63],R=[1,83],Y=[1,82],j=[1,80],$=[1,81],U=[1,71],W=[1,66],G=[1,65],V=[1,61],H=[1,73],z=[1,74],q=[1,75],Z=[1,76],K=[1,77],X=[1,68],Q=[1,67],J=[8,9,11],te=[8,9,11,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62],ee=[1,112],ne=[8,9,10,11,13,15,18,36,38,40,44,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,79,83,85,86,88,89,91,92,93],re=[8,9,10,11,12,13,15,16,17,18,30,32,36,37,38,39,40,41,44,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,69,70,71,72,73,76,79,81,83,85,86,88,89,91,92,93],ie=[1,114],ae=[1,115],se=[8,9,10,11,13,18,30,32,44,69,70,71,72,73,79,83,85,86,88,89,91,92,93],oe=[8,9,10,11,12,13,15,16,17,18,30,32,37,39,41,44,48,49,50,51,52,54,55,56,57,58,59,60,61,62,63,69,70,71,72,73,76,79,81,83,85,86,88,89,91,92,93],ue=[13,18,44,79,83,85,86,88,89,91,92,93],ce=[13,18,44,47,63,79,83,85,86,88,89,91,92,93],le=[1,186],he=[1,183],fe=[1,190],de=[1,187],pe=[1,184],ge=[1,191],ye=[1,181],me=[1,182],ve=[1,185],_e=[1,188],be=[1,189],xe=[1,205],we=[8,9,11,83],ke=[8,9,10,11,44,69,78,79,81,83,85,86,87,88,89],Ae={trace:function(){},yy:{},symbols_:{error:2,mermaidDoc:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,DIR:13,FirstStmtSeperator:14,TAGEND:15,TAGSTART:16,UP:17,DOWN:18,ending:19,endToken:20,spaceList:21,spaceListNewline:22,verticeStatement:23,separator:24,styleStatement:25,linkStyleStatement:26,classDefStatement:27,classStatement:28,clickStatement:29,subgraph:30,text:31,end:32,vertex:33,link:34,alphaNum:35,SQS:36,SQE:37,PS:38,PE:39,DIAMOND_START:40,DIAMOND_STOP:41,alphaNumStatement:42,alphaNumToken:43,MINUS:44,linkStatement:45,arrowText:46,TESTSTR:47,"--":48,ARROW_POINT:49,ARROW_CIRCLE:50,ARROW_CROSS:51,ARROW_OPEN:52,"-.":53,DOTTED_ARROW_POINT:54,DOTTED_ARROW_CIRCLE:55,DOTTED_ARROW_CROSS:56,DOTTED_ARROW_OPEN:57,"==":58,THICK_ARROW_POINT:59,THICK_ARROW_CIRCLE:60,THICK_ARROW_CROSS:61,THICK_ARROW_OPEN:62,PIPE:63,textToken:64,STR:65,commentText:66,commentToken:67,keywords:68,STYLE:69,LINKSTYLE:70,CLASSDEF:71,CLASS:72,CLICK:73,textNoTags:74,textNoTagsToken:75,DEFAULT:76,stylesOpt:77,HEX:78,NUM:79,commentStatement:80,PCT:81,style:82,COMMA:83,styleComponent:84,ALPHA:85,COLON:86,UNIT:87,BRKT:88,DOT:89,graphCodeTokens:90,PLUS:91,EQUALS:92,MULT:93,TAG_START:94,TAG_END:95,QUOTE:96,$accept:0,$end:1},terminals_:{2:"error",8:"SEMI",9:"NEWLINE",10:"SPACE",11:"EOF",12:"GRAPH",13:"DIR",15:"TAGEND",16:"TAGSTART",17:"UP",18:"DOWN",30:"subgraph",32:"end",36:"SQS",37:"SQE",38:"PS",39:"PE",40:"DIAMOND_START",41:"DIAMOND_STOP",44:"MINUS",47:"TESTSTR",48:"--",49:"ARROW_POINT",50:"ARROW_CIRCLE",51:"ARROW_CROSS",52:"ARROW_OPEN",53:"-.",54:"DOTTED_ARROW_POINT",55:"DOTTED_ARROW_CIRCLE",56:"DOTTED_ARROW_CROSS",57:"DOTTED_ARROW_OPEN",58:"==",59:"THICK_ARROW_POINT",60:"THICK_ARROW_CIRCLE",61:"THICK_ARROW_CROSS",62:"THICK_ARROW_OPEN",63:"PIPE",65:"STR",69:"STYLE",70:"LINKSTYLE",71:"CLASSDEF",72:"CLASS",73:"CLICK",76:"DEFAULT",78:"HEX",79:"NUM",81:"PCT",83:"COMMA",85:"ALPHA",86:"COLON",87:"UNIT",88:"BRKT",89:"DOT",91:"PLUS",92:"EQUALS",93:"MULT",94:"TAG_START",95:"TAG_END",96:"QUOTE"},product
return t}();return Ae.lexer=Ee,t.prototype=Ae,Ae.Parser=t,new t}();"undefined"!=typeof t&&"undefined"!=typeof n&&(n.parser=i,n.Parser=i.Parser,n.parse=function(){return i.parse.apply(i,arguments)},n.main=function(e){e[1]||(console.log("Usage: "+e[0]+" FILE"),r.exit(1));var i=t("fs").readFileSync(t("path").normalize(e[1]),"utf8");return n.parser.parse(i)},"undefined"!=typeof e&&t.main===e&&n.main(r.argv.slice(1)))}).call(this,t("1YiZ5S"))},{"1YiZ5S":82,fs:80,path:81}],94:[function(t,e,n){var r=t("moment"),i=t("../../logger").create(),a="",s="",o=[],u=[],c="";n.clear=function(){o=[],u=[],c="",s="",d=0,l=void 0},n.setDateFormat=function(t){a=t},n.getDateFormat=function(){return a},n.setTitle=function(t){s=t},n.getTitle=function(){return s},n.addSection=function(t){c=t,o.push(t)},n.findTaskById=function(t){var e;for(e=0;e<u.length;e++)if(u[e].id===t)return u[e]},n.getTasks=function(){var t;for(t=1e4;t<u.length;t++)u[t].startTime=r(u[t].startTime).format(a),u[t].endTime=r(u[t].endTime).format(a);return u};var l,h=function(t,e,a){a=a.trim();var s=/^after\s+([\d\w\-]+)/,o=s.exec(a.trim());if(null!==o){var u=n.findTaskById(o[1]);if("undefined"==typeof u){var c=new Date;return c.setHours(0,0,0,0),c}return u.endTime}return r(a,e.trim(),!0).isValid()?r(a,e.trim(),!0).toDate():(i.debug("Invalid date:"+a),i.debug("With date format:"+e.trim()),new Date)},f=function(t,e,n){if(n=n.trim(),r(n,e.trim(),!0).isValid())return r(n,e.trim()).toDate();var i=r(t),a=/^([\d]+)([wdhms])/,s=a.exec(n.trim());if(null!==s){switch(s[2]){case"s":i.add(s[1],"seconds");break;case"m":i.add(s[1],"minutes");break;case"h":i.add(s[1],"hours");break;case"d":i.add(s[1],"days");break;case"w":i.add(s[1],"weeks")}return i.toDate()}return i.toDate()},d=0,p=function(t){return"undefined"==typeof t?(d+=1,"task"+d):t},g=function(t,e){var r;r=":"===e.substr(0,1)?e.substr(1,e.length):e;for(var i=r.split(","),a={},s=n.getDateFormat(),o=!0;o;)o=!1,i[0].match(/^\s*active\s*$/)&&(a.active=!0,i.shift(1),o=!0),i[0].match(/^\s*done\s*$/)&&(a.done=!0,i.shift(1),o=!0),i[0].match(/^\s*crit\s*$/)&&(a.crit=!0,i.shift(1),o=!0);var u;for(u=0;u<i.length;u++)i[u]=i[u].trim();switch(i.length){case 1:a.id=p(),a.startTime=t.endTime,a.endTime=f(a.startTime,s,i[0]);break;case 2:a.id=p(),a.startTime=h(void 0,s,i[0]),a.endTime=f(a.startTime,s,i[1]);break;case 3:a.id=p(i[0]),a.startTime=h(void 0,s,i[1]),a.endTime=f(a.startTime,s,i[2])}return a};n.addTask=function(t,e){var n={section:c,type:c,description:t,task:t},r=g(l,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,l=n,u.push(n)},n.parseError=function(t,e){mermaidAPI.parseError(t,e)}},{"../../logger":102,moment:83}],95:[function(t,e){var n=t("./parser/gantt").parser;n.yy=t("./ganttDb");var r,i=t("../../d3"),a=t("moment"),s=(t("../../logger").create(),{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,sidePadding:75,gridLineStartPadding:35,fontSize:11,fontFamily:'"Open-Sans", "sans-serif"'});e.exports.setConf=function(t){var e=Object.keys(t);e.forEach(function(e){s[e]=t[e]})};var o;e.exports.draw=function(t,e){function u(t,e,n){var r=s.barHeight,a=r+s.barGap,o=s.topPadding,u=s.sidePadding,d=i.scale.linear().domain([0,k.length]).range(["#00B9FA","#F95002"]).interpolate(i.interpolateHcl);l(u,o,e,n),c(t,a,o,u,r,d,e,n),h(a,o,u,r,d),f(u,o,e,n)}function c(t,e,n,r,i,a,o){{var u=(_.append("g").selectAll("rect").data(t).enter().append("rect").attr("x",0).attr("y",function(t,r){return r*e+n-2}).attr("width",function(){return o-r/2}).attr("height",e).attr("class",function(t){for(var e=0;e<k.length;e++)if(t.type===k[e])return"section section"+e%s.numberSectionStyles;return"section section0"}),_.append("g").selectAll("rect").data(t).enter());u.append("rect").attr("rx",3).attr("ry",3).attr("x",function(t){return w(t.startTime)+r}).attr("y",function(t,r){return r*e+n}).attr("width",function(t){return w(t.endTime)-w(t.startTime)}).attr("height",i).attr("class",function(t){for(var e="task ",n=0,r=0;r<k.length;r++)t.type===k[r]&&(n=r%s.numberSectionStyles);return t.active?t.crit?e+" activeCrit"+n:e+" acti
break;case"else":n.addSignal(void 0,void 0,t.altText,t.signalType);break;case"altEnd":n.addSignal(void 0,void 0,void 0,t.signalType)}}},{"../../logger":102}],99:[function(t,e,n){var r=t("./parser/sequenceDiagram").parser;r.yy=t("./sequenceDb");var i=t("./svgDraw"),a=t("../../d3"),s=t("../../logger").create(),o={diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!1,bottomMarginAdj:1};n.bounds={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,list:[],init:function(){this.list=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0},updateVal:function(t,e,n,r){t[e]="undefined"==typeof t[e]?n:r(n,t[e])},updateLoops:function(t,e,r,i){var a=this,s=0;this.list.forEach(function(u){s++;var c=a.list.length-s+1;a.updateVal(u,"startx",t-c*o.boxMargin,Math.min),a.updateVal(u,"starty",e-c*o.boxMargin,Math.min),a.updateVal(u,"stopx",r+c*o.boxMargin,Math.max),a.updateVal(u,"stopy",i+c*o.boxMargin,Math.max),a.updateVal(n.bounds.data,"startx",t-c*o.boxMargin,Math.min),a.updateVal(n.bounds.data,"starty",e-c*o.boxMargin,Math.min),a.updateVal(n.bounds.data,"stopx",r+c*o.boxMargin,Math.max),a.updateVal(n.bounds.data,"stopy",i+c*o.boxMargin,Math.max)})},insert:function(t,e,r,i){var a,s,o,u;a=Math.min(t,r),o=Math.max(t,r),s=Math.min(e,i),u=Math.max(e,i),this.updateVal(n.bounds.data,"startx",a,Math.min),this.updateVal(n.bounds.data,"starty",s,Math.min),this.updateVal(n.bounds.data,"stopx",o,Math.max),this.updateVal(n.bounds.data,"stopy",u,Math.max),this.updateLoops(a,s,o,u)},newLoop:function(t){this.list.push({startx:void 0,starty:this.verticalPos,stopx:void 0,stopy:void 0,title:t})},endLoop:function(){var t=this.list.pop();return t},addElseToLoop:function(t){var e=this.list.pop();e.elsey=n.bounds.getVerticalPos(),e.elseText=t,this.list.push(e)},bumpVerticalPos:function(t){this.verticalPos=this.verticalPos+t,this.data.stopy=this.verticalPos},getVerticalPos:function(){return this.verticalPos},getBounds:function(){return this.data}};var u=function(t,e,r,a){var s=i.getNoteRect();s.x=e,s.y=r,s.width=o.width,s.class="note";var u=t.append("g"),c=i.drawRect(u,s),l=i.getTextObj();l.x=e-4,l.y=r-13,l.textMargin=o.noteMargin,l.dy="1em",l.text=a.message,l.class="noteText";var h=i.drawText(u,l,o.width-o.noteMargin),f=h[0][0].getBBox().height;f>o.width?(h.remove(),u=t.append("g"),h=i.drawText(u,l,2*o.width-o.noteMargin),f=h[0][0].getBBox().height,c.attr("width",2*o.width),n.bounds.insert(e,r,e+2*o.width,r+2*o.noteMargin+f)):n.bounds.insert(e,r,e+o.width,r+2*o.noteMargin+f),c.attr("height",f+2*o.noteMargin),n.bounds.bumpVerticalPos(f+2*o.noteMargin)},c=function(t,e,i,a,s){var o,u=t.append("g"),c=e+(i-e)/2,l=u.append("text").attr("x",c).attr("y",a-7).style("text-anchor","middle").attr("class","messageText").text(s.message);o="undefined"!=typeof l[0][0].getBBox?l[0][0].getBBox().width:l[0][0].getBoundingClientRect();var h;if(e===i){h=u.append("path").attr("d","M "+e+","+a+" C "+(e+60)+","+(a-10)+" "+(e+60)+","+(a+30)+" "+e+","+(a+20)),n.bounds.bumpVerticalPos(30);var f=Math.max(o/2,100);n.bounds.insert(e-f,n.bounds.getVerticalPos()-10,i+f,n.bounds.getVerticalPos())}else h=u.append("line"),h.attr("x1",e),h.attr("y1",a),h.attr("x2",i),h.attr("y2",a),n.bounds.insert(e,n.bounds.getVerticalPos()-10,i,n.bounds.getVerticalPos());s.type===r.yy.LINETYPE.DOTTED||s.type===r.yy.LINETYPE.DOTTED_CROSS||s.type===r.yy.LINETYPE.DOTTED_OPEN?(h.style("stroke-dasharray","3, 3"),h.attr("class","messageLine1")):h.attr("class","messageLine0"),h.attr("stroke-width",2),h.attr("stroke","black"),h.style("fill","none"),(s.type===r.yy.LINETYPE.SOLID||s.type===r.yy.LINETYPE.DOTTED)&&h.attr("marker-end","url("+window.location.protocol+"//"+window.location.host+window.location.pathname+"#arrowhead)"),(s.type===r.yy.LINETYPE.SOLID_CROSS||s.type===r.yy.LINETYPE.DOTTED_CROSS)&&h.attr("marker-end","url("+window.location.protocol+"//"+window.location.host+window.location.pathname+"#crosshead)")};e.exports.drawActors=function(t,e,r,a){var s;for(s=0;s