mermaid/dist/mermaid.slim.min.js

8 lines
303 KiB
JavaScript
Raw Normal View History

2015-06-14 09:37:59 +02:00
!function t(e,r,n){function i(s,o){if(!r[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=r[s]={exports:{}};e[s][0].call(c.exports,function(t){var r=e[s][1][t];return i(r?r:t)},c,c.exports,t,e,r,n)}return r[s].exports}for(var a="function"==typeof require&&require,s=0;s<n.length;s++)i(n[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 r(t,e,r,n){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,r[n+"Style"])}function n(t,e,r,n){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,r[n+"Style"])}function i(t,e,r,n){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,r[n+"Style"])}var a=t("./util");e.exports={"default":r,normal:r,vee:n,undirected:i}},{"./util":27}],3:[function(t,e){function r(t,e){var r=e.nodes().filter(function(t){return n.isSubgraph(e,t)}),a=t.selectAll("g.cluster").data(r,function(t){return t});return a.selectAll("*").remove(),a.enter().append("g").attr("class","cluster").attr("id",function(t){var r=e.node(t);return r.id}).style("opacity",0),n.applyTransition(a,e).style("opacity",1),a.each(function(t){var r=e.node(t),n=d3.select(this),a=n.append("g").attr("class","label");d3.select(this).append("rect"),i(a,r,r.clusterLabelPos)}),a.selectAll("rect").each(function(t){var r=e.node(t),i=d3.select(this);n.applyStyle(i,r.style)}),n.applyTransition(a.exit(),e).style("opacity",0).remove(),a}var n=t("./util"),i=t("./label/add-label");e.exports=r},{"./label/add-label":18,"./util":27}],4:[function(t,e){"use strict";function r(t,e){var r=t.selectAll("g.edgeLabel").data(e.edges(),function(t){return a.edgeToId(t)}).classed("update",!0);return r.selectAll("*").remove(),r.enter().append("g").classed("edgeLabel",!0).style("opacity",0),r.each(function(t){var r=e.edge(t),a=i(s.select(this),e.edge(t),0,0).classed("label",!0),o=a.node().getBBox();r.labelId&&a.attr("id",r.labelId),n.has(r,"width")||(r.width=o.width),n.has(r,"height")||(r.height=o.height)}),a.applyTransition(r.exit(),e).style("opacity",0).remove(),r}var n=t("./lodash"),i=t("./label/add-label"),a=t("./util"),s=t("./d3");e.exports=r},{"./d3":7,"./label/add-label":18,"./lodash":21,"./util":27}],5:[function(t,e){"use strict";function r(t,e,r){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 r=h.select(this),n=e.edge(t);n.elem=this,n.id&&r.attr("id",n.id),l.applyClass(r,n["class"],(r.classed("update")?"update ":"")+"edgePath")}),i.selectAll("path.path").each(function(t){var r=e.edge(t);r.arrowheadId=u.uniqueId("arrowhead");var i=h.select(this).attr("marker-end",function(){return"url(#"+r.arrowheadId+")"}).style("fill","none");l.applyTransition(i,e).attr("d",function(t){return n(e,t)}),l.applyStyle(i,r.style)}),i.selectAll("defs *").remove(),i.selectAll("defs").each(function(t){var n=e.edge(t),i=r[n.arrowhead];i(h.select(this),n.arrowheadId,n,"arrowhead"
function r(t){function e(i){if(!n.has(r,i)){r[i]=!0;var a=t.node(i);s[a.rank].push(i),n.each(t.successors(i),e)}}var r={},i=n.filter(t.nodes(),function(e){return!t.children(e).length}),a=n.max(n.map(i,function(e){return t.node(e).rank})),s=n.map(n.range(a+1),function(){return[]}),o=n.sortBy(i,function(e){return t.node(e).rank});return n.each(o,e),s}var n=t("../lodash");e.exports=r},{"../lodash":38}],47:[function(t,e){"use strict";function r(t,e){var r={};a.each(t,function(t,e){var n=r[t.v]={indegree:0,"in":[],out:[],vs:[t.v],i:e};a.isUndefined(t.barycenter)||(n.barycenter=t.barycenter,n.weight=t.weight)}),a.each(e.edges(),function(t){var e=r[t.v],n=r[t.w];a.isUndefined(e)||a.isUndefined(n)||(n.indegree++,e.out.push(r[t.w]))});var i=a.filter(r,function(t){return!t.indegree});return n(i)}function n(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 r(e){return function(r){r["in"].push(e),0===--r.indegree&&t.push(r)}}for(var n=[];t.length;){var s=t.pop();n.push(s),a.each(s["in"].reverse(),e(s)),a.each(s.out,r(s))}return a.chain(n).filter(function(t){return!t.merged}).map(function(t){return a.pick(t,["vs","i","barycenter","weight"])}).value()}function i(t,e){var r=0,n=0;t.weight&&(r+=t.barycenter*t.weight,n+=t.weight),e.weight&&(r+=e.barycenter*e.weight,n+=e.weight),t.vs=e.vs.concat(t.vs),t.barycenter=r/n,t.weight=n,t.i=Math.min(e.i,t.i),e.merged=!0}var a=t("../lodash");e.exports=r},{"../lodash":38}],48:[function(t,e){function r(t,e,c,l){var h=t.children(e),d=t.node(e),f=d?d.borderLeft:void 0,p=d?d.borderRight:void 0,g={};f&&(h=a.filter(h,function(t){return t!==f&&t!==p}));var y=s(t,h);a.each(y,function(e){if(t.children(e.v).length){var n=r(t,e.v,c,l);g[e.v]=n,a.has(n,"barycenter")&&i(e,n)}});var m=o(y,c);n(m,g);var v=u(m,l);if(f&&(v.vs=a.flatten([f,v.vs,p],!0),t.predecessors(f).length)){var b=t.node(t.predecessors(f)[0]),_=t.node(t.predecessors(p)[0]);a.has(v,"barycenter")||(v.barycenter=0,v.weight=0),v.barycenter=(v.barycenter*v.weight+b.order+_.order)/(v.weight+2),v.weight+=2}return v}function n(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=r},{"../lodash":38,"./barycenter":42,"./resolve-conflicts":47,"./sort":49}],49:[function(t,e){function r(t,e){var r=s.partition(t,function(t){return a.has(t,"barycenter")}),o=r.lhs,u=a.sortBy(r.rhs,function(t){return-t.i}),c=[],l=0,h=0,d=0;o.sort(i(!!e)),d=n(c,u,d),a.each(o,function(t){d+=t.vs.length,c.push(t.vs),l+=t.barycenter*t.weight,h+=t.weight,d=n(c,u,d)});var f={vs:a.flatten(c,!0)};return h&&(f.barycenter=l/h,f.weight=h),f}function n(t,e,r){for(var n;e.length&&(n=a.last(e)).i<=r;)e.pop(),t.push(n.vs),r++;return r}function i(t){return function(e,r){return e.barycenter<r.barycenter?-1:e.barycenter>r.barycenter?1:t?r.i-e.i:e.i-r.i}}var a=t("../lodash"),s=t("../util");e.exports=r},{"../lodash":38,"../util":57}],50:[function(t,e){function r(t){var e=i(t);a.each(t.graph().dummyChains,function(r){for(var i=t.node(r),a=i.edgeObj,s=n(t,e,a.v,a.w),o=s.path,u=s.lca,c=0,l=o[c],h=!0;r!==a.w;){if(i=t.node(r),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(r,l),r=t.successors(r)[0]}})}function n(t,e,r,n){var i,a,s=[],o=[],u=Math.min(e[r].low,e[n].low),c=Math.max(e[r].lim,e[n].lim);i=r;do i=t.parent(i),s.push(i);while(i&&(e[i].low>u||c>e[i].lim));for(a=i,i=n;(i=t.parent(i))!==a;)o.push(i);return{path:s.concat(o.reverse()),lca:a}}function i(t){function e(i){var s=n;a.each(t.children(i),e),r[i]={low:s,lim:n++}}var r={},n=0;return a.each(t.children(),e),r}var a=t("./lodash");e.exports=r},{"./lodash":38}],51:[function(t,e){"use strict";function r(t,e){function r(e,r){var s=0,o=0
2015-06-14 09:37:59 +02:00
},D=function(t,e){for(var r=-1,n=t.length;++r<n;)if(t[r]==e)return!0;return!1},E=function(t,e){if(!t)return e;var r,n={};for(r in e)n[r]=k(t,r)?t[r]:e[r];return n},C=function(t,e){var r="";return t>=55296&&57343>=t||t>1114111?(e&&F("character reference outside the permissible Unicode range"),"<22>"):k(b,t)?(e&&F("disallowed character reference"),b[t]):(e&&D(_,t)&&F("disallowed character reference"),t>65535&&(t-=65536,r+=w(t>>>10&1023|55296),t=56320|1023&t),r+=w(t))},T=function(t){return"&#x"+t.charCodeAt(0).toString(16).toUpperCase()+";"},F=function(t){throw Error("Parse error: "+t)},S=function(t,e){e=E(e,S.options);var r=e.strict;r&&g.test(t)&&F("forbidden code point");var n=e.encodeEverything,i=e.useNamedReferences,a=e.allowUnsafeSymbols;return n?(t=t.replace(u,function(t){return i&&k(h,t)?"&"+h[t]+";":T(t)}),i&&(t=t.replace(/&gt;\u20D2/g,"&nvgt;").replace(/&lt;\u20D2/g,"&nvlt;").replace(/&#x66;&#x6A;/g,"&fjlig;")),i&&(t=t.replace(l,function(t){return"&"+h[t]+";"}))):i?(a||(t=t.replace(d,function(t){return"&"+h[t]+";"})),t=t.replace(/&gt;\u20D2/g,"&nvgt;").replace(/&lt;\u20D2/g,"&nvlt;"),t=t.replace(l,function(t){return"&"+h[t]+";"})):a||(t=t.replace(d,T)),t.replace(o,function(t){var e=t.charCodeAt(0),r=t.charCodeAt(1),n=1024*(e-55296)+r-56320+65536;return"&#x"+n.toString(16).toUpperCase()+";"}).replace(c,T)};S.options={allowUnsafeSymbols:!1,encodeEverything:!1,strict:!1,useNamedReferences:!1};var B=function(t,e){e=E(e,B.options);var r=e.strict;return r&&p.test(t)&&F("malformed character reference"),t.replace(y,function(t,n,i,a,s,o,u,c){var l,h,d,f,p;return n?(l=n,h=i,r&&!h&&F("character reference was not terminated by a semicolon"),C(l,r)):a?(d=a,h=s,r&&!h&&F("character reference was not terminated by a semicolon"),l=parseInt(d,16),C(l,r)):o?(f=o,k(m,f)?m[f]:(r&&F("named character reference was not terminated by a semicolon"),t)):(f=u,p=c,p&&e.isAttributeValue?(r&&"="==p&&F("`&` did not start a character reference"),t):(r&&F("named character reference was not terminated by a semicolon"),v[f]+(p||"")))})};B.options={isAttributeValue:!1,strict:!1};var L=function(t){return t.replace(d,function(t){return f[t]})},O={version:"0.5.0",encode:S,decode:B,escape:L,unescape:B};if("function"==typeof define&&"object"==typeof define.amd&&define.amd)define(function(){return O});else if(i&&!i.nodeType)if(a)a.exports=O;else for(var I in O)k(O,I)&&(i[I]=O[I]);else n.he=O}(this)}).call(this,"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],83:[function(t,e,r){(function(t){(function(){function n(t,e,r){for(var n=(r||0)-1,i=t?t.length:0;++n<i;)if(t[n]===e)return n;return-1}function i(t,e){var r=typeof e;if(t=t.cache,"boolean"==r||null==e)return t[e]?0:-1;"number"!=r&&"string"!=r&&(r="object");var i="number"==r?e:_+e;return t=(t=t[r])&&t[i],"object"==r?t&&n(t,e)>-1?0:-1:t?0:-1}function a(t){var e=this.cache,r=typeof t;if("boolean"==r||null==t)e[t]=!0;else{"number"!=r&&"string"!=r&&(r="object");var n="number"==r?t:_+t,i=e[r]||(e[r]={});"object"==r?(i[n]||(i[n]=[])).push(t):i[n]=!0}}function s(t){return t.charCodeAt(0)}function o(t,e){for(var r=t.criteria,n=e.criteria,i=-1,a=r.length;++i<a;){var s=r[i],o=n[i];if(s!==o){if(s>o||"undefined"==typeof s)return 1;if(o>s||"undefined"==typeof o)return-1}}return t.index-e.index}function u(t){var e=-1,r=t.length,n=t[0],i=t[r/2|0],s=t[r-1];if(n&&"object"==typeof n&&i&&"object"==typeof i&&s&&"object"==typeof s)return!1;var o=h();o["false"]=o["null"]=o["true"]=o.undefined=!1;var u=h();for(u.array=t,u.cache=o,u.push=a;++e<r;)u.push(t[e]);return u}function c(t){return"\\"+K[t]}function l(){return m.pop()||[]}function h(){return v.pop()||{array:null,cache:null,criteria:null,"false":!1,index:0,"null":!1,number:null,object:null,push:null,string:null,"true":!1,undefined:!1,value:null}}function d(t){t.length=0,m.length<x&&m.push(t)}function f(t){var e=t.cache;e&&f(e),t.array=t.cache=t.criteria=t.object=t.number=t.string=t.value=null,v.length<x&&v.push(t)}function p(t,e,r){e||(e=0),"undefined"==typeof r&&(r=t?t.length:0);for(var n=-1,i=r-e||0,a=Array(0>i?0:i);++n<i;)a[n]=t[e+n];return a}fun
}function h(t){return null==t._pf&&(t._pf=l()),t._pf}function d(t){if(null==t._isValid){var e=h(t);t._isValid=!isNaN(t._d.getTime())&&e.overflow<0&&!e.empty&&!e.invalidMonth&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated,t._strict&&(t._isValid=t._isValid&&0===e.charsLeftOver&&0===e.unusedTokens.length&&void 0===e.bigHour)}return t._isValid}function f(t){var e=c(0/0);return null!=t?u(h(e),t):h(e).userInvalidated=!0,e}function p(t,e){var r,n,i;if("undefined"!=typeof e._isAMomentObject&&(t._isAMomentObject=e._isAMomentObject),"undefined"!=typeof e._i&&(t._i=e._i),"undefined"!=typeof e._f&&(t._f=e._f),"undefined"!=typeof e._l&&(t._l=e._l),"undefined"!=typeof e._strict&&(t._strict=e._strict),"undefined"!=typeof e._tzm&&(t._tzm=e._tzm),"undefined"!=typeof e._isUTC&&(t._isUTC=e._isUTC),"undefined"!=typeof e._offset&&(t._offset=e._offset),"undefined"!=typeof e._pf&&(t._pf=h(e)),"undefined"!=typeof e._locale&&(t._locale=e._locale),In.length>0)for(r in In)n=In[r],i=e[n],"undefined"!=typeof i&&(t[n]=i);return t}function g(t){p(this,t),this._d=new Date(+t._d),Nn===!1&&(Nn=!0,r.updateOffset(this),Nn=!1)}function y(t){return t instanceof g||null!=t&&null!=t._isAMomentObject}function m(t){var e=+t,r=0;return 0!==e&&isFinite(e)&&(r=e>=0?Math.floor(e):Math.ceil(e)),r}function v(t,e,r){var n,i=Math.min(t.length,e.length),a=Math.abs(t.length-e.length),s=0;for(n=0;i>n;n++)(r&&t[n]!==e[n]||!r&&m(t[n])!==m(e[n]))&&s++;return s+a}function b(){}function _(t){return t?t.toLowerCase().replace("_","-"):t}function w(t){for(var e,r,n,i,a=0;a<t.length;){for(i=_(t[a]).split("-"),e=i.length,r=_(t[a+1]),r=r?r.split("-"):null;e>0;){if(n=x(i.slice(0,e).join("-")))return n;if(r&&r.length>=e&&v(i,r,!0)>=e-1)break;e--}a++}return null}function x(r){var n=null;if(!Mn[r]&&"undefined"!=typeof e&&e&&e.exports)try{n=On._abbr,t("./locale/"+r),A(n)}catch(i){}return Mn[r]}function A(t,e){var r;return t&&(r="undefined"==typeof e?D(t):k(t,e),r&&(On=r)),On._abbr}function k(t,e){return null!==e?(e.abbr=t,Mn[t]||(Mn[t]=new b),Mn[t].set(e),A(t),Mn[t]):(delete Mn[t],null)}function D(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return On;if(!i(t)){if(e=x(t))return e;t=[t]}return w(t)}function E(t,e){var r=t.toLowerCase();Pn[r]=Pn[r+"s"]=Pn[e]=t}function C(t){return"string"==typeof t?Pn[t]||Pn[t.toLowerCase()]:void 0}function T(t){var e,r,n={};for(r in t)o(t,r)&&(e=C(r),e&&(n[e]=t[r]));return n}function F(t,e){return function(n){return null!=n?(B(this,t,n),r.updateOffset(this,e),this):S(this,t)}}function S(t,e){return t._d["get"+(t._isUTC?"UTC":"")+e]()}function B(t,e,r){return t._d["set"+(t._isUTC?"UTC":"")+e](r)}function L(t,e){var r;if("object"==typeof t)for(r in t)this.set(r,t[r]);else if(t=C(t),"function"==typeof this[t])return this[t](e);return this}function O(t,e,r){for(var n=""+Math.abs(t),i=t>=0;n.length<e;)n="0"+n;return(i?r?"+":"":"-")+n}function I(t,e,r,n){var i=n;"string"==typeof n&&(i=function(){return this[n]()}),t&&(Un[t]=i),e&&(Un[e[0]]=function(){return O(i.apply(this,arguments),e[1],e[2])}),r&&(Un[r]=function(){return this.localeData().ordinal(i.apply(this,arguments),t)})}function N(t){return t.match(/\[[\s\S]/)?t.replace(/^\[|\]$/g,""):t.replace(/\\/g,"")}function M(t){var e,r,n=t.match(Rn);for(e=0,r=n.length;r>e;e++)n[e]=Un[n[e]]?Un[n[e]]:N(n[e]);return function(i){var a="";for(e=0;r>e;e++)a+=n[e]instanceof Function?n[e].call(i,t):n[e];return a}}function P(t,e){return t.isValid()?(e=R(e,t.localeData()),Yn[e]||(Yn[e]=M(e)),Yn[e](t)):t.localeData().invalidDate()}function R(t,e){function r(t){return e.longDateFormat(t)||t}var n=5;for(qn.lastIndex=0;n>=0&&qn.test(t);)t=t.replace(qn,r),qn.lastIndex=0,n-=1;return t}function q(t,e,r){ri[t]="function"==typeof e?e:function(t){return t&&r?r:e}}function Y(t,e){return o(ri,t)?ri[t](e._strict,e._locale):new RegExp(U(t))}function U(t){return t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,e,r,n,i){return e||r||n||i}).replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function j(t,e){var r,n=e;for("string"==typeof t&&(t=[t]),"number"==typeof e&&(n=function(t,r){r[e]=m(t)}),r=
var Hi=Math.abs,Wi=An("ms"),zi=An("s"),Zi=An("m"),Ki=An("h"),Xi=An("d"),Ji=An("w"),Qi=An("M"),ta=An("y"),ea=Dn("milliseconds"),ra=Dn("seconds"),na=Dn("minutes"),ia=Dn("hours"),aa=Dn("days"),sa=Dn("months"),oa=Dn("years"),ua=Math.round,ca={s:45,m:45,h:22,d:26,M:11},la=Math.abs,ha=Le.prototype;ha.abs=pn,ha.add=yn,ha.subtract=mn,ha.as=wn,ha.asMilliseconds=Wi,ha.asSeconds=zi,ha.asMinutes=Zi,ha.asHours=Ki,ha.asDays=Xi,ha.asWeeks=Ji,ha.asMonths=Qi,ha.asYears=ta,ha.valueOf=xn,ha._bubble=vn,ha.get=kn,ha.milliseconds=ea,ha.seconds=ra,ha.minutes=na,ha.hours=ia,ha.days=aa,ha.weeks=En,ha.months=sa,ha.years=oa,ha.humanize=Sn,ha.toISOString=Bn,ha.toString=Bn,ha.toJSON=Bn,ha.locale=mr,ha.localeData=vr,ha.toIsoString=te("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Bn),ha.lang=Ci,I("X",0,0,"unix"),I("x",0,0,"valueOf"),q("x",Jn),q("X",ti),j("X",function(t,e,r){r._d=new Date(1e3*parseFloat(t,10))}),j("x",function(t,e,r){r._d=new Date(m(t))}),r.version="2.10.3",n(Te),r.fn=Ri,r.min=Se,r.max=Be,r.utc=c,r.unix=Kr,r.months=cn,r.isDate=a,r.locale=A,r.invalid=f,r.duration=Ze,r.isMoment=y,r.weekdays=hn,r.parseZone=Xr,r.localeData=D,r.isDuration=Oe,r.monthsShort=ln,r.weekdaysMin=fn,r.defineLocale=k,r.weekdaysShort=dn,r.normalizeUnits=C,r.relativeTimeThreshold=Fn;var da=r;return da})},{}],85:[function(t,e){e.exports={name:"mermaid",version:"0.5.1",description:"Markdownish syntax for generating flowcharts, sequence diagrams and gantt charts.",main:"src/mermaid.js",keywords:["diagram","markdown","flowchart","sequence diagram","gantt"],bin:{mermaid:"./bin/mermaid.js"},scripts:{test:"gulp test"},repository:{type:"git",url:"https://github.com/knsv/mermaid"},author:"Knut Sveidqvist",license:"MIT",dependencies:{chalk:"^0.5.1",d3:"~3.4.13","dagre-d3":"~0.4.8",he:"^0.5.0",minimist:"^1.1.0",mkdirp:"^0.5.0",moment:"^2.9.0",semver:"^4.1.1",which:"^1.0.8"},devDependencies:{async:"^0.9.0",browserify:"~6.2.0",clone:"^0.2.0","codeclimate-test-reporter":"0.0.4","connect-livereload":"^0.5.3",d3:"~3.4.13",dateformat:"^1.0.11","event-stream":"^3.2.0",express:"^4.12.4",foundation:"^4.2.1-1","front-matter":"^0.2.0",gulp:"~3.8.9","gulp-browserify":"^0.5.0","gulp-bump":"^0.1.11","gulp-concat":"~2.4.1","gulp-data":"^1.1.1","gulp-ext-replace":"~0.1.0","gulp-filelog":"^0.4.1","gulp-hogan":"^1.1.0","gulp-if":"^1.2.5","gulp-insert":"^0.4.0","gulp-istanbul":"^0.4.0","gulp-jasmine":"~1.0.1","gulp-jison":"~1.2.0","gulp-jshint":"^1.9.0","gulp-less":"^3.0.1","gulp-livereload":"^3.8.0","gulp-rename":"~1.2.0","gulp-shell":"^0.2.10","gulp-tag-version":"^1.2.1","gulp-uglify":"~1.0.1",he:"^0.5.0","hogan.js":"^3.0.2",jasmine:"~2.0.1",jison:"~0.4.15","jshint-stylish":"^1.0.0",karma:"~0.12.20","karma-chrome-launcher":"~0.1.5","karma-jasmine":"~0.2.1","karma-requirejs":"~0.2.2",lodash:"^2.4.1","lodash._escapestringchar":"^2.4.1","lodash._objecttypes":"^2.4.1","lodash._reinterpolate":"^2.4.1","lodash._reunescapedhtml":"^2.4.1","lodash.defaults":"^2.4.1","lodash.templatesettings":"^2.4.1","lodash.values":"^2.4.1",marked:"^0.3.2","mock-browser":"^0.90.27",path:"^0.4.9",phantomjs:"^1.9.17",proxyquire:"^1.3.1","require-dir":"^0.3.0",rewire:"^2.1.3",rimraf:"^2.2.8",tape:"^3.0.3","tiny-lr":"^0.1.6","vinyl-source-stream":"^1.1.0",watchify:"^3.2.2"}}},{}],86:[function(t,e){var r;if(t)try{r=t("d3")}catch(n){}r||(r=window.d3),e.exports=r,function(){var t=!1;if(t="tspans",r.selection.prototype.textwrap)return!1;if("undefined"==typeof t)var t=!1;r.selection.prototype.textwrap=r.selection.enter.prototype.textwrap=function(e,n){var i,n=parseInt(n)||0,a=this,s=function(t){var e=t[0][0],n=e.tagName.toString();if("rect"!==n)return!1;var i={};return i.x=r.select(e).attr("x")||0,i.y=r.select(e).attr("y")||0,i.width=r.select(e).attr("width")||0,i.height=r.select(e).attr("height")||0,i.attr=t.attr,i},o=function(t){if(t.attr||(t.attr=function(t){return this[t]?this[t]:void 0}),"object"==typeof t&&"undefined"!=typeof t.x&&"undefined"!=typeof t.y&&"undefined"!=typeof t.width&&"undefined"!=typeof t.height)return t;if("function"==typeof Array.isArray&&Array.isArray(t)||"[objec
C=[];for(k in s[w])this.terminals_[k]&&k>h&&C.push("'"+this.terminals_[k]+"'");F=p.showPosition?"Parse error on line "+(u+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(u+1)+": Unexpected "+(b==d?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(F,{text:p.match,token:this.terminals_[b]||b,line:p.yylineno,loc:m,expected:C})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+b);switch(x[0]){case 1:n.push(b),i.push(p.yytext),a.push(p.yylloc),n.push(x[1]),b=null,_?(b=_,_=null):(c=p.yyleng,o=p.yytext,u=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(D=this.productions_[x[1]][1],T.$=i[i.length-D],T._$={first_line:a[a.length-(D||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(D||1)].first_column,last_column:a[a.length-1].last_column},v&&(T._$.range=[a[a.length-(D||1)].range[0],a[a.length-1].range[1]]),A=this.performAction.apply(T,[o,c,u,g.yy,x[1],i,a].concat(f)),"undefined"!=typeof A)return A;D&&(n=n.slice(0,-1*D*2),i=i.slice(0,-1*D),a=a.slice(0,-1*D)),n.push(this.productions_[x[1]][0]),i.push(T.$),a.push(T._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},j=function(){var t={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];this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t;var e=t.match(/(?:\r\n?|\n).*/g);return e?(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,r=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 n=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),r.length-1&&(this.yylineno-=r.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:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[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 r,n,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.rang
break;case 3:return!0}}return!0}},Ae=function(){var t={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];this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t;var e=t.match(/(?:\r\n?|\n).*/g);return e?(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,r=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 n=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),r.length-1&&(this.yylineno-=r.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:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[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 r,n,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))),n=t[0].match(/(?:\r\n?|\n).*/g),n&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.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],r=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;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,r,n;this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;a<i.length;a++)if(r=this._input.match(this.rules[i[a]]),r&&(!e||r[0].length>e[0].length)){if(e=r,n=a,this.options.backtrack_lexer){if(t=this.test_match(r,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(
this.trace(t)},parse:function(t){function e(){var t;return t=p.lex()||d,"number"!=typeof t&&(t=r.symbols_[t]||t),t}var r=this,n=[0],i=[null],a=[],s=this.table,o="",u=0,c=0,l=0,h=2,d=1,f=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,"undefined"==typeof p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var v=p.options&&p.options.ranges;this.parseError="function"==typeof g.yy.parseError?g.yy.parseError:Object.getPrototypeOf(this).parseError;for(var b,_,w,x,A,k,D,E,C,T={};;){if(w=n[n.length-1],this.defaultActions[w]?x=this.defaultActions[w]:((null===b||"undefined"==typeof b)&&(b=e()),x=s[w]&&s[w][b]),"undefined"==typeof x||!x.length||!x[0]){var F="";C=[];for(k in s[w])this.terminals_[k]&&k>h&&C.push("'"+this.terminals_[k]+"'");F=p.showPosition?"Parse error on line "+(u+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(u+1)+": Unexpected "+(b==d?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(F,{text:p.match,token:this.terminals_[b]||b,line:p.yylineno,loc:m,expected:C})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+b);switch(x[0]){case 1:n.push(b),i.push(p.yytext),a.push(p.yylloc),n.push(x[1]),b=null,_?(b=_,_=null):(c=p.yyleng,o=p.yytext,u=p.yylineno,m=p.yylloc,l>0&&l--);break;case 2:if(D=this.productions_[x[1]][1],T.$=i[i.length-D],T._$={first_line:a[a.length-(D||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(D||1)].first_column,last_column:a[a.length-1].last_column},v&&(T._$.range=[a[a.length-(D||1)].range[0],a[a.length-1].range[1]]),A=this.performAction.apply(T,[o,c,u,g.yy,x[1],i,a].concat(f)),"undefined"!=typeof A)return A;D&&(n=n.slice(0,-1*D*2),i=i.slice(0,-1*D),a=a.slice(0,-1*D)),n.push(this.productions_[x[1]][0]),i.push(T.$),a.push(T._$),E=s[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0}},_=function(){var t={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];this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t;var e=t.match(/(?:\r\n?|\n).*/g);return e?(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,r=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 n=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),r.length-1&&(this.yylineno-=r.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:r?(r.length===n.length?this.yylloc.first_column:0)+n[n.length-r.length].length-r[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.le